]> git.lyx.org Git - lyx.git/blob - lib/doc/Additional.lyx
9a4826f79f0adabe2c70ab7f8cfd44314bd68cfa
[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 1
84 \use_package esint 1
85 \use_package mathdots 1
86 \use_package mathtools 1
87 \use_package mhchem 1
88 \use_package stackrel 1
89 \use_package stmaryrd 1
90 \use_package undertilde 1
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 false
119 \output_changes false
120 \html_math_output 0
121 \html_css_as_file 0
122 \html_be_strict true
123 \end_header
124
125 \begin_body
126
127 \begin_layout Title
128 Additional \SpecialChar LyX
129  Features
130 \end_layout
131
132 \begin_layout Subtitle
133 Version 2.3.x
134 \end_layout
135
136 \begin_layout Author
137 by the \SpecialChar LyX
138  Team
139 \begin_inset Foot
140 status collapsed
141
142 \begin_layout Plain Layout
143 \noindent
144 Principal maintainer of this file is
145 \noun on
146  Richard Heck
147 \noun default
148 .
149  If you have comments or error corrections, please send them to the \SpecialChar LyX
150  Documentati
151 on mailing list, 
152 \begin_inset Flex Code
153 status collapsed
154
155 \begin_layout Plain Layout
156 \noindent
157 <lyx-docs@lists.lyx.org>
158 \end_layout
159
160 \end_inset
161
162 .
163 \end_layout
164
165 \end_inset
166
167
168 \end_layout
169
170 \begin_layout Standard
171 \begin_inset CommandInset toc
172 LatexCommand tableofcontents
173
174 \end_inset
175
176
177 \end_layout
178
179 \begin_layout Chapter
180 Introduction
181 \end_layout
182
183 \begin_layout Standard
184 This manual is essentially Part II of the 
185 \emph on
186 User's Guide\SpecialChar endofsentence
187
188 \emph default
189  The reason for separating the two documents is simple: the 
190 \emph on
191 User's Guide
192 \emph default
193  is already quite lengthy, and it contains information on all of the basic
194  features one needs to know in order to prepare most documents.
195  However, the \SpecialChar LyX
196  Team has worked to make \SpecialChar LyX
197  extensible through various configuration
198  files and external packages.
199  That means that if you want to support the Fizzwizzle \SpecialChar LaTeX
200  package, you can
201  create a layout file (or module) for it without having to alter \SpecialChar LyX
202  itself.
203  We've already had contributions of several new features this way, and some
204  of them are documented here.
205  There are also some more `advanced' features, such as how to control the
206  presentation of bibliographies and how to work with multi-part documents,
207  that are not covered in the 
208 \emph on
209 User's Guide
210 \emph default
211  and are discussed here.
212 \end_layout
213
214 \begin_layout Standard
215 This manual also documents some special features, like fax support, version
216  control, and SGML support, which require additional software to work properly.
217  There is also a chapter on \SpecialChar LyX
218 's support for HTML.
219  And lastly, there's a chapter of \SpecialChar LaTeX
220  tools and tips, things you can use to
221  spruce up your documents by directly using the powerful features of \SpecialChar LaTeX
222 .
223  After all, \SpecialChar LyX
224  
225 \emph on
226 is
227 \emph default
228  only WYSIWYM and will only ever interface to some, not all, \SpecialChar LaTeX
229  features.
230 \end_layout
231
232 \begin_layout Standard
233 If you haven't read the 
234 \emph on
235 Introduction
236 \emph default
237  yet, you are definitely in the wrong manual.
238  The 
239 \emph on
240 Introduction
241 \emph default
242  is the first place to go, since it describes the notation and format of
243  all of the manuals.
244  You should also be thoroughly familiar with the 
245 \emph on
246 User's Guide
247 \emph default
248  and all of the basic features of \SpecialChar LyX
249  before attempting to read this one.
250 \end_layout
251
252 \begin_layout Standard
253 Since many of the topics in this manual depend heavily on \SpecialChar LyX
254 's interaction
255  with \SpecialChar LaTeX
256 , this first chapter covers the inner workings of \SpecialChar LyX
257  and how to direct
258  \SpecialChar LyX
259  to generate exactly the \SpecialChar LaTeX
260  code you want.
261  It is obviously for more seasoned \SpecialChar LyX
262  users.
263 \end_layout
264
265 \begin_layout Chapter
266 \SpecialChar LyX
267  and \SpecialChar LaTeX
268
269 \end_layout
270
271 \begin_layout Section
272 How \SpecialChar LyX
273  Uses \SpecialChar LaTeX
274
275 \end_layout
276
277 \begin_layout Standard
278 This chapter is for both \SpecialChar TeX
279 -nicians and the \SpecialChar LaTeX
280 -curious.
281  In it, we'll explain how \SpecialChar LyX
282  and \SpecialChar LaTeX
283  work together to produce printable output.
284  This is the only place in any of the manuals where we assume you know something
285  about \SpecialChar LaTeX
286 .
287 \end_layout
288
289 \begin_layout Standard
290 At one time, \SpecialChar LyX
291  was called a 
292 \begin_inset Quotes eld
293 \end_inset
294
295 WYSIWYM frontend to \SpecialChar LaTeX
296 ,
297 \begin_inset Quotes erd
298 \end_inset
299
300  but that's no longer true.
301  There are frontends to \SpecialChar LaTeX
302  out there.
303 \begin_inset Foot
304 status collapsed
305
306 \begin_layout Plain Layout
307 Some familar ones are \SpecialChar TeX
308 maker and kile, on Linux, and \SpecialChar TeX
309 shop, OSX.
310  There are also the \SpecialChar LaTeX
311  modes for vi and emacs, of course.
312 \end_layout
313
314 \end_inset
315
316  These are basically text editors with the ability to run \SpecialChar LaTeX
317  and mark any
318  errors in the file you're editing.
319  Although \SpecialChar LyX
320  
321 \emph on
322 is
323 \emph default
324  an editor, and it 
325 \emph on
326 does
327 \emph default
328  run \SpecialChar LaTeX
329 , and it also indicates errors in the file, it also does much, much
330  more.
331  For one thing, you don't need to know \SpecialChar LaTeX
332  to use \SpecialChar LyX
333  effectively.
334  And \SpecialChar LyX
335  has added its own extensions to \SpecialChar LaTeX
336 .
337  Try the following sometime: select 
338 \begin_inset Flex Noun
339 status collapsed
340
341 \begin_layout Plain Layout
342 Export\SpecialChar menuseparator
343 LaTeX
344 \end_layout
345
346 \end_inset
347
348  from the 
349 \begin_inset Flex Noun
350 status collapsed
351
352 \begin_layout Plain Layout
353 File
354 \end_layout
355
356 \end_inset
357
358  menu (or 
359 \begin_inset Flex Noun
360 status collapsed
361
362 \begin_layout Plain Layout
363 View\SpecialChar menuseparator
364 Source
365 \begin_inset space ~
366 \end_inset
367
368 Pane
369 \end_layout
370
371 \end_inset
372
373 ), then look at the preamble of the resulting 
374 \begin_inset Flex Code
375 status collapsed
376
377 \begin_layout Plain Layout
378 .tex
379 \end_layout
380
381 \end_inset
382
383  file.
384  You'll notice a variety of new macros defined specifically by \SpecialChar LyX
385 .
386  These macros are defined automatically, according to the features you use
387  in the document.
388 \end_layout
389
390 \begin_layout Standard
391 There are several commands that automatically invoke \SpecialChar LaTeX
392 .
393  They are:
394 \end_layout
395
396 \begin_layout Itemize
397 \begin_inset Flex Noun
398 status collapsed
399
400 \begin_layout Plain Layout
401 Document\SpecialChar menuseparator
402 View
403 \end_layout
404
405 \end_inset
406
407
408 \end_layout
409
410 \begin_layout Itemize
411 \begin_inset Flex Noun
412 status collapsed
413
414 \begin_layout Plain Layout
415 Document\SpecialChar menuseparator
416 Update
417 \end_layout
418
419 \end_inset
420
421
422 \end_layout
423
424 \begin_layout Standard
425 They will only invoke \SpecialChar LaTeX
426  if the file has changed since the last time \SpecialChar LaTeX
427  was
428  run.
429  
430 \end_layout
431
432 \begin_layout Standard
433 When \SpecialChar LyX
434  runs \SpecialChar LaTeX
435  on the file you're editing, it performs these steps:
436 \end_layout
437
438 \begin_layout Enumerate
439 Convert the document to \SpecialChar LaTeX
440  and save to a file with the extension 
441 \begin_inset Flex Code
442 status collapsed
443
444 \begin_layout Plain Layout
445 .tex
446 \end_layout
447
448 \end_inset
449
450  in place of 
451 \begin_inset Flex Code
452 status collapsed
453
454 \begin_layout Plain Layout
455 .lyx
456 \end_layout
457
458 \end_inset
459
460 .
461 \end_layout
462
463 \begin_layout Enumerate
464 Run \SpecialChar LaTeX
465  on the 
466 \begin_inset Flex Code
467 status collapsed
468
469 \begin_layout Plain Layout
470 .tex
471 \end_layout
472
473 \end_inset
474
475  file (maybe several times), and run any other commands (such as 
476 \begin_inset Flex Code
477 status collapsed
478
479 \begin_layout Plain Layout
480 bibtex
481 \end_layout
482
483 \end_inset
484
485  or 
486 \begin_inset Flex Code
487 status collapsed
488
489 \begin_layout Plain Layout
490 makeindex
491 \end_layout
492
493 \end_inset
494
495 ) needed to compile the \SpecialChar LaTeX
496  file.
497 \end_layout
498
499 \begin_layout Enumerate
500 If there are any errors, show the error log.
501 \end_layout
502
503 \begin_layout Standard
504 If you have run \SpecialChar LaTeX
505  using 
506 \begin_inset Flex Noun
507 status collapsed
508
509 \begin_layout Plain Layout
510 View\SpecialChar menuseparator
511 DVI
512 \end_layout
513
514 \end_inset
515
516 , \SpecialChar LyX
517  then runs a DVI viewer to display the DVI-file.
518  If you have used 
519 \begin_inset Flex Noun
520 status collapsed
521
522 \begin_layout Plain Layout
523 View\SpecialChar menuseparator
524 PostScript
525 \end_layout
526
527 \end_inset
528
529 , \SpecialChar LyX
530  performs further steps:
531 \end_layout
532
533 \begin_layout Itemize
534 Run 
535 \begin_inset Flex Code
536 status collapsed
537
538 \begin_layout Plain Layout
539 dvips
540 \end_layout
541
542 \end_inset
543
544  to convert the DVI file to PostScript.
545 \end_layout
546
547 \begin_layout Itemize
548 Run a PostScript viewer, such as 
549 \begin_inset Flex Code
550 status collapsed
551
552 \begin_layout Plain Layout
553 ghostview
554 \end_layout
555
556 \end_inset
557
558 , to display the PostScript file.
559 \end_layout
560
561 \begin_layout Standard
562 \SpecialChar LyX
563  does similar things when viewing, or exporting, other formats.
564 \end_layout
565
566 \begin_layout Section
567 Translating \SpecialChar LaTeX
568  files into \SpecialChar LyX
569
570 \end_layout
571
572 \begin_layout Standard
573 You can import a \SpecialChar LaTeX
574  file into \SpecialChar LyX
575  by using the 
576 \begin_inset Flex Noun
577 status collapsed
578
579 \begin_layout Plain Layout
580 File\SpecialChar menuseparator
581 Import\SpecialChar menuseparator
582 LaTeX
583 \end_layout
584
585 \end_inset
586
587  command in \SpecialChar LyX
588 .
589  This will call a program named 
590 \begin_inset Flex Code
591 status collapsed
592
593 \begin_layout Plain Layout
594 tex2lyx
595 \end_layout
596
597 \end_inset
598
599  which will create a file 
600 \begin_inset Flex Code
601 status collapsed
602
603 \begin_layout Plain Layout
604 foo.lyx
605 \end_layout
606
607 \end_inset
608
609  from the file 
610 \begin_inset Flex Code
611 status collapsed
612
613 \begin_layout Plain Layout
614 foo.tex
615 \end_layout
616
617 \end_inset
618
619 .
620  \SpecialChar LyX
621  will then open that file.
622 \begin_inset Foot
623 status collapsed
624
625 \begin_layout Plain Layout
626 \begin_inset Flex Code
627 status collapsed
628
629 \begin_layout Plain Layout
630 tex2lyx
631 \end_layout
632
633 \end_inset
634
635  can also be run from the command line, of course.
636 \end_layout
637
638 \end_inset
639
640
641 \end_layout
642
643 \begin_layout Standard
644 \begin_inset Flex Code
645 status collapsed
646
647 \begin_layout Plain Layout
648 tex2lyx
649 \end_layout
650
651 \end_inset
652
653  will translate most legal \SpecialChar LaTeX
654 , but not everything.
655  It will put things it doesn't understand into \SpecialChar TeX
656  code, so after translating
657  a file with 
658 \begin_inset Flex Code
659 status collapsed
660
661 \begin_layout Plain Layout
662 tex2lyx
663 \end_layout
664
665 \end_inset
666
667 , you can look for \SpecialChar TeX
668  code and hand-edit it until it looks right.
669 \end_layout
670
671 \begin_layout Standard
672 If you don't know what \SpecialChar TeX
673  code is, read the next section.
674 \end_layout
675
676 \begin_layout Section
677 \begin_inset CommandInset label
678 LatexCommand label
679 name "sec:Inserting-TeX-Code"
680
681 \end_inset
682
683 Inserting \SpecialChar TeX
684  Code into \SpecialChar LyX
685  Documents 
686 \end_layout
687
688 \begin_layout Standard
689 Anything you can do in \SpecialChar LaTeX
690  you can do in \SpecialChar LyX
691 , for a very simple reason: You can
692  always insert \SpecialChar TeX
693  code into any \SpecialChar LyX
694  document.
695  \SpecialChar LyX
696  cannot, and will never be able to, display every possible \SpecialChar LaTeX
697  construct.
698  If ever you need to insert \SpecialChar LaTeX
699  commands into your \SpecialChar LyX
700  document, you can use the
701  
702 \begin_inset Flex Code
703 status collapsed
704
705 \begin_layout Plain Layout
706 \SpecialChar TeX
707  Code
708 \end_layout
709
710 \end_inset
711
712  box, which you can insert into your document with 
713 \begin_inset Flex Noun
714 status collapsed
715
716 \begin_layout Plain Layout
717 Insert\SpecialChar menuseparator
718
719 \family sans
720 TeX
721 \family default
722  Code
723 \end_layout
724
725 \end_inset
726
727  or the keyboard shortcut 
728 \begin_inset Info
729 type  "shortcut"
730 arg   "ert-insert"
731 \end_inset
732
733 .
734 \end_layout
735
736 \begin_layout Standard
737 Here's an example of inserting \SpecialChar LaTeX
738  commands in a \SpecialChar LyX
739  document.
740  The code looks like this:
741 \end_layout
742
743 \begin_layout LyX-Code
744
745 \backslash
746 begin{tabular}{ll}
747 \begin_inset Newline newline
748 \end_inset
749
750
751 \backslash
752 begin{minipage}{5cm}
753 \begin_inset Newline newline
754 \end_inset
755
756 This is an example of a minipage environment.
757  You 
758 \begin_inset Newline newline
759 \end_inset
760
761 can put nearly everything in it, even (non-floating) 
762 \begin_inset Newline newline
763 \end_inset
764
765 figures and tables.
766  
767 \begin_inset Newline newline
768 \end_inset
769
770
771 \backslash
772 end{minipage}
773 \begin_inset Newline newline
774 \end_inset
775
776 &
777 \begin_inset Newline newline
778 \end_inset
779
780
781 \backslash
782 begin{minipage}{5cm}
783 \begin_inset Newline newline
784 \end_inset
785
786
787 \backslash
788 begin{verbatim}
789 \begin_inset Newline newline
790 \end_inset
791
792
793 \backslash
794 begin{minipage}{5cm}
795 \begin_inset Newline newline
796 \end_inset
797
798 This ...
799  
800 \begin_inset Newline newline
801 \end_inset
802
803
804 \backslash
805 end{minipage}
806 \begin_inset Newline newline
807 \end_inset
808
809
810 \backslash
811 end{verbatim}
812 \begin_inset Newline newline
813 \end_inset
814
815
816 \backslash
817 end{minipage}
818 \begin_inset Newline newline
819 \end_inset
820
821
822 \backslash
823 end{tabular}
824 \end_layout
825
826 \begin_layout LyX-Code
827
828 \end_layout
829
830 \begin_layout Standard
831 The 
832 \begin_inset Flex Code
833 status collapsed
834
835 \begin_layout Plain Layout
836 \SpecialChar TeX
837  Code
838 \end_layout
839
840 \end_inset
841
842  box containing this text is directly after this paragraph.
843  Those of you reading the manual in \SpecialChar LyX
844  will only see the \SpecialChar TeX
845  code inset.
846  Those reading a printed version of the manuals will see the actual results:
847 \begin_inset VSpace bigskip
848 \end_inset
849
850
851 \end_layout
852
853 \begin_layout Standard
854 \begin_inset ERT
855 status open
856
857 \begin_layout Plain Layout
858
859
860 \backslash
861 begin{tabular}{ll}
862 \end_layout
863
864 \begin_layout Plain Layout
865
866
867 \backslash
868 begin{minipage}{5cm}
869 \end_layout
870
871 \begin_layout Plain Layout
872
873 This is an example of a minipage environment.
874  You can put nearly everything in it, even (non-floating) figures and tables.
875  
876 \end_layout
877
878 \begin_layout Plain Layout
879
880
881 \backslash
882 end{minipage}
883 \end_layout
884
885 \begin_layout Plain Layout
886
887 &
888 \end_layout
889
890 \begin_layout Plain Layout
891
892
893 \backslash
894 begin{minipage}{5cm}
895 \end_layout
896
897 \begin_layout Plain Layout
898
899
900 \backslash
901 begin{verbatim}
902 \end_layout
903
904 \begin_layout Plain Layout
905
906
907 \backslash
908 begin{minipage}{5cm}
909 \end_layout
910
911 \begin_layout Plain Layout
912
913 This ...
914  
915 \end_layout
916
917 \begin_layout Plain Layout
918
919
920 \backslash
921 end{minipage}
922 \end_layout
923
924 \begin_layout Plain Layout
925
926
927 \backslash
928 end{verbatim}
929 \end_layout
930
931 \begin_layout Plain Layout
932
933
934 \backslash
935 end{minipage}
936 \end_layout
937
938 \begin_layout Plain Layout
939
940
941 \backslash
942 end{tabular}
943 \end_layout
944
945 \end_inset
946
947
948 \begin_inset VSpace bigskip
949 \end_inset
950
951
952 \end_layout
953
954 \begin_layout Standard
955 In addition to using \SpecialChar TeX
956  code, you can also create a separate file containing
957  some complex \SpecialChar LaTeX
958  structure and then use 
959 \begin_inset Flex Noun
960 status collapsed
961
962 \begin_layout Plain Layout
963 Insert\SpecialChar menuseparator
964 Child
965 \begin_inset space ~
966 \end_inset
967
968 Document
969 \end_layout
970
971 \end_inset
972
973  to include your file (you should select the type 
974 \begin_inset Flex Code
975 status collapsed
976
977 \begin_layout Plain Layout
978 Input
979 \end_layout
980
981 \end_inset
982
983 ).
984  We recommend that you only do this if you have a 
985 \begin_inset Flex Code
986 status collapsed
987
988 \begin_layout Plain Layout
989 .tex
990 \end_layout
991
992 \end_inset
993
994  file which you 
995 \emph on
996 know
997 \emph default
998  works already.
999  Otherwise, you'll have a big job tracking down \SpecialChar LaTeX
1000  errors.
1001 \end_layout
1002
1003 \begin_layout Standard
1004 There are a few last points to emphasize:
1005 \end_layout
1006
1007 \begin_layout Itemize
1008 \SpecialChar LyX
1009  
1010 \emph on
1011 does not
1012 \emph default
1013  check if your \SpecialChar LaTeX
1014  code is correct.
1015 \end_layout
1016
1017 \begin_layout Itemize
1018 Beware of reinventing the wheel.
1019 \end_layout
1020
1021 \begin_layout Standard
1022 On that last point, \SpecialChar LyX
1023  does have quite a few features tucked into it, and
1024  more are coming.
1025  Be sure to check the manuals to make sure that \SpecialChar LyX
1026  doesn't have such-and-such
1027  feature before you decide you have to do it by hand.
1028  Moreover, there are numerous \SpecialChar LaTeX
1029  packages out there to do all sorts of things,
1030  from labels to envelopes to fancy multipage tables.
1031  Check out 
1032 \begin_inset CommandInset href
1033 LatexCommand href
1034 name "CTAN"
1035 target "http://www.ctan.org/"
1036 literal "false"
1037
1038 \end_inset
1039
1040  for details.
1041 \end_layout
1042
1043 \begin_layout Standard
1044 If you do need to do some wild and fancy things within your document, be
1045  sure to check out a good \SpecialChar LaTeX
1046  book for assistance.
1047  There are a number of them listed in the bibliography of the 
1048 \emph on
1049 User's Guide
1050 \emph default
1051 .
1052 \end_layout
1053
1054 \begin_layout Section
1055 \SpecialChar LyX
1056  and the \SpecialChar LaTeX
1057  Preamble
1058 \end_layout
1059
1060 \begin_layout Subsection
1061 About the \SpecialChar LaTeX
1062  Preamble
1063 \end_layout
1064
1065 \begin_layout Standard
1066 If you already know \SpecialChar LaTeX
1067 , there is no need to explain here what the preamble
1068  is good for.
1069  If you don't, the following will give you some ideas—we recommend again
1070  that you consult a \SpecialChar LaTeX
1071  book for further information.
1072  In any case, you should read the points below, because they explain what
1073  you can do and what you don't need to do in the \SpecialChar LaTeX
1074  preamble of a \SpecialChar LyX
1075  document.
1076 \end_layout
1077
1078 \begin_layout Standard
1079 The \SpecialChar LaTeX
1080  preamble comes at the very beginning of a document, 
1081 \emph on
1082 before
1083 \emph default
1084  the text.
1085  It serves to:
1086 \end_layout
1087
1088 \begin_layout Itemize
1089 Declare the document class.
1090  
1091 \begin_inset Newline newline
1092 \end_inset
1093
1094 \SpecialChar LyX
1095  already does this for you.
1096  If you're a seasoned \SpecialChar LaTeX
1097 -nician, and you have a custom document class you
1098  want to use, check out the 
1099 \emph on
1100 Customization Manual
1101 \emph default
1102  for information on how to make \SpecialChar LyX
1103  interface to it.
1104 \end_layout
1105
1106 \begin_layout Itemize
1107 Declare the usage of packages.
1108  
1109 \begin_inset Newline newline
1110 \end_inset
1111
1112 \SpecialChar LaTeX
1113  packages provide special commands, which are only available within a document
1114  when the package has been declared in the preamble.
1115  In addition to providing special commands, the inclusion of a package can
1116  change the document.
1117  For example, the package 
1118 \begin_inset Flex Code
1119 status collapsed
1120
1121 \begin_layout Plain Layout
1122 indentfirst
1123 \end_layout
1124
1125 \end_inset
1126
1127  forces all paragraphs to be indented.
1128  There are other packages for labels, envelopes, margins, etc.
1129  
1130 \end_layout
1131
1132 \begin_layout Itemize
1133 Set counters, variables, lengths and widths.
1134  
1135 \begin_inset Newline newline
1136 \end_inset
1137
1138 There are several \SpecialChar LaTeX
1139  counters and variables that 
1140 \emph on
1141 must
1142 \emph default
1143  be set globally from within the preamble in order to have the desired effect.
1144  (There are variables that you can set and reset inside the document, too.)
1145  Margins are a good example of something that must be set in the preamble.
1146  Another example is the label format for lists.
1147  You can actually set these just about anywhere, but it's best to do it
1148  just once, inside the preamble.
1149 \end_layout
1150
1151 \begin_layout Itemize
1152 Declare user defined commands (with 
1153 \begin_inset Flex Code
1154 status collapsed
1155
1156 \begin_layout Plain Layout
1157
1158 \backslash
1159 newcommand
1160 \end_layout
1161
1162 \end_inset
1163
1164  or 
1165 \begin_inset Flex Code
1166 status collapsed
1167
1168 \begin_layout Plain Layout
1169
1170 \backslash
1171 renewcommand
1172 \end_layout
1173
1174 \end_inset
1175
1176 ).
1177 \begin_inset Newline newline
1178 \end_inset
1179
1180 These are abbreviations for \SpecialChar LaTeX
1181  commands which appear very often inside a document.
1182  Although the preamble is a good place to declare such commands, they 
1183 \emph on
1184 can
1185 \emph default
1186  be declared anywhere (before they are used for the first time, of course).
1187  This can be useful if there is a lot of raw \SpecialChar LaTeX
1188  code in your document, which
1189  normally should not be the case.
1190 \end_layout
1191
1192 \begin_layout Standard
1193 \SpecialChar LyX
1194  adds its own set of definitions to the preamble of the 
1195 \begin_inset Flex Code
1196 status collapsed
1197
1198 \begin_layout Plain Layout
1199 .tex
1200 \end_layout
1201
1202 \end_inset
1203
1204  file it produces.
1205  This makes \SpecialChar LaTeX
1206  files generated by \SpecialChar LyX
1207  portable.
1208 \end_layout
1209
1210 \begin_layout Subsection
1211 Changing the Preamble
1212 \end_layout
1213
1214 \begin_layout Standard
1215 The commands which \SpecialChar LyX
1216  adds to the preamble of a \SpecialChar LaTeX
1217  file are fixed; you can't
1218  change them without patching \SpecialChar LyX
1219  itself.
1220  You can, however, add your own stuff to the preamble by selecting 
1221 \begin_inset Flex Noun
1222 status collapsed
1223
1224 \begin_layout Plain Layout
1225 \SpecialChar LaTeX
1226
1227 \begin_inset space ~
1228 \end_inset
1229
1230 Preamble
1231 \end_layout
1232
1233 \end_inset
1234
1235  in the 
1236 \begin_inset Flex Noun
1237 status collapsed
1238
1239 \begin_layout Plain Layout
1240 Document\SpecialChar menuseparator
1241 Settings
1242 \end_layout
1243
1244 \end_inset
1245
1246  dialog.
1247  \SpecialChar LyX
1248  adds anything in the 
1249 \begin_inset Flex Noun
1250 status collapsed
1251
1252 \begin_layout Plain Layout
1253 Preamble
1254 \end_layout
1255
1256 \end_inset
1257
1258  dialog to its own built-in preamble.
1259  Before adding your own declarations in the preamble, you should make sure
1260  that \SpecialChar LyX
1261  doesn't already support what you want to do.
1262  (Remember what we said about reinventing the wheel?) Also, 
1263 \emph on
1264 make sure your preamble code is correct
1265 \emph default
1266 .
1267  \SpecialChar LyX
1268  doesn't check it for you.
1269  If there is an error, you're likely to get an error like 
1270 \begin_inset Quotes eld
1271 \end_inset
1272
1273
1274 \begin_inset Flex Code
1275 status collapsed
1276
1277 \begin_layout Plain Layout
1278 Missing 
1279 \backslash
1280 begin{document}
1281 \end_layout
1282
1283 \end_inset
1284
1285
1286 \begin_inset Quotes erd
1287 \end_inset
1288
1289 .
1290  If you see this error, check your preamble.
1291 \end_layout
1292
1293 \begin_layout Subsection
1294 Examples
1295 \end_layout
1296
1297 \begin_layout Standard
1298 Here are some examples of what you can add to a preamble, and what they
1299  do.
1300 \end_layout
1301
1302 \begin_layout Subsubsection
1303 Example #1: Offsets
1304 \end_layout
1305
1306 \begin_layout Standard
1307 There are two variables under \SpecialChar LaTeX
1308  that control page position: 
1309 \begin_inset Flex Code
1310 status collapsed
1311
1312 \begin_layout Plain Layout
1313
1314 \backslash
1315 hoffset
1316 \end_layout
1317
1318 \end_inset
1319
1320  and 
1321 \begin_inset Flex Code
1322 status collapsed
1323
1324 \begin_layout Plain Layout
1325
1326 \backslash
1327 voffset
1328 \end_layout
1329
1330 \end_inset
1331
1332 .
1333  Their names should be self-explanatory.
1334  These variables are useful if you think for a moment about computer labels.
1335  Sometimes, the size of a print medium and the area of the medium that you
1336  can actually print on aren't the same.
1337  This is where 
1338 \begin_inset Flex Code
1339 status collapsed
1340
1341 \begin_layout Plain Layout
1342
1343 \backslash
1344 hoffset
1345 \end_layout
1346
1347 \end_inset
1348
1349  and 
1350 \begin_inset Flex Code
1351 status collapsed
1352
1353 \begin_layout Plain Layout
1354
1355 \backslash
1356 voffset
1357 \end_layout
1358
1359 \end_inset
1360
1361  come in.
1362 \end_layout
1363
1364 \begin_layout Standard
1365 The default values for 
1366 \begin_inset Flex Code
1367 status collapsed
1368
1369 \begin_layout Plain Layout
1370
1371 \backslash
1372 hoffset
1373 \end_layout
1374
1375 \end_inset
1376
1377  and 
1378 \begin_inset Flex Code
1379 status collapsed
1380
1381 \begin_layout Plain Layout
1382
1383 \backslash
1384 voffset
1385 \end_layout
1386
1387 \end_inset
1388
1389  are both 0
1390 \begin_inset space \thinspace{}
1391 \end_inset
1392
1393 points, i.
1394 \begin_inset space \thinspace{}
1395 \end_inset
1396
1397 e.
1398 \begin_inset space \space{}
1399 \end_inset
1400
1401 the page isn't shifted.
1402  Unfortunately, some DVI drivers always seem to shift the page.
1403  We have no idea why, or why the sysadmin hasn't fixed such behavior.
1404  If you're using \SpecialChar LyX
1405  on a system that you don't personally maintain, and your
1406  sysadmin is a doofus, 
1407 \begin_inset Flex Code
1408 status collapsed
1409
1410 \begin_layout Plain Layout
1411
1412 \backslash
1413 hoffset
1414 \end_layout
1415
1416 \end_inset
1417
1418  and 
1419 \begin_inset Flex Code
1420 status collapsed
1421
1422 \begin_layout Plain Layout
1423
1424 \backslash
1425 voffset
1426 \end_layout
1427
1428 \end_inset
1429
1430  can save the day.
1431  Suppose your left and top margins are always 0.5
1432 \begin_inset space \thinspace{}
1433 \end_inset
1434
1435 inches too big.
1436  You can add this to the preamble:
1437 \end_layout
1438
1439 \begin_layout LyX-Code
1440
1441 \backslash
1442 setlength{
1443 \backslash
1444 hoffset}{-0.5 in}
1445 \end_layout
1446
1447 \begin_layout LyX-Code
1448
1449 \backslash
1450 setlength{
1451 \backslash
1452 voffset}{-0.5 in}
1453 \end_layout
1454
1455 \begin_layout Standard
1456 and your margins should now be correct.
1457 \end_layout
1458
1459 \begin_layout Subsubsection
1460 Example #2: Labels
1461 \end_layout
1462
1463 \begin_layout Standard
1464 Speaking of labels, suppose you wanted to print out a bunch of address labels.
1465  There's a rather nice package, available at your nearest CTAN archive,
1466  for printing sheets of labels: 
1467 \begin_inset Flex Code
1468 status collapsed
1469
1470 \begin_layout Plain Layout
1471 labels.sty
1472 \end_layout
1473
1474 \end_inset
1475
1476 .
1477  Now, your system may not have this package installed by default.
1478  We leave that up to you to check.
1479  You'll also want to read the documentation for it; we're not going to do
1480  that for you.
1481  Since this is an example, however, we'll give you an example of how you
1482  use this package.
1483 \end_layout
1484
1485 \begin_layout Standard
1486 First, make sure you're using the 
1487 \begin_inset Flex Code
1488 status collapsed
1489
1490 \begin_layout Plain Layout
1491 article
1492 \end_layout
1493
1494 \end_inset
1495
1496  document class.
1497  Next, you need to put the following in your preamble:
1498 \end_layout
1499
1500 \begin_layout LyX-Code
1501
1502 \backslash
1503 usepackage{labels}
1504 \end_layout
1505
1506 \begin_layout LyX-Code
1507
1508 \backslash
1509 LabelCols=3
1510 \end_layout
1511
1512 \begin_layout LyX-Code
1513
1514 \backslash
1515 LabelRows=7
1516 \end_layout
1517
1518 \begin_layout LyX-Code
1519
1520 \backslash
1521 LeftBorder=8mm
1522 \end_layout
1523
1524 \begin_layout LyX-Code
1525
1526 \backslash
1527 RightBorder=8mm
1528 \end_layout
1529
1530 \begin_layout LyX-Code
1531
1532 \backslash
1533 TopBorder=9mm
1534 \end_layout
1535
1536 \begin_layout LyX-Code
1537
1538 \backslash
1539 BottomBorder=2mm
1540 \end_layout
1541
1542 \begin_layout Standard
1543 This sets things up for Avery label sheets, stock #5360.
1544  You're now ready to print labels, but you'll need to insert \SpecialChar LaTeX
1545  code, placing
1546  the commands 
1547 \begin_inset Flex Code
1548 status collapsed
1549
1550 \begin_layout Plain Layout
1551
1552 \backslash
1553 begin{labels}
1554 \end_layout
1555
1556 \end_inset
1557
1558  and 
1559 \begin_inset Flex Code
1560 status collapsed
1561
1562 \begin_layout Plain Layout
1563
1564 \backslash
1565 end{labels}
1566 \end_layout
1567
1568 \end_inset
1569
1570  around each label text.
1571  This and other special features of 
1572 \begin_inset Flex Code
1573 status collapsed
1574
1575 \begin_layout Plain Layout
1576 labels.sty
1577 \end_layout
1578
1579 \end_inset
1580
1581  are explained in its documentation.
1582 \end_layout
1583
1584 \begin_layout Standard
1585 Someday, someone may write a \SpecialChar LyX
1586  layout file to support this package directly.
1587  Maybe that someone is you.
1588 \end_layout
1589
1590 \begin_layout Subsubsection
1591 Example #3: Paragraph Indentation
1592 \end_layout
1593
1594 \begin_layout Standard
1595 Americans are trained to indent the first line of 
1596 \emph on
1597 every
1598 \emph default
1599  paragraph.
1600  As with all of their other weird quirks, most Americans will whine and
1601  moan until they can have their way and indent the first line of all paragraphs.
1602  (Yes, we're joking.
1603  (We are?) 
1604 \emph on
1605 Yeah
1606 \emph default
1607 , we are.)
1608 \end_layout
1609
1610 \begin_layout Standard
1611 Of course, this behavior isn't standard typography.
1612  In books, you typically only indent the first line of a paragraph 
1613 \emph on
1614 if
1615 \emph default
1616  it follows another one.
1617  The idea behind indenting the first line of a paragraph is to distinguish
1618  neighboring paragraphs from one another.
1619  If there is no previous paragraph—for example, if it follows a figure or
1620  is the first paragraph in a section—then there is no need for indentation.
1621  
1622 \end_layout
1623
1624 \begin_layout Standard
1625 If you're a typical American (we're still joking!), though, you don't care
1626  about such esoteric things; you want your indentation! Add this to the
1627  preamble:
1628 \end_layout
1629
1630 \begin_layout LyX-Code
1631
1632 \backslash
1633 usepackage{indentfirst}
1634 \end_layout
1635
1636 \begin_layout Standard
1637 If your \SpecialChar TeX
1638  distribution isn't braindead, you'll have this package, and all
1639  of your paragraphs will get the indentation the Founding Fathers intended
1640  they should have.
1641 \end_layout
1642
1643 \begin_layout Subsubsection
1644 Example #4: This Document
1645 \end_layout
1646
1647 \begin_layout Standard
1648 You can also check out the preamble of this document to get an idea of some
1649  of the advanced things you can do.
1650 \end_layout
1651
1652 \begin_layout Section
1653 \SpecialChar LyX
1654  and \SpecialChar LaTeX
1655  Errors
1656 \end_layout
1657
1658 \begin_layout Standard
1659 When \SpecialChar LyX
1660  calls \SpecialChar LaTeX
1661 , it tells \SpecialChar LaTeX
1662  to blithely ignore any errors and keep going.
1663  It then uses the logfile from the \SpecialChar LaTeX
1664  run to do a post-mortem.
1665  After analyzing the logfile, \SpecialChar LyX
1666  displays a dialog listing the errors.
1667  Clicking on any one of them will take you to the position in your \SpecialChar LyX
1668  file
1669  where the error occurred.
1670 \begin_inset Foot
1671 status collapsed
1672
1673 \begin_layout Plain Layout
1674 Well, usually.
1675  Analyzing the logfile is a tough job, and \SpecialChar LyX
1676  doesn't always go to the right
1677  line.
1678  There are also cases where \SpecialChar LaTeX
1679  reports the error on one line, but the actual
1680  error is earlier.
1681  This is not unlike forgetting a closing brace in a program: You'll get
1682  an error, but only later.
1683 \end_layout
1684
1685 \end_inset
1686
1687
1688 \end_layout
1689
1690 \begin_layout Standard
1691 Some folks also like to look at the log file directly: It is available from
1692  
1693 \begin_inset Flex Noun
1694 status collapsed
1695
1696 \begin_layout Plain Layout
1697 Document\SpecialChar menuseparator
1698 LaTeX
1699 \begin_inset space ~
1700 \end_inset
1701
1702 Log
1703 \end_layout
1704
1705 \end_inset
1706
1707 .
1708  There are some fairly common error messages and warnings.
1709  We'll cover those here.
1710  You should look at a good \SpecialChar LaTeX
1711  book for a complete listing.
1712 \end_layout
1713
1714 \begin_layout Itemize
1715 \begin_inset Flex Code
1716 status collapsed
1717
1718 \begin_layout Plain Layout
1719 LaTeX Warning
1720 \end_layout
1721
1722 \end_inset
1723
1724
1725 \begin_inset Newline newline
1726 \end_inset
1727
1728 Anything beginning with these words is a warning message for the purpose
1729  of 
1730 \begin_inset Quotes eld
1731 \end_inset
1732
1733 debugging
1734 \begin_inset Quotes erd
1735 \end_inset
1736
1737  the \SpecialChar LaTeX
1738  code itself.
1739  You'll get messages like this if you added or changed cross-references
1740  or bibliography entries, in which case, \SpecialChar LaTeX
1741  is trying to tell you that you
1742  need to make another run.
1743  You can by-and-large ignore these.
1744 \end_layout
1745
1746 \begin_layout Itemize
1747 \begin_inset Flex Code
1748 status collapsed
1749
1750 \begin_layout Plain Layout
1751 LaTeX Font Warning
1752 \end_layout
1753
1754 \end_inset
1755
1756
1757 \begin_inset Newline newline
1758 \end_inset
1759
1760 Another warning message, this time about fonts which \SpecialChar LaTeX
1761  couldn't find.
1762  The rest of the message will often say something about a replacement font
1763  that \SpecialChar LaTeX
1764  used.
1765  You can safely ignore these, too.
1766 \end_layout
1767
1768 \begin_layout Itemize
1769 \begin_inset Flex Code
1770 status collapsed
1771
1772 \begin_layout Plain Layout
1773 Overfull 
1774 \backslash
1775 hbox
1776 \end_layout
1777
1778 \end_inset
1779
1780
1781 \begin_inset Newline newline
1782 \end_inset
1783
1784 \SpecialChar LaTeX
1785  absolutely 
1786 \emph on
1787 loves
1788 \emph default
1789  to spew these out.
1790  It seems to generate at least one of these messages for just about any
1791  document you write.
1792  They are warnings about lines that were too long and run past the right
1793  margin.
1794  This happens if \SpecialChar LaTeX
1795  does not find a reasonable way to break the lines (notoriously
1796  often with typewriter font, since this does not allow for automatic break
1797  points).
1798  In many cases, this is unnoticeable in the final output.
1799  (It can be just a point or two.) Sometimes, however, the lines run rather
1800  visibly into the margin; something you will not want to have in your final
1801  print.
1802  
1803 \begin_inset Newline newline
1804 \end_inset
1805
1806 There are several global ways to try to minimize the overfull lines.
1807  Clicking 
1808 \family sans
1809 Enable micro-typographic extensions
1810 \family default
1811  in 
1812 \family sans
1813 Document\SpecialChar menuseparator
1814 Settings\SpecialChar menuseparator
1815 Fonts
1816 \family default
1817  might already improve things a lot.
1818  Furthermore, \SpecialChar LaTeX
1819  code such as the following in 
1820 \family sans
1821 Document\SpecialChar menuseparator
1822 Settings\SpecialChar menuseparator
1823 Preamble
1824 \family default
1825  usually reduces the overfull lines drastically (we use this in the preamble
1826  of this document):
1827 \end_layout
1828
1829 \begin_deeper
1830 \begin_layout LyX-Code
1831
1832 \backslash
1833 tolerance 1414
1834 \begin_inset Newline newline
1835 \end_inset
1836
1837
1838 \backslash
1839 hbadness 1414
1840 \begin_inset Newline newline
1841 \end_inset
1842
1843
1844 \backslash
1845 emergencystretch 1.5em
1846 \begin_inset Newline newline
1847 \end_inset
1848
1849
1850 \backslash
1851 hfuzz 0.3pt
1852 \end_layout
1853
1854 \begin_layout Standard
1855 In some cases, however, you eventually have to rewrite the text to get the
1856  line breaking right.
1857 \begin_inset Foot
1858 status collapsed
1859
1860 \begin_layout Plain Layout
1861 For more information, see 
1862 \begin_inset Flex URL
1863 status open
1864
1865 \begin_layout Plain Layout
1866
1867 http://www.tex.ac.uk/FAQ-overfull.html
1868 \end_layout
1869
1870 \end_inset
1871
1872
1873 \end_layout
1874
1875 \end_inset
1876
1877
1878 \end_layout
1879
1880 \begin_layout Standard
1881 In any case, you should check the respective lines, at least for the final
1882  version of your document.
1883  Your eyes will tell you if there's a problem with something that's too
1884  wide.
1885 \begin_inset Foot
1886 status collapsed
1887
1888 \begin_layout Plain Layout
1889 You can also enable the `draft' option in 
1890 \begin_inset Flex Noun
1891 status collapsed
1892
1893 \begin_layout Plain Layout
1894 Document\SpecialChar menuseparator
1895 Settings
1896 \end_layout
1897
1898 \end_inset
1899
1900 , and then \SpecialChar LaTeX
1901  will draw a black box in the margin of lines that are overfull.
1902 \end_layout
1903
1904 \end_inset
1905
1906  
1907 \end_layout
1908
1909 \end_deeper
1910 \begin_layout Itemize
1911 \begin_inset Flex Code
1912 status collapsed
1913
1914 \begin_layout Plain Layout
1915 Underfull 
1916 \backslash
1917 hbox
1918 \end_layout
1919
1920 \end_inset
1921
1922
1923 \begin_inset Newline newline
1924 \end_inset
1925
1926 Not quite as common as its cousin.
1927  This happens again if \SpecialChar LaTeX
1928  does not find a reasonable break point and consequently
1929  generates too loose lines.
1930  As with the overfull lines, you should check if this is a visible problem.
1931 \end_layout
1932
1933 \begin_layout Itemize
1934 \begin_inset Flex Code
1935 status collapsed
1936
1937 \begin_layout Plain Layout
1938 Overfull 
1939 \backslash
1940 vbox
1941 \end_layout
1942
1943 \end_inset
1944
1945  and 
1946 \begin_inset Flex Code
1947 status collapsed
1948
1949 \begin_layout Plain Layout
1950 Underfull 
1951 \backslash
1952 vbox
1953 \end_layout
1954
1955 \end_inset
1956
1957
1958 \begin_inset Newline newline
1959 \end_inset
1960
1961 Warnings about troubles breaking the page.
1962  Once again, just look at the output.
1963  Your eyes will tell you where something has gone wrong.
1964 \end_layout
1965
1966 \begin_layout Itemize
1967 \begin_inset Flex Code
1968 status collapsed
1969
1970 \begin_layout Plain Layout
1971 LaTeX Error: File 
1972 \begin_inset Quotes els
1973 \end_inset
1974
1975 Xxxx
1976 \begin_inset Quotes ers
1977 \end_inset
1978
1979  not found
1980 \end_layout
1981
1982 \end_inset
1983
1984
1985 \begin_inset Newline newline
1986 \end_inset
1987
1988 The file 
1989 \begin_inset Quotes eld
1990 \end_inset
1991
1992 Xxxx
1993 \begin_inset Quotes erd
1994 \end_inset
1995
1996  isn't installed on this system.
1997  This usually appears because some package your document needs isn't installed.
1998  If you didn't touch the preamble or didn't use the 
1999 \begin_inset Flex Code
2000 status collapsed
2001
2002 \begin_layout Plain Layout
2003
2004 \backslash
2005 usepackage{}
2006 \end_layout
2007
2008 \end_inset
2009
2010  command, then one of the packages \SpecialChar LyX
2011  tried to load is missing.
2012  Use 
2013 \begin_inset Flex Noun
2014 status collapsed
2015
2016 \begin_layout Plain Layout
2017 Help\SpecialChar menuseparator
2018 \SpecialChar LaTeX
2019  Configuration
2020 \end_layout
2021
2022 \end_inset
2023
2024  to get a list of packages that \SpecialChar LyX
2025  knows about.
2026  This file is updated whenever you reconfigure \SpecialChar LyX
2027  (using 
2028 \begin_inset Flex Noun
2029 status collapsed
2030
2031 \begin_layout Plain Layout
2032 Tools\SpecialChar menuseparator
2033 Reconfigure
2034 \end_layout
2035
2036 \end_inset
2037
2038 ) and tells you which packages have been detected and what they do.
2039 \begin_inset Newline newline
2040 \end_inset
2041
2042 If you did use the 
2043 \begin_inset Flex Code
2044 status collapsed
2045
2046 \begin_layout Plain Layout
2047
2048 \backslash
2049 usepackage{}
2050 \end_layout
2051
2052 \end_inset
2053
2054  command and the package in question isn't installed, then you'll need to
2055  install it yourself.
2056 \end_layout
2057
2058 \begin_layout Itemize
2059 \begin_inset Flex Code
2060 status collapsed
2061
2062 \begin_layout Plain Layout
2063 LaTeX Error: Unknown option
2064 \end_layout
2065
2066 \end_inset
2067
2068
2069 \begin_inset Newline newline
2070 \end_inset
2071
2072 Error messages beginning with this are trying to tell you that you specified
2073  a bad or undefined option to a package.
2074  Check the package's documentation.
2075 \end_layout
2076
2077 \begin_layout Itemize
2078 \begin_inset Flex Code
2079 status collapsed
2080
2081 \begin_layout Plain Layout
2082 Undefined control sequence
2083 \end_layout
2084
2085 \end_inset
2086
2087
2088 \begin_inset Newline newline
2089 \end_inset
2090
2091 If you've inserted \SpecialChar LaTeX
2092  code into your document, but made a typo, you'll get
2093  one of these.
2094  You may have forgotten to load a package.
2095  In any case, this error message usually means that you used an undefined
2096  command.
2097  
2098 \end_layout
2099
2100 \begin_layout Standard
2101 There are other error and warning messages.
2102  Some are self-explanatory.
2103  These are usually \SpecialChar LaTeX
2104  messages.
2105  Others are downright cryptic.
2106  These are usually \SpecialChar TeX
2107  error messages, and we really have 
2108 \emph on
2109 no clue
2110 \emph default
2111  what they mean or how to decipher them.
2112  No-one does.
2113 \end_layout
2114
2115 \begin_layout Standard
2116 There's a general sequence you should follow if you get error messages:
2117 \end_layout
2118
2119 \begin_layout Enumerate
2120 Look at the \SpecialChar LaTeX
2121  code you inserted for typos.
2122 \end_layout
2123
2124 \begin_layout Enumerate
2125 If there are no typos, check that you used the command(s) correctly.
2126 \end_layout
2127
2128 \begin_layout Enumerate
2129 If you get a bunch of error boxes piled up at the very top of the document—and
2130  especially if you see a 
2131 \begin_inset Quotes eld
2132 \end_inset
2133
2134
2135 \begin_inset Flex Code
2136 status collapsed
2137
2138 \begin_layout Plain Layout
2139 Missing 
2140 \backslash
2141 begin{document}
2142 \end_layout
2143
2144 \end_inset
2145
2146
2147 \begin_inset Quotes erd
2148 \end_inset
2149
2150  error—it means that there are errors in the preamble.
2151  Start debugging your preamble.
2152 \end_layout
2153
2154 \begin_layout Enumerate
2155 If you didn't add anything to the preamble and didn't add any \SpecialChar LaTeX
2156  code to the
2157  document, the first suspect is your \SpecialChar LaTeX
2158  distribution itself.
2159  Check for missing packages and install them.
2160 \end_layout
2161
2162 \begin_layout Enumerate
2163 Okay, so there are no missing packages.
2164  Did you use any of the fine-tuning options in \SpecialChar LyX
2165 ? Specifically, did you 
2166 \emph on
2167 misuse
2168 \emph default
2169  any of them, like trying to manually insert lots of 
2170 \begin_inset Flex Code
2171 status collapsed
2172
2173 \begin_layout Plain Layout
2174 Protected
2175 \begin_inset space ~
2176 \end_inset
2177
2178 Blanks
2179 \end_layout
2180
2181 \end_inset
2182
2183
2184 \begin_inset Flex Code
2185 status collapsed
2186
2187 \begin_layout Plain Layout
2188 Linebreaks
2189 \end_layout
2190
2191 \end_inset
2192
2193 , or 
2194 \begin_inset Flex Code
2195 status collapsed
2196
2197 \begin_layout Plain Layout
2198 Pagebreaks
2199 \end_layout
2200
2201 \end_inset
2202
2203 ? Did you try to kludge something together with these instead of using the
2204  appropriate paragraph environment?
2205 \end_layout
2206
2207 \begin_layout Enumerate
2208 All right, you didn't use any of the fine-tuning options, you played by
2209  the rules.
2210  Did you try to pull a fancy maneuver? Did you do something funky inside
2211  a table or an equation, like inserting a graphic into a table cell?
2212 \end_layout
2213
2214 \begin_layout Enumerate
2215 Do you have long sections of text where \SpecialChar LaTeX
2216  cannot find a place to break a
2217  line? By default, \SpecialChar LaTeX
2218  is rather strict about how much extra inter-word spacing
2219  it will add in order to break a line.
2220  Preferably, you should rework the paragraph to avoid the problem.
2221 \end_layout
2222
2223 \begin_layout Enumerate
2224 Did you go overboard with the nesting? \SpecialChar LyX
2225  (currently) doesn't check to make
2226  sure you're in the limits for nesting environments.
2227  If you nested a bunch of environments to the 
2228 \begin_inset Formula $17^{\mathrm{th}}$
2229 \end_inset
2230
2231  level, that's the problem.
2232  (The limit in \SpecialChar LaTeX
2233  is five.)
2234 \end_layout
2235
2236 \begin_layout Enumerate
2237 Okay, you didn't get any error messages, but your output looks awful.
2238  If you have a table or figure that's too wide or long for the page, you
2239  need to:
2240 \end_layout
2241
2242 \begin_deeper
2243 \begin_layout Enumerate
2244 rescale the figure so it fits.
2245 \end_layout
2246
2247 \begin_layout Enumerate
2248 trim down the table so it fits.
2249 \end_layout
2250
2251 \end_deeper
2252 \begin_layout Enumerate
2253 If something else is wrong with the output, and you didn't try to pull anything
2254  fancy or kludge the fine-tuning options, we're not sure what's wrong.
2255 \end_layout
2256
2257 \begin_layout Standard
2258 If all this doesn't help—well, then 
2259 \emph on
2260 perhaps
2261 \emph default
2262  you might have found a bug in \SpecialChar LyX
2263 \SpecialChar ldots
2264 .
2265 \end_layout
2266
2267 \begin_layout Chapter
2268 Supplemental Tools
2269 \end_layout
2270
2271 \begin_layout Section
2272 Customizing Bibliographies with Bib\SpecialChar TeX
2273  or Biblatex
2274 \end_layout
2275
2276 \begin_layout Standard
2277 The most basic information about how to use Bib\SpecialChar TeX
2278  or 
2279 \family sans
2280 Biblatex
2281 \family default
2282  with \SpecialChar LyX
2283  is contained in the section 
2284 \emph on
2285 Bibliography databases
2286 \emph default
2287  of the 
2288 \emph on
2289 User's Guide
2290 \emph default
2291 .
2292  The following subsections explain special bibliography features supported
2293  by \SpecialChar LyX
2294 .
2295 \end_layout
2296
2297 \begin_layout Subsection
2298 Alternative Citation Styles
2299 \end_layout
2300
2301 \begin_layout Standard
2302 Standard Bib\SpecialChar TeX
2303  uses numbers (e.
2304 \begin_inset space \thinspace{}
2305 \end_inset
2306
2307 g.
2308 \begin_inset space \space{}
2309 \end_inset
2310
2311
2312 \begin_inset Quotes eld
2313 \end_inset
2314
2315 [12]
2316 \begin_inset Quotes erd
2317 \end_inset
2318
2319 ) to refer to a cited work.
2320  However, in many scientific disciplines, other citation styles are in use.
2321  The most common one is the author-year style (e.
2322 \begin_inset space \thinspace{}
2323 \end_inset
2324
2325 g.
2326 \begin_inset space \space{}
2327 \end_inset
2328
2329
2330 \begin_inset Quotes eld
2331 \end_inset
2332
2333 Knuth 1984a
2334 \begin_inset Quotes erd
2335 \end_inset
2336
2337 ).
2338  \SpecialChar LyX
2339  supports three packages that provide this style, 
2340 \begin_inset Flex Code
2341 status collapsed
2342
2343 \begin_layout Plain Layout
2344 biblatex
2345 \end_layout
2346
2347 \end_inset
2348
2349
2350 \begin_inset Flex Code
2351 status collapsed
2352
2353 \begin_layout Plain Layout
2354 natbib
2355 \end_layout
2356
2357 \end_inset
2358
2359 , and 
2360 \begin_inset Flex Code
2361 status collapsed
2362
2363 \begin_layout Plain Layout
2364 jurabib
2365 \end_layout
2366
2367 \end_inset
2368
2369 .
2370  Each of these packages has their pros and cons, which cannot be listed
2371  in detail.
2372  If you only want to have simple author-year (or author-numerical) style,
2373  or if you want to use one of the countless style files for 
2374 \begin_inset Flex Code
2375 status collapsed
2376
2377 \begin_layout Plain Layout
2378 natbib
2379 \end_layout
2380
2381 \end_inset
2382
2383 , then the established 
2384 \begin_inset Flex Code
2385 status collapsed
2386
2387 \begin_layout Plain Layout
2388 natbib
2389 \end_layout
2390
2391 \end_inset
2392
2393  package is probably your choice.
2394  If you look for specific citation styles common in law studies, you might
2395  consider the 
2396 \begin_inset Flex Code
2397 status collapsed
2398
2399 \begin_layout Plain Layout
2400 jurabib
2401 \end_layout
2402
2403 \end_inset
2404
2405  package.
2406  If you want to have full control over the formatting or look for advanced
2407  features such as ibidem, footnote citations, full title citations, advanced
2408  date formats (such as 400 BC) or full localization to other languages than
2409  English, you should definitely consider 
2410 \begin_inset Flex Code
2411 status collapsed
2412
2413 \begin_layout Plain Layout
2414 biblatex
2415 \end_layout
2416
2417 \end_inset
2418
2419 , which exceeds all other packages in terms of features, but is also quite
2420  heavy and more resource-hungry.
2421 \end_layout
2422
2423 \begin_layout Standard
2424 The handling of these packages in \SpecialChar LyX
2425  is basically the same.
2426  Go to 
2427 \begin_inset Flex Noun
2428 status collapsed
2429
2430 \begin_layout Plain Layout
2431 Document\SpecialChar menuseparator
2432 Settings
2433 \end_layout
2434
2435 \end_inset
2436
2437  and select under 
2438 \begin_inset Flex Noun
2439 status collapsed
2440
2441 \begin_layout Plain Layout
2442 Bibliography
2443 \end_layout
2444
2445 \end_inset
2446
2447  the 
2448 \begin_inset Flex Noun
2449 status collapsed
2450
2451 \begin_layout Plain Layout
2452 Style Format
2453 \end_layout
2454
2455 \end_inset
2456
2457  
2458 \begin_inset Flex Noun
2459 status collapsed
2460
2461 \begin_layout Plain Layout
2462 Basic (BibTeX)
2463 \end_layout
2464
2465 \end_inset
2466
2467
2468 \begin_inset Flex Noun
2469 status collapsed
2470
2471 \begin_layout Plain Layout
2472 Biblatex
2473 \end_layout
2474
2475 \end_inset
2476
2477
2478 \begin_inset Flex Noun
2479 status collapsed
2480
2481 \begin_layout Plain Layout
2482 Biblatex (Natbib mode)
2483 \end_layout
2484
2485 \end_inset
2486
2487
2488 \begin_inset Flex Noun
2489 status collapsed
2490
2491 \begin_layout Plain Layout
2492 Natbib (BibTeX)
2493 \end_layout
2494
2495 \end_inset
2496
2497  or 
2498 \begin_inset Flex Noun
2499 status collapsed
2500
2501 \begin_layout Plain Layout
2502 Jurabib (BibTeX)
2503 \end_layout
2504
2505 \end_inset
2506
2507  (see sec.
2508 \begin_inset space ~
2509 \end_inset
2510
2511 6.5.3 in the User's Guide for more information on these choices).
2512  With all these packages, you will get some extra features in the citation
2513  dialog and you can select the style of the reference (
2514 \begin_inset Quotes eld
2515 \end_inset
2516
2517 Knuth 1984
2518 \begin_inset Quotes erd
2519 \end_inset
2520
2521
2522 \begin_inset Quotes eld
2523 \end_inset
2524
2525 Knuth (1984)
2526 \begin_inset Quotes erd
2527 \end_inset
2528
2529
2530 \begin_inset Quotes eld
2531 \end_inset
2532
2533 Knuth, 1984
2534 \begin_inset Quotes erd
2535 \end_inset
2536
2537
2538 \begin_inset Quotes eld
2539 \end_inset
2540
2541 1984
2542 \begin_inset Quotes erd
2543 \end_inset
2544
2545  etc.).
2546  Note that either package needs specifically designed style files.
2547  They all ship their own, but there are lots of additional style files,
2548  and there is even an interactive style file builder
2549 \begin_inset Foot
2550 status collapsed
2551
2552 \begin_layout Plain Layout
2553 See 
2554 \begin_inset Flex URL
2555 status open
2556
2557 \begin_layout Plain Layout
2558
2559 ftp://ctan.tug.org/tex-archive/macros/latex/contrib/custom-bib/
2560 \end_layout
2561
2562 \end_inset
2563
2564
2565 \end_layout
2566
2567 \end_inset
2568
2569  for 
2570 \begin_inset Flex Code
2571 status collapsed
2572
2573 \begin_layout Plain Layout
2574 natbib
2575 \end_layout
2576
2577 \end_inset
2578
2579 .
2580 \end_layout
2581
2582 \begin_layout Subsection
2583 Subdivided Bibliographies
2584 \end_layout
2585
2586 \begin_layout Standard
2587 Sometimes you might need to divide your bibliography into several sections.
2588  If you are for instance a historian, the possibility to separate sources
2589  and scientific works is most likely a 
2590 \begin_inset Quotes eld
2591 \end_inset
2592
2593 must have
2594 \begin_inset Quotes erd
2595 \end_inset
2596
2597 .
2598  Unfortunately, Bib\SpecialChar TeX
2599  itself does not allow you to do this.
2600  But with the help of some \SpecialChar LaTeX
2601  packages, Bib\SpecialChar TeX
2602  can be extended to fit your needs.
2603 \end_layout
2604
2605 \begin_layout Standard
2606 \SpecialChar LyX
2607  provides native support for one of these packages, 
2608 \family typewriter
2609 bibtopic
2610 \family default
2611 .
2612 \begin_inset Foot
2613 status collapsed
2614
2615 \begin_layout Plain Layout
2616 Available from 
2617 \begin_inset Flex URL
2618 status open
2619
2620 \begin_layout Plain Layout
2621
2622 ftp://ctan.tug.org/tex-archive/macros/latex/contrib/bibtopic/
2623 \end_layout
2624
2625 \end_inset
2626
2627
2628 \end_layout
2629
2630 \end_inset
2631
2632  The advantage of this package (compared to other packages such as 
2633 \family typewriter
2634 multibib
2635 \family default
2636 ) is that you don't need to define new citation commands.
2637  Instead, you need to prepare different bibliographic databases which include
2638  the entries for the different sections of the bibliography.
2639  For example: If you want to divide your bibliography into the sections
2640  
2641 \begin_inset Quotes eld
2642 \end_inset
2643
2644 Sources
2645 \begin_inset Quotes erd
2646 \end_inset
2647
2648  and 
2649 \begin_inset Quotes eld
2650 \end_inset
2651
2652 Scientific works
2653 \begin_inset Quotes erd
2654 \end_inset
2655
2656 , you first need to create two bibliographic databases, e.
2657 \begin_inset space \thinspace{}
2658 \end_inset
2659
2660 g.
2661 \begin_inset space \space{}
2662 \end_inset
2663
2664
2665 \begin_inset Flex Code
2666 status collapsed
2667
2668 \begin_layout Plain Layout
2669 sources.bib
2670 \end_layout
2671
2672 \end_inset
2673
2674  and 
2675 \begin_inset Flex Code
2676 status collapsed
2677
2678 \begin_layout Plain Layout
2679 scientific.bib
2680 \end_layout
2681
2682 \end_inset
2683
2684 .
2685  
2686 \end_layout
2687
2688 \begin_layout Standard
2689 Go to 
2690 \begin_inset Flex Noun
2691 status collapsed
2692
2693 \begin_layout Plain Layout
2694 Document\SpecialChar menuseparator
2695 Settings
2696 \end_layout
2697
2698 \end_inset
2699
2700  and check under 
2701 \begin_inset Flex Noun
2702 status collapsed
2703
2704 \begin_layout Plain Layout
2705 Bibliography
2706 \end_layout
2707
2708 \end_inset
2709
2710  the option 
2711 \begin_inset Flex Noun
2712 status collapsed
2713
2714 \begin_layout Plain Layout
2715 Subdivided bibliography
2716 \end_layout
2717
2718 \end_inset
2719
2720 .
2721  Now you can insert multiple Bib\SpecialChar TeX
2722  bibliographies, one for each section of
2723  your bibliography.
2724  Returning to our example: Insert the Bib\SpecialChar TeX
2725  bibliography 
2726 \begin_inset Flex Code
2727 status collapsed
2728
2729 \begin_layout Plain Layout
2730 sources.bib
2731 \end_layout
2732
2733 \end_inset
2734
2735  and a second one for the database 
2736 \begin_inset Flex Code
2737 status collapsed
2738
2739 \begin_layout Plain Layout
2740 scientific.bib
2741 \end_layout
2742
2743 \end_inset
2744
2745 .
2746  You are free to use the same or different styles for each section.
2747  Additionally, you can choose if the bibliography section should contain
2748  
2749 \begin_inset Quotes eld
2750 \end_inset
2751
2752 all cited references
2753 \begin_inset Quotes erd
2754 \end_inset
2755
2756  of the specified database(s) (which is the default), 
2757 \begin_inset Quotes eld
2758 \end_inset
2759
2760 all uncited references
2761 \begin_inset Quotes erd
2762 \end_inset
2763
2764  or even 
2765 \begin_inset Quotes eld
2766 \end_inset
2767
2768 all references
2769 \begin_inset Quotes erd
2770 \end_inset
2771
2772 .
2773  This might be useful if you would like to separate your bibliography into
2774  three sections: 
2775 \begin_inset Quotes eld
2776 \end_inset
2777
2778 Cited sources
2779 \begin_inset Quotes erd
2780 \end_inset
2781
2782
2783 \begin_inset Quotes eld
2784 \end_inset
2785
2786 Uncited sources
2787 \begin_inset Quotes erd
2788 \end_inset
2789
2790 , and 
2791 \begin_inset Quotes eld
2792 \end_inset
2793
2794 Scientific works
2795 \begin_inset Quotes erd
2796 \end_inset
2797
2798 .
2799  The titles for the sections can be added as ordinary sections or subsections.
2800  Since 
2801 \begin_inset Flex Code
2802 status collapsed
2803
2804 \begin_layout Plain Layout
2805 bibtopic
2806 \end_layout
2807
2808 \end_inset
2809
2810  removes the bibliography title, you have to manually re-add that, too (as
2811  a chapter* or section*, for instance).
2812 \end_layout
2813
2814 \begin_layout Standard
2815 With 
2816 \family sans
2817 Biblatex
2818 \family default
2819 , the procedure is a bit different.
2820  Since 
2821 \family typewriter
2822 bibtopic
2823 \family default
2824  does not work with 
2825 \family sans
2826 Biblatex
2827 \family default
2828 , the aforementioned 
2829 \begin_inset Flex Noun
2830 status collapsed
2831
2832 \begin_layout Plain Layout
2833 Subdivided bibliography
2834 \end_layout
2835
2836 \end_inset
2837
2838  option is disabled if you use 
2839 \family sans
2840 Biblatex
2841 \family default
2842 .
2843  However, 
2844 \family sans
2845 Biblatex
2846 \family default
2847  provides its own means to generate subdivided bibliographies.
2848  You can either add keywords to bibliography entries via the 
2849 \begin_inset Flex Code
2850 status collapsed
2851
2852 \begin_layout Plain Layout
2853 keywords
2854 \end_layout
2855
2856 \end_inset
2857
2858  entry option and then filter bibliography sections by keyword (by adding
2859  
2860 \begin_inset Flex Code
2861 status collapsed
2862
2863 \begin_layout Plain Layout
2864 keyword=mykeyword
2865 \end_layout
2866
2867 \end_inset
2868
2869  to the 
2870 \begin_inset Flex Noun
2871 status collapsed
2872
2873 \begin_layout Plain Layout
2874 Options
2875 \end_layout
2876
2877 \end_inset
2878
2879  field of the dialog that opens if you left-click on the 
2880 \begin_inset Flex Noun
2881 status collapsed
2882
2883 \begin_layout Plain Layout
2884 Biblatex Generated Bibliography
2885 \end_layout
2886
2887 \end_inset
2888
2889  button), or you can filter by entry types (such as 
2890 \emph on
2891 book
2892 \emph default
2893  or 
2894 \emph on
2895 article
2896 \emph default
2897 ) by entering e.
2898 \begin_inset space \thinspace{}
2899 \end_inset
2900
2901 g.
2902  
2903 \begin_inset Flex Code
2904 status collapsed
2905
2906 \begin_layout Plain Layout
2907 type=book
2908 \end_layout
2909
2910 \end_inset
2911
2912  or 
2913 \begin_inset Flex Code
2914 status collapsed
2915
2916 \begin_layout Plain Layout
2917 nottype=collection
2918 \end_layout
2919
2920 \end_inset
2921
2922  to the mentioned 
2923 \begin_inset Flex Noun
2924 status collapsed
2925
2926 \begin_layout Plain Layout
2927 Options
2928 \end_layout
2929
2930 \end_inset
2931
2932  field, or you can create so-called 
2933 \begin_inset Quotes eld
2934 \end_inset
2935
2936 Bibliography Categories
2937 \begin_inset Quotes erd
2938 \end_inset
2939
2940  to which you can assign individual entries.
2941  Please refer to the Biblatex manual, section 
2942 \emph on
2943 Subdivided Bibliographies
2944 \emph default
2945 , for details.
2946 \end_layout
2947
2948 \begin_layout Subsection
2949 Multiple Bibliographies
2950 \begin_inset CommandInset label
2951 LatexCommand label
2952 name "subsec:Multiple-Bibliographies"
2953
2954 \end_inset
2955
2956
2957 \end_layout
2958
2959 \begin_layout Standard
2960 Multiple bibliographies, e.
2961 \begin_inset space \thinspace{}
2962 \end_inset
2963
2964 g.
2965 \begin_inset space \space{}
2966 \end_inset
2967
2968 a bibliography for each part, chapter, section, subsection or child (sub-documen
2969 t) of the document, are also supported by \SpecialChar LyX
2970 .
2971  In order to enable it, go to 
2972 \begin_inset Flex Noun
2973 status collapsed
2974
2975 \begin_layout Plain Layout
2976 Document\SpecialChar menuseparator
2977 Settings\SpecialChar menuseparator
2978 Bibliography
2979 \end_layout
2980
2981 \end_inset
2982
2983  and select the relevant unit (e.
2984 \begin_inset space \thinspace{}
2985 \end_inset
2986
2987 g., 
2988 \begin_inset Quotes eld
2989 \end_inset
2990
2991 per section
2992 \begin_inset Quotes erd
2993 \end_inset
2994
2995 ) in the 
2996 \begin_inset Flex Noun
2997 status collapsed
2998
2999 \begin_layout Plain Layout
3000 Multiple Bibliographies
3001 \end_layout
3002
3003 \end_inset
3004
3005  combo box.
3006  Then add a Bib(la)\SpecialChar TeX
3007  bibliography to each unit (e.
3008 \begin_inset space \thinspace{}
3009 \end_inset
3010
3011 g., section) of your document.
3012  In the output, a separate bibliography, containing only the references
3013  done in the current unit is generated.
3014 \end_layout
3015
3016 \begin_layout Standard
3017 If you use Bib\SpecialChar TeX
3018 , either the 
3019 \begin_inset Flex Code
3020 status collapsed
3021
3022 \begin_layout Plain Layout
3023 chapterbib
3024 \end_layout
3025
3026 \end_inset
3027
3028  or the 
3029 \begin_inset Flex Code
3030 status collapsed
3031
3032 \begin_layout Plain Layout
3033 bibtopic
3034 \end_layout
3035
3036 \end_inset
3037
3038  package is used to create multiple bibliographies.
3039  The former package is used if you select 
3040 \begin_inset Quotes eld
3041 \end_inset
3042
3043 per child document
3044 \begin_inset Quotes erd
3045 \end_inset
3046
3047  and do 
3048 \emph on
3049 not
3050 \emph default
3051  check 
3052 \begin_inset Flex Noun
3053 status collapsed
3054
3055 \begin_layout Plain Layout
3056 Sectioned Bibliography
3057 \end_layout
3058
3059 \end_inset
3060
3061 .
3062  In all other cases, 
3063 \begin_inset Flex Code
3064 status collapsed
3065
3066 \begin_layout Plain Layout
3067 bibtopic
3068 \end_layout
3069
3070 \end_inset
3071
3072  is used.
3073 \begin_inset Foot
3074 status collapsed
3075
3076 \begin_layout Plain Layout
3077 An alternative approach, if you are willing to use some 
3078 \begin_inset Flex Noun
3079 status collapsed
3080
3081 \begin_layout Plain Layout
3082 \SpecialChar TeX
3083  Code
3084 \end_layout
3085
3086 \end_inset
3087
3088  (see section
3089 \begin_inset space ~
3090 \end_inset
3091
3092
3093 \begin_inset CommandInset ref
3094 LatexCommand ref
3095 reference "sec:Inserting-TeX-Code"
3096
3097 \end_inset
3098
3099 ), is to use the 
3100 \begin_inset Flex Code
3101 status collapsed
3102
3103 \begin_layout Plain Layout
3104 bibunits
3105 \end_layout
3106
3107 \end_inset
3108
3109  package.
3110 \end_layout
3111
3112 \end_inset
3113
3114  If 
3115 \begin_inset Flex Code
3116 status collapsed
3117
3118 \begin_layout Plain Layout
3119 bibtopic
3120 \end_layout
3121
3122 \end_inset
3123
3124  is used, \SpecialChar LyX
3125  encloses the specified units in 
3126 \begin_inset Flex Code
3127 status collapsed
3128
3129 \begin_layout Plain Layout
3130 bibtopic
3131 \end_layout
3132
3133 \end_inset
3134
3135 's 
3136 \begin_inset Flex Code
3137 status collapsed
3138
3139 \begin_layout Plain Layout
3140
3141 \backslash
3142 begin{btUnit}
3143 \end_layout
3144
3145 \end_inset
3146
3147  and 
3148 \begin_inset Flex Code
3149 status collapsed
3150
3151 \begin_layout Plain Layout
3152
3153 \backslash
3154 end{btUnit}
3155 \end_layout
3156
3157 \end_inset
3158
3159  in order to create the units.
3160  Note that this approach has some limitations.
3161  First, every citation reference has to be inside some 
3162 \begin_inset Flex Code
3163 status collapsed
3164
3165 \begin_layout Plain Layout
3166 btUnit
3167 \end_layout
3168
3169 \end_inset
3170
3171 .
3172  So citations outside a defined unit (e.
3173 \begin_inset space \thinspace{}
3174 \end_inset
3175
3176 g., before the first section if you use 
3177 \begin_inset Quotes eld
3178 \end_inset
3179
3180 by section
3181 \begin_inset Quotes erd
3182 \end_inset
3183
3184 ) will appear as 
3185 \begin_inset Quotes eld
3186 \end_inset
3187
3188 ???
3189 \begin_inset Quotes erd
3190 \end_inset
3191
3192 .
3193  You can also create your own units by entering 
3194 \begin_inset Flex Code
3195 status collapsed
3196
3197 \begin_layout Plain Layout
3198
3199 \backslash
3200 begin{btUnit}
3201 \end_layout
3202
3203 \end_inset
3204
3205  and 
3206 \begin_inset Flex Code
3207 status collapsed
3208
3209 \begin_layout Plain Layout
3210
3211 \backslash
3212 end{btUnit}
3213 \end_layout
3214
3215 \end_inset
3216
3217  as \SpecialChar TeX
3218  code (for instance to work around the mentioned limitation).
3219  Note, though, that 
3220 \begin_inset Flex Code
3221 status collapsed
3222
3223 \begin_layout Plain Layout
3224 btUnit
3225 \end_layout
3226
3227 \end_inset
3228
3229 s cannot be nested.
3230  A second limitation is that 
3231 \begin_inset Flex Code
3232 status collapsed
3233
3234 \begin_layout Plain Layout
3235 bibtopic
3236 \end_layout
3237
3238 \end_inset
3239
3240  always processes all references of a bibliography database, even if they
3241  are not cited.
3242  This can result in odd labels (e.
3243 \begin_inset space \thinspace{}
3244 \end_inset
3245
3246 g.
3247  
3248 \begin_inset Quotes eld
3249 \end_inset
3250
3251 Miller 2014b
3252 \begin_inset Quotes erd
3253 \end_inset
3254
3255  if two works of this author from 2014 are in the database, even if only
3256  one is cited).
3257 \end_layout
3258
3259 \begin_layout Standard
3260 If you use 
3261 \family sans
3262 Biblatex
3263 \family default
3264 , the 
3265 \begin_inset Flex Code
3266 status collapsed
3267
3268 \begin_layout Plain Layout
3269 refsection
3270 \end_layout
3271
3272 \end_inset
3273
3274  option is used instead.
3275  If you need specific units, you can start them with the \SpecialChar TeX
3276  code 
3277 \begin_inset Flex Code
3278 status collapsed
3279
3280 \begin_layout Plain Layout
3281
3282 \backslash
3283 newrefsection
3284 \end_layout
3285
3286 \end_inset
3287
3288  or 
3289 \begin_inset Flex Code
3290 status collapsed
3291
3292 \begin_layout Plain Layout
3293
3294 \backslash
3295 newrefsegment
3296 \end_layout
3297
3298 \end_inset
3299
3300 , respectively.
3301  If you also want to control the end of the unit, use the environment 
3302 \begin_inset Flex Code
3303 status collapsed
3304
3305 \begin_layout Plain Layout
3306
3307 \backslash
3308 begin{refsection}
3309 \end_layout
3310
3311 \end_inset
3312
3313  \SpecialChar ldots
3314  
3315 \begin_inset Flex Code
3316 status collapsed
3317
3318 \begin_layout Plain Layout
3319
3320 \backslash
3321 end{refsection}
3322 \end_layout
3323
3324 \end_inset
3325
3326  instead.
3327  Note, though, that 
3328 \begin_inset Flex Code
3329 status collapsed
3330
3331 \begin_layout Plain Layout
3332 refsection
3333 \end_layout
3334
3335 \end_inset
3336
3337 s cannot be nested.
3338  In addition to the individual bibliography of the current unit, 
3339 \family sans
3340 Biblatex
3341 \family default
3342  also provides an easy way to output all bibliographies, subsequently, at
3343  one place (e.
3344 \begin_inset space \thinspace{}
3345 \end_inset
3346
3347 g., at the end of the document).
3348  Select 
3349 \begin_inset Quotes eld
3350 \end_inset
3351
3352 all reference units
3353 \begin_inset Quotes erd
3354 \end_inset
3355
3356  from the Content combo box of the Bib(la)TeX inset dialog in order to achieve
3357  this.
3358  Please refer to the 
3359 \family sans
3360 Biblatex
3361 \family default
3362  manual for more information on this topic.
3363 \end_layout
3364
3365 \begin_layout Section
3366 Multipart Documents
3367 \end_layout
3368
3369 \begin_layout Subsection
3370 General Operation
3371 \end_layout
3372
3373 \begin_layout Standard
3374 When you are working on a large file with many sections, it is often convenient
3375  to break up the document into several files, or perhaps you have something
3376  where a table may change from time to time, but the preceding text does
3377  not.
3378  In these cases, you should seriously consider using multipart documents.
3379  For example, scientific papers often have five major sections: the introduction
3380 , observations, results, discussion, and conclusion.
3381  Each of these could be its own separate \SpecialChar LyX
3382  file, with one 
3383 \begin_inset Quotes eld
3384 \end_inset
3385
3386 master
3387 \begin_inset Quotes erd
3388 \end_inset
3389
3390  file which contains the title, authors, abstract, references, etc., plus
3391  the five included files.
3392  It is important to note that each of these files is a full \SpecialChar LyX
3393  file which
3394  can be formatted and printed on its own, as well as included in a master
3395  file.
3396  Each of these files must have the same document class, however—don't attempt
3397  to mix book classes with article classes.
3398  You may also include \SpecialChar LaTeX
3399  files; however, these files must not have their own
3400  preamble (i.
3401 \begin_inset space \thinspace{}
3402 \end_inset
3403
3404 e.
3405 \begin_inset space \space{}
3406 \end_inset
3407
3408 everything up to and including the 
3409 \begin_inset Flex Code
3410 status collapsed
3411
3412 \begin_layout Plain Layout
3413
3414 \backslash
3415 begin{document}
3416 \end_layout
3417
3418 \end_inset
3419
3420  line as well as the 
3421 \begin_inset Flex Code
3422 status collapsed
3423
3424 \begin_layout Plain Layout
3425
3426 \backslash
3427 end{document}
3428 \end_layout
3429
3430 \end_inset
3431
3432  line must be deleted) or else errors will be generated when you try to
3433  make a DVI file.
3434 \end_layout
3435
3436 \begin_layout Standard
3437 \SpecialChar LyX
3438  allows you to include files quite easily with 
3439 \begin_inset Flex Noun
3440 status collapsed
3441
3442 \begin_layout Plain Layout
3443 Insert\SpecialChar menuseparator
3444 Child
3445 \begin_inset space ~
3446 \end_inset
3447
3448 Document
3449 \end_layout
3450
3451 \end_inset
3452
3453 .
3454  When you click on this selection a small box is inserted into the file
3455  at the current cursor location.
3456  Clicking on the box raises a dialog which allows you to select the file
3457  to be included, and the method of its inclusion.
3458  
3459 \end_layout
3460
3461 \begin_layout Standard
3462 The file selection box should by now be obvious.
3463  The three inclusion methods are 
3464 \begin_inset Quotes eld
3465 \end_inset
3466
3467 include
3468 \begin_inset Quotes erd
3469 \end_inset
3470
3471
3472 \begin_inset Quotes eld
3473 \end_inset
3474
3475 input
3476 \begin_inset Quotes erd
3477 \end_inset
3478
3479 , and 
3480 \begin_inset Quotes eld
3481 \end_inset
3482
3483 verbatim
3484 \begin_inset Quotes erd
3485 \end_inset
3486
3487 .
3488  The methods 
3489 \begin_inset Quotes eld
3490 \end_inset
3491
3492 include
3493 \begin_inset Quotes erd
3494 \end_inset
3495
3496  and 
3497 \begin_inset Quotes eld
3498 \end_inset
3499
3500 input
3501 \begin_inset Quotes erd
3502 \end_inset
3503
3504  are similar in many ways, but there are also some notable differences:
3505 \end_layout
3506
3507 \begin_layout Enumerate
3508 Files that are 
3509 \begin_inset Quotes eld
3510 \end_inset
3511
3512 included
3513 \begin_inset Quotes erd
3514 \end_inset
3515
3516  are typeset beginning on a new page, while files that are 
3517 \begin_inset Quotes eld
3518 \end_inset
3519
3520 inputted
3521 \begin_inset Quotes erd
3522 \end_inset
3523
3524  are typeset starting on the current page.
3525 \end_layout
3526
3527 \begin_layout Enumerate
3528 \begin_inset Quotes eld
3529 \end_inset
3530
3531 Included
3532 \begin_inset Quotes erd
3533 \end_inset
3534
3535  files cannot themselves 
3536 \begin_inset Quotes eld
3537 \end_inset
3538
3539 include
3540 \begin_inset Quotes erd
3541 \end_inset
3542
3543  further files (
3544 \begin_inset Quotes eld
3545 \end_inset
3546
3547 grandchilds
3548 \begin_inset Quotes erd
3549 \end_inset
3550
3551 ).
3552  With 
3553 \begin_inset Quotes eld
3554 \end_inset
3555
3556 input
3557 \begin_inset Quotes erd
3558 \end_inset
3559
3560 , on the other hand, infinite sub-inputting is possible.
3561 \end_layout
3562
3563 \begin_layout Enumerate
3564 \begin_inset Quotes eld
3565 \end_inset
3566
3567 Include
3568 \begin_inset Quotes erd
3569 \end_inset
3570
3571  allow for the output of only selected 
3572 \begin_inset Quotes eld
3573 \end_inset
3574
3575 included
3576 \begin_inset Quotes erd
3577 \end_inset
3578
3579  files, while maintaining the actual counters (pagination etc.) and references
3580  (please refer to the section 
3581 \emph on
3582 Child
3583 \begin_inset space ~
3584 \end_inset
3585
3586 Documents
3587 \emph default
3588  of the 
3589 \emph on
3590 Embedded
3591 \begin_inset space ~
3592 \end_inset
3593
3594 Objects
3595 \emph default
3596  manual for details).
3597 \end_layout
3598
3599 \begin_layout Standard
3600 Hence, 
3601 \begin_inset Quotes eld
3602 \end_inset
3603
3604 include
3605 \begin_inset Quotes erd
3606 \end_inset
3607
3608  is the preferred method for chapters that are outsourced to child documents,
3609  while 
3610 \begin_inset Quotes eld
3611 \end_inset
3612
3613 input
3614 \begin_inset Quotes erd
3615 \end_inset
3616
3617  is more suitable for arbitrary file inheritance.
3618 \end_layout
3619
3620 \begin_layout Standard
3621
3622 \begin_inset Quotes eld
3623 \end_inset
3624
3625 verbatim
3626 \begin_inset Quotes erd
3627 \end_inset
3628
3629  included file allows you to include a file typeset exactly as it appears
3630  in the file, i.
3631 \begin_inset space \thinspace{}
3632 \end_inset
3633
3634 e.
3635 \begin_inset space \space{}
3636 \end_inset
3637
3638 in 
3639 \begin_inset Flex Code
3640 status collapsed
3641
3642 \begin_layout Plain Layout
3643 verbatim
3644 \end_layout
3645
3646 \end_inset
3647
3648  mode, with the characters set in a fixed-width typewriter font.
3649  Normally, spaces in this file are invisible, though two consecutive spaces
3650  are conserved, unlike \SpecialChar LyX
3651 's normal treatment of spaces.
3652  However, setting the 
3653 \begin_inset Flex Noun
3654 status collapsed
3655
3656 \begin_layout Plain Layout
3657 Mark
3658 \begin_inset space ~
3659 \end_inset
3660
3661 spaces
3662 \begin_inset space ~
3663 \end_inset
3664
3665 in
3666 \begin_inset space ~
3667 \end_inset
3668
3669 output
3670 \end_layout
3671
3672 \end_inset
3673
3674  checkbox typesets a mark to unambiguously define the presence of a space.
3675  
3676 \end_layout
3677
3678 \begin_layout Standard
3679 Generally, the master file is converted into a full \SpecialChar LaTeX
3680  file before typesetting,
3681  while the included files are converted to \SpecialChar LaTeX
3682  files that do not have all the
3683  preamble information.
3684 \end_layout
3685
3686 \begin_layout Subsection
3687 Cross-References Between Files
3688 \end_layout
3689
3690 \begin_layout Standard
3691 \begin_inset Box Shadowbox
3692 position "t"
3693 hor_pos "c"
3694 has_inner_box 1
3695 inner_pos "t"
3696 use_parbox 0
3697 use_makebox 0
3698 width "100col%"
3699 special "none"
3700 height "1in"
3701 height_special "totalheight"
3702 thickness "0.4pt"
3703 separation "3pt"
3704 shadowsize "4pt"
3705 framecolor "black"
3706 backgroundcolor "none"
3707 status open
3708
3709 \begin_layout Plain Layout
3710 This section is somewhat out of date.
3711  Need to describe default master documents and how children are opened when
3712  the master is.
3713  [[FIXME]]
3714 \end_layout
3715
3716 \end_inset
3717
3718
3719 \end_layout
3720
3721 \begin_layout Standard
3722 It is possible to set up cross-references between the different files.
3723  First, open all the files in question: let's call them A and B in a two
3724  file example, where B is included in A.
3725  Let's say you insert a label in A, then want to reference it in B.
3726  Open the cross-reference dialog whilst in document B, and you can select
3727  the 
3728 \begin_inset Quotes eld
3729 \end_inset
3730
3731 buffer
3732 \begin_inset Quotes erd
3733 \end_inset
3734
3735  to use.
3736 \end_layout
3737
3738 \begin_layout Subsection
3739 Bibliography Lists in all Subdocuments
3740 \end_layout
3741
3742 \begin_layout Standard
3743 If you work with child documents, you might want to have only one main bibliogra
3744 phy at the end, but still be able to have a selected bibliography for the
3745  child if you output it on its own.
3746  Here is how to achieve this.
3747 \end_layout
3748
3749 \begin_layout Standard
3750 For the main document, you just insert a bibliography inset at the place
3751  where the main bibliography has to appear (within the master file or within
3752  a child).
3753  If the bibliography inset is in the master file, the references will be
3754  inherited by all children, so they are available in the citation dialog
3755  within each child.
3756 \end_layout
3757
3758 \begin_layout Standard
3759 For child-specific bibliographies, insert bibliography insets within the
3760  child documents, at the place where the bibliography should appear when
3761  the child is compiled separately.
3762  However, the trick is to insert them into a branch (
3763 \family sans
3764 Insert\SpecialChar menuseparator
3765 Branch\SpecialChar menuseparator
3766 Insert New Branch...
3767 \family default
3768 ), e.
3769 \begin_inset space \thinspace{}
3770 \end_inset
3771
3772 g.
3773  called 
3774 \begin_inset Quotes eld
3775 \end_inset
3776
3777 Childonly
3778 \begin_inset Quotes erd
3779 \end_inset
3780
3781 .
3782  Within the children, activate the branch (
3783 \family sans
3784 Document\SpecialChar menuseparator
3785 Settings...\SpecialChar menuseparator
3786 Branches
3787 \family default
3788 ).
3789  Within the master, deactivate the branch (
3790 \family sans
3791 Document\SpecialChar menuseparator
3792 Settings...\SpecialChar menuseparator
3793 Branches
3794 \family default
3795 ).
3796  Now the child's bibliography will be ignored by the master, but considered
3797  by the child.
3798 \end_layout
3799
3800 \begin_layout Standard
3801 If you need multiple bibliographies (e.
3802 \begin_inset space \thinspace{}
3803 \end_inset
3804
3805 g., one per child in the 
3806 \emph on
3807 main document
3808 \emph default
3809 ), please refer to sec.
3810 \begin_inset space ~
3811 \end_inset
3812
3813
3814 \begin_inset CommandInset ref
3815 LatexCommand ref
3816 reference "subsec:Multiple-Bibliographies"
3817
3818 \end_inset
3819
3820 .
3821 \end_layout
3822
3823 \begin_layout Section
3824 \SpecialChar LyX
3825  Archives
3826 \end_layout
3827
3828 \begin_layout Standard
3829 Users sometimes need to be able to 
3830 \begin_inset Quotes eld
3831 \end_inset
3832
3833 bundle
3834 \begin_inset Quotes erd
3835 \end_inset
3836
3837  a \SpecialChar LyX
3838  file together with all the images (and other files) on which it depends,
3839  either for sending to a publisher or for sharing with a co-author.
3840  \SpecialChar LyX
3841  includes a Python script (
3842 \begin_inset Flex Code
3843 status collapsed
3844
3845 \begin_layout Plain Layout
3846 lyxpak.py
3847 \end_layout
3848
3849 \end_inset
3850
3851 ) that automates this process.
3852  To use it, you must have either the 
3853 \begin_inset Flex Code
3854 status collapsed
3855
3856 \begin_layout Plain Layout
3857 zipfile
3858 \end_layout
3859
3860 \end_inset
3861
3862  or 
3863 \begin_inset Flex Code
3864 status collapsed
3865
3866 \begin_layout Plain Layout
3867 tarfile
3868 \end_layout
3869
3870 \end_inset
3871
3872  python modules installed on your system.
3873  By default, the script prefers the 
3874 \begin_inset Flex Code
3875 status collapsed
3876
3877 \begin_layout Plain Layout
3878 gzip
3879 \end_layout
3880
3881 \end_inset
3882
3883 -compressed 
3884 \begin_inset Flex Code
3885 status collapsed
3886
3887 \begin_layout Plain Layout
3888 tar
3889 \end_layout
3890
3891 \end_inset
3892
3893  format on Unix-like systems and the 
3894 \begin_inset Flex Code
3895 status collapsed
3896
3897 \begin_layout Plain Layout
3898 zip
3899 \end_layout
3900
3901 \end_inset
3902
3903  format on Windows.
3904 \end_layout
3905
3906 \begin_layout Standard
3907 \SpecialChar LyX
3908 's configuration process will set the script up to export a `\SpecialChar LyX
3909  Archive',
3910  and this format will then be available under 
3911 \begin_inset Flex Code
3912 status collapsed
3913
3914 \begin_layout Plain Layout
3915 File\SpecialChar menuseparator
3916 Export
3917 \end_layout
3918
3919 \end_inset
3920
3921 .
3922 \end_layout
3923
3924 \begin_layout Standard
3925 Independently of the platform, the generation of a particular archive format
3926  can be forced by adding either the 
3927 \begin_inset Flex Code
3928 status collapsed
3929
3930 \begin_layout Plain Layout
3931 -t
3932 \end_layout
3933
3934 \end_inset
3935
3936  (for the 
3937 \begin_inset Flex Code
3938 status collapsed
3939
3940 \begin_layout Plain Layout
3941 tar
3942 \end_layout
3943
3944 \end_inset
3945
3946  format) or 
3947 \begin_inset Flex Code
3948 status collapsed
3949
3950 \begin_layout Plain Layout
3951 -z
3952 \end_layout
3953
3954 \end_inset
3955
3956  (for the 
3957 \begin_inset Flex Code
3958 status collapsed
3959
3960 \begin_layout Plain Layout
3961 zip
3962 \end_layout
3963
3964 \end_inset
3965
3966  format) switch to the 
3967 \begin_inset Flex Code
3968 status collapsed
3969
3970 \begin_layout Plain Layout
3971 \SpecialChar LyX
3972 \SpecialChar menuseparator
3973 \SpecialChar LyX
3974  Archive
3975 \end_layout
3976
3977 \end_inset
3978
3979  converter in 
3980 \begin_inset Flex Code
3981 status collapsed
3982
3983 \begin_layout Plain Layout
3984 Tools\SpecialChar menuseparator
3985 Preferences\SpecialChar menuseparator
3986 File Handling\SpecialChar menuseparator
3987 Converters
3988 \end_layout
3989
3990 \end_inset
3991
3992 .
3993  (Make sure you add the switch after the script name, not before it.)
3994 \end_layout
3995
3996 \begin_layout Section
3997 Fancy Headers and Footers
3998 \end_layout
3999
4000 \begin_layout Standard
4001 The default page layout is rather plain; for an 
4002 \begin_inset Flex Code
4003 status collapsed
4004
4005 \begin_layout Plain Layout
4006 article
4007 \end_layout
4008
4009 \end_inset
4010
4011  document class, all you get is a centered page number at the bottom of
4012  the page.
4013  This document uses KOMA-script's book class, so it appears to be a bit
4014  fancier.
4015  But to really put on a show, you need to set the document page style to
4016  
4017 \begin_inset Quotes eld
4018 \end_inset
4019
4020 fancy
4021 \begin_inset Quotes erd
4022 \end_inset
4023
4024 , as mentioned in the 
4025 \emph on
4026 User Guide
4027 \emph default
4028 .
4029  This section describes the \SpecialChar LaTeX
4030  code you need to insert in your \SpecialChar LaTeX
4031  preamble in
4032  order to get the desired effects.
4033 \end_layout
4034
4035 \begin_layout Standard
4036 For more information on fancy headers, see the 
4037 \begin_inset Flex Code
4038 status collapsed
4039
4040 \begin_layout Plain Layout
4041 fancyhdr
4042 \end_layout
4043
4044 \end_inset
4045
4046  package documentation.
4047  (
4048 \begin_inset Flex URL
4049 status collapsed
4050
4051 \begin_layout Plain Layout
4052
4053 https://www.ctan.org/tex-archive/help/Catalogue/entries/fancyhdr.html
4054 \end_layout
4055
4056 \end_inset
4057
4058 )
4059 \end_layout
4060
4061 \begin_layout Standard
4062 The page header is divided into three fields, not surprisingly labeled 
4063 \begin_inset Quotes eld
4064 \end_inset
4065
4066 left
4067 \begin_inset Quotes erd
4068 \end_inset
4069
4070
4071 \begin_inset Quotes eld
4072 \end_inset
4073
4074 center
4075 \begin_inset Quotes erd
4076 \end_inset
4077
4078 , and 
4079 \begin_inset Quotes eld
4080 \end_inset
4081
4082 right
4083 \begin_inset Quotes erd
4084 \end_inset
4085
4086 .
4087  The footer is also divided into these three fields.
4088  The \SpecialChar LaTeX
4089  commands to set these fields in the simplest manner are 
4090 \begin_inset Flex Code
4091 status collapsed
4092
4093 \begin_layout Plain Layout
4094
4095 \backslash
4096 lhead
4097 \end_layout
4098
4099 \end_inset
4100
4101
4102 \begin_inset Flex Code
4103 status collapsed
4104
4105 \begin_layout Plain Layout
4106
4107 \backslash
4108 chead
4109 \end_layout
4110
4111 \end_inset
4112
4113
4114 \begin_inset Flex Code
4115 status collapsed
4116
4117 \begin_layout Plain Layout
4118
4119 \backslash
4120 rhead
4121 \end_layout
4122
4123 \end_inset
4124
4125
4126 \begin_inset Flex Code
4127 status collapsed
4128
4129 \begin_layout Plain Layout
4130
4131 \backslash
4132 lfoot
4133 \end_layout
4134
4135 \end_inset
4136
4137 , etc.
4138  Suppose you wish to put your name in the upper left hand corner of each
4139  page.
4140  Simply insert the following command in the preamble: 
4141 \end_layout
4142
4143 \begin_layout Standard
4144
4145 \family typewriter
4146
4147 \backslash
4148 lhead{John Q.
4149  DocWriter}
4150 \end_layout
4151
4152 \begin_layout Standard
4153 You will now see your name in the upper left.
4154  If a field has a default entry that you would like to get rid of (often
4155  the page number appears in the central footer) simply include a command
4156  with a blank argument, e.
4157 \begin_inset space \thinspace{}
4158 \end_inset
4159
4160 g.:
4161 \end_layout
4162
4163 \begin_layout Standard
4164
4165 \family typewriter
4166
4167 \backslash
4168 cfoot{}
4169 \end_layout
4170
4171 \begin_layout Standard
4172 Let's get really fancy: lets put the section number with the word 
4173 \begin_inset Quotes eld
4174 \end_inset
4175
4176 Section
4177 \begin_inset Quotes erd
4178 \end_inset
4179
4180  (e.
4181 \begin_inset space \thinspace{}
4182 \end_inset
4183
4184 g.
4185 \begin_inset space \space{}
4186 \end_inset
4187
4188 Section 3) in the upper left, the page number (e.
4189 \begin_inset space \thinspace{}
4190 \end_inset
4191
4192 g.
4193 \begin_inset space \space{}
4194 \end_inset
4195
4196 Page 4) in the upper right, your name in the lower left, and the date in
4197  the lower right.
4198  The following commands should now appear in the preamble:
4199 \end_layout
4200
4201 \begin_layout Standard
4202
4203 \family typewriter
4204
4205 \backslash
4206 lhead{Section 
4207 \backslash
4208 thesection}
4209 \end_layout
4210
4211 \begin_layout Standard
4212
4213 \family typewriter
4214
4215 \backslash
4216 chead{}
4217 \end_layout
4218
4219 \begin_layout Standard
4220
4221 \family typewriter
4222
4223 \backslash
4224 rhead{Page 
4225 \backslash
4226 thepage}
4227 \end_layout
4228
4229 \begin_layout Standard
4230
4231 \family typewriter
4232
4233 \backslash
4234 lfoot{John Q.
4235  DocWriter}
4236 \end_layout
4237
4238 \begin_layout Standard
4239
4240 \family typewriter
4241
4242 \backslash
4243 cfoot{}
4244 \end_layout
4245
4246 \begin_layout Standard
4247
4248 \family typewriter
4249
4250 \backslash
4251 rfoot{
4252 \backslash
4253 today}
4254 \end_layout
4255
4256 \begin_layout Standard
4257 The commands 
4258 \begin_inset Flex Code
4259 status collapsed
4260
4261 \begin_layout Plain Layout
4262
4263 \backslash
4264 thesection
4265 \end_layout
4266
4267 \end_inset
4268
4269  and 
4270 \begin_inset Flex Code
4271 status collapsed
4272
4273 \begin_layout Plain Layout
4274
4275 \backslash
4276 thepage
4277 \end_layout
4278
4279 \end_inset
4280
4281  access \SpecialChar LaTeX
4282 's section and page counters, and so print out the current section
4283  and page numbers.
4284  
4285 \begin_inset Flex Code
4286 status collapsed
4287
4288 \begin_layout Plain Layout
4289
4290 \backslash
4291 today
4292 \end_layout
4293
4294 \end_inset
4295
4296  simply prints out today's date.
4297 \end_layout
4298
4299 \begin_layout Standard
4300 The thicknesses of the horizontal rules drawn beneath the header and above
4301  the footer can also be modified.
4302  If you don't want one of the rules, set its thickness to 0.
4303  The header rule has a default thickness of 0.4pt, the footer rule is 0pt.
4304  Use commands
4305 \family typewriter
4306  
4307 \family default
4308 like 
4309 \begin_inset Flex Code
4310 status collapsed
4311
4312 \begin_layout Plain Layout
4313
4314 \backslash
4315 renewcommand{
4316 \backslash
4317 headrulewidth}{0.4pt}
4318 \end_layout
4319
4320 \end_inset
4321
4322  and 
4323 \begin_inset Flex Code
4324 status collapsed
4325
4326 \begin_layout Plain Layout
4327
4328 \backslash
4329 renewcommand{
4330 \backslash
4331 footrulewidth}{0.4pt}
4332 \end_layout
4333
4334 \end_inset
4335
4336  to set the thicknesses.
4337 \end_layout
4338
4339 \begin_layout Standard
4340 You can switch the header/footer settings on and off for individual pages
4341  using commands like 
4342 \begin_inset Flex Code
4343 status collapsed
4344
4345 \begin_layout Plain Layout
4346
4347 \backslash
4348 thispagestyle{empty}
4349 \end_layout
4350
4351 \end_inset
4352
4353
4354 \begin_inset Flex Code
4355 status collapsed
4356
4357 \begin_layout Plain Layout
4358
4359 \backslash
4360 thispagestyle{plain}
4361 \end_layout
4362
4363 \end_inset
4364
4365 , and 
4366 \begin_inset Flex Code
4367 status collapsed
4368
4369 \begin_layout Plain Layout
4370
4371 \backslash
4372 thispagestyle{fancy}
4373 \end_layout
4374
4375 \end_inset
4376
4377 .
4378  Simply insert them in the text on the page you want changed and mark them
4379  as \SpecialChar TeX
4380  code.
4381  In fact, title pages are marked as plain by default, while following pages
4382  are marked fancy when using the global fancy setting.
4383 \end_layout
4384
4385 \begin_layout Standard
4386 As a final example, it is possible to include an image in the header or
4387  footer.
4388  Suppose you want to put a company logo in the upper lefthand corner.
4389  You might try something like
4390 \end_layout
4391
4392 \begin_layout Standard
4393
4394 \family typewriter
4395
4396 \backslash
4397 lhead{
4398 \backslash
4399 resizebox{1in}{!}{
4400 \backslash
4401 includegraphics{logo.eps}}}
4402 \end_layout
4403
4404 \begin_layout Standard
4405 \noindent
4406 (you may need to preface this with 
4407 \begin_inset Flex Code
4408 status collapsed
4409
4410 \begin_layout Plain Layout
4411 \noindent
4412
4413 \backslash
4414 usepackage{graphics}
4415 \end_layout
4416
4417 \end_inset
4418
4419  if you don't include graphics elsewhere in your document).
4420 \end_layout
4421
4422 \begin_layout Section
4423 Itemize Bullet Selection
4424 \begin_inset CommandInset label
4425 LatexCommand label
4426 name "sec:bullet"
4427
4428 \end_inset
4429
4430
4431 \end_layout
4432
4433 \begin_layout Standard
4434 by
4435 \noun on
4436  Allan Rae
4437 \end_layout
4438
4439 \begin_layout Subsection
4440 Introduction
4441 \end_layout
4442
4443 \begin_layout Standard
4444 \SpecialChar LyX
4445  provides 216 bullet shapes that can be accessed from a simple dialog.
4446  Using this dialog you can easily specify what bullet shape to use at each
4447  level of an itemized list.
4448  These settings are document-wide so you won't be able to specify different
4449  sets of bullets for different paragraphs.
4450 \begin_inset Foot
4451 status collapsed
4452
4453 \begin_layout Plain Layout
4454 Well, actually you can but you'll have to do it by hand.
4455 \end_layout
4456
4457 \end_inset
4458
4459
4460 \end_layout
4461
4462 \begin_layout Subsection
4463 How it looks
4464 \end_layout
4465
4466 \begin_layout Standard
4467 Open the dialog by selecting the 
4468 \begin_inset Flex Noun
4469 status collapsed
4470
4471 \begin_layout Plain Layout
4472 Document\SpecialChar menuseparator
4473 Settings
4474 \end_layout
4475
4476 \end_inset
4477
4478  menu item and then select the 
4479 \begin_inset Flex Noun
4480 status collapsed
4481
4482 \begin_layout Plain Layout
4483 Bullets
4484 \end_layout
4485
4486 \end_inset
4487
4488  tab.
4489 \end_layout
4490
4491 \begin_layout Standard
4492 The dialog provides you with a table of bullet shapes.
4493  A column of buttons on the left of the table provides access to the six
4494  different panels of bullet shapes.
4495  The row of buttons across the top is used to select which bullet depth
4496  you are changing.
4497  A text entry under the table shows the currently selected bullet shape's
4498  \SpecialChar LaTeX
4499  equivalent and this can be edited if desired.
4500  If you do modify the text you will also need to specify any needed packages
4501  in the \SpecialChar LaTeX
4502  preamble.
4503 \end_layout
4504
4505 \begin_layout Standard
4506 The six panels are divided up by the packages they require.
4507  The following table shows the mappings from button name to \SpecialChar LaTeX
4508  package.
4509 \end_layout
4510
4511 \begin_layout Standard
4512 \align center
4513 \begin_inset Tabular
4514 <lyxtabular version="3" rows="7" columns="2">
4515 <features tabularvalignment="middle">
4516 <column alignment="center" valignment="top" width="0pt">
4517 <column alignment="center" valignment="top" width="0pt">
4518 <row>
4519 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
4520 \begin_inset Text
4521
4522 \begin_layout Plain Layout
4523
4524 \family roman
4525 \series medium
4526 \shape up
4527 \size normal
4528 \emph off
4529 \bar no
4530 \noun off
4531 \color none
4532 Button
4533 \end_layout
4534
4535 \end_inset
4536 </cell>
4537 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
4538 \begin_inset Text
4539
4540 \begin_layout Plain Layout
4541
4542 \family roman
4543 \series medium
4544 \shape up
4545 \size normal
4546 \emph off
4547 \bar no
4548 \noun off
4549 \color none
4550 Packages Required
4551 \end_layout
4552
4553 \end_inset
4554 </cell>
4555 </row>
4556 <row>
4557 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4558 \begin_inset Text
4559
4560 \begin_layout Plain Layout
4561
4562 \family sans
4563 \series medium
4564 \shape up
4565 \size normal
4566 \emph off
4567 \bar no
4568 \noun off
4569 \color none
4570 Standard
4571 \end_layout
4572
4573 \end_inset
4574 </cell>
4575 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4576 \begin_inset Text
4577
4578 \begin_layout Plain Layout
4579
4580 \series medium
4581 \shape up
4582 \size normal
4583 \emph off
4584 \bar no
4585 \noun off
4586 \color none
4587 base \SpecialChar LaTeX
4588
4589 \end_layout
4590
4591 \end_inset
4592 </cell>
4593 </row>
4594 <row>
4595 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4596 \begin_inset Text
4597
4598 \begin_layout Plain Layout
4599
4600 \family sans
4601 \series medium
4602 \shape up
4603 \size normal
4604 \emph off
4605 \bar no
4606 \noun off
4607 \color none
4608 Maths
4609 \end_layout
4610
4611 \end_inset
4612 </cell>
4613 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4614 \begin_inset Text
4615
4616 \begin_layout Plain Layout
4617
4618 \family typewriter
4619 \series medium
4620 \shape up
4621 \size normal
4622 \emph off
4623 \bar no
4624 \noun off
4625 \color none
4626 amssymb.sty
4627 \end_layout
4628
4629 \end_inset
4630 </cell>
4631 </row>
4632 <row>
4633 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4634 \begin_inset Text
4635
4636 \begin_layout Plain Layout
4637
4638 \family sans
4639 \series medium
4640 \shape up
4641 \size normal
4642 \emph off
4643 \bar no
4644 \noun off
4645 \color none
4646 Ding1
4647 \end_layout
4648
4649 \end_inset
4650 </cell>
4651 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4652 \begin_inset Text
4653
4654 \begin_layout Plain Layout
4655
4656 \family typewriter
4657 \series medium
4658 \shape up
4659 \size normal
4660 \emph off
4661 \bar no
4662 \noun off
4663 \color none
4664 pifont.sty
4665 \end_layout
4666
4667 \end_inset
4668 </cell>
4669 </row>
4670 <row>
4671 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4672 \begin_inset Text
4673
4674 \begin_layout Plain Layout
4675
4676 \family sans
4677 \series medium
4678 \shape up
4679 \size normal
4680 \emph off
4681 \bar no
4682 \noun off
4683 \color none
4684 Ding2
4685 \end_layout
4686
4687 \end_inset
4688 </cell>
4689 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4690 \begin_inset Text
4691
4692 \begin_layout Plain Layout
4693
4694 \family typewriter
4695 \series medium
4696 \shape up
4697 \size normal
4698 \emph off
4699 \bar no
4700 \noun off
4701 \color none
4702 pifont.sty
4703 \end_layout
4704
4705 \end_inset
4706 </cell>
4707 </row>
4708 <row>
4709 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
4710 \begin_inset Text
4711
4712 \begin_layout Plain Layout
4713
4714 \family sans
4715 \series medium
4716 \shape up
4717 \size normal
4718 \emph off
4719 \bar no
4720 \noun off
4721 \color none
4722 Ding3
4723 \end_layout
4724
4725 \end_inset
4726 </cell>
4727 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
4728 \begin_inset Text
4729
4730 \begin_layout Plain Layout
4731
4732 \family typewriter
4733 \series medium
4734 \shape up
4735 \size normal
4736 \emph off
4737 \bar no
4738 \noun off
4739 \color none
4740 pifont.sty
4741 \end_layout
4742
4743 \end_inset
4744 </cell>
4745 </row>
4746 <row>
4747 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
4748 \begin_inset Text
4749
4750 \begin_layout Plain Layout
4751
4752 \family sans
4753 \series medium
4754 \shape up
4755 \size normal
4756 \emph off
4757 \bar no
4758 \noun off
4759 \color none
4760 Ding4
4761 \end_layout
4762
4763 \end_inset
4764 </cell>
4765 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
4766 \begin_inset Text
4767
4768 \begin_layout Plain Layout
4769
4770 \family typewriter
4771 \series medium
4772 \shape up
4773 \size normal
4774 \emph off
4775 \bar no
4776 \noun off
4777 \color none
4778 pifont.sty
4779 \end_layout
4780
4781 \end_inset
4782 </cell>
4783 </row>
4784 </lyxtabular>
4785
4786 \end_inset
4787
4788
4789 \end_layout
4790
4791 \begin_layout Standard
4792 \SpecialChar LyX
4793  doesn't stop you using bullets from packages you don't have.
4794  If you get errors from \SpecialChar LaTeX
4795  when you try to view or print the file, then it
4796  is likely you are missing a package.
4797 \begin_inset Foot
4798 status collapsed
4799
4800 \begin_layout Plain Layout
4801 \SpecialChar LyX
4802  doesn't restrict your use since you may be editing locally and exporting
4803  elsewhere.
4804 \end_layout
4805
4806 \end_inset
4807
4808
4809 \end_layout
4810
4811 \begin_layout Subsection
4812 How to use it
4813 \end_layout
4814
4815 \begin_layout Standard
4816 Select which bullet depth you want to change then select the bullet shape
4817  and size.
4818  Any changes will not be visible in \SpecialChar LyX
4819 , but are visible when viewing the document.
4820 \end_layout
4821
4822 \begin_layout Standard
4823 You can reset a bullet shape to the default simply by clicking your right
4824  mouse button on the appropriate bullet depth button.
4825 \begin_inset Foot
4826 status open
4827
4828 \begin_layout Plain Layout
4829 If you 
4830 \emph on
4831 really
4832 \emph default
4833  want to have multiple sets of paragraphs with different sets of bullets
4834  in each, then you're going to have to get your hands dirty with \SpecialChar TeX
4835  code.
4836  The bullet selection dialog can help though because it provides you with
4837  the \SpecialChar LaTeX
4838  code for a wide range of bullet shapes.
4839  To make your own custom paragraphs you have the following options:
4840 \end_layout
4841
4842 \begin_layout Plain Layout
4843 \begin_inset ERT
4844 status open
4845
4846 \begin_layout Plain Layout
4847
4848
4849 \backslash
4850 let
4851 \backslash
4852 savelabelitemi=
4853 \backslash
4854 labelitemi
4855 \end_layout
4856
4857 \end_inset
4858
4859
4860 \end_layout
4861
4862 \begin_layout Plain Layout
4863 \begin_inset ERT
4864 status open
4865
4866 \begin_layout Plain Layout
4867
4868
4869 \backslash
4870 renewcommand
4871 \backslash
4872 labelitemi[0]{
4873 \backslash
4874 small
4875 \backslash
4876 (
4877 \backslash
4878 sharp
4879 \backslash
4880 )}
4881 \end_layout
4882
4883 \end_inset
4884
4885
4886 \end_layout
4887
4888 \begin_layout Itemize
4889 Use the \SpecialChar LaTeX
4890  command 
4891 \begin_inset Flex Code
4892 status collapsed
4893
4894 \begin_layout Plain Layout
4895
4896 \backslash
4897 renewcommand{}{}
4898 \end_layout
4899
4900 \end_inset
4901
4902  to specify a new bullet shape for a given depth.
4903  You'll also need to save the current bullet shape so you can restore it
4904  again afterwards.
4905  In this itemized list the following \SpecialChar LaTeX
4906  code was used to change the bullet
4907  used for the first depth.
4908 \end_layout
4909
4910 \begin_deeper
4911 \begin_layout LyX-Code
4912
4913 \backslash
4914 let
4915 \backslash
4916 savelabelitemi=
4917 \backslash
4918 labelitemi 
4919 \end_layout
4920
4921 \begin_layout LyX-Code
4922
4923 \backslash
4924 renewcommand
4925 \backslash
4926 labelitemi[0]{
4927 \backslash
4928 small
4929 \backslash
4930 (
4931 \backslash
4932 sharp
4933 \backslash
4934 )}
4935 \end_layout
4936
4937 \end_deeper
4938 \begin_layout Itemize
4939 Note that the itemize depth is specified in Roman numerals as part of the
4940  
4941 \family typewriter
4942
4943 \backslash
4944 labelitem
4945 \family default
4946  command.
4947 \end_layout
4948
4949 \begin_layout Itemize
4950 \begin_inset Argument item:1
4951 status open
4952
4953 \begin_layout Plain Layout
4954 \begin_inset ERT
4955 status open
4956
4957 \begin_layout Plain Layout
4958
4959
4960 \backslash
4961 (
4962 \backslash
4963 star
4964 \backslash
4965 )
4966 \end_layout
4967
4968 \end_inset
4969
4970
4971 \end_layout
4972
4973 \end_inset
4974
4975  Specify each individual entry by starting each item with the bullet shape
4976  enclosed in a 
4977 \begin_inset Quotes eld
4978 \end_inset
4979
4980 Custom Item
4981 \begin_inset Quotes erd
4982 \end_inset
4983
4984  inset (available at 
4985 \family sans
4986 Insert\SpecialChar menuseparator
4987 Custom Item
4988 \family default
4989 ) and set as 
4990 \begin_inset Flex Noun
4991 status collapsed
4992
4993 \begin_layout Plain Layout
4994 \SpecialChar TeX
4995  Code
4996 \end_layout
4997
4998 \end_inset
4999
5000 .
5001  For example, this item was started with 
5002 \begin_inset Flex Code
5003 status collapsed
5004
5005 \begin_layout Plain Layout
5006
5007 \backslash
5008 (
5009 \backslash
5010 star
5011 \backslash
5012 )
5013 \end_layout
5014
5015 \end_inset
5016
5017 .
5018 \end_layout
5019
5020 \begin_layout Plain Layout
5021 \begin_inset ERT
5022 status open
5023
5024 \begin_layout Plain Layout
5025
5026
5027 \backslash
5028 renewcommand
5029 \backslash
5030 labelitemi[0]{
5031 \backslash
5032 savelabelitemi}
5033 \end_layout
5034
5035 \end_inset
5036
5037
5038 \end_layout
5039
5040 \begin_layout Plain Layout
5041 You'll also need to revert the labelitem back to its previous setting for
5042  the global bullet shape settings to remain in effect.
5043  The way used here was:
5044 \end_layout
5045
5046 \begin_layout LyX-Code
5047
5048 \backslash
5049 renewcommand
5050 \backslash
5051 labelitemi[0]{
5052 \backslash
5053 savelabelitemi}
5054 \end_layout
5055
5056 \end_inset
5057
5058
5059 \end_layout
5060
5061 \begin_layout Chapter
5062 \SpecialChar LyX
5063  and the World Wide Web
5064 \end_layout
5065
5066 \begin_layout Standard
5067 \SpecialChar LyX
5068  has long supported the export of documents to various web-friendly formats,
5069  such as HTML.
5070  Before version 2.0, however, HTML export was always accomplished by the
5071  use of external converters.
5072 \begin_inset Foot
5073 status collapsed
5074
5075 \begin_layout Plain Layout
5076 For details on the use of external converters with \SpecialChar LyX
5077 , see the 
5078 \emph on
5079 Converters
5080 \emph default
5081  section of the Customization manual.
5082 \end_layout
5083
5084 \end_inset
5085
5086  These fall into two large groups: there are converters that use \SpecialChar LaTeX
5087  as an
5088  intermediate format, such as 
5089 \begin_inset Flex Code
5090 status collapsed
5091
5092 \begin_layout Plain Layout
5093 htlatex
5094 \end_layout
5095
5096 \end_inset
5097
5098
5099 \begin_inset Flex Code
5100 status collapsed
5101
5102 \begin_layout Plain Layout
5103 html2latex
5104 \end_layout
5105
5106 \end_inset
5107
5108 , and 
5109 \begin_inset Flex Code
5110 status collapsed
5111
5112 \begin_layout Plain Layout
5113 plastex
5114 \end_layout
5115
5116 \end_inset
5117
5118 , relying upon \SpecialChar LyX
5119  to produce the \SpecialChar LaTeX
5120 ; and there is a converter that works directly
5121  on \SpecialChar LyX
5122  files, 
5123 \begin_inset Flex Code
5124 status collapsed
5125
5126 \begin_layout Plain Layout
5127 e\SpecialChar LyX
5128 er
5129 \end_layout
5130
5131 \end_inset
5132
5133 .
5134  All of these have different advantages and disadvantages.
5135  
5136 \end_layout
5137
5138 \begin_layout Standard
5139 The \SpecialChar LaTeX
5140 -based converters have the advantage that, in principle, they know everythin
5141 g about the exported document that \SpecialChar LaTeX
5142  does.
5143  Such converters do not care, for example, if a certain block of code was
5144  produced by \SpecialChar LyX
5145  or was Evil Red Text.
5146  These converters know about 
5147 \begin_inset Flex Code
5148 status collapsed
5149
5150 \begin_layout Plain Layout
5151 aux
5152 \end_layout
5153
5154 \end_inset
5155
5156  files, counters, and references, and can often make use of the 
5157 \begin_inset Flex Code
5158 status collapsed
5159
5160 \begin_layout Plain Layout
5161 bbl
5162 \end_layout
5163
5164 \end_inset
5165
5166  files generated by Bib\SpecialChar TeX
5167 .
5168  On the other hand, \SpecialChar LaTeX
5169  is a very hard language to parse—it is sometimes said
5170  that only \SpecialChar TeX
5171  itself understands \SpecialChar TeX
5172 —and \SpecialChar LaTeX
5173 -based converters will often choke on
5174  what seem to be quite simple constructs; complex ones can throw them completely
5175 , and as of this writing, for example, the 
5176 \emph on
5177 Embedded Objects
5178 \emph default
5179  manual will not export with 
5180 \begin_inset Flex Code
5181 status collapsed
5182
5183 \begin_layout Plain Layout
5184 htlatex
5185 \end_layout
5186
5187 \end_inset
5188
5189 , though the others will.
5190  The other issue concerns how math is handled.
5191  These converters typically convert the formulae into little pictures that
5192  are then linked from the HTML document.
5193  Since these are actually generated by \SpecialChar LaTeX
5194 , they are accurate.
5195  But they do not scale well, and just getting them to look as if they are
5196  actually meant to be in your document—so that the font sizes seem to be
5197  roughly the same—can be a challenge.
5198 \end_layout
5199
5200 \begin_layout Standard
5201 Alex Fernandez's 
5202 \begin_inset Flex Code
5203 status collapsed
5204
5205 \begin_layout Plain Layout
5206 e\SpecialChar LyX
5207 er
5208 \end_layout
5209
5210 \end_inset
5211
5212  (
5213 \begin_inset CommandInset href
5214 LatexCommand href
5215 name "http://pinchito.es/elyxer/"
5216 target "http://pinchito.es/elyxer/"
5217 literal "false"
5218
5219 \end_inset
5220
5221 ) solves some of these problems.
5222  In particular, the formulae it produces scale perfectly, since it renders
5223  math using a combination of HTML and CSS rather than converting the formulae
5224  to images.
5225  But even moderately complex formula are rendered less well than with 
5226 \begin_inset Flex Code
5227 status collapsed
5228
5229 \begin_layout Plain Layout
5230 htlatex
5231 \end_layout
5232
5233 \end_inset
5234
5235 ; this reflects the limitations of HTML.
5236 \begin_inset Foot
5237 status collapsed
5238
5239 \begin_layout Plain Layout
5240 That said, 
5241 \begin_inset Flex Code
5242 status collapsed
5243
5244 \begin_layout Plain Layout
5245 e\SpecialChar LyX
5246 er
5247 \end_layout
5248
5249 \end_inset
5250
5251  can also use jsMath and MathJax for equations, but this setting is only
5252  available globally and requires one to have access to a server that runs
5253  the backend.
5254 \end_layout
5255
5256 \end_inset
5257
5258  More importantly (as of version 1.1.1, at least), 
5259 \begin_inset Flex Code
5260 status collapsed
5261
5262 \begin_layout Plain Layout
5263 e\SpecialChar LyX
5264 er
5265 \end_layout
5266
5267 \end_inset
5268
5269  has limited support for math macros and no support for user-defined paragraph
5270  or character styles.
5271  These limitations make 
5272 \begin_inset Flex Code
5273 status collapsed
5274
5275 \begin_layout Plain Layout
5276 e\SpecialChar LyX
5277 er
5278 \end_layout
5279
5280 \end_inset
5281
5282  unsuitable for many of the documents \SpecialChar LyX
5283  users produce.
5284  In principle, of course, these problems could be solved, but the \SpecialChar LyX
5285  developers
5286  have decided to follow a different path and have made \SpecialChar LyX
5287  itself capable of
5288  writing XHTML, just as it is capable of writing \SpecialChar LaTeX
5289 , DocBook, and plaintext.
5290 \end_layout
5291
5292 \begin_layout Standard
5293 As of this writing, XHTML output remains under development and should probably
5294  be regarded as 
5295 \begin_inset Quotes eld
5296 \end_inset
5297
5298 experimental
5299 \begin_inset Quotes erd
5300 \end_inset
5301
5302 .
5303 \begin_inset Foot
5304 status collapsed
5305
5306 \begin_layout Plain Layout
5307 The file 
5308 \begin_inset Flex Code
5309 status collapsed
5310
5311 \begin_layout Plain Layout
5312 development/HTML/HTML.notes
5313 \end_layout
5314
5315 \end_inset
5316
5317 , which can be found in the \SpecialChar LyX
5318  source tree or 
5319 \begin_inset CommandInset href
5320 LatexCommand href
5321 name "accessed online"
5322 target "https://www.lyx.org/trac/browser/lyxgit/development/HTML/HTML.notes?rev=master"
5323 literal "false"
5324
5325 \end_inset
5326
5327 , usually contains up-to-date information about the state of XHTML output.
5328  See also the list of XHTML bugs on 
5329 \begin_inset CommandInset href
5330 LatexCommand href
5331 name "the bug tracker"
5332 target "https://www.lyx.org/trac/query?status=reopened&status=assigned&status=new&max=0&component=xhtml+export&order=id&col=id&col=summary&col=reporter&col=keywords&keywords=%21%7Efixedintrunk&desc=1"
5333 literal "false"
5334
5335 \end_inset
5336
5337 .
5338 \end_layout
5339
5340 \end_inset
5341
5342  Still, the developers have chosen this approach because it has several
5343  potential advantages over the other two.
5344 \end_layout
5345
5346 \begin_layout Standard
5347 These advantages are primarily due to the fact that the XHTML output routines,
5348  since they are part of \SpecialChar LyX
5349 , know everything \SpecialChar LyX
5350  knows about the document being
5351  exported.
5352 \begin_inset Foot
5353 status collapsed
5354
5355 \begin_layout Plain Layout
5356 Another advantage is that, since these routines are internal to \SpecialChar LyX
5357 , they are
5358  immune to changes in \SpecialChar LyX
5359 's file format, or to changes in the semantics of
5360  existing insets.
5361 \end_layout
5362
5363 \end_inset
5364
5365  So they know about the table of contents (as displayed in the outline),
5366  about the counters associated with different paragraph styles, and about
5367  user-defined styles.
5368  The XHTML output routines know what \SpecialChar LyX
5369  knows about internationalization,
5370  too, so they will output 
5371 \begin_inset Quotes eld
5372 \end_inset
5373
5374 Chapter 1
5375 \begin_inset Quotes erd
5376 \end_inset
5377
5378  or 
5379 \begin_inset Quotes eld
5380 \end_inset
5381
5382
5383 \lang ngerman
5384 Kapitel
5385 \lang english
5386  1
5387 \begin_inset Quotes erd
5388 \end_inset
5389
5390 , depending upon the language in effect at the time.
5391  
5392 \end_layout
5393
5394 \begin_layout Standard
5395 Quite generally, the output routines know what \SpecialChar LyX
5396  knows about document layout,
5397  that is, about how the document is to be rendered on screen.
5398  We use this information when we output the document as XHTML.
5399  In particular, \SpecialChar LyX
5400  
5401 \emph on
5402 automatically
5403 \emph default
5404  generates CSS style information corresponding to the layout information
5405  it uses to render the document on screen: if section headings are supposed
5406  to be sans-serif and bold as seen in \SpecialChar LyX
5407 , then (by default) they will be sans-seri
5408 f and bold when viewed in a web browser, too.
5409  And this is true not just for pre-defined styles, like Section, but for
5410  any style, including user-defined styles.
5411  Indeed, the XHTML output routines make no distinction between user-defined
5412  paragraph and character styles and \SpecialChar LyX
5413 's own pre-defined styles: in each case,
5414  everything \SpecialChar LyX
5415  knows about the styles is contained in the layout files.
5416  And much the same is true as regards pre-defined textual insets, such as
5417  footnotes, and various custom insets.
5418  
5419 \end_layout
5420
5421 \begin_layout Standard
5422 The result is that XHTML output can be customized and extended in exactly
5423  the same way \SpecialChar LaTeX
5424  output can be customized and extended: through layout files
5425  and modules.
5426  See chapter five of the 
5427 \emph on
5428 Customization 
5429 \emph default
5430 manual for the details.
5431 \end_layout
5432
5433 \begin_layout Standard
5434 The remainder of this chapter contains more detailed information on XHTML
5435  output, its limitations, and ways to work around those limitations.
5436 \end_layout
5437
5438 \begin_layout Section
5439 Math Output in XHTML
5440 \end_layout
5441
5442 \begin_layout Standard
5443 \SpecialChar LyX
5444  offers four choices for how math is rendered.
5445  These have various advantages and disadvantages:
5446 \end_layout
5447
5448 \begin_layout Itemize
5449 MathML
5450 \begin_inset Newline newline
5451 \end_inset
5452
5453 MathML is a dialect of XML designed specifically for mathematics on the
5454  web, and it typically renders very well in browsers that support it.
5455  The disadvantage is that not all browsers support MathML, and support is
5456  not complete even in the Gecko-based browsers, such as Firefox.
5457 \begin_inset Newline newline
5458 \end_inset
5459
5460 If \SpecialChar LyX
5461  is unable to render a formula as MathML—for example, if the formula
5462  uses the 
5463 \begin_inset Flex Code
5464 status collapsed
5465
5466 \begin_layout Plain Layout
5467 xymatrix
5468 \end_layout
5469
5470 \end_inset
5471
5472  package or ERT—then it will instead output the formula as an image.
5473  
5474 \end_layout
5475
5476 \begin_layout Itemize
5477 HTML
5478 \begin_inset Newline newline
5479 \end_inset
5480
5481 As mentioned above, 
5482 \begin_inset Flex Code
5483 status collapsed
5484
5485 \begin_layout Plain Layout
5486 elyxer
5487 \end_layout
5488
5489 \end_inset
5490
5491  outputs math as HTML, styled by CSS.
5492 \begin_inset Foot
5493 status collapsed
5494
5495 \begin_layout Plain Layout
5496 \SpecialChar LyX
5497  has borrowed some of the CSS for its HTML output from 
5498 \begin_inset Flex Code
5499 status collapsed
5500
5501 \begin_layout Plain Layout
5502 elyxer
5503 \end_layout
5504
5505 \end_inset
5506
5507 .
5508 \end_layout
5509
5510 \end_inset
5511
5512  For simple formulae, this can work quite well, though with more complicated
5513  formulae it tends to break down.
5514  Still, this method has the advantage that it is very widely supported and
5515  so it may be appropriate for documents that contain only a little, fairly
5516  simple math.
5517 \begin_inset Newline newline
5518 \end_inset
5519
5520 If Lyx is unable to render a formula as HTML—for example, if the formula
5521  uses the 
5522 \begin_inset Flex Code
5523 status collapsed
5524
5525 \begin_layout Plain Layout
5526 xymatrix
5527 \end_layout
5528
5529 \end_inset
5530
5531  package or ERT—then it will instead output the formula as an image.
5532  
5533 \end_layout
5534
5535 \begin_layout Itemize
5536 Images
5537 \begin_inset Newline newline
5538 \end_inset
5539
5540 Like 
5541 \begin_inset Flex Code
5542 status collapsed
5543
5544 \begin_layout Plain Layout
5545 htlatex
5546 \end_layout
5547
5548 \end_inset
5549
5550 , \SpecialChar LyX
5551  will output formulae as images, the very same images, in fact, that are
5552  used for instant preview.
5553 \begin_inset Foot
5554 status collapsed
5555
5556 \begin_layout Plain Layout
5557 Instant preview does 
5558 \emph on
5559 not 
5560 \emph default
5561 have to be on for images to be output, however.
5562 \end_layout
5563
5564 \end_inset
5565
5566  The advantage to this method is that the images are simply generated by
5567  \SpecialChar LaTeX
5568 , so they are very accurate.
5569  The disadvantage, as mentioned earlier, is that these are bitmapped images,
5570  so they do not scale terribly well, and one cannot copy them, etc.
5571 \begin_inset Newline newline
5572 \end_inset
5573
5574 The size of the images can be controlled by setting the 
5575 \begin_inset Quotes eld
5576 \end_inset
5577
5578 Math Images Scaling
5579 \begin_inset Quotes erd
5580 \end_inset
5581
5582  parameter under 
5583 \begin_inset Flex Noun
5584 status collapsed
5585
5586 \begin_layout Plain Layout
5587 Document\SpecialChar menuseparator
5588 Settings\SpecialChar menuseparator
5589 Formats
5590 \end_layout
5591
5592 \end_inset
5593
5594 .
5595 \begin_inset Foot
5596 status collapsed
5597
5598 \begin_layout Plain Layout
5599 For those who want to know, this controls the resolution of the image in
5600  dots per inch and is based upon a default of 75 dpi.
5601 \end_layout
5602
5603 \end_inset
5604
5605
5606 \begin_inset Newline newline
5607 \end_inset
5608
5609 If \SpecialChar LyX
5610  for some reason fails to create an image for a formula (e.g., if a required
5611  \SpecialChar LaTeX
5612  package is not installed), then it will fall back to outputing the raw
5613  \SpecialChar LaTeX
5614 .
5615 \end_layout
5616
5617 \begin_layout Itemize
5618 \SpecialChar LaTeX
5619
5620 \begin_inset Newline newline
5621 \end_inset
5622
5623 Finally, \SpecialChar LyX
5624  will happily output math as \SpecialChar LaTeX
5625 .
5626  As well as being the output of last resort, this method can be used with
5627  such tools as 
5628 \begin_inset CommandInset href
5629 LatexCommand href
5630 name "jsMath"
5631 target "http://www.math.union.edu/~dpvc/jsMath/"
5632 literal "false"
5633
5634 \end_inset
5635
5636 , which uses JavaScript to render \SpecialChar LaTeX
5637  embedded in HTML documents.
5638  \SpecialChar LyX
5639  wraps the \SpecialChar LaTeX
5640  in either a 
5641 \begin_inset Flex Code
5642 status collapsed
5643
5644 \begin_layout Plain Layout
5645 span
5646 \end_layout
5647
5648 \end_inset
5649
5650  (for inline formulas) or 
5651 \begin_inset Flex Code
5652 status collapsed
5653
5654 \begin_layout Plain Layout
5655 div
5656 \end_layout
5657
5658 \end_inset
5659
5660  (for displayed formulas) with 
5661 \begin_inset Flex Code
5662 status collapsed
5663
5664 \begin_layout Plain Layout
5665 class='math'
5666 \end_layout
5667
5668 \end_inset
5669
5670 , as is required for jsMath.
5671 \end_layout
5672
5673 \begin_layout Standard
5674 One of these output methods must be selected under 
5675 \begin_inset Flex Noun
5676 status collapsed
5677
5678 \begin_layout Plain Layout
5679 Document\SpecialChar menuseparator
5680 Settings\SpecialChar menuseparator
5681 Formats
5682 \end_layout
5683
5684 \end_inset
5685
5686 .
5687  By default, \SpecialChar LyX
5688  outputs MathML.
5689  This is a document-wide setting, therefore.
5690 \end_layout
5691
5692 \begin_layout Standard
5693 Eventually, \SpecialChar LyX
5694  will offer the user the option to select an alternate output
5695  method for a particular inset, say, one that isn't being rendered very
5696  well by MathML.
5697 \begin_inset Foot
5698 status collapsed
5699
5700 \begin_layout Plain Layout
5701 That said, since \SpecialChar LyX
5702  falls back to images if the inset contains ERT, then one
5703  can force output as an image by putting some harmless ERT into the math,
5704  for example: 
5705 \begin_inset Formula $a=b\relax$
5706 \end_inset
5707
5708 .
5709 \end_layout
5710
5711 \end_inset
5712
5713
5714 \end_layout
5715
5716 \begin_layout Section
5717 Bibliography and Citations
5718 \end_layout
5719
5720 \begin_layout Standard
5721 XHTML output fully supports bibliographies and citations.
5722  
5723 \end_layout
5724
5725 \begin_layout Standard
5726 Citation labels are generated by the same machinery that generates \SpecialChar LyX
5727 's on-screen
5728  labels, so the labels will look in the output much as they do in \SpecialChar LyX
5729 , though
5730  better.
5731  If you are using numerical citations, then \SpecialChar LyX
5732  will output numerical labels,
5733  such as [1] or [17], rather than simply showing the citation key in square
5734  brackets, as it does on-screen.
5735  If you are using author-year citations, then \SpecialChar LyX
5736  will add lowercase letters
5737  to the years, just as Bib\SpecialChar TeX
5738  does, if it finds more than one citation for
5739  a given author-year combination.
5740  The labels will be printed with the bibliography entries.
5741  Note that there is, at present, no way to customize the appearance of the
5742  labels, for example, to choose between square brackets and parentheses.
5743 \end_layout
5744
5745 \begin_layout Standard
5746 Bibliography output is handled by the same machinery that handles the presentati
5747 on of reference information in the citation dialog, so you will see in the
5748  XHTML output pretty much what you would see if you were to look at a given
5749  entry in the citation dialog.
5750  The formatting can be customized in your layout file or, preferably, in
5751  a module.
5752  See the 
5753 \emph on
5754 Customization
5755 \emph default
5756  manual for the details.
5757 \end_layout
5758
5759 \begin_layout Standard
5760 The main defect at present is that cross-referenced information is printed
5761  with every entry with which it is associated.
5762  So you can see things like this:
5763 \end_layout
5764
5765 \begin_layout Quote
5766 Jason Stanley, 
5767 \begin_inset Quotes eld
5768 \end_inset
5769
5770 Context and Logical Form
5771 \begin_inset Quotes erd
5772 \end_inset
5773
5774 , in 
5775 \emph on
5776 Language in Context: Selected Essays
5777 \emph default
5778  (Oxford: Oxford University Press, 2007), pp.
5779  30–68.
5780 \end_layout
5781
5782 \begin_layout Quote
5783 Jason Stanley, 
5784 \begin_inset Quotes eld
5785 \end_inset
5786
5787 Semantics in Context
5788 \begin_inset Quotes erd
5789 \end_inset
5790
5791 , in 
5792 \emph on
5793 Language in Context: Selected Essays
5794 \emph default
5795  (Oxford: Oxford University Press, 2007), pp.
5796  201–30.
5797 \end_layout
5798
5799 \begin_layout Standard
5800 This should be fixed before long.
5801 \end_layout
5802
5803 \begin_layout Standard
5804 There is no support at present for sectioned bibliographies.
5805  If you have multiple bibliographies, then \SpecialChar LyX
5806  will print the same bibliography
5807  over and over.
5808 \end_layout
5809
5810 \begin_layout Section
5811 Indexes
5812 \end_layout
5813
5814 \begin_layout Standard
5815 \SpecialChar LyX
5816  will happily export indexes as XHTML, but with certain limitations at the
5817  moment.
5818 \end_layout
5819
5820 \begin_layout Standard
5821 Index export will be most reliable when you do not attempt to use the fancy
5822  constructs that are described in the section on indexes in the 
5823 \emph on
5824 User's Guide
5825 \emph default
5826 .
5827 \begin_inset Foot
5828 status collapsed
5829
5830 \begin_layout Plain Layout
5831 The main issue here is that \SpecialChar LyX
5832  itself does not really handle these.
5833  It just lets you enter what you would have to enter in raw \SpecialChar LaTeX
5834 .
5835 \end_layout
5836
5837 \end_inset
5838
5839  We'll describe how they are handled using the subsection headings from
5840  that section.
5841 \end_layout
5842
5843 \begin_layout Itemize
5844 Grouping Index Entries (aka, sub-entries): \SpecialChar LyX
5845  makes an effort to support these,
5846  but the entries must be separated by 
5847 \begin_inset Quotes eld
5848 \end_inset
5849
5850  ! 
5851 \begin_inset Quotes erd
5852 \end_inset
5853
5854 , that is, there must be spaces around the exclamation point.
5855  This is because it is otherwise too difficult to check for escaped exclamation
5856  points, ones in math, and so forth.
5857 \end_layout
5858
5859 \begin_layout Itemize
5860 Page Ranges: There is no support at all for page ranges, since these make
5861  no sense with XHMTL.
5862  Instead, you will just get two index entries, one at either end.
5863 \end_layout
5864
5865 \begin_layout Itemize
5866 Cross-referencing: There is no support for cross-referencing.
5867  If \SpecialChar LyX
5868  finds an entry containing the 
5869 \begin_inset Quotes eld
5870 \end_inset
5871
5872 |see\SpecialChar ldots
5873
5874 \begin_inset Quotes erd
5875 \end_inset
5876
5877  construct, it is just dropped, and the rest is treated as an ordinary index
5878  entry.
5879 \end_layout
5880
5881 \begin_layout Itemize
5882 Index Entry Order: \SpecialChar LyX
5883  does support attempts to fix the sorting order.
5884  It will take what is before the first `@' it finds and use that for sorting,
5885  taking what follows the first `@' to be the actual entry.
5886  At present, \SpecialChar LyX
5887  does not check for escaped `@', so do not try to index email
5888  addresses.
5889 \end_layout
5890
5891 \begin_layout Itemize
5892 Index Entry Layout: You can format entries by using the text style dialog,
5893  or by using any other method available within \SpecialChar LyX
5894  itself.
5895  There is no support for constructs like: 
5896 \begin_inset Quotes eld
5897 \end_inset
5898
5899 entry|textbf
5900 \begin_inset Quotes erd
5901 \end_inset
5902
5903 .
5904  Indeed, if \SpecialChar LyX
5905  finds a pipe symbol, `|', in an entry, it will delete it and
5906  everything that follows it.
5907 \end_layout
5908
5909 \begin_layout Itemize
5910 Multiple Indexes: There is no support for multiple indexes.
5911  Rather, all index entries will be printed as one large index.
5912  To avoid our printing several versions of the index, we print only the
5913  main index, so make sure you have one.
5914 \end_layout
5915
5916 \begin_layout Section
5917 Nomenclature and Glossary
5918 \end_layout
5919
5920 \begin_layout Standard
5921 There is at present no support for glossaries.
5922  Adding it would be fairly trivial, and welcome.
5923 \end_layout
5924
5925 \begin_layout Chapter
5926 The \SpecialChar LyX
5927  Server
5928 \end_layout
5929
5930 \begin_layout Section
5931 Introduction
5932 \end_layout
5933
5934 \begin_layout Standard
5935 The `\SpecialChar LyX
5936  server' allows other programs to talk to \SpecialChar LyX
5937 , invoke \SpecialChar LyX
5938  commands, and retrieve
5939  information about the \SpecialChar LyX
5940  internal state.
5941  This is only intended for advanced users, but they should find it useful.
5942  It is by writing to the \SpecialChar LyX
5943  server, for example, that bibliography managers,
5944  such as JabRef, are able to 
5945 \begin_inset Quotes eld
5946 \end_inset
5947
5948 push
5949 \begin_inset Quotes erd
5950 \end_inset
5951
5952  citations to \SpecialChar LyX
5953 .
5954 \end_layout
5955
5956 \begin_layout Section
5957 Starting the \SpecialChar LyX
5958  Server
5959 \begin_inset CommandInset label
5960 LatexCommand label
5961 name "sec:Starting-the-Server"
5962
5963 \end_inset
5964
5965
5966 \end_layout
5967
5968 \begin_layout Standard
5969 The \SpecialChar LyX
5970  server works through the use of a pair of named pipes.
5971  These are usually located in 
5972 \begin_inset Flex Code
5973 status collapsed
5974
5975 \begin_layout Plain Layout
5976 UserDir
5977 \end_layout
5978
5979 \end_inset
5980
5981 , (except on Windows, where 
5982 \emph on
5983 local
5984 \emph default
5985  named pipes are special objects located in 
5986 \begin_inset Flex Code
5987 status collapsed
5988
5989 \begin_layout Plain Layout
5990
5991 \backslash
5992
5993 \backslash
5994 .
5995 \backslash
5996 pipe
5997 \end_layout
5998
5999 \end_inset
6000
6001 ) and have the names 
6002 \begin_inset Quotes eld
6003 \end_inset
6004
6005
6006 \begin_inset Flex Code
6007 status collapsed
6008
6009 \begin_layout Plain Layout
6010 lyxpipe.in
6011 \end_layout
6012
6013 \end_inset
6014
6015
6016 \begin_inset Quotes erd
6017 \end_inset
6018
6019  and 
6020 \begin_inset Quotes eld
6021 \end_inset
6022
6023
6024 \begin_inset Flex Code
6025 status collapsed
6026
6027 \begin_layout Plain Layout
6028 lyxpipe.out
6029 \end_layout
6030
6031 \end_inset
6032
6033
6034 \begin_inset Quotes erd
6035 \end_inset
6036
6037 .
6038  External programs write into 
6039 \begin_inset Flex Code
6040 status collapsed
6041
6042 \begin_layout Plain Layout
6043 lyxpipe.in
6044 \end_layout
6045
6046 \end_inset
6047
6048  and read back data from 
6049 \begin_inset Flex Code
6050 status collapsed
6051
6052 \begin_layout Plain Layout
6053 lyxpipe.out
6054 \end_layout
6055
6056 \end_inset
6057
6058 .
6059  The stem of the pipe names can be defined in the 
6060 \begin_inset Flex Noun
6061 status collapsed
6062
6063 \begin_layout Plain Layout
6064 Tools\SpecialChar menuseparator
6065 Preferences
6066 \end_layout
6067
6068 \end_inset
6069
6070  dialog, for example 
6071 \begin_inset Flex Code
6072 status collapsed
6073
6074 \begin_layout Plain Layout
6075 "/home/myhome/lyxpipe"
6076 \end_layout
6077
6078 \end_inset
6079
6080 , or 
6081 \begin_inset Flex Code
6082 status collapsed
6083
6084 \begin_layout Plain Layout
6085 "
6086 \backslash
6087
6088 \backslash
6089 .
6090 \backslash
6091 pipe
6092 \backslash
6093 lyxpipe"
6094 \end_layout
6095
6096 \end_inset
6097
6098  on Windows (where any working path instead of lyxpipe can be used, for
6099  example 
6100 \begin_inset Flex Code
6101 status collapsed
6102
6103 \begin_layout Plain Layout
6104 "
6105 \backslash
6106
6107 \backslash
6108 .
6109 \backslash
6110 pipe
6111 \backslash
6112 my
6113 \backslash
6114 lyx
6115 \backslash
6116 pipe"
6117 \end_layout
6118
6119 \end_inset
6120
6121  would also work).
6122  You 
6123 \emph on
6124 must
6125 \emph default
6126  configure this manually in order for the server to start.
6127 \end_layout
6128
6129 \begin_layout Standard
6130 \SpecialChar LyX
6131  will add the '
6132 \begin_inset Flex Code
6133 status collapsed
6134
6135 \begin_layout Plain Layout
6136 .in
6137 \end_layout
6138
6139 \end_inset
6140
6141 ' and '
6142 \begin_inset Flex Code
6143 status collapsed
6144
6145 \begin_layout Plain Layout
6146 .out
6147 \end_layout
6148
6149 \end_inset
6150
6151 ' to create the pipes.
6152  If one of the pipes already exists, \SpecialChar LyX
6153  will assume that another \SpecialChar LyX
6154  process
6155  is already running and will not start the server.
6156  On POSIX (Unix like) systems, if for some other reason, an unused 
6157 \begin_inset Quotes eld
6158 \end_inset
6159
6160 stale
6161 \begin_inset Quotes erd
6162 \end_inset
6163
6164  pipe is left in existence when \SpecialChar LyX
6165  closes, then \SpecialChar LyX
6166  will try to delete it.
6167  If this fails for some reason, you will need to delete the pipes manually
6168  and then restart \SpecialChar LyX
6169 .
6170  On Windows, pipes are deleted by the OS on program termination or crash,
6171  so 
6172 \begin_inset Quotes eld
6173 \end_inset
6174
6175 stale
6176 \begin_inset Quotes erd
6177 \end_inset
6178
6179  pipes should not be possible.
6180 \end_layout
6181
6182 \begin_layout Standard
6183 To have several \SpecialChar LyX
6184  processes with servers at the same time, you have to use
6185  different configurations, perhaps by using separate user directories, each
6186  with its own 
6187 \begin_inset Flex Code
6188 status collapsed
6189
6190 \begin_layout Plain Layout
6191 preferences
6192 \end_layout
6193
6194 \end_inset
6195
6196  file, for each process.
6197 \end_layout
6198
6199 \begin_layout Standard
6200 If you are developing a client program, you might find it useful to enable
6201  debugging information from the \SpecialChar LyX
6202  server.
6203  Do this by starting \SpecialChar LyX
6204  as 
6205 \begin_inset Flex Code
6206 status collapsed
6207
6208 \begin_layout Plain Layout
6209 lyx -dbg lyxserver
6210 \end_layout
6211
6212 \end_inset
6213
6214 .
6215 \end_layout
6216
6217 \begin_layout Standard
6218 You can find a complete example client written in C++ in the source distribution
6219  as 
6220 \begin_inset Flex Code
6221 status collapsed
6222
6223 \begin_layout Plain Layout
6224 development/lyxserver/server_monitor.cpp
6225 \end_layout
6226
6227 \end_inset
6228
6229 .
6230 \end_layout
6231
6232 \begin_layout Standard
6233 Another useful tool is the command-line based client found in 
6234 \begin_inset Flex Code
6235 status collapsed
6236
6237 \begin_layout Plain Layout
6238 src/client/lyxclient
6239 \end_layout
6240
6241 \end_inset
6242
6243 .
6244 \end_layout
6245
6246 \begin_layout Section
6247 Normal communication
6248 \end_layout
6249
6250 \begin_layout Standard
6251 To issue a \SpecialChar LyX
6252  call, the client writes a line of ASCII text into the input
6253  pipe.
6254  This line has the following format:
6255 \end_layout
6256
6257 \begin_layout Quote
6258 LYXCMD:
6259 \emph on
6260 clientname
6261 \emph default
6262 :
6263 \emph on
6264 function
6265 \emph default
6266 :
6267 \emph on
6268 argument
6269 \end_layout
6270
6271 \begin_layout Description
6272 clientname is a name that the client can choose arbitrarily.
6273  Its only use is that \SpecialChar LyX
6274  will echo it if it sends an answer—so a client can
6275  dispatch results from different requesters.
6276 \end_layout
6277
6278 \begin_layout Description
6279 function is the function you want \SpecialChar LyX
6280  to perform.
6281  It is the same as the commands you'd use in the minibuffer.
6282 \end_layout
6283
6284 \begin_layout Description
6285 argument is an optional argument which is meaningful only to some functions
6286  (for instance, the 
6287 \begin_inset Quotes eld
6288 \end_inset
6289
6290 self-insert
6291 \begin_inset Quotes erd
6292 \end_inset
6293
6294  LFUN will insert the argument as text at the cursor position).
6295 \end_layout
6296
6297 \begin_layout Standard
6298 The answer from \SpecialChar LyX
6299  will arrive in the output pipe and be of the form
6300 \end_layout
6301
6302 \begin_layout Quote
6303 INFO:
6304 \emph on
6305 clientname
6306 \emph default
6307 :
6308 \emph on
6309 function
6310 \emph default
6311 :
6312 \emph on
6313 data
6314 \end_layout
6315
6316 \begin_layout Standard
6317 where 
6318 \emph on
6319 clientname
6320 \emph default
6321  and 
6322 \emph on
6323 function
6324 \emph default
6325  are just echoed from the command request, while 
6326 \emph on
6327 data
6328 \emph default
6329  is more or less useful information filled according to how the command
6330  execution worked out.
6331  Some commands, such as 
6332 \begin_inset Quotes eld
6333 \end_inset
6334
6335 font-state
6336 \begin_inset Quotes erd
6337 \end_inset
6338
6339 , will return information about the internal state of \SpecialChar LyX
6340 , while other will
6341  return an empty data-response.
6342  This means that the command execution went fine.
6343 \end_layout
6344
6345 \begin_layout Standard
6346 In case of errors, the response from \SpecialChar LyX
6347  will have this form
6348 \end_layout
6349
6350 \begin_layout Quote
6351 ERROR:
6352 \emph on
6353 clientname
6354 \emph default
6355 :
6356 \emph on
6357 function
6358 \emph default
6359 :
6360 \emph on
6361 error message
6362 \end_layout
6363
6364 \begin_layout Standard
6365 where the 
6366 \emph on
6367 error message
6368 \emph default
6369  should contain an explanation of why the command failed.
6370 \end_layout
6371
6372 \begin_layout Standard
6373 Examples:
6374 \end_layout
6375
6376 \begin_layout LyX-Code
6377 echo "LYXCMD:test:beginning-of-buffer:" >~/.lyxpipe.in
6378 \begin_inset Newline newline
6379 \end_inset
6380
6381 echo "LYXCMD:test:get-xy:" >~/.lyxpipe.in
6382 \begin_inset Newline newline
6383 \end_inset
6384
6385 read a <~/.lyxpipe.out
6386 \begin_inset Newline newline
6387 \end_inset
6388
6389 echo $a
6390 \end_layout
6391
6392 \begin_layout Subsection
6393 AppleScript (Mac OS X)
6394 \end_layout
6395
6396 \begin_layout Standard
6397 Since \SpecialChar LyX
6398  2.1, \SpecialChar LyX
6399  supports basic interactions with AppleScript for normal communicatio
6400 n through the command run.
6401  This command takes a direct argument (the 
6402 \series bold
6403 function
6404 \series default
6405  to perform) and an optional argument.
6406  It either returns the output of the function or triggers an error with
6407  the error message and code.
6408 \end_layout
6409
6410 \begin_layout Standard
6411 Example:
6412 \end_layout
6413
6414 \begin_layout LyX-Code
6415 tell application "\SpecialChar LyX
6416 "
6417 \end_layout
6418
6419 \begin_layout LyX-Code
6420   try
6421 \end_layout
6422
6423 \begin_layout LyX-Code
6424     -- Stores the current file name into f
6425 \end_layout
6426
6427 \begin_layout LyX-Code
6428     set f to (run "server-get-filename" with argument "")
6429 \end_layout
6430
6431 \begin_layout LyX-Code
6432     on error the error_message number the error_number
6433 \end_layout
6434
6435 \begin_layout LyX-Code
6436       display dialog "Error: " & the error_number & ".
6437  " Â¬
6438 \end_layout
6439
6440 \begin_layout LyX-Code
6441               & the error_message buttons {"OK"} default button 1
6442 \end_layout
6443
6444 \begin_layout LyX-Code
6445   end try
6446 \end_layout
6447
6448 \begin_layout LyX-Code
6449 end tell
6450 \end_layout
6451
6452 \begin_layout Section
6453 Notification
6454 \end_layout
6455
6456 \begin_layout Standard
6457 \SpecialChar LyX
6458  can notify clients of events going on asynchronously.
6459  Currently it will only do this if the user binds a key sequence with the
6460  function 
6461 \begin_inset Quotes eld
6462 \end_inset
6463
6464 notify
6465 \begin_inset Quotes erd
6466 \end_inset
6467
6468 .
6469  The format of the string \SpecialChar LyX
6470  sends is as follows:
6471 \end_layout
6472
6473 \begin_layout Quote
6474 \begin_inset Flex Code
6475 status collapsed
6476
6477 \begin_layout Plain Layout
6478 NOTIFY:
6479 \end_layout
6480
6481 \end_inset
6482
6483
6484 \emph on
6485 key-sequence
6486 \end_layout
6487
6488 \begin_layout Standard
6489 where 
6490 \emph on
6491 key-sequence
6492 \emph default
6493  is the printed representation of the key sequence that was actually typed
6494  by the user.
6495 \end_layout
6496
6497 \begin_layout Standard
6498 This mechanism can be used to extend \SpecialChar LyX
6499 's command set and implement macros.
6500  Bind some key sequence to 
6501 \begin_inset Quotes eld
6502 \end_inset
6503
6504 notify
6505 \begin_inset Quotes erd
6506 \end_inset
6507
6508 .
6509  Then start a client that listens on the output pipe, dispatches the command
6510  according to the sequence, and starts a function that may use \SpecialChar LyX
6511  calls and
6512  \SpecialChar LyX
6513  requests to issue a command or a series of commands to \SpecialChar LyX
6514 .
6515 \end_layout
6516
6517 \begin_layout Section
6518 The simple \SpecialChar LyX
6519  Server Protocol
6520 \end_layout
6521
6522 \begin_layout Standard
6523 \SpecialChar LyX
6524  implements a simple protocol that can be used for session management.
6525  All messages are of the form
6526 \end_layout
6527
6528 \begin_layout Quote
6529 LYXSRV:
6530 \emph on
6531 clientname
6532 \emph default
6533 :
6534 \emph on
6535 protocol message
6536 \end_layout
6537
6538 \begin_layout Standard
6539 where 
6540 \emph on
6541 protocol message
6542 \emph default
6543  can be 
6544 \begin_inset Quotes eld
6545 \end_inset
6546
6547 hello
6548 \begin_inset Quotes erd
6549 \end_inset
6550
6551  or 
6552 \begin_inset Quotes eld
6553 \end_inset
6554
6555 bye
6556 \begin_inset Quotes erd
6557 \end_inset
6558
6559 .
6560  If 
6561 \begin_inset Quotes eld
6562 \end_inset
6563
6564 hello
6565 \begin_inset Quotes erd
6566 \end_inset
6567
6568  is received from a client, \SpecialChar LyX
6569  will report back to inform the client that
6570  it's listening to it's messages, while 
6571 \begin_inset Quotes eld
6572 \end_inset
6573
6574 bye
6575 \begin_inset Quotes erd
6576 \end_inset
6577
6578  sent from \SpecialChar LyX
6579  will inform clients that \SpecialChar LyX
6580  is closing.
6581 \end_layout
6582
6583 \begin_layout Section
6584 Reverse DVI/PDF search
6585 \end_layout
6586
6587 \begin_layout Standard
6588 Some DVI/PDF viewers
6589 \begin_inset Foot
6590 status collapsed
6591
6592 \begin_layout Plain Layout
6593 The following viewers offer the reverse PDF search feature: Okular on KDE/Linux,
6594  Qpdfview on Unix, Skim on Mac OSX and SumatraPDF on Windows.
6595 \end_layout
6596
6597 \end_inset
6598
6599  provide 
6600 \emph on
6601 reverse search
6602 \emph default
6603  facility (also called 
6604 \emph on
6605 inverse search
6606 \emph default
6607 ).
6608  This means that you can tell \SpecialChar LyX
6609  to put the cursor to a specific line in the
6610  document by clicking at the respective position in the DVI/PDF output.
6611  To achieve this, the viewer must be able to communicate with \SpecialChar LyX
6612 .
6613  This is done via the \SpecialChar LyX
6614  server either by using the named pipe (
6615 \emph on
6616 lyxpipe
6617 \emph default
6618 ), or the UNIX domain socket (
6619 \emph on
6620 lyxsocket
6621 \emph default
6622 ) that \SpecialChar LyX
6623  creates in its temporary directory (this is the way the 
6624 \begin_inset Flex Code
6625 status collapsed
6626
6627 \begin_layout Plain Layout
6628 lyxclient
6629 \end_layout
6630
6631 \end_inset
6632
6633  program communicates with \SpecialChar LyX
6634 ).
6635  In some cases, you need a helper script that mediates between the viewer
6636  and \SpecialChar LyX
6637 , in others, the viewer can communicate with \SpecialChar LyX
6638  directly.
6639  This depends on the selected viewer and on your operating system.
6640  The same applies to the way viewers need to be configured and the way the
6641  reverse search is actually performed.
6642  In what follows, we will thus describe how to setup reverse search for
6643  specific viewers.
6644  Before we turn to this, though, we will explain what needs to be done generally
6645  to enable reverse search in the DVI/PDF output.
6646 \end_layout
6647
6648 \begin_layout Subsection
6649 Automatic setup
6650 \begin_inset CommandInset label
6651 LatexCommand label
6652 name "subsec:rev-search"
6653
6654 \end_inset
6655
6656
6657 \end_layout
6658
6659 \begin_layout Standard
6660 In most cases \SpecialChar LyX
6661  will do the work for you by pressing the following button
6662  in the toolbar: 
6663 \begin_inset Info
6664 type  "icon"
6665 arg   "buffer-toggle-output-sync"
6666 \end_inset
6667
6668 .
6669  Alternatively, you can also enable the feature by checking 
6670 \family sans
6671 Synchronize with Output
6672 \family default
6673  in 
6674 \begin_inset Flex Noun
6675 status collapsed
6676
6677 \begin_layout Plain Layout
6678 Document\SpecialChar menuseparator
6679 Settings\SpecialChar menuseparator
6680 Formats
6681 \end_layout
6682
6683 \end_inset
6684
6685 .
6686  In such a case \SpecialChar LyX
6687  will automatically insert the necessary Sync\SpecialChar TeX
6688  macro (for
6689  PDF) or load the srcltx package (for DVI) respectively.
6690  This option can be easily reached also on 
6691 \begin_inset Flex Code
6692 status collapsed
6693
6694 \begin_layout Plain Layout
6695 View/Update
6696 \end_layout
6697
6698 \end_inset
6699
6700  Toolbar.
6701 \end_layout
6702
6703 \begin_layout Standard
6704 If you need a different setting, you can select or input a custom macro
6705  from the drop down box just below 
6706 \begin_inset Flex Noun
6707 status collapsed
6708
6709 \begin_layout Plain Layout
6710 Document\SpecialChar menuseparator
6711 Settings\SpecialChar menuseparator
6712 Output\SpecialChar menuseparator
6713 Synchronize with Output
6714 \end_layout
6715
6716 \end_inset
6717
6718 .
6719 \end_layout
6720
6721 \begin_layout Standard
6722 Note that the method 
6723 \begin_inset Flex Code
6724 status collapsed
6725
6726 \begin_layout Plain Layout
6727
6728 \backslash
6729 synctex=1
6730 \end_layout
6731
6732 \end_inset
6733
6734  enables gzip compression.
6735  If your viewer does not support it, you should instead use 
6736 \begin_inset Flex Code
6737 status collapsed
6738
6739 \begin_layout Plain Layout
6740
6741 \backslash
6742 synctex=-1
6743 \end_layout
6744
6745 \end_inset
6746
6747 .
6748 \end_layout
6749
6750 \begin_layout Standard
6751 Please also note that including the 
6752 \begin_inset Flex Code
6753 status collapsed
6754
6755 \begin_layout Plain Layout
6756 srcltx
6757 \end_layout
6758
6759 \end_inset
6760
6761  package or 
6762 \begin_inset Flex Code
6763 status collapsed
6764
6765 \begin_layout Plain Layout
6766 src-specials
6767 \end_layout
6768
6769 \end_inset
6770
6771  sometimes has an undesired impact on the typesetting.
6772  Thus, you should switch output synchronization off for the final typesetting
6773  if you use the 
6774 \begin_inset Flex Code
6775 status collapsed
6776
6777 \begin_layout Plain Layout
6778 srcltx
6779 \end_layout
6780
6781 \end_inset
6782
6783  package or 
6784 \begin_inset Flex Code
6785 status collapsed
6786
6787 \begin_layout Plain Layout
6788 src-specials
6789 \end_layout
6790
6791 \end_inset
6792
6793 .
6794  
6795 \end_layout
6796
6797 \begin_layout Standard
6798 In case you need some more special settings that are not covered by the
6799  automatic settings, read the next section about how to set up output synchroniz
6800 ation manually.
6801  If the automatic setup suits your needs, you can readily jump to section
6802 \begin_inset space ~
6803 \end_inset
6804
6805
6806 \begin_inset CommandInset ref
6807 LatexCommand ref
6808 reference "subsec:configuring-viewers"
6809
6810 \end_inset
6811
6812 , where the necessary configuration steps in your viewer â€“ needed both with
6813  the automatic and the manual setup â€“ are described.
6814 \end_layout
6815
6816 \begin_layout Subsection
6817 Manual setup
6818 \end_layout
6819
6820 \begin_layout Standard
6821 \SpecialChar LaTeX
6822  provides several different methods for reverse search.
6823  Some are built-in in the 
6824 \begin_inset Flex Code
6825 status collapsed
6826
6827 \begin_layout Plain Layout
6828 latex/pdflatex
6829 \end_layout
6830
6831 \end_inset
6832
6833  program, some are provided by external packages.
6834  Your choice depends on whether your \SpecialChar LaTeX
6835  distribution already provides a given
6836  method (the built-in methods are rather new) and whether your viewer can
6837  cope with it.
6838  The available methods are described in the following.
6839 \end_layout
6840
6841 \begin_layout Subsubsection*
6842 Built-in DVI-search via src-specials (DVI only) 
6843 \end_layout
6844
6845 \begin_layout Standard
6846 This method provides the DVI file with the necessary information for reverse
6847  search.
6848  It is available in \SpecialChar LaTeX
6849  since quite some time (any somewhat recent \SpecialChar LaTeX
6850  distribution
6851  should include it), and it works reliably.
6852  To enable it, change the 
6853 \begin_inset Flex Noun
6854 status collapsed
6855
6856 \begin_layout Plain Layout
6857 La
6858 \family sans
6859 TeX
6860 \family default
6861  (plain)->DVI
6862 \end_layout
6863
6864 \end_inset
6865
6866  or 
6867 \begin_inset Flex Noun
6868 status collapsed
6869
6870 \begin_layout Plain Layout
6871 La
6872 \family sans
6873 TeX
6874 \family default
6875  (plain)->DraftDVI
6876 \end_layout
6877
6878 \end_inset
6879
6880  converter in 
6881 \begin_inset Flex Noun
6882 status collapsed
6883
6884 \begin_layout Plain Layout
6885 Preferences\SpecialChar menuseparator
6886 File Handling\SpecialChar menuseparator
6887 Converters
6888 \end_layout
6889
6890 \end_inset
6891
6892  to 
6893 \begin_inset Flex Code
6894 status collapsed
6895
6896 \begin_layout Plain Layout
6897 latex -src-specials $$i
6898 \end_layout
6899
6900 \end_inset
6901
6902 .
6903  If this doesn't work, check if your \SpecialChar TeX
6904  engine needs different options (the
6905  syntax might differ in some distributions).
6906 \end_layout
6907
6908 \begin_layout Subsubsection*
6909 External Packages (PDFSync and scrltx) 
6910 \end_layout
6911
6912 \begin_layout Standard
6913 The packages 
6914 \emph on
6915 pdfsync
6916 \emph default
6917  and 
6918 \emph on
6919 scrltx
6920 \emph default
6921  provide reverse search facility for PDF output (via pdflatex) and DVI output,
6922  respectively.
6923  In order to enable it, load the packages in the \SpecialChar LyX
6924  preamble: 
6925 \end_layout
6926
6927 \begin_layout Itemize
6928 \begin_inset Flex Code
6929 status collapsed
6930
6931 \begin_layout Plain Layout
6932
6933 \backslash
6934 usepackage{pdfsync}
6935 \end_layout
6936
6937 \end_inset
6938
6939  for reverse PDF search,
6940 \end_layout
6941
6942 \begin_layout Itemize
6943 \begin_inset Flex Code
6944 status collapsed
6945
6946 \begin_layout Plain Layout
6947
6948 \backslash
6949 usepackage[active]{srcltx}
6950 \end_layout
6951
6952 \end_inset
6953
6954  for reverse DVI search.
6955 \end_layout
6956
6957 \begin_layout Standard
6958 If you want to be able to perform both DVI and PDF reverse searches, you
6959  can also insert in the preamble the following lines
6960 \end_layout
6961
6962 \begin_layout LyX-Code
6963
6964 \backslash
6965 usepackage{ifpdf}
6966 \begin_inset Newline newline
6967 \end_inset
6968
6969
6970 \backslash
6971 ifpdf
6972 \begin_inset Newline newline
6973 \end_inset
6974
6975   
6976 \backslash
6977 usepackage{pdfsync}
6978 \begin_inset Newline newline
6979 \end_inset
6980
6981
6982 \backslash
6983 else
6984 \begin_inset Newline newline
6985 \end_inset
6986
6987   
6988 \backslash
6989 usepackage[active]{srcltx}
6990 \begin_inset Newline newline
6991 \end_inset
6992
6993
6994 \backslash
6995 fi
6996 \end_layout
6997
6998 \begin_layout Standard
6999 This way, you can preview the file as either DVI or PDF (pdflatex) and the
7000  right package will be used.
7001 \end_layout
7002
7003 \begin_layout Standard
7004 Note that PDFSync might affect the output layout of your document.
7005  It is therefore advised to disable PDFsync for final documents.
7006 \end_layout
7007
7008 \begin_layout Subsubsection*
7009 Built-in reverse search via Sync\SpecialChar TeX
7010  (DVI and PDF) 
7011 \end_layout
7012
7013 \begin_layout Standard
7014 Recent versions of 
7015 \begin_inset Flex Code
7016 status collapsed
7017
7018 \begin_layout Plain Layout
7019 (pdf)latex
7020 \end_layout
7021
7022 \end_inset
7023
7024  have built-in support for both PDF and DVI reverse search.
7025  This so-called 
7026 \emph on
7027 Sync\SpecialChar TeX
7028
7029 \emph default
7030  facility is basically the result of the integration of the PDFSync package
7031  to the pdftex program and its merge with the 
7032 \emph on
7033 scr-specials
7034 \emph default
7035  approach.
7036  You need at least \SpecialChar TeX
7037 Live 2008 or a recent Mik\SpecialChar TeX
7038  distribution in order to use
7039  it.
7040 \begin_inset Foot
7041 status collapsed
7042
7043 \begin_layout Plain Layout
7044 For some reason, Mik\SpecialChar TeX
7045  does not understand/obey the command \SpecialChar LyX
7046  inserts into
7047  the preamble when you check the "Enable Forward/Reverse Search" button
7048  in the toolbar and does not generate the necessary info.
7049 \end_layout
7050
7051 \begin_layout Plain Layout
7052 The generation of the required info can be forced by changing the converter
7053  "\SpecialChar LaTeX
7054  (pdflatex) -> PDF (pdflatex)" in Preferences->File handling->Converters
7055  from the default "pdflatex $$i" to "pdflatex -synctex=1 $$i" (i.e., by adding
7056  the -synctex=1 switch).
7057 \end_layout
7058
7059 \end_inset
7060
7061  Also note that only a few PDF viewers (such as Okular and Qpdfview on Unix,
7062  Skim on the Mac, SumatraPDF on Windows; see the next section for details)
7063  already provide Sync\SpecialChar TeX
7064  support.
7065 \end_layout
7066
7067 \begin_layout Standard
7068 To enable Sync\SpecialChar TeX
7069  for DVI output, change the 
7070 \begin_inset Flex Noun
7071 status collapsed
7072
7073 \begin_layout Plain Layout
7074 La
7075 \family sans
7076 TeX
7077 \family default
7078  (plain) -> DVI
7079 \end_layout
7080
7081 \end_inset
7082
7083  or 
7084 \begin_inset Flex Noun
7085 status collapsed
7086
7087 \begin_layout Plain Layout
7088 La
7089 \family sans
7090 TeX
7091 \family default
7092  (plain) -> DraftDVI
7093 \end_layout
7094
7095 \end_inset
7096
7097  converter in 
7098 \begin_inset Flex Noun
7099 status collapsed
7100
7101 \begin_layout Plain Layout
7102 Preferences\SpecialChar menuseparator
7103 File Handling\SpecialChar menuseparator
7104 Converters
7105 \end_layout
7106
7107 \end_inset
7108
7109  to 
7110 \begin_inset Flex Code
7111 status collapsed
7112
7113 \begin_layout Plain Layout
7114 latex -synctex=1 $$i
7115 \end_layout
7116
7117 \end_inset
7118
7119 , and for PDF output, change the 
7120 \begin_inset Flex Noun
7121 status collapsed
7122
7123 \begin_layout Plain Layout
7124 La
7125 \family sans
7126 TeX
7127 \family default
7128  (pdflatex) -> PDF (pdflatex)
7129 \end_layout
7130
7131 \end_inset
7132
7133  converter to 
7134 \begin_inset Flex Code
7135 status collapsed
7136
7137 \begin_layout Plain Layout
7138 pdflatex -synctex=1 $$i
7139 \end_layout
7140
7141 \end_inset
7142
7143 .
7144  Should your viewer not be considered in the following description, or in
7145  case of missing success, please check the documentation of your viewer
7146  whether the viewer needs to be configured for the use with Sync\SpecialChar TeX
7147 .
7148 \begin_inset Foot
7149 status collapsed
7150
7151 \begin_layout Plain Layout
7152 Note that the option 
7153 \begin_inset Flex Code
7154 status collapsed
7155
7156 \begin_layout Plain Layout
7157 -synctex=1
7158 \end_layout
7159
7160 \end_inset
7161
7162  option enables gzip compression.
7163  If your viewer does not support it, you should instead use 
7164 \begin_inset Flex Code
7165 status collapsed
7166
7167 \begin_layout Plain Layout
7168 -synctex=-1
7169 \end_layout
7170
7171 \end_inset
7172
7173 .
7174 \end_layout
7175
7176 \end_inset
7177
7178
7179 \end_layout
7180
7181 \begin_layout Subsection
7182 Configuring and using specific viewers
7183 \begin_inset CommandInset label
7184 LatexCommand label
7185 name "subsec:configuring-viewers"
7186
7187 \end_inset
7188
7189
7190 \end_layout
7191
7192 \begin_layout Subsubsection*
7193 Xdvi (all platforms)
7194 \end_layout
7195
7196 \begin_layout Standard
7197 If you use 
7198 \begin_inset Flex Code
7199 status collapsed
7200
7201 \begin_layout Plain Layout
7202 xdvi
7203 \end_layout
7204
7205 \end_inset
7206
7207 , you don't need to do anything else for performing a reverse DVI search,
7208  as \SpecialChar LyX
7209  already provides the necessary hooks for automatically using the 
7210 \begin_inset Flex Code
7211 status collapsed
7212
7213 \begin_layout Plain Layout
7214 lyxclient
7215 \end_layout
7216
7217 \end_inset
7218
7219  program.
7220  Just setup your document as described above (reverse search is triggered
7221  by Ctrl-click or Alt-click on Mac OSX, respectively).
7222 \end_layout
7223
7224 \begin_layout Standard
7225 However, if for whatever reason you want to use the named pipe instead of
7226  the socket for communicating with \SpecialChar LyX
7227 , simply change the DVI viewer in 
7228 \begin_inset Flex Noun
7229 status collapsed
7230
7231 \begin_layout Plain Layout
7232 Preferences\SpecialChar menuseparator
7233 File Handling\SpecialChar menuseparator
7234 File formats
7235 \end_layout
7236
7237 \end_inset
7238
7239  to
7240 \begin_inset Foot
7241 status collapsed
7242
7243 \begin_layout Plain Layout
7244 On Mac OSX you have to use 
7245 \begin_inset Flex Code
7246 status collapsed
7247
7248 \begin_layout Plain Layout
7249 DISPLAY=:0.0 xdvi -editor "lyxeditor.sh %f %l"
7250 \end_layout
7251
7252 \end_inset
7253
7254
7255 \end_layout
7256
7257 \end_inset
7258
7259  
7260 \begin_inset Flex Code
7261 status collapsed
7262
7263 \begin_layout Plain Layout
7264 xdvi -editor "lyxeditor.sh %f %l"
7265 \end_layout
7266
7267 \end_inset
7268
7269 , where 
7270 \begin_inset Flex Code
7271 status collapsed
7272
7273 \begin_layout Plain Layout
7274 lyxeditor.sh
7275 \end_layout
7276
7277 \end_inset
7278
7279  is a suitable script.
7280  For example, a minimal shell script is the following one:
7281 \end_layout
7282
7283 \begin_layout LyX-Code
7284 #!/bin/sh
7285 \begin_inset Newline newline
7286 \end_inset
7287
7288 LYXPIPE="/path/to/lyxpipe"
7289 \begin_inset Newline newline
7290 \end_inset
7291
7292 COMMAND="LYXCMD:revdvi:server-goto-file-row:$1 $2"
7293 \begin_inset Newline newline
7294 \end_inset
7295
7296 echo "$COMMAND" > "${LYXPIPE}".in || exit
7297 \begin_inset Newline newline
7298 \end_inset
7299
7300 read TMP < "${LYXPIPE}".out || exit
7301 \end_layout
7302
7303 \begin_layout Standard
7304 where 
7305 \begin_inset Flex Code
7306 status collapsed
7307
7308 \begin_layout Plain Layout
7309 /path/to/lyxpipe
7310 \end_layout
7311
7312 \end_inset
7313
7314  is the LyXServer pipe path specified in 
7315 \begin_inset Flex Noun
7316 status collapsed
7317
7318 \begin_layout Plain Layout
7319 Preferences\SpecialChar menuseparator
7320 Paths
7321 \end_layout
7322
7323 \end_inset
7324
7325 .
7326 \begin_inset Foot
7327 status collapsed
7328
7329 \begin_layout Plain Layout
7330 In the 
7331 \begin_inset Flex Code
7332 status collapsed
7333
7334 \begin_layout Plain Layout
7335 development/tools
7336 \end_layout
7337
7338 \end_inset
7339
7340  folder of a source distribution you can find a 
7341 \begin_inset Flex Code
7342 status collapsed
7343
7344 \begin_layout Plain Layout
7345 lyxeditor
7346 \end_layout
7347
7348 \end_inset
7349
7350  script which is able to locate the 
7351 \emph on
7352 lyxpipe
7353 \emph default
7354  based on your preferences.
7355 \end_layout
7356
7357 \end_inset
7358
7359
7360 \end_layout
7361
7362 \begin_layout Subsubsection*
7363 MacDviX (Mac OSX)
7364 \end_layout
7365
7366 \begin_layout Standard
7367 At the end of 
7368 \begin_inset Flex Code
7369 status collapsed
7370
7371 \begin_layout Plain Layout
7372 /Applications/MacDviX_Folder/calleditor.script
7373 \end_layout
7374
7375 \end_inset
7376
7377 , add the following lines:
7378 \end_layout
7379
7380 \begin_layout LyX-Code
7381 /Applications/LyX.app/Contents/MacOS/lyxeditor "$2" $1
7382 \begin_inset Newline newline
7383 \end_inset
7384
7385 exit 1
7386 \end_layout
7387
7388 \begin_layout Standard
7389 Modify the lines accordingly if you install \SpecialChar LyX
7390  somewhere else than in the
7391  Applications folder.
7392 \end_layout
7393
7394 \begin_layout Standard
7395 Reverse search is triggered by Alt-click (OPTION-click).
7396 \end_layout
7397
7398 \begin_layout Subsubsection*
7399 Skim (Mac OSX)
7400 \end_layout
7401
7402 \begin_layout Standard
7403 Enter 
7404 \begin_inset Flex Code
7405 status collapsed
7406
7407 \begin_layout Plain Layout
7408 open -a Skim.app $$i
7409 \end_layout
7410
7411 \end_inset
7412
7413  to the viewer setting in 
7414 \begin_inset Flex Noun
7415 status collapsed
7416
7417 \begin_layout Plain Layout
7418 Preferences\SpecialChar menuseparator
7419 File Handling\SpecialChar menuseparator
7420 File formats\SpecialChar menuseparator
7421 PDF (pdflatex)
7422 \end_layout
7423
7424 \end_inset
7425
7426 , and then in 
7427 \begin_inset Flex Noun
7428 status collapsed
7429
7430 \begin_layout Plain Layout
7431 Skim\SpecialChar menuseparator
7432 Preferences\SpecialChar menuseparator
7433 Sync
7434 \end_layout
7435
7436 \end_inset
7437
7438  choose 
7439 \begin_inset Flex Noun
7440 status collapsed
7441
7442 \begin_layout Plain Layout
7443 custom
7444 \end_layout
7445
7446 \end_inset
7447
7448  preset and enter command 
7449 \begin_inset Flex Noun
7450 status collapsed
7451
7452 \begin_layout Plain Layout
7453 /Applications/\SpecialChar LyX
7454 .app/Contents/MacOS/lyxeditor
7455 \end_layout
7456
7457 \end_inset
7458
7459 .
7460 \end_layout
7461
7462 \begin_layout Standard
7463 Reverse search is triggered by COMMAND-SHIFT-click
7464 \end_layout
7465
7466 \begin_layout Subsubsection*
7467 Evince (GNOME)
7468 \end_layout
7469
7470 \begin_layout Standard
7471 Reverse search with evince does not work out of the box, but it can be achieved
7472  by means of some third party helper scripts.
7473  Please refer to 
7474 \begin_inset CommandInset href
7475 LatexCommand href
7476 target "https://wiki.lyx.org/LyX/SyncTeX"
7477 literal "false"
7478
7479 \end_inset
7480
7481  for details.
7482 \end_layout
7483
7484 \begin_layout Subsubsection*
7485 Okular (KDE)
7486 \end_layout
7487
7488 \begin_layout Standard
7489 Go to 
7490 \begin_inset Flex Noun
7491 status collapsed
7492
7493 \begin_layout Plain Layout
7494 Settings\SpecialChar menuseparator
7495 Configure Okular\SpecialChar menuseparator
7496 Editor
7497 \end_layout
7498
7499 \end_inset
7500
7501  and select LyX
7502 \begin_inset Quotes erd
7503 \end_inset
7504
7505  as editor.
7506  This inserts the appropriate command (
7507 \begin_inset Flex Code
7508 status collapsed
7509
7510 \begin_layout Plain Layout
7511 lyxclient -g %f %l
7512 \end_layout
7513
7514 \end_inset
7515
7516 ).
7517 \end_layout
7518
7519 \begin_layout Standard
7520 Reverse search is triggered by SHIFT-click.
7521 \end_layout
7522
7523 \begin_layout Subsubsection*
7524 Qpdfview (Unix)
7525 \end_layout
7526
7527 \begin_layout Standard
7528 Qpdfview supports Sync\SpecialChar TeX
7529  since version 0.3.5.
7530  Go to 
7531 \begin_inset Flex Noun
7532 status collapsed
7533
7534 \begin_layout Plain Layout
7535 Edit\SpecialChar menuseparator
7536 Settings\SpecialChar menuseparator
7537 Behavior
7538 \end_layout
7539
7540 \end_inset
7541
7542 , click on the input field of the 
7543 \begin_inset Quotes eld
7544 \end_inset
7545
7546 Source editor
7547 \begin_inset Quotes erd
7548 \end_inset
7549
7550  item and add the command 
7551 \begin_inset Flex Code
7552 status collapsed
7553
7554 \begin_layout Plain Layout
7555 lyxclient -g %1 %2
7556 \end_layout
7557
7558 \end_inset
7559
7560 .
7561 \end_layout
7562
7563 \begin_layout Standard
7564 Reverse search is triggered by double-click or, in more recent versions,
7565  by context menu.
7566 \end_layout
7567
7568 \begin_layout Subsubsection*
7569 YAP (Windows)
7570 \end_layout
7571
7572 \begin_layout Standard
7573 Launch yap, choose its 
7574 \begin_inset Flex Noun
7575 status collapsed
7576
7577 \begin_layout Plain Layout
7578 View\SpecialChar menuseparator
7579 Options
7580 \end_layout
7581
7582 \end_inset
7583
7584  menu and select the 
7585 \begin_inset Quotes eld
7586 \end_inset
7587
7588 Inverse DVI Search
7589 \begin_inset Quotes erd
7590 \end_inset
7591
7592  tab.
7593  Click on the 
7594 \begin_inset Quotes eld
7595 \end_inset
7596
7597 New\SpecialChar ldots
7598
7599 \begin_inset Quotes erd
7600 \end_inset
7601
7602  button and, in the window that opens, enter 
7603 \begin_inset Quotes eld
7604 \end_inset
7605
7606 \SpecialChar LyX
7607  Editor
7608 \begin_inset Quotes erd
7609 \end_inset
7610
7611  (or any other name you like) in the 
7612 \begin_inset Quotes eld
7613 \end_inset
7614
7615 Name:
7616 \begin_inset Quotes erd
7617 \end_inset
7618
7619  field.
7620  Now click on the button labeled 
7621 \begin_inset Quotes eld
7622 \end_inset
7623
7624 \SpecialChar ldots
7625
7626 \begin_inset Quotes erd
7627 \end_inset
7628
7629  to open a file dialog and navigate to the directory containing the batch
7630  file 
7631 \begin_inset Flex Code
7632 status collapsed
7633
7634 \begin_layout Plain Layout
7635 lyxeditor.bat
7636 \end_layout
7637
7638 \end_inset
7639
7640  (see below).
7641  Select 
7642 \begin_inset Flex Code
7643 status collapsed
7644
7645 \begin_layout Plain Layout
7646 lyxeditor.bat
7647 \end_layout
7648
7649 \end_inset
7650
7651  and then specify the program arguments as 
7652 \begin_inset Flex Code
7653 status collapsed
7654
7655 \begin_layout Plain Layout
7656 %f %l
7657 \end_layout
7658
7659 \end_inset
7660
7661 .
7662  The 
7663 \begin_inset Flex Code
7664 status collapsed
7665
7666 \begin_layout Plain Layout
7667 lyxeditor.bat
7668 \end_layout
7669
7670 \end_inset
7671
7672  wrapper is used for communicating with \SpecialChar LyX
7673  through the 
7674 \emph on
7675 lyxpipe
7676 \emph default
7677  and is as follows:
7678 \end_layout
7679
7680 \begin_layout LyX-Code
7681 @echo off
7682 \begin_inset Newline newline
7683 \end_inset
7684
7685 echo LYXCMD:revdvi:server-goto-file-row:%~1 %2> 
7686 \backslash
7687
7688 \backslash
7689 .
7690 \backslash
7691 pipe
7692 \backslash
7693 lyxpipe.in
7694 \begin_inset Newline newline
7695 \end_inset
7696
7697 type 
7698 \backslash
7699
7700 \backslash
7701 .
7702 \backslash
7703 pipe
7704 \backslash
7705 lyxpipe.out
7706 \end_layout
7707
7708 \begin_layout Standard
7709 Make sure that the \SpecialChar LyX
7710 Server pipe path you specified in \SpecialChar LyX
7711  is 
7712 \begin_inset Flex Code
7713 status collapsed
7714
7715 \begin_layout Plain Layout
7716
7717 \backslash
7718
7719 \backslash
7720 .
7721 \backslash
7722 pipe
7723 \backslash
7724 lyxpipe
7725 \end_layout
7726
7727 \end_inset
7728
7729 , otherwise change the 
7730 \begin_inset Flex Code
7731 status collapsed
7732
7733 \begin_layout Plain Layout
7734 lyxeditor.bat
7735 \end_layout
7736
7737 \end_inset
7738
7739  wrapper accordingly.
7740 \end_layout
7741
7742 \begin_layout Standard
7743 In yap, reverse search is triggered by double-click.
7744 \end_layout
7745
7746 \begin_layout Subsubsection*
7747 SumatraPDF (Windows)
7748 \end_layout
7749
7750 \begin_layout Standard
7751 In order to use SumatraPDF for inverse search, enter 
7752 \begin_inset Flex Code
7753 status collapsed
7754
7755 \begin_layout Plain Layout
7756 SumatraPDF -inverse-search "lyxeditor.bat "%f" %l"
7757 \end_layout
7758
7759 \end_inset
7760
7761  in the viewer setting in 
7762 \begin_inset Flex Noun
7763 status collapsed
7764
7765 \begin_layout Plain Layout
7766 Preferences\SpecialChar menuseparator
7767 File Handling\SpecialChar menuseparator
7768 File formats\SpecialChar menuseparator
7769 PDF (pdflatex)
7770 \end_layout
7771
7772 \end_inset
7773
7774 , where 
7775 \begin_inset Flex Code
7776 status collapsed
7777
7778 \begin_layout Plain Layout
7779 lyxeditor.bat
7780 \end_layout
7781
7782 \end_inset
7783
7784  is the previous wrapper.
7785  If SumatraPDF.exe is not in your command PATH, use its full file name.
7786 \end_layout
7787
7788 \begin_layout Standard
7789 Reverse search is triggered by double-click.
7790 \end_layout
7791
7792 \begin_layout Subsubsection*
7793 YAP (Cygwin)
7794 \end_layout
7795
7796 \begin_layout Standard
7797 First of all, make sure that yap is your default DVI viewer in the Windows
7798  environment, then launch it, choose its 
7799 \begin_inset Flex Noun
7800 status collapsed
7801
7802 \begin_layout Plain Layout
7803 View\SpecialChar menuseparator
7804 Options
7805 \end_layout
7806
7807 \end_inset
7808
7809  menu and select the 
7810 \begin_inset Quotes eld
7811 \end_inset
7812
7813 Inverse DVI Search
7814 \begin_inset Quotes erd
7815 \end_inset
7816
7817  tab.
7818  Click on the 
7819 \begin_inset Quotes eld
7820 \end_inset
7821
7822 New\SpecialChar ldots
7823
7824 \begin_inset Quotes erd
7825 \end_inset
7826
7827  button and, in the window that opens, enter 
7828 \begin_inset Quotes eld
7829 \end_inset
7830
7831 \SpecialChar LyX
7832  Editor
7833 \begin_inset Quotes erd
7834 \end_inset
7835
7836  (or any other name you like) in the 
7837 \begin_inset Quotes eld
7838 \end_inset
7839
7840 Name:
7841 \begin_inset Quotes erd
7842 \end_inset
7843
7844  field.
7845  Now click on the button labeled 
7846 \begin_inset Quotes eld
7847 \end_inset
7848
7849 \SpecialChar ldots
7850
7851 \begin_inset Quotes erd
7852 \end_inset
7853
7854  to open a file dialog and navigate to the directory containing the 
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  program (which is installed by default on Cygwin along with the \SpecialChar LyX
7865  executable).
7866  Select 
7867 \begin_inset Flex Code
7868 status collapsed
7869
7870 \begin_layout Plain Layout
7871 lyxeditor.exe
7872 \end_layout
7873
7874 \end_inset
7875
7876  and then specify the program arguments as 
7877 \begin_inset Flex Code
7878 status collapsed
7879
7880 \begin_layout Plain Layout
7881 -g %f %l
7882 \end_layout
7883
7884 \end_inset
7885
7886 .
7887  In this way, you will be using the 
7888 \emph on
7889 lyxsocket
7890 \emph default
7891  for communicating with \SpecialChar LyX
7892 .
7893  If, for whatever reason, you want to use the 
7894 \emph on
7895 lyxpipe
7896 \emph default
7897 , omit the 
7898 \begin_inset Flex Code
7899 status collapsed
7900
7901 \begin_layout Plain Layout
7902 -g
7903 \end_layout
7904
7905 \end_inset
7906
7907  option and be sure to specify the \SpecialChar LyX
7908 Server pipe path in the \SpecialChar LyX
7909  preferences.
7910 \end_layout
7911
7912 \begin_layout Standard
7913 In yap, reverse search is triggered by double-click.
7914 \end_layout
7915
7916 \begin_layout Subsubsection*
7917 SumatraPDF (Cygwin)
7918 \end_layout
7919
7920 \begin_layout Standard
7921 In order to use SumatraPDF for inverse search, enter 
7922 \begin_inset Flex Code
7923 status collapsed
7924
7925 \begin_layout Plain Layout
7926 SumatraPDF -inverse-search "lyxeditor -g %f %l"
7927 \end_layout
7928
7929 \end_inset
7930
7931  in the viewer setting in 
7932 \begin_inset Flex Noun
7933 status collapsed
7934
7935 \begin_layout Plain Layout
7936 Preferences\SpecialChar menuseparator
7937 File Handling\SpecialChar menuseparator
7938 File formats\SpecialChar menuseparator
7939 PDF (pdflatex)
7940 \end_layout
7941
7942 \end_inset
7943
7944 .
7945  If SumatraPDF.exe is not in your command PATH, use its full posix path.
7946  The 
7947 \begin_inset Flex Code
7948 status collapsed
7949
7950 \begin_layout Plain Layout
7951 -g
7952 \end_layout
7953
7954 \end_inset
7955
7956  enables communication via the 
7957 \emph on
7958 lyxsocket
7959 \emph default
7960 .
7961  Again, omit the 
7962 \begin_inset Flex Code
7963 status collapsed
7964
7965 \begin_layout Plain Layout
7966 -g
7967 \end_layout
7968
7969 \end_inset
7970
7971  option if you want to use the 
7972 \emph on
7973 lyxpipe
7974 \emph default
7975 , and be sure to specify the \SpecialChar LyX
7976 Server pipe path in the \SpecialChar LyX
7977  preferences.
7978 \end_layout
7979
7980 \begin_layout Standard
7981 Reverse search is triggered by double-click.
7982 \end_layout
7983
7984 \begin_layout Section
7985 Forward search
7986 \end_layout
7987
7988 \begin_layout Standard
7989 Forward search is, as the name implies, in a sense the 
7990 \begin_inset Quotes eld
7991 \end_inset
7992
7993 opposite
7994 \begin_inset Quotes erd
7995 \end_inset
7996
7997  of reverse search.
7998  It allows you to let the viewer jump to a given position from within \SpecialChar LyX
7999 .
8000  If forward search is set up (as described in what follows), you can put
8001  the cursor anywhere in your \SpecialChar LyX
8002  document, and hit 
8003 \begin_inset Flex Noun
8004 status collapsed
8005
8006 \begin_layout Plain Layout
8007 Navigate\SpecialChar menuseparator
8008 Forward search
8009 \end_layout
8010
8011 \end_inset
8012
8013  (or select 
8014 \begin_inset Flex Noun
8015 status collapsed
8016
8017 \begin_layout Plain Layout
8018 Forward search
8019 \end_layout
8020
8021 \end_inset
8022
8023  in the context menu via right mouse click), and then the viewer will jump
8024  to that position as well.
8025  This implies, of course, that your viewer supports this function.
8026 \end_layout
8027
8028 \begin_layout Standard
8029 To make forward search possible, you first need to provide the generated
8030  output PDF/DVI file with additional information about the \SpecialChar TeX
8031  sources.
8032  This can be done via the methods described in the section 
8033 \begin_inset CommandInset ref
8034 LatexCommand ref
8035 reference "subsec:rev-search"
8036
8037 \end_inset
8038
8039 .
8040 \end_layout
8041
8042 \begin_layout Standard
8043 Additionally, you need to configure \SpecialChar LyX
8044  for using your viewers in 
8045 \begin_inset Flex Noun
8046 status collapsed
8047
8048 \begin_layout Plain Layout
8049 Tools\SpecialChar menuseparator
8050 Preferences\SpecialChar menuseparator
8051 Output\SpecialChar menuseparator
8052 General
8053 \end_layout
8054
8055 \end_inset
8056
8057 .
8058  We provide a range of tested configurations for some viewers, which you
8059  can select from the drop down list.
8060  If none of these configurations suits you, you have to find out and enter
8061  a suitable configuration yourself.
8062  The definition syntax uses the following placeholders:
8063 \end_layout
8064
8065 \begin_layout Itemize
8066 \noindent
8067 \begin_inset Flex Code
8068 status collapsed
8069
8070 \begin_layout Plain Layout
8071 $$n
8072 \end_layout
8073
8074 \end_inset
8075
8076 : row number
8077 \end_layout
8078
8079 \begin_layout Itemize
8080 \noindent
8081 \begin_inset Flex Code
8082 status collapsed
8083
8084 \begin_layout Plain Layout
8085 $$t
8086 \end_layout
8087
8088 \end_inset
8089
8090 : name of the (temporary) exported .tex file (without path)
8091 \end_layout
8092
8093 \begin_layout Itemize
8094 \noindent
8095 \begin_inset Flex Code
8096 status collapsed
8097
8098 \begin_layout Plain Layout
8099 $$f
8100 \end_layout
8101
8102 \end_inset
8103
8104 : name of the (temporary) exported .tex file (including path)
8105 \end_layout
8106
8107 \begin_layout Itemize
8108 \noindent
8109 \begin_inset Flex Code
8110 status collapsed
8111
8112 \begin_layout Plain Layout
8113 $$o
8114 \end_layout
8115
8116 \end_inset
8117
8118 : name of the exported output file (either dvi or pdf, depending on which
8119  one exists in the temporary directory)
8120 \end_layout
8121
8122 \begin_layout Standard
8123 Note that only some of the viewers provide full and usable forward search
8124  functionality out of the box, among them yap, xdvi, okular
8125 \begin_inset Foot
8126 status collapsed
8127
8128 \begin_layout Plain Layout
8129 You might want to set 
8130 \begin_inset Flex Code
8131 status collapsed
8132
8133 \begin_layout Plain Layout
8134 okular --unique
8135 \end_layout
8136
8137 \end_inset
8138
8139  in 
8140 \begin_inset Flex Noun
8141 status collapsed
8142
8143 \begin_layout Plain Layout
8144 Tools\SpecialChar menuseparator
8145 Preferences\SpecialChar menuseparator
8146 File Handling\SpecialChar menuseparator
8147 File
8148 \begin_inset space ~
8149 \end_inset
8150
8151 Formats
8152 \end_layout
8153
8154 \end_inset
8155
8156
8157 \end_layout
8158
8159 \end_inset
8160
8161 , qpdfview, and SumatraPDF
8162 \begin_inset Foot
8163 status collapsed
8164
8165 \begin_layout Plain Layout
8166 SumatraPDF can also use DDE commands through the external program CMCDDE
8167  â€” downloadable from 
8168 \begin_inset CommandInset href
8169 LatexCommand href
8170 target "http://www.istri.fr/spip/zip/CMCDDE.zip"
8171 literal "false"
8172
8173 \end_inset
8174
8175
8176 \end_layout
8177
8178 \end_inset
8179
8180 .
8181  Others, such as evince
8182 \begin_inset Foot
8183 status collapsed
8184
8185 \begin_layout Plain Layout
8186 Forward search with evince can be achieved by means of third party helper
8187  scripts.
8188  Please refer to 
8189 \begin_inset CommandInset href
8190 LatexCommand href
8191 target "https://wiki.lyx.org/LyX/SyncTeX"
8192 literal "false"
8193
8194 \end_inset
8195
8196  for details.
8197 \end_layout
8198
8199 \end_inset
8200
8201 , require some extra tools in order to use forward search.
8202  While many of the widespread PDF viewers (most notably Adobe Reader) do
8203  not support forward search at all, some other viewers â€“ e.
8204 \begin_inset space \thinspace{}
8205 \end_inset
8206
8207 g.
8208  xpdf â€“ allow at least to reload the document and jump to a specific page
8209  of the file, so you can at least navigate 
8210 \begin_inset Quotes eld
8211 \end_inset
8212
8213 near
8214 \begin_inset Quotes erd
8215 \end_inset
8216
8217 .
8218  This latter functionality is provided by an external call of synctex (see
8219  the predefined example configurations).
8220  
8221 \end_layout
8222
8223 \begin_layout Standard
8224 Forward search works both with DVI and PDF output.
8225  \SpecialChar LyX
8226  simply checks which preview format you have used before (i.
8227 \begin_inset space \thinspace{}
8228 \end_inset
8229
8230 e., which format is already there in the temporary directory) and chooses
8231  the appropriate configuration for the respective format.
8232 \end_layout
8233
8234 \begin_layout Chapter
8235 Special Document Classes
8236 \end_layout
8237
8238 \begin_layout Section
8239 A&A Paper
8240 \end_layout
8241
8242 \begin_layout Standard
8243 by 
8244 \noun on
8245 Peter Sütterlin
8246 \end_layout
8247
8248 \begin_layout Subsection
8249 Introduction
8250 \end_layout
8251
8252 \begin_layout Standard
8253 This section describes how \SpecialChar LyX
8254  can be used to write articles for submission
8255  to the scientific journal 
8256 \emph on
8257 Astronomy and Astrophysics
8258 \emph default
8259  (
8260 \begin_inset Flex URL
8261 status collapsed
8262
8263 \begin_layout Plain Layout
8264
8265 https://www.aanda.org/
8266 \end_layout
8267
8268 \end_inset
8269
8270 ) using Version 5.01 of the document class 
8271 \family typewriter
8272 aa.cls
8273 \family default
8274 .
8275  This package can be downloaded from the ftp site
8276 \end_layout
8277
8278 \begin_layout Standard
8279 \begin_inset VSpace medskip
8280 \end_inset
8281
8282
8283 \end_layout
8284
8285 \begin_layout Standard
8286 \align center
8287 \begin_inset Flex URL
8288 status collapsed
8289
8290 \begin_layout Plain Layout
8291
8292 ftp://ftp.edpsciences.org/pub/aa/readme.html
8293 \end_layout
8294
8295 \end_inset
8296
8297
8298 \end_layout
8299
8300 \begin_layout Standard
8301 \begin_inset VSpace medskip
8302 \end_inset
8303
8304
8305 \end_layout
8306
8307 \begin_layout Standard
8308 A manual comes together with that package, and this text is not meant to
8309  replace the original manual but is merely a short guide in how to realize
8310  the correct form of your paper.
8311  
8312 \end_layout
8313
8314 \begin_layout Standard
8315 Please note that the publisher of the journal was changed from Springer
8316  to EDP Sciences starting January 1, 2001.
8317  That change involved also some slight changes to the style files, namely
8318  the removal of the thesaurus command.
8319  The \SpecialChar LyX
8320  class aa supports the newest version of these style files, V 5.01.
8321  If you have an older version installed, please upgrade.
8322  For compatibility, the old (version 4) layout has been kept as 
8323 \family sans
8324 article (A&A V4)
8325 \family default
8326 .
8327  Please refer to the comments in 
8328 \family typewriter
8329 \SpecialChar LyX
8330 Dir/layouts/aapaper.layout
8331 \family default
8332 .
8333 \end_layout
8334
8335 \begin_layout Subsection
8336 Getting started
8337 \end_layout
8338
8339 \begin_layout Standard
8340 It is recommended you start from the example template distributed with \SpecialChar LyX
8341 .
8342  If you are not using a template, note the following settings:
8343 \end_layout
8344
8345 \begin_layout Itemize
8346 Select 
8347 \family sans
8348 article (A&A)
8349 \family default
8350  in the 
8351 \family sans
8352 Document\SpecialChar menuseparator
8353 Settings
8354 \family default
8355  dialog (OK, that one was obvious).
8356 \end_layout
8357
8358 \begin_layout Itemize
8359 Don't change the option 
8360 \family sans
8361 Page
8362 \begin_inset space ~
8363 \end_inset
8364
8365 style
8366 \family default
8367 : Leave it set to 
8368 \family sans
8369 default
8370 \family default
8371 .
8372  The whole layout is done by the macros, you shouldn't change anything.
8373 \end_layout
8374
8375 \begin_layout Subsection
8376 The header block
8377 \end_layout
8378
8379 \begin_layout Standard
8380 First thing to enter is the header information.
8381  It consists of seven entries, of which some are optional.
8382  They are
8383 \end_layout
8384
8385 \begin_layout Itemize
8386
8387 \family sans
8388 Title
8389 \family default
8390 : [required] 
8391 \end_layout
8392
8393 \begin_layout Itemize
8394
8395 \family sans
8396 Subtitle
8397 \family default
8398 : [optional] 
8399 \end_layout
8400
8401 \begin_layout Itemize
8402
8403 \family sans
8404 Author
8405 \family default
8406 : [required]
8407 \end_layout
8408
8409 \begin_layout Itemize
8410
8411 \family sans
8412 Address
8413 \family default
8414 : [required]
8415 \end_layout
8416
8417 \begin_layout Itemize
8418
8419 \family sans
8420 Offprints
8421 \family default
8422 : [optional] if more than one author: whom to contact for offprint requests.
8423 \end_layout
8424
8425 \begin_layout Itemize
8426
8427 \family sans
8428 Mail
8429 \family default
8430 : [optional] mail address for contacts.
8431 \end_layout
8432
8433 \begin_layout Itemize
8434
8435 \family sans
8436 Date
8437 \family default
8438 : [required].
8439  Suggested format is 
8440 \family typewriter
8441 Received: <date>; Accepted <date> 
8442 \end_layout
8443
8444 \begin_layout Standard
8445 There is no need to issue the 
8446 \family typewriter
8447
8448 \backslash
8449 maketitle
8450 \family default
8451  command, this is done automatically by \SpecialChar LyX
8452  when the header is finished.
8453  Although the order of the single header entries doesn't matter it is advised
8454  to keep the above sequence, just to get the best optics and meets the layout
8455  of the real document.
8456 \end_layout
8457
8458 \begin_layout Standard
8459 If you want to place footnotes in the header block, e.
8460 \begin_inset space \thinspace{}
8461 \end_inset
8462
8463 g.
8464 \begin_inset space \space{}
8465 \end_inset
8466
8467 to state your present address, just use the standard footnote via the menu
8468  
8469 \family sans
8470 Insert\SpecialChar menuseparator
8471 Footnote.
8472
8473 \family default
8474  \SpecialChar LyX
8475  will automagically use the term 
8476 \family typewriter
8477
8478 \backslash
8479 thanks{}
8480 \family default
8481  in that case.
8482 \end_layout
8483
8484 \begin_layout Standard
8485 Under 
8486 \family sans
8487 Edit\SpecialChar menuseparator
8488 Text Style
8489 \family default
8490 , you'll find two insets which are relevant for the titling:
8491 \end_layout
8492
8493 \begin_layout Itemize
8494
8495 \family sans
8496 Institute
8497 \family typewriter
8498  
8499 \family default
8500 to mark corresponding author\SpecialChar breakableslash
8501 institute pairs.
8502  The institutes are numbered sequentially as they appear in the 
8503 \family sans
8504 Address
8505 \family default
8506  field, so you have to put a marker to each author.
8507 \end_layout
8508
8509 \begin_layout Itemize
8510
8511 \family sans
8512 Email
8513 \family default
8514  to supply an email address for fast contact.
8515 \end_layout
8516
8517 \begin_layout Standard
8518 In addition to these topics, the macros use one additional \SpecialChar LaTeX
8519  command that
8520  has no counterpart in \SpecialChar LyX
8521 :
8522 \end_layout
8523
8524 \begin_layout Itemize
8525
8526 \family typewriter
8527
8528 \backslash
8529 and
8530 \family default
8531  to separate different names for more than one author and institute, respectivel
8532 y.
8533 \end_layout
8534
8535 \begin_layout Standard
8536 The appropriate command has to be entered in \SpecialChar LyX
8537  and marked as \SpecialChar LaTeX
8538  code.
8539  See the examples.
8540  
8541 \end_layout
8542
8543 \begin_layout Subsection
8544 The abstract
8545 \end_layout
8546
8547 \begin_layout Standard
8548 The abstract should immediately follow the header block.
8549  With version 5 the abstract environment was changed to a command, and there
8550  is now a restriction to only one paragraph.
8551  In addition, it should contain an entry with the keywords.
8552  This is done via the paragraph style 
8553 \family sans
8554 Keywords
8555 \family default
8556 .
8557  Refer to the example paper.
8558 \end_layout
8559
8560 \begin_layout Subsection
8561 Supported environments
8562 \end_layout
8563
8564 \begin_layout Standard
8565 The A&A paper layout supports the following environments for structuring
8566  your text:
8567 \end_layout
8568
8569 \begin_layout Itemize
8570
8571 \family sans
8572 Standard
8573 \end_layout
8574
8575 \begin_layout Itemize
8576
8577 \family sans
8578 Section
8579 \end_layout
8580
8581 \begin_layout Itemize
8582
8583 \family sans
8584 Subsection
8585 \end_layout
8586
8587 \begin_layout Itemize
8588
8589 \family sans
8590 Subsubsection
8591 \end_layout
8592
8593 \begin_layout Itemize
8594
8595 \family sans
8596 Itemize
8597 \end_layout
8598
8599 \begin_layout Itemize
8600
8601 \family sans
8602 Enumerate
8603 \end_layout
8604
8605 \begin_layout Itemize
8606
8607 \family sans
8608 Description
8609 \end_layout
8610
8611 \begin_layout Itemize
8612
8613 \family sans
8614 Caption
8615 \end_layout
8616
8617 \begin_layout Itemize
8618
8619 \family sans
8620 Abstract
8621 \end_layout
8622
8623 \begin_layout Itemize
8624
8625 \family sans
8626 Acknowledgment
8627 \end_layout
8628
8629 \begin_layout Itemize
8630
8631 \family sans
8632 Bibliography
8633 \end_layout
8634
8635 \begin_layout Itemize
8636
8637 \family sans
8638 \SpecialChar LaTeX
8639
8640 \end_layout
8641
8642 \begin_layout Subsection
8643 Commands not supported by \SpecialChar LyX
8644
8645 \end_layout
8646
8647 \begin_layout Standard
8648 Some commands are not yet supported by the 
8649 \family sans
8650 paper (A&A)
8651 \family default
8652  layout for \SpecialChar LyX
8653 .
8654  Some have already been mentioned.
8655  For the sake of completeness, they are listed all together here:
8656 \end_layout
8657
8658 \begin_layout Itemize
8659
8660 \family typewriter
8661
8662 \backslash
8663 and
8664 \end_layout
8665
8666 \begin_layout Itemize
8667
8668 \family typewriter
8669
8670 \backslash
8671 authorrunning
8672 \end_layout
8673
8674 \begin_layout Itemize
8675
8676 \family typewriter
8677
8678 \backslash
8679 object{}
8680 \end_layout
8681
8682 \begin_layout Itemize
8683
8684 \family typewriter
8685
8686 \backslash
8687 titlerunning{}
8688 \end_layout
8689
8690 \begin_layout Standard
8691 If you want to use any of these commands, you have to enter them yourself.
8692  
8693 \series bold
8694 Do not forget to mark them as \SpecialChar LaTeX
8695  code!
8696 \end_layout
8697
8698 \begin_layout Subsection
8699 Figure and Table Floats
8700 \end_layout
8701
8702 \begin_layout Standard
8703 \SpecialChar LyX
8704  provides support for the necessary float environments 
8705 \family sans
8706 figure, figure*, table
8707 \family default
8708  and 
8709 \family sans
8710 table*
8711 \family default
8712 , therefore we won't tell much about it here.
8713  Refer to the 
8714 \emph on
8715 User's
8716 \begin_inset space ~
8717 \end_inset
8718
8719 Guide
8720 \emph default
8721 .
8722  Just remember that tables should be left-aligned.
8723  For that, select the table and change the alignment in 
8724 \family sans
8725 Edit\SpecialChar menuseparator
8726 Paragraph
8727 \begin_inset space ~
8728 \end_inset
8729
8730 Settings.
8731 \end_layout
8732
8733 \begin_layout Standard
8734 There is only one special thing: the figures with caption besides the figure.
8735  To create such a figure, you have to do the following:
8736 \end_layout
8737
8738 \begin_layout Enumerate
8739 Create a wide figure float: 
8740 \family sans
8741 Insert\SpecialChar menuseparator
8742 Float\SpecialChar menuseparator
8743 Figure
8744 \family default
8745 , then right click in the figure and select 
8746 \family sans
8747 Span
8748 \begin_inset space ~
8749 \end_inset
8750
8751 columns
8752 \family default
8753 .
8754 \end_layout
8755
8756 \begin_layout Enumerate
8757 Enter your caption text.
8758 \end_layout
8759
8760 \begin_layout Enumerate
8761 Press 
8762 \family sans
8763 Return
8764 \family default
8765  to move the cursor above the caption.
8766 \end_layout
8767
8768 \begin_layout Enumerate
8769 Insert your figure
8770 \end_layout
8771
8772 \begin_layout Enumerate
8773 Position the cursor behind the figure and insert a horizontal fill: 
8774 \family sans
8775 Insert\SpecialChar menuseparator
8776 Special
8777 \begin_inset space ~
8778 \end_inset
8779
8780 Character\SpecialChar menuseparator
8781 Horizontal
8782 \begin_inset space ~
8783 \end_inset
8784
8785 Fill
8786 \family default
8787 .
8788 \end_layout
8789
8790 \begin_layout Enumerate
8791 Switch to \SpecialChar LaTeX
8792  mode: 
8793 \family sans
8794 M-c
8795 \begin_inset space ~
8796 \end_inset
8797
8798 t
8799 \family default
8800 .
8801 \end_layout
8802
8803 \begin_layout Enumerate
8804 Enter 
8805 \family typewriter
8806
8807 \backslash
8808 parbox[b]{55mm}{
8809 \family default
8810 .
8811  
8812 \series bold
8813 Do not close the brace!
8814 \end_layout
8815
8816 \begin_layout Enumerate
8817 Position the cursor behind the caption text, switch to \SpecialChar LaTeX
8818  mode and insert
8819  the closing brace: 
8820 \family sans
8821 M-c
8822 \begin_inset space ~
8823 \end_inset
8824
8825 t
8826 \family default
8827  
8828 \family typewriter
8829 }
8830 \family default
8831 .
8832 \end_layout
8833
8834 \begin_layout Standard
8835 Also, refer to the figures in the example paper.
8836 \end_layout
8837
8838 \begin_layout Subsection
8839 Referee layout
8840 \end_layout
8841
8842 \begin_layout Standard
8843 For submission, the paper has to be formated in a special double-spacing
8844  layout.
8845  For this purpose, you have to give the option 
8846 \family typewriter
8847 referee
8848 \family default
8849  to the document class.
8850  This must be done using the custom class options field in the 
8851 \family sans
8852 Document\SpecialChar menuseparator
8853 Settings
8854 \family default
8855  dialog.
8856  Just enter the string 
8857 \family typewriter
8858 referee
8859 \family default
8860  there.
8861 \end_layout
8862
8863 \begin_layout Subsection
8864 The example paper
8865 \end_layout
8866
8867 \begin_layout Standard
8868 The 
8869 \family sans
8870 Examples
8871 \family default
8872  directory contains an example paper written with \SpecialChar LyX
8873 .
8874  It is the example paper from the original macro package, translated to
8875  \SpecialChar LyX
8876 .
8877  Use it for inspiration, and compare the original \SpecialChar LaTeX
8878  code with \SpecialChar LyX
8879  way of writing.
8880 \end_layout
8881
8882 \begin_layout Section
8883 AAS\SpecialChar TeX
8884
8885 \end_layout
8886
8887 \begin_layout Standard
8888 by 
8889 \noun on
8890 Mike Ressler
8891 \end_layout
8892
8893 \begin_layout Subsection
8894 Introduction
8895 \end_layout
8896
8897 \begin_layout Standard
8898 AAS\SpecialChar TeX
8899  is a set of macros produced by the American Astronomical Society to
8900  facilitate electronic manuscript submission to the three journals they
8901  publish: the Astrophysical Journal (including the Letters and Supplement),
8902  the Astronomical Journal, and the Publications of the Astronomical Society
8903  of the Pacific.
8904  \SpecialChar LyX
8905  has proven to be an excellent tool for generating these documents, especially
8906  given its equation, citation, and figure handling capabilities.
8907  \SpecialChar LyX
8908  requires version 5.0 (or higher) of these macros; preferably 6.0, which
8909  is the version described here, or higher.
8910  Versions prior to 5.0 are intended for use with \SpecialChar LaTeX
8911 2.09 and are fundamentally
8912  incompatible with \SpecialChar LyX
8913 .
8914  The AAS\SpecialChar TeX
8915  package may be downloaded from the AAS\SpecialChar TeX
8916  Web site
8917 \end_layout
8918
8919 \begin_layout Standard
8920 \begin_inset VSpace medskip
8921 \end_inset
8922
8923
8924 \end_layout
8925
8926 \begin_layout Standard
8927 \align center
8928 \begin_inset Flex URL
8929 status collapsed
8930
8931 \begin_layout Plain Layout
8932
8933 https://aas.org/aastex/aastex-downloads
8934 \end_layout
8935
8936 \end_inset
8937
8938
8939 \end_layout
8940
8941 \begin_layout Standard
8942 \begin_inset VSpace medskip
8943 \end_inset
8944
8945
8946 \end_layout
8947
8948 \begin_layout Standard
8949 A complete user guide is contained in that package and you should familiarize
8950  yourself with it thoroughly before embarking on writing a paper in \SpecialChar LyX
8951 .
8952  \SpecialChar LyX
8953  will not reduce the need to figure out all the AAS\SpecialChar TeX
8954  commands, it will only
8955  reduce the drudgery of typing everything in.
8956  It is your responsibility to ensure that the final exported \SpecialChar LaTeX
8957  document conforms
8958  completely to the requirements of the journal to which you are submitting
8959  your paper.
8960 \end_layout
8961
8962 \begin_layout Subsection
8963 Starting a New Paper
8964 \end_layout
8965
8966 \begin_layout Standard
8967 I strongly suggest that you start with the AAS\SpecialChar TeX
8968  template file.
8969  Click on 
8970 \family sans
8971 File\SpecialChar menuseparator
8972 New from
8973 \family default
8974  
8975 \family sans
8976 Template
8977 \family default
8978 , enter the new file name, then choose the 
8979 \family typewriter
8980 aastex6.lyx
8981 \family default
8982  template.
8983  This will show the most common fields found in a manuscript.
8984  Simply overwrite the existing text (including the brackets, 
8985 \family typewriter
8986 <>
8987 \family default
8988 ) with the correct information.
8989  Many of the AAS\SpecialChar TeX
8990  commands and environments can be implemented directly in
8991  \SpecialChar LyX
8992 , but some cannot.
8993  For commands such as these, the \SpecialChar LaTeX
8994  code must be entered directly and marked
8995  as such.
8996  Such commands are referred to as \SpecialChar TeX
8997  code, or Evil Red Text.
8998  I tried to minimize the amount of \SpecialChar TeX
8999  code needed in an AAS\SpecialChar TeX
9000  document.
9001 \end_layout
9002
9003 \begin_layout Subsection
9004 Finishing Your Paper
9005 \end_layout
9006
9007 \begin_layout Standard
9008 When the paper is finished to your satisfaction and previews/prints correctly,
9009  there are a few 
9010 \begin_inset Quotes eld
9011 \end_inset
9012
9013 postprocessing
9014 \begin_inset Quotes erd
9015 \end_inset
9016
9017  actions which need to be done before you submit it to the journals.
9018  
9019 \end_layout
9020
9021 \begin_layout Enumerate
9022 Export your paper as a \SpecialChar LaTeX
9023  file (
9024 \family sans
9025 File\SpecialChar menuseparator
9026 Export\SpecialChar menuseparator
9027 \SpecialChar LaTeX
9028
9029 \family default
9030 ).
9031  
9032 \end_layout
9033
9034 \begin_layout Enumerate
9035 Edit the resulting 
9036 \family typewriter
9037 .tex
9038 \family default
9039  file with your favorite text editor
9040 \end_layout
9041
9042 \begin_deeper
9043 \begin_layout Enumerate
9044 remove the comment lines before the 
9045 \family typewriter
9046
9047 \backslash
9048 documentclass
9049 \family default
9050  command
9051 \end_layout
9052
9053 \begin_layout Enumerate
9054 remove the 
9055 \family typewriter
9056
9057 \backslash
9058 usepackage...{fontenc}
9059 \family default
9060  line if it appears (usually just after 
9061 \family typewriter
9062
9063 \backslash
9064 documentclass
9065 \family default
9066 }; also remove the 
9067 \family typewriter
9068
9069 \backslash
9070 secnumdepth
9071 \family default
9072  line if it appears.
9073 \end_layout
9074
9075 \begin_layout Enumerate
9076 remove everything between (and including) the 
9077 \family typewriter
9078
9079 \backslash
9080 makeatletter
9081 \family default
9082  and 
9083 \family typewriter
9084
9085 \backslash
9086 makeatother
9087 \family default
9088  commands, except for any commands you specifically put into the \SpecialChar LaTeX
9089  preamble
9090  (which should appear immediately after the 
9091 \begin_inset Quotes eld
9092 \end_inset
9093
9094 User specified \SpecialChar LaTeX
9095  commands
9096 \begin_inset Quotes erd
9097 \end_inset
9098
9099  comment in the 
9100 \family typewriter
9101 .tex
9102 \family default
9103  file).
9104 \end_layout
9105
9106 \end_deeper
9107 \begin_layout Enumerate
9108 Run the resulting file through \SpecialChar LaTeX
9109  to make sure it still processes correctly.
9110 \end_layout
9111
9112 \begin_layout Enumerate
9113 Reread the journal requirements to make sure your filenames and formats
9114  are correct.
9115 \end_layout
9116
9117 \begin_layout Enumerate
9118 Submit it.
9119 \end_layout
9120
9121 \begin_layout Subsection
9122 Comments On Specific Commands
9123 \end_layout
9124
9125 \begin_layout Standard
9126 I will not describe the detailed usage of the individual AAS\SpecialChar TeX
9127  commands: the
9128  AAS\SpecialChar TeX
9129  User Guide (
9130 \family typewriter
9131 aasguide.tex
9132 \family default
9133 ) gives a good description of each.
9134  Thus it's probably easiest for me to go down the list as found in the guide
9135  and offer comments where necessary.
9136  So let's begin \SpecialChar ldots
9137
9138 \end_layout
9139
9140 \begin_layout Subsubsection
9141 Things that work as expected
9142 \end_layout
9143
9144 \begin_layout Standard
9145 Because they work as you might expect, I simply list them and the section
9146  they are found in: 
9147 \family typewriter
9148
9149 \backslash
9150 documentclass
9151 \family default
9152  (2.1.1), 
9153 \family typewriter
9154
9155 \backslash
9156 begin{document}
9157 \family default
9158  (2.2), 
9159 \family typewriter
9160
9161 \backslash
9162 title
9163 \family default
9164  (2.3), 
9165 \family typewriter
9166
9167 \backslash
9168 author
9169 \family default
9170  (2.3), 
9171 \family typewriter
9172
9173 \backslash
9174 affil
9175 \family default
9176  (2.3), 
9177 \family typewriter
9178
9179 \backslash
9180 abstract
9181 \family default
9182  (2.4), 
9183 \family typewriter
9184
9185 \backslash
9186 keywords
9187 \family default
9188  (2.5), 
9189 \family typewriter
9190
9191 \backslash
9192 section
9193 \family default
9194  (2.7), 
9195 \family typewriter
9196
9197 \backslash
9198 subsection
9199 \family default
9200  (2.7), 
9201 \family typewriter
9202
9203 \backslash
9204 subsubsection
9205 \family default
9206  (2.7), 
9207 \family typewriter
9208
9209 \backslash
9210 paragraph
9211 \family default
9212  (2.7), 
9213 \family typewriter
9214
9215 \backslash
9216 facility
9217 \family default
9218  (2.10), 
9219 \family typewriter
9220
9221 \backslash
9222 begin{displaymath}
9223 \family default
9224  (2.12), 
9225 \family typewriter
9226
9227 \backslash
9228 begin{equation}
9229 \family default
9230  (2.12), 
9231 \family typewriter
9232
9233 \backslash
9234 begin{eqnarray}
9235 \family default
9236  (2.12), 
9237 \family typewriter
9238
9239 \backslash
9240 begin{mathletters}
9241 \family default
9242  (2.12), 
9243 \family typewriter
9244
9245 \backslash
9246 begin{thebibliography}
9247 \family default
9248  (2.13.1), 
9249 \family typewriter
9250
9251 \backslash
9252 bibitem
9253 \family default
9254  (2.13.2), all the cite commands and their variations (2.13.2), the generic
9255  graphicx figure commands (2.14.1), 
9256 \family typewriter
9257
9258 \backslash
9259 begin{table}
9260 \family default
9261  (2.15.4), 
9262 \family typewriter
9263
9264 \backslash
9265 begin{tabular}
9266 \family default
9267  (2.15.4), 
9268 \family typewriter
9269
9270 \backslash
9271 caption
9272 \family default
9273  (2.15.4), 
9274 \family typewriter
9275
9276 \backslash
9277 label
9278 \family default
9279  (2.15.4, amongst other places), 
9280 \family typewriter
9281
9282 \backslash
9283 tablerefs
9284 \family default
9285  (2.15.5), 
9286 \family typewriter
9287
9288 \backslash
9289 tablecomments
9290 \family default
9291  (2.15.5), 
9292 \family typewriter
9293
9294 \backslash
9295 url
9296 \family default
9297  (2.17.4), 
9298 \family typewriter
9299
9300 \backslash
9301 end{document}
9302 \family default
9303  (2.18).
9304 \end_layout
9305
9306 \begin_layout Standard
9307 The following style options also work correctly: 
9308 \family typewriter
9309 longabstract
9310 \family default
9311  (2.4), 
9312 \family typewriter
9313 preprint
9314 \family default
9315  (3.2.1), 
9316 \family typewriter
9317 preprint2
9318 \family default
9319  (3.2.2), 
9320 \family typewriter
9321 eqsecnum
9322 \family default
9323  (3.3), 
9324 \family typewriter
9325 flushrt
9326 \family default
9327  (3.4).
9328  Simply put them in the 
9329 \family sans
9330 Options
9331 \family default
9332  box in 
9333 \family sans
9334 Layout\SpecialChar menuseparator
9335 Document
9336 \family default
9337 .
9338 \end_layout
9339
9340 \begin_layout Subsubsection
9341 Things that work, but require more comment
9342 \end_layout
9343
9344 \begin_layout Standard
9345 The following items work, but require a little more discussion:
9346 \end_layout
9347
9348 \begin_layout Itemize
9349 These items are reserved for use by the journal editors, but you can put
9350  them into the \SpecialChar LaTeX
9351  preamble if you feel compelled to do so: 
9352 \family typewriter
9353
9354 \backslash
9355 received
9356 \family default
9357
9358 \family typewriter
9359
9360 \backslash
9361 revised
9362 \family default
9363
9364 \family typewriter
9365
9366 \backslash
9367 accepted
9368 \family default
9369
9370 \family typewriter
9371
9372 \backslash
9373 ccc
9374 \family default
9375
9376 \family typewriter
9377
9378 \backslash
9379 cpright
9380 \family default
9381  (all from 2.1.3)
9382 \end_layout
9383
9384 \begin_layout Itemize
9385 These items may be placed in the \SpecialChar LaTeX
9386  preamble, and are included as blanks in
9387  the template file: 
9388 \family typewriter
9389
9390 \backslash
9391 slugcomment
9392 \family default
9393  (2.1.4), 
9394 \family typewriter
9395
9396 \backslash
9397 shorttitle
9398 \family default
9399  (2.1.5), 
9400 \family typewriter
9401
9402 \backslash
9403 shortauthors
9404 \family default
9405  (2.1.5)
9406 \end_layout
9407
9408 \begin_layout Itemize
9409
9410 \family typewriter
9411
9412 \backslash
9413 email
9414 \family default
9415  (2.3) â€“ can only be used 
9416 \begin_inset Quotes eld
9417 \end_inset
9418
9419 standalone
9420 \begin_inset Quotes erd
9421 \end_inset
9422
9423 , not in the middle of a paragraph.
9424  Use \SpecialChar TeX
9425  code if you need to embed it.
9426 \end_layout
9427
9428 \begin_layout Itemize
9429
9430 \family typewriter
9431
9432 \backslash
9433 and
9434 \family default
9435  (2.3) â€“ will have extra {} after it.
9436  This should not cause an error.
9437 \end_layout
9438
9439 \begin_layout Itemize
9440
9441 \family typewriter
9442
9443 \backslash
9444 notetoeditor
9445 \family default
9446  (2.6) â€“ can only be used 
9447 \begin_inset Quotes eld
9448 \end_inset
9449
9450 standalone
9451 \begin_inset Quotes erd
9452 \end_inset
9453
9454 , not in the middle of a paragraph.
9455  Use \SpecialChar TeX
9456  code if you need to embed it.
9457 \end_layout
9458
9459 \begin_layout Itemize
9460
9461 \family typewriter
9462
9463 \backslash
9464 placetable
9465 \family default
9466  (2.8) â€“ can't insert a cross-reference tag, you must type the tag name by
9467  hand
9468 \end_layout
9469
9470 \begin_layout Itemize
9471
9472 \family typewriter
9473
9474 \backslash
9475 placefigure
9476 \family default
9477  (2.8) â€“ same as for 
9478 \family typewriter
9479
9480 \backslash
9481 placetable
9482 \end_layout
9483
9484 \begin_layout Itemize
9485
9486 \family typewriter
9487
9488 \backslash
9489 acknowledgements
9490 \family default
9491  (2.9) â€“ will have extra {} after it.
9492  This should not cause an error.
9493 \end_layout
9494
9495 \begin_layout Itemize
9496
9497 \family typewriter
9498
9499 \backslash
9500 appendix
9501 \family default
9502  (2.11) â€“ will have extra {} after it.
9503  This should not cause an error.
9504 \end_layout
9505
9506 \begin_layout Itemize
9507
9508 \family typewriter
9509
9510 \backslash
9511 figcaption
9512 \family default
9513  (2.14.2) â€“ you can insert an optional filename argument by placing the cursor
9514  at the beginning of the text and selecting 
9515 \family sans
9516 Insert\SpecialChar menuseparator
9517 Short Title
9518 \family default
9519 .
9520  
9521 \begin_inset Quotes eld
9522 \end_inset
9523
9524 Short Title
9525 \begin_inset Quotes erd
9526 \end_inset
9527
9528  inserts an optional argument of the type needed by 
9529 \family typewriter
9530
9531 \backslash
9532 figcaption
9533 \family default
9534 .
9535  Hopefully it will be renamed someday.
9536 \end_layout
9537
9538 \begin_layout Itemize
9539
9540 \family typewriter
9541
9542 \backslash
9543 objectname
9544 \family default
9545  (2.17.1) â€“ same as 
9546 \family typewriter
9547
9548 \backslash
9549 figcaption
9550 \family default
9551  for the catalog ID optional parameter
9552 \end_layout
9553
9554 \begin_layout Itemize
9555
9556 \family typewriter
9557
9558 \backslash
9559 dataset
9560 \family default
9561  (2.17.1) â€“ same as 
9562 \family typewriter
9563
9564 \backslash
9565 figcaption
9566 \family default
9567  for the catalog ID optional parameter
9568 \end_layout
9569
9570 \begin_layout Subsubsection
9571 Things not implemented, use \SpecialChar TeX
9572  code
9573 \end_layout
9574
9575 \begin_layout Standard
9576
9577 \family typewriter
9578
9579 \backslash
9580 eqnum
9581 \family default
9582  (2.12), 
9583 \family typewriter
9584
9585 \backslash
9586 setcounter{equation}
9587 \family default
9588  (2.12), Journal name abbreviations (2.13.4), 
9589 \family typewriter
9590
9591 \backslash
9592 figurenum
9593 \family default
9594  (2.14.1), 
9595 \family typewriter
9596
9597 \backslash
9598 epsscale
9599 \family default
9600  (2.14.1), 
9601 \family typewriter
9602
9603 \backslash
9604 plotone
9605 \family default
9606  (2.14.1), 
9607 \family typewriter
9608
9609 \backslash
9610 plottwo
9611 \family default
9612  (2.14.1), 
9613 \family typewriter
9614
9615 \backslash
9616 tablenum
9617 \family default
9618  (2.15.4), 
9619 \family typewriter
9620
9621 \backslash
9622 tableline
9623 \family default
9624  (2.15.4, insert it as the first element in the lefthand cell after where
9625  you want it.
9626  Don't use any of \SpecialChar LyX
9627 's rules in the table), 
9628 \family typewriter
9629
9630 \backslash
9631 tablenotemark
9632 \family default
9633  (2.15.5), 
9634 \family typewriter
9635
9636 \backslash
9637 tablenotetext
9638 \family default
9639  (2.15.5), much of Misc (2.17, except 
9640 \family typewriter
9641
9642 \backslash
9643 objectname
9644 \family default
9645
9646 \family typewriter
9647
9648 \backslash
9649 dataset
9650 \family default
9651
9652 \family typewriter
9653
9654 \backslash
9655 url
9656 \family default
9657 , and 
9658 \family typewriter
9659
9660 \backslash
9661 email
9662 \family default
9663 ; see above), 
9664 \family typewriter
9665
9666 \backslash
9667 singlespace
9668 \family default
9669  (3.1), 
9670 \family typewriter
9671
9672 \backslash
9673 doublespace
9674 \family default
9675  (3.1), 
9676 \family typewriter
9677
9678 \backslash
9679 onecolumn
9680 \family default
9681  (3.2), 
9682 \family typewriter
9683
9684 \backslash
9685 twocolumn
9686 \family default
9687  (3.2)
9688 \end_layout
9689
9690 \begin_layout Subsubsection
9691 Things that cannot be implemented
9692 \end_layout
9693
9694 \begin_layout Standard
9695 \SpecialChar ldots
9696  at least in any meaningful sort of way, so I suggest ignoring them.
9697  They are the references environment (2.13.3), and the deluxetable environment
9698  (2.15).
9699  If you really, really need to use deluxetable, I suggest editing it in
9700  a separate file with a text editor, then using 
9701 \family sans
9702 Insert\SpecialChar menuseparator
9703 Child
9704 \begin_inset space ~
9705 \end_inset
9706
9707 Document
9708 \family default
9709  to include it in your \SpecialChar LyX
9710  document.
9711  See the 
9712 \family typewriter
9713 aas_sample.lyx
9714 \family default
9715  file to see an example of this.
9716 \end_layout
9717
9718 \begin_layout Subsection
9719 FAQs, Tips, Tricks, and Other Ruminations
9720 \end_layout
9721
9722 \begin_layout Subsubsection
9723 Getting \SpecialChar LyX
9724  and AAS\SpecialChar TeX
9725  to cooperate
9726 \end_layout
9727
9728 \begin_layout Standard
9729 It can be a bit tricky to get \SpecialChar LyX
9730  to recognize a new layout and document class.
9731  When all else fails, do this:
9732 \end_layout
9733
9734 \begin_layout Enumerate
9735 Make certain that \SpecialChar LaTeX
9736  can find AAS\SpecialChar TeX
9737 .
9738  Copy sample.tex (and perhaps table.tex) from the AAS\SpecialChar TeX
9739  distribution into a
9740  directory completely unrelated to \SpecialChar LaTeX
9741  or AAS\SpecialChar TeX
9742  and run \SpecialChar LaTeX
9743  on 
9744 \family typewriter
9745 sample.tex
9746 \family default
9747 .
9748 \end_layout
9749
9750 \begin_layout Enumerate
9751 Make certain that 
9752 \family typewriter
9753 aastex.layout
9754 \family default
9755  appears in \SpecialChar LyX
9756 's 
9757 \family typewriter
9758 layouts
9759 \family default
9760  folder
9761 \end_layout
9762
9763 \begin_layout Enumerate
9764 Rerun 
9765 \family sans
9766 Tools\SpecialChar menuseparator
9767 Reconfigure
9768 \family default
9769  in \SpecialChar LyX
9770 , then restart \SpecialChar LyX
9771 .
9772 \end_layout
9773
9774 \begin_layout Enumerate
9775 Open a regular new file, not from a template.
9776  Does AAS\SpecialChar TeX
9777  appear in the class list in 
9778 \family sans
9779 Document\SpecialChar menuseparator
9780 Settings
9781 \family default
9782 ?
9783 \end_layout
9784
9785 \begin_layout Standard
9786 If you get a warning from an existing AAS\SpecialChar TeX
9787  document about not being able
9788  to find the AAS\SpecialChar TeX
9789  layout or a message about 
9790 \begin_inset Quotes eld
9791 \end_inset
9792
9793 You should not mix title layouts with normal ones
9794 \begin_inset Quotes erd
9795 \end_inset
9796
9797 , things haven't been installed correctly.
9798 \end_layout
9799
9800 \begin_layout Subsubsection
9801 \SpecialChar LaTeX
9802  error processing a table 
9803 \end_layout
9804
9805 \begin_layout Standard
9806 \SpecialChar LyX
9807 , by default, attempts to center the table caption/title.
9808  This seems to produce a bad interaction in AAS\SpecialChar TeX
9809  so you should click somewhere
9810  in the caption/title, then select 
9811 \family sans
9812 Edit\SpecialChar menuseparator
9813 Paragraph
9814 \begin_inset space ~
9815 \end_inset
9816
9817 Settings
9818 \family default
9819 , then set the 
9820 \family sans
9821 Alignment
9822 \family default
9823  to 
9824 \family sans
9825 Block
9826 \family default
9827 .
9828  This took care of it for me.
9829 \end_layout
9830
9831 \begin_layout Subsubsection
9832 References
9833 \end_layout
9834
9835 \begin_layout Standard
9836 A couple of things: 1) I have noticed some funny spacing in the reference
9837  entries in the text.
9838  When you enter the bibliography item data, make sure their is 
9839 \emph on
9840 no
9841 \emph default
9842  space between the last author and the parenthesis setting off the year;
9843  
9844 \emph on
9845 e.
9846 \begin_inset space \thinspace{}
9847 \end_inset
9848
9849 g.
9850 \begin_inset space \space{}
9851 \end_inset
9852
9853
9854 \emph default
9855 type 
9856 \family typewriter
9857 Ressler(1992)
9858 \family default
9859 , not 
9860 \family typewriter
9861 Ressler (1992)
9862 \family default
9863 .
9864  2) Entering the references at all is not obvious.
9865  The easiest thing is to start typing your first reference at the end of
9866  the document, then mark it as type 
9867 \family sans
9868 References
9869 \family default
9870 .
9871  That will put a small gray box in front of what you just typed.
9872  Click on the box to fill in the rest of the information.
9873  For new references, go to the end of an existing reference and press return.
9874  That will create a new line with its own box, etc.
9875 \end_layout
9876
9877 \begin_layout Subsubsection
9878 Including EPS files
9879 \end_layout
9880
9881 \begin_layout Standard
9882 Even though AAS\SpecialChar TeX
9883  provides its own figure commands (
9884 \family typewriter
9885
9886 \backslash
9887 plotone
9888 \family default
9889 , for example), I much prefer \SpecialChar LaTeX
9890 's standard figure commands (with the default
9891  graphicx).
9892  You can insert the 
9893 \family typewriter
9894
9895 \backslash
9896 plotone
9897 \family default
9898 , etc.
9899 \begin_inset space ~
9900 \end_inset
9901
9902 commands as \SpecialChar TeX
9903  code into a Figure Float box if you desire, but I never have
9904  much luck getting the layout right.
9905  With the standard graphics, \SpecialChar LyX
9906  will insert a 
9907 \family typewriter
9908
9909 \backslash
9910 usepackage{graphicx}
9911 \family default
9912  command into the \SpecialChar LaTeX
9913  preamble and handle the figures in the standard \SpecialChar LaTeX2e
9914  way,
9915  interspersing the figures in the text.
9916  I believe ApJ accepts figures exactly this way now; AJ might still use
9917  the 
9918 \begin_inset Quotes eld
9919 \end_inset
9920
9921 stack everything at the end
9922 \begin_inset Quotes erd
9923 \end_inset
9924
9925  technique.
9926 \end_layout
9927
9928 \begin_layout Subsubsection
9929 Things I could have done, but didn't
9930 \end_layout
9931
9932 \begin_layout Standard
9933 There are a few 
9934 \begin_inset Quotes eld
9935 \end_inset
9936
9937 pretty
9938 \begin_inset Quotes erd
9939 \end_inset
9940
9941  things I could have implemented, but chose not to.
9942  For instance, I saw no point in double-spacing the text in the \SpecialChar LyX
9943  window,
9944  even though it is double-spaced in the paper manuscript.
9945  Also, I chose not to make separate layouts for the preprint and preprint2
9946  styles.
9947  Since I assume you will spend most of your time in the plain manuscript
9948  mode anyway, I decided not to chew up more disk space with this.
9949  
9950 \end_layout
9951
9952 \begin_layout Subsection
9953 Final Caveat
9954 \end_layout
9955
9956 \begin_layout Standard
9957 Your mileage may vary.
9958  I've now had papers published by both ApJ and AJ that have had 98% of the
9959  effort done in \SpecialChar LyX
9960 ; the last 2% was the \SpecialChar LaTeX
9961  post-processing and a few cleanups.
9962  I have had no trouble with the submission process, and I'm sure the journals
9963  were never aware that there might be a difference.
9964  So, go forth and publish!
9965 \end_layout
9966
9967 \begin_layout Section
9968 AMS \SpecialChar LaTeX
9969
9970 \end_layout
9971
9972 \begin_layout Standard
9973 by 
9974 \noun on
9975 David Johnson
9976 \noun default
9977 ; updated by 
9978 \noun on
9979 Richard Heck
9980 \end_layout
9981
9982 \begin_layout Standard
9983 \begin_inset VSpace bigskip
9984 \end_inset
9985
9986
9987 \end_layout
9988
9989 \begin_layout Standard
9990 \noindent
9991 The AMS \SpecialChar LaTeX
9992  layouts are set up to conform to suggested styles for mathematical
9993  papers to be submitted to American Mathematical Society publications.
9994  The layouts are not tailored to a specific journal, but easily can be.
9995  You should refer to the AMS documentation for specific instructions for
9996  each journal (usually it will entail only changing a single line in the
9997  \SpecialChar TeX
9998  output).
9999  That documentation is available on the Web at 
10000 \begin_inset Flex URL
10001 status open
10002
10003 \begin_layout Plain Layout
10004
10005 http://www.ams.org
10006 \end_layout
10007
10008 \end_inset
10009
10010  or by ftp at 
10011 \begin_inset Flex URL
10012 status open
10013
10014 \begin_layout Plain Layout
10015
10016 ftp://ftp.ams.org/pub/tex/amslatex/
10017 \end_layout
10018
10019 \end_inset
10020
10021 .
10022  These layouts are appropriate, and useful, for any mathematical writing.
10023  
10024 \end_layout
10025
10026 \begin_layout Standard
10027 There are two basic AMS \SpecialChar LaTeX
10028  layouts: 
10029 \end_layout
10030
10031 \begin_layout Itemize
10032 amsart: The standard AMS article format.
10033 \end_layout
10034
10035 \begin_layout Itemize
10036 amsbook: the standard AMS book (really, monograph) format.
10037  
10038 \end_layout
10039
10040 \begin_layout Standard
10041 The layouts themselves contain only the minimum necessary to use the AMS
10042  classes.
10043  They do not, in particular, contain any of the `theorem' environments used
10044  for setting theorems, lemmas, and the like.
10045  These are contained, instead, in the 
10046 \begin_inset Flex Code
10047 status collapsed
10048
10049 \begin_layout Plain Layout
10050 Theorems (AMS)
10051 \end_layout
10052
10053 \end_inset
10054
10055  module, which is loaded by default when you select one of the AMS classes.
10056  (It can also be used with other classes and can be removed, if you would
10057  rather use something else.) Less commonly used environments are in the 
10058 \begin_inset Flex Code
10059 status collapsed
10060
10061 \begin_layout Plain Layout
10062 Theorems (AMS-Extended)
10063 \end_layout
10064
10065 \end_inset
10066
10067  module, which must be loaded manually.
10068 \end_layout
10069
10070 \begin_layout Standard
10071 By default, theorems and the like are numbered consecutively throughout
10072  the document, but this may be modified by loading the module 
10073 \begin_inset Flex Code
10074 status collapsed
10075
10076 \begin_layout Plain Layout
10077 Theorems (Order by Section)
10078 \end_layout
10079
10080 \end_inset
10081
10082  or, if you are using 
10083 \begin_inset Flex Code
10084 status collapsed
10085
10086 \begin_layout Plain Layout
10087 book (AMS)
10088 \end_layout
10089
10090 \end_inset
10091
10092 , the module 
10093 \begin_inset Flex Code
10094 status collapsed
10095
10096 \begin_layout Plain Layout
10097 Theorems (Order by Chapter)
10098 \end_layout
10099
10100 \end_inset
10101
10102 .
10103  These will number the results as 
10104 \begin_inset Formula $n.m$
10105 \end_inset
10106
10107 , where the first number refers to the section (or chapter) and the second
10108  refers to the total number of results so far in that section (or chapter).
10109  Many environments are also available unnumbered.
10110  These are indicated by an asterisk at the end.
10111  If you happen to want 
10112 \emph on
10113 only
10114 \emph default
10115  unnumbered results, the module 
10116 \begin_inset Flex Code
10117 status collapsed
10118
10119 \begin_layout Plain Layout
10120 Theorems (Starred)
10121 \end_layout
10122
10123 \end_inset
10124
10125  provides that option.
10126 \end_layout
10127
10128 \begin_layout Standard
10129 Note that these modules do not 
10130 \emph on
10131 have
10132 \emph default
10133  to be used with the AMS classes.
10134  It is perfectly possible to use the 
10135 \begin_inset Flex Code
10136 status collapsed
10137
10138 \begin_layout Plain Layout
10139 Theorems (AMS)
10140 \end_layout
10141
10142 \end_inset
10143
10144  module, and the others mentioned, with other classes, such as 
10145 \begin_inset Flex Code
10146 status collapsed
10147
10148 \begin_layout Plain Layout
10149 article
10150 \end_layout
10151
10152 \end_inset
10153
10154
10155 \begin_inset Flex Code
10156 status collapsed
10157
10158 \begin_layout Plain Layout
10159 report
10160 \end_layout
10161
10162 \end_inset
10163
10164
10165 \begin_inset Flex Code
10166 status collapsed
10167
10168 \begin_layout Plain Layout
10169 book (KOMA-script)
10170 \end_layout
10171
10172 \end_inset
10173
10174 , and so forth.
10175 \end_layout
10176
10177 \begin_layout Subsection
10178 What these layouts provide
10179 \end_layout
10180
10181 \begin_layout Standard
10182 There is a long list of included environments provided by these layouts.
10183  In AMS-\SpecialChar LaTeX
10184 , there is, in fact, an opportunity to define an unlimited variety
10185  of `theorem' environments.
10186  However, the AMS recommends the environments that are available in \SpecialChar LyX
10187 .
10188  
10189 \end_layout
10190
10191 \begin_layout Standard
10192 The following environments—as well as the standard environments, such as
10193  
10194 \begin_inset Flex Noun
10195 status collapsed
10196
10197 \begin_layout Plain Layout
10198 section
10199 \end_layout
10200
10201 \end_inset
10202
10203
10204 \begin_inset Flex Noun
10205 status collapsed
10206
10207 \begin_layout Plain Layout
10208 bibliography
10209 \end_layout
10210
10211 \end_inset
10212
10213
10214 \begin_inset Flex Noun
10215 status collapsed
10216
10217 \begin_layout Plain Layout
10218 title
10219 \end_layout
10220
10221 \end_inset
10222
10223
10224 \begin_inset Flex Noun
10225 status collapsed
10226
10227 \begin_layout Plain Layout
10228 author
10229 \end_layout
10230
10231 \end_inset
10232
10233 , and 
10234 \begin_inset Flex Noun
10235 status collapsed
10236
10237 \begin_layout Plain Layout
10238 date
10239 \end_layout
10240
10241 \end_inset
10242
10243 —are provided by 
10244 \begin_inset Flex Code
10245 status collapsed
10246
10247 \begin_layout Plain Layout
10248 article (AMS)
10249 \end_layout
10250
10251 \end_inset
10252
10253  and 
10254 \begin_inset Flex Code
10255 status collapsed
10256
10257 \begin_layout Plain Layout
10258 book (AMS)
10259 \end_layout
10260
10261 \end_inset
10262
10263 :
10264 \end_layout
10265
10266 \begin_layout Description
10267 Address This should be the author's permanent address.
10268 \end_layout
10269
10270 \begin_layout Description
10271 Current
10272 \begin_inset space ~
10273 \end_inset
10274
10275 Address This should be the author's temporary address at the time of submission,
10276  if different from the Address.
10277 \end_layout
10278
10279 \begin_layout Description
10280 Email Author's e-mail address
10281 \end_layout
10282
10283 \begin_layout Description
10284 URL Author's Web address, if desired.
10285 \end_layout
10286
10287 \begin_layout Description
10288 Keywords Key words or phrases used to identify specific topics discussed
10289  in the paper.
10290 \end_layout
10291
10292 \begin_layout Description
10293 Subjectclass These refer to the AMS Subject Classifications, published and
10294  described in 
10295 \emph on
10296 Mathematical Reviews
10297 \emph default
10298 .
10299  These are also available online at the AMS cites listed above.
10300 \end_layout
10301
10302 \begin_layout Description
10303 Thanks
10304 \end_layout
10305
10306 \begin_layout Description
10307 Dedicatory
10308 \end_layout
10309
10310 \begin_layout Description
10311 Translator
10312 \end_layout
10313
10314 \begin_layout Standard
10315 The following environments are provided by both the 
10316 \begin_inset Flex Code
10317 status collapsed
10318
10319 \begin_layout Plain Layout
10320 Theorems
10321 \end_layout
10322
10323 \end_inset
10324
10325  and 
10326 \begin_inset Flex Code
10327 status collapsed
10328
10329 \begin_layout Plain Layout
10330 Theorems (AMS)
10331 \end_layout
10332
10333 \end_inset
10334
10335  modules, in the latter case in both starred (unnumbered) and unstarred
10336  (numbered) versions.
10337  These same environments are provided only in the starred versions by the
10338  
10339 \begin_inset Flex Code
10340 status collapsed
10341
10342 \begin_layout Plain Layout
10343 Theorems (Starred)
10344 \end_layout
10345
10346 \end_inset
10347
10348  module:
10349 \end_layout
10350
10351 \begin_layout Theorem
10352 This is typically used for the statements of major results.
10353  
10354 \end_layout
10355
10356 \begin_layout Corollary*
10357 This is used for statements which follow fairly directly from previous statement
10358 s.
10359  Again, these can be major results.
10360  
10361 \end_layout
10362
10363 \begin_layout Lemma
10364 These are smaller results needed to prove other statements.
10365 \end_layout
10366
10367 \begin_layout Proposition
10368 These are less major results which (hopefully) add to the general theory
10369  being discussed.
10370 \end_layout
10371
10372 \begin_layout Conjecture
10373 These are statements provided without justification, which the author does
10374  not know how to prove, but which seem to be true (to the author, at least).
10375 \end_layout
10376
10377 \begin_layout Definition*
10378 Guess what this is for.
10379  The font is different for this environment than for the previous ones.
10380  
10381 \end_layout
10382
10383 \begin_layout Example*
10384 Used for examples illustrating proven results.
10385 \end_layout
10386
10387 \begin_layout Problem
10388 It's not really known what this is for.
10389  You should figure it out.
10390 \end_layout
10391
10392 \begin_layout Exercise*
10393 Write a description for this one.
10394 \end_layout
10395
10396 \begin_layout Remark
10397 This environment is also a type of theorem, usually a lesser sort of observation.
10398 \end_layout
10399
10400 \begin_layout Claim*
10401 Often used in the course of giving a proof of a larger result.
10402 \end_layout
10403
10404 \begin_layout Case
10405 Generally, these are used to break up long arguments, using specific instances
10406  of some condition.
10407  
10408 \end_layout
10409
10410 \begin_layout Case
10411 The numbering scheme for cases is on its own, not together with other numbered
10412  statements.
10413  
10414 \end_layout
10415
10416 \begin_layout Proof
10417 At the end of this environment, a QED symbol (usually a square, but it can
10418  vary with different styles) is placed.
10419  If you want to have other environments within this one—for example, Case
10420  environments—and have the QED symbol appear only after them, then the other
10421  environments need to be nested within the proof environment.
10422  See the section 
10423 \emph on
10424 Nesting Environments
10425 \emph default
10426  of the 
10427 \emph on
10428 User's Guide
10429 \emph default
10430  for information on nesting.
10431 \end_layout
10432
10433 \begin_layout Standard
10434 And these environments are provided by 
10435 \begin_inset Flex Code
10436 status collapsed
10437
10438 \begin_layout Plain Layout
10439 Theorems (AMS-Extended)
10440 \end_layout
10441
10442 \end_inset
10443
10444 :
10445 \end_layout
10446
10447 \begin_layout Criterion*
10448 A required condition.
10449 \end_layout
10450
10451 \begin_layout Algorithm*
10452 A general procedure to be used.
10453 \end_layout
10454
10455 \begin_layout Axiom*
10456 This is a property or statement taken as true within the system being discussed.
10457 \end_layout
10458
10459 \begin_layout Condition*
10460 Sometimes used to state a condition assumed within the present context of
10461  discussion.
10462 \end_layout
10463
10464 \begin_layout Note*
10465 Similar to a Remark.
10466 \end_layout
10467
10468 \begin_layout Notation*
10469 Used for the explanation of, yes, notation.
10470 \end_layout
10471
10472 \begin_layout Summary
10473 Do we really need to tell you? 
10474 \end_layout
10475
10476 \begin_layout Acknowledgement*
10477 Acknowledgement.
10478 \end_layout
10479
10480 \begin_layout Conclusion*
10481 Sometimes used at the end of a long train of argument.
10482 \end_layout
10483
10484 \begin_layout Fact
10485 Used in a way similar to Proposition, though perhaps lower on the scale.
10486 \end_layout
10487
10488 \begin_layout Standard
10489 In addition, the AMS classes automatically provide the AMS \SpecialChar LaTeX
10490  and AMS fonts
10491  packages.
10492  They need to be available on your system in order to use these environments.
10493 \end_layout
10494
10495 \begin_layout Section
10496 AGU journals (
10497 \family sans
10498 aguplus
10499 \family default
10500 )
10501 \end_layout
10502
10503 \begin_layout Standard
10504 by 
10505 \shape smallcaps
10506 Martin Vermeer
10507 \end_layout
10508
10509 \begin_layout Subsection
10510 Description
10511 \end_layout
10512
10513 \begin_layout Standard
10514 These are the layout files for some of the journals of the American Geophysical
10515  Society.
10516  It is assumed that you have both the AGU's own class files and AGUplus
10517  installed (everything to be found at
10518 \begin_inset Flex URL
10519 status collapsed
10520
10521 \begin_layout Plain Layout
10522
10523 http://publications.agu.org/files/2013/08/AGU-LaTeX.zip
10524 \end_layout
10525
10526 \end_inset
10527
10528 ).
10529 \end_layout
10530
10531 \begin_layout Subsection
10532 New styles
10533 \end_layout
10534
10535 \begin_layout Standard
10536 Redefined are 
10537 \family sans
10538 Paragraph
10539 \family default
10540
10541 \family sans
10542 Paragraph*
10543 \family default
10544 .
10545  They are still called this in the \SpecialChar LyX
10546  GUI, though their \SpecialChar LaTeX
10547  equivalents in the
10548  AGU classes are 
10549 \family sans
10550 Subsubsubsection
10551 \family default
10552  and 
10553 \family sans
10554 Subsubsubsection*
10555 \family default
10556 .
10557 \end_layout
10558
10559 \begin_layout Standard
10560 Newly defined styles are 
10561 \family sans
10562 Left_Header
10563 \family default
10564
10565 \family sans
10566 Right_Header
10567 \family default
10568
10569 \family sans
10570 Received
10571 \family default
10572
10573 \family sans
10574 Revised
10575 \family default
10576
10577 \family sans
10578 Accepted
10579 \family default
10580
10581 \family sans
10582 CCC
10583 \family default
10584
10585 \family sans
10586 PaperId
10587 \family default
10588
10589 \family sans
10590 AuthorAddr
10591 \family default
10592
10593 \family sans
10594 SlugComment
10595 \family default
10596 .
10597  These are mostly manuscript attributes and defined in the AGU class documentati
10598 on.
10599 \end_layout
10600
10601 \begin_layout Standard
10602 I suspect this is still badly incomplete.
10603 \end_layout
10604
10605 \begin_layout Subsection
10606 New floats
10607 \end_layout
10608
10609 \begin_layout Standard
10610
10611 \family sans
10612 Planotable
10613 \family default
10614  and 
10615 \family sans
10616 Plate
10617 \family default
10618 .
10619  We also have a new 
10620 \family sans
10621 Table_Caption
10622 \family default
10623 .
10624 \end_layout
10625
10626 \begin_layout Subsection
10627 Supported journals
10628 \end_layout
10629
10630 \begin_layout Itemize
10631
10632 \emph on
10633 Journal of Geophysical Research
10634 \emph default
10635
10636 \family typewriter
10637 jgrga.layout
10638 \family default
10639  â€” Martin Vermeer
10640 \end_layout
10641
10642 \begin_layout Standard
10643 Add your own, it isn't so hard! Look at the 
10644 \family typewriter
10645 jgrga.layout
10646 \family default
10647  example and 
10648 \family typewriter
10649 aguplus.inc
10650 \family default
10651 .
10652 \end_layout
10653
10654 \begin_layout Subsection
10655 Bugs and things to remember
10656 \end_layout
10657
10658 \begin_layout Standard
10659 In order to use the new layouts, you must remember to do the following for
10660  a new document:
10661 \end_layout
10662
10663 \begin_layout Enumerate
10664
10665 \emph on
10666 Turn off babel
10667 \emph default
10668 .
10669  This can be done in the 
10670 \family sans
10671 Layout\SpecialChar menuseparator
10672 Document
10673 \family default
10674  or 
10675 \family sans
10676 Document\SpecialChar menuseparator
10677 Settings
10678 \family default
10679  menu item.
10680  (AGU articles are always in English, right? So 
10681 \emph on
10682 don't
10683 \emph default
10684  choose a language.)
10685 \end_layout
10686
10687 \begin_layout Enumerate
10688 Enter 
10689 \family typewriter
10690 jgrga
10691 \family default
10692  into the document's 
10693 \family sans
10694 Extra Options
10695 \family default
10696  field.
10697  (Yes, this is a bug.)
10698 \end_layout
10699
10700 \begin_layout Enumerate
10701 Make sure you use the 
10702 \family typewriter
10703 agu.bst
10704 \family default
10705  bibliography style, by entering 
10706 \family sans
10707 agu
10708 \family default
10709  into the second field of the Bib\SpecialChar TeX
10710  inset.
10711  None of the standard styles will do.
10712 \end_layout
10713
10714 \begin_layout Section
10715 Broadway
10716 \end_layout
10717
10718 \begin_layout Standard
10719 by 
10720 \shape smallcaps
10721 Garst Reese
10722 \end_layout
10723
10724 \begin_layout Subsection
10725 Introduction
10726 \end_layout
10727
10728 \begin_layout Standard
10729 Broadway is for writing plays.
10730  The format is more decorative than Hollywood, and much less standardized.
10731  This format should be suitable for workshops.
10732 \end_layout
10733
10734 \begin_layout Subsection
10735 Special problems
10736 \end_layout
10737
10738 \begin_layout Standard
10739 The same as in Hollywood.
10740 \end_layout
10741
10742 \begin_layout Subsection
10743 Special features
10744 \end_layout
10745
10746 \begin_layout Standard
10747 Insert the 
10748 \family sans
10749 Speaker
10750 \family default
10751  names as labels then cross-reference the label to insert the name.
10752  The cross-reference dialog will show the current cast of characters.
10753 \end_layout
10754
10755 \begin_layout Subsection
10756 Paper size and Margins
10757 \end_layout
10758
10759 \begin_layout Standard
10760 USLetter, left 1.6in, right 0.75in, top 0.5in, bottom 0.75in
10761 \end_layout
10762
10763 \begin_layout Subsection
10764 Environments
10765 \end_layout
10766
10767 \begin_layout Standard
10768 The following environments are available.
10769  You can use broadway.bind to get the bind keys shown at the right.
10770 \end_layout
10771
10772 \begin_layout Itemize
10773
10774 \family sans
10775 Standard
10776 \begin_inset Newline newline
10777 \end_inset
10778
10779
10780 \family default
10781 You should not have to use this, but it is here for anything that does not
10782  fit otherwise.
10783 \end_layout
10784
10785 \begin_layout Itemize
10786
10787 \family sans
10788 Narrative
10789 \begin_inset space \hfill{}
10790 \end_inset
10791
10792 M-z n
10793 \begin_inset Newline newline
10794 \end_inset
10795
10796
10797 \family default
10798 Used to describe stage setting and the action.
10799  First use of speaker names in all CAPs.
10800 \end_layout
10801
10802 \begin_layout Itemize
10803
10804 \family sans
10805 ACT
10806 \begin_inset space \hfill{}
10807 \end_inset
10808
10809 M-z a
10810 \begin_inset Newline newline
10811 \end_inset
10812
10813
10814 \family default
10815 Automatically numbered.
10816  On screen it will be arabic, but will print as Roman.
10817 \end_layout
10818
10819 \begin_layout Itemize
10820
10821 \family sans
10822 ACT*
10823 \begin_inset space \hfill{}
10824 \end_inset
10825
10826 M-z S at
10827 \begin_inset Newline newline
10828 \end_inset
10829
10830
10831 \family default
10832 Subtitle for 
10833 \family sans
10834 ACT.
10835
10836 \family default
10837  It is just centered text.
10838 \end_layout
10839
10840 \begin_layout Itemize
10841
10842 \family sans
10843 SCENE
10844 \begin_inset space \hfill{}
10845 \end_inset
10846
10847 M-z S-S
10848 \begin_inset Newline newline
10849 \end_inset
10850
10851
10852 \family default
10853 Not automatically numbered.
10854  You supply the number.
10855  This is because I couldn't figure out how.
10856 \end_layout
10857
10858 \begin_layout Itemize
10859
10860 \family sans
10861 AT_RISE:
10862 \begin_inset space \hfill{}
10863 \end_inset
10864
10865 M-z S-R
10866 \begin_inset Newline newline
10867 \end_inset
10868
10869
10870 \family default
10871 A special case of Narrative to describe the setting and action as the curtain
10872  rises.
10873 \end_layout
10874
10875 \begin_layout Itemize
10876
10877 \family sans
10878 Speaker
10879 \begin_inset space \hfill{}
10880 \end_inset
10881
10882 M-z s
10883 \begin_inset Newline newline
10884 \end_inset
10885
10886
10887 \family default
10888 The speaker's (actor's) title, centered in all CAPS.
10889 \end_layout
10890
10891 \begin_layout Itemize
10892
10893 \family sans
10894 Parenthetical
10895 \begin_inset space \hfill{}
10896 \end_inset
10897
10898 M-z p
10899 \begin_inset Newline newline
10900 \end_inset
10901
10902
10903 \family default
10904 Instructions to the speaker.
10905  The parentheses are automatically inserted.
10906  The ( will appear on screen, but both will be in the printed play.
10907  This environment is only used within 
10908 \family sans
10909 Dialogue
10910 \family default
10911 .
10912 \end_layout
10913
10914 \begin_layout Itemize
10915
10916 \family sans
10917 Dialogue
10918 \begin_inset space \hfill{}
10919 \end_inset
10920
10921 M-z d
10922 \begin_inset Newline newline
10923 \end_inset
10924
10925
10926 \family default
10927 What the Speaker says.
10928 \end_layout
10929
10930 \begin_layout Itemize
10931
10932 \family sans
10933 CURTAIN
10934 \begin_inset space \hfill{}
10935 \end_inset
10936
10937 M-z S-C
10938 \begin_inset Newline newline
10939 \end_inset
10940
10941
10942 \family default
10943 The curtain comes down.
10944 \end_layout
10945
10946 \begin_layout Itemize
10947
10948 \family sans
10949 Title
10950 \begin_inset space \hfill{}
10951 \end_inset
10952
10953 M-z S-T
10954 \end_layout
10955
10956 \begin_layout Itemize
10957
10958 \family sans
10959 Author
10960 \begin_inset space \hfill{}
10961 \end_inset
10962
10963 M-z S-A
10964 \end_layout
10965
10966 \begin_layout Itemize
10967
10968 \family sans
10969 Right_Address
10970 \begin_inset space \hfill{}
10971 \end_inset
10972
10973 M-z r
10974 \end_layout
10975
10976 \begin_layout Standard
10977 Hello there.
10978 \end_layout
10979
10980 \begin_layout Section
10981 Dinbrief
10982 \end_layout
10983
10984 \begin_layout Standard
10985 The document class 
10986 \family sans
10987 dinbrief
10988 \family default
10989  can be used to type letters according to German conventions.
10990  A template file is included in 
10991 \family typewriter
10992 .../lyx/share/templates
10993 \family default
10994  for you to use as a starting point.
10995 \end_layout
10996
10997 \begin_layout Section
10998 EGS journals (
10999 \family sans
11000 egs
11001 \family default
11002 )
11003 \end_layout
11004
11005 \begin_layout Standard
11006 by 
11007 \shape smallcaps
11008 Martin Vermeer
11009 \end_layout
11010
11011 \begin_layout Subsection
11012 Description
11013 \end_layout
11014
11015 \begin_layout Standard
11016 This is the layout file for the European Geophysical Society journals.
11017  The needed 
11018 \family typewriter
11019 egs.cls
11020 \family default
11021  can be downloaded from the web site of the EGS under 
11022 \begin_inset Flex URL
11023 status collapsed
11024
11025 \begin_layout Plain Layout
11026
11027 www.copernicus.org
11028 \end_layout
11029
11030 \end_inset
11031
11032 .
11033 \end_layout
11034
11035 \begin_layout Subsection
11036 New styles
11037 \end_layout
11038
11039 \begin_layout Standard
11040
11041 \family sans
11042 Right_address, Latex_Title, Affil, Journal, msnumber, FirstAuthor, Received,
11043  Accepted
11044 \family default
11045
11046 \family sans
11047 Offsets
11048 \family default
11049 .
11050  The current layout file is unfortunately very unmodular and would benefit
11051  from using the various 
11052 \family typewriter
11053 std*.inc
11054 \family default
11055  file inclusions.
11056 \end_layout
11057
11058 \begin_layout Section
11059 Elsevier Journals
11060 \end_layout
11061
11062 \begin_layout Standard
11063 See the \SpecialChar LyX
11064  template file 
11065 \family typewriter
11066 elsarticle.lyx
11067 \family default
11068 .
11069  It contains all infos you need.
11070 \end_layout
11071
11072 \begin_layout Section
11073 Foils [aka 
11074 \family sans
11075 Foil\SpecialChar TeX
11076
11077 \family default
11078 ]
11079 \begin_inset CommandInset label
11080 LatexCommand label
11081 name "sec:foiltex"
11082
11083 \end_inset
11084
11085
11086 \end_layout
11087
11088 \begin_layout Standard
11089 by 
11090 \noun on
11091 Allan Rae
11092 \end_layout
11093
11094 \begin_layout Subsection
11095 Introduction
11096 \end_layout
11097
11098 \begin_layout Standard
11099 This section describes how to use \SpecialChar LyX
11100  to make slides for overhead projectors.
11101  There are two document classes that can do this: the default slides class
11102  and the 
11103 \family sans
11104 Foil\SpecialChar TeX
11105
11106 \family default
11107  slides class.
11108  This section documents the latter.
11109 \end_layout
11110
11111 \begin_layout Standard
11112 I'm going to say this again, nice and clear, so that there's no misunderstanding
11113 :
11114 \end_layout
11115
11116 \begin_layout Standard
11117 \begin_inset VSpace bigskip
11118 \end_inset
11119
11120
11121 \end_layout
11122
11123 \begin_layout Standard
11124 \align center
11125
11126 \size large
11127 This section documents the class 
11128 \begin_inset Quotes eld
11129 \end_inset
11130
11131
11132 \family sans
11133 FoilTeX
11134 \family default
11135
11136 \begin_inset Quotes erd
11137 \end_inset
11138
11139  
11140 \emph on
11141 only.
11142 \end_layout
11143
11144 \begin_layout Standard
11145 \begin_inset VSpace bigskip
11146 \end_inset
11147
11148
11149 \end_layout
11150
11151 \begin_layout Standard
11152 If you're looking for the documentation for 
11153 \begin_inset Quotes eld
11154 \end_inset
11155
11156
11157 \family sans
11158 slides (default)
11159 \family default
11160
11161 \begin_inset Quotes erd
11162 \end_inset
11163
11164 , check out section
11165 \begin_inset space ~
11166 \end_inset
11167
11168
11169 \begin_inset CommandInset ref
11170 LatexCommand ref
11171 reference "sec:slitex"
11172
11173 \end_inset
11174
11175 .
11176  If your machine doesn't have the 
11177 \family sans
11178 foils
11179 \family default
11180  class 
11181 \family sans
11182 FoilTeX
11183 \family default
11184  installed, you'll probably have to use the default 
11185 \family sans
11186 slides
11187 \family default
11188  class, which isn't quite as good as 
11189 \family sans
11190 foils.
11191 \end_layout
11192
11193 \begin_layout Standard
11194 The 
11195 \family sans
11196 foils
11197 \family default
11198  class is designed for use with version
11199 \begin_inset space ~
11200 \end_inset
11201
11202 2.1 of the 
11203 \family sans
11204 foils.cls
11205 \family default
11206  \SpecialChar LaTeX
11207  class file which is now an integral part of \SpecialChar LaTeX2e
11208 .
11209 \end_layout
11210
11211 \begin_layout Subsection
11212 Getting Started
11213 \end_layout
11214
11215 \begin_layout Standard
11216 Obviously, to use this document class, you need to select 
11217 \family sans
11218 FoilTeX
11219 \family default
11220  from the 
11221 \family sans
11222 Class
11223 \family default
11224  entry in the 
11225 \family sans
11226 Document
11227 \begin_inset space ~
11228 \end_inset
11229
11230 Layout
11231 \family default
11232  dialog.
11233  There are some settings in the 
11234 \family sans
11235 Document
11236 \begin_inset space ~
11237 \end_inset
11238
11239 Layout
11240 \family default
11241  dialog that you should know about that are specific to this class:
11242 \end_layout
11243
11244 \begin_layout Itemize
11245 Don't change the options 
11246 \family sans
11247 Sides
11248 \family default
11249  and 
11250 \family sans
11251 Columns
11252 \family default
11253  on the 
11254 \family sans
11255 Document
11256 \begin_inset space ~
11257 \end_inset
11258
11259 Layout
11260 \family default
11261  dialog.
11262  They're ignored by the 
11263 \family sans
11264 foils
11265 \family default
11266  class.
11267 \end_layout
11268
11269 \begin_layout Itemize
11270 The default font size is 20
11271 \begin_inset space \thinspace{}
11272 \end_inset
11273
11274 pt with the other options being 17
11275 \begin_inset space \thinspace{}
11276 \end_inset
11277
11278 pt, 25
11279 \begin_inset space \thinspace{}
11280 \end_inset
11281
11282 pt and 30
11283 \begin_inset space \thinspace{}
11284 \end_inset
11285
11286 pt.
11287 \end_layout
11288
11289 \begin_layout Itemize
11290 The default font is 
11291 \family sans
11292 sans
11293 \family default
11294  
11295 \family sans
11296 serif
11297 \family default
11298  but all math equations are still typeset in the usual roman font.
11299 \end_layout
11300
11301 \begin_layout Itemize
11302
11303 \family sans
11304 Foil\SpecialChar TeX
11305
11306 \family default
11307  supports A4 and Letter paper sizes as well as a special size for working
11308  with 35
11309 \begin_inset space \thinspace{}
11310 \end_inset
11311
11312 mm slides.
11313  It doesn't support A5, B5, legal or executive paper sizes.
11314 \end_layout
11315
11316 \begin_layout Itemize
11317 Don't bother changing the 
11318 \family sans
11319 Float Placement
11320 \family default
11321  settings because they are ignored anyway.
11322  All floats appear where they are defined in the text.
11323 \end_layout
11324
11325 \begin_layout Itemize
11326 The 
11327 \family sans
11328 Pagestyle
11329 \family default
11330  setting behaves a bit differently for this class.
11331  
11332 \family sans
11333 Foil\SpecialChar TeX
11334
11335 \family default
11336  provides extensive footer and header capabilities including a user-defined
11337  logo.
11338  See section
11339 \begin_inset space ~
11340 \end_inset
11341
11342
11343 \begin_inset CommandInset ref
11344 LatexCommand ref
11345 reference "sec:foilfoot"
11346
11347 \end_inset
11348
11349  for more details.
11350  The title page is treated differently to all other pages in the document
11351  and is 
11352 \emph on
11353 always
11354 \emph default
11355  unnumbered and 
11356 \emph on
11357 always
11358 \emph default
11359  has the logo centered at the bottom of the page (if one is defined).
11360  The possible page style choices and what they do are as follows:
11361 \end_layout
11362
11363 \begin_deeper
11364 \begin_layout Labeling
11365 \labelwidthstring MMMMMMM
11366
11367 \family sans
11368 \series bold
11369 empty
11370 \family default
11371 \series default
11372  The final output contains no page numbers, or other headers or footers
11373  (except footnotes of course).
11374  
11375 \end_layout
11376
11377 \begin_layout Labeling
11378 \labelwidthstring MMMMMMM
11379
11380 \family sans
11381 \series bold
11382 plain
11383 \family default
11384 \series default
11385  The final output contains page numbers centered at the bottom of the page.
11386  No other headings or footers (other than footnotes).
11387 \end_layout
11388
11389 \begin_layout Labeling
11390 \labelwidthstring MMMMMMM
11391
11392 \series bold
11393 foilheadings
11394 \series default
11395  Page numbers in lower right corner.
11396  Additional headers and footers are also shown.
11397  This is also the default.
11398 \end_layout
11399
11400 \begin_layout Labeling
11401 \labelwidthstring MMMMMMM
11402
11403 \series bold
11404 fancy
11405 \series default
11406  Gives you access to the 
11407 \family sans
11408 fancyheadings
11409 \family default
11410  package although its use with 
11411 \family sans
11412 Foil\SpecialChar TeX
11413
11414 \family default
11415  is discouraged by the writer of the 
11416 \family sans
11417 Foil\SpecialChar TeX
11418
11419 \family default
11420  package because of some potential page layout clashes.
11421 \end_layout
11422
11423 \end_deeper
11424 \begin_layout Subsubsection
11425 Extra Options
11426 \end_layout
11427
11428 \begin_layout Standard
11429 The following options may be used in the extra class options in the 
11430 \family sans
11431 Document\SpecialChar menuseparator
11432 Settings
11433 \family default
11434  dialog.
11435 \end_layout
11436
11437 \begin_layout Labeling
11438 \labelwidthstring MMMMMMx
11439
11440 \series bold
11441 35mmSlide
11442 \series default
11443  This sets up the page layout for 7.33
11444 \begin_inset space \thinspace{}
11445 \end_inset
11446
11447 in by 11
11448 \begin_inset space \thinspace{}
11449 \end_inset
11450
11451 in paper, which is about the same aspect ratio as a 35
11452 \begin_inset space \thinspace{}
11453 \end_inset
11454
11455 mm slide, making it a bit easier to work with this medium.
11456 \end_layout
11457
11458 \begin_layout Labeling
11459 \labelwidthstring MMMMMMx
11460
11461 \series bold
11462 headrule
11463 \series default
11464  Places a rule across the page below the header on every page except the
11465  title page.
11466 \end_layout
11467
11468 \begin_layout Labeling
11469 \labelwidthstring MMMMMMx
11470
11471 \series bold
11472 footrule
11473 \series default
11474  Places a rule across the page above the footer on every page except the
11475  title page.
11476 \end_layout
11477
11478 \begin_layout Labeling
11479 \labelwidthstring MMMMMMx
11480
11481 \series bold
11482 dvips
11483 \series default
11484  This is automatically set each time you create a new 
11485 \family sans
11486 foils
11487 \family default
11488  document.
11489  This option tells 
11490 \family sans
11491 Foil\SpecialChar TeX
11492
11493 \family default
11494  to use the dvips driver to rotate those pages that are set as landscape
11495  foils.
11496 \end_layout
11497
11498 \begin_layout Labeling
11499 \labelwidthstring MMMMMMx
11500
11501 \series bold
11502 landscape
11503 \series default
11504  Simply changes the page dimensions to those of a landscape page but doesn't
11505  do any rotation.
11506  Thus if you use this option you need to use an external program to rotate
11507  each page or feed your paper through your printer as landscape.
11508  Note that this option effectively reverses the roles of the 
11509 \family sans
11510 Foilhead
11511 \family default
11512  and 
11513 \family sans
11514 Rotatefoilhead
11515 \family default
11516  environments (don't worry these are described in the next section).
11517 \end_layout
11518
11519 \begin_layout Labeling
11520 \labelwidthstring MMMMMMx
11521
11522 \series bold
11523 leqno
11524 \series default
11525  Equation numbers on the left.
11526 \end_layout
11527
11528 \begin_layout Labeling
11529 \labelwidthstring MMMMMMx
11530
11531 \series bold
11532 fleqn
11533 \series default
11534  Flush-left equations.
11535 \end_layout
11536
11537 \begin_layout Subsection
11538 Supported Environments
11539 \end_layout
11540
11541 \begin_layout Standard
11542 Most of the environments commonly supported in other classes are also supported
11543  by the 
11544 \family sans
11545 foils
11546 \family default
11547  class.
11548  There are several additional environments provided by 
11549 \family sans
11550 Foil\SpecialChar TeX
11551
11552 \family default
11553  as well as a couple added by \SpecialChar LyX
11554 .
11555  The following environments are shared with other classes:
11556 \end_layout
11557
11558 \begin_layout Standard
11559 \begin_inset Flex Multiple Columns
11560 status open
11561
11562 \begin_layout Itemize
11563
11564 \family sans
11565 Standard
11566 \end_layout
11567
11568 \begin_layout Itemize
11569
11570 \family sans
11571 Itemize
11572 \end_layout
11573
11574 \begin_layout Itemize
11575
11576 \family sans
11577 Enumerate
11578 \end_layout
11579
11580 \begin_layout Itemize
11581
11582 \family sans
11583 Description
11584 \end_layout
11585
11586 \begin_layout Itemize
11587
11588 \family sans
11589 List
11590 \end_layout
11591
11592 \begin_layout Itemize
11593
11594 \family sans
11595 \SpecialChar LyX
11596 -Code
11597 \end_layout
11598
11599 \begin_layout Itemize
11600
11601 \family sans
11602 Verse
11603 \end_layout
11604
11605 \begin_layout Itemize
11606
11607 \family sans
11608 Quote
11609 \end_layout
11610
11611 \begin_layout Itemize
11612
11613 \family sans
11614 Quotation
11615 \end_layout
11616
11617 \begin_layout Itemize
11618
11619 \family sans
11620 TitleAuthor
11621 \end_layout
11622
11623 \begin_layout Itemize
11624
11625 \family sans
11626 Date
11627 \end_layout
11628
11629 \begin_layout Itemize
11630
11631 \family sans
11632 Abstract
11633 \end_layout
11634
11635 \begin_layout Itemize
11636
11637 \family sans
11638 Bibliography
11639 \end_layout
11640
11641 \begin_layout Itemize
11642
11643 \family sans
11644 Address
11645 \end_layout
11646
11647 \begin_layout Itemize
11648
11649 \family sans
11650 RightAddress
11651 \end_layout
11652
11653 \end_inset
11654
11655
11656 \end_layout
11657
11658 \begin_layout Standard
11659 That is, all the major environments apart from the sectioning environments.
11660  Since foils are essentially self-contained sections, with a title and body,
11661  
11662 \family sans
11663 Foil\SpecialChar TeX
11664
11665 \family default
11666  provides specific commands for starting new foils and these are:
11667 \end_layout
11668
11669 \begin_layout Itemize
11670
11671 \family sans
11672 Foilhead
11673 \end_layout
11674
11675 \begin_layout Itemize
11676
11677 \family sans
11678 Rotatefoilhead
11679 \end_layout
11680
11681 \begin_layout Standard
11682 \SpecialChar LyX
11683  also provides slightly modified versions of these two environments called:
11684 \end_layout
11685
11686 \begin_layout Itemize
11687
11688 \family sans
11689 ShortFoilhead
11690 \end_layout
11691
11692 \begin_layout Itemize
11693
11694 \family sans
11695 ShortRotatefoilhead
11696 \end_layout
11697
11698 \begin_layout Standard
11699 and the differences will be explained in the next section.
11700 \end_layout
11701
11702 \begin_layout Standard
11703 Since foils are often used in presenting ideas or new theorems and such
11704  
11705 \family sans
11706 Foil\SpecialChar TeX
11707
11708 \family default
11709  also provides a comprehensive box of goodies for presenting them:
11710 \end_layout
11711
11712 \begin_layout Standard
11713 \begin_inset Flex Multiple Columns
11714 status open
11715
11716 \begin_layout Itemize
11717
11718 \family sans
11719 Theorem
11720 \end_layout
11721
11722 \begin_layout Itemize
11723
11724 \family sans
11725 Lemma
11726 \end_layout
11727
11728 \begin_layout Itemize
11729
11730 \family sans
11731 Corollary
11732 \end_layout
11733
11734 \begin_layout Itemize
11735
11736 \family sans
11737 Proposition
11738 \end_layout
11739
11740 \begin_layout Itemize
11741
11742 \family sans
11743 Definition
11744 \end_layout
11745
11746 \begin_layout Itemize
11747
11748 \family sans
11749 Proof
11750 \end_layout
11751
11752 \begin_layout Itemize
11753
11754 \family sans
11755 Theorem*
11756 \end_layout
11757
11758 \begin_layout Itemize
11759
11760 \family sans
11761 Lemma*
11762 \end_layout
11763
11764 \begin_layout Itemize
11765
11766 \family sans
11767 Corollary*
11768 \end_layout
11769
11770 \begin_layout Itemize
11771
11772 \family sans
11773 Proposition*
11774 \end_layout
11775
11776 \begin_layout Itemize
11777
11778 \family sans
11779 Definition*
11780 \end_layout
11781
11782 \end_inset
11783
11784
11785 \end_layout
11786
11787 \begin_layout Standard
11788 The starred versions are unnumbered while the unstarred versions are numbered.
11789  There are also two list environments added by \SpecialChar LyX
11790  and these are:
11791 \end_layout
11792
11793 \begin_layout Itemize
11794
11795 \family sans
11796 TickList
11797 \end_layout
11798
11799 \begin_layout Itemize
11800
11801 \family sans
11802 CrossList
11803 \end_layout
11804
11805 \begin_layout Standard
11806
11807 \family sans
11808 Foil\SpecialChar TeX
11809
11810 \family default
11811  provides some powerful header and footer capabilities that are best set
11812  in the preamble although they may be set at any point in a document.
11813  If you want to change these settings in your document the best place to
11814  do so is at the very top of a foil, i.
11815 \begin_inset space \thinspace{}
11816 \end_inset
11817
11818 e.
11819 \emph on
11820
11821 \begin_inset space \space{}
11822 \end_inset
11823
11824
11825 \emph default
11826 straight after the foilhead.
11827 \end_layout
11828
11829 \begin_layout Standard
11830 For this purpose, the following command styles are provided [
11831 \shape smallcaps
11832 Martin Vermeer
11833 \shape default
11834 ]:
11835 \end_layout
11836
11837 \begin_layout Standard
11838 \begin_inset Flex Multiple Columns
11839 status open
11840
11841 \begin_layout Itemize
11842
11843 \family sans
11844 My
11845 \begin_inset space ~
11846 \end_inset
11847
11848 Logo
11849 \end_layout
11850
11851 \begin_layout Itemize
11852
11853 \family sans
11854 Restriction
11855 \end_layout
11856
11857 \begin_layout Itemize
11858
11859 \family sans
11860 Right
11861 \begin_inset space ~
11862 \end_inset
11863
11864 Footer
11865 \end_layout
11866
11867 \begin_layout Itemize
11868
11869 \family sans
11870 Right
11871 \begin_inset space ~
11872 \end_inset
11873
11874 Header
11875 \end_layout
11876
11877 \begin_layout Itemize
11878
11879 \family sans
11880 Left
11881 \begin_inset space ~
11882 \end_inset
11883
11884 Header
11885 \end_layout
11886
11887 \begin_deeper
11888 \begin_layout Plain Layout
11889 \begin_inset space ~
11890 \end_inset
11891
11892
11893 \end_layout
11894
11895 \end_deeper
11896 \end_inset
11897
11898
11899 \end_layout
11900
11901 \begin_layout Standard
11902 There are also a few commands provided by 
11903 \family sans
11904 Foil\SpecialChar TeX
11905
11906 \family default
11907  that aren't directly supported by \SpecialChar LyX
11908  but I'll tell you what they do and how
11909  to use them in section
11910 \begin_inset space ~
11911 \end_inset
11912
11913
11914 \begin_inset CommandInset ref
11915 LatexCommand ref
11916 reference "sec:unsuppfoils"
11917
11918 \end_inset
11919
11920 .
11921 \end_layout
11922
11923 \begin_layout Subsection
11924 Building a Set of Foils
11925 \end_layout
11926
11927 \begin_layout Standard
11928 This section will give a simple introduction to using the different environments
11929  to build a set of foils.
11930  If you want to see an example set of foils, take a look at the 
11931 \family typewriter
11932 Foils.lyx
11933 \family default
11934  file you find in \SpecialChar LyX
11935 's 
11936 \family typewriter
11937 examples
11938 \family default
11939  folder.
11940 \end_layout
11941
11942 \begin_layout Subsubsection
11943 Give It a Title Page
11944 \end_layout
11945
11946 \begin_layout Standard
11947 Unlike other classes that provide 
11948 \family sans
11949 Title
11950 \family default
11951
11952 \family sans
11953 Author
11954 \family default
11955
11956 \family sans
11957 Date
11958 \family default
11959  and 
11960 \family sans
11961 Abstract
11962 \family default
11963  environments, 
11964 \family sans
11965 foils
11966 \family default
11967  creates the title on a page of its own.
11968  If you leave out the 
11969 \family sans
11970 Date
11971 \family default
11972  environment \SpecialChar LaTeX
11973  will substitute the current date (every time you regenerate
11974  the output).
11975 \end_layout
11976
11977 \begin_layout Subsubsection
11978 Start a New Foil
11979 \end_layout
11980
11981 \begin_layout Standard
11982 As I mentioned earlier, there are four ways of starting a new foil.
11983  For portrait foils you should use 
11984 \family sans
11985 Foilhead
11986 \family default
11987  or 
11988 \family sans
11989 ShortFoilhead.
11990
11991 \family default
11992  The difference between these two environments is the amount of space between
11993  the title of the foil (the foilhead) and the body of the foil.
11994 \end_layout
11995
11996 \begin_layout Standard
11997 Landscape foils are generated using the 
11998 \family sans
11999 Rotatefoilhead
12000 \family default
12001  and 
12002 \family sans
12003 ShortRotatefoilhead
12004 \family default
12005  environments.
12006  Again the only difference is the spacing between foilhead and body.
12007  Both of the short versions have 0.5
12008 \begin_inset space ~
12009 \end_inset
12010
12011 inches less separation between the foilhead and the body.
12012  
12013 \end_layout
12014
12015 \begin_layout Standard
12016 One problem with the support for landscape foils is the requirement that
12017  you have to use the 
12018 \family typewriter
12019 dvips
12020 \family default
12021  driver to generate the PostScript output otherwise the foils won't be rotated.
12022  It is possible to get landscape foils even if you haven't got the 
12023 \family typewriter
12024 dvips
12025 \family default
12026  driver provided you can feed your foils sideways through your printer ;-)
12027 \end_layout
12028
12029 \begin_layout Subsubsection
12030 Theorems, Lemmas, Proofs and more
12031 \end_layout
12032
12033 \begin_layout Standard
12034 You can't have two of the same type of these environments directly following
12035  each other.
12036  If you use a normal paragraph break, , you will just be extending the previous
12037  environment as if you had merged the two environments together.
12038  Rather than that, you need to insert a so-called separator.
12039  Please refer to the section entitled 
12040 \emph on
12041 Separate Nestings
12042 \emph default
12043  in the 
12044 \emph on
12045 User's Guide
12046 \emph default
12047 .
12048 \end_layout
12049
12050 \begin_layout Subsubsection
12051 Lists
12052 \end_layout
12053
12054 \begin_layout Standard
12055 You get all the commonly supported list styles found in other classes as
12056  well as two new ones.
12057  I'll only describe the new ones here.
12058  If you want to find out more about the other list environments check out
12059  the 
12060 \emph on
12061 User's Guide.
12062
12063 \emph default
12064  If you intend to use itemized lists you might also want to read about the
12065  
12066 \family sans
12067 Itemize
12068 \begin_inset space ~
12069 \end_inset
12070
12071 Bullet
12072 \begin_inset space ~
12073 \end_inset
12074
12075 Selection
12076 \family default
12077  dialog described above in section
12078 \begin_inset space ~
12079 \end_inset
12080
12081
12082 \begin_inset CommandInset ref
12083 LatexCommand ref
12084 reference "sec:bullet"
12085
12086 \end_inset
12087
12088 .
12089 \end_layout
12090
12091 \begin_layout Standard
12092 The two new list styles, 
12093 \family sans
12094 TickList
12095 \family default
12096  and 
12097 \family sans
12098 CrossList
12099 \family default
12100 , are designed to make it easier for you to create lists of do's and don'ts
12101  or right and wrong by providing dedicated environments that use a tick
12102  or a cross as the label of the list.
12103  These lists are in fact dedicated variants of the 
12104 \family sans
12105 Itemize
12106 \family default
12107  environment.
12108  They do however require that you have the 
12109 \family typewriter
12110 psnfss
12111 \family default
12112  packages installed.
12113 \end_layout
12114
12115 \begin_layout Subsubsection
12116 Figures and Tables
12117 \end_layout
12118
12119 \begin_layout Standard
12120
12121 \family sans
12122 Foil\SpecialChar TeX
12123
12124 \family default
12125  redefines the floating tables and figures so that they appear exactly where
12126  they are in the text rather than pushing them to the top of the page or
12127  to some user specified location.
12128  In fact if you change the float placement settings they are simply ignored.
12129 \end_layout
12130
12131 \begin_layout Subsubsection
12132 Page Headers and Footers
12133 \begin_inset CommandInset label
12134 LatexCommand label
12135 name "sec:foilfoot"
12136
12137 \end_inset
12138
12139
12140 \end_layout
12141
12142 \begin_layout Standard
12143
12144 \family sans
12145 My
12146 \begin_inset space ~
12147 \end_inset
12148
12149 Logo
12150 \family default
12151  and 
12152 \family sans
12153 Restriction
12154 \family default
12155  are two commands used to control the left-footer text string.
12156  The first is meant to allow you to include a graphic logo on your foils
12157  and defaults to 
12158 \begin_inset Quotes eld
12159 \end_inset
12160
12161 -Typeset by 
12162 \family sans
12163 Foil\SpecialChar TeX
12164
12165 \family default
12166 -
12167 \begin_inset Quotes erd
12168 \end_inset
12169
12170 .
12171  While the second is meant to provide a classification for the audience,
12172  
12173 \emph on
12174 e.
12175 \begin_inset space \thinspace{}
12176 \end_inset
12177
12178 g.
12179 \emph default
12180
12181 \begin_inset space \space{}
12182 \end_inset
12183
12184 Confidential.
12185  It is empty by default.
12186 \end_layout
12187
12188 \begin_layout Standard
12189 The remaining page corners can be filled by 
12190 \family sans
12191 Right
12192 \begin_inset space ~
12193 \end_inset
12194
12195 Footer
12196 \family default
12197  (which defaults to page numbers), 
12198 \family sans
12199 Right
12200 \begin_inset space ~
12201 \end_inset
12202
12203 Header
12204 \family default
12205  (top right) and 
12206 \family sans
12207 Left
12208 \begin_inset space ~
12209 \end_inset
12210
12211 Header
12212 \family default
12213  (top left).
12214 \end_layout
12215
12216 \begin_layout Subsection
12217 Unsupported 
12218 \family sans
12219 Foil\SpecialChar TeX
12220
12221 \family default
12222  Goodies
12223 \begin_inset CommandInset label
12224 LatexCommand label
12225 name "sec:unsuppfoils"
12226
12227 \end_inset
12228
12229
12230 \end_layout
12231
12232 \begin_layout Standard
12233 All the commands mentioned below need to be set in a 
12234 \family sans
12235 \SpecialChar LaTeX
12236
12237 \family default
12238  environment or as 
12239 \family sans
12240 \SpecialChar TeX
12241
12242 \family default
12243  within another environment.
12244 \end_layout
12245
12246 \begin_layout Subsubsection
12247 Lengths
12248 \end_layout
12249
12250 \begin_layout Standard
12251 All lengths are adjusted using the 
12252 \family typewriter
12253
12254 \backslash
12255 setlength{
12256 \family default
12257 \emph on
12258 lengthname
12259 \family typewriter
12260 \emph default
12261 }{
12262 \family default
12263 \emph on
12264 newlength
12265 \family typewriter
12266 \emph default
12267 }
12268 \family default
12269  command.
12270  Where 
12271 \emph on
12272 lengthname
12273 \emph default
12274  should be replaced by the name given to the length you want to change and
12275  
12276 \emph on
12277 newlength
12278 \emph default
12279  is the length value.
12280  All lengths should be specified in units of length such as inches (
12281 \family typewriter
12282 in
12283 \family default
12284 ), millimeters (
12285 \family typewriter
12286 mm
12287 \family default
12288 ) or points (
12289 \family typewriter
12290 pt
12291 \family default
12292 ) or relative to some document or font-based length such as 
12293 \family typewriter
12294
12295 \backslash
12296 textwidth
12297 \family default
12298 .
12299  
12300 \end_layout
12301
12302 \begin_layout Standard
12303 It's possible to change the spacing between a foilhead and the body of the
12304  foil by adjusting the length specified by 
12305 \family typewriter
12306
12307 \backslash
12308 foilheadskip
12309 \family default
12310 .
12311  For example, to make 
12312 \emph on
12313 all
12314 \emph default
12315  foilheads 0.5
12316 \begin_inset space \space{}
12317 \end_inset
12318
12319 in closer to their bodies put the following in the preamble: 
12320 \family typewriter
12321
12322 \backslash
12323 setlength{
12324 \backslash
12325 foilheadskip}{-0.5in}
12326 \end_layout
12327
12328 \begin_layout Standard
12329 The spacings around floats can be adjusted by setting these lengths:
12330 \end_layout
12331
12332 \begin_layout Labeling
12333 \labelwidthstring MMMMMMMMMMM
12334
12335 \family typewriter
12336
12337 \backslash
12338 abovefloatskip
12339 \family default
12340  Separation between the text and the top of the float
12341 \end_layout
12342
12343 \begin_layout Labeling
12344 \labelwidthstring MMMMMMMMMMM
12345
12346 \family typewriter
12347
12348 \backslash
12349 abovecaptionskip
12350 \family default
12351  Separation between the float and the caption
12352 \end_layout
12353
12354 \begin_layout Labeling
12355 \labelwidthstring MMMMMMMMMMM
12356
12357 \family typewriter
12358
12359 \backslash
12360 belowcaptionskip
12361 \family default
12362  Separation between the caption and the following text
12363 \end_layout
12364
12365 \begin_layout Labeling
12366 \labelwidthstring MMMMMMMMMMM
12367
12368 \family typewriter
12369
12370 \backslash
12371 captionwidth
12372 \family default
12373  You can make the captions narrower than the surrounding text by adjusting
12374  this length.
12375  Best done relative to 
12376 \family typewriter
12377
12378 \backslash
12379 textwidth
12380 \family default
12381 .
12382 \end_layout
12383
12384 \begin_layout Standard
12385 There are also several title page related lengths that you may find useful
12386  if you have a long title or several authors:
12387 \end_layout
12388
12389 \begin_layout Labeling
12390 \labelwidthstring MMMMMMMMMMM
12391
12392 \family typewriter
12393
12394 \backslash
12395 abovetitleskip
12396 \family default
12397  Separation from headers to 
12398 \family sans
12399 Title
12400 \end_layout
12401
12402 \begin_layout Labeling
12403 \labelwidthstring MMMMMMMMMMM
12404
12405 \family typewriter
12406
12407 \backslash
12408 titleauthorskip
12409 \family default
12410  between 
12411 \family sans
12412 Title
12413 \family default
12414  and 
12415 \family sans
12416 Author
12417 \family default
12418  environments
12419 \end_layout
12420
12421 \begin_layout Labeling
12422 \labelwidthstring MMMMMMMMMMM
12423
12424 \family typewriter
12425
12426 \backslash
12427 authorauthorskip
12428 \family default
12429  between multiple 
12430 \family sans
12431 Author
12432 \family default
12433  lines
12434 \end_layout
12435
12436 \begin_layout Labeling
12437 \labelwidthstring MMMMMMMMMMM
12438
12439 \family typewriter
12440
12441 \backslash
12442 authordateskip
12443 \family default
12444  between the 
12445 \family sans
12446 Author
12447 \family default
12448  and the 
12449 \family sans
12450 Date
12451 \end_layout
12452
12453 \begin_layout Labeling
12454 \labelwidthstring MMMMMMMMMMM
12455
12456 \family typewriter
12457
12458 \backslash
12459 dateabstractskip
12460 \family default
12461  between the 
12462 \family sans
12463 Date
12464 \family default
12465  and the 
12466 \family sans
12467 Abstract
12468 \end_layout
12469
12470 \begin_layout Standard
12471 The last length related command affects all the list environments.
12472  If you place 
12473 \family typewriter
12474
12475 \backslash
12476 zerolistvertdimens
12477 \family default
12478  
12479 \emph on
12480 inside
12481 \emph default
12482  a list environment then all the vertical spacing between the list items
12483  is removed.
12484  Note that this is a command not a length so it doesn't require 
12485 \family typewriter
12486
12487 \backslash
12488 setlength
12489 \family default
12490  like the stuff mentioned above.
12491 \end_layout
12492
12493 \begin_layout Subsubsection
12494 Headers and Footers
12495 \end_layout
12496
12497 \begin_layout Standard
12498 The 
12499 \family typewriter
12500
12501 \backslash
12502 LogoOn
12503 \family default
12504  and 
12505 \family typewriter
12506
12507 \backslash
12508 LogoOff
12509 \family default
12510  commands control whether the logo in the 
12511 \family sans
12512 MyLogo
12513 \family default
12514  definition appear on a given page.
12515  If you put 
12516 \family typewriter
12517
12518 \backslash
12519 LogoOff
12520 \family default
12521  in the preamble then none of the foils will have the logo on them.
12522  If you don't want the logo on a particular page place the 
12523 \family typewriter
12524
12525 \backslash
12526 LogoOff
12527 \family default
12528  directly after the foilhead of that page and the 
12529 \family typewriter
12530
12531 \backslash
12532 LogoOn
12533 \family default
12534  directly after the next foilhead.
12535 \end_layout
12536
12537 \begin_layout Standard
12538 If you decide to use the 
12539 \family sans
12540 fancy
12541 \family default
12542  page style setting in the 
12543 \family sans
12544 Document
12545 \begin_inset space ~
12546 \end_inset
12547
12548 Layout
12549 \family default
12550  dialog you should probably add 
12551 \family typewriter
12552
12553 \backslash
12554 let
12555 \backslash
12556 headwidth
12557 \backslash
12558 textwidth
12559 \family default
12560  to your preamble so headers and footers on landscape pages are correctly
12561  placed when rotated.
12562  This is due to some clashes between the page layouts provided by the 
12563 \family sans
12564 fancyheadings
12565 \family default
12566  package and the 
12567 \family sans
12568 foils
12569 \family default
12570  class.
12571 \end_layout
12572
12573 \begin_layout Section
12574 Hollywood (Hollywood spec scripts)
12575 \end_layout
12576
12577 \begin_layout Standard
12578 by 
12579 \shape smallcaps
12580 Garst Reese
12581 \end_layout
12582
12583 \begin_layout Subsection
12584 Introduction
12585 \end_layout
12586
12587 \begin_layout Standard
12588 Getting the format of a Hollywood script right is a 
12589 \begin_inset Quotes eld
12590 \end_inset
12591
12592 rite of passage.
12593 \begin_inset Quotes erd
12594 \end_inset
12595
12596  It is designed to make the readers focus on content and to be easy and
12597  familiar for the actors to read.
12598  Each page of a script should be one minute of film.
12599  Nothing goes in a script that you cannot see or hear on screen.
12600  The courier 12 pt font should be used throughout.
12601  No italics.
12602 \end_layout
12603
12604 \begin_layout Subsection
12605 Special problems
12606 \end_layout
12607
12608 \begin_layout Standard
12609 Speakers' lines should NEVER break in mid-sentence.
12610  If a speaker's lines continue over a page break, repeat the 
12611 \family sans
12612 Speaker
12613 \family default
12614  title followed by (Cont'd).
12615 \end_layout
12616
12617 \begin_layout Subsection
12618 Special features
12619 \end_layout
12620
12621 \begin_layout Standard
12622 Insert the 
12623 \family sans
12624 Speaker
12625 \family default
12626  names as labels then cross-reference the label to insert the name.
12627  The cross-reference dialog will show the current cast of characters.
12628  You can use this to insert the speaker name in narratives also.
12629 \end_layout
12630
12631 \begin_layout Subsection
12632 Paper size and Margins
12633 \end_layout
12634
12635 \begin_layout Standard
12636 USLetter, left 1.6in, right 0.75in, top 0.5in, bottom 0.75in
12637 \end_layout
12638
12639 \begin_layout Subsection
12640 Environments
12641 \end_layout
12642
12643 \begin_layout Standard
12644 The following environments are available.
12645  You can use hollywood.bind to get the bind keys shown at the right.
12646 \end_layout
12647
12648 \begin_layout Itemize
12649
12650 \family sans
12651 Standard
12652 \begin_inset Newline newline
12653 \end_inset
12654
12655
12656 \family default
12657 Used where nothing else works.
12658  Try to avoid it.
12659 \end_layout
12660
12661 \begin_layout Itemize
12662
12663 \family sans
12664 FADE_IN
12665 \family default
12666 :
12667 \begin_inset space \hfill{}
12668 \end_inset
12669
12670
12671 \family sans
12672 M-z S-I
12673 \family default
12674
12675 \begin_inset Newline newline
12676 \end_inset
12677
12678 Usually followed by something like 
12679 \begin_inset Quotes eld
12680 \end_inset
12681
12682 on Sally waking up.
12683 \begin_inset Quotes erd
12684 \end_inset
12685
12686
12687 \end_layout
12688
12689 \begin_layout Itemize
12690
12691 \family sans
12692 INT:
12693 \begin_inset space \hfill{}
12694 \end_inset
12695
12696 M-z i
12697 \begin_inset Newline newline
12698 \end_inset
12699
12700
12701 \family default
12702 Introduces a new INTERIOR camera set-up.
12703  Always followed by DAY or NIGHT, or something similar to define the lighting
12704  required.
12705  Everthing on this line in CAPS.
12706 \end_layout
12707
12708 \begin_layout Itemize
12709
12710 \family sans
12711 EXT:
12712 \begin_inset space \hfill{}
12713 \end_inset
12714
12715 M-z e
12716 \begin_inset Newline newline
12717 \end_inset
12718
12719
12720 \family default
12721 Introduces a new EXTERIOR camera set-up.
12722  Everthing on this line in CAPS.
12723 \end_layout
12724
12725 \begin_layout Itemize
12726
12727 \family sans
12728 Speaker
12729 \begin_inset space \hfill{}
12730 \end_inset
12731
12732 M-z s
12733 \begin_inset Newline newline
12734 \end_inset
12735
12736
12737 \family default
12738 The character speaking.
12739 \end_layout
12740
12741 \begin_layout Itemize
12742
12743 \family sans
12744 Parenthetical
12745 \begin_inset space \hfill{}
12746 \end_inset
12747
12748 M-z p
12749 \begin_inset Newline newline
12750 \end_inset
12751
12752
12753 \family default
12754 Instructions to the speaker.
12755  The () are automatically inserted.
12756 \end_layout
12757
12758 \begin_layout Itemize
12759
12760 \family sans
12761 Dialogue
12762 \begin_inset space \hfill{}
12763 \end_inset
12764
12765 M-z d
12766 \begin_inset Newline newline
12767 \end_inset
12768
12769
12770 \family default
12771 What the 
12772 \family sans
12773 Speaker
12774 \family default
12775  says.
12776 \end_layout
12777
12778 \begin_layout Itemize
12779
12780 \family sans
12781 Transition
12782 \begin_inset space \hfill{}
12783 \end_inset
12784
12785 M-z t
12786 \begin_inset Newline newline
12787 \end_inset
12788
12789
12790 \family default
12791 Camera movement instruction.
12792  e.
12793 \begin_inset space \thinspace{}
12794 \end_inset
12795
12796 g.
12797 \begin_inset space \space{}
12798 \end_inset
12799
12800 CUT TO:
12801 \end_layout
12802
12803 \begin_layout Itemize
12804
12805 \family sans
12806 FADE OUT:
12807 \begin_inset space \hfill{}
12808 \end_inset
12809
12810 M-z S-I
12811 \end_layout
12812
12813 \begin_layout Itemize
12814
12815 \family sans
12816 Author
12817 \begin_inset space \hfill{}
12818 \end_inset
12819
12820 M-z S-A
12821 \end_layout
12822
12823 \begin_layout Itemize
12824
12825 \family sans
12826 Title
12827 \begin_inset space \hfill{}
12828 \end_inset
12829
12830 M-z S-T
12831 \end_layout
12832
12833 \begin_layout Itemize
12834
12835 \family sans
12836 Right_Address
12837 \begin_inset space \hfill{}
12838 \end_inset
12839
12840 M-z r
12841 \end_layout
12842
12843 \begin_layout Subsection
12844 Script jargon
12845 \end_layout
12846
12847 \begin_layout Itemize
12848 (O.S) â€” off screen
12849 \end_layout
12850
12851 \begin_layout Itemize
12852 (V.0) â€” voice over
12853 \end_layout
12854
12855 \begin_layout Itemize
12856 b.
12857 \begin_inset space \thinspace{}
12858 \end_inset
12859
12860 g.
12861  â€” background
12862 \end_layout
12863
12864 \begin_layout Itemize
12865 C.U.
12866  â€” close-up
12867 \end_layout
12868
12869 \begin_layout Itemize
12870 PAN â€” camera movement
12871 \end_layout
12872
12873 \begin_layout Itemize
12874 INSERT â€” cut to close-up of
12875 \end_layout
12876
12877 \begin_layout Section
12878 ijmpc and ijmpd
12879 \end_layout
12880
12881 \begin_layout Standard
12882 by 
12883 \noun on
12884 Panayotis Papasotiriou
12885 \end_layout
12886
12887 \begin_layout Subsection
12888 Overview
12889 \end_layout
12890
12891 \begin_layout Standard
12892 The ijmpc package is a set of macros that facilitates electronic manuscript
12893  submission to the 
12894 \emph on
12895 International Journal of Modern Physics C
12896 \emph default
12897 .
12898  Similarly, the ijmpd package is for creating manuscripts to be submitted
12899  to the 
12900 \emph on
12901 International Journal of Modern Physics D
12902 \emph default
12903 .
12904  Both journals are published by World Scientific.
12905  The corresponding document classes are named 
12906 \family typewriter
12907 ws-ijmpc.cls
12908 \family default
12909  and 
12910 \family typewriter
12911 ws-ijmpd.cls
12912 \family default
12913 , respectively.
12914  These files, together with instructions for the authors, can be downloaded
12915  from the sites 
12916 \begin_inset Flex URL
12917 status collapsed
12918
12919 \begin_layout Plain Layout
12920
12921 http://www.worldscinet.com/ijmpc/mkt/guidelines.shtml
12922 \end_layout
12923
12924 \end_inset
12925
12926  and 
12927 \begin_inset Flex URL
12928 status collapsed
12929
12930 \begin_layout Plain Layout
12931
12932 http://www.worldscinet.com/ijmpd/mkt/guidelines.shtml
12933 \end_layout
12934
12935 \end_inset
12936
12937 .
12938  Both packages are modified versions of the standard 
12939 \begin_inset Quotes eld
12940 \end_inset
12941
12942 article
12943 \begin_inset Quotes erd
12944 \end_inset
12945
12946  package, and they are almost (but not exactly) identical.
12947  Most of their features are supported by \SpecialChar LyX
12948 .
12949  I have used \SpecialChar LyX
12950  successfully to write articles submitted to both journals
12951  without any problem.
12952 \end_layout
12953
12954 \begin_layout Subsection
12955 Writing a paper
12956 \end_layout
12957
12958 \begin_layout Standard
12959 As usual, the easiest way to write a paper is to start with a template.
12960  Click on 
12961 \family sans
12962 File\SpecialChar menuseparator
12963 New from
12964 \family default
12965  
12966 \family sans
12967 Template
12968 \family default
12969 , then choose the 
12970 \family typewriter
12971 ijmpc.lyx
12972 \family default
12973  or 
12974 \family typewriter
12975 ijmpd.lyx
12976 \family default
12977  template.
12978  This will give an (almost) empty document that includes the most common
12979  fields found in a manuscript.
12980  Simply overwrite the existing text (including the brackets, 
12981 \family typewriter
12982 <>
12983 \family default
12984 ) with your text.
12985  You should keep in mind the following remarks.
12986 \end_layout
12987
12988 \begin_layout Enumerate
12989 \SpecialChar LyX
12990  won't let you change the font size and the page style of the document,
12991  because such modifications are not allowed by both packages.
12992 \end_layout
12993
12994 \begin_layout Enumerate
12995 The language of the document should not be changed.
12996  Before previewing your paper, be sure that the babel package is not used.
12997  To do this, click on 
12998 \begin_inset Info
12999 type  "menu"
13000 arg   "dialog-show document"
13001 \end_inset
13002
13003  
13004 \family sans
13005 \SpecialChar menuseparator
13006 Language
13007 \family default
13008 , and select 
13009 \begin_inset Quotes eld
13010 \end_inset
13011
13012 None
13013 \begin_inset Quotes erd
13014 \end_inset
13015
13016  as 
13017 \family sans
13018 Language Package
13019 \family default
13020 .
13021 \end_layout
13022
13023 \begin_layout Enumerate
13024 The 
13025 \begin_inset Quotes eld
13026 \end_inset
13027
13028 Keywords
13029 \begin_inset Quotes erd
13030 \end_inset
13031
13032  style must be used to define keywords.
13033 \end_layout
13034
13035 \begin_layout Enumerate
13036 The ijmpc package provides a style named 
13037 \begin_inset Quotes eld
13038 \end_inset
13039
13040 Classification Codes
13041 \begin_inset Quotes erd
13042 \end_inset
13043
13044 , which can be used to define classification codes, such as PACS numbers.
13045  Note that this facility is not supported by the ijmpd package.
13046 \end_layout
13047
13048 \begin_layout Enumerate
13049 Several new environments are available: 
13050 \begin_inset Quotes eld
13051 \end_inset
13052
13053 Definition
13054 \begin_inset Quotes erd
13055 \end_inset
13056
13057
13058 \begin_inset Quotes eld
13059 \end_inset
13060
13061 Step
13062 \begin_inset Quotes erd
13063 \end_inset
13064
13065
13066 \begin_inset Quotes eld
13067 \end_inset
13068
13069 Example
13070 \begin_inset Quotes erd
13071 \end_inset
13072
13073
13074 \begin_inset Quotes eld
13075 \end_inset
13076
13077 Remark
13078 \begin_inset Quotes erd
13079 \end_inset
13080
13081
13082 \begin_inset Quotes eld
13083 \end_inset
13084
13085 Notation
13086 \begin_inset Quotes erd
13087 \end_inset
13088
13089
13090 \begin_inset Quotes eld
13091 \end_inset
13092
13093 Theorem
13094 \begin_inset Quotes erd
13095 \end_inset
13096
13097
13098 \begin_inset Quotes eld
13099 \end_inset
13100
13101 Proof
13102 \begin_inset Quotes erd
13103 \end_inset
13104
13105
13106 \begin_inset Quotes eld
13107 \end_inset
13108
13109 Corollary
13110 \begin_inset Quotes erd
13111 \end_inset
13112
13113
13114 \begin_inset Quotes eld
13115 \end_inset
13116
13117 Lemma
13118 \begin_inset Quotes erd
13119 \end_inset
13120
13121
13122 \begin_inset Quotes eld
13123 \end_inset
13124
13125 Proposition
13126 \begin_inset Quotes erd
13127 \end_inset
13128
13129
13130 \begin_inset Quotes eld
13131 \end_inset
13132
13133 Prop
13134 \begin_inset Quotes erd
13135 \end_inset
13136
13137
13138 \begin_inset Quotes eld
13139 \end_inset
13140
13141 Question
13142 \begin_inset Quotes erd
13143 \end_inset
13144
13145
13146 \begin_inset Quotes eld
13147 \end_inset
13148
13149 Claim
13150 \begin_inset Quotes erd
13151 \end_inset
13152
13153 , and 
13154 \begin_inset Quotes eld
13155 \end_inset
13156
13157 Conjecture
13158 \begin_inset Quotes erd
13159 \end_inset
13160
13161 .
13162  Their use is more or less obvious.
13163  \SpecialChar LyX
13164  supports all these environments; it will use the proper label, text style,
13165  and numbering scheme for each of them.
13166 \end_layout
13167
13168 \begin_layout Enumerate
13169 Both packages use basic citations; the natbib package should not be used.
13170  In \SpecialChar LyX
13171 , citation references are shown as usual; in the output, citations are
13172  shown as superscripts.
13173  If you want to use a citation as normal text, you should use the 
13174 \family typewriter
13175 refcite
13176 \family default
13177  command, e.
13178 \begin_inset space \thinspace{}
13179 \end_inset
13180
13181 g.
13182 \begin_inset space \space{}
13183 \end_inset
13184
13185
13186 \begin_inset Quotes eld
13187 \end_inset
13188
13189 See Ref.
13190 \begin_inset space \space{}
13191 \end_inset
13192
13193
13194 \family typewriter
13195
13196 \backslash
13197 refcite{key}
13198 \family default
13199
13200 \begin_inset Quotes erd
13201 \end_inset
13202
13203 .
13204 \end_layout
13205
13206 \begin_layout Enumerate
13207 There is no 
13208 \begin_inset Quotes eld
13209 \end_inset
13210
13211 Acknowledgments
13212 \begin_inset Quotes erd
13213 \end_inset
13214
13215  section in both packages.
13216  To put acknowledgments, just use the 
13217 \begin_inset Quotes eld
13218 \end_inset
13219
13220 Section*
13221 \begin_inset Quotes erd
13222 \end_inset
13223
13224  environment.
13225 \end_layout
13226
13227 \begin_layout Enumerate
13228 Appendices may be added to the paper, 
13229 \emph on
13230 after
13231 \emph default
13232  the Acknowledgments and 
13233 \shape italic
13234 before
13235 \shape default
13236  the References.
13237  \SpecialChar LyX
13238  provides a special environment, called 
13239 \begin_inset Quotes eld
13240 \end_inset
13241
13242 Appendices Section
13243 \begin_inset Quotes erd
13244 \end_inset
13245
13246  which marks the beginning of the appendices.
13247  This environment should be left blank; it just sends a \SpecialChar LaTeX
13248  command, but nothing
13249  is really printed.
13250  In \SpecialChar LyX
13251 , the word 
13252 \begin_inset Quotes eld
13253 \end_inset
13254
13255 Appendix
13256 \begin_inset Quotes erd
13257 \end_inset
13258
13259  is printed with blue letters, as a signal that all sections after that
13260  point are appendices.
13261  To write an appendix, use the 
13262 \begin_inset Quotes eld
13263 \end_inset
13264
13265 Appendix
13266 \begin_inset Quotes erd
13267 \end_inset
13268
13269  environment.
13270  \SpecialChar LyX
13271  will number each appendix with capital letters, as required by both journals.
13272  Note that 
13273 \begin_inset Quotes eld
13274 \end_inset
13275
13276 Appendices Section
13277 \begin_inset Quotes erd
13278 \end_inset
13279
13280  
13281 \emph on
13282 must
13283 \emph default
13284  be present before the first appendix; if not, all appendices will be numbered
13285  as normal sections in the output.
13286 \end_layout
13287
13288 \begin_layout Enumerate
13289 The ijmpc and the ijmpd packages use the 
13290 \family typewriter
13291 tbl
13292 \family default
13293  command to implement table captions.
13294  As a result, a table created by \SpecialChar LyX
13295  is printed correctly, but its caption
13296  is ignored.
13297  However, you can use some \SpecialChar TeX
13298  code to overcome this problem, so that captions
13299  are printed as expected.
13300  To do so, create a float table as usual, remove the caption, and replace
13301  it with the \SpecialChar TeX
13302  code 
13303 \family typewriter
13304
13305 \backslash
13306 tbl{
13307 \emph on
13308 your table caption
13309 \emph default
13310 }{
13311 \family default
13312  (sic); you must also the \SpecialChar TeX
13313  code 
13314 \family typewriter
13315 }
13316 \family default
13317  immediately after the tabular material.
13318  Study the example table included in the template files to see how this
13319  trick is implemented.
13320  Alternatively, If you need table captions, you should implement the whole
13321  table float in a 
13322 \family typewriter
13323 .tex
13324 \family default
13325  file, then include this file to the \SpecialChar LyX
13326  document (
13327 \family sans
13328 Insert\SpecialChar menuseparator
13329 File\SpecialChar menuseparator
13330 Child
13331 \begin_inset space ~
13332 \end_inset
13333
13334 Document
13335 \family default
13336 ).
13337  Details on how to create a table float can be found in the files 
13338 \family typewriter
13339 ws-ijmpc.tex
13340 \family default
13341  and 
13342 \family typewriter
13343 ws-ijmpd.tex
13344 \family default
13345 , included in the corresponding packages.
13346 \end_layout
13347
13348 \begin_layout Subsection
13349 Preparing a paper for submission
13350 \end_layout
13351
13352 \begin_layout Standard
13353 Before you submit your paper you must export the \SpecialChar LyX
13354  document as a \SpecialChar LaTeX
13355  file (
13356 \family sans
13357 File\SpecialChar menuseparator
13358 Export\SpecialChar menuseparator
13359 \SpecialChar LaTeX
13360
13361 \family default
13362 )
13363 \begin_inset Foot
13364 status open
13365
13366 \begin_layout Plain Layout
13367 Actually you have the choice between \SpecialChar LaTeX
13368  (plain) and pdflatex.
13369  If you intend to use pdflatex to prepare the paper, you should use the
13370  pdflatex option so that included graphics are converted to PDF format,
13371  ready for use by pdflatex.
13372 \end_layout
13373
13374 \end_inset
13375
13376 , then make the following changes to the resulting 
13377 \family typewriter
13378 .tex
13379 \family default
13380  file.
13381 \end_layout
13382
13383 \begin_layout Enumerate
13384 Remove the comment lines before the 
13385 \family typewriter
13386
13387 \backslash
13388 documentclass
13389 \family default
13390  command.
13391 \end_layout
13392
13393 \begin_layout Enumerate
13394 Remove everything between (and including) the 
13395 \family typewriter
13396
13397 \backslash
13398 makeatletter
13399 \family default
13400  and 
13401 \family typewriter
13402
13403 \backslash
13404 makeatother
13405 \family default
13406  commands, except for any commands you specifically put into the \SpecialChar LaTeX
13407  preamble.
13408 \end_layout
13409
13410 \begin_layout Standard
13411 The modified 
13412 \family typewriter
13413 .tex
13414 \family default
13415  file should be saved and processed through \SpecialChar LaTeX
13416  as many times as necessary.
13417  You may also want to check the resulting 
13418 \family typewriter
13419 .dvi
13420 \family default
13421  document.
13422 \end_layout
13423
13424 \begin_layout Section
13425 iopart
13426 \end_layout
13427
13428 \begin_layout Standard
13429 by 
13430 \noun on
13431 Uwe Stöhr
13432 \end_layout
13433
13434 \begin_layout Subsection
13435 Overview
13436 \end_layout
13437
13438 \begin_layout Standard
13439 The iopart package provides a document class to create electronic manuscript
13440  submission to the journals published by the Institute of Physics.
13441  Instructions for the authors how to create a paper using the iopart class
13442  can be downloaded together with the iopart package from the site 
13443 \begin_inset Flex URL
13444 status collapsed
13445
13446 \begin_layout Plain Layout
13447
13448 ftp://ftp.iop.org/pub/journals/latex2e
13449 \end_layout
13450
13451 \end_inset
13452
13453 .
13454 \end_layout
13455
13456 \begin_layout Subsection
13457 Writing a paper
13458 \end_layout
13459
13460 \begin_layout Standard
13461 The easiest way to write a paper is to start with the template 
13462 \emph on
13463 IOP-article.lyx
13464 \emph default
13465  that is available via 
13466 \family sans
13467 File\SpecialChar menuseparator
13468 New From Template
13469 \family default
13470  The template explains how to use the special text environments.
13471  Here are the most important advices:
13472 \end_layout
13473
13474 \begin_layout Itemize
13475 To be able to compile your document to a PDF, PS, or DVI, ensure that the
13476  no AMS packages are loaded in 
13477 \family sans
13478 Document\SpecialChar menuseparator
13479 Settings\SpecialChar menuseparator
13480 Math Options
13481 \family default
13482 !
13483 \end_layout
13484
13485 \begin_layout Itemize
13486
13487 \size normal
13488 The title environment defines the kind of your paper.
13489  So use one of the following environments for the title:
13490 \end_layout
13491
13492 \begin_deeper
13493 \begin_layout Itemize
13494
13495 \family sans
13496 \size normal
13497 Title
13498 \family default
13499  for a Paper
13500 \end_layout
13501
13502 \begin_layout Itemize
13503
13504 \family sans
13505 \size normal
13506 Review
13507 \family default
13508  for a Review
13509 \end_layout
13510
13511 \begin_layout Itemize
13512
13513 \family sans
13514 \size normal
13515 Topical
13516 \family default
13517  for a Topical review
13518 \end_layout
13519
13520 \begin_layout Itemize
13521
13522 \family sans
13523 \size normal
13524 Comment
13525 \family default
13526  for a Comment
13527 \end_layout
13528
13529 \begin_layout Itemize
13530
13531 \family sans
13532 \size normal
13533 Note
13534 \family default
13535  for a Note
13536 \end_layout
13537
13538 \begin_layout Itemize
13539
13540 \family sans
13541 \size normal
13542 Paper
13543 \family default
13544  for a Paper (same as Title)
13545 \end_layout
13546
13547 \begin_layout Itemize
13548
13549 \family sans
13550 \size normal
13551 Prelim
13552 \family default
13553  for a Preliminary communication
13554 \end_layout
13555
13556 \begin_layout Itemize
13557
13558 \family sans
13559 \size normal
13560 Rapid
13561 \family default
13562  for a Rapid communication
13563 \end_layout
13564
13565 \begin_layout Itemize
13566
13567 \family sans
13568 \size normal
13569 Letter
13570 \family default
13571  for a Letter to the editor
13572 \end_layout
13573
13574 \end_deeper
13575 \begin_layout Itemize
13576
13577 \size normal
13578 All title environments except of 
13579 \family sans
13580 Letter
13581 \family default
13582  can have an optional short title.
13583 \end_layout
13584
13585 \begin_layout Itemize
13586 There is a general title environment 
13587 \family sans
13588 Article
13589 \family default
13590  which is not directly supported by \SpecialChar LyX
13591 .
13592  This can be used as \SpecialChar TeX
13593  code when your document doesn't fit into one of the
13594  other title types.
13595 \end_layout
13596
13597 \begin_layout Standard
13598 For more informations like hints for special table and formula formatting,
13599  look at the IOP author guidelines.
13600 \end_layout
13601
13602 \begin_layout Section
13603 Kluwer
13604 \end_layout
13605
13606 \begin_layout Standard
13607 by 
13608 \noun on
13609 Panayotis Papasotiriou
13610 \end_layout
13611
13612 \begin_layout Subsection
13613 Overview
13614 \end_layout
13615
13616 \begin_layout Standard
13617 The Kluwer package is a set of macros produced by Kluwer Academic Publishers
13618  that facilitates electronic manuscript submission to the journals they
13619  publish.
13620  Most known of them (at least in my domain of interest) are 
13621 \emph on
13622 Astrophysics and Space Science
13623 \emph default
13624  and 
13625 \emph on
13626 Solar Physics
13627 \emph default
13628 , but there are many others (see a complete list at 
13629 \begin_inset Flex URL
13630 status collapsed
13631
13632 \begin_layout Plain Layout
13633
13634 http://www.wkap.nl/jrnllist.htm/JRNLHOME
13635 \end_layout
13636
13637 \end_inset
13638
13639 ).
13640  The Kluwer package may be downloaded from the site 
13641 \begin_inset Flex URL
13642 status collapsed
13643
13644 \begin_layout Plain Layout
13645
13646 http://www.wkap.nl/kaphtml.htm/STYLEFILES
13647 \end_layout
13648
13649 \end_inset
13650
13651 .
13652  A complete user guide is contained in that package (but it can also be
13653  downloaded separately).
13654 \end_layout
13655
13656 \begin_layout Standard
13657 \SpecialChar LyX
13658  supports many features of the package but not everything.
13659  However, the \SpecialChar TeX
13660  code needed is reduced to some 
13661 \begin_inset Quotes eld
13662 \end_inset
13663
13664 peculiar
13665 \begin_inset Quotes erd
13666 \end_inset
13667
13668  commands of the package (see
13669 \begin_inset space ~
13670 \end_inset
13671
13672
13673 \begin_inset CommandInset ref
13674 LatexCommand ref
13675 reference "subsec:kluwer_peculiarities"
13676
13677 \end_inset
13678
13679 ).
13680  I have recently used \SpecialChar LyX
13681  to write an article submitted to the 
13682 \emph on
13683 Astrophysics and Space Science
13684 \emph default
13685  without any problem.
13686 \end_layout
13687
13688 \begin_layout Subsection
13689 Writing a paper
13690 \end_layout
13691
13692 \begin_layout Standard
13693 The easiest way to write a paper is to start with the Kluwer template file.
13694  Click on 
13695 \family sans
13696 File\SpecialChar menuseparator
13697 New from
13698 \family default
13699  
13700 \family sans
13701 Template
13702 \family default
13703 , then choose the 
13704 \family typewriter
13705 kluwer.lyx
13706 \family default
13707  template.
13708  This will give an (almost) empty document that includes the most common
13709  fields found in a manuscript and a short description of their use.
13710  As in most templates, simply overwrite the existing text (including the
13711  brackets, 
13712 \family typewriter
13713 <>
13714 \family default
13715 ) with the correct information.
13716 \end_layout
13717
13718 \begin_layout Subsection
13719 Preparing a paper for submission
13720 \end_layout
13721
13722 \begin_layout Standard
13723 As in the AAS\SpecialChar TeX
13724  package, before you submit your paper to a journal you must
13725  
13726 \begin_inset Quotes eld
13727 \end_inset
13728
13729 postprocess
13730 \begin_inset Quotes erd
13731 \end_inset
13732
13733  it as follows.
13734 \end_layout
13735
13736 \begin_layout Enumerate
13737 Export your paper as a \SpecialChar LaTeX
13738  file.
13739  To do this, click on 
13740 \family sans
13741 File\SpecialChar menuseparator
13742 Export\SpecialChar menuseparator
13743 \SpecialChar LaTeX
13744
13745 \family default
13746 .
13747  
13748 \end_layout
13749
13750 \begin_layout Enumerate
13751 Edit the resulting 
13752 \family typewriter
13753 .tex
13754 \family default
13755  file with a text editor and make the following changes
13756 \end_layout
13757
13758 \begin_deeper
13759 \begin_layout Enumerate
13760 remove the comment lines before the 
13761 \family typewriter
13762
13763 \backslash
13764 documentclass
13765 \family default
13766  command,
13767 \end_layout
13768
13769 \begin_layout Enumerate
13770 remove everything between (and including) the 
13771 \family typewriter
13772
13773 \backslash
13774 makeatletter
13775 \family default
13776  and 
13777 \family typewriter
13778
13779 \backslash
13780 makeatother
13781 \family default
13782  commands, except for any commands you specifically put into the \SpecialChar LaTeX
13783  preamble.
13784 \end_layout
13785
13786 \begin_layout Standard
13787 Save the resulting 
13788 \family typewriter
13789 .tex
13790 \family default
13791  file.
13792 \end_layout
13793
13794 \end_deeper
13795 \begin_layout Enumerate
13796 Run the 
13797 \family typewriter
13798 .tex
13799 \family default
13800  file through \SpecialChar LaTeX
13801  as many times as necessary (usually up to three).
13802 \end_layout
13803
13804 \begin_layout Enumerate
13805 View the resulting 
13806 \family typewriter
13807 .dvi
13808 \family default
13809  document using, e.
13810 \begin_inset space \thinspace{}
13811 \end_inset
13812
13813 g.
13814 \begin_inset space \space{}
13815 \end_inset
13816
13817
13818 \family sans
13819 xdvi
13820 \family default
13821 , and check if everything is OK (it should, if you didn't make any mistake).
13822 \end_layout
13823
13824 \begin_layout Subsection
13825 \begin_inset Quotes eld
13826 \end_inset
13827
13828 Peculiarities
13829 \begin_inset Quotes erd
13830 \end_inset
13831
13832  of the Kluwer package
13833 \begin_inset CommandInset label
13834 LatexCommand label
13835 name "subsec:kluwer_peculiarities"
13836
13837 \end_inset
13838
13839
13840 \end_layout
13841
13842 \begin_layout Standard
13843 The Kluwer package has the following 
13844 \begin_inset Quotes eld
13845 \end_inset
13846
13847 peculiarities
13848 \begin_inset Quotes erd
13849 \end_inset
13850
13851 .
13852 \end_layout
13853
13854 \begin_layout Enumerate
13855 It is possible to write multiple articles in the same \SpecialChar LaTeX
13856  file
13857 \begin_inset Foot
13858 status collapsed
13859
13860 \begin_layout Plain Layout
13861 I can't imagine any good reason to do this.
13862 \end_layout
13863
13864 \end_inset
13865
13866 .
13867  Each article must be included in the environment 
13868 \begin_inset Quotes eld
13869 \end_inset
13870
13871 article
13872 \begin_inset Quotes erd
13873 \end_inset
13874
13875 .
13876  Unfortunately, this environment cannot be omitted, even if you write just
13877  one article.
13878  Therefore, each article starts with the command 
13879 \family typewriter
13880
13881 \backslash
13882 begin{article}
13883 \family default
13884  and, obviously, ends with the command 
13885 \family typewriter
13886
13887 \backslash
13888 end{article}
13889 \family default
13890 .
13891  Although this can be implemented in \SpecialChar LyX
13892 , I didn't included it, since it looks
13893  ugly and can confuse the novice user.
13894  Therefore, you need to enter them directly and mark them as \SpecialChar LaTeX
13895  code (the
13896  well-known 
13897 \begin_inset Quotes eld
13898 \end_inset
13899
13900 \SpecialChar TeX
13901  code
13902 \begin_inset Quotes erd
13903 \end_inset
13904
13905 ).
13906 \end_layout
13907
13908 \begin_layout Enumerate
13909 Information given at the beginning of the article (i.
13910 \begin_inset space \thinspace{}
13911 \end_inset
13912
13913 e.
13914 \begin_inset space \space{}
13915 \end_inset
13916
13917 title, subtitle, author, institution, running title, running author, abstract
13918  and keywords) must be included in an environment called 
13919 \begin_inset Quotes eld
13920 \end_inset
13921
13922 opening
13923 \begin_inset Quotes erd
13924 \end_inset
13925
13926 .
13927  This is not implemented in \SpecialChar LyX
13928 , so you must enter title, subtitle etc.
13929 \begin_inset space ~
13930 \end_inset
13931
13932 between two \SpecialChar TeX
13933  code lines (
13934 \family typewriter
13935
13936 \backslash
13937 begin{opening}
13938 \family default
13939  and 
13940 \family typewriter
13941
13942 \backslash
13943 end{opening}
13944 \family default
13945 ).
13946 \end_layout
13947
13948 \begin_layout Enumerate
13949 According to the user manual, the label of each bibliography item must be
13950  written as 
13951 \family typewriter
13952
13953 \backslash
13954 protect
13955 \backslash
13956 citeauthoryear{
13957 \family default
13958 \emph on
13959 author(s)
13960 \family typewriter
13961 \emph default
13962 }{
13963 \family default
13964 \emph on
13965 year
13966 \family typewriter
13967 \emph default
13968 }
13969 \family default
13970 .
13971 \end_layout
13972
13973 \begin_layout Standard
13974 The 
13975 \family typewriter
13976 kluwer.lyx
13977 \family default
13978  template takes care of all these 
13979 \begin_inset Quotes eld
13980 \end_inset
13981
13982 peculiarities
13983 \begin_inset Quotes erd
13984 \end_inset
13985
13986 .
13987  If you start a new paper using this template you don't need to do anything
13988  special.
13989  Just 
13990 \end_layout
13991
13992 \begin_layout Enumerate
13993 don't delete the \SpecialChar TeX
13994  code included in the template, and
13995 \end_layout
13996
13997 \begin_layout Enumerate
13998 copy the example bibliography item included in the template and modify it
13999  as necessary to enter new bibliography items.
14000 \end_layout
14001
14002 \begin_layout Section
14003 Koma-Script
14004 \end_layout
14005
14006 \begin_layout Standard
14007 by 
14008 \noun on
14009 Bernd Rellermeyer
14010 \end_layout
14011
14012 \begin_layout Subsection
14013 Overview
14014 \end_layout
14015
14016 \begin_layout Standard
14017 The \SpecialChar LyX
14018  document classes 
14019 \emph on
14020 article (koma-script)
14021 \emph default
14022
14023 \emph on
14024 report (koma-script)
14025 \emph default
14026
14027 \emph on
14028 book
14029 \emph default
14030  
14031 \emph on
14032 (koma-script)
14033 \emph default
14034 , and 
14035 \emph on
14036 letter
14037 \emph default
14038  
14039 \emph on
14040 (koma-script)
14041 \emph default
14042  correspond to the \SpecialChar LaTeX
14043  document classes 
14044 \family typewriter
14045 scrartcl.cls
14046 \family default
14047
14048 \family typewriter
14049 scrreprt.cls
14050 \family default
14051
14052 \family typewriter
14053 scrbook.cls
14054 \family default
14055 , and 
14056 \family typewriter
14057 scrlettr.cls
14058 \family default
14059 , resp.
14060 \begin_inset space ~
14061 \end_inset
14062
14063 of the Koma-Script family.
14064  They are replacements for the standard document classes 
14065 \family typewriter
14066 article.cls
14067 \family default
14068
14069 \family typewriter
14070 report.cls
14071 \family default
14072
14073 \family typewriter
14074 book.cls
14075 \family default
14076  and 
14077 \family typewriter
14078 letter.cls
14079 \family default
14080 , resp., and fit better to European typography conventions in a number of
14081  points.
14082 \end_layout
14083
14084 \begin_layout Itemize
14085 Standard character size is 11pt in 
14086 \emph on
14087 article (koma-script)
14088 \emph default
14089
14090 \emph on
14091 report (koma-script)
14092 \emph default
14093 , and 
14094 \emph on
14095 book (koma-script)
14096 \emph default
14097 , and 12pt in 
14098 \emph on
14099 letter (koma-script)
14100 \emph default
14101 .
14102 \end_layout
14103
14104 \begin_layout Itemize
14105 Headings, labels of the description environment, and a number of elements
14106  of the 
14107 \emph on
14108 letter (koma-script)
14109 \emph default
14110  document class are set in a bold sans serif font.
14111 \begin_inset Foot
14112 status collapsed
14113
14114 \begin_layout Plain Layout
14115 There is a big difference between the bold sans serif old cm fonts and new
14116  ec fonts, especially in the appearance of headings.
14117  In comparison, the ec bold sans serif fonts look a bit thin.
14118  Here the \SpecialChar LaTeX
14119  package 
14120 \family typewriter
14121 cmsd.sty by
14122 \family default
14123  
14124 \shape smallcaps
14125 Walter Schmidt
14126 \shape default
14127  helps to produce the 
14128 \begin_inset Quotes eld
14129 \end_inset
14130
14131 usual
14132 \begin_inset Quotes erd
14133 \end_inset
14134
14135  appearance when using the ec fonts.
14136 \end_layout
14137
14138 \end_inset
14139
14140  The numbering of chapter headings is made in the same way as the numbering
14141  of section headings, that is without the extra line 
14142 \begin_inset Quotes eld
14143 \end_inset
14144
14145 Chapter\SpecialChar ldots
14146
14147 \begin_inset Quotes erd
14148 \end_inset
14149
14150 .
14151  In addition, the appearance of the headings can be modified by using a
14152  number of options (in \SpecialChar LyX
14153  to be entered in the field 
14154 \family sans
14155 Extra
14156 \begin_inset space ~
14157 \end_inset
14158
14159 Options
14160 \family default
14161  of the dialog 
14162 \family sans
14163 Layout\SpecialChar menuseparator
14164 Document
14165 \family default
14166 ).
14167  
14168 \end_layout
14169
14170 \begin_layout Itemize
14171 The main means in the Koma-Script document classes to design the type area
14172  are the options 
14173 \family sans
14174 BCOR
14175 \family default
14176  and 
14177 \family sans
14178 DIV
14179 \family default
14180  (in \SpecialChar LyX
14181  to be entered in the extra class options field in the dialog 
14182 \family sans
14183 Document\SpecialChar menuseparator
14184 Settings
14185 \family default
14186 ).
14187  They make a clearer modification of page margins possible as do the options
14188  of the dialog 
14189 \family sans
14190 Document\SpecialChar menuseparator
14191 Settings
14192 \family default
14193 .
14194  
14195 \end_layout
14196
14197 \begin_layout Itemize
14198 The \SpecialChar LaTeX
14199  document classes of the Koma-Script family define a number of additional
14200  commands.
14201  Those part of it which makes sense in \SpecialChar LyX
14202  is implemented in corresponding
14203  paragraph types.
14204 \end_layout
14205
14206 \begin_layout Standard
14207 Detailed descriptions of the \SpecialChar LaTeX
14208  document classes of the Koma-Script family
14209  can be found in the Koma-Script documentation 
14210 \emph on
14211 scrguide
14212 \emph default
14213  (German) and 
14214 \emph on
14215 scrguien
14216 \emph default
14217  (English).
14218 \end_layout
14219
14220 \begin_layout Subsection
14221 article (koma-script), report (koma-script), and book (koma-script)
14222 \end_layout
14223
14224 \begin_layout Standard
14225 The document classes 
14226 \emph on
14227 article (koma-script)
14228 \emph default
14229
14230 \emph on
14231 report (koma-script)
14232 \emph default
14233 , and 
14234 \emph on
14235 book
14236 \emph default
14237  
14238 \emph on
14239 (koma-script)
14240 \emph default
14241  are implemented in the layout files 
14242 \family typewriter
14243 scrartcl.layout
14244 \family default
14245
14246 \family typewriter
14247 scrreprt.layout
14248 \family default
14249 , and 
14250 \family typewriter
14251 scrbook.layout
14252 \family default
14253 , resp.
14254  They contain all the paragraph types of the corresponding standard document
14255  classes 
14256 \emph on
14257 article
14258 \emph default
14259
14260 \emph on
14261 report
14262 \emph default
14263 , and 
14264 \emph on
14265 book
14266 \emph default
14267 , resp., partly modified, with the exception of the \SpecialChar LyX
14268  specific 
14269 \family sans
14270 List
14271 \family default
14272 -type, which is replaced by the new 
14273 \family sans
14274 Labeling
14275 \family default
14276 -type having the same functionality.
14277  Beside the 
14278 \family sans
14279 Labeling
14280 \family default
14281 -Type there is a number of new paragraph types added.
14282  They are 
14283 \emph on
14284 not
14285 \emph default
14286  part of 
14287 \emph on
14288 letter (koma-script)
14289 \emph default
14290 .
14291 \end_layout
14292
14293 \begin_layout Itemize
14294
14295 \family sans
14296 Addpart, Addchap
14297 \family default
14298
14299 \family sans
14300 Addsec
14301 \family default
14302 : are equivalents to 
14303 \family sans
14304 Part*, Chapter*
14305 \family default
14306  and 
14307 \family sans
14308 Section*
14309 \family default
14310 , resp., additionally inserting an entry in the table of contents.
14311  
14312 \family sans
14313 Addpart
14314 \family default
14315  and 
14316 \family sans
14317 Addchap
14318 \family default
14319  are not contained in 
14320 \emph on
14321 article (koma-script)
14322 \emph default
14323 .
14324 \end_layout
14325
14326 \begin_layout Itemize
14327
14328 \family sans
14329 Addchap*
14330 \family default
14331
14332 \family sans
14333 Addsec*
14334 \family default
14335 : behave exactly as 
14336 \family sans
14337 Addchap
14338 \family default
14339  and 
14340 \family sans
14341 Addsec
14342 \family default
14343 , resp., additionally clearing running heads.
14344  
14345 \family sans
14346 Addchap*
14347 \family default
14348  is not contained in 
14349 \emph on
14350 article (koma-script)
14351 \emph default
14352 .
14353 \begin_inset Foot
14354 status collapsed
14355
14356 \begin_layout Plain Layout
14357 There is also an 
14358 \family typewriter
14359
14360 \backslash
14361 addpart*
14362 \family default
14363  command in 
14364 \emph on
14365 book (koma-script)
14366 \emph default
14367  and in 
14368 \emph on
14369 report (koma-script)
14370 \emph default
14371 , but since this is identical to 
14372 \family sans
14373 Part*
14374 \family default
14375 , is has not been implemented in \SpecialChar LyX
14376 .
14377 \end_layout
14378
14379 \end_inset
14380
14381
14382 \end_layout
14383
14384 \begin_layout Itemize
14385
14386 \family sans
14387 Minisec
14388 \family default
14389 : generates a heading directly above the following paragraph in the standard
14390  character size without affecting the structure of the document.
14391 \end_layout
14392
14393 \begin_layout Itemize
14394
14395 \family sans
14396 Captionabove
14397 \family default
14398  and 
14399 \family sans
14400 Captionbelow
14401 \family default
14402  are special captions which respect the different space settings needed
14403  for captions placed above or below an element (if you follow strict typographic
14404  rules, you might want to place table captions always above the table).
14405  You can also use the class option 
14406 \family typewriter
14407 tablecaptionsabove
14408 \family default
14409 , which will switch 
14410 \family sans
14411 caption
14412 \family default
14413  to 
14414 \family sans
14415 captionabove
14416 \family default
14417  for tables and 
14418 \family sans
14419 captionbelow
14420 \family default
14421  for figures.
14422  You need at least Koma-Script version 2.8q to use this.
14423 \end_layout
14424
14425 \begin_layout Itemize
14426
14427 \family sans
14428 Dictum
14429 \family default
14430 : can be used to set a bonmot, e.
14431 \begin_inset space \thinspace{}
14432 \end_inset
14433
14434 g.
14435 \begin_inset space \space{}
14436 \end_inset
14437
14438 at the beginning of a chapter.
14439  If you use the optional argument (
14440 \family sans
14441 Insert\SpecialChar menuseparator
14442 Dictum
14443 \begin_inset space ~
14444 \end_inset
14445
14446 Author
14447 \family default
14448 ), you can insert the dictum's author there.
14449  Dictum and author are separated by a line.
14450  You need at least Koma-Script version 2.8q to use this.
14451  
14452 \family sans
14453 Dictum
14454 \family default
14455  is not contained in 
14456 \emph on
14457 article (koma-script)
14458 \emph default
14459 .
14460 \end_layout
14461
14462 \begin_layout Standard
14463 The following types, together with the standard types 
14464 \family sans
14465 Title
14466 \family default
14467
14468 \family sans
14469 Author
14470 \family default
14471 , and 
14472 \family sans
14473 Date
14474 \family default
14475 , form the title area of the document.
14476  They must be entered ahead of the first 
14477 \begin_inset Quotes eld
14478 \end_inset
14479
14480 ordinary
14481 \begin_inset Quotes erd
14482 \end_inset
14483
14484  paragraph.
14485 \begin_inset Foot
14486 status collapsed
14487
14488 \begin_layout Plain Layout
14489 The corresponding \SpecialChar LaTeX
14490  commands must appear before the 
14491 \family typewriter
14492
14493 \backslash
14494 maketitle
14495 \family default
14496  command.
14497 \end_layout
14498
14499 \end_inset
14500
14501  When such a type is used more than once, the latter usage overwrites the
14502  former one, that means, for every type only the latest usage is valid.
14503  The order of the different types however has, like 
14504 \family sans
14505 Title
14506 \family default
14507
14508 \family sans
14509 Author
14510 \family default
14511 , and 
14512 \family sans
14513 Date
14514 \family default
14515 , no effect on the appearance of the produced document.
14516 \end_layout
14517
14518 \begin_layout Itemize
14519
14520 \family sans
14521 Subject
14522 \family default
14523 : produces a centered paragraph above the ordinary title (
14524 \family sans
14525 Title
14526 \family default
14527
14528 \family sans
14529 Author
14530 \family default
14531
14532 \family sans
14533 Date
14534 \family default
14535 ) for the subject of the document.
14536 \end_layout
14537
14538 \begin_layout Itemize
14539
14540 \family sans
14541 Publishers
14542 \family default
14543 : produces a centered paragraph below the ordinary title (
14544 \family sans
14545 Title
14546 \family default
14547
14548 \family sans
14549 Author
14550 \family default
14551
14552 \family sans
14553 Date
14554 \family default
14555 ) for the publishers' name.
14556 \end_layout
14557
14558 \begin_layout Itemize
14559
14560 \family sans
14561 Dedication
14562 \family default
14563 : in 
14564 \emph on
14565 report (koma-script)
14566 \emph default
14567  and 
14568 \emph on
14569 book (koma-script)
14570 \emph default
14571  produces a centered paragraph on its own page behind the title page, or
14572  in 
14573 \emph on
14574 article (koma-script)
14575 \emph default
14576  produces a centered paragraph below the ordinary title (
14577 \family sans
14578 Title
14579 \family default
14580
14581 \family sans
14582 Author
14583 \family default
14584
14585 \family sans
14586 Date
14587 \family default
14588
14589 \family sans
14590 Publishers
14591 \family default
14592 ) for a dedication.
14593 \end_layout
14594
14595 \begin_layout Itemize
14596
14597 \family sans
14598 Titlehead
14599 \family default
14600 : produces a left aligned paragraph above the ordinary title (
14601 \family sans
14602 Title
14603 \family default
14604
14605 \family sans
14606 Author
14607 \family default
14608
14609 \family sans
14610 Date
14611 \family default
14612
14613 \family sans
14614 Subject
14615 \family default
14616 ) for a document`s head.
14617 \end_layout
14618
14619 \begin_layout Itemize
14620
14621 \family sans
14622 Uppertitleback
14623 \family default
14624 : produces in a double-sided print in 
14625 \emph on
14626 report (koma-script)
14627 \emph default
14628  and 
14629 \emph on
14630 book (koma-script)
14631 \emph default
14632  a left-aligned paragraph at the top of the title page`s back or has no
14633  effect in a single-sided print or in 
14634 \emph on
14635 article (koma-script)
14636 \emph default
14637 .
14638 \end_layout
14639
14640 \begin_layout Itemize
14641
14642 \family sans
14643 Lowertitleback
14644 \family default
14645 : produces in a double-sided print in 
14646 \emph on
14647 report (koma-script)
14648 \emph default
14649  and 
14650 \emph on
14651 book (koma-script)
14652 \emph default
14653  a left-aligned paragraph at the bottom of the title page`s back or has
14654  no effect in a single-sided print or in 
14655 \emph on
14656 article (koma-script)
14657 \emph default
14658 .
14659 \end_layout
14660
14661 \begin_layout Itemize
14662
14663 \family sans
14664 Extratitle
14665 \family default
14666 : produces a special 
14667 \begin_inset Quotes eld
14668 \end_inset
14669
14670 dirty
14671 \begin_inset Quotes erd
14672 \end_inset
14673
14674  page ahead of the actual document containing a paragraph without special
14675  formatting.
14676 \end_layout
14677
14678 \begin_layout Standard
14679 The layout files for the document classes 
14680 \emph on
14681 article (koma-script)
14682 \emph default
14683
14684 \emph on
14685 report (koma-script)
14686 \emph default
14687 , and 
14688 \emph on
14689 book (koma-script)
14690 \emph default
14691  do include the file 
14692 \family typewriter
14693 scrmacros.inc
14694 \family default
14695 .
14696  This is thought of as a place to define your own types.
14697  Copy scrmacros
14698 \family typewriter
14699 .inc
14700 \family default
14701  in your personal layout directory and edit the file!
14702 \end_layout
14703
14704 \begin_layout Subsection
14705 letter (koma-script)
14706 \end_layout
14707
14708 \begin_layout Description
14709 Note: This section discusses the obsolete 
14710 \family sans
14711 KOMA-Script-Letter (v.
14712 \begin_inset space ~
14713 \end_inset
14714
14715 1)
14716 \family default
14717 , which is not even included anymore in recent KOMA releases.
14718  Please refer to the next section for the current KOMA-Script-Letter class
14719  (v.
14720 \begin_inset space ~
14721 \end_inset
14722
14723 2)!
14724 \end_layout
14725
14726 \begin_layout Standard
14727 \noindent
14728 The document class 
14729 \emph on
14730 letter (koma-script)
14731 \emph default
14732  is implemented in the layout file 
14733 \family typewriter
14734 scrlettr.layout
14735 \family default
14736 .
14737  It contains all the paragraph types of the corresponding standard document
14738  class 
14739 \emph on
14740 letter
14741 \emph default
14742 , partly modified, with the exception of the \SpecialChar LyX
14743  specific types 
14744 \family sans
14745 \SpecialChar LyX
14746 -Code
14747 \family default
14748  and 
14749 \family sans
14750 Comment
14751 \family default
14752  and the 
14753 \family sans
14754 List
14755 \family default
14756  type, which is replaced by the new 
14757 \family sans
14758 Labeling
14759 \family default
14760  type.
14761  In addition, it contains, in contrast to the standard document class, the
14762  standard types 
14763 \family sans
14764 \SpecialChar LaTeX
14765
14766 \family default
14767
14768 \family sans
14769 Quotation
14770 \family default
14771
14772 \family sans
14773 Quote
14774 \family default
14775 , and 
14776 \family sans
14777 Verse
14778 \family default
14779 .
14780  Furthermore, there are a number of new letter specific types.
14781 \end_layout
14782
14783 \begin_layout Standard
14784 The appearance of the letter produced by this document class can be controlled
14785  by a number of \SpecialChar LaTeX
14786  commands, which you can put in the \SpecialChar LaTeX
14787  preamble.
14788 \begin_inset Foot
14789 status collapsed
14790
14791 \begin_layout Plain Layout
14792 For example, the standard appearance of the letter`s heading, consisting
14793  of name and address, is quite self-willed.
14794  An 
14795 \begin_inset Quotes eld
14796 \end_inset
14797
14798 ordinary
14799 \begin_inset Quotes erd
14800 \end_inset
14801
14802  heading is produced by the following \SpecialChar LaTeX
14803  commands in the preamble:
14804 \end_layout
14805
14806 \begin_layout LyX-Code
14807
14808 \backslash
14809 firsthead{
14810 \backslash
14811 parbox[b]{
14812 \backslash
14813 textwidth}
14814 \end_layout
14815
14816 \begin_layout LyX-Code
14817   {
14818 \backslash
14819 ignorespaces 
14820 \backslash
14821 fromname
14822 \backslash
14823
14824 \backslash
14825  
14826 \backslash
14827 ignorespaces 
14828 \backslash
14829 fromaddress}} 
14830 \end_layout
14831
14832 \begin_layout LyX-Code
14833
14834 \backslash
14835 nexthead{
14836 \backslash
14837 parbox[b]{
14838 \backslash
14839 textwidth}
14840 \end_layout
14841
14842 \begin_layout LyX-Code
14843   {
14844 \backslash
14845 ignorespaces 
14846 \backslash
14847 fromname 
14848 \backslash
14849 hfill 
14850 \backslash
14851 ignorespaces 
14852 \backslash
14853 pagename
14854 \backslash
14855  
14856 \backslash
14857 thepage}}
14858 \end_layout
14859
14860 \end_inset
14861
14862  A detailed German description of such \SpecialChar LaTeX
14863  commands can be found in the Koma-Script
14864  documentation 
14865 \emph on
14866 scrguide
14867 \emph default
14868 .
14869  With it, the letter's author can produce his personal letter layout.
14870 \end_layout
14871
14872 \begin_layout Standard
14873 The types 
14874 \family sans
14875 Letter
14876 \family default
14877  and 
14878 \family sans
14879 Opening
14880 \family default
14881  define the beginning of the letter and must be used in every letter.
14882  To emphasize them in the \SpecialChar LyX
14883  document class, they are marked with the letter
14884  
14885 \shape italic
14886 L
14887 \shape default
14888  or 
14889 \shape italic
14890 O
14891 \shape default
14892 , resp.
14893 \begin_inset space ~
14894 \end_inset
14895
14896 in the left margin.
14897  It is possible to write any number of letters in one file.
14898  An 
14899 \family sans
14900 Opening
14901 \family default
14902  type produces a new letter using the same addressee and a 
14903 \family sans
14904 Letter
14905 \family default
14906  type produces a new addressee.
14907  The types 
14908 \family sans
14909 Closing
14910 \family default
14911
14912 \family sans
14913 PS
14914 \family default
14915
14916 \family sans
14917 CC
14918 \family default
14919 , and 
14920 \family sans
14921 Encl
14922 \family default
14923  are ordinary paragraph types and can also be used several times in one
14924  and the same letter.
14925 \end_layout
14926
14927 \begin_layout Itemize
14928
14929 \family sans
14930 Letter
14931 \family default
14932 : produces a paragraph for the addressee and implicitly defines the beginning
14933  of the letter.
14934 \end_layout
14935
14936 \begin_layout Itemize
14937
14938 \family sans
14939 Opening
14940 \family default
14941 : produces a paragraph for the form of address and implicitly produces a
14942  new letter.
14943 \end_layout
14944
14945 \begin_layout Itemize
14946
14947 \family sans
14948 Closing
14949 \family default
14950 : produces a paragraph for a close.
14951 \end_layout
14952
14953 \begin_layout Itemize
14954
14955 \family sans
14956 PS
14957 \family default
14958 : produces a paragraph for a postscript.
14959 \end_layout
14960
14961 \begin_layout Itemize
14962
14963 \family sans
14964 CC
14965 \family default
14966 : produces a paragraph for a distribution list.
14967 \end_layout
14968
14969 \begin_layout Itemize
14970
14971 \family sans
14972 Encl
14973 \family default
14974 : produces a paragraph for enclosures.
14975 \end_layout
14976
14977 \begin_layout Standard
14978 The types 
14979 \family sans
14980 Name
14981 \family default
14982
14983 \family sans
14984 Signature
14985 \family default
14986
14987 \family sans
14988 Address
14989 \family default
14990
14991 \family sans
14992 Telephone
14993 \family default
14994
14995 \family sans
14996 Place
14997 \family default
14998
14999 \family sans
15000 Backaddress
15001 \family default
15002
15003 \family sans
15004 Specialmail
15005 \family default
15006
15007 \family sans
15008 Location
15009 \family default
15010
15011 \family sans
15012 Title
15013 \family default
15014 , and 
15015 \family sans
15016 Subject
15017 \family default
15018  are input types provided with a label to enter information, which will
15019  be processed by the document class.
15020 \begin_inset Foot
15021 status collapsed
15022
15023 \begin_layout Plain Layout
15024 It could be seen as a matter of inconsequence, that the types 
15025 \family sans
15026 Letter
15027 \family default
15028  and 
15029 \family sans
15030 Opening
15031 \family default
15032  described above are not such input types as well.
15033  Because of the special meaning of those types, however, I have implemented
15034  them as ordinary paragraph types with a one letter mark in the left margin.
15035  Moreover, it would affect my feeling of symmetry, if the 
15036 \family sans
15037 Opening
15038 \family default
15039  type and the 
15040 \family sans
15041 Closing
15042 \family default
15043  type had such a serious different appearance.
15044 \end_layout
15045
15046 \end_inset
15047
15048  The types must be used ahead of the corresponding 
15049 \family sans
15050 Opening
15051 \family default
15052  type.
15053 \end_layout
15054
15055 \begin_layout Standard
15056 An implementation of these types in a WYSIWYG fashion does not seem to make
15057  sense, because the real appearance of the produced letter does not only
15058  depend on the usage of the particular type, but also on other factors.
15059  For example, a signature entered in the 
15060 \family sans
15061 Signature
15062 \family default
15063  type will in the standard behavior appear in the produced letter only,
15064  when in the same letter also a 
15065 \family sans
15066 Closing
15067 \family default
15068  type is used.
15069  The entered value of the 
15070 \family sans
15071 Telephone
15072 \family default
15073  type will in the standard behavior not appear in the produced letter at
15074  all.
15075  The possibility to design the letter`s heading freely is already indicated
15076  in a footnote above.
15077 \end_layout
15078
15079 \begin_layout Standard
15080 The input types can also be used as empty paragraphs.
15081  This makes sense e.
15082 \begin_inset space \thinspace{}
15083 \end_inset
15084
15085 g.
15086 \begin_inset space \space{}
15087 \end_inset
15088
15089 for the 
15090 \family sans
15091 Signature
15092 \family default
15093  type.
15094  If the 
15095 \family sans
15096 Signature
15097 \family default
15098  type is not used at all, in the standard behavior the value of the 
15099 \family sans
15100 Name
15101 \family default
15102  type is used as signature, whereas if an empty 
15103 \family sans
15104 Signature
15105 \family default
15106  type is used, no signature value is defined.
15107 \end_layout
15108
15109 \begin_layout Standard
15110 By using the input types it is possible to write a letter template, containing
15111  filled input types with your personal dates (name, address, etc.) and empty
15112  input types for other dates you want to enter.
15113 \end_layout
15114
15115 \begin_layout Itemize
15116
15117 \family sans
15118 Name
15119 \family default
15120 : sender's name, in the standard behavior appears as a centered paragraph
15121  in small caps in the letter`s heading.
15122 \end_layout
15123
15124 \begin_layout Itemize
15125
15126 \family sans
15127 Signature
15128 \family default
15129 : sender's signature, in the standard behavior appears below the 
15130 \family sans
15131 Closing
15132 \family default
15133  type.
15134  If no 
15135 \family sans
15136 Signature
15137 \family default
15138  type is used, the value of the 
15139 \family sans
15140 Name
15141 \family default
15142  type appears instead.
15143 \end_layout
15144
15145 \begin_layout Itemize
15146
15147 \family sans
15148 Address
15149 \family default
15150 : sender's address, in the standard behavior appears in a centered paragraph
15151  in the letter`s heading below the sender's name.
15152 \end_layout
15153
15154 \begin_layout Itemize
15155
15156 \family sans
15157 Telephone
15158 \family default
15159 : sender's telephone number, in the standard behavior only sets the \SpecialChar LaTeX
15160  variable
15161  
15162 \family typewriter
15163
15164 \backslash
15165 telephonenum
15166 \family default
15167 .
15168 \end_layout
15169
15170 \begin_layout Itemize
15171
15172 \family sans
15173 Place
15174 \family default
15175 : place of the letter`s making.
15176 \end_layout
15177
15178 \begin_layout Itemize
15179
15180 \family sans
15181 Date
15182 \family default
15183 : date of the letter`s making.
15184  
15185 \family sans
15186 Place
15187 \family default
15188  and 
15189 \family sans
15190 Date
15191 \family default
15192 , in the standard behavior, produce the place and the date in a right-aligned
15193  line below the addressee's field.
15194  If an empty 
15195 \family sans
15196 Date
15197 \family default
15198  type is used, neither place nor date appear, independent of the value of
15199  the 
15200 \family sans
15201 Place
15202 \family default
15203  type.
15204  If no 
15205 \family sans
15206 Date
15207 \family default
15208  type is used, the date of the letter `s production is used.
15209 \end_layout
15210
15211 \begin_layout Itemize
15212
15213 \family sans
15214 Backaddress
15215 \family default
15216 : sender`s back address, in the standard behavior appears above the addressee's
15217  field in a small sans serif font.
15218 \end_layout
15219
15220 \begin_layout Itemize
15221
15222 \family sans
15223 Specialmail
15224 \family default
15225 : special mail information, in the standard behavior appears underlined
15226  above the addressee's field below the back address.
15227 \end_layout
15228
15229 \begin_layout Itemize
15230
15231 \family sans
15232 Location
15233 \family default
15234 : additional information, in the standard behavior appears on right side
15235  below the addressee`s field.
15236 \end_layout
15237
15238 \begin_layout Itemize
15239
15240 \family sans
15241 Title
15242 \family default
15243 : the letter's title, in the standard behavior appears in a big, bold, sans
15244  serif font above the subject.
15245 \end_layout
15246
15247 \begin_layout Itemize
15248
15249 \family sans
15250 Subject
15251 \family default
15252 : the letter's subject, in the standard behavior appears in a bold font
15253  above the 
15254 \family sans
15255 Opening
15256 \family default
15257  paragraph.
15258 \end_layout
15259
15260 \begin_layout Standard
15261 The types 
15262 \family sans
15263 Yourref
15264 \family default
15265
15266 \family sans
15267 Yourmail
15268 \family default
15269
15270 \family sans
15271 Myref
15272 \family default
15273
15274 \family sans
15275 Customer
15276 \family default
15277 , and 
15278 \family sans
15279 Invoice
15280 \family default
15281  produce a business letter like line above the 
15282 \family sans
15283 Title
15284 \family default
15285  line containing the fields 
15286 \begin_inset Quotes eld
15287 \end_inset
15288
15289 Your ref.
15290 \begin_inset Quotes erd
15291 \end_inset
15292
15293
15294 \begin_inset Quotes eld
15295 \end_inset
15296
15297 Your letter of
15298 \begin_inset Quotes erd
15299 \end_inset
15300
15301
15302 \begin_inset Quotes eld
15303 \end_inset
15304
15305 Our ref.
15306 \begin_inset Quotes erd
15307 \end_inset
15308
15309
15310 \begin_inset Quotes eld
15311 \end_inset
15312
15313 Customer no.
15314 \begin_inset Quotes erd
15315 \end_inset
15316
15317
15318 \begin_inset Quotes eld
15319 \end_inset
15320
15321 Invoice no.
15322 \begin_inset Quotes erd
15323 \end_inset
15324
15325 , and 
15326 \begin_inset Quotes eld
15327 \end_inset
15328
15329 Date
15330 \begin_inset Quotes erd
15331 \end_inset
15332
15333 .
15334  For the date field, the value of the 
15335 \family sans
15336 Date
15337 \family default
15338  type is used.
15339  If one of these 
15340 \begin_inset Quotes eld
15341 \end_inset
15342
15343 business letter types
15344 \begin_inset Quotes erd
15345 \end_inset
15346
15347  is used, the value of the 
15348 \family sans
15349 Place
15350 \family default
15351  type however does not appear, but only the \SpecialChar LaTeX
15352  variable 
15353 \family typewriter
15354
15355 \backslash
15356 fromplace
15357 \family default
15358  is set.
15359  The ordinary output of place and date in a right-aligned line below the
15360  addressee`s field is suppressed.
15361  The types are implemented as input types provided with a label and must
15362  be used ahead of the corresponding 
15363 \family sans
15364 Opening
15365 \family default
15366  type.
15367 \end_layout
15368
15369 \begin_layout Itemize
15370
15371 \family sans
15372 Yourref
15373 \family default
15374 : Your ref.
15375 \end_layout
15376
15377 \begin_layout Itemize
15378
15379 \family sans
15380 Yourmail
15381 \family default
15382 : Your letter of.
15383 \end_layout
15384
15385 \begin_layout Itemize
15386
15387 \family sans
15388 Myref
15389 \family default
15390 : Our ref.
15391 \end_layout
15392
15393 \begin_layout Itemize
15394
15395 \family sans
15396 Customer
15397 \family default
15398 : Customer no.
15399 \end_layout
15400
15401 \begin_layout Itemize
15402
15403 \family sans
15404 Invoice
15405 \family default
15406 : Invoice no.
15407 \end_layout
15408
15409 \begin_layout Subsection
15410 The new letter class: letter (koma-script v.2)
15411 \end_layout
15412
15413 \begin_layout Standard
15414 by 
15415 \noun on
15416 Jürgen Spitzmüller
15417 \end_layout
15418
15419 \begin_layout Standard
15420 \begin_inset VSpace medskip
15421 \end_inset
15422
15423
15424 \end_layout
15425
15426 \begin_layout Standard
15427 \noindent
15428 Koma-Script version 2.8 has introduced a new letter class 
15429 \family typewriter
15430 scrlttr2
15431 \family default
15432  which supersedes the now unsupported 
15433 \family typewriter
15434 scrlettr
15435 \family default
15436 .
15437  It has â€” on the \SpecialChar LaTeX
15438  side â€” a completely new interface and is not compatible
15439  with the old class.
15440  Therefore, \SpecialChar LyX
15441  supports both, though it is recommended you use the new class.
15442 \end_layout
15443
15444 \begin_layout Standard
15445 This class covers the same functionality as 
15446 \emph on
15447 letter (koma-script),
15448 \emph default
15449  and a few more.
15450  The basic items are 
15451 \family sans
15452 Address
15453 \family default
15454  (receiver's address, same as 
15455 \family sans
15456 Letter
15457 \family default
15458  in the old layout), 
15459 \family sans
15460 Opening
15461 \family default
15462 , and 
15463 \family sans
15464 Closing
15465 \family default
15466 .
15467  
15468 \family sans
15469 NextAddress
15470 \family default
15471  will start a new letter (i.
15472 \begin_inset space \thinspace{}
15473 \end_inset
15474
15475 e.
15476 \begin_inset space \space{}
15477 \end_inset
15478
15479 you can write several letters per document).
15480  New elements are sender's 
15481 \family sans
15482 E-Mail
15483 \family default
15484
15485 \family sans
15486 URL
15487 \family default
15488
15489 \family sans
15490 Fax
15491 \family default
15492
15493 \family sans
15494 Bank
15495 \family default
15496  and the possibility to use a 
15497 \family sans
15498 Logo
15499 \family default
15500  (via 
15501 \family sans
15502 Insert\SpecialChar menuseparator
15503 Graphics
15504 \family default
15505 ) in the header.
15506 \end_layout
15507
15508 \begin_layout Standard
15509 The biggest improvement is, though, that the letter's layout is configurable
15510  to meet almost any needs.
15511  This can be done via the preamble or with a special style file (Letter
15512  Class Option, extension 
15513 \family typewriter
15514 *.lco
15515 \family default
15516 ), that will be read in as a class option.
15517 \begin_inset Foot
15518 status collapsed
15519
15520 \begin_layout Plain Layout
15521 The KOMA package comes with some default 
15522 \family typewriter
15523 *.lco
15524 \family default
15525  files.
15526  There is, for instance, a 
15527 \family typewriter
15528 DIN.lco
15529 \family default
15530  file that follows german typesetting rules, or a 
15531 \family typewriter
15532 KOMAold.lco
15533 \family default
15534  that provides the default layout of the old 
15535 \family typewriter
15536 scrlettr
15537 \family default
15538  class.
15539  The latter can be loaded with the class option 
15540 \family typewriter
15541 KOMAold
15542 \family default
15543 , inserted via the 
15544 \family sans
15545 Layout\SpecialChar menuseparator
15546 Document\SpecialChar menuseparator
15547 Extra Options
15548 \family default
15549  field.
15550 \end_layout
15551
15552 \end_inset
15553
15554  Have a look at the 
15555 \emph on
15556 koma-letter2
15557 \emph default
15558  template that is included in \SpecialChar LyX
15559  for examples.
15560  A detailed description is to be found in the Koma-Script documentation
15561  (
15562 \emph on
15563 scrguide
15564 \emph default
15565 ).
15566 \end_layout
15567
15568 \begin_layout Subsection
15569 Problems
15570 \end_layout
15571
15572 \begin_layout Standard
15573 Visualizing the Koma-Script document classes in \SpecialChar LyX
15574 , the \SpecialChar LyX
15575  internals cause some
15576  problems.
15577 \end_layout
15578
15579 \begin_layout Itemize
15580 The chapter number of a 
15581 \family sans
15582 Chapter
15583 \family default
15584  type appears on a line of its own above the chapter heading instead of
15585  appearing in the same line ahead of it.
15586  The cause for that is the \SpecialChar LyX
15587  internal behavior for the labeltype 
15588 \family sans
15589 Counter_Chapter
15590 \family default
15591  in the layout file.
15592 \end_layout
15593
15594 \begin_layout Itemize
15595 The headings of the types 
15596 \family sans
15597 Addchap
15598 \family default
15599  and 
15600 \family sans
15601 Addsec
15602 \family default
15603  are only put in the 
15604 \begin_inset Quotes eld
15605 \end_inset
15606
15607 true
15608 \begin_inset Quotes erd
15609 \end_inset
15610
15611  \SpecialChar LaTeX
15612  table of contents, but not in the \SpecialChar LyX
15613  table of contents (
15614 \family sans
15615 Document\SpecialChar menuseparator
15616 Table
15617 \begin_inset space ~
15618 \end_inset
15619
15620 of
15621 \begin_inset space ~
15622 \end_inset
15623
15624 Contents
15625 \family default
15626 ).
15627 \end_layout
15628
15629 \begin_layout Itemize
15630 The paragraphs in a 
15631 \emph on
15632 letter
15633 \emph default
15634  document class appear in a skip separation mode, not indented.
15635  This is the standard behavior, no special \SpecialChar LaTeX
15636  commands are needed for that.
15637  But in the 
15638 \family sans
15639 Document\SpecialChar menuseparator
15640 Settings
15641 \family default
15642  dialog the corresponding radio button indicates 
15643 \family sans
15644 Indent
15645 \family default
15646 .
15647  A 
15648 \family sans
15649 Skip
15650 \family default
15651  value always has the effect that extra \SpecialChar LaTeX
15652  commands are inserted in the document
15653  to produce the gap, which is not what is wanted in this case.
15654 \end_layout
15655
15656 \begin_layout Section
15657 Memoir
15658 \end_layout
15659
15660 \begin_layout Standard
15661 By 
15662 \noun on
15663 Jürgen Spitzmüller
15664 \end_layout
15665
15666 \begin_layout Subsection
15667 Overview
15668 \end_layout
15669
15670 \begin_layout Standard
15671 Memoir is a very powerful and constantly evolving class.
15672  It has been designed with regard to fictional and non-fictional literature.
15673  Its aim is to let the user have maximum control over the typesetting of
15674  his document.
15675  Memoir is based on the standard book class, but it can also emulate the
15676  article class (see below).
15677 \end_layout
15678
15679 \begin_layout Standard
15680 Peter Wilson, the developer of Memoir, is known as the author of lots of
15681  useful packages in the \SpecialChar LaTeX
15682  world.
15683  Most of them have been merged with Memoir.
15684  Therefore, it is much easier to layout the table of contents, appendices,
15685  chapter designs and such.
15686  \SpecialChar LyX
15687 , though, does not support all of these goodies natively.
15688  Some of them might be added to forthcoming releases
15689 \begin_inset Foot
15690 status collapsed
15691
15692 \begin_layout Plain Layout
15693 You are invited to send suggestions to 
15694 \begin_inset Flex URL
15695 status collapsed
15696
15697 \begin_layout Plain Layout
15698
15699 lyx-devel@lists.lyx.org
15700 \end_layout
15701
15702 \end_inset
15703
15704 .
15705 \end_layout
15706
15707 \end_inset
15708
15709 , lots will probably never be supported, due to the limitations of \SpecialChar LyX
15710 's framework.
15711  Of course you can still use all features with the help of some native \SpecialChar LaTeX
15712
15713  commands (\SpecialChar TeX
15714  code
15715 \begin_inset Foot
15716 status collapsed
15717
15718 \begin_layout Plain Layout
15719 Cf.
15720 \begin_inset ERT
15721 status collapsed
15722
15723 \begin_layout Plain Layout
15724
15725
15726 \backslash
15727  
15728 \end_layout
15729
15730 \end_inset
15731
15732 section
15733 \begin_inset space ~
15734 \end_inset
15735
15736
15737 \begin_inset CommandInset ref
15738 LatexCommand ref
15739 reference "sec:Inserting-TeX-Code"
15740
15741 \end_inset
15742
15743  for details.
15744 \end_layout
15745
15746 \end_inset
15747
15748 ).
15749  In this section, we can only list those features that are natively supported
15750  by \SpecialChar LyX
15751 .
15752  For detailed descriptions (and for the rest of features) we recommend you
15753  have a look at the detailed manual of the Memoir class
15754 \begin_inset Foot
15755 status collapsed
15756
15757 \begin_layout Plain Layout
15758 Cf.
15759 \begin_inset ERT
15760 status collapsed
15761
15762 \begin_layout Plain Layout
15763
15764
15765 \backslash
15766  
15767 \end_layout
15768
15769 \end_inset
15770
15771
15772 \begin_inset Flex URL
15773 status collapsed
15774
15775 \begin_layout Plain Layout
15776
15777 CTAN:/macros/latex/memoir/memman.pdf
15778 \end_layout
15779
15780 \end_inset
15781
15782 .
15783 \end_layout
15784
15785 \end_inset
15786
15787 , which is not only a user guide for the class, but also both a comprehensive
15788  description on good typesetting and a superb example for good typesetting
15789  itself.
15790 \end_layout
15791
15792 \begin_layout Subsection
15793 Basic features and restrictions
15794 \end_layout
15795
15796 \begin_layout Standard
15797 Memoir supports basically all features of the standard book classes.
15798  There are, however, some differences, as follows:
15799 \end_layout
15800
15801 \begin_layout Description
15802 Font
15803 \begin_inset space ~
15804 \end_inset
15805
15806 sizes: Memoir has a broader range of font sizes: 9, 10, 11, 12, 14, 17
15807 \end_layout
15808
15809 \begin_layout Description
15810 Page
15811 \begin_inset space ~
15812 \end_inset
15813
15814 style: The fancy page style is not supported, due to a command clash between
15815  Memoir and the fancyhdr package (they both define a command with the same
15816  name, which confuses \SpecialChar LaTeX
15817 ).
15818  Instead, Memoir comes with a number of its own page styles (see 
15819 \family sans
15820 Document\SpecialChar menuseparator
15821 Settings\SpecialChar menuseparator
15822 Page
15823 \begin_inset space ~
15824 \end_inset
15825
15826 Style
15827 \family default
15828 ).
15829  If you want to use these for the chapter pages, you have to use the command
15830  
15831 \family typewriter
15832
15833 \backslash
15834 chapterstyle
15835 \family default
15836  in the main text or in preamble (e.
15837 \begin_inset space \thinspace{}
15838 \end_inset
15839
15840 g.
15841 \begin_inset space \space{}
15842 \end_inset
15843
15844
15845 \family typewriter
15846
15847 \backslash
15848 chapterstyle{companion}
15849 \family default
15850 ).
15851 \end_layout
15852
15853 \begin_layout Description
15854 Sectioning: Sectionings (chapter, section, subsection etc.) come with an
15855  optional argument in the standard classes.
15856  With this, you can specify an alternative version of the title for the
15857  table of contents and the headers (for instance, if the title is too long).
15858  In \SpecialChar LyX
15859 , you can do this via 
15860 \family sans
15861 Insert\SpecialChar menuseparator
15862 Short
15863 \begin_inset space ~
15864 \end_inset
15865
15866 Title
15867 \family default
15868  at the beginning of a chapter/section.
15869  Memoir features a second optional argument and thus separates the table
15870  of contents from the header.
15871  You can define three variants of a title with this: one for the main text,
15872  one for the table of contents, and one for the headers.
15873  \SpecialChar LyX
15874  makes these available in form of specific 
15875 \family sans
15876 Short Title
15877 \family default
15878  variants in the 
15879 \family sans
15880 Insert
15881 \family default
15882  menu.
15883 \end_layout
15884
15885 \begin_layout Description
15886 TOC/LOT/LOF: In the standard classes (and in many other classes), the table
15887  of contents, the list of figures and the list of table start a new page
15888  automatically.
15889  Memoir does not follow this route.
15890  You have to insert a page break yourself, if you want to have one.
15891 \end_layout
15892
15893 \begin_layout Description
15894 Titlepage: For some unknown reason, Memoir uses pagination on the title
15895  page (in the standard classes, title pages are 
15896 \begin_inset Quotes eld
15897 \end_inset
15898
15899 empty
15900 \begin_inset Quotes erd
15901 \end_inset
15902
15903 ).
15904  If you want an empty title page, type 
15905 \family typewriter
15906
15907 \backslash
15908 aliaspagestyle{title}{empty}
15909 \family default
15910  in the preamble.
15911 \end_layout
15912
15913 \begin_layout Description
15914 Article: With the class option 
15915 \emph on
15916 article
15917 \emph default
15918  (to be inserted in 
15919 \family sans
15920 Document\SpecialChar menuseparator
15921 Settings\SpecialChar menuseparator
15922 Class Settings\SpecialChar menuseparator
15923 Custom
15924 \begin_inset space ~
15925 \end_inset
15926
15927 Options
15928 \family default
15929 ), you can emulate article style.
15930  That is, counters (footnotes, figures, tables etc.) will not be reset on
15931  new chapters, chapters don't start a new page (but are—in contrary to 
15932 \begin_inset Quotes eld
15933 \end_inset
15934
15935 real
15936 \begin_inset Quotes erd
15937 \end_inset
15938
15939  article classes—still allowed), parts, though, use their own page, as in
15940  book.
15941 \end_layout
15942
15943 \begin_layout Description
15944 Oldfontcommands: By default, Memoir does not allow the use of the deprecated
15945  font commands, which have been used in the old \SpecialChar LaTeX
15946  version 2.09 (e.
15947 \begin_inset space \thinspace{}
15948 \end_inset
15949
15950 g.
15951 \begin_inset space \space{}
15952 \end_inset
15953
15954
15955 \family typewriter
15956
15957 \backslash
15958 rm
15959 \family default
15960
15961 \family typewriter
15962
15963 \backslash
15964 it
15965 \family default
15966 ).
15967  It produces an error and stops \SpecialChar LaTeX
15968  whenever such a command appears.
15969  The class option 
15970 \emph on
15971 oldfontcommands
15972 \emph default
15973  reallows the commands and spits out warnings instead (which does at least
15974  not stop \SpecialChar LaTeX
15975 ).
15976  Since a lot of packages and particularly Bib\SpecialChar TeX
15977  style files are still using
15978  those commands, we have decided to use this option by default.
15979 \end_layout
15980
15981 \begin_layout Subsection
15982 Extra features
15983 \end_layout
15984
15985 \begin_layout Standard
15986 We will only describe the features supported by \SpecialChar LyX
15987  (which is not much currently).
15988  Please consult the Memoir manual
15989 \begin_inset Foot
15990 status collapsed
15991
15992 \begin_layout Plain Layout
15993 Cf.
15994 \begin_inset ERT
15995 status collapsed
15996
15997 \begin_layout Plain Layout
15998
15999
16000 \backslash
16001  
16002 \end_layout
16003
16004 \end_inset
16005
16006
16007 \begin_inset Flex URL
16008 status collapsed
16009
16010 \begin_layout Plain Layout
16011
16012 CTAN:/macros/latex/memoir/memman.pdf
16013 \end_layout
16014
16015 \end_inset
16016
16017 .
16018 \end_layout
16019
16020 \end_inset
16021
16022  for details.
16023 \end_layout
16024
16025 \begin_layout Description
16026 Abstract: You may wonder why an abstract is an extra feature.
16027  Well, it is in book class.
16028  Usually books don't have abstracts.
16029  Memoir, however, has.
16030  You can use it wherever and how often you like.
16031 \end_layout
16032
16033 \begin_layout Description
16034 Chapterprecis: You may know this older typesetting style: The contents of
16035  a chapter are summarized below the title and also in the table of contents
16036  (e.
16037 \begin_inset space \thinspace{}
16038 \end_inset
16039
16040 g.
16041 \begin_inset space \space{}
16042 \end_inset
16043
16044
16045 \emph on
16046 Our hero arrives in Troia; he loses some friends; he finds others
16047 \emph default
16048 ).
16049  Chapterprecis does exactly this.
16050  It is therefore only sensible below a chapter.
16051 \end_layout
16052
16053 \begin_layout Description
16054 Epigraph: An epigraph is a smart slogan or motto at the beginning of a chapter.
16055  The epigraph environment provides an elegant way of typesetting such a
16056  motto.
16057  The motto itself (text) and its (optional) author (source) are divided
16058  by a short line.
16059  The author (source) can be inserted via 
16060 \family sans
16061 Insert\SpecialChar menuseparator
16062 Epigraph Source
16063 \family default
16064 \emph on
16065 .
16066 \end_layout
16067
16068 \begin_layout Description
16069 Poemtitle: Memoir has lots of possibilities to typeset poetry (up to very
16070  complex figurative poems).
16071  \SpecialChar LyX
16072  can only support a few of them.
16073  One is poemtitle, which is a centered title for poems, which will also
16074  be added to the table of contents (verse is the standard environment for
16075  poems.
16076  Memoir has some enhanced versions of verse, but you need to use \SpecialChar TeX
16077  code,
16078  because they have to be nested inside regular verse environments, which
16079  is not possible with \SpecialChar LyX
16080 ).
16081 \end_layout
16082
16083 \begin_layout Description
16084 Poemtitle*: Same as poemtitle, but it adds no entry to the table of contents.
16085 \end_layout
16086
16087 \begin_layout Section
16088 Article (mwart), book (mwbk) and report (mwrep)
16089 \begin_inset Argument status
16090 status collapsed
16091
16092 \begin_layout Plain Layout
16093 The 
16094 \family typewriter
16095 mw
16096 \family default
16097  Classes
16098 \end_layout
16099
16100 \end_inset
16101
16102
16103 \end_layout
16104
16105 \begin_layout Standard
16106 by 
16107 \noun on
16108 Tomasz Luczak
16109 \end_layout
16110
16111 \begin_layout Standard
16112 The \SpecialChar LyX
16113  document classes 
16114 \emph on
16115 article (mwart)
16116 \emph default
16117
16118 \emph on
16119 report (mwrep)
16120 \emph default
16121  and 
16122 \emph on
16123 book
16124 \emph default
16125  
16126 \emph on
16127 (mwbk)
16128 \emph default
16129  correspond to the \SpecialChar LaTeX
16130  document classes 
16131 \family typewriter
16132 mwart.cls
16133 \family default
16134
16135 \family typewriter
16136 mwrep.cls
16137 \family default
16138  and 
16139 \family typewriter
16140 mwbk.cls
16141 \family default
16142 , resp.
16143  They are replacements for the standard document classes 
16144 \family typewriter
16145 article.cls
16146 \family default
16147
16148 \family typewriter
16149 report.cls
16150 \family default
16151  and 
16152 \family typewriter
16153 book.cls
16154 \family default
16155 , resp., and fit better to Polish typography conventions in a number of points.
16156  
16157 \end_layout
16158
16159 \begin_layout Standard
16160 Basic differences:
16161 \end_layout
16162
16163 \begin_layout Itemize
16164 Unnumbered titles (with star, e.
16165 \begin_inset space \thinspace{}
16166 \end_inset
16167
16168 g.
16169 \begin_inset space \space{}
16170 \end_inset
16171
16172
16173 \family sans
16174 Section*
16175 \family default
16176 ) are added into table of contents,
16177 \end_layout
16178
16179 \begin_layout Itemize
16180 Additional page styles:
16181 \end_layout
16182
16183 \begin_deeper
16184 \begin_layout Description
16185 uheadings header with separated lines,
16186 \end_layout
16187
16188 \begin_layout Description
16189 myheadings custom header, contents headers via commands: 
16190 \family typewriter
16191
16192 \backslash
16193 markright
16194 \family default
16195  and 
16196 \family typewriter
16197
16198 \backslash
16199 markboth
16200 \family default
16201 ,
16202 \end_layout
16203
16204 \begin_layout Description
16205 myuheadings custom header with separated lines,
16206 \end_layout
16207
16208 \begin_layout Description
16209 outer page number is placed on outer side of page
16210 \end_layout
16211
16212 \end_deeper
16213 \begin_layout Itemize
16214 Options 
16215 \end_layout
16216
16217 \begin_deeper
16218 \begin_layout Description
16219 rmheadings serif titles â€” default,
16220 \end_layout
16221
16222 \begin_layout Description
16223 sfheadings sansserif titles,
16224 \end_layout
16225
16226 \begin_layout Description
16227 authortitle on title page first placed is author next title â€” default,
16228 \end_layout
16229
16230 \begin_layout Description
16231 titleauthor on title page first placed is title next author,
16232 \end_layout
16233
16234 \begin_layout Description
16235 withmarginpar reserve place on page for margins.
16236 \end_layout
16237
16238 \end_deeper
16239 \begin_layout Section
16240 Paper
16241 \end_layout
16242
16243 \begin_layout Standard
16244 The document class 
16245 \family sans
16246 paper
16247 \family default
16248  provides an alternative to the standard 
16249 \family sans
16250 article
16251 \family default
16252  class.
16253  It provides similar functionality, but you might prefer this layout with
16254  sans serif sections, headings, and more.
16255 \end_layout
16256
16257 \begin_layout Section
16258 Rev\SpecialChar TeX
16259 4
16260 \end_layout
16261
16262 \begin_layout Standard
16263 by 
16264 \noun on
16265 Amir Karger
16266 \end_layout
16267
16268 \begin_layout Standard
16269 \begin_inset VSpace bigskip
16270 \end_inset
16271
16272
16273 \end_layout
16274
16275 \begin_layout Standard
16276 \noindent
16277 The 
16278 \family sans
16279 Revtex
16280 \begin_inset space ~
16281 \end_inset
16282
16283 4
16284 \family default
16285  textclass works with the American Physical Sociey's Rev\SpecialChar TeX
16286  4.0 (the 
16287 \begin_inset Formula $\beta$
16288 \end_inset
16289
16290  release of May, 1999) class.
16291 \end_layout
16292
16293 \begin_layout Standard
16294 \SpecialChar LyX
16295  has a 
16296 \family sans
16297 Revtex
16298 \family default
16299  textclass, which works with Rev\SpecialChar TeX
16300  3.1.
16301  However, v3.1 is basically obsolete, as it works with \SpecialChar LaTeX
16302  2.09.
16303  That means that it doesn't interact very well with \SpecialChar LyX
16304 , which requires \SpecialChar LaTeX2e
16305 , although
16306  it has been kludged to work.
16307  Since Rev\SpecialChar TeX
16308  4.0 has been designed to work much more cleanly with \SpecialChar LaTeX2e
16309 , \SpecialChar LyX
16310  with the
16311  
16312 \family sans
16313 Rev\SpecialChar TeX
16314
16315 \begin_inset space ~
16316 \end_inset
16317
16318 4
16319 \family default
16320  textclass should also be pretty easy to use.
16321 \end_layout
16322
16323 \begin_layout Standard
16324 These documents are supposed to be used in 
16325 \emph on
16326 addition
16327 \emph default
16328  to the Rev\SpecialChar TeX
16329  4.0 documents, so we don't describe any of the special Rev\SpecialChar TeX
16330  macros,
16331  and assume you'll know what to put in the preamble if necessary.
16332 \end_layout
16333
16334 \begin_layout Subsection
16335 Installation
16336 \end_layout
16337
16338 \begin_layout Standard
16339 All you need to do is install Rev\SpecialChar TeX
16340  4, as described in the package's README
16341  file.
16342  The package can be found at The Rev\SpecialChar TeX
16343  4 Web Site 
16344 \begin_inset Flex URL
16345 status collapsed
16346
16347 \begin_layout Plain Layout
16348
16349 http://publish.aps.org/revtex4/
16350 \end_layout
16351
16352 \end_inset
16353
16354 .
16355  Install it somewhere that \SpecialChar LaTeX
16356  can see it.
16357  Test it by trying to \SpecialChar LaTeX
16358  a short Rev\SpecialChar TeX
16359  4 document in some random directory (i.
16360 \begin_inset space \thinspace{}
16361 \end_inset
16362
16363 e.
16364 \begin_inset space \space{}
16365 \end_inset
16366
16367 not the directory where you installed the class file.) Then, if you reconfigure
16368  \SpecialChar LyX
16369 , it will find the class file and let you use the Rev\SpecialChar TeX
16370 4 textclass.
16371 \end_layout
16372
16373 \begin_layout Standard
16374 Probably the easiest way to get started is either to import a Rev\SpecialChar TeX
16375  4 document
16376  using 
16377 \family typewriter
16378 tex2lyx
16379 \family default
16380 , or to use the 
16381 \family sans
16382 Revtex
16383 \begin_inset space ~
16384 \end_inset
16385
16386 4
16387 \family default
16388  template, found in the templates directory.
16389 \end_layout
16390
16391 \begin_layout Subsection
16392 Preamble Matter
16393 \end_layout
16394
16395 \begin_layout Standard
16396 Optional arguments to 
16397 \family typewriter
16398
16399 \backslash
16400 documentclass
16401 \family default
16402 , like 
16403 \begin_inset Quotes eld
16404 \end_inset
16405
16406 preprint
16407 \begin_inset Quotes erd
16408 \end_inset
16409
16410  and 
16411 \begin_inset Quotes eld
16412 \end_inset
16413
16414 aps
16415 \begin_inset Quotes erd
16416 \end_inset
16417
16418 , go in the 
16419 \family sans
16420 Extra
16421 \begin_inset space ~
16422 \end_inset
16423
16424 Options
16425 \family default
16426  field in the 
16427 \family sans
16428 Document
16429 \begin_inset space ~
16430 \end_inset
16431
16432 Layout
16433 \family default
16434  dialog, as usual.
16435  Remember that in Rev\SpecialChar TeX
16436 , at least one optional argument is required! 
16437 \end_layout
16438
16439 \begin_layout Standard
16440 Other preamble matter, like 
16441 \family typewriter
16442
16443 \backslash
16444 draft
16445 \family default
16446  etc.
16447 \begin_inset space ~
16448 \end_inset
16449
16450 goes in the 
16451 \family sans
16452 \SpecialChar LaTeX
16453
16454 \begin_inset space ~
16455 \end_inset
16456
16457 Preamble
16458 \family default
16459  dialog, also as usual.
16460 \end_layout
16461
16462 \begin_layout Subsection
16463 Layouts
16464 \end_layout
16465
16466 \begin_layout Standard
16467 The layouts basically correspond to the commands in Rev\SpecialChar TeX
16468 4.0.
16469  For example, the Email layout corresponds to 
16470 \family typewriter
16471
16472 \backslash
16473 email{}
16474 \family default
16475 .
16476  Note that (at least as of Rev\SpecialChar TeX
16477  4.0 Beta), the 
16478 \family sans
16479 Address
16480 \family default
16481  and 
16482 \family sans
16483 Affiliation
16484 \family default
16485  layouts are exactly equivalent, so you shouldn't need to use both.
16486 \begin_inset Foot
16487 status collapsed
16488
16489 \begin_layout Plain Layout
16490 In case you're curious, both were included so that 
16491 \family typewriter
16492 tex2lyx
16493 \family default
16494  would be able to translate both 
16495 \family typewriter
16496
16497 \backslash
16498 address
16499 \family default
16500  and 
16501 \family typewriter
16502
16503 \backslash
16504 affiliation
16505 \family default
16506 .
16507 \end_layout
16508
16509 \end_inset
16510
16511
16512 \end_layout
16513
16514 \begin_layout Subsection
16515 Important Notes
16516 \end_layout
16517
16518 \begin_layout Standard
16519 There are a couple of important unique aspects of Rev\SpecialChar TeX
16520  4 which might cause
16521  bugs that will be even more confusing in \SpecialChar LyX
16522 .
16523 \end_layout
16524
16525 \begin_layout Standard
16526 In Rev\SpecialChar TeX
16527 , the 
16528 \family typewriter
16529
16530 \backslash
16531 thanks
16532 \family default
16533  command goes 
16534 \emph on
16535 outside
16536 \emph default
16537  the 
16538 \family typewriter
16539
16540 \backslash
16541 author
16542 \family default
16543  command.
16544  The \SpecialChar LyX
16545  equivalent is that there is a separate Thanks layout.
16546  Do 
16547 \emph on
16548 not
16549 \emph default
16550  write footnotes in the 
16551 \family sans
16552 Author
16553 \family default
16554  layout, or weird things may happen.
16555  See the Rev\SpecialChar TeX
16556  4 documentation for more details.
16557 \end_layout
16558
16559 \begin_layout Standard
16560 Also, the 
16561 \family sans
16562 Author
16563 \begin_inset space ~
16564 \end_inset
16565
16566 Email
16567 \family default
16568
16569 \family sans
16570 Author
16571 \begin_inset space ~
16572 \end_inset
16573
16574 URL
16575 \family default
16576 , and 
16577 \family sans
16578 Thanks
16579 \family default
16580  layouts must be placed 
16581 \emph on
16582 in between
16583 \emph default
16584  the 
16585 \family sans
16586 Author
16587 \family default
16588  layout and the corresponding 
16589 \family sans
16590 Address
16591 \family default
16592  (or equivalent 
16593 \family sans
16594 Affiliation
16595 \family default
16596 ) layout.
16597  If you put the 
16598 \family sans
16599 Thanks
16600 \family default
16601  after the 
16602 \family sans
16603 Address
16604 \family default
16605 , the \SpecialChar LaTeX
16606  won't compile.
16607 \end_layout
16608
16609 \begin_layout Section
16610 Springer Journals (
16611 \family sans
16612 svjour
16613 \family default
16614 )
16615 \end_layout
16616
16617 \begin_layout Standard
16618 by 
16619 \noun on
16620 Martin Vermeer
16621 \end_layout
16622
16623 \begin_layout Subsection
16624 Description
16625 \end_layout
16626
16627 \begin_layout Standard
16628 These are the layout files for some of the journal formats used by Springer
16629  Verlag and listed on 
16630 \begin_inset Flex URL
16631 status collapsed
16632
16633 \begin_layout Plain Layout
16634
16635 http://www.springer.de/author/tex/help-journals.html
16636 \end_layout
16637
16638 \end_inset
16639
16640 , where you should also go to fetch the class files (yes, these are \SpecialChar LaTeX2e
16641  now!).
16642  It is a modular system: the things common to all journals are implemented
16643  in 
16644 \family typewriter
16645 svjour.inc
16646 \family default
16647 , which journal-specific layout files (such as, e.
16648 \begin_inset space \thinspace{}
16649 \end_inset
16650
16651 g.
16652 \begin_inset space \space{}
16653 \end_inset
16654
16655
16656 \family typewriter
16657 svjog.layout
16658 \family default
16659  for Journal of Geodesy) can include.
16660 \end_layout
16661
16662 \begin_layout Standard
16663 This means that implementing support for any other Springer journal on this
16664  list is as simple as writing your own 
16665 \family typewriter
16666 sv
16667 \family default
16668 <myjournal>
16669 \family typewriter
16670 .layout
16671 \family default
16672  file following the outline given in 
16673 \family typewriter
16674 svjog.layout
16675 \family default
16676 .
16677  
16678 \end_layout
16679
16680 \begin_layout Standard
16681 It is reasonably well tested only for the Journal of Geodesy.
16682  
16683 \family typewriter
16684 svjour
16685 \family default
16686  and 
16687 \family typewriter
16688 svjog
16689 \family default
16690  come with the standard \SpecialChar LyX
16691  distribution.
16692  Install the relevant class file (downloaded from Springer) in a proper
16693  directory, reconfigure \SpecialChar LaTeX
16694  (in the te\SpecialChar TeX
16695  case by running 
16696 \family typewriter
16697 texhash
16698 \family default
16699 , as root if necessary â€” doesn't \SpecialChar LyX
16700  take care of this?), reconfigure \SpecialChar LyX
16701  and
16702  it should work.
16703 \end_layout
16704
16705 \begin_layout Subsection
16706 New styles
16707 \end_layout
16708
16709 \begin_layout Standard
16710 A large number of theorem-like styles â€” 
16711 \family sans
16712 Claim, Conjecture,
16713 \family default
16714  
16715 \family sans
16716 \SpecialChar ldots
16717 Theorem
16718 \family default
16719 .
16720 \end_layout
16721
16722 \begin_layout Standard
16723
16724 \family sans
16725 Headnote, Dedication, Subtitle, Running_\SpecialChar LaTeX
16726 _Title, Author_Running, Institute,
16727  Mail, Offprints, Keywords, Acknowledgements, Acknowledgement
16728 \family default
16729 .
16730  See the Springer class file documentation for details.
16731 \end_layout
16732
16733 \begin_layout Subsection
16734 Supported journals
16735 \end_layout
16736
16737 \begin_layout Itemize
16738
16739 \emph on
16740 Journal of Geodesy
16741 \emph default
16742
16743 \family typewriter
16744 svjog.layout
16745 \family default
16746  â€” Martin Vermeer
16747 \end_layout
16748
16749 \begin_layout Itemize
16750
16751 \emph on
16752 Probability Theory and Related Fields
16753 \emph default
16754
16755 \family typewriter
16756 svprobth.layout
16757 \family default
16758  â€” Jean-Marc Lasgouttes
16759 \end_layout
16760
16761 \begin_layout Standard
16762 Add your own, it isn't so hard!
16763 \end_layout
16764
16765 \begin_layout Subsection
16766 Credits
16767 \end_layout
16768
16769 \begin_layout Standard
16770 These files are partly based on the older 
16771 \family typewriter
16772 ejour2.layout
16773 \family default
16774 , which was again based on a tinkered-with version of an old \SpecialChar LaTeX
16775  2.09 style
16776  file from Springer.
16777  All this, and the 
16778 \family typewriter
16779 ejour2
16780 \family default
16781  layout, are now defunct.
16782  Jean-Marc Lasgouttes helped out big in making me find my way around the
16783  \SpecialChar LyX
16784  layout file mechanism.
16785 \end_layout
16786
16787 \begin_layout Subsection
16788 Bugs
16789 \end_layout
16790
16791 \begin_layout Standard
16792 Probably.
16793  But probably less than in the old hacked-\SpecialChar LaTeX
16794  
16795 \family typewriter
16796 ejour2
16797 \family default
16798 .
16799 \end_layout
16800
16801 \begin_layout Section
16802 Slides [aka 
16803 \noun on
16804 Sli\SpecialChar TeX
16805
16806 \noun default
16807 ]
16808 \begin_inset CommandInset label
16809 LatexCommand label
16810 name "sec:slitex"
16811
16812 \end_inset
16813
16814
16815 \end_layout
16816
16817 \begin_layout Standard
16818 by 
16819 \noun on
16820 John Weiss
16821 \noun default
16822  
16823 \end_layout
16824
16825 \begin_layout Subsection
16826 Introduction
16827 \end_layout
16828
16829 \begin_layout Standard
16830 This section describes how to use \SpecialChar LyX
16831  to make slides for overhead projectors.
16832  There are two document classes that can do this: the default slides class
16833  and the 
16834 \family sans
16835 Foil\SpecialChar TeX
16836
16837 \family default
16838  slides class.
16839  This section documents the former.
16840 \end_layout
16841
16842 \begin_layout Standard
16843 I'm going to say this again, nice and clear, so that there's no misunderstanding
16844 :
16845 \end_layout
16846
16847 \begin_layout Standard
16848 \begin_inset VSpace bigskip
16849 \end_inset
16850
16851
16852 \end_layout
16853
16854 \begin_layout Standard
16855 \align center
16856
16857 \size large
16858 This section documents the class 
16859 \begin_inset Quotes eld
16860 \end_inset
16861
16862
16863 \family sans
16864 slides (default)
16865 \family default
16866
16867 \begin_inset Quotes erd
16868 \end_inset
16869
16870  
16871 \emph on
16872 only.
16873 \end_layout
16874
16875 \begin_layout Standard
16876 \begin_inset VSpace bigskip
16877 \end_inset
16878
16879
16880 \end_layout
16881
16882 \begin_layout Standard
16883 If you're looking for the documentation for 
16884 \begin_inset Quotes eld
16885 \end_inset
16886
16887
16888 \family sans
16889 slides (Foil\SpecialChar TeX
16890 )
16891 \family default
16892
16893 \begin_inset Quotes erd
16894 \end_inset
16895
16896 , check out section
16897 \begin_inset space ~
16898 \end_inset
16899
16900
16901 \begin_inset CommandInset ref
16902 LatexCommand ref
16903 reference "sec:foiltex"
16904
16905 \end_inset
16906
16907 .
16908  The 
16909 \family sans
16910 foils
16911 \family default
16912  class [
16913 \begin_inset Quotes eld
16914 \end_inset
16915
16916
16917 \family sans
16918 slides (Foil\SpecialChar TeX
16919 )
16920 \family default
16921
16922 \begin_inset Quotes erd
16923 \end_inset
16924
16925 ] is actually somewhat better than the default 
16926 \family sans
16927 slides
16928 \family default
16929  class,
16930 \begin_inset Foot
16931 status collapsed
16932
16933 \begin_layout Plain Layout
16934 \SpecialChar ldots
16935 or so I've been told repeatedly by its advocates.
16936  Having never used it, I have no idea if this claim is true or not.
16937 \end_layout
16938
16939 \end_inset
16940
16941  which this section documents.
16942 \end_layout
16943
16944 \begin_layout Standard
16945 This class is the \SpecialChar LaTeX2e
16946  improvement of the old 
16947 \noun on
16948 Sli\SpecialChar TeX
16949
16950 \noun default
16951  package.
16952  Every \SpecialChar LaTeX2e
16953  distribution includes this class [which I'll just refer to as 
16954 \begin_inset Quotes eld
16955 \end_inset
16956
16957
16958 \family sans
16959 slides
16960 \family default
16961
16962 \begin_inset Quotes erd
16963 \end_inset
16964
16965  from now on], so you're bound to have it.
16966  As I noted earlier, there are other classes, such as 
16967 \family sans
16968 foils
16969 \family default
16970 , which also produce slides for overhead projectors and do a better job
16971  at it.
16972  However, there are some things which 
16973 \family sans
16974 slides
16975 \family default
16976  can do which the others can't, such as generate overlays.
16977  Read on to learn more!
16978 \end_layout
16979
16980 \begin_layout Subsection
16981 Getting Started
16982 \begin_inset CommandInset label
16983 LatexCommand label
16984 name "sec:slidesetup"
16985
16986 \end_inset
16987
16988
16989 \end_layout
16990
16991 \begin_layout Standard
16992 Obviously, to use this document class, you need to select 
16993 \begin_inset Quotes eld
16994 \end_inset
16995
16996
16997 \family sans
16998 slides (default)
16999 \family default
17000
17001 \begin_inset Quotes erd
17002 \end_inset
17003
17004  from the class list in the 
17005 \family sans
17006 Document\SpecialChar menuseparator
17007 Settings
17008 \family default
17009  dialog.
17010  There are some other special things you should know about this class:
17011 \end_layout
17012
17013 \begin_layout Itemize
17014 Don't bother changing the options 
17015 \family sans
17016 Sides and Columns
17017 \family default
17018 .
17019  They're not supported by the 
17020 \family sans
17021 slides
17022 \family default
17023  class, anyways.
17024 \end_layout
17025
17026 \begin_layout Itemize
17027 The option 
17028 \family sans
17029 Page
17030 \begin_inset space ~
17031 \end_inset
17032
17033 style
17034 \family default
17035  behaves a bit differently for this class.
17036  The possible choices and what they do are as follows:
17037 \end_layout
17038
17039 \begin_deeper
17040 \begin_layout Description
17041
17042 \family sans
17043 plain
17044 \family default
17045  The final output contains page numbers in the lower right corner.
17046 \end_layout
17047
17048 \begin_layout Description
17049
17050 \family sans
17051 headings
17052 \family default
17053  Like 
17054 \family sans
17055 plain
17056 \family default
17057 , but also prints out any time markers you've put in.
17058  This is the default.
17059 \end_layout
17060
17061 \begin_layout Description
17062
17063 \family sans
17064 empty
17065 \family default
17066  The final output contains no page numbers, time markers, or alignment markers.
17067 \end_layout
17068
17069 \end_deeper
17070 \begin_layout Itemize
17071 The 
17072 \family sans
17073 slides
17074 \family default
17075  class has an extra option: 
17076 \family typewriter
17077 clock
17078 \family default
17079 .
17080  To use it, put 
17081 \begin_inset Quotes eld
17082 \end_inset
17083
17084
17085 \family typewriter
17086 clock
17087 \family default
17088
17089 \begin_inset Quotes erd
17090 \end_inset
17091
17092  in the extra class options.
17093 \end_layout
17094
17095 \begin_deeper
17096 \begin_layout Standard
17097 Using this options allows you to add time markers to 
17098 \family sans
17099 Note
17100 \family default
17101 s.
17102  See section
17103 \begin_inset space ~
17104 \end_inset
17105
17106
17107 \begin_inset CommandInset ref
17108 LatexCommand ref
17109 reference "sec:slideNote"
17110
17111 \end_inset
17112
17113  for more details.
17114 \end_layout
17115
17116 \end_deeper
17117 \begin_layout Standard
17118 You can also use the template file 
17119 \begin_inset Quotes eld
17120 \end_inset
17121
17122
17123 \family typewriter
17124 slides.lyx
17125 \family default
17126
17127 \begin_inset Quotes erd
17128 \end_inset
17129
17130  to automatically set up a document to use the 
17131 \family sans
17132 slides
17133 \family default
17134  class [using 
17135 \family sans
17136 File\SpecialChar menuseparator
17137 New
17138 \begin_inset space ~
17139 \end_inset
17140
17141 from
17142 \begin_inset space ~
17143 \end_inset
17144
17145 Template
17146 \family default
17147  to open your new document].
17148  The template file also contains some examples of the special paragraph
17149  environments used by this class.
17150  I'll describe those next.
17151 \end_layout
17152
17153 \begin_layout Subsection
17154 Paragraph Environments
17155 \end_layout
17156
17157 \begin_layout Subsubsection
17158 Supported Environments
17159 \end_layout
17160
17161 \begin_layout Standard
17162 The first thing you'll notice when you start up a new 
17163 \family sans
17164 slides
17165 \family default
17166  document is the font size and type: it's the equivalent of the size 
17167 \begin_inset Quotes eld
17168 \end_inset
17169
17170
17171 \family sans
17172 Largest
17173 \family default
17174
17175 \begin_inset Quotes erd
17176 \end_inset
17177
17178  in the 
17179 \family sans
17180 Sans
17181 \begin_inset space ~
17182 \end_inset
17183
17184 Serif
17185 \family default
17186  font.
17187  This is also what's used in the output.
17188  Think of this as a 
17189 \begin_inset Quotes eld
17190 \end_inset
17191
17192 visual cue
17193 \begin_inset Quotes erd
17194 \end_inset
17195
17196  to remind you that this is a slide.
17197  Your final slides will use a larger font; ergo, you'll have less space.
17198  Of course, the larger default screen font isn't WYSIWYG, only a reminder.
17199 \end_layout
17200
17201 \begin_layout Standard
17202 The next thing that becomes obvious is the changes to the paragraph environment
17203  pull-down box [at the far-left end of the toolbar].
17204  Most of the paragraph environments you're used to seeing are missing.
17205  There are also five new ones.
17206  That's because the 
17207 \family sans
17208 slides
17209 \family default
17210  class itself only supports certain paragraph environments:
17211 \end_layout
17212
17213 \begin_layout Itemize
17214
17215 \family sans
17216 Standard
17217 \end_layout
17218
17219 \begin_layout Itemize
17220
17221 \family sans
17222 Itemize
17223 \end_layout
17224
17225 \begin_layout Itemize
17226
17227 \family sans
17228 Enumerate
17229 \end_layout
17230
17231 \begin_layout Itemize
17232
17233 \family sans
17234 Description
17235 \end_layout
17236
17237 \begin_layout Itemize
17238
17239 \family sans
17240 List
17241 \end_layout
17242
17243 \begin_layout Itemize
17244
17245 \family sans
17246 Quotation
17247 \end_layout
17248
17249 \begin_layout Itemize
17250
17251 \family sans
17252 Quote
17253 \end_layout
17254
17255 \begin_layout Itemize
17256
17257 \family sans
17258 Verse
17259 \end_layout
17260
17261 \begin_layout Itemize
17262
17263 \family sans
17264 Caption
17265 \end_layout
17266
17267 \begin_layout Itemize
17268
17269 \family sans
17270 \SpecialChar LyX
17271 -Code
17272 \end_layout
17273
17274 \begin_layout Standard
17275 All of the other standard environments, including the section-heading environmen
17276 ts, aren't used in the 
17277 \family sans
17278 slides
17279 \family default
17280  class.
17281 \end_layout
17282
17283 \begin_layout Standard
17284 On the other hand, you'll notice the following new environments:
17285 \end_layout
17286
17287 \begin_layout Itemize
17288
17289 \family sans
17290 Slide
17291 \end_layout
17292
17293 \begin_layout Itemize
17294
17295 \family sans
17296 Overlay
17297 \end_layout
17298
17299 \begin_layout Itemize
17300
17301 \family sans
17302 Note
17303 \end_layout
17304
17305 \begin_layout Itemize
17306
17307 \family sans
17308 InvisibleText
17309 \end_layout
17310
17311 \begin_layout Itemize
17312
17313 \family sans
17314 VisibleText
17315 \end_layout
17316
17317 \begin_layout Standard
17318 These five are kind of quirky, due to a 
17319 \begin_inset Quotes eld
17320 \end_inset
17321
17322 feature
17323 \begin_inset Quotes erd
17324 \end_inset
17325
17326  in \SpecialChar LyX
17327 .
17328  You see, \SpecialChar LyX
17329  doesn't permit you to nest any other paragraph environment into
17330  an empty environment.
17331  Now, that's fine and dandy, but it means that you wouldn't be able to start
17332  a slide with anything except plain text.
17333  To deal with this, I've performed a little 
17334 \begin_inset Quotes eld
17335 \end_inset
17336
17337 \SpecialChar LaTeX
17338  magic.
17339 \begin_inset Quotes erd
17340 \end_inset
17341
17342  
17343 \end_layout
17344
17345 \begin_layout Subsubsection
17346 Quirks of the New Environments
17347 \begin_inset CommandInset label
17348 LatexCommand label
17349 name "sec:slideQuirk"
17350
17351 \end_inset
17352
17353
17354 \end_layout
17355
17356 \begin_layout Standard
17357 All five of the new paragraph environments are somewhat quirky due to inherent
17358  limitiations in the current version of \SpecialChar LyX
17359 .
17360  As I just mentioned, \SpecialChar LyX
17361  forbids environments that begin with another environment.
17362  To get around this, the 
17363 \family sans
17364 Slide
17365 \family default
17366  environment isn't a paragraph environment as described in the 
17367 \emph on
17368 User's Guide
17369 \emph default
17370 .
17371  
17372 \end_layout
17373
17374 \begin_layout Standard
17375 You should consider 
17376 \family sans
17377 Slide
17378 \family default
17379
17380 \family sans
17381 Overlay
17382 \family default
17383 , and 
17384 \family sans
17385 Note
17386 \family default
17387  to be 
17388 \begin_inset Quotes eld
17389 \end_inset
17390
17391 pseudo-environments.
17392 \begin_inset Quotes erd
17393 \end_inset
17394
17395  They look like a section heading or a 
17396 \begin_inset Quotes eld
17397 \end_inset
17398
17399
17400 \family sans
17401 Caption
17402 \family default
17403 ,
17404 \begin_inset Quotes erd
17405 \end_inset
17406
17407  but really begin a [and, if necessary, end the previous] paragraph environment.
17408  Likewise, treat 
17409 \family sans
17410 InvisibleText
17411 \family default
17412  and 
17413 \family sans
17414 VisibleText
17415 \family default
17416  as 
17417 \begin_inset Quotes eld
17418 \end_inset
17419
17420 pseudo-commands.
17421 \begin_inset Quotes erd
17422 \end_inset
17423
17424  These two perform some action.
17425 \end_layout
17426
17427 \begin_layout Standard
17428 A common feature of all five environments, 
17429 \family sans
17430 Slide
17431 \family default
17432
17433 \family sans
17434 Overlay
17435 \family default
17436
17437 \family sans
17438 Note
17439 \family default
17440
17441 \family sans
17442 InvisibleText
17443 \family default
17444  and 
17445 \family sans
17446 VisibleText
17447 \family default
17448 , is a rather long-ish label.
17449  The text following this label â€” ordinarily the contents of the paragraph
17450  environment â€” is utterly irrelevant for 
17451 \family sans
17452 Slide
17453 \family default
17454
17455 \family sans
17456 Overlay
17457 \family default
17458
17459 \family sans
17460 Note
17461 \family default
17462
17463 \family sans
17464 InvisibleText
17465 \family default
17466  and 
17467 \family sans
17468 VisibleText
17469 \family default
17470 .
17471  \SpecialChar LyX
17472  completely ignores it.
17473  In fact, you can leave these five environments completely empty.
17474  
17475 \end_layout
17476
17477 \begin_layout Standard
17478 While you don't 
17479 \emph on
17480 have
17481 \emph default
17482  to put any text after the rather long-ish label, you might want to.
17483  This could be a short description of the contents of the 
17484 \family sans
17485 Slide
17486 \family default
17487 , for example.
17488  In that case, enter your descriptive comment and hit 
17489 \family sans
17490 Return
17491 \family default
17492  as you normally would.
17493 \end_layout
17494
17495 \begin_layout Standard
17496 If, on the other hand, you don't want to enter any descriptive text, you'll
17497  hit another \SpecialChar LyX
17498  quirk.
17499  \SpecialChar LyX
17500 , like nature, abhors a vacuum, and will not let you start a new paragraph
17501  environment until you put something in the old one.
17502  So, do this:
17503 \end_layout
17504
17505 \begin_layout Itemize
17506 Start entering the text that will 
17507 \emph on
17508 follow
17509 \emph default
17510  the new 
17511 \family sans
17512 Slide
17513 \family default
17514
17515 \family sans
17516 Overlay
17517 \family default
17518
17519 \family sans
17520 Note
17521 \family default
17522
17523 \family sans
17524 InvisibleText
17525 \family default
17526  or 
17527 \family sans
17528 VisibleText
17529 \family default
17530 .
17531  
17532 \end_layout
17533
17534 \begin_layout Itemize
17535 Now move to the beginning of that paragraph.
17536  
17537 \end_layout
17538
17539 \begin_layout Itemize
17540 Next, hit 
17541 \family sans
17542 Return
17543 \family default
17544 .
17545  
17546 \end_layout
17547
17548 \begin_layout Itemize
17549 Finally, change this new, empty paragraph to a 
17550 \family sans
17551 Slide
17552 \family default
17553
17554 \family sans
17555 Overlay
17556 \family default
17557
17558 \family sans
17559 Note
17560 \family default
17561
17562 \family sans
17563 InvisibleText
17564 \family default
17565  or 
17566 \family sans
17567 VisibleText
17568 \family default
17569 .
17570  
17571 \end_layout
17572
17573 \begin_layout Standard
17574 Some future version of \SpecialChar LyX
17575  will, hopefully, resolve this quirkiness\SpecialChar ldots
17576
17577 \end_layout
17578
17579 \begin_layout Subsection
17580 Making a Presentation with 
17581 \family sans
17582 Slide
17583 \family default
17584
17585 \family sans
17586 Overlay
17587 \family default
17588  and 
17589 \family sans
17590 Note
17591 \end_layout
17592
17593 \begin_layout Subsubsection
17594 Using the 
17595 \family sans
17596 Slide
17597 \family default
17598  Environment
17599 \end_layout
17600
17601 \begin_layout Standard
17602 If you're expecting this section to teach you how to actually make a presentatio
17603 n, you'll be sorely disappointed.
17604  Naturally, I'll describe all of the ways the 
17605 \family sans
17606 slides
17607 \family default
17608  class can assist you in preparing the materials for a presentation.
17609  Filling in the contents, however, is up to you.
17610  [Then again, that 
17611 \emph on
17612 is
17613 \emph default
17614  the \SpecialChar LyX
17615  philosophy.]
17616 \end_layout
17617
17618 \begin_layout Standard
17619 Choosing the 
17620 \family sans
17621 Slide
17622 \family default
17623  environment [in the manner described in section
17624 \begin_inset space ~
17625 \end_inset
17626
17627
17628 \begin_inset CommandInset ref
17629 LatexCommand ref
17630 reference "sec:slideQuirk"
17631
17632 \end_inset
17633
17634 ] tells \SpecialChar LyX
17635  to begin a new slide [duh].
17636  The label for this environment/
17637 \begin_inset Quotes erd
17638 \end_inset
17639
17640 pseudo-command
17641 \begin_inset Quotes erd
17642 \end_inset
17643
17644  is an 
17645 \begin_inset Quotes eld
17646 \end_inset
17647
17648 ASCII line,
17649 \begin_inset Quotes erd
17650 \end_inset
17651
17652  in cool blue, followed by the label, 
17653 \begin_inset Quotes eld
17654 \end_inset
17655
17656 NewSlide:
17657 \begin_inset Quotes erd
17658 \end_inset
17659
17660 .
17661  Any text or paragraph environments that follow this one go on the new slide.
17662  It's that simple.
17663 \end_layout
17664
17665 \begin_layout Standard
17666 Slides are probably the only time you'll need to forcibly end pages in \SpecialChar LyX
17667
17668  (this can be specified in the 
17669 \family sans
17670 Paragraph Layout
17671 \family default
17672  dialog).
17673  In fact, you'll want to, once you finish entering the contents of one slide.
17674  If you've entered more text than can physically fit on a slide, the extra
17675  overflows onto a new slide.
17676  I don't recommend doing this, however, since the overflow slide won't have
17677  any page number on it.
17678  Furthermore, it may interfere with any 
17679 \family sans
17680 Overlay
17681 \family default
17682  you've made to accompany the oversized 
17683 \family sans
17684 Slide
17685 \family default
17686 .
17687 \end_layout
17688
17689 \begin_layout Standard
17690 The 
17691 \family sans
17692 Overlay
17693 \family default
17694  and 
17695 \family sans
17696 Note
17697 \family default
17698  environments work the same way as the 
17699 \family sans
17700 Slide
17701 \family default
17702  environment.
17703  They both create an 
17704 \begin_inset Quotes eld
17705 \end_inset
17706
17707 ASCII line
17708 \begin_inset Quotes erd
17709 \end_inset
17710
17711  followed by a label [
17712 \begin_inset Quotes eld
17713 \end_inset
17714
17715 NewOverlay:
17716 \begin_inset Quotes erd
17717 \end_inset
17718
17719  and 
17720 \begin_inset Quotes eld
17721 \end_inset
17722
17723 NewNote:
17724 \begin_inset Quotes erd
17725 \end_inset
17726
17727 , respectively].
17728  The color is a stunning magenta instead of blue, and the 
17729 \begin_inset Quotes eld
17730 \end_inset
17731
17732 ASCII line
17733 \begin_inset Quotes erd
17734 \end_inset
17735
17736  will look different, in style and in length.
17737  The label fonts of all three also differ from one another.
17738 \end_layout
17739
17740 \begin_layout Standard
17741 As with a 
17742 \family sans
17743 Slide
17744 \family default
17745 , if the contents of a 
17746 \family sans
17747 Note
17748 \family default
17749  or 
17750 \family sans
17751 Overlay
17752 \family default
17753  exceed the physical size of a slide or sheet of paper, the extra will overflow
17754  onto a new sheet.
17755  Again, you should avoid this.
17756  It defeats the whole purpose of 
17757 \family sans
17758 Note
17759 \family default
17760 s and 
17761 \family sans
17762 Overlay
17763 \family default
17764 s.
17765 \end_layout
17766
17767 \begin_layout Subsubsection
17768 Using 
17769 \family sans
17770 Overlay
17771 \family default
17772  with 
17773 \family sans
17774 Slide
17775 \end_layout
17776
17777 \begin_layout Standard
17778 The idea behind an 
17779 \family sans
17780 Overlay
17781 \family default
17782  is a slide that sits atop another slide.
17783  Perhaps you wish to discuss a figure on the main 
17784 \family sans
17785 Slide
17786 \family default
17787  before displaying the text associated with it.
17788  One way to accomplish this is tape a flap of dark paper over the part of
17789  the 
17790 \family sans
17791 Slide
17792 \family default
17793  you want to display later.
17794  This method fails, however, if you wish to overlap one graph with another,
17795  for example.
17796  You would then have to fumble while speaking to align the two separate,
17797  overlapping 
17798 \family sans
17799 Slide
17800 \family default
17801 s to align the two graphs.
17802  The use of an 
17803 \family sans
17804 Overlay
17805 \family default
17806  environment in both cases makes life much easier.
17807 \end_layout
17808
17809 \begin_layout Standard
17810 Each 
17811 \family sans
17812 Overlay
17813 \family default
17814  receives the page number of its 
17815 \begin_inset Quotes eld
17816 \end_inset
17817
17818 parent
17819 \begin_inset Quotes erd
17820 \end_inset
17821
17822  
17823 \family sans
17824 Slide
17825 \family default
17826 , appended by 
17827 \begin_inset Quotes eld
17828 \end_inset
17829
17830
17831 \family typewriter
17832 -a
17833 \family default
17834
17835 \begin_inset Quotes erd
17836 \end_inset
17837
17838 .
17839 \begin_inset Foot
17840 status collapsed
17841
17842 \begin_layout Plain Layout
17843 Presumably, mutliple 
17844 \family sans
17845 Overlay
17846 \family default
17847 s would have 
17848 \begin_inset Quotes eld
17849 \end_inset
17850
17851
17852 \family typewriter
17853 -a
17854 \family default
17855
17856 \begin_inset Quotes erd
17857 \end_inset
17858
17859
17860 \begin_inset Quotes eld
17861 \end_inset
17862
17863
17864 \family typewriter
17865 -b
17866 \family default
17867
17868 \begin_inset Quotes erd
17869 \end_inset
17870
17871
17872 \begin_inset Quotes eld
17873 \end_inset
17874
17875
17876 \family typewriter
17877 -c
17878 \family default
17879
17880 \begin_inset Quotes erd
17881 \end_inset
17882
17883 , etc.
17884 \begin_inset space ~
17885 \end_inset
17886
17887 appended to the page number of the parent 
17888 \family sans
17889 Slide
17890 \family default
17891 .
17892  
17893 \end_layout
17894
17895 \end_inset
17896
17897  Clearly, you want the contents of both the 
17898 \family sans
17899 Slide
17900 \family default
17901  and the 
17902 \family sans
17903 Overlay
17904 \family default
17905  to each fit on a single physical slide! You should probably consider an
17906  
17907 \family sans
17908 Overlay
17909 \family default
17910  as 
17911 \begin_inset Quotes eld
17912 \end_inset
17913
17914 part of
17915 \begin_inset Quotes erd
17916 \end_inset
17917
17918  a 
17919 \family sans
17920 Slide
17921 \family default
17922 .
17923  Indeed, the \SpecialChar LyX
17924  
17925 \family sans
17926 slides
17927 \family default
17928  class provides a visual cue for this: the label at the start of an 
17929 \family sans
17930 Overlay
17931 \family default
17932  is shorter than that at the start of a 
17933 \family sans
17934 Slide
17935 \family default
17936 .
17937  Lastly, when you generate printable output, you'll find alignment markers
17938  in all four corners of both the 
17939 \family sans
17940 Overlay
17941 \family default
17942  page and its parent 
17943 \family sans
17944 Slide
17945 \family default
17946 .
17947  These will assist you in lining up the two physical slides.
17948 \end_layout
17949
17950 \begin_layout Standard
17951 The major problem in overlaying two slides is aligning the contents of the
17952  two transparencies.
17953  How much space should you leave for that graph on the second slide? Worse
17954  still, what if you want a graph and a sentence on second slide, but there
17955  is text on the main transparency that goes in between them? You could try
17956  and insert vertical space of the right size.
17957  The better way is to use 
17958 \family sans
17959 InvisibleText
17960 \family default
17961  and 
17962 \family sans
17963 VisibleText
17964 \family default
17965 .
17966 \end_layout
17967
17968 \begin_layout Standard
17969 As their names imply, 
17970 \family sans
17971 InvisibleText
17972 \family default
17973  and 
17974 \family sans
17975 VisibleText
17976 \family default
17977  are two command-like paragraph environments that make all subsequent text
17978  invisible and visible, respectively.
17979  Note from section
17980 \begin_inset space ~
17981 \end_inset
17982
17983
17984 \begin_inset CommandInset ref
17985 LatexCommand ref
17986 reference "sec:slideQuirk"
17987
17988 \end_inset
17989
17990  that you don't place anything 
17991 \emph on
17992 into
17993 \emph default
17994  these two environments, however.
17995  When you create an 
17996 \family sans
17997 InvisibleText
17998 \family default
17999 , it inserts a centered, sky-blue label into the page reading 
18000 \begin_inset Quotes eld
18001 \end_inset
18002
18003 <Invisible Text Follows>
18004 \begin_inset Quotes erd
18005 \end_inset
18006
18007 .
18008  For paragraphs following this label, the parts of the 
18009 \family sans
18010 Slide
18011 \family default
18012  [or 
18013 \family sans
18014 Overlay
18015 \family default
18016 ; it doesn't matter which] where they would be contain instead blank space.
18017  
18018 \end_layout
18019
18020 \begin_layout Standard
18021 For 
18022 \family sans
18023 VisibleText
18024 \family default
18025 , the corresponding centered label is 
18026 \begin_inset Quotes eld
18027 \end_inset
18028
18029 <Visible Text Follows>
18030 \begin_inset Quotes erd
18031 \end_inset
18032
18033  in blazing green.
18034  Paragraphs following this label behave normally.
18035  Note that the beginning of a new 
18036 \family sans
18037 Slide
18038 \family default
18039
18040 \family sans
18041 Overlay
18042 \family default
18043 , or 
18044 \family sans
18045 Note
18046 \family default
18047  automatically shuts off an 
18048 \family sans
18049 InvisibleText
18050 \family default
18051 .
18052  It's therefore not necessary to use 
18053 \family sans
18054 VisibleText
18055 \family default
18056  at the end of a 
18057 \family sans
18058 Slide
18059 \family default
18060 .
18061 \end_layout
18062
18063 \begin_layout Standard
18064 By now, it should be obvious how to create overlay transparencies using
18065  the proper combination of 
18066 \family sans
18067 InvisibleText
18068 \family default
18069  and 
18070 \family sans
18071 VisibleText
18072 \family default
18073  on a 
18074 \family sans
18075 Slide
18076 \family default
18077  and 
18078 \family sans
18079 Overlay
18080 \family default
18081 :
18082 \end_layout
18083
18084 \begin_layout Enumerate
18085 Create a 
18086 \family sans
18087 Slide
18088 \family default
18089 , including everything that will appear on it, whether on the main slide
18090  or on the 
18091 \family sans
18092 Overlay
18093 \family default
18094 .
18095 \end_layout
18096
18097 \begin_layout Enumerate
18098 Before each figure or paragraph that will appear only on the 
18099 \family sans
18100 Overlay
18101 \family default
18102 , insert an 
18103 \family sans
18104 InvisibleText
18105 \family default
18106  environment.
18107  If necessary, insert a 
18108 \family sans
18109 VisibleText
18110 \family default
18111  environment after the 
18112 \family sans
18113 Overlay
18114 \family default
18115 -only text.
18116 \end_layout
18117
18118 \begin_layout Enumerate
18119 Start an 
18120 \family sans
18121 Overlay
18122 \family default
18123  immediately following the 
18124 \family sans
18125 Slide
18126 \family default
18127 .
18128 \end_layout
18129
18130 \begin_layout Enumerate
18131 Copy the contents of this 
18132 \family sans
18133 Slide
18134 \family default
18135  into the 
18136 \family sans
18137 Overlay
18138 \family default
18139 .
18140 \end_layout
18141
18142 \begin_layout Enumerate
18143 Within the 
18144 \family sans
18145 Overlay
18146 \family default
18147 , change all of the 
18148 \family sans
18149 InvisibleText
18150 \family default
18151  lines to 
18152 \family sans
18153 VisibleText
18154 \family default
18155  and vice-versa.
18156 \end_layout
18157
18158 \begin_layout Standard
18159 That's it.
18160  You've just made an 
18161 \family sans
18162 Overlay
18163 \family default
18164 .
18165 \end_layout
18166
18167 \begin_layout Standard
18168 There's one problem with the way I've designed the \SpecialChar LyX
18169  
18170 \family sans
18171 slides
18172 \family default
18173  class: you can't make text in the middle of a paragraph invisible, nor
18174  make text in the middle of an invisible paragraph visible again.
18175  To accomplish this feat, you'll need to use some inlined \SpecialChar LaTeX
18176  codes.
18177 \begin_inset Foot
18178 status collapsed
18179
18180 \begin_layout Plain Layout
18181 The commands of interest are: 
18182 \end_layout
18183
18184 \begin_layout Itemize
18185
18186 \family typewriter
18187 {
18188 \backslash
18189 invisible \SpecialChar ldots
18190  }
18191 \end_layout
18192
18193 \begin_layout Itemize
18194
18195 \family typewriter
18196 {
18197 \backslash
18198 visible \SpecialChar ldots
18199  }
18200 \end_layout
18201
18202 \begin_layout Plain Layout
18203 \SpecialChar ldots
18204 and need to be marked as \SpecialChar TeX
18205 .
18206  The text whose 
18207 \begin_inset Quotes eld
18208 \end_inset
18209
18210 visibility
18211 \begin_inset Quotes erd
18212 \end_inset
18213
18214  you wish to change goes in between the brackets [and after the 
18215 \family typewriter
18216
18217 \backslash
18218 invisible
18219 \family default
18220  or 
18221 \family typewriter
18222
18223 \backslash
18224 visible
18225 \family default
18226  command].
18227  If you don't know how to mark text as \SpecialChar TeX
18228 , see the appropriate section of
18229  the 
18230 \emph on
18231 User's Guide
18232 \emph default
18233 .
18234 \end_layout
18235
18236 \end_inset
18237
18238
18239 \end_layout
18240
18241 \begin_layout Subsubsection
18242 Using 
18243 \family sans
18244 Note
18245 \family default
18246  with 
18247 \family sans
18248 Slide
18249 \family default
18250
18251 \begin_inset CommandInset label
18252 LatexCommand label
18253 name "sec:slideNote"
18254
18255 \end_inset
18256
18257
18258 \end_layout
18259
18260 \begin_layout Standard
18261 Like an 
18262 \family sans
18263 Overlay
18264 \family default
18265 , a 
18266 \family sans
18267 Note
18268 \family default
18269  is associated with a 
18270 \begin_inset Quotes eld
18271 \end_inset
18272
18273 parent
18274 \begin_inset Quotes erd
18275 \end_inset
18276
18277  
18278 \family sans
18279 Slide
18280 \family default
18281 .
18282  Here, too, the \SpecialChar LyX
18283  
18284 \family sans
18285 slides
18286 \family default
18287  class provides visual cues.
18288  The label for a 
18289 \family sans
18290 Note
18291 \family default
18292  is shorter than that of a 
18293 \family sans
18294 Slide
18295 \family default
18296  [yet longer than that of an 
18297 \family sans
18298 Overlay
18299 \family default
18300 ] and, like the label of an 
18301 \family sans
18302 Overlay
18303 \family default
18304  is shockingly magenta.
18305  Additionally, the printed 
18306 \family sans
18307 Note
18308 \family default
18309  has the page number of its 
18310 \begin_inset Quotes eld
18311 \end_inset
18312
18313 parent
18314 \begin_inset Quotes erd
18315 \end_inset
18316
18317  
18318 \family sans
18319 Slide
18320 \family default
18321 , appended by 
18322 \begin_inset Quotes eld
18323 \end_inset
18324
18325
18326 \family typewriter
18327 -
18328 \family default
18329 1
18330 \begin_inset Quotes erd
18331 \end_inset
18332
18333
18334 \begin_inset Quotes eld
18335 \end_inset
18336
18337
18338 \family typewriter
18339 -
18340 \family default
18341 2
18342 \begin_inset Quotes erd
18343 \end_inset
18344
18345
18346 \begin_inset Quotes eld
18347 \end_inset
18348
18349
18350 \family typewriter
18351 -
18352 \family default
18353 3
18354 \begin_inset Quotes erd
18355 \end_inset
18356
18357 , etc.
18358  You can have multiple 
18359 \family sans
18360 Note
18361 \family default
18362 s associated with a single 
18363 \family sans
18364 Slide
18365 \family default
18366 , and, as with 
18367 \family sans
18368 Slide
18369 \family default
18370  and 
18371 \family sans
18372 Overlay
18373 \family default
18374 , you'll probably want to break up long 
18375 \family sans
18376 Note
18377 \family default
18378 s so that they fit on a single sheet of paper.
18379 \end_layout
18380
18381 \begin_layout Standard
18382 The purpose of a 
18383 \family sans
18384 Note
18385 \family default
18386  is obvious: it contains anything additional you might want to say about
18387  a 
18388 \family sans
18389 Slide
18390 \family default
18391 .
18392  It could also be used as a sheet of reminders for a particular 
18393 \family sans
18394 Slide
18395 \family default
18396 .
18397  In the case of the latter, you might want to make use of time markers.
18398  Currently, the \SpecialChar LyX
18399  
18400 \family sans
18401 slides
18402 \family default
18403  class has no 
18404 \begin_inset Quotes eld
18405 \end_inset
18406
18407 native
18408 \begin_inset Quotes erd
18409 \end_inset
18410
18411  support for time markers, a 
18412 \noun on
18413 Sli\SpecialChar TeX
18414
18415 \noun default
18416  feature.
18417  So, you'll have to resort to using the \SpecialChar LaTeX
18418  codes.
18419 \end_layout
18420
18421 \begin_layout Standard
18422 To use time markers, you'll need to specify the extra class option 
18423 \begin_inset Quotes eld
18424 \end_inset
18425
18426
18427 \family typewriter
18428 clock
18429 \family default
18430
18431 \begin_inset Quotes erd
18432 \end_inset
18433
18434  [see section
18435 \begin_inset space ~
18436 \end_inset
18437
18438
18439 \begin_inset CommandInset ref
18440 LatexCommand ref
18441 reference "sec:slidesetup"
18442
18443 \end_inset
18444
18445 ].
18446  This option turns on timing marks, which will appear in the lower-left-hand
18447  corner of every 
18448 \family sans
18449 Note
18450 \family default
18451  you generate.
18452  To set what appears in the time marker, you use the \SpecialChar LaTeX
18453  commands 
18454 \begin_inset Quotes eld
18455 \end_inset
18456
18457
18458 \family typewriter
18459
18460 \backslash
18461 settime{}
18462 \family default
18463
18464 \begin_inset Quotes erd
18465 \end_inset
18466
18467  and 
18468 \begin_inset Quotes eld
18469 \end_inset
18470
18471
18472 \family typewriter
18473
18474 \backslash
18475 addtime{}
18476 \family default
18477
18478 \begin_inset Quotes erd
18479 \end_inset
18480
18481 .
18482  The arguments of both commands are time measured in seconds.
18483  
18484 \begin_inset Quotes eld
18485 \end_inset
18486
18487
18488 \family typewriter
18489
18490 \backslash
18491 settime{}
18492 \family default
18493
18494 \begin_inset Quotes erd
18495 \end_inset
18496
18497  sets the time marker to a given time.
18498  
18499 \begin_inset Quotes eld
18500 \end_inset
18501
18502
18503 \family typewriter
18504
18505 \backslash
18506 addtime{}
18507 \family default
18508
18509 \begin_inset Quotes erd
18510 \end_inset
18511
18512  increments the time marker by the specified amount.
18513  Using time markers and 
18514 \family sans
18515 Note
18516 \family default
18517 s in this fashion, you can remind yourself how much time to spend on a particula
18518
18519 \family sans
18520 Slide
18521 \family default
18522 .
18523 \end_layout
18524
18525 \begin_layout Standard
18526 There's one last feature to describe.
18527  Clearly, you'd like to print out all of your 
18528 \family sans
18529 Slide
18530 \family default
18531 s and 
18532 \family sans
18533 Overlay
18534 \family default
18535 s on transparencies while printing all of your 
18536 \family sans
18537 Note
18538 \family default
18539 s on plain paper.
18540  However, a 
18541 \family sans
18542 Note
18543 \family default
18544  
18545 \emph on
18546 must
18547 \emph default
18548  follow the 
18549 \family sans
18550 Slide
18551 \family default
18552  with which it is associated.
18553  What's a person to do?
18554 \end_layout
18555
18556 \begin_layout Standard
18557 Luckily, there are two \SpecialChar LaTeX
18558  commands that allow you to select what to print
18559  out.
18560  Both must be placed into the preamble of your document.
18561  The command 
18562 \begin_inset Quotes eld
18563 \end_inset
18564
18565
18566 \family typewriter
18567
18568 \backslash
18569 onlyslides{
18570 \backslash
18571 slides}
18572 \family default
18573
18574 \begin_inset Quotes erd
18575 \end_inset
18576
18577  will cause the output to contain only the 
18578 \family sans
18579 Slide
18580 \family default
18581 s and 
18582 \family sans
18583 Overlay
18584 \family default
18585 s.
18586  Correspondingly, the command 
18587 \begin_inset Quotes eld
18588 \end_inset
18589
18590
18591 \family typewriter
18592
18593 \backslash
18594 onlynotes{
18595 \backslash
18596 notes}
18597 \family default
18598
18599 \begin_inset Quotes erd
18600 \end_inset
18601
18602  prevents the output of anything but 
18603 \family sans
18604 Note
18605 \family default
18606 s.
18607  I'd advise placing both commands in the preamble and initially comment
18608  both out.
18609  You can then preview your entire presentation as you write.
18610  When you're done writing, you can then uncomment one of the two to select
18611  what you want to print.
18612  I like to uncomment 
18613 \begin_inset Quotes eld
18614 \end_inset
18615
18616
18617 \family typewriter
18618
18619 \backslash
18620 onlyslides{
18621 \backslash
18622 slides}
18623 \family default
18624
18625 \begin_inset Quotes erd
18626 \end_inset
18627
18628  , print to a file with 
18629 \begin_inset Quotes eld
18630 \end_inset
18631
18632
18633 \family typewriter
18634 -slides
18635 \family default
18636
18637 \begin_inset Quotes erd
18638 \end_inset
18639
18640  in its name, comment it back out, then uncomment 
18641 \begin_inset Quotes eld
18642 \end_inset
18643
18644
18645 \family typewriter
18646
18647 \backslash
18648 onlynotes{
18649 \backslash
18650 notes}
18651 \family default
18652
18653 \begin_inset Quotes erd
18654 \end_inset
18655
18656  and print to a 
18657 \begin_inset Quotes eld
18658 \end_inset
18659
18660
18661 \family typewriter
18662 *-notes.ps
18663 \family default
18664
18665 \begin_inset Quotes erd
18666 \end_inset
18667
18668  file.
18669  I can then send either file to a printer, loading transparencies or plain
18670  paper as appropriate.
18671 \end_layout
18672
18673 \begin_layout Standard
18674 You can also provide other arguments to the 
18675 \begin_inset Quotes eld
18676 \end_inset
18677
18678
18679 \family typewriter
18680
18681 \backslash
18682 onlyslides{}
18683 \family default
18684
18685 \begin_inset Quotes erd
18686 \end_inset
18687
18688  and 
18689 \begin_inset Quotes eld
18690 \end_inset
18691
18692
18693 \family typewriter
18694
18695 \backslash
18696 onlynotes{}
18697 \family default
18698
18699 \begin_inset Quotes erd
18700 \end_inset
18701
18702  commands.
18703  See a good \SpecialChar LaTeX
18704  book for details.
18705 \end_layout
18706
18707 \begin_layout Subsection
18708 The 
18709 \family sans
18710 slides
18711 \family default
18712  Class Template File
18713 \end_layout
18714
18715 \begin_layout Standard
18716 I have also provided a template file, 
18717 \begin_inset Quotes eld
18718 \end_inset
18719
18720
18721 \family typewriter
18722 slides.lyx
18723 \family default
18724
18725 \begin_inset Quotes erd
18726 \end_inset
18727
18728 , with the 
18729 \family sans
18730 slides
18731 \family default
18732  class.
18733  To use it, begin your new presentation with 
18734 \family sans
18735 File\SpecialChar menuseparator
18736 New
18737 \begin_inset space ~
18738 \end_inset
18739
18740 from
18741 \begin_inset space ~
18742 \end_inset
18743
18744 Template
18745 \family default
18746 .
18747  Your new \SpecialChar LyX
18748  presentation file will contain an example 
18749 \family sans
18750 Slide
18751 \family default
18752  â€“ 
18753 \family sans
18754 Overlay
18755 \family default
18756  â€“ 
18757 \family sans
18758 Note
18759 \family default
18760  triplet.
18761  The 
18762 \family sans
18763 Slide
18764 \family default
18765  and 
18766 \family sans
18767 Overlay
18768 \family default
18769  additionally contain an example of the use of 
18770 \family sans
18771 InvisibleText
18772 \family default
18773  and 
18774 \family sans
18775 VisibleText
18776 \family default
18777 .
18778  Lastly, the preamble will contain:
18779 \end_layout
18780
18781 \begin_layout LyX-Code
18782 % Uncomment to print out only slides and overlays
18783 \end_layout
18784
18785 \begin_layout LyX-Code
18786 %
18787 \end_layout
18788
18789 \begin_layout LyX-Code
18790 %
18791 \backslash
18792 onlyslides{
18793 \backslash
18794 slides}
18795 \begin_inset Newline newline
18796 \end_inset
18797
18798  
18799 \end_layout
18800
18801 \begin_layout LyX-Code
18802 % Uncomment to print out only notes
18803 \end_layout
18804
18805 \begin_layout LyX-Code
18806 %
18807 \end_layout
18808
18809 \begin_layout LyX-Code
18810 %
18811 \backslash
18812 onlynotes{
18813 \backslash
18814 notes}
18815 \end_layout
18816
18817 \begin_layout Standard
18818 One final thing: I created this class to support the \SpecialChar LaTeX2e
18819  
18820 \begin_inset Quotes eld
18821 \end_inset
18822
18823
18824 \noun on
18825 Sli\SpecialChar TeX
18826
18827 \noun default
18828  emulation
18829 \begin_inset Quotes erd
18830 \end_inset
18831
18832  class, one of the built-in \SpecialChar LaTeX2e
18833  classes.
18834  Neither I nor the rest of the \SpecialChar LyX
18835  Team endorse or oppose the use of this built-in
18836  slide class.
18837  It's here if you want it or need it.
18838  There exist other \SpecialChar LaTeX2e
18839  classes for creating presentations, such as the 
18840 \family sans
18841 Foils
18842 \family default
18843  class [see section
18844 \begin_inset space ~
18845 \end_inset
18846
18847
18848 \begin_inset CommandInset ref
18849 LatexCommand ref
18850 reference "sec:foiltex"
18851
18852 \end_inset
18853
18854 ] or the 
18855 \begin_inset Quotes eld
18856 \end_inset
18857
18858
18859 \family typewriter
18860 seminar
18861 \family default
18862
18863 \begin_inset Quotes erd
18864 \end_inset
18865
18866  package [present on some \SpecialChar TeX
18867  distributions].
18868  The latter is not yet supported under \SpecialChar LyX
18869 .
18870 \begin_inset Foot
18871 status collapsed
18872
18873 \begin_layout Plain Layout
18874 Perhaps you can take on the task\SpecialChar ldots
18875
18876 \end_layout
18877
18878 \end_inset
18879
18880  I know nothing about these other classes.
18881  Try them out to see what sort of alternative they provide.
18882 \end_layout
18883
18884 \begin_layout Chapter
18885 \SpecialChar LyX
18886  Features needing Extra Software
18887 \end_layout
18888
18889 \begin_layout Section
18890 Checking \SpecialChar TeX
18891
18892 \end_layout
18893
18894 \begin_layout Standard
18895 by 
18896 \noun on
18897 Asger Alstrup
18898 \end_layout
18899
18900 \begin_layout Subsection
18901 Introduction
18902 \end_layout
18903
18904 \begin_layout Standard
18905 If you have the 
18906 \family typewriter
18907 chktex
18908 \family default
18909  program installed
18910 \begin_inset Foot
18911 status collapsed
18912
18913 \begin_layout Plain Layout
18914
18915 \family typewriter
18916 chktex
18917 \family default
18918  is not yet available when you are using the \SpecialChar LaTeX
18919  distribution MiK\SpecialChar TeX
18920 .
18921 \end_layout
18922
18923 \end_inset
18924
18925 , you'll find in the 
18926 \family sans
18927 Tools
18928 \family default
18929  menu the entry: 
18930 \family sans
18931 Check
18932 \begin_inset space ~
18933 \end_inset
18934
18935 TeX
18936 \family default
18937 .
18938  You can get 
18939 \family typewriter
18940 chktex
18941 \family default
18942  from CTAN,
18943 \begin_inset Newline newline
18944 \end_inset
18945
18946
18947 \begin_inset CommandInset href
18948 LatexCommand href
18949 target "https://www.ctan.org/tex-archive/help/Catalogue/entries/chktex.html"
18950 literal "false"
18951
18952 \end_inset
18953
18954 .
18955 \end_layout
18956
18957 \begin_layout Standard
18958 The 
18959 \family sans
18960 Chk\SpecialChar TeX
18961
18962 \family default
18963  package is a program that was written by 
18964 \begin_inset Flex Noun
18965 status collapsed
18966
18967 \begin_layout Plain Layout
18968 Jens T.
18969 \begin_inset space ~
18970 \end_inset
18971
18972 Berger Thielemann
18973 \end_layout
18974
18975 \end_inset
18976
18977  in frustration because some constructs in \SpecialChar LaTeX
18978  are sometimes non-intuitive,
18979  and easy to forget.
18980  The program runs over your \SpecialChar LaTeX
18981  file, checks the integrity of the file, and
18982  flags some common errors.
18983  In other technical words, it is 
18984 \family typewriter
18985 lint
18986 \family default
18987  for \SpecialChar LaTeX
18988 .
18989 \end_layout
18990
18991 \begin_layout Standard
18992 Well, what is a syntax checker doing in \SpecialChar LyX
18993  which is supposed to produce correct
18994  \SpecialChar LaTeX
18995  anyways? The answer is simple: Just as 
18996 \family typewriter
18997 Lint
18998 \family default
18999  not only checks the 
19000 \emph on
19001 syntax
19002 \emph default
19003  of C programs, but also does 
19004 \emph on
19005 semantic
19006 \emph default
19007  checks for type-errors, 
19008 \family sans
19009 Chk\SpecialChar TeX
19010
19011 \family default
19012  catches some common 
19013 \emph on
19014 typographic
19015 \emph default
19016  errors, in addition to the syntactical ones.
19017  Specifically, 
19018 \family sans
19019 Chk\SpecialChar TeX
19020
19021 \family default
19022  is capable of detecting several common errors, such as
19023 \end_layout
19024
19025 \begin_layout Itemize
19026 Ellipsis detection:
19027 \begin_inset Newline newline
19028 \end_inset
19029
19030 Use \SpecialChar ldots
19031  instead of ...
19032 \end_layout
19033
19034 \begin_layout Itemize
19035 No space in front of/after parenthesis:
19036 \begin_inset Newline newline
19037 \end_inset
19038
19039 ( wrong spacing )
19040 \end_layout
19041
19042 \begin_layout Itemize
19043 Enforcement of normal space after common abbreviations:
19044 \begin_inset Newline newline
19045 \end_inset
19046
19047 e.
19048 \begin_inset space \thinspace{}
19049 \end_inset
19050
19051 g.
19052 \begin_inset space \space{}
19053 \end_inset
19054
19055 is too wide spacing.
19056 \end_layout
19057
19058 \begin_layout Itemize
19059 Enforcement of end-of-sentence space when the last sentence ends with a
19060  capital letter:
19061 \begin_inset Newline newline
19062 \end_inset
19063
19064 This is a TEST.
19065  And this is wrong spacing.
19066 \end_layout
19067
19068 \begin_layout Itemize
19069 Space in front of labels and similar commands:
19070 \begin_inset Newline newline
19071 \end_inset
19072
19073 The label should stick right up to the text to avoid falling to a wrong
19074  page.
19075  
19076 \begin_inset CommandInset label
19077 LatexCommand label
19078 name "sec:chktex"
19079
19080 \end_inset
19081
19082  
19083 \begin_inset Foot
19084 status collapsed
19085
19086 \begin_layout Plain Layout
19087 This footnote is in danger of falling off to a wrong page
19088 \end_layout
19089
19090 \end_inset
19091
19092  The label is separated too much.
19093 \end_layout
19094
19095 \begin_layout Itemize
19096 Space in front of references, instead of hard spaces:
19097 \begin_inset Newline newline
19098 \end_inset
19099
19100 If you have bad luck, the text will break right between the referenced text
19101  and reference number, and that's a pity.
19102  See section 
19103 \begin_inset CommandInset ref
19104 LatexCommand ref
19105 reference "sec:chktex"
19106
19107 \end_inset
19108
19109 .
19110 \end_layout
19111
19112 \begin_layout Itemize
19113 Use of 
19114 \begin_inset Quotes eld
19115 \end_inset
19116
19117 x
19118 \begin_inset Quotes erd
19119 \end_inset
19120
19121  instead of 
19122 \begin_inset Formula $\times$
19123 \end_inset
19124
19125  between numbers:
19126 \begin_inset Newline newline
19127 \end_inset
19128
19129 2x2 looks cheap compared to 
19130 \begin_inset Formula $2\times2$
19131 \end_inset
19132
19133 .
19134 \end_layout
19135
19136 \begin_layout Standard
19137 and more \SpecialChar ldots
19138  It is an invaluable tool when you are 
19139 \begin_inset Quotes eld
19140 \end_inset
19141
19142 finishing up
19143 \begin_inset Quotes erd
19144 \end_inset
19145
19146  your document before printing, and you should run it right after the obligatory
19147  spelling check, and before you go fine tuning the typesetting.
19148 \end_layout
19149
19150 \begin_layout Subsection
19151 How to use it
19152 \end_layout
19153
19154 \begin_layout Standard
19155 If you have the program installed, usage is as simple as choosing 
19156 \family sans
19157 Tools\SpecialChar menuseparator
19158 Check
19159 \begin_inset space ~
19160 \end_inset
19161
19162 TeX
19163 \family default
19164 .
19165  This will make \SpecialChar LyX
19166  generate a \SpecialChar LaTeX
19167  file of your document, start 
19168 \family sans
19169 Chk\SpecialChar TeX
19170
19171 \family default
19172  to check it, and then make \SpecialChar LyX
19173  insert 
19174 \begin_inset Quotes eld
19175 \end_inset
19176
19177 error boxes
19178 \begin_inset Quotes erd
19179 \end_inset
19180
19181  with the warnings from 
19182 \family sans
19183 Chk\SpecialChar TeX
19184
19185 \family default
19186 , if there were any.
19187  The warnings will be placed close to the point of the mistake, and you
19188  can quickly find them by using the 
19189 \family sans
19190 Navigate\SpecialChar menuseparator
19191 Error
19192 \family default
19193  menu item, or the shortcut key 
19194 \family sans
19195 C-g
19196 \family default
19197  from the default 
19198 \family typewriter
19199 cua
19200 \family default
19201  bind file.
19202  Open the error boxes by clicking on them with the mouse, or use the shortcut
19203  key 
19204 \family sans
19205 C-i
19206 \family default
19207  from 
19208 \family typewriter
19209 cua
19210 \family default
19211  bindings, or the corresponding 
19212 \family sans
19213 C-o
19214 \family default
19215  for the alternate 
19216 \family typewriter
19217 emacs
19218 \family default
19219  bind file.
19220  Read the warning and correct the mistake, if it is a mistake.
19221  If you have trouble understanding what the warning is about, you can safely
19222  ignore it.
19223  Remember that there is a hidden layer between the document on screen and
19224  the technical details in invoking 
19225 \family sans
19226 Chk\SpecialChar TeX
19227
19228 \family default
19229 , and this gap can make some warnings seem arcane or just plain silly.
19230 \end_layout
19231
19232 \begin_layout Standard
19233 This document is an excellent testing bed for the feature, and it should
19234  provide quite a few warnings for you to fiddle with.
19235  Since computers are only so smart, expect most of the warnings to be false
19236  alarms, though.
19237 \end_layout
19238
19239 \begin_layout Subsection
19240 How to fine tune it
19241 \end_layout
19242
19243 \begin_layout Standard
19244 Sometimes, you'll find that 
19245 \family sans
19246 Chk\SpecialChar TeX
19247
19248 \family default
19249  makes more noise than suits your mood.
19250  Then you can choose not to use it, wait until your mood changes, or try
19251  to customize 
19252 \family sans
19253 Chk\SpecialChar TeX
19254
19255 \family default
19256  to get better along with you.
19257 \end_layout
19258
19259 \begin_layout Standard
19260 Although 
19261 \family sans
19262 Chk\SpecialChar TeX
19263
19264 \family default
19265  
19266 \emph on
19267 is
19268 \emph default
19269  very configurable and extensible, you should not expect to solve all problems
19270  with 
19271 \family sans
19272 Chk\SpecialChar TeX
19273
19274 \family default
19275  in \SpecialChar LyX
19276  this way.
19277  Since \SpecialChar LyX
19278  has to generate a somewhat special \SpecialChar LaTeX
19279  file to be able to match the
19280  line numbers from the 
19281 \family sans
19282 Chk\SpecialChar TeX
19283
19284 \family default
19285  output
19286 \begin_inset Foot
19287 status collapsed
19288
19289 \begin_layout Plain Layout
19290 You can inspect the specific output from 
19291 \family sans
19292 chktex
19293 \family default
19294  by using 
19295 \family sans
19296 Document\SpecialChar menuseparator
19297 \SpecialChar LaTeX
19298
19299 \begin_inset space ~
19300 \end_inset
19301
19302 Log
19303 \family default
19304  right after a 
19305 \family sans
19306 chktex
19307 \family default
19308  run.
19309 \end_layout
19310
19311 \end_inset
19312
19313  to the internal document structure, some of the warnings will not appear
19314  correctly.
19315  There are two things you can do about this:
19316 \end_layout
19317
19318 \begin_layout Itemize
19319 Fine tune the 
19320 \family sans
19321 Chk\SpecialChar TeX
19322
19323 \family default
19324  invocation command line in 
19325 \begin_inset Flex Noun
19326 status collapsed
19327
19328 \begin_layout Plain Layout
19329 Tools\SpecialChar menuseparator
19330 Preferences\SpecialChar menuseparator
19331 Output\SpecialChar menuseparator
19332 LaTeX\SpecialChar menuseparator
19333 CheckTeX command
19334 \end_layout
19335
19336 \end_inset
19337
19338 , or the global 
19339 \family sans
19340 Chk\SpecialChar TeX
19341
19342 \family default
19343  installation configuration file (usually with the file 
19344 \family typewriter
19345 chktexrc
19346 \family default
19347 ).
19348  See below to learn what warnings can be enabled and disabled on the command
19349  line.
19350 \end_layout
19351
19352 \begin_layout Itemize
19353 Export your document as a raw \SpecialChar LaTeX
19354  file using 
19355 \family sans
19356 File\SpecialChar menuseparator
19357 Export\SpecialChar menuseparator
19358 \SpecialChar LaTeX
19359
19360 \family default
19361  and run 
19362 \family typewriter
19363 chktex
19364 \family default
19365  manually on that.
19366  Invoked in this way, it can be a hassle to find the corresponding place
19367  in the document inside \SpecialChar LyX
19368 , but with a little patience, you should be able
19369  to do it.
19370 \end_layout
19371
19372 \begin_layout Standard
19373 Here follows the warning messages that can be enabled and disabled in 
19374 \family sans
19375 Preferences
19376 \family default
19377 .
19378  Use 
19379 \family typewriter
19380 -n#
19381 \family default
19382  to disable a warning, and 
19383 \family typewriter
19384 -w#
19385 \family default
19386  to enable a warning.
19387  The emphasized entries are disabled by default, because the default is
19388  "
19389 \family typewriter
19390 chktex -n1 -n3 -n6 -n9 -n22 -n25 -n30 -n38
19391 \family default
19392 ".
19393 \end_layout
19394
19395 \begin_layout Standard
19396 Notice that you should only use the options that enable and disable warnings,
19397  because \SpecialChar LyX
19398  relies on some of the other command line parameters to be set
19399  in a specific way to have a chance to communicate with 
19400 \family typewriter
19401 chktex
19402 \family default
19403 .
19404 \end_layout
19405
19406 \begin_layout Enumerate
19407
19408 \size small
19409 \emph on
19410 Command terminated with space.
19411 \end_layout
19412
19413 \begin_layout Enumerate
19414
19415 \size small
19416 Non-breaking space (
19417 \begin_inset Quotes eld
19418 \end_inset
19419
19420
19421 \family typewriter
19422 ~
19423 \family default
19424
19425 \begin_inset Quotes erd
19426 \end_inset
19427
19428 ) should have been used.
19429 \end_layout
19430
19431 \begin_layout Enumerate
19432
19433 \size small
19434 \emph on
19435 You should enclose the previous parenthesis with 
19436 \begin_inset Quotes eld
19437 \end_inset
19438
19439
19440 \family typewriter
19441 {}
19442 \family default
19443
19444 \begin_inset Quotes erd
19445 \end_inset
19446
19447 .
19448 \end_layout
19449
19450 \begin_layout Enumerate
19451
19452 \size small
19453 Italic correction (
19454 \begin_inset Quotes eld
19455 \end_inset
19456
19457
19458 \family typewriter
19459
19460 \backslash
19461 /
19462 \family default
19463
19464 \begin_inset Quotes erd
19465 \end_inset
19466
19467 ) found in non-italic buffer.
19468 \end_layout
19469
19470 \begin_layout Enumerate
19471
19472 \size small
19473 Italic correction (
19474 \begin_inset Quotes eld
19475 \end_inset
19476
19477
19478 \family typewriter
19479
19480 \backslash
19481 /
19482 \family default
19483
19484 \begin_inset Quotes erd
19485 \end_inset
19486
19487 ) found more than once.
19488 \end_layout
19489
19490 \begin_layout Enumerate
19491
19492 \size small
19493 \emph on
19494 No italic correction (
19495 \begin_inset Quotes eld
19496 \end_inset
19497
19498
19499 \family typewriter
19500
19501 \backslash
19502 /
19503 \family default
19504
19505 \begin_inset Quotes erd
19506 \end_inset
19507
19508 ) found.
19509 \end_layout
19510
19511 \begin_layout Enumerate
19512
19513 \size small
19514 Accent command 
19515 \begin_inset Quotes eld
19516 \end_inset
19517
19518
19519 \family typewriter
19520 cmd
19521 \family default
19522
19523 \begin_inset Quotes erd
19524 \end_inset
19525
19526  needs use of 
19527 \begin_inset Quotes eld
19528 \end_inset
19529
19530
19531 \family typewriter
19532 cmd
19533 \family default
19534
19535 \begin_inset Quotes erd
19536 \end_inset
19537
19538 .
19539 \end_layout
19540
19541 \begin_layout Enumerate
19542
19543 \size small
19544 Wrong length of dash may have been used.
19545 \end_layout
19546
19547 \begin_layout Enumerate
19548
19549 \size small
19550 \emph on
19551 \begin_inset Quotes eld
19552 \end_inset
19553
19554
19555 \family typewriter
19556 %s
19557 \family default
19558
19559 \begin_inset Quotes erd
19560 \end_inset
19561
19562  expected, found 
19563 \begin_inset Quotes eld
19564 \end_inset
19565
19566
19567 \family typewriter
19568 %s
19569 \family default
19570
19571 \begin_inset Quotes erd
19572 \end_inset
19573
19574 .
19575 \end_layout
19576
19577 \begin_layout Enumerate
19578
19579 \size small
19580 Solo 
19581 \begin_inset Quotes eld
19582 \end_inset
19583
19584
19585 \family typewriter
19586 %s
19587 \family default
19588
19589 \begin_inset Quotes erd
19590 \end_inset
19591
19592  found.
19593 \end_layout
19594
19595 \begin_layout Enumerate
19596
19597 \size small
19598 You should use 
19599 \begin_inset Quotes eld
19600 \end_inset
19601
19602
19603 \family typewriter
19604 %s
19605 \family default
19606
19607 \begin_inset Quotes erd
19608 \end_inset
19609
19610  to achieve an ellipsis.
19611 \end_layout
19612
19613 \begin_layout Enumerate
19614
19615 \size small
19616 Inter-word spacing (
19617 \begin_inset Quotes eld
19618 \end_inset
19619
19620
19621 \family typewriter
19622
19623 \backslash
19624
19625 \family default
19626  
19627 \begin_inset Quotes eld
19628 \end_inset
19629
19630 ) should perhaps be used.
19631 \end_layout
19632
19633 \begin_layout Enumerate
19634
19635 \size small
19636 Inter-sentence spacing (
19637 \begin_inset Quotes eld
19638 \end_inset
19639
19640
19641 \family typewriter
19642
19643 \backslash
19644 @
19645 \family default
19646
19647 \begin_inset Quotes erd
19648 \end_inset
19649
19650 ) should perhaps be used.
19651 \end_layout
19652
19653 \begin_layout Enumerate
19654
19655 \size small
19656 Could not find argument for command.
19657 \end_layout
19658
19659 \begin_layout Enumerate
19660
19661 \size small
19662 No match found for 
19663 \begin_inset Quotes eld
19664 \end_inset
19665
19666
19667 \family typewriter
19668 %s
19669 \family default
19670
19671 \begin_inset Quotes erd
19672 \end_inset
19673
19674 .
19675 \end_layout
19676
19677 \begin_layout Enumerate
19678
19679 \size small
19680 Math mode still on at end of \SpecialChar LaTeX
19681  file.
19682 \end_layout
19683
19684 \begin_layout Enumerate
19685
19686 \size small
19687 Number of 
19688 \begin_inset Quotes eld
19689 \end_inset
19690
19691
19692 \family typewriter
19693 char
19694 \family default
19695
19696 \begin_inset Quotes erd
19697 \end_inset
19698
19699  doesn't match the number of 
19700 \begin_inset Quotes eld
19701 \end_inset
19702
19703
19704 \family typewriter
19705 char
19706 \family default
19707
19708 \begin_inset Quotes erd
19709 \end_inset
19710
19711 .
19712 \end_layout
19713
19714 \begin_layout Enumerate
19715
19716 \size small
19717 You should use either 
19718 \family typewriter
19719
19720 \begin_inset Quotes eld
19721 \end_inset
19722
19723
19724 \family default
19725  or 
19726 \family typewriter
19727
19728 \begin_inset Quotes erd
19729 \end_inset
19730
19731
19732 \family default
19733  as an alternative to 
19734 \begin_inset Quotes eld
19735 \end_inset
19736
19737
19738 \family typewriter
19739 "
19740 \family default
19741
19742 \begin_inset Quotes erd
19743 \end_inset
19744
19745 .
19746 \end_layout
19747
19748 \begin_layout Enumerate
19749
19750 \size small
19751 You should use "
19752 \family typewriter
19753 '
19754 \family default
19755 " (ASCII 39) instead of "
19756 \family typewriter
19757 ´
19758 \family default
19759 " (ASCII 180).
19760 \end_layout
19761
19762 \begin_layout Enumerate
19763
19764 \size small
19765 User-specified pattern found.
19766 \end_layout
19767
19768 \begin_layout Enumerate
19769
19770 \size small
19771 This command might not be intended.
19772 \end_layout
19773
19774 \begin_layout Enumerate
19775
19776 \size small
19777 \emph on
19778 Comment displayed.
19779 \end_layout
19780
19781 \begin_layout Enumerate
19782
19783 \size small
19784 Either 
19785 \family typewriter
19786 ''
19787 \backslash
19788 ,'
19789 \family default
19790  or 
19791 \family typewriter
19792 '
19793 \backslash
19794 ,''
19795 \family default
19796  will look better.
19797 \end_layout
19798
19799 \begin_layout Enumerate
19800
19801 \size small
19802 Delete this space to maintain correct page references.
19803 \end_layout
19804
19805 \begin_layout Enumerate
19806
19807 \size small
19808 \emph on
19809 You might wish to put this between a pair of 
19810 \begin_inset Quotes eld
19811 \end_inset
19812
19813
19814 \family typewriter
19815 {}
19816 \family default
19817
19818 \begin_inset Quotes erd
19819 \end_inset
19820
19821 .
19822 \end_layout
19823
19824 \begin_layout Enumerate
19825
19826 \size small
19827 You ought to remove spaces in front of punctuation.
19828 \end_layout
19829
19830 \begin_layout Enumerate
19831
19832 \size small
19833 Could not execute \SpecialChar LaTeX
19834  command.
19835 \end_layout
19836
19837 \begin_layout Enumerate
19838
19839 \size small
19840 Don't use 
19841 \family typewriter
19842
19843 \backslash
19844 /
19845 \family default
19846  in front of small punctuation.
19847 \end_layout
19848
19849 \begin_layout Enumerate
19850
19851 \family typewriter
19852 \size small
19853 $
19854 \backslash
19855 times$
19856 \family default
19857  may look prettier here.
19858 \end_layout
19859
19860 \begin_layout Enumerate
19861
19862 \size small
19863 \emph on
19864 Multiple spaces detected in output.
19865 \end_layout
19866
19867 \begin_layout Enumerate
19868
19869 \size small
19870 This text may be ignored.
19871 \end_layout
19872
19873 \begin_layout Enumerate
19874
19875 \size small
19876 Use 
19877 \family typewriter
19878
19879 \begin_inset Quotes eld
19880 \end_inset
19881
19882
19883 \family default
19884  to begin quotation, not 
19885 \family typewriter
19886 '
19887 \family default
19888 .
19889 \end_layout
19890
19891 \begin_layout Enumerate
19892
19893 \size small
19894 Use 
19895 \family typewriter
19896 '
19897 \family default
19898  to end quotation, not 
19899 \family typewriter
19900
19901 \begin_inset Quotes eld
19902 \end_inset
19903
19904
19905 \family default
19906 .
19907 \end_layout
19908
19909 \begin_layout Enumerate
19910
19911 \size small
19912 Don't mix quotes.
19913 \end_layout
19914
19915 \begin_layout Enumerate
19916
19917 \size small
19918 You should perhaps use 
19919 \begin_inset Quotes eld
19920 \end_inset
19921
19922
19923 \family typewriter
19924 cmd
19925 \family default
19926
19927 \begin_inset Quotes erd
19928 \end_inset
19929
19930  instead.
19931 \end_layout
19932
19933 \begin_layout Enumerate
19934
19935 \size small
19936 You should put a space in front of/after parenthesis.
19937 \end_layout
19938
19939 \begin_layout Enumerate
19940
19941 \size small
19942 You should avoid spaces in front of/after parenthesis.
19943 \end_layout
19944
19945 \begin_layout Enumerate
19946
19947 \size small
19948 \emph on
19949 You should not use punctuation in front of/after quotes.
19950 \end_layout
19951
19952 \begin_layout Enumerate
19953
19954 \size small
19955 Double space found.
19956 \end_layout
19957
19958 \begin_layout Enumerate
19959
19960 \size small
19961 You should put punctuation outside inner/inside display math mode.
19962 \end_layout
19963
19964 \begin_layout Enumerate
19965
19966 \size small
19967 You ought to not use primitive \SpecialChar TeX
19968  in \SpecialChar LaTeX
19969  code.
19970 \end_layout
19971
19972 \begin_layout Enumerate
19973
19974 \size small
19975 You should remove spaces in front of 
19976 \begin_inset Quotes eld
19977 \end_inset
19978
19979
19980 \family typewriter
19981 %s
19982 \family default
19983
19984 \begin_inset Quotes erd
19985 \end_inset
19986
19987
19988 \end_layout
19989
19990 \begin_layout Enumerate
19991
19992 \size small
19993 \begin_inset Quotes eld
19994 \end_inset
19995
19996
19997 \family typewriter
19998 %s
19999 \family default
20000
20001 \begin_inset Quotes erd
20002 \end_inset
20003
20004  is normally not followed by 
20005 \begin_inset Quotes eld
20006 \end_inset
20007
20008
20009 \family typewriter
20010 %c
20011 \family default
20012
20013 \begin_inset Quotes erd
20014 \end_inset
20015
20016 .
20017 \end_layout
20018
20019 \begin_layout Standard
20020 In later versions of \SpecialChar LyX
20021 , we hope to provide a more complete interface to this
20022  tool (and it's smaller cousin 
20023 \family typewriter
20024 lacheck
20025 \family default
20026 ) to exploit the full power of it.
20027  But it's not exactly useless as it is now: go try it on one of your existing
20028  documents of a certain length and be surprised.
20029 \end_layout
20030
20031 \begin_layout Section
20032 Version Control in \SpecialChar LyX
20033
20034 \end_layout
20035
20036 \begin_layout Standard
20037 by
20038 \noun on
20039  Lars Gullik Bjønnes 
20040 \noun default
20041 and 
20042 \noun on
20043 Pavel Sanda
20044 \end_layout
20045
20046 \begin_layout Subsection
20047 Introduction
20048 \end_layout
20049
20050 \begin_layout Standard
20051 \SpecialChar LyX
20052  supports some of the most basic RCS/CVS/SVN/GIT commands.
20053  If you need something a bit more sophisticated you will have to do that
20054  manually in a terminal.
20055 \end_layout
20056
20057 \begin_layout Standard
20058 Also note that CVS support is not as good as subversion support, so we advise
20059  using SVN instead.
20060  A good place to start learning Subversion is the SVN Book
20061 \begin_inset Foot
20062 status collapsed
20063
20064 \begin_layout Plain Layout
20065 \begin_inset CommandInset href
20066 LatexCommand href
20067 target "http://svnbook.red-bean.com/"
20068 literal "false"
20069
20070 \end_inset
20071
20072
20073 \end_layout
20074
20075 \end_inset
20076
20077 .
20078  In the case of RCS you should read 
20079 \begin_inset Quotes eld
20080 \end_inset
20081
20082 rcsintro
20083 \begin_inset Quotes erd
20084 \end_inset
20085
20086  (a man file, read it with 
20087 \family typewriter
20088 man rcsintro
20089 \family default
20090 ).
20091  This file describes all the basic features of RCS.
20092  You should especially notice the comment about a RCS directory, and the
20093  notion of a master RCS file (the file ending in 
20094 \family typewriter
20095 ,v
20096 \family default
20097 ).
20098 \end_layout
20099
20100 \begin_layout Standard
20101 Before you begin to use the version control features in \SpecialChar LyX
20102 , you should be
20103  familiar with RCS/CVS/SVN/GIT usage.
20104  The implementation in \SpecialChar LyX
20105  assumes a recent version of the GNU RCS or CVS/SVN
20106  package â€” no guarantees are made for older versions.
20107  Most of the log messages are not currently displayed after operations â€”
20108  you can check them in the Messages pane if you are unsure.
20109  Regular users of version control will appreciate the VC toolbar, which
20110  can be enabled via 
20111 \family sans
20112 View\SpecialChar menuseparator
20113 Toolbars\SpecialChar menuseparator
20114 Version
20115 \begin_inset space ~
20116 \end_inset
20117
20118 Control
20119 \family default
20120 .
20121 \end_layout
20122
20123 \begin_layout Standard
20124 For introducing your own external commands consult 
20125 \begin_inset Flex Code
20126 status collapsed
20127
20128 \begin_layout Plain Layout
20129 vc-command
20130 \end_layout
20131
20132 \end_inset
20133
20134  in the manual 
20135 \emph on
20136 \SpecialChar LyX
20137  Functions
20138 \emph default
20139 .
20140 \end_layout
20141
20142 \begin_layout Standard
20143 It is strongly recommended to store documents in uncompressed format if
20144  using version control (uncheck 
20145 \family sans
20146 Document\SpecialChar menuseparator
20147 Compressed
20148 \family default
20149  if it is checked): Uncompressed LyX documents are text files and therefore
20150  for merging two different versions by version control systems.
20151  Compressed LyX documents are binary files, which cannot be merged by version
20152  control systems.
20153 \end_layout
20154
20155 \begin_layout Subsection
20156 RCS commands in \SpecialChar LyX
20157
20158 \end_layout
20159
20160 \begin_layout Standard
20161 The following sections describe the RCS commands supported by \SpecialChar LyX
20162 .
20163  You can find them in the 
20164 \family sans
20165 File\SpecialChar menuseparator
20166 Version
20167 \begin_inset space ~
20168 \end_inset
20169
20170 Control
20171 \family default
20172  submenu.
20173  \SpecialChar LyX
20174  was tested against RCS 5.7/5.8.
20175 \end_layout
20176
20177 \begin_layout Subsubsection
20178
20179 \family sans
20180 Register
20181 \end_layout
20182
20183 \begin_layout Standard
20184 If your document is not under revision control, this is the only item shown
20185  in the menu.
20186  And if it is under revision control, the 
20187 \family sans
20188 Register
20189 \family default
20190  item is not visible.
20191  
20192 \end_layout
20193
20194 \begin_layout Standard
20195 This command registers your document with RCS (unless you are under the
20196  directory managed by CVS)\SpecialChar endofsentence
20197  You are asked interactively to supply an initial
20198  description of the document.
20199  The document is now set in Read-Only mode and you have to 
20200 \family sans
20201 Check
20202 \begin_inset space ~
20203 \end_inset
20204
20205 Out
20206 \begin_inset space ~
20207 \end_inset
20208
20209 For
20210 \begin_inset space ~
20211 \end_inset
20212
20213 Edit
20214 \family default
20215 , before making any changes to it.
20216  A document under revision control has a 
20217 \begin_inset Quotes eld
20218 \end_inset
20219
20220 [RCS:<version> <locker>]
20221 \begin_inset Quotes erd
20222 \end_inset
20223
20224  item tagged to the filename in the minibuffer.
20225 \end_layout
20226
20227 \begin_layout Standard
20228 RCS command that is run:
20229 \end_layout
20230
20231 \begin_layout LyX-Code
20232
20233 \family typewriter
20234 ci -q -u -i -t-"<initial description>" <file-name>
20235 \end_layout
20236
20237 \begin_layout Standard
20238 Read 
20239 \family typewriter
20240 man ci
20241 \family default
20242  to understand the switches.
20243  
20244 \end_layout
20245
20246 \begin_layout Subsubsection
20247
20248 \family sans
20249 Check In Changes
20250 \end_layout
20251
20252 \begin_layout Standard
20253 When you are finished editing a file, you check in your changes.
20254  When you do this, you are asked for a description of the changes.
20255  This is stored in the history log.
20256  The version number is bumped, your changes are applied to the master RCS
20257  file, the document is unlocked and set to Read-Only mode.
20258 \end_layout
20259
20260 \begin_layout Itemize
20261 RCS command: 
20262 \family typewriter
20263 ci -q -u -m"<description>" <file-name>
20264 \end_layout
20265
20266 \begin_layout Subsubsection
20267
20268 \family sans
20269 Check Out For Edit
20270 \end_layout
20271
20272 \begin_layout Standard
20273 By doing this you lock the document so that only you can edit it.
20274  This will also make the document Read-Write only for you.
20275  You will usually continue editing for a while and when you are finished
20276  you check in your changes.
20277  The status line is changed to reflect that you have locked the file.
20278 \end_layout
20279
20280 \begin_layout Itemize
20281 RCS command: 
20282 \family typewriter
20283 co -q -l <file-name>
20284 \end_layout
20285
20286 \begin_layout Subsubsection
20287
20288 \family sans
20289 Revert To Repository Version
20290 \end_layout
20291
20292 \begin_layout Standard
20293 This will discard all changes made to the document since the last check
20294  in.
20295  You get a warning before changes are discarded.
20296 \end_layout
20297
20298 \begin_layout Itemize
20299 RCS command: 
20300 \family typewriter
20301 co -f -u<version> <file-name>
20302 \end_layout
20303
20304 \begin_layout Subsubsection
20305
20306 \family sans
20307 Copy
20308 \end_layout
20309
20310 \begin_layout Standard
20311 This will create a copy of the current document.
20312  Since RCS does not support copy operations natively, the version history
20313  is not preserved, and the copy is added as a new file.
20314  It requires a clean document without any changes since the last checkin.
20315  You are asked for a file name and a description of the copy operation.
20316  After that the copy is created, both locally and in the repository.
20317  If the parent directories of the copied and original document differ, all
20318  relative paths of included files of the copy are adjusted (like in 
20319 \family sans
20320 File\SpecialChar menuseparator
20321 Save As
20322 \family default
20323 \SpecialChar ldots
20324 ).
20325  Finally, the copy is loaded instead of the original document.
20326 \end_layout
20327
20328 \begin_layout Labeling
20329 \labelwidthstring 00.00.0000
20330 RCS
20331 \begin_inset space ~
20332 \end_inset
20333
20334 commands: 
20335 \begin_inset space ~
20336 \end_inset
20337
20338
20339 \begin_inset Newline newline
20340 \end_inset
20341
20342 Copy 
20343 \begin_inset Flex Code
20344 status collapsed
20345
20346 \begin_layout Plain Layout
20347
20348 \family typewriter
20349 \begin_inset Quotes qld
20350 \end_inset
20351
20352 <file-name>
20353 \begin_inset Quotes qld
20354 \end_inset
20355
20356
20357 \end_layout
20358
20359 \end_inset
20360
20361  to 
20362 \begin_inset Flex Code
20363 status collapsed
20364
20365 \begin_layout Plain Layout
20366
20367 \family typewriter
20368 \begin_inset Quotes qld
20369 \end_inset
20370
20371 <new-file-name>
20372 \begin_inset Quotes qld
20373 \end_inset
20374
20375
20376 \end_layout
20377
20378 \end_inset
20379
20380
20381 \begin_inset Newline newline
20382 \end_inset
20383
20384
20385 \begin_inset Flex Code
20386 status collapsed
20387
20388 \begin_layout Plain Layout
20389 ci -q -u 
20390 \family typewriter
20391 -i 
20392 \begin_inset Quotes qld
20393 \end_inset
20394
20395 <new-file-name>
20396 \begin_inset Quotes qld
20397 \end_inset
20398
20399
20400 \end_layout
20401
20402 \end_inset
20403
20404
20405 \end_layout
20406
20407 \begin_layout Subsubsection
20408
20409 \family sans
20410 Undo Last Checkin
20411 \end_layout
20412
20413 \begin_layout Standard
20414 This makes as if the last check in never happened.
20415  No changes are made to the document loaded into \SpecialChar LyX
20416 , but the last version
20417  is removed from the master RCS file.
20418 \end_layout
20419
20420 \begin_layout Itemize
20421 RCS command: 
20422 \family typewriter
20423 rcs -o<version> <file-name>
20424 \end_layout
20425
20426 \begin_layout Subsubsection
20427
20428 \family sans
20429 Show History
20430 \end_layout
20431
20432 \begin_layout Standard
20433 This shows the complete history of the RCS document.
20434  The output of 
20435 \family typewriter
20436 rlog <file-name>
20437 \family default
20438  is shown in a browser.
20439  See 
20440 \family typewriter
20441 man rlog
20442 \family default
20443  for more info.
20444 \end_layout
20445
20446 \begin_layout Subsubsection
20447 Revision info
20448 \end_layout
20449
20450 \begin_layout Standard
20451 \SpecialChar LyX
20452  supports RCS version number, author name, date and time of last commit.
20453  All those are extracted from 
20454 \family typewriter
20455 rlog -r <file-name>
20456 \family default
20457 .
20458  See 
20459 \begin_inset CommandInset ref
20460 LatexCommand ref
20461 reference "subsec:VCS-Revision-Information"
20462
20463 \end_inset
20464
20465  for details.
20466 \end_layout
20467
20468 \begin_layout Subsection
20469 CVS commands in \SpecialChar LyX
20470
20471 \end_layout
20472
20473 \begin_layout Standard
20474 A subset of CVS operations is supported by \SpecialChar LyX
20475 .
20476  You can find the commands in the 
20477 \family sans
20478 File\SpecialChar menuseparator
20479 Version
20480 \begin_inset space ~
20481 \end_inset
20482
20483 Control
20484 \family default
20485  submenu.
20486  The version control system SVN is more powerful, so please use it instead
20487  of CVS if possible.
20488 \end_layout
20489
20490 \begin_layout Subsubsection
20491
20492 \family sans
20493 General CVS usage
20494 \end_layout
20495
20496 \begin_layout Standard
20497 If you start from scratch with CVS you have to create your repository and
20498  checkout the working copy with external tools.
20499  If you're using a client-server setup you may need to login before doing
20500  the first repository checkout.
20501 \end_layout
20502
20503 \begin_layout Standard
20504 If your documents are under revision control and others are using the same
20505  repository problems arise when different changes to the same document at
20506  the same location happen.
20507  Standard CVS repositories don't operate with a file locking mechanism.
20508  This may be surprising, but conflicts only occur if people disagree on
20509  the proper content of the same part of a document.
20510  So, if co-workers are used to communicate regularly, these conflicts occur
20511  rarely.
20512  If they don't communicate they have a fundamental problem anyway.
20513  Nevertheless some people like to work with so called 
20514 \begin_inset Quotes eld
20515 \end_inset
20516
20517 reserved checkouts
20518 \begin_inset Quotes erd
20519 \end_inset
20520
20521 .
20522  If they do so the working copy of all files is readonly when checked out
20523  first and the user starts editing after using a special command to make
20524  the working copy writable.
20525  When the changes are checked in the working copy returns to readonly state.
20526  With \SpecialChar LyX
20527  one has to edit the 
20528 \begin_inset Flex Code
20529 status collapsed
20530
20531 \begin_layout Plain Layout
20532 .cvsrc
20533 \end_layout
20534
20535 \end_inset
20536
20537  file and add the line 
20538 \begin_inset Flex Code
20539 status collapsed
20540
20541 \begin_layout Plain Layout
20542 cvs -r
20543 \end_layout
20544
20545 \end_inset
20546
20547  to work with reserved checkouts.
20548  The benefit is the possibility to see who is using a writable copy of some
20549  document.
20550  It's not guaranteed only one user makes a copy writable.
20551 \end_layout
20552
20553 \begin_layout Standard
20554 \SpecialChar LyX
20555  tries to guess if you're using reserved or non-reserved checkouts.
20556  If your working copy is readonly or it is writable and an additional copy
20557  of your document exists in the CVS/Base sub-directory a reserved otherwise
20558  a non-reserved checkout is assumed.
20559  When a reserved checkout is detected you have to use 
20560 \begin_inset Flex Noun
20561 status collapsed
20562
20563 \begin_layout Plain Layout
20564 Check Out
20565 \end_layout
20566
20567 \end_inset
20568
20569  to make your working copy writable if it's readonly.
20570  After doing so the 
20571 \begin_inset Flex Noun
20572 status collapsed
20573
20574 \begin_layout Plain Layout
20575 Check In
20576 \end_layout
20577
20578 \end_inset
20579
20580  operation is possible and that makes your working copy readonly again after
20581  transferring your changes to the repository.
20582 \end_layout
20583
20584 \begin_layout Standard
20585 More information about CVS can be found here 
20586 \begin_inset Flex URL
20587 status collapsed
20588
20589 \begin_layout Plain Layout
20590
20591 http://www.nongnu.org/cvs
20592 \end_layout
20593
20594 \end_inset
20595
20596  and here 
20597 \begin_inset Flex URL
20598 status collapsed
20599
20600 \begin_layout Plain Layout
20601
20602 http://ximbiot.com/cvs
20603 \end_layout
20604
20605 \end_inset
20606
20607 .
20608 \end_layout
20609
20610 \begin_layout Standard
20611 Read 
20612 \family typewriter
20613 man cvs
20614 \family default
20615  to understand the sub-commands and the switches mentioned below.
20616 \end_layout
20617
20618 \begin_layout Subsubsection
20619
20620 \family sans
20621 Register
20622 \end_layout
20623
20624 \begin_layout Standard
20625 If your document is not under revision control, this is the only item shown
20626  in the menu.
20627  And if it is under revision control, the 
20628 \family sans
20629 Register
20630 \family default
20631  item is not visible.
20632  
20633 \end_layout
20634
20635 \begin_layout Standard
20636 This command registers in CVS your document 
20637 \begin_inset Flex Strong
20638 status collapsed
20639
20640 \begin_layout Plain Layout
20641
20642 \emph on
20643 only
20644 \end_layout
20645
20646 \end_inset
20647
20648  in the case you have already the documents directory under CVS control
20649  (in particular 
20650 \family typewriter
20651 CVS/Entries
20652 \family default
20653  file exists).
20654  This means you have to create or checkout the archive by yourself using
20655  external tools.
20656  (In case you forget that step \SpecialChar LyX
20657  registers the document with RCS.)
20658 \end_layout
20659
20660 \begin_layout Standard
20661 Then you are asked interactively to supply an initial description of the
20662  document.
20663  Don't forget that registered file is not yet checked in.
20664 \end_layout
20665
20666 \begin_layout Standard
20667 CVS command that is run: 
20668 \family typewriter
20669 cvs -q add -m"<entered message>" "<file-name>"
20670 \end_layout
20671
20672 \begin_layout Standard
20673 The term 
20674 \family typewriter
20675 "<file-name>"
20676 \family default
20677  above and for all other CVS commands is an abbreviation for 
20678 \begin_inset Quotes eld
20679 \end_inset
20680
20681 change the current working directory to file location and use the file name
20682  without path component as argument
20683 \begin_inset Quotes erd
20684 \end_inset
20685
20686 .
20687 \end_layout
20688
20689 \begin_layout Subsubsection
20690
20691 \family sans
20692 Check In Changes
20693 \end_layout
20694
20695 \begin_layout Standard
20696 When you are finished editing a file, you commit your changes.
20697  When you do this and you had changed the document, you are asked for a
20698  description of the changes.
20699  After that changes are written to the repository.
20700  In case you didn't change the document and a reserved checkout is detected
20701  the reservation made on 
20702 \begin_inset Flex Noun
20703 status collapsed
20704
20705 \begin_layout Plain Layout
20706 Check Out
20707 \end_layout
20708
20709 \end_inset
20710
20711  is undone.
20712 \end_layout
20713
20714 \begin_layout Labeling
20715 \labelwidthstring 00.00.0000
20716 CVS
20717 \begin_inset space ~
20718 \end_inset
20719
20720 command: 
20721 \begin_inset space ~
20722 \end_inset
20723
20724
20725 \begin_inset Newline newline
20726 \end_inset
20727
20728
20729 \begin_inset Flex Code
20730 status collapsed
20731
20732 \begin_layout Plain Layout
20733 cvs 
20734 \family typewriter
20735 -q commit -m"<description>" "<file-name>"
20736 \end_layout
20737
20738 \end_inset
20739
20740  or
20741 \begin_inset Newline newline
20742 \end_inset
20743
20744
20745 \begin_inset Flex Code
20746 status collapsed
20747
20748 \begin_layout Plain Layout
20749 cvs -q unedit 
20750 \family typewriter
20751 "<file-name>"
20752 \end_layout
20753
20754 \end_inset
20755
20756
20757 \end_layout
20758
20759 \begin_layout Subsubsection
20760
20761 \family sans
20762 Check Out Changes
20763 \end_layout
20764
20765 \begin_layout Standard
20766 When you are sharing a repository with others, you may have to incorporate
20767  their changes into your working copy.
20768 \end_layout
20769
20770 \begin_layout Standard
20771 CVS command: 
20772 \family typewriter
20773 cvs -q update "<file-name>"
20774 \end_layout
20775
20776 \begin_layout Standard
20777 If a readonly checkout is detected the working copy is made writable and
20778  reserved.
20779 \end_layout
20780
20781 \begin_layout Standard
20782 CVS command: 
20783 \family typewriter
20784 cvs -q edit "<file-name>"
20785 \end_layout
20786
20787 \begin_layout Subsubsection
20788
20789 \family sans
20790 Revert To Repository Version
20791 \end_layout
20792
20793 \begin_layout Standard
20794 This will discard all changes made to the document since the last check
20795  in.
20796  You get a warning before changes are discarded.
20797  Firstly the file is deleted, secondly CVS update command is run.
20798 \end_layout
20799
20800 \begin_layout Standard
20801 CVS command: 
20802 \family typewriter
20803 cvs -q update "<file-name>"
20804 \end_layout
20805
20806 \begin_layout Standard
20807 If a reserved checkout is detected and the working copy has no changes only
20808  the reservation is undone.
20809 \end_layout
20810
20811 \begin_layout Standard
20812 CVS command: 
20813 \family typewriter
20814 cvs -q unedit "<file-name>"
20815 \end_layout
20816
20817 \begin_layout Subsubsection
20818
20819 \family sans
20820 Copy
20821 \end_layout
20822
20823 \begin_layout Standard
20824 This will create a copy of the current document.
20825  Since CVS does not support copy operations natively, the version history
20826  is not preserved, and the copy is added as a new file.
20827  It requires a clean document without any changes since the last checkin.
20828  You are asked for a file name and a description of the copy operation.
20829  After that the copy is created, both locally and in the repository.
20830  If the parent directories of the copied and original document differ, all
20831  relative paths of included files of the copy are adjusted (like in 
20832 \family sans
20833 File\SpecialChar menuseparator
20834 Save As
20835 \family default
20836 \SpecialChar ldots
20837 ).
20838  Finally, the copy is loaded instead of the original document.
20839 \end_layout
20840
20841 \begin_layout Labeling
20842 \labelwidthstring 00.00.0000
20843 CVS
20844 \begin_inset space ~
20845 \end_inset
20846
20847 commands: 
20848 \begin_inset space ~
20849 \end_inset
20850
20851
20852 \begin_inset Newline newline
20853 \end_inset
20854
20855 Copy 
20856 \begin_inset Flex Code
20857 status collapsed
20858
20859 \begin_layout Plain Layout
20860
20861 \family typewriter
20862 \lang ngerman
20863 "
20864 \lang english
20865 <file-name>
20866 \lang ngerman
20867 "
20868 \end_layout
20869
20870 \end_inset
20871
20872  to 
20873 \begin_inset Flex Code
20874 status collapsed
20875
20876 \begin_layout Plain Layout
20877
20878 \family typewriter
20879 \lang ngerman
20880 "
20881 \lang english
20882 <new-file-name>
20883 \lang ngerman
20884 "
20885 \end_layout
20886
20887 \end_inset
20888
20889
20890 \begin_inset Newline newline
20891 \end_inset
20892
20893
20894 \begin_inset Flex Code
20895 status collapsed
20896
20897 \begin_layout Plain Layout
20898 cvs -q add 
20899 \family typewriter
20900 \lang ngerman
20901 "
20902 \lang english
20903 <new-file-name>
20904 \lang ngerman
20905 "
20906 \end_layout
20907
20908 \end_inset
20909
20910
20911 \end_layout
20912
20913 \begin_layout Subsubsection
20914
20915 \family sans
20916 Rename
20917 \end_layout
20918
20919 \begin_layout Standard
20920 This will rename the current document.
20921  Since CVS does not support rename operations natively, the version history
20922  is not preserved, the renamed document is added as a new file, and the
20923  original document is deleted.
20924  It requires a clean document without any changes since the last checkin.
20925  You are asked for a file name and a description of the rename operation.
20926  After that the document is renamed, both locally and in the repository.
20927  If the parent directories of the new and old file names differ, all relative
20928  paths of included files are adjusted (like in 
20929 \family sans
20930 File\SpecialChar menuseparator
20931 Save As
20932 \family default
20933 \SpecialChar ldots
20934 ).
20935  Finally, the document is reloaded using the new name.
20936 \end_layout
20937
20938 \begin_layout Labeling
20939 \labelwidthstring 00.00.0000
20940 CVS
20941 \begin_inset space ~
20942 \end_inset
20943
20944 commands: 
20945 \begin_inset space ~
20946 \end_inset
20947
20948
20949 \begin_inset Newline newline
20950 \end_inset
20951
20952 Rename 
20953 \begin_inset Flex Code
20954 status collapsed
20955
20956 \begin_layout Plain Layout
20957
20958 \family typewriter
20959 \lang ngerman
20960 "
20961 \lang english
20962 <file-name>
20963 \lang ngerman
20964 "
20965 \end_layout
20966
20967 \end_inset
20968
20969  to 
20970 \begin_inset Flex Code
20971 status collapsed
20972
20973 \begin_layout Plain Layout
20974
20975 \family typewriter
20976 \lang ngerman
20977 "
20978 \lang english
20979 <new-file-name>
20980 \lang ngerman
20981 "
20982 \end_layout
20983
20984 \end_inset
20985
20986
20987 \begin_inset Newline newline
20988 \end_inset
20989
20990
20991 \begin_inset Flex Code
20992 status collapsed
20993
20994 \begin_layout Plain Layout
20995 cvs -q add 
20996 \family typewriter
20997 \lang ngerman
20998 "
20999 \lang english
21000 <new-file-name>
21001 \lang ngerman
21002 "
21003 \end_layout
21004
21005 \end_inset
21006
21007
21008 \begin_inset Newline newline
21009 \end_inset
21010
21011
21012 \begin_inset Flex Code
21013 status collapsed
21014
21015 \begin_layout Plain Layout
21016 cvs -q remove 
21017 \family typewriter
21018 \lang ngerman
21019 "
21020 \lang english
21021 <file-name>
21022 \lang ngerman
21023 "
21024 \end_layout
21025
21026 \end_inset
21027
21028
21029 \end_layout
21030
21031 \begin_layout Subsubsection
21032 Update of the local directory checkout from repository
21033 \end_layout
21034
21035 \begin_layout Standard
21036 Once your documents gets more complex, containing sub-documents and pictures,
21037  including external 
21038 \begin_inset Flex Code
21039 status collapsed
21040
21041 \begin_layout Plain Layout
21042 .tex
21043 \end_layout
21044
21045 \end_inset
21046
21047  files and so on using version control becomes more complicated.
21048  \SpecialChar LyX
21049  supports updating the whole tree in which resides the document.
21050  This become especially useful once you cooperate with people which neither
21051  have detailed knowledge about CVS usage nor they have ambition to commit
21052  additional material to the repository.
21053  You have to organize the files structure so that all external files are
21054  in the same directory or subdirectories of the document.
21055  It's good practice anyway to store multipart documents in an extra directory.
21056 \end_layout
21057
21058 \begin_layout Standard
21059 The 
21060 \begin_inset Flex Code
21061 status collapsed
21062
21063 \begin_layout Plain Layout
21064 Update local directory from repository
21065 \end_layout
21066
21067 \end_inset
21068
21069  command updates the whole directory.
21070  If local changes are detected user is warned before update starts.
21071  In case of merge conflicts both versions of the conflicting document parts
21072  are placed in the final document.
21073  You have to review and correct the result of the merge.
21074  You'll find the conflicts enclosed in pairs of 
21075 \begin_inset Flex Code
21076 status collapsed
21077
21078 \begin_layout Plain Layout
21079 <<<<<<<
21080 \end_layout
21081
21082 \end_inset
21083
21084  and 
21085 \begin_inset Flex Code
21086 status collapsed
21087
21088 \begin_layout Plain Layout
21089 >>>>>>>
21090 \end_layout
21091
21092 \end_inset
21093
21094  separated by 
21095 \begin_inset Flex Code
21096 status collapsed
21097
21098 \begin_layout Plain Layout
21099 =======
21100 \end_layout
21101
21102 \end_inset
21103
21104 .
21105  The first part is your version as before the update operation with the
21106  document name prepended.
21107  The second one is the repository version with the version number after
21108  the sequence of 
21109 \begin_inset Flex Code
21110 status collapsed
21111
21112 \begin_layout Plain Layout
21113 >
21114 \end_layout
21115
21116 \end_inset
21117
21118  signs.
21119 \end_layout
21120
21121 \begin_layout Labeling
21122 \labelwidthstring 00.00.0000
21123 CVS
21124 \begin_inset space ~
21125 \end_inset
21126
21127 commands: 
21128 \begin_inset space ~
21129 \end_inset
21130
21131
21132 \begin_inset Newline newline
21133 \end_inset
21134
21135
21136 \begin_inset Flex Code
21137 status collapsed
21138
21139 \begin_layout Plain Layout
21140 cd $path; cvs diff 
21141 \family typewriter
21142 "."
21143 \end_layout
21144
21145 \end_inset
21146
21147  (Ask if changes are detected.)
21148 \begin_inset Newline newline
21149 \end_inset
21150
21151
21152 \begin_inset Flex Code
21153 status collapsed
21154
21155 \begin_layout Plain Layout
21156 cd $path; cvs -q update 
21157 \family typewriter
21158 "."
21159 \end_layout
21160
21161 \end_inset
21162
21163
21164 \end_layout
21165
21166 \begin_layout Standard
21167 where 
21168 \begin_inset Flex Code
21169 status collapsed
21170
21171 \begin_layout Plain Layout
21172 $path
21173 \end_layout
21174
21175 \end_inset
21176
21177  stands for the path to the document.
21178 \end_layout
21179
21180 \begin_layout Subsubsection
21181
21182 \family sans
21183 Show History
21184 \end_layout
21185
21186 \begin_layout Standard
21187 This shows the complete history of the CVS document.
21188  The output of 
21189 \family typewriter
21190 cvs log "<file-name>"
21191 \family default
21192  is shown in a browser.
21193 \end_layout
21194
21195 \begin_layout Subsubsection
21196 Revision info
21197 \end_layout
21198
21199 \begin_layout Standard
21200 \SpecialChar LyX
21201  supports CVS version number, author name, date and time of last commit.
21202  All those are extracted from 
21203 \family typewriter
21204 cvs log -r <file-name>
21205 \family default
21206 .
21207  See 
21208 \begin_inset CommandInset ref
21209 LatexCommand ref
21210 reference "subsec:VCS-Revision-Information"
21211
21212 \end_inset
21213
21214  for details.
21215 \end_layout
21216
21217 \begin_layout Subsection
21218 SVN commands in \SpecialChar LyX
21219
21220 \end_layout
21221
21222 \begin_layout Standard
21223 SVN is now partially supported by \SpecialChar LyX
21224 .
21225  You can find the commands in the 
21226 \family sans
21227 File\SpecialChar menuseparator
21228 Version
21229 \begin_inset space ~
21230 \end_inset
21231
21232 Control
21233 \family default
21234  submenu.
21235  Please note that if you use password protected access to repository via
21236  ssh, you will be asked in terminal window.
21237  \SpecialChar LyX
21238  was tested against SVN 1.5, 1.6, 1.7 and 1.8
21239 \begin_inset Foot
21240 status collapsed
21241
21242 \begin_layout Plain Layout
21243 Most of the commands will work with 1.4 too, see 
21244 \begin_inset CommandInset ref
21245 LatexCommand ref
21246 reference "subsec:SVN-Repo-Update"
21247
21248 \end_inset
21249
21250 .
21251  There seems to be currently unresolved permissions problem under SVN 1.8
21252  with reverting changes when file is locked.
21253 \end_layout
21254
21255 \end_inset
21256
21257
21258 \end_layout
21259
21260 \begin_layout Subsubsection
21261
21262 \family sans
21263 Register
21264 \end_layout
21265
21266 \begin_layout Standard
21267 If your document is not under revision control, this is the only item shown
21268  in the menu.
21269  And if it is under revision control, the 
21270 \family sans
21271 Register
21272 \family default
21273  item is not visible.
21274 \end_layout
21275
21276 \begin_layout Standard
21277 This command registers in SVN your document ONLY in case you have already
21278  the documents directory under SVN control (in particular 
21279 \family typewriter
21280 .svn/entries
21281 \family default
21282  file exists).
21283  This means you have to checkout the archive by yourself.
21284 \end_layout
21285
21286 \begin_layout Standard
21287 Then you are asked interactively to supply an initial description of the
21288  document.
21289  Don't forget that registered file is not yet commited.
21290 \end_layout
21291
21292 \begin_layout Standard
21293 SVN command that is run: 
21294 \family typewriter
21295 svn add -q 
21296 \begin_inset Quotes qld
21297 \end_inset
21298
21299 <file-name>
21300 \begin_inset Quotes qld
21301 \end_inset
21302
21303
21304 \end_layout
21305
21306 \begin_layout Standard
21307 Read 
21308 \family typewriter
21309 man svn
21310 \family default
21311  to understand the switches.
21312 \end_layout
21313
21314 \begin_layout Subsubsection
21315
21316 \family sans
21317 Check In Changes
21318 \end_layout
21319
21320 \begin_layout Standard
21321 When you are finished editing a file, you commit your changes.
21322  When you do this, you are asked for a description of the changes.
21323  After that changes are commited.
21324 \end_layout
21325
21326 \begin_layout Standard
21327 SVN command:
21328 \begin_inset Foot
21329 status collapsed
21330
21331 \begin_layout Plain Layout
21332 In case locking is not enabled.
21333  See Section 
21334 \begin_inset CommandInset ref
21335 LatexCommand ref
21336 reference "subsec:SVN-File-Locking"
21337
21338 \end_inset
21339
21340 .
21341 \end_layout
21342
21343 \end_inset
21344
21345  
21346 \family typewriter
21347 svn commit -q -m"<description>" <file-name>
21348 \end_layout
21349
21350 \begin_layout Subsubsection
21351
21352 \family sans
21353 Check Out For Edit
21354 \end_layout
21355
21356 \begin_layout Standard
21357 Updates the changes of this file from the repository.
21358  Be sure you understand SVN merging and conflicts resolving before using
21359  this function, because all conflicts has to be resolved manually by you!
21360 \end_layout
21361
21362 \begin_layout Standard
21363 SVN command:
21364 \begin_inset Foot
21365 status collapsed
21366
21367 \begin_layout Plain Layout
21368 Ditto.
21369 \end_layout
21370
21371 \end_inset
21372
21373  
21374 \family typewriter
21375 svn update --non-interactive 
21376 \begin_inset Quotes qld
21377 \end_inset
21378
21379 <file-name>
21380 \begin_inset Quotes qld
21381 \end_inset
21382
21383
21384 \end_layout
21385
21386 \begin_layout Subsubsection
21387
21388 \family sans
21389 Revert To Repository Version
21390 \end_layout
21391
21392 \begin_layout Standard
21393 This will discard all changes made to the document since the last check
21394  in.
21395  You get a warning before changes are discarded.
21396 \end_layout
21397
21398 \begin_layout Standard
21399 SVN command: 
21400 \family typewriter
21401 svn revert -q 
21402 \begin_inset Quotes qld
21403 \end_inset
21404
21405 <file-name>
21406 \begin_inset Quotes qld
21407 \end_inset
21408
21409
21410 \end_layout
21411
21412 \begin_layout Subsubsection
21413
21414 \family sans
21415 Copy
21416 \end_layout
21417
21418 \begin_layout Standard
21419 This will create a copy of the current document including the version history.
21420  It requires a clean document without any changes since the last checkin.
21421  You are asked for a file name and a description of the copy operation.
21422  After that the copy is created, both locally and in the repository.
21423  If the parent directories of the copied and original document differ, all
21424  relative paths of included files of the copy are adjusted (like in 
21425 \family sans
21426 File\SpecialChar menuseparator
21427 Save As
21428 \family default
21429 \SpecialChar ldots
21430 ).
21431  Finally, the copy is loaded instead of the original document.
21432 \end_layout
21433
21434 \begin_layout Labeling
21435 \labelwidthstring 00.00.0000
21436 SVN
21437 \begin_inset space ~
21438 \end_inset
21439
21440 commands: 
21441 \begin_inset space ~
21442 \end_inset
21443
21444
21445 \begin_inset Newline newline
21446 \end_inset
21447
21448
21449 \begin_inset Flex Code
21450 status collapsed
21451
21452 \begin_layout Plain Layout
21453 svn copy -q 
21454 \family typewriter
21455
21456 \begin_inset Quotes qld
21457 \end_inset
21458
21459 <file-name>
21460 \begin_inset Quotes qld
21461 \end_inset
21462
21463  
21464 \begin_inset Quotes qld
21465 \end_inset
21466
21467 <new-file-name>
21468 \begin_inset Quotes qld
21469 \end_inset
21470
21471
21472 \end_layout
21473
21474 \end_inset
21475
21476
21477 \begin_inset Newline newline
21478 \end_inset
21479
21480
21481 \begin_inset Flex Code
21482 status collapsed
21483
21484 \begin_layout Plain Layout
21485 svn commit
21486 \end_layout
21487
21488 \end_inset
21489
21490
21491 \end_layout
21492
21493 \begin_layout Subsubsection
21494
21495 \family sans
21496 Rename
21497 \end_layout
21498
21499 \begin_layout Standard
21500 This will rename the current document including the version history.
21501  It requires a clean document without any changes since the last checkin.
21502  You are asked for a file name and a description of the rename operation.
21503  After that the document is renamed, both locally and in the repository.
21504  If the parent directories of the new and old file names differ, all relative
21505  paths of included files are adjusted (like in 
21506 \family sans
21507 File\SpecialChar menuseparator
21508 Save As
21509 \family default
21510 \SpecialChar ldots
21511 ).
21512  Finally, the document is reloaded using the new name.
21513 \end_layout
21514
21515 \begin_layout Labeling
21516 \labelwidthstring 00.00.0000
21517 SVN
21518 \begin_inset space ~
21519 \end_inset
21520
21521 commands: 
21522 \begin_inset space ~
21523 \end_inset
21524
21525
21526 \begin_inset Newline newline
21527 \end_inset
21528
21529
21530 \begin_inset Flex Code
21531 status collapsed
21532
21533 \begin_layout Plain Layout
21534 svn move -q 
21535 \family typewriter
21536
21537 \begin_inset Quotes qld
21538 \end_inset
21539
21540 <file-name>
21541 \begin_inset Quotes qld
21542 \end_inset
21543
21544  
21545 \begin_inset Quotes qld
21546 \end_inset
21547
21548 <new-file-name>
21549 \begin_inset Quotes qld
21550 \end_inset
21551
21552
21553 \end_layout
21554
21555 \end_inset
21556
21557
21558 \begin_inset Newline newline
21559 \end_inset
21560
21561
21562 \begin_inset Flex Code
21563 status collapsed
21564
21565 \begin_layout Plain Layout
21566 svn commit
21567 \end_layout
21568
21569 \end_inset
21570
21571
21572 \end_layout
21573
21574 \begin_layout Subsubsection
21575 \begin_inset CommandInset label
21576 LatexCommand label
21577 name "subsec:SVN-Repo-Update"
21578
21579 \end_inset
21580
21581 Update of the local directory checkout from repository
21582 \begin_inset Foot
21583 status collapsed
21584
21585 \begin_layout Plain Layout
21586 Note that this command will work only with subversion 
21587 \begin_inset Formula $\geqq1.5$
21588 \end_inset
21589
21590
21591 \end_layout
21592
21593 \end_inset
21594
21595
21596 \end_layout
21597
21598 \begin_layout Standard
21599 All the commands above have one shortcoming â€“ they deal with the current
21600  document only.
21601  Once your document contains pictures, includes external 
21602 \begin_inset Flex Code
21603 status collapsed
21604
21605 \begin_layout Plain Layout
21606 .tex
21607 \end_layout
21608
21609 \end_inset
21610
21611  files and so on administration becomes more complicated.
21612  \SpecialChar LyX
21613  now supports updating the whole tree in which resides the document
21614 \begin_inset Foot
21615 status collapsed
21616
21617 \begin_layout Plain Layout
21618 One need to organize the files structure so that all external files are
21619  in the same directory or subdirectories of the document.
21620  
21621 \end_layout
21622
21623 \end_inset
21624
21625 .
21626  This become especially useful once you cooperate with people which neither
21627  know about subversion management nor they have ambition to commit additional
21628  material to the repository.
21629  
21630 \end_layout
21631
21632 \begin_layout Standard
21633 \begin_inset Flex Code
21634 status collapsed
21635
21636 \begin_layout Plain Layout
21637 Update local directory from repository
21638 \end_layout
21639
21640 \end_inset
21641
21642  command updates the whole directory and in case of merge conflicts local
21643  version of the files are left, so no unintended data loss occurs.
21644  If local changes are detected user is warned before update starts.
21645 \end_layout
21646
21647 \begin_layout Labeling
21648 \labelwidthstring 00.00.0000
21649 SVN
21650 \begin_inset space ~
21651 \end_inset
21652
21653 commands: 
21654 \begin_inset space ~
21655 \end_inset
21656
21657
21658 \begin_inset Newline newline
21659 \end_inset
21660
21661
21662 \begin_inset Flex Code
21663 status collapsed
21664
21665 \begin_layout Plain Layout
21666 svn diff $path
21667 \end_layout
21668
21669 \end_inset
21670
21671  (Ask if changes are detected.)
21672 \begin_inset Newline newline
21673 \end_inset
21674
21675
21676 \begin_inset Flex Code
21677 status collapsed
21678
21679 \begin_layout Plain Layout
21680 svn update --accept mine-full $path
21681 \end_layout
21682
21683 \end_inset
21684
21685
21686 \end_layout
21687
21688 \begin_layout Standard
21689 where 
21690 \begin_inset Flex Code
21691 status collapsed
21692
21693 \begin_layout Plain Layout
21694 $path
21695 \end_layout
21696
21697 \end_inset
21698
21699  stands for the path to the document.
21700 \end_layout
21701
21702 \begin_layout Subsubsection
21703
21704 \family sans
21705 Show History
21706 \end_layout
21707
21708 \begin_layout Standard
21709 This shows the complete history of the SVN document.
21710  The output of 
21711 \family typewriter
21712 svn log 
21713 \begin_inset Quotes qld
21714 \end_inset
21715
21716 <file-name>
21717 \begin_inset Quotes qld
21718 \end_inset
21719
21720
21721 \family default
21722  is shown in a browser.
21723 \end_layout
21724
21725 \begin_layout Subsubsection
21726 File Locking
21727 \begin_inset CommandInset label
21728 LatexCommand label
21729 name "subsec:SVN-File-Locking"
21730
21731 \end_inset
21732
21733
21734 \end_layout
21735
21736 \begin_layout Standard
21737 The file exchange through various revision control systems brings the problem
21738  of merge conflicts in case two different users try to edit the same (parts
21739  of) document.
21740  When such a conflict happens it needs manual resolving and one reasonable
21741  alternative is to provide some kind of locking mechanism, which guarantees
21742  that only one user is allowed to edit file at the given time.
21743 \end_layout
21744
21745 \begin_layout Standard
21746 SVN has two such mechanisms to provide mutual exclusivity for file access
21747  â€“ locks and automatic setting of write permissions (see sec.
21748  
21749 \begin_inset CommandInset ref
21750 LatexCommand ref
21751 reference "subsec:Automatical-Locking-Property"
21752
21753 \end_inset
21754
21755 ) based on 
21756 \begin_inset Flex Code
21757 status collapsed
21758
21759 \begin_layout Plain Layout
21760 svn:needs-lock
21761 \end_layout
21762
21763 \end_inset
21764
21765  file svn property
21766 \begin_inset Foot
21767 status collapsed
21768
21769 \begin_layout Plain Layout
21770 \begin_inset Flex URL
21771 status open
21772
21773 \begin_layout Plain Layout
21774
21775 http://svnbook.red-bean.com/en/1.2/svn.advanced.locking.html
21776 \end_layout
21777
21778 \end_inset
21779
21780
21781 \end_layout
21782
21783 \end_inset
21784
21785 .
21786  If this property is detected for a given document \SpecialChar LyX
21787  starts to use SVN locks
21788  for document editing automatically and the whole check-in/out mechanism
21789  switches to the same regimen as for RCS.
21790  This in particular means there are two different modes of file use in \SpecialChar LyX
21791 :
21792 \end_layout
21793
21794 \begin_layout Itemize
21795 Unlocked state.
21796  The loaded file is in the read-only mode.
21797  For editing on needs to check-out.
21798  
21799 \emph on
21800 Check-out
21801 \emph default
21802  consists of updating from the repository and gaining write lock.
21803  If the lock is not possible to obtain, we remain in unlocked state.
21804 \end_layout
21805
21806 \begin_layout Itemize
21807 Locked state.
21808  The loaded file is in the 
21809 \begin_inset Quotes els
21810 \end_inset
21811
21812 normal
21813 \begin_inset Quotes ers
21814 \end_inset
21815
21816  edit mode.
21817  No other user is allowed to edit the file.
21818  
21819 \emph on
21820 Check-in
21821 \emph default
21822  consists of commiting changes and releasing write-lock.
21823  If no changes have been made to the document, no commit will be produced
21824 \begin_inset Foot
21825 status collapsed
21826
21827 \begin_layout Plain Layout
21828 Don't be puzzled by the fact that you will be asked for commit message anyway.
21829 \end_layout
21830
21831 \end_inset
21832
21833  and only the write-lock will be released.
21834 \end_layout
21835
21836 \begin_layout Standard
21837 SVN commands:
21838 \end_layout
21839
21840 \begin_layout Labeling
21841 \labelwidthstring 00.00.0000
21842 Check-in:
21843 \family typewriter
21844  svn commit -q -m"<description>" "<file-name>"
21845 \begin_inset Newline newline
21846 \end_inset
21847
21848 svn unlock "<file-name>"
21849 \end_layout
21850
21851 \begin_layout Labeling
21852 \labelwidthstring 00.00.0000
21853 Check-out: 
21854 \family typewriter
21855 svn update "<file-name>"
21856 \begin_inset Newline newline
21857 \end_inset
21858
21859 svn lock "<file-name>"
21860 \end_layout
21861
21862 \begin_layout Subsubsection
21863
21864 \family typewriter
21865 \begin_inset CommandInset label
21866 LatexCommand label
21867 name "subsec:Automatical-Locking-Property"
21868
21869 \end_inset
21870
21871
21872 \family default
21873 Automatic Locking Property
21874 \end_layout
21875
21876 \begin_layout Standard
21877 The above mentioned automatic setting of write permissions of the .lyx file
21878  can be set through
21879 \family sans
21880  File\SpecialChar menuseparator
21881 Version
21882 \begin_inset space ~
21883 \end_inset
21884
21885 Control\SpecialChar menuseparator
21886 Use Locking Property
21887 \family default
21888 .
21889  This command is active only when the file is not locked on the svn server
21890  (i.e.
21891  you need to check-out before proceeding).
21892 \end_layout
21893
21894 \begin_layout Labeling
21895 \labelwidthstring 00.00.0000
21896 SVN
21897 \begin_inset space ~
21898 \end_inset
21899
21900 commands:
21901 \end_layout
21902
21903 \begin_layout Labeling
21904 \labelwidthstring 00.00.0000
21905 Set:
21906 \family typewriter
21907  svn propset svn:needs-lock ON "<file-name>"
21908 \end_layout
21909
21910 \begin_layout Labeling
21911 \labelwidthstring 00.00.0000
21912 Unset: 
21913 \family typewriter
21914 svn propdel svn:needs-lock "<file-name>"
21915 \end_layout
21916
21917 \begin_layout Subsubsection
21918 \begin_inset CommandInset label
21919 LatexCommand label
21920 name "subsec:VCS-Revision-Information"
21921
21922 \end_inset
21923
21924 Revision Information in Documents
21925 \end_layout
21926
21927 \begin_layout Standard
21928 There are more possibilities how to activate revision information in our
21929  document.
21930 \end_layout
21931
21932 \begin_layout Itemize
21933 \SpecialChar LyX
21934  supports directly:
21935 \end_layout
21936
21937 \begin_deeper
21938 \begin_layout Itemize
21939 tree revision information (
21940 \begin_inset Flex Code
21941 status collapsed
21942
21943 \begin_layout Plain Layout
21944 vcs-tree-revision
21945 \end_layout
21946
21947 \end_inset
21948
21949 ).
21950  The result is the output of the 
21951 \begin_inset Flex Code
21952 status collapsed
21953
21954 \begin_layout Plain Layout
21955 svnversion
21956 \end_layout
21957
21958 \end_inset
21959
21960  command, the following table gives you an idea, how to read the results.
21961 \end_layout
21962
21963 \begin_layout Standard
21964 \align center
21965 \begin_inset Tabular
21966 <lyxtabular version="3" rows="6" columns="2">
21967 <features tabularvalignment="middle">
21968 <column alignment="left" valignment="top">
21969 <column alignment="left" valignment="top">
21970 <row>
21971 <cell alignment="left" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
21972 \begin_inset Text
21973
21974 \begin_layout Plain Layout
21975
21976 \series bold
21977 Output
21978 \end_layout
21979
21980 \end_inset
21981 </cell>
21982 <cell alignment="left" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
21983 \begin_inset Text
21984
21985 \begin_layout Plain Layout
21986
21987 \series bold
21988 Meaning
21989 \end_layout
21990
21991 \end_inset
21992 </cell>
21993 </row>
21994 <row>
21995 <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
21996 \begin_inset Text
21997
21998 \begin_layout Plain Layout
21999 4123:4168
22000 \end_layout
22001
22002 \end_inset
22003 </cell>
22004 <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
22005 \begin_inset Text
22006
22007 \begin_layout Plain Layout
22008 mixed revision working copy
22009 \end_layout
22010
22011 \end_inset
22012 </cell>
22013 </row>
22014 <row>
22015 <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
22016 \begin_inset Text
22017
22018 \begin_layout Plain Layout
22019 4168M
22020 \end_layout
22021
22022 \end_inset
22023 </cell>
22024 <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
22025 \begin_inset Text
22026
22027 \begin_layout Plain Layout
22028 modified working copy
22029 \end_layout
22030
22031 \end_inset
22032 </cell>
22033 </row>
22034 <row>
22035 <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
22036 \begin_inset Text
22037
22038 \begin_layout Plain Layout
22039 4123S
22040 \end_layout
22041
22042 \end_inset
22043 </cell>
22044 <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
22045 \begin_inset Text
22046
22047 \begin_layout Plain Layout
22048 switched working copy
22049 \end_layout
22050
22051 \end_inset
22052 </cell>
22053 </row>
22054 <row>
22055 <cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
22056 \begin_inset Text
22057
22058 \begin_layout Plain Layout
22059 4123P
22060 \end_layout
22061
22062 \end_inset
22063 </cell>
22064 <cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
22065 \begin_inset Text
22066
22067 \begin_layout Plain Layout
22068 partial working copy, from a sparse checkout
22069 \end_layout
22070
22071 \end_inset
22072 </cell>
22073 </row>
22074 <row>
22075 <cell alignment="left" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
22076 \begin_inset Text
22077
22078 \begin_layout Plain Layout
22079 4123:4168MS
22080 \end_layout
22081
22082 \end_inset
22083 </cell>
22084 <cell alignment="left" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
22085 \begin_inset Text
22086
22087 \begin_layout Plain Layout
22088 mixed revision, modified, switched working copy
22089 \end_layout
22090
22091 \end_inset
22092 </cell>
22093 </row>
22094 </lyxtabular>
22095
22096 \end_inset
22097
22098
22099 \end_layout
22100
22101 \begin_layout Itemize
22102 file revision information.
22103  The result comes from parsing the output of 
22104 \begin_inset Flex Code
22105 status collapsed
22106
22107 \begin_layout Plain Layout
22108 svn
22109 \begin_inset space ~
22110 \end_inset
22111
22112 info
22113 \begin_inset space ~
22114 \end_inset
22115
22116 --xml
22117 \begin_inset space ~
22118 \end_inset
22119
22120 file.lyx
22121 \end_layout
22122
22123 \end_inset
22124
22125 .
22126  Supported flags are:
22127 \end_layout
22128
22129 \begin_deeper
22130 \begin_layout Itemize
22131 version number of the last commit (
22132 \begin_inset Flex Code
22133 status collapsed
22134
22135 \begin_layout Plain Layout
22136 vcs-revision
22137 \end_layout
22138
22139 \end_inset
22140
22141 )
22142 \end_layout
22143
22144 \begin_layout Itemize
22145 author of the last commit (
22146 \begin_inset Flex Code
22147 status collapsed
22148
22149 \begin_layout Plain Layout
22150 vcs-author
22151 \end_layout
22152
22153 \end_inset
22154
22155 )
22156 \end_layout
22157
22158 \begin_layout Itemize
22159 date of the last commit (
22160 \begin_inset Flex Code
22161 status collapsed
22162
22163 \begin_layout Plain Layout
22164 vcs-date
22165 \end_layout
22166
22167 \end_inset
22168
22169 )
22170 \end_layout
22171
22172 \begin_layout Itemize
22173 time of the last commit (
22174 \begin_inset Flex Code
22175 status collapsed
22176
22177 \begin_layout Plain Layout
22178 vcs-time
22179 \end_layout
22180
22181 \end_inset
22182
22183 )
22184 \end_layout
22185
22186 \end_deeper
22187 \begin_layout Standard
22188 You can obtain this info via InsetInfo (e.g.
22189  
22190 \begin_inset Flex Code
22191 status collapsed
22192
22193 \begin_layout Plain Layout
22194 info-insert buffer vcs-date
22195 \end_layout
22196
22197 \end_inset
22198
22199 ).
22200  The information will be available only when you have the file stored under
22201  svn managment (i.e.
22202  the 
22203 \begin_inset Flex Code
22204 status collapsed
22205
22206 \begin_layout Plain Layout
22207 .svn
22208 \end_layout
22209
22210 \end_inset
22211
22212  directory is available with your document).
22213 \end_layout
22214
22215 \end_deeper
22216 \begin_layout Itemize
22217 Another—a hacking one—possibility is to use svn keywords
22218 \begin_inset Foot
22219 status collapsed
22220
22221 \begin_layout Plain Layout
22222 http://svnbook.red-bean.com/en/1.4/svn.advanced.props.special.keywords.html
22223 \end_layout
22224
22225 \end_inset
22226
22227 .
22228  In short â€“ you set file keywords property (e.g.
22229  
22230 \family sans
22231 svn propset svn:keywords 'Rev' file.lyx
22232 \family default
22233 ) and then paste keyword \SpecialChar TeX
22234  code
22235 \begin_inset Foot
22236 status collapsed
22237
22238 \begin_layout Plain Layout
22239 This is an easy way how to ensure that \SpecialChar LyX
22240  won't break the line in the middle
22241  of keyword tag.
22242 \end_layout
22243
22244 \end_inset
22245
22246  tag in your document (e.g.
22247  
22248 \begin_inset Flex Code
22249 status collapsed
22250
22251 \begin_layout Plain Layout
22252 $Rev$
22253 \end_layout
22254
22255 \end_inset
22256
22257 ).
22258  This way svn client will automatically substitute revision number (e.g.
22259  
22260 \begin_inset Flex Code
22261 status collapsed
22262
22263 \begin_layout Plain Layout
22264 $Rev: 59 $
22265 \end_layout
22266
22267 \end_inset
22268
22269 ) after each update and commit.
22270  There are more problems with this approach.
22271  Firstly, the '$' character is used in \SpecialChar TeX
22272  world for math equations, so any
22273  occurence of math formula 
22274 \begin_inset Formula $Rev$
22275 \end_inset
22276
22277  become 
22278 \begin_inset Formula $Rev:59$
22279 \end_inset
22280
22281  in your \SpecialChar LyX
22282  document.
22283  Similarly for other keywords like Id, Date, Author, etc.
22284  Secondly svn output is dependent on your locales, so its very easy that
22285  svn would produce some problematic strings once Date is used.
22286  Thirdly you get the whole 'Rev: 59' string in your document instead of
22287  the plain number.
22288  Until subversion implements user's custom keywords it will be hard to use
22289  this approach reliably or let \SpecialChar LyX
22290  to support it directly.
22291 \end_layout
22292
22293 \begin_layout Subsection
22294 SVN and Windows Environment
22295 \end_layout
22296
22297 \begin_layout Quote
22298 My inclination is to say that if the user cannot figure out the command
22299  line operations on their own fairly quickly, they would be well advised
22300  to use TortoiseSVN.
22301  â€”P.
22302  A.
22303  Rubin
22304 \end_layout
22305
22306 \begin_layout Subsubsection
22307 Preparation
22308 \end_layout
22309
22310 \begin_layout Standard
22311 In addition to installing \SpecialChar LyX
22312 , and having access to a Subversion repository,
22313  the user will need to install the Subversion client program.
22314  A Windows installer for the client program is available from 
22315 \begin_inset CommandInset href
22316 LatexCommand href
22317 name "CollabNet"
22318 target "http://www.collab.net/nonav/downloads/subversion/"
22319 literal "false"
22320
22321 \end_inset
22322
22323 .
22324  The user may also want to install 
22325 \begin_inset CommandInset href
22326 LatexCommand href
22327 name "TortoiseSVN"
22328 target "http://tortoisesvn.tigris.org/"
22329 literal "false"
22330
22331 \end_inset
22332
22333 , which integrates Subversion operations into the context (rightclick) menu
22334  of Windows Explorer.
22335  Operations done outside \SpecialChar LyX
22336  will typically be more convenient using the Explorer
22337  context menu.
22338  Note that TortoiseSVN is not a replacement for the client program, which
22339  is what \SpecialChar LyX
22340  itself will use.
22341 \end_layout
22342
22343 \begin_layout Subsubsection
22344 Bringing a document under Subversion control
22345 \end_layout
22346
22347 \begin_layout Standard
22348 Before a \SpecialChar LyX
22349  document can be brought under version control in Subversion, its
22350  parent directory needs to be under version control.
22351  If the document is being added to a project already in the repository,
22352  this is accomplished by checking the project out to the directory where
22353  the new document will be placed.
22354  If the project itself is not yet under version control (for instance, if
22355  this document starts a new project), the directory must be imported into
22356  the repository.
22357  This is done outside \SpecialChar LyX
22358 .
22359  Both import and checkout are easily accomplished from the Explorer context
22360  menu using TortoiseSVN, or alternatively can be done using the command
22361  line client at a DOS prompt.
22362  The procedure for importing the project using TortoiseSVN is described
22363  below, assuming an existing repository and a new project being started
22364  in 
22365 \family typewriter
22366 C:
22367 \backslash
22368 new project
22369 \family default
22370 .
22371  For information on using the Subversion client program, run 
22372 \family typewriter
22373 svn --help 
22374 \family default
22375 in a DOS shell.
22376 \end_layout
22377
22378 \begin_layout Enumerate
22379 Locate 
22380 \family typewriter
22381 C:
22382 \backslash
22383 new project 
22384 \family default
22385 in Windows Explorer, right click it, and select 
22386 \family sans
22387 TortoiseSVN\SpecialChar menuseparator
22388 Repo-browser
22389 \family default
22390 .
22391  If necessary, adjust the URL for the repository, then click OK.
22392 \end_layout
22393
22394 \begin_layout Enumerate
22395 Right click the level of the repository under which you want to place the
22396  new project folder (typically the top level) and click 
22397 \family sans
22398 Create folder
22399 \family default
22400  Supply a name for the project folder and click OK.
22401  Add a message for the log file if desired, then click OK again.
22402  The new project folder should appear in the repository.
22403  Finally, click OK again to exit the repository browser.
22404 \end_layout
22405
22406 \begin_layout Enumerate
22407 Once again right click 
22408 \family typewriter
22409 C:
22410 \backslash
22411 new project
22412 \family default
22413 , this time selecting SVN Checkout\SpecialChar ldots
22414  Select the URL of the project folder
22415  you just created in the repository, and set the checkout directory to 
22416 \family typewriter
22417 C:
22418 \backslash
22419 new project.
22420
22421 \family default
22422  Click OK.
22423  You will be warned about a non-empty folder; click OK to proceed.
22424  You should now have a 
22425 \family typewriter
22426 .svn
22427 \family default
22428  directory under 
22429 \family typewriter
22430 C:
22431 \backslash
22432 new project.
22433 \end_layout
22434
22435 \begin_layout Enumerate
22436 Create or open your document in \SpecialChar LyX
22437  and click 
22438 \family sans
22439 File\SpecialChar menuseparator
22440 Version
22441 \begin_inset space ~
22442 \end_inset
22443
22444 Control\SpecialChar menuseparator
22445 Register.
22446  
22447 \family default
22448 Add a log message and click OK to commit the document to version control.
22449 \end_layout
22450
22451 \begin_layout Standard
22452 From this point onward, you should have full functionality in the 
22453 \family sans
22454 File\SpecialChar menuseparator
22455 Version
22456 \begin_inset space ~
22457 \end_inset
22458
22459 Control
22460 \family default
22461  menu.
22462  You also have the option of checking the document in and out, viewing its
22463  history, etc.
22464  using the TortoiseSVN context menu in Windows Explorer or the Subversion
22465  client program from a command prompt.
22466 \end_layout
22467
22468 \begin_layout Subsubsection
22469 SSH tunnel used with SVN under Windows
22470 \end_layout
22471
22472 \begin_layout Standard
22473 Compared with Linux setting up an svn client to communicate over ssh under
22474  Windows is a rather troublesome task.
22475  We will at least offer some hints how to setup the client side but prior
22476  knowledge about ssh and the Windows command line is needed, also be prepared
22477  for a great deal of frustration\SpecialChar ldots
22478
22479 \end_layout
22480
22481 \begin_layout Enumerate
22482 Get an svn client for windows, as described in the previous sections.
22483  When it is a fresh install run some svn command (e.g.
22484  
22485 \begin_inset Flex Code
22486 status collapsed
22487
22488 \begin_layout Plain Layout
22489 svn --version
22490 \end_layout
22491
22492 \end_inset
22493
22494 ) to create config files, which you will need to change later on.
22495 \end_layout
22496
22497 \begin_layout Enumerate
22498 Choose an ssh client for Windows.
22499  There are several possibilities, we will use the one from Putty tools
22500 \begin_inset Foot
22501 status collapsed
22502
22503 \begin_layout Plain Layout
22504 \begin_inset Flex URL
22505 status collapsed
22506
22507 \begin_layout Plain Layout
22508
22509 http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html
22510 \end_layout
22511
22512 \end_inset
22513
22514
22515 \end_layout
22516
22517 \end_inset
22518
22519 .
22520  You will need to set the connection up so that the client doesn't ask for
22521  any password from you.
22522  To keep things easy we will use only keys without any additional password
22523  protection etc.
22524 \end_layout
22525
22526 \begin_deeper
22527 \begin_layout Enumerate
22528 Generate keys by 
22529 \begin_inset Flex Code
22530 status collapsed
22531
22532 \begin_layout Plain Layout
22533 puttygen
22534 \end_layout
22535
22536 \end_inset
22537
22538 .
22539  Save your private .ppk key file and put the public one on the server side.
22540  If the SVN server runs on Linux, note that the format of the public key
22541  is not compatible with Linux openssh and you will need to direcly copy-paste
22542  the key from the 
22543 \begin_inset Quotes eld
22544 \end_inset
22545
22546
22547 \emph on
22548 Public key for pasting into OpenSSH authorized_keys file
22549 \emph default
22550 :
22551 \begin_inset Quotes erd
22552 \end_inset
22553
22554  edit field into the server's 
22555 \begin_inset Flex Code
22556 status collapsed
22557
22558 \begin_layout Plain Layout
22559 ~/.ssh/authorized_keys
22560 \end_layout
22561
22562 \end_inset
22563
22564  / 
22565 \begin_inset Flex Code
22566 status collapsed
22567
22568 \begin_layout Plain Layout
22569 authorized_keys2
22570 \end_layout
22571
22572 \end_inset
22573
22574  file.
22575 \end_layout
22576
22577 \begin_layout Enumerate
22578 Get the Putty's 
22579 \begin_inset Flex Code
22580 status collapsed
22581
22582 \begin_layout Plain Layout
22583 plink
22584 \end_layout
22585
22586 \end_inset
22587
22588 .
22589  In the SVN config file
22590 \begin_inset Foot
22591 status collapsed
22592
22593 \begin_layout Plain Layout
22594 Exact path depends on Windows version, usually somewhere around 
22595 \begin_inset Flex Code
22596 status collapsed
22597
22598 \begin_layout Plain Layout
22599 c:
22600 \backslash
22601 Documents and Settings
22602 \backslash
22603 user
22604 \backslash
22605 Application Data
22606 \backslash
22607 Subversion
22608 \backslash
22609 config
22610 \end_layout
22611
22612 \end_inset
22613
22614  / 
22615 \begin_inset Flex Code
22616 status collapsed
22617
22618 \begin_layout Plain Layout
22619 AppData
22620 \backslash
22621 Roaming
22622 \backslash
22623 Subversion
22624 \end_layout
22625
22626 \end_inset
22627
22628 .
22629 \end_layout
22630
22631 \end_inset
22632
22633 , section [tunnels], setup ssh command, e.g.
22634  
22635 \begin_inset Flex Code
22636 status collapsed
22637
22638 \begin_layout Plain Layout
22639 ssh=c:/path/plink.exe -i c:/path/private_key.ppk
22640 \end_layout
22641
22642 \end_inset
22643
22644 .
22645 \begin_inset Foot
22646 status collapsed
22647
22648 \begin_layout Plain Layout
22649 It will usually take a lot of time to get exact command right and it depends
22650  on many things.
22651  For example do not have some remote server saved as a default session in
22652  Putty etc.
22653  If things fail, try to connect via plink without SVN first.
22654 \end_layout
22655
22656 \end_inset
22657
22658
22659 \end_layout
22660
22661 \end_deeper
22662 \begin_layout Enumerate
22663 Checkout the SVN archive, e.
22664 \begin_inset space \thinspace{}
22665 \end_inset
22666
22667 g.
22668 \begin_inset Newline newline
22669 \end_inset
22670
22671
22672 \begin_inset Flex Code
22673 status collapsed
22674
22675 \begin_layout Plain Layout
22676 svn co svn+ssh://user@server/repository_path
22677 \end_layout
22678
22679 \end_inset
22680
22681 .
22682 \end_layout
22683
22684 \begin_layout Subsubsection
22685 End-of-Line Conversions
22686 \end_layout
22687
22688 \begin_layout Standard
22689 When the collaborators are mixing Linux and Windows environments, \SpecialChar LyX
22690  will
22691  use different line endings inside the .lyx files.
22692  This is not a problem as far as \SpecialChar LyX
22693  functionality is concerned, but the commit
22694  diffs will be huge and merge-conflicts prone.
22695  Fortunately SVN itself knows
22696 \begin_inset Foot
22697 status collapsed
22698
22699 \begin_layout Plain Layout
22700 \begin_inset Flex URL
22701 status collapsed
22702
22703 \begin_layout Plain Layout
22704
22705 http://svnbook.red-bean.com/en/1.4/svn.advanced.props.file-portability.html
22706 \end_layout
22707
22708 \end_inset
22709
22710
22711 \end_layout
22712
22713 \end_inset
22714
22715  how to deal with CR/LF problems when switching .lyx files to the 
22716 \begin_inset Flex Code
22717 status collapsed
22718
22719 \begin_layout Plain Layout
22720 native
22721 \end_layout
22722
22723 \end_inset
22724
22725  mode.
22726 \begin_inset Foot
22727 status collapsed
22728
22729 \begin_layout Plain Layout
22730 For the lazy guys: 
22731 \begin_inset Flex Code
22732 status collapsed
22733
22734 \begin_layout Plain Layout
22735 svn propset svn:eol-style native FILE_NAME
22736 \end_layout
22737
22738 \end_inset
22739
22740
22741 \end_layout
22742
22743 \end_inset
22744
22745
22746 \end_layout
22747
22748 \begin_layout Subsection
22749 GIT commands in \SpecialChar LyX
22750
22751 \end_layout
22752
22753 \begin_layout Standard
22754 A minimal subset of GIT commands is now supported by \SpecialChar LyX
22755 .
22756  You can find the commands in the 
22757 \family sans
22758 File\SpecialChar menuseparator
22759 Version
22760 \begin_inset space ~
22761 \end_inset
22762
22763 Control
22764 \family default
22765  submenu.
22766  Please note that if you use password protected access to repository via
22767  ssh, you will be asked in terminal window.
22768  \SpecialChar LyX
22769  was tested against GIT 1.7.
22770 \begin_inset Foot
22771 status collapsed
22772
22773 \begin_layout Plain Layout
22774 Windows users please note that you need to ensure that git is on the path.
22775  This can be set from within \SpecialChar LyX
22776  at 
22777 \family sans
22778 Tools\SpecialChar menuseparator
22779 Preferences\SpecialChar menuseparator
22780 Paths\SpecialChar menuseparator
22781 PATH prefix
22782 \family default
22783 .
22784 \end_layout
22785
22786 \end_inset
22787
22788
22789 \end_layout
22790
22791 \begin_layout Standard
22792 One big difference of GIT and the other supported version control systems
22793  is the distributed nature of GIT: With traditional version control systems
22794  there is one central server which hosts the repository.
22795  Users commit their changes to the server, and get updates made by other
22796  users from it.
22797  With GIT, users commit to a local repository.
22798  The local repository can be synchronized with one or more remote repositories
22799  using the 
22800 \begin_inset Flex Code
22801 status collapsed
22802
22803 \begin_layout Plain Layout
22804 pull
22805 \end_layout
22806
22807 \end_inset
22808
22809  and 
22810 \begin_inset Flex Code
22811 status collapsed
22812
22813 \begin_layout Plain Layout
22814 push
22815 \end_layout
22816
22817 \end_inset
22818
22819  GIT commands.
22820  \SpecialChar LyX
22821  does not interact in any way with remote GIT repositories.
22822  It works exclusively with the local repository in a very similar way as
22823  with a central CVS or SVN repository.
22824  If you use remote GIT repositories you need to do the 
22825 \begin_inset Flex Code
22826 status collapsed
22827
22828 \begin_layout Plain Layout
22829 pull
22830 \end_layout
22831
22832 \end_inset
22833
22834  and 
22835 \begin_inset Flex Code
22836 status collapsed
22837
22838 \begin_layout Plain Layout
22839 push
22840 \end_layout
22841
22842 \end_inset
22843
22844  operations with your favourite GIT client.
22845 \end_layout
22846
22847 \begin_layout Subsubsection
22848
22849 \family sans
22850 Register
22851 \end_layout
22852
22853 \begin_layout Standard
22854 If your document is not under revision control, this is the only item shown
22855  in the menu.
22856  And if it is under revision control, the 
22857 \family sans
22858 Register
22859 \family default
22860  item is not visible.
22861 \end_layout
22862
22863 \begin_layout Standard
22864 This command registers in GIT your document ONLY in case you have already
22865  the documents directory under GIT control (in particular 
22866 \family typewriter
22867 .git/index
22868 \family default
22869  file exists).
22870  This means you have to checkout the archive by yourself.
22871 \end_layout
22872
22873 \begin_layout Standard
22874 Then you are asked interactively to supply an initial description of the
22875  document.
22876  Don't forget that registered file is not yet committed.
22877 \end_layout
22878
22879 \begin_layout Standard
22880 GIT command that is run: 
22881 \family typewriter
22882 git add 
22883 \begin_inset Quotes qld
22884 \end_inset
22885
22886 <file-name>
22887 \begin_inset Quotes qld
22888 \end_inset
22889
22890
22891 \end_layout
22892
22893 \begin_layout Standard
22894 Read 
22895 \family typewriter
22896 man git
22897 \family default
22898  to understand the switches.
22899 \end_layout
22900
22901 \begin_layout Subsubsection
22902
22903 \family sans
22904 Check In Changes
22905 \end_layout
22906
22907 \begin_layout Standard
22908 When you are finished editing a file, you commit your changes.
22909  When you do this, you are asked for a description of the changes.
22910  After that changes are committed.
22911 \end_layout
22912
22913 \begin_layout Standard
22914 GIT command: 
22915 \family typewriter
22916 git commit -q -m"<description>" <file-name>
22917 \end_layout
22918
22919 \begin_layout Subsubsection
22920
22921 \family sans
22922 Revert To Repository Version
22923 \end_layout
22924
22925 \begin_layout Standard
22926 This will discard all changes made to the document since the last check
22927  in.
22928  You get a warning before changes are discarded.
22929 \end_layout
22930
22931 \begin_layout Standard
22932 GIT command: 
22933 \family typewriter
22934 git checkout -q 
22935 \begin_inset Quotes qld
22936 \end_inset
22937
22938 <file-name>
22939 \begin_inset Quotes qld
22940 \end_inset
22941
22942
22943 \end_layout
22944
22945 \begin_layout Subsubsection
22946
22947 \family sans
22948 Rename
22949 \end_layout
22950
22951 \begin_layout Standard
22952 This will rename the current document including the version history.
22953  It requires a clean document without any changes since the last checkin.
22954  You are asked for a file name and a description of the rename operation.
22955  After that the document is renamed, both locally and in the repository.
22956  If the parent directories of the new and old file names differ, all relative
22957  paths of included files are adjusted (like in 
22958 \family sans
22959 File\SpecialChar menuseparator
22960 Save As
22961 \family default
22962 \SpecialChar ldots
22963 ).
22964  Finally, the document is reloaded using the new name.
22965 \end_layout
22966
22967 \begin_layout Labeling
22968 \labelwidthstring 00.00.0000
22969 GIT
22970 \begin_inset space ~
22971 \end_inset
22972
22973 commands: 
22974 \begin_inset space ~
22975 \end_inset
22976
22977
22978 \begin_inset Newline newline
22979 \end_inset
22980
22981
22982 \begin_inset Flex Code
22983 status collapsed
22984
22985 \begin_layout Plain Layout
22986 git mv 
22987 \family typewriter
22988
22989 \begin_inset Quotes qld
22990 \end_inset
22991
22992 <file-name>
22993 \begin_inset Quotes qld
22994 \end_inset
22995
22996  
22997 \begin_inset Quotes qld
22998 \end_inset
22999
23000 <new-file-name>
23001 \begin_inset Quotes qld
23002 \end_inset
23003
23004
23005 \end_layout
23006
23007 \end_inset
23008
23009
23010 \begin_inset Newline newline
23011 \end_inset
23012
23013
23014 \begin_inset Flex Code
23015 status collapsed
23016
23017 \begin_layout Plain Layout
23018 git commit
23019 \end_layout
23020
23021 \end_inset
23022
23023
23024 \end_layout
23025
23026 \begin_layout Subsubsection
23027
23028 \family sans
23029 Show History
23030 \end_layout
23031
23032 \begin_layout Standard
23033 This shows the complete history of the GIT document.
23034  The output of 
23035 \family typewriter
23036 git log 
23037 \begin_inset Quotes qld
23038 \end_inset
23039
23040 <file-name>
23041 \begin_inset Quotes qld
23042 \end_inset
23043
23044
23045 \family default
23046  is shown in a browser.
23047 \end_layout
23048
23049 \begin_layout Subsubsection
23050 Version Info
23051 \end_layout
23052
23053 \begin_layout Standard
23054 \SpecialChar LyX
23055  supports GIT hash number of the last commit to the file, author name, date
23056  and time of last commit.
23057  All those are extracted from 
23058 \family typewriter
23059 git log -n 1 --pretty=format:%H%n%an%n%ai
23060 \family default
23061 .
23062  Tree version information is obtained via 
23063 \family typewriter
23064 git describe --abbrev --dirty --long
23065 \family default
23066 .
23067  See 
23068 \begin_inset CommandInset ref
23069 LatexCommand ref
23070 reference "subsec:VCS-Revision-Information"
23071
23072 \end_inset
23073
23074  for other details.
23075 \end_layout
23076
23077 \begin_layout Subsection
23078 Further tuning
23079 \end_layout
23080
23081 \begin_layout Standard
23082 With the recent addition of the 
23083 \begin_inset Flex Code
23084 status collapsed
23085
23086 \begin_layout Plain Layout
23087 vc-command
23088 \end_layout
23089
23090 \end_inset
23091
23092  function \SpecialChar LyX
23093  power users are allowed to create their own commands for revision
23094  control.
23095 \end_layout
23096
23097 \begin_layout Standard
23098 As an example you can see how two TortoiseSVN commands could be integrated
23099  directly:
23100 \end_layout
23101
23102 \begin_layout Description
23103 Commit: 
23104 \begin_inset Flex Code
23105 status collapsed
23106
23107 \begin_layout Plain Layout
23108 vc-command DR "." "TortoiseProc /command:commit /path:$$p"
23109 \end_layout
23110
23111 \end_inset
23112
23113
23114 \end_layout
23115
23116 \begin_layout Description
23117 Revert: 
23118 \begin_inset Flex Code
23119 status collapsed
23120
23121 \begin_layout Plain Layout
23122 vc-command DR "." "TortoiseProc /command:revert /path:$$p"
23123 \end_layout
23124
23125 \end_inset
23126
23127
23128 \end_layout
23129
23130 \begin_layout Subsection
23131 Version control and Document comparison
23132 \end_layout
23133
23134 \begin_layout Standard
23135 One of the typical uses of version control is to inspect the changes between
23136  revisions, usually by creating 
23137 \begin_inset Flex Code
23138 status collapsed
23139
23140 \begin_layout Plain Layout
23141 diff
23142 \end_layout
23143
23144 \end_inset
23145
23146  dumps.
23147  While this is useful for plain text files, it is much less useful in the
23148  case of \SpecialChar LyX
23149  files, which have more a complicated structure.
23150  Hence we provide binding to the Document comparison feature.
23151  There are two ways of calling this feature â€“ either by direct call of 
23152 \begin_inset Flex Code
23153 status collapsed
23154
23155 \begin_layout Plain Layout
23156 vc-compare
23157 \end_layout
23158
23159 \end_inset
23160
23161  \SpecialChar LyX
23162  function (for details see \SpecialChar LyX
23163  functions manual) or by the toolbar icon 
23164 \begin_inset Info
23165 type  "icon"
23166 arg   "vc-compare"
23167 \end_inset
23168
23169  or the menu item 
23170 \begin_inset Info
23171 type  "menu"
23172 arg   "vc-compare"
23173 \end_inset
23174
23175 , respectively.
23176  One can either compare two chosen revisions of the document or he can simply
23177  compare the current version of edited text with older revisions (where
23178  '
23179 \begin_inset Flex Noun
23180 status collapsed
23181
23182 \begin_layout Plain Layout
23183 0
23184 \end_layout
23185
23186 \end_inset
23187
23188 ' revisions back means comparison of the edited file with last commited
23189  revision).
23190  
23191 \end_layout
23192
23193 \begin_layout Standard
23194 This feature is supported for SVN and RCS though due to the more complicated
23195  versioning scheme of RCS there is a constraint â€“ when addressing the revisions
23196  in dialog, numbers always point to the last number in RCS revision number,
23197  i.e.
23198  '35' in '1.2.35'.
23199  We don't currently support GIT addressing of revisions, one can just compare
23200  edited document with its revision X steps backs, where X is addressed as
23201  
23202 \begin_inset Flex Code
23203 status collapsed
23204
23205 \begin_layout Plain Layout
23206 HEAD~X
23207 \end_layout
23208
23209 \end_inset
23210
23211 .
23212 \end_layout
23213
23214 \begin_layout Section
23215 Literate Programming
23216 \end_layout
23217
23218 \begin_layout Standard
23219 Updated by 
23220 \noun on
23221 Kayvan Sylvan 
23222 \noun default
23223 (kayvan@sylvan.com)
23224 \noun on
23225
23226 \noun default
23227 original documentation written by 
23228 \noun on
23229 Edmar Wienskoski Jr.
23230
23231 \noun default
23232  (edmar-w-jr@technologist.com)
23233 \end_layout
23234
23235 \begin_layout Subsection
23236 Introduction
23237 \end_layout
23238
23239 \begin_layout Standard
23240 The main purpose of this documentation is to show you how to use \SpecialChar LyX
23241  for literate
23242  programming, where it is assumed that you are familiar with this programming
23243  technique, and know what 
23244 \begin_inset Quotes eld
23245 \end_inset
23246
23247 tangling
23248 \begin_inset Quotes erd
23249 \end_inset
23250
23251  and 
23252 \begin_inset Quotes eld
23253 \end_inset
23254
23255 weaving
23256 \begin_inset Quotes erd
23257 \end_inset
23258
23259  means.
23260  If that is not the case, please follow the web links provided in the following
23261  sections.
23262  There is a lot of good documentation out there covering old development
23263  history to the latest tools tips.
23264 \end_layout
23265
23266 \begin_layout Standard
23267 It is also assumed that you are familiar with \SpecialChar LyX
23268  itself to a point that you
23269  are comfortable changing your \SpecialChar LyX
23270  preferences, and X resources file.
23271  If that is not the case please refer to other \SpecialChar LyX
23272  documentation to cover your
23273  specific needs.
23274 \end_layout
23275
23276 \begin_layout Subsection
23277 Literate Programming
23278 \end_layout
23279
23280 \begin_layout Standard
23281 From the Literate Programming FAQ: 
23282 \end_layout
23283
23284 \begin_layout Quotation
23285 Literate programming is the combination of documentation and source together
23286  in a fashion suited for reading by human beings.
23287  In fact, literate programs should be enjoyable reading, even inviting!
23288  (Sorry Bob, I couldn't resist!) In general, literate programs combine source
23289  and documentation in a single file.
23290  Literate programming tools then parse the file to produce either readable
23291  documentation or compilable source.
23292  The WEB style of literate programming was created by D.
23293 \begin_inset space \thinspace{}
23294 \end_inset
23295
23296 E.
23297  Knuth during the development of his \SpecialChar TeX
23298  typesetting software.
23299  
23300 \end_layout
23301
23302 \begin_layout Standard
23303 Another excerpt says:
23304 \end_layout
23305
23306 \begin_layout Quotation
23307
23308 \emph on
23309 How is literate programming different from verbose commenting?
23310 \end_layout
23311
23312 \begin_layout Quotation
23313 There are three distinguishing characteristics.
23314  In order of importance, they are: 
23315 \end_layout
23316
23317 \begin_deeper
23318 \begin_layout Itemize
23319 flexible order of elaboration 
23320 \end_layout
23321
23322 \begin_layout Itemize
23323 automatic support for browsing 
23324 \end_layout
23325
23326 \begin_layout Itemize
23327 typeset documentation, especially diagrams and mathematics 
23328 \end_layout
23329
23330 \end_deeper
23331 \begin_layout Standard
23332 Now that I sparked your curiosity, take a look in the references.
23333 \end_layout
23334
23335 \begin_layout Subsubsection
23336 References
23337 \end_layout
23338
23339 \begin_layout Standard
23340 The complete Literate Programming FAQ can be found at:
23341 \end_layout
23342
23343 \begin_layout Quote
23344 Literate Programming FAQ 
23345 \begin_inset Flex URL
23346 status open
23347
23348 \begin_layout Plain Layout
23349
23350 http://www.literateprogramming.com/lpfaq.pdf
23351 \end_layout
23352
23353 \end_inset
23354
23355
23356 \end_layout
23357
23358 \begin_layout Standard
23359 The FAQ lists 23 (twenty three!) different literate programming tools.
23360  Where some are specialized or 
23361 \begin_inset Quotes eld
23362 \end_inset
23363
23364 tailored
23365 \begin_inset Quotes erd
23366 \end_inset
23367
23368  for particular programming languages, while other have general scope.
23369  I selected 
23370 \noun on
23371 Noweb
23372 \noun default
23373  for my own use for several reasons:
23374 \end_layout
23375
23376 \begin_layout Itemize
23377 It can generate the documentation either in \SpecialChar LaTeX
23378  or HTML.
23379 \end_layout
23380
23381 \begin_layout Itemize
23382 It has a open architecture, i.
23383 \begin_inset space \thinspace{}
23384 \end_inset
23385
23386 e.
23387 \begin_inset space \space{}
23388 \end_inset
23389
23390 it is easy to plug in new filters
23391 \begin_inset Foot
23392 status collapsed
23393
23394 \begin_layout Plain Layout
23395
23396 \emph on
23397 Filters 
23398 \emph default
23399 are programs that read a given data stream and output a manipulated data
23400  stream.
23401  That way, a WEB file (consisting of literate code) can be turned into a
23402  file consisting only of C program code or \SpecialChar LaTeX
23403  code.
23404 \end_layout
23405
23406 \end_inset
23407
23408  and to perform special processing that you may need.
23409  
23410 \end_layout
23411
23412 \begin_layout Itemize
23413 There is a good selection of filters available already (the HTML is one
23414  of them).
23415 \end_layout
23416
23417 \begin_layout Itemize
23418 It is free.
23419 \end_layout
23420
23421 \begin_layout Standard
23422 The Noweb web page can be found at: 
23423 \end_layout
23424
23425 \begin_layout Quote
23426 Noweb home page 
23427 \begin_inset Flex URL
23428 status collapsed
23429
23430 \begin_layout Plain Layout
23431
23432 https://www.cs.tufts.edu/~nr/noweb/
23433 \end_layout
23434
23435 \end_inset
23436
23437
23438 \end_layout
23439
23440 \begin_layout Standard
23441 Starting from there you can reach many other interesting links and even
23442  some literate program examples.
23443 \end_layout
23444
23445 \begin_layout Subsection
23446 \SpecialChar LyX
23447  and Literate Programming with Noweb
23448 \end_layout
23449
23450 \begin_layout Standard
23451 The \SpecialChar LyX
23452  support for Literate Programming is provided by using the generic \SpecialChar LyX
23453
23454  converters mechanism.
23455  This support is provided in a 
23456 \begin_inset Quotes eld
23457 \end_inset
23458
23459 Noweb independent
23460 \begin_inset Quotes erd
23461 \end_inset
23462
23463  way, i.
23464 \begin_inset space \thinspace{}
23465 \end_inset
23466
23467 e.
23468 \begin_inset space \space{}
23469 \end_inset
23470
23471 you will be able to use this new \SpecialChar LyX
23472  feature with some other literate programming
23473  tool of your choice by just changing your \SpecialChar LyX
23474  preferences.
23475 \end_layout
23476
23477 \begin_layout Subsubsection
23478 Generating documents and code (weaving and tangling)
23479 \end_layout
23480
23481 \begin_layout Paragraph
23482 Using the noweb module
23483 \end_layout
23484
23485 \begin_layout Standard
23486 If you have installed Noweb and \SpecialChar LyX
23487  successfully, whenever you open a new document,
23488  after you have chosen its document class, use the 
23489 \family sans
23490 Document\SpecialChar menuseparator
23491 Settings
23492 \family default
23493  menu to add the 
23494 \begin_inset Quotes eld
23495 \end_inset
23496
23497 noweb
23498 \begin_inset Quotes erd
23499 \end_inset
23500
23501  module.
23502  If Noweb is correctly installed, when you click on the 
23503 \begin_inset Quotes eld
23504 \end_inset
23505
23506 Modules
23507 \begin_inset Quotes erd
23508 \end_inset
23509
23510  link, you will see the 
23511 \begin_inset Quotes eld
23512 \end_inset
23513
23514 noweb
23515 \begin_inset Quotes erd
23516 \end_inset
23517
23518  module in the available list and you can add it to your document.
23519 \end_layout
23520
23521 \begin_layout Paragraph
23522 Typing code in
23523 \end_layout
23524
23525 \begin_layout Standard
23526 \SpecialChar LyX
23527  enables you to write code with a custom inset named 
23528 \begin_inset Flex Noun
23529 status collapsed
23530
23531 \begin_layout Plain Layout
23532 Chunk
23533 \end_layout
23534
23535 \end_inset
23536
23537 .
23538  Noweb delimits chunks like this:
23539 \end_layout
23540
23541 \begin_layout LyX-Code
23542 <<My code>>=
23543 \end_layout
23544
23545 \begin_layout LyX-Code
23546   code
23547 \end_layout
23548
23549 \begin_layout LyX-Code
23550   more code
23551 \end_layout
23552
23553 \begin_layout LyX-Code
23554   even more code
23555 \end_layout
23556
23557 \begin_layout LyX-Code
23558   @
23559 \end_layout
23560
23561 \begin_layout Standard
23562 The problem is that whatever is written in between the << and the 
23563 \family typewriter
23564 @
23565 \family default
23566  must be taken literally, i.
23567 \begin_inset space \thinspace{}
23568 \end_inset
23569
23570 e.
23571 \begin_inset space \space{}
23572 \end_inset
23573
23574 \SpecialChar LyX
23575  should be prevented from making any special interpretation of what has
23576  been written.
23577  This is also handled by 
23578 \begin_inset Flex Noun
23579 status collapsed
23580
23581 \begin_layout Plain Layout
23582 Chunk
23583 \end_layout
23584
23585 \end_inset
23586
23587 , that works like a normal text inset but has a free spacing capability.
23588 \end_layout
23589
23590 \begin_layout Standard
23591 As a special note, you can also use the 
23592 \begin_inset Quotes eld
23593 \end_inset
23594
23595 %def
23596 \begin_inset Quotes erd
23597 \end_inset
23598
23599  construct of Noweb in your chunks to add items to Noweb's identifier cross-refe
23600 rence:
23601 \end_layout
23602
23603 \begin_layout LyX-Code
23604 <<My chunk>>=
23605 \end_layout
23606
23607 \begin_layout LyX-Code
23608 def some_function(args):
23609 \end_layout
23610
23611 \begin_layout LyX-Code
23612    "This is the doc string for this function."
23613 \end_layout
23614
23615 \begin_layout LyX-Code
23616    print "My args: ", args
23617 \end_layout
23618
23619 \begin_layout LyX-Code
23620 @ %def some_function
23621 \end_layout
23622
23623 \begin_layout Standard
23624 For an example of this usage and the resulting cross-reference output, look
23625  at the Literate python program in 
23626 \emph on
23627 LIBDIR/examples/listerrors.lyx
23628 \emph default
23629  which should make this all clear.
23630 \end_layout
23631
23632 \begin_layout Paragraph
23633 Generating the documentation
23634 \end_layout
23635
23636 \begin_layout Standard
23637 At this point you already have a new document file with a proper document
23638  class, and with some code and text on it.
23639  How do I print it? The answer is simple, you select 
23640 \family sans
23641 View\SpecialChar menuseparator
23642 DVI,
23643 \family default
23644  etc.
23645  Just like you would do for a plain document.
23646  No special procedure is required.
23647 \end_layout
23648
23649 \begin_layout Standard
23650 To help orientate you, I will now explain what happens inside \SpecialChar LyX
23651 :
23652 \end_layout
23653
23654 \begin_layout Enumerate
23655 When the 
23656 \family sans
23657 Update\SpecialChar menuseparator
23658 DVI
23659 \family default
23660  menu option is chosen, a \SpecialChar LaTeX
23661  file is generated.
23662  
23663 \end_layout
23664
23665 \begin_deeper
23666 \begin_layout Standard
23667 If the document is of any literate class the generated file will be named
23668  with an extension name defined by the 
23669 \begin_inset Quotes eld
23670 \end_inset
23671
23672 literate
23673 \begin_inset Quotes erd
23674 \end_inset
23675
23676  format (defined in the Preferences panel), otherwise the file will have
23677  the usual 
23678 \family typewriter
23679 .tex
23680 \family default
23681  extension.
23682 \end_layout
23683
23684 \end_deeper
23685 \begin_layout Enumerate
23686 Note that the only difference so far is in the name of the file, no special
23687  processing is required by \SpecialChar LyX
23688 .
23689  Given that you formatted the code using the 
23690 \begin_inset Flex Noun
23691 status collapsed
23692
23693 \begin_layout Plain Layout
23694 Chunk
23695 \end_layout
23696
23697 \end_inset
23698
23699  inset that, by itself, takes care of the business.
23700 \end_layout
23701
23702 \begin_layout Enumerate
23703 If the document is of any literate class \SpecialChar LyX
23704  will then use the internal \SpecialChar LyX
23705  to
23706  Noweb converter, followed by the Noweb to \SpecialChar LaTeX
23707  converter
23708 \begin_inset Foot
23709 status collapsed
23710
23711 \begin_layout Plain Layout
23712 The converters are defined in the 
23713 \family sans
23714 Tools\SpecialChar menuseparator
23715 Preferences
23716 \family default
23717  panel, under the 
23718 \begin_inset Quotes eld
23719 \end_inset
23720
23721 Conversion
23722 \begin_inset Quotes erd
23723 \end_inset
23724
23725  tab.
23726  See section 
23727 \emph on
23728 Converters
23729 \emph default
23730  of the 
23731 \emph on
23732 Customization
23733 \emph default
23734  manual for general information about converters.
23735 \end_layout
23736
23737 \end_inset
23738
23739  to generate the \SpecialChar LaTeX
23740  file.
23741 \end_layout
23742
23743 \begin_deeper
23744 \begin_layout Standard
23745 Otherwise it will just skip this step.
23746 \end_layout
23747
23748 \end_deeper
23749 \begin_layout Enumerate
23750 Finally, \SpecialChar LaTeX
23751  is invoked and the regular post processing continues as in a plain
23752  document.
23753 \end_layout
23754
23755 \begin_layout Standard
23756 Independence from a particular 
23757 \begin_inset Quotes eld
23758 \end_inset
23759
23760 literate tool
23761 \begin_inset Quotes erd
23762 \end_inset
23763
23764  is easily achieved by changing the commands that are run by the various
23765  converters.
23766 \end_layout
23767
23768 \begin_layout Paragraph
23769 Generating the code
23770 \end_layout
23771
23772 \begin_layout Standard
23773 When the build menu option is chosen or the corresponding button in the
23774  toolbar is pressed, a \SpecialChar LaTeX
23775  file is generated just like step 1 above.
23776  Next, \SpecialChar LyX
23777  invokes the 
23778 \family typewriter
23779 Noweb->Program
23780 \family default
23781  converter.
23782  This converter needs to be defined by the user and is not installed by
23783  default, though the Program format is.
23784  This converter (like any other converter) will have two parts:
23785 \end_layout
23786
23787 \begin_layout Enumerate
23788 The converter program itself.
23789  This program performs the conversion from the one format to the other (in
23790  this case, from the Noweb format to the Program pseudo-format).
23791 \end_layout
23792
23793 \begin_layout Enumerate
23794 The error log parser.
23795  This is a program whose sole purpose is to rewrite error messages in a
23796  format that \SpecialChar LyX
23797  understands.
23798  This makes it possible for \SpecialChar LyX
23799  to place error boxes in the right places in
23800  the file buffer.
23801 \end_layout
23802
23803 \begin_layout Standard
23804 The first part, the 
23805 \begin_inset Quotes eld
23806 \end_inset
23807
23808 Converter
23809 \begin_inset Quotes erd
23810 \end_inset
23811
23812  setting, should be set to
23813 \end_layout
23814
23815 \begin_layout LyX-Code
23816
23817 \family typewriter
23818 build-script $$i
23819 \family default
23820  $$r
23821 \end_layout
23822
23823 \begin_layout Standard
23824 This basically means that \SpecialChar LyX
23825  will call 
23826 \begin_inset Quotes eld
23827 \end_inset
23828
23829 build-script
23830 \begin_inset Quotes erd
23831 \end_inset
23832
23833  (a program or script) with the name of the Noweb file (normally a file
23834  in the \SpecialChar LyX
23835  temp directory) and the directory path of the original \SpecialChar LyX
23836  file.
23837  
23838 \end_layout
23839
23840 \begin_layout Standard
23841 This is an implementation of 
23842 \begin_inset Quotes eld
23843 \end_inset
23844
23845 build-script
23846 \begin_inset Quotes erd
23847 \end_inset
23848
23849  that you can place in a directory on your path:
23850 \end_layout
23851
23852 \begin_layout LyX-Code
23853
23854 \family sans
23855 #!/bin/sh
23856 \end_layout
23857
23858 \begin_layout LyX-Code
23859
23860 \family sans
23861 #
23862 \end_layout
23863
23864 \begin_layout LyX-Code
23865
23866 \family sans
23867 notangle -Rbuild-script $1 | env NOWEB_SOURCE=$1 NOWEB_OUTPUT_DIR=$2 sh
23868 \end_layout
23869
23870 \begin_layout Standard
23871 The next part of the converter setting is the 
23872 \begin_inset Quotes eld
23873 \end_inset
23874
23875 Flags
23876 \begin_inset Quotes erd
23877 \end_inset
23878
23879  which is to be set to
23880 \end_layout
23881
23882 \begin_layout LyX-Code
23883
23884 \family typewriter
23885 parselog=$$s/scripts/listerrors
23886 \end_layout
23887
23888 \begin_layout Standard
23889 This will run any errors that are generated by the 
23890 \begin_inset Quotes eld
23891 \end_inset
23892
23893 build-script
23894 \begin_inset Quotes erd
23895 \end_inset
23896
23897  process through the 
23898 \begin_inset Quotes eld
23899 \end_inset
23900
23901 listerrors
23902 \begin_inset Quotes erd
23903 \end_inset
23904
23905  program.
23906 \end_layout
23907
23908 \begin_layout Standard
23909 The build will normally take place in \SpecialChar LyX
23910 's temporary directory, so the files
23911  produced by the conversion will be in that directory.
23912  \SpecialChar LyX
23913  will copy out what it regards as the `main' file, but the 
23914 \family typewriter
23915 Noweb->Program
23916 \family default
23917  conversion may produce several files, and so most of these would then be
23918  deleted when \SpecialChar LyX
23919  was closed.
23920  This is why we pass in the NOWEB_OUTPUT_DIR environment variable so that
23921  the build-script chunk can place the generated files in that location.
23922 \end_layout
23923
23924 \begin_layout Paragraph
23925 Build instructions in the document
23926 \end_layout
23927
23928 \begin_layout Standard
23929 The last piece of the integration between \SpecialChar LyX
23930  and noweb is the 
23931 \begin_inset Quotes eld
23932 \end_inset
23933
23934 build-script
23935 \begin_inset Quotes erd
23936 \end_inset
23937
23938  chunk.
23939  Generally, the instructions for building your program should be embedded
23940  in a chunk of its own.
23941  The noweb-specific 
23942 \begin_inset Quotes eld
23943 \end_inset
23944
23945 build-script
23946 \begin_inset Quotes erd
23947 \end_inset
23948
23949  above uses the notangle command to look for this chunk (called 
23950 \begin_inset Quotes eld
23951 \end_inset
23952
23953 build-script
23954 \begin_inset Quotes erd
23955 \end_inset
23956
23957 ) and runs its contents through 
23958 \begin_inset Quotes eld
23959 \end_inset
23960
23961 sh
23962 \begin_inset Quotes erd
23963 \end_inset
23964
23965 .
23966 \end_layout
23967
23968 \begin_layout Standard
23969 Typically, such a chunk would look something like this:
23970 \end_layout
23971
23972 \begin_layout LyX-Code
23973 <<build-script>>=
23974 \end_layout
23975
23976 \begin_layout LyX-Code
23977 #!/bin/sh
23978 \begin_inset Newline newline
23979 \end_inset
23980
23981 if [ -z "${NOWEB_SOURCE}" ]
23982 \begin_inset Newline newline
23983 \end_inset
23984
23985 then
23986 \end_layout
23987
23988 \begin_layout LyX-Code
23989 NOWEB_SOURCE=myfile.nw
23990 \begin_inset Newline newline
23991 \end_inset
23992
23993 fi
23994 \begin_inset Newline newline
23995 \end_inset
23996
23997 [...
23998  code to extract files ...
23999  use NOWEB_OUTPUT_DIR here ...]
24000 \begin_inset Newline newline
24001 \end_inset
24002
24003 [...
24004  code to compile files ...]
24005 \begin_inset Newline newline
24006 \end_inset
24007
24008 @
24009 \end_layout
24010
24011 \begin_layout Standard
24012 Look in 
24013 \emph on
24014 LIBDIR/examples/listerrors.lyx
24015 \emph default
24016  or in 
24017 \emph on
24018 LIBDIR/examples/Literate.lyx
24019 \emph default
24020  which implement two versions of the 
24021 \begin_inset Quotes eld
24022 \end_inset
24023
24024 listerrors
24025 \begin_inset Quotes erd
24026 \end_inset
24027
24028  program for some illustrations of how all of these pieces go together or
24029  in 
24030 \emph on
24031 LIBDIR/examples/noweb2lyx.lyx.
24032
24033 \emph default
24034  Interestingly, these three files show off the language-indepence of the
24035  \SpecialChar LyX
24036  literate programming support since they are written in Python, C and Perl
24037  respectively.
24038 \end_layout
24039
24040 \begin_layout Subsubsection
24041 Configuring \SpecialChar LyX
24042
24043 \end_layout
24044
24045 \begin_layout Standard
24046 All the Literate Programming support is configured by the 
24047 \family sans
24048 Tools\SpecialChar menuseparator
24049 Preferences
24050 \family default
24051  panel in the 
24052 \begin_inset Quotes eld
24053 \end_inset
24054
24055 File Handling
24056 \begin_inset Quotes erd
24057 \end_inset
24058
24059  tab.
24060  The important parts are:
24061 \end_layout
24062
24063 \begin_layout Description
24064 the
24065 \begin_inset space ~
24066 \end_inset
24067
24068
24069 \begin_inset Quotes eld
24070 \end_inset
24071
24072 NoWeb
24073 \begin_inset Quotes erd
24074 \end_inset
24075
24076
24077 \begin_inset space ~
24078 \end_inset
24079
24080 format Set up via the File Formats tab, this is where the Noweb-specific
24081  pieces are set up.
24082  The 
24083 \family sans
24084 GUI Name
24085 \family default
24086  is set to 
24087 \family typewriter
24088 NoWeb
24089 \family default
24090 , the file extension is set to 
24091 \family typewriter
24092 .nw
24093 \family default
24094 .
24095  This tells \SpecialChar LyX
24096  to create a file with a 
24097 \family typewriter
24098 .nw
24099 \family default
24100  extension in the first step of the conversion process.
24101 \end_layout
24102
24103 \begin_layout Description
24104 the
24105 \begin_inset space ~
24106 \end_inset
24107
24108
24109 \family sans
24110 Program
24111 \family default
24112
24113 \begin_inset space ~
24114 \end_inset
24115
24116 format This is an empty format whose sole purpose is to be the endpoint
24117  of a conversion (which then allows us to set up a converter for it).
24118 \end_layout
24119
24120 \begin_layout Description
24121
24122 \family sans
24123 NoWeb
24124 \family default
24125 ->
24126 \family sans
24127 \SpecialChar LaTeX
24128
24129 \family default
24130  This converter performs the 
24131 \begin_inset Quotes eld
24132 \end_inset
24133
24134 weaving
24135 \begin_inset Quotes erd
24136 \end_inset
24137
24138  of the literate document.
24139  For Noweb, it is set to 
24140 \begin_inset Quotes eld
24141 \end_inset
24142
24143
24144 \family typewriter
24145 noweave -delay -index $$i > $$o
24146 \family default
24147
24148 \begin_inset Quotes erd
24149 \end_inset
24150
24151
24152 \end_layout
24153
24154 \begin_layout Description
24155
24156 \family sans
24157 NoWeb
24158 \family default
24159 ->
24160 \family sans
24161 Program
24162 \family default
24163  This performs the 
24164 \begin_inset Quotes eld
24165 \end_inset
24166
24167 tangling step
24168 \begin_inset Quotes erd
24169 \end_inset
24170
24171 .
24172  As stated above, the Converter is set to 
24173 \begin_inset Quotes eld
24174 \end_inset
24175
24176
24177 \family typewriter
24178 build-script $$i
24179 \family default
24180  $$r
24181 \begin_inset Quotes erd
24182 \end_inset
24183
24184 , with Flags set to
24185 \begin_inset Newline newline
24186 \end_inset
24187
24188
24189 \begin_inset Quotes eld
24190 \end_inset
24191
24192
24193 \family typewriter
24194 parselog=$$s/scripts/listerrors
24195 \family default
24196
24197 \begin_inset Quotes erd
24198 \end_inset
24199
24200 .
24201 \end_layout
24202
24203 \begin_layout Subsubsection
24204 Debug extensions
24205 \end_layout
24206
24207 \begin_layout Standard
24208 There is also a new function implemented in the \SpecialChar LyX
24209  server, the 
24210 \begin_inset Quotes eld
24211 \end_inset
24212
24213 server-goto-file-row" function, to be used with ddd/gdb or other debugger.
24214  
24215 \end_layout
24216
24217 \begin_layout Standard
24218 When debugging code with ddd/gdb, it is possible to invoke a text editor
24219  at the current execution position with a single key stroke.
24220  The default ddd configuration for that is shift-ctrl-V.
24221  It happens that you can define the editor command line invocation in ddd
24222  by accessing the 
24223 \family sans
24224 Edit\SpecialChar menuseparator
24225 Preferences\SpecialChar menuseparator
24226 Helpers
24227 \family default
24228  dialog and changing the "Edit Sources" entry.
24229 \end_layout
24230
24231 \begin_layout Standard
24232 I take advantage of the newly created \SpecialChar LyX
24233  server function and this ddd feature,
24234  and set 
24235 \begin_inset Quotes eld
24236 \end_inset
24237
24238 Edit Sources
24239 \begin_inset Quotes erd
24240 \end_inset
24241
24242  to:
24243 \end_layout
24244
24245 \begin_layout LyX-Code
24246 echo "LYXCMD:monitor:server-goto-file-row:@FILE@ @LINE@" >~/.lyxpipe.in
24247 \end_layout
24248
24249 \begin_layout Standard
24250 With this, whenever you are using ddd and find a point in the program that
24251  you want to edit, you just press shift-ctrl-V (in the ddd window), and
24252  ddd will forward this information to \SpecialChar LyX
24253  through the \SpecialChar LyX
24254  server and then the
24255  \SpecialChar LyX
24256  window will show the same file with the cursor at the same position ddd
24257  was pointing to.
24258  No more guessing or long scrolling to locate a point in the program back
24259  from debugging !
24260 \end_layout
24261
24262 \begin_layout Standard
24263 Note however that you must enable the \SpecialChar LyX
24264  server to get this feature working
24265  (it is disabled by default).
24266  Sec.
24267 \begin_inset space ~
24268 \end_inset
24269
24270
24271 \begin_inset CommandInset ref
24272 LatexCommand ref
24273 reference "sec:Starting-the-Server"
24274
24275 \end_inset
24276
24277  explains how to do that.
24278 \end_layout
24279
24280 \begin_layout Subsubsection
24281 Toolbar extensions
24282 \end_layout
24283
24284 \begin_layout Standard
24285 There are six new buttons that can be added to your \SpecialChar LyX
24286  toolbar.
24287  Four of these buttons are short cuts to layout styles: 
24288 \family sans
24289 Standard
24290 \family default
24291
24292 \family sans
24293 Section
24294 \family default
24295
24296 \family sans
24297 \SpecialChar LaTeX
24298
24299 \family default
24300 , and 
24301 \family sans
24302 \SpecialChar LyX
24303 -Code
24304 \family default
24305 , one for the custom inset 
24306 \family sans
24307 Chunk
24308 \family default
24309 .
24310  The last one is a short cut to the 
24311 \begin_inset Quotes eld
24312 \end_inset
24313
24314 Build Program
24315 \begin_inset Quotes erd
24316 \end_inset
24317
24318  File menu entry.
24319  
24320 \end_layout
24321
24322 \begin_layout Standard
24323 \SpecialChar LyX
24324  has a range of buttons that are available for tool bar customization.
24325  In my toolbar I like to combine the six short cuts above with two more:
24326  One for 
24327 \family sans
24328 Document
24329 \family default
24330 \SpecialChar menuseparator
24331
24332 \family sans
24333 Update
24334 \family default
24335 \SpecialChar menuseparator
24336
24337 \family sans
24338 DVI
24339 \family default
24340  and the other for 
24341 \family sans
24342 Document\SpecialChar menuseparator
24343 View\SpecialChar menuseparator
24344 DVI
24345 \family default
24346  File menu entries.
24347  Here is how it looks like:
24348 \end_layout
24349
24350 \begin_layout LyX-Code
24351 Toolbar
24352 \end_layout
24353
24354 \begin_layout LyX-Code
24355   Layouts
24356 \end_layout
24357
24358 \begin_layout LyX-Code
24359   Icon "layout Standard"
24360 \end_layout
24361
24362 \begin_layout LyX-Code
24363   Icon "layout Section"
24364 \end_layout
24365
24366 \begin_layout LyX-Code
24367   Icon "layout \SpecialChar LaTeX
24368 "
24369 \end_layout
24370
24371 \begin_layout LyX-Code
24372   Icon "layout \SpecialChar LyX
24373 -Code"
24374 \end_layout
24375
24376 \begin_layout LyX-Code
24377   Icon "flex.insert Chunk"
24378 \end_layout
24379
24380 \begin_layout LyX-Code
24381   Separator
24382 \end_layout
24383
24384 \begin_layout LyX-Code
24385   Icon "buffer-view"
24386 \end_layout
24387
24388 \begin_layout LyX-Code
24389   Icon "buffer-typeset"
24390 \end_layout
24391
24392 \begin_layout LyX-Code
24393   Icon "build-program"
24394 \end_layout
24395
24396 \begin_layout LyX-Code
24397   Separator
24398 \end_layout
24399
24400 \begin_layout LyX-Code
24401 .
24402 \end_layout
24403
24404 \begin_layout LyX-Code
24405 .
24406 \end_layout
24407
24408 \begin_layout LyX-Code
24409 .
24410 \end_layout
24411
24412 \begin_layout LyX-Code
24413 End
24414 \end_layout
24415
24416 \begin_layout Subsubsection
24417 Colors customization
24418 \end_layout
24419
24420 \begin_layout Standard
24421 There are a number of colors in \SpecialChar LyX
24422  that can be customized in 
24423 \family sans
24424 Preferences
24425 \family default
24426 .
24427  One of the things that bothers people is the \SpecialChar LaTeX
24428  font color.
24429  The default color is red, since the chunks uses \SpecialChar LaTeX
24430  font, and there is a lot
24431  of chunks in literate documents, you may get tired of seeing everything
24432  in red.
24433  You can change it by going to the tabs 
24434 \family sans
24435 Look&Feel
24436 \family default
24437
24438 \family sans
24439 Colors.
24440 \end_layout
24441
24442 \begin_layout Standard
24443 The next thing is the visible presence of the newline character in the screen.
24444  You can choose the color of this particular character and make it blend
24445  in the background.
24446  I recommend you choosing a color that is close to the background but not
24447  equal, that way you still can see it is there, but it is not bothering
24448  you anymore.
24449 \end_layout
24450
24451 \begin_layout Subsection
24452 \SpecialChar LyX
24453  and knitr/Sweave
24454 \end_layout
24455
24456 \begin_layout Standard
24457 Support for 
24458 \family sans
24459 knitr
24460 \family default
24461  and 
24462 \family sans
24463 Sweave
24464 \family default
24465  is documented in the 
24466 \emph on
24467 knitr.lyx
24468 \emph default
24469  example file and in the Sweave manual (menu 
24470 \family sans
24471 Help\SpecialChar menuseparator
24472 Specific Manuals
24473 \family default
24474 ).
24475 \end_layout
24476
24477 \begin_layout Chapter
24478 Special features
24479 \end_layout
24480
24481 \begin_layout Standard
24482 You can do everything with \SpecialChar LyX
24483  that you can do with \SpecialChar LaTeX
24484 .
24485  However, \SpecialChar LyX
24486  cannot support every \SpecialChar LaTeX
24487  feature directly.
24488  But you can always use \SpecialChar TeX
24489  Code.
24490  This chapter shows you some more special things you might want to use.
24491  For other special things you can do with figures, tables, floats, boxes
24492  and notes, have a look at the 
24493 \emph on
24494 Embedded
24495 \begin_inset space ~
24496 \end_inset
24497
24498 Objects
24499 \emph default
24500  manual.
24501 \end_layout
24502
24503 \begin_layout Section
24504 Multiple Text Columns
24505 \end_layout
24506
24507 \begin_layout Standard
24508 This feature is independent of the option 
24509 \family sans
24510 Two-column document
24511 \family default
24512  in the document settings under 
24513 \family sans
24514 Text Layout
24515 \family default
24516 .
24517  If you want to have 2
24518 \begin_inset space ~
24519 \end_inset
24520
24521 columns for the whole document, it is recommended to use the 
24522 \family sans
24523 Two-column document
24524 \family default
24525  option.
24526  For all other cases use this feature.
24527 \end_layout
24528
24529 \begin_layout Standard
24530 To use multiple text columns in your document, you have to load the module
24531  
24532 \family sans
24533 Multiple Columns
24534 \family default
24535  (menu 
24536 \family sans
24537 Document\SpecialChar menuseparator
24538 Settings\SpecialChar menuseparator
24539 Modules
24540 \family default
24541 ) and must have the \SpecialChar LaTeX
24542 -package 
24543 \begin_inset Flex Code
24544 status collapsed
24545
24546 \begin_layout Plain Layout
24547 multicol
24548 \end_layout
24549
24550 \end_inset
24551
24552  installed.
24553 \end_layout
24554
24555 \begin_layout Standard
24556 Footnotes within multiple columns will be placed at the bottom of the page
24557  and not under each column.
24558  Within the different columns you can use everything, with the limitation
24559  that for floats you need to use the float option 
24560 \family sans
24561 Span columns
24562 \family default
24563 .
24564 \end_layout
24565
24566 \begin_layout Subsection
24567 Basics
24568 \end_layout
24569
24570 \begin_layout Standard
24571 If you want to have 2
24572 \begin_inset space ~
24573 \end_inset
24574
24575 columns in your text, insert a multicolumn inset via the menu 
24576 \family sans
24577 Insert\SpecialChar menuseparator
24578 Custom
24579 \begin_inset space ~
24580 \end_inset
24581
24582 Insets\SpecialChar menuseparator
24583 Multiple
24584 \begin_inset space ~
24585 \end_inset
24586
24587 Columns
24588 \family default
24589  where the columns should start.
24590  Write all text that should be printed in 2
24591 \begin_inset space ~
24592 \end_inset
24593
24594 columns into this inset.
24595 \end_layout
24596
24597 \begin_layout Standard
24598 Here is an example:
24599 \end_layout
24600
24601 \begin_layout Standard
24602 \noindent
24603 \begin_inset Flex Multiple Columns
24604 status open
24605
24606 \begin_layout Plain Layout
24607 \noindent
24608
24609 \series bold
24610 \size small
24611 The Adventure of the Empty House
24612 \series default
24613
24614 \begin_inset Newline newline
24615 \end_inset
24616
24617 by Sir Arthur Conan Doyle
24618 \end_layout
24619
24620 \begin_layout Plain Layout
24621
24622 \size small
24623 It was in the spring of the year 1894 that all London was interested, and
24624  the fashionable world dismayed, by the murder of the Honourable Ronald
24625  Adair under most unusual and inexplicable circumstances.
24626  The public has already learned those particulars of the crime which came
24627  out in the police investigation, but a good deal was suppressed upon that
24628  occasion, since the case for the prosecution was so overwhelmingly strong
24629  that it was not necessary to bring forward all the facts.
24630  Only now, at the end of nearly ten years, am I allowed to supply those
24631  missing links which make up the whole of that remarkable chain.
24632  The crime was of interest in itself, but that interest was as nothing to
24633  me compared to the inconceivable sequel, which afforded me the greatest
24634  shock and surprise of any event in my adventurous life.
24635  Even now, after this long interval, I find myself thrilling as I think
24636  of it, and feeling once more that sudden flood of joy, amazement, and increduli
24637 ty which utterly submerged my mind.
24638  Let me say to that public, which has shown some interest in those glimpses
24639  which I have occasionally given them of the thoughts and actions of a very
24640  remarkable man, that they are not to blame me if I have not shared my knowledge
24641  with them, for I should have considered it my first duty to do so, had
24642  I not been barred by a positive prohibition from his own lips, which was
24643  only withdrawn upon the third of last month.
24644 \end_layout
24645
24646 \end_inset
24647
24648
24649 \end_layout
24650
24651 \begin_layout Standard
24652 To get 3 or more columns, set the cursor into the multicolumn inset and
24653  use the menu 
24654 \family sans
24655 Insert\SpecialChar menuseparator
24656 Number
24657 \begin_inset space ~
24658 \end_inset
24659
24660 of
24661 \begin_inset space ~
24662 \end_inset
24663
24664 Columns
24665 \family default
24666 .
24667  The number of the desired columns is written into that inset (for 3
24668 \begin_inset space ~
24669 \end_inset
24670
24671 columns write 
24672 \begin_inset Quotes eld
24673 \end_inset
24674
24675 3
24676 \begin_inset Quotes erd
24677 \end_inset
24678
24679 ).
24680 \begin_inset Newline newline
24681 \end_inset
24682
24683 Here is an example with 3
24684 \begin_inset space ~
24685 \end_inset
24686
24687 columns:
24688 \end_layout
24689
24690 \begin_layout Standard
24691 \begin_inset Flex Multiple Columns
24692 status open
24693
24694 \begin_layout Plain Layout
24695
24696 \size footnotesize
24697 \begin_inset Argument 1
24698 status open
24699
24700 \begin_layout Plain Layout
24701
24702 3
24703 \end_layout
24704
24705 \end_inset
24706
24707 It can be imagined that my close intimacy with Sherlock Holmes had interested
24708  me deeply in crime, and that after his disappearance I never failed to
24709  read with care the various problems which came before the public.
24710  And I even attempted, more than once, for my own private satisfaction,
24711  to employ his methods in their solution, though with indifferent success.
24712  There was none, however, which appealed to me like this tragedy of Ronald
24713  Adair.
24714  As I read the evidence at the inquest, which led up to a verdict of willful
24715  murder against some person or persons unknown, I realized more clearly
24716  than I had ever done the loss which the community had sustained by the
24717  death of Sherlock Holmes.
24718  There were points about this strange business which would, I was sure,
24719  have specially appealed to him, and the efforts of the police would have
24720  been supplemented, or more probably anticipated, by the trained observation
24721  and the alert mind of the first criminal agent in Europe.
24722  All day, as I drove upon my round, I turned over the case in my mind and
24723  found no explanation which appeared to me to be adequate.
24724  At the risk of telling a twice-told tale, I will recapitulate the facts
24725  as they were known to the public at the conclusion of the inquest.
24726 \end_layout
24727
24728 \end_inset
24729
24730
24731 \end_layout
24732
24733 \begin_layout Standard
24734 You can have up to 10
24735 \begin_inset space ~
24736 \end_inset
24737
24738 columns if you want to, but that might not be very pleasant for the readers
24739  of your document.
24740 \end_layout
24741
24742 \begin_layout Standard
24743 \begin_inset Newpage newpage
24744 \end_inset
24745
24746
24747 \end_layout
24748
24749 \begin_layout Subsection
24750 Columns inside Columns
24751 \end_layout
24752
24753 \begin_layout Standard
24754 You can also have columns inside columns:
24755 \end_layout
24756
24757 \begin_layout Standard
24758 \begin_inset Flex Multiple Columns
24759 status open
24760
24761 \begin_layout Plain Layout
24762
24763 \size footnotesize
24764 The Honourable Ronald Adair was the second son of the Earl of Maynooth,
24765  at that time governor of one of the Australian colonies.
24766  Adair's mother had returned from Australia to undergo the operation for
24767  cataract, and she, her son Ronald, and her daughter Hilda were living together
24768  at 427 Park Lane.
24769 \end_layout
24770
24771 \begin_layout Plain Layout
24772 \begin_inset Flex Multiple Columns
24773 status open
24774
24775 \begin_layout Plain Layout
24776
24777 \size footnotesize
24778 The youth moved in the best society
24779 \begin_inset space ~
24780 \end_inset
24781
24782 – had, so far as was known, no enemies and no particular vices.
24783  He had been engaged to Miss Edith Woodley, of Carstairs, but the engagement
24784  had been broken off by mutual consent some months before, and there was
24785  no sign that it had left any very profound feeling behind it.
24786  For the rest {sic} the man's life moved in a narrow and conventional circle,
24787  for his habits were quiet and his nature unemotional.
24788  Yet it was upon this easy-going young aristocrat that death came, in most
24789  strange and unexpected form, between the hours of ten and eleven-twenty
24790  on the night of March 30, 1894.
24791 \end_layout
24792
24793 \end_inset
24794
24795
24796 \end_layout
24797
24798 \begin_layout Plain Layout
24799
24800 \size footnotesize
24801 Ronald Adair was fond of cards
24802 \begin_inset space ~
24803 \end_inset
24804
24805 – playing continually, but never for such stakes as would hurt him.
24806  He was a member of the Baldwin, the Cavendish, and the Bagatelle card clubs.
24807  It was shown that, after dinner on the day of his death, he had played
24808  a rubber of whist at the latter club.
24809  He had also played there in the afternoon.
24810
24811 \size default
24812  
24813 \size footnotesize
24814 The evidence of those who had played with him
24815 \begin_inset space ~
24816 \end_inset
24817
24818 – Mr.
24819  Murray, Sir John Hardy, and Colonel Moran
24820 \begin_inset space ~
24821 \end_inset
24822
24823 – showed that the game was whist, and that there was a fairly equal fall
24824  of the cards.
24825  Adair might have lost five pounds, but not more.
24826  His fortune was a considerable one, and such a loss could not in any way
24827  affect him.
24828  He had played nearly every day at one club or other, but he was a cautious
24829  player, and usually rose a winner.
24830  It came out in evidence that, in partnership with Colonel Moran, he had
24831  actually won as much as four hundred and twenty pounds in a sitting, some
24832  weeks before, from Godfrey Milner and Lord Balmoral.
24833  So much for his recent history as it came out at the inquest.
24834 \end_layout
24835
24836 \end_inset
24837
24838
24839 \end_layout
24840
24841 \begin_layout Subsection
24842 Advanced Examples
24843 \end_layout
24844
24845 \begin_layout Standard
24846 The examples in this section show some more special features of multiple
24847  columns.
24848 \end_layout
24849
24850 \begin_layout Standard
24851 For more features of multiple columns, have a look at the 
24852 \begin_inset CommandInset href
24853 LatexCommand href
24854 name "documentation"
24855 target "http://mirror.ctan.org/macros/latex/required/tools/multicol.pdf"
24856 literal "false"
24857
24858 \end_inset
24859
24860  of the \SpecialChar LaTeX
24861 -package 
24862 \begin_inset Flex Code
24863 status collapsed
24864
24865 \begin_layout Plain Layout
24866 multicol
24867 \end_layout
24868
24869 \end_inset
24870
24871 .
24872 \end_layout
24873
24874 \begin_layout Subsubsection
24875 Preface
24876 \end_layout
24877
24878 \begin_layout Standard
24879 To add a preface text for multiple columns, set the cursor into the multicolumn
24880  inset and use the menu 
24881 \family sans
24882 Insert\SpecialChar menuseparator
24883 Preface
24884 \family default
24885 .
24886  Write your preface text into that inset.
24887 \begin_inset Newline newline
24888 \end_inset
24889
24890 This is an example with some preface text:
24891 \end_layout
24892
24893 \begin_layout Standard
24894 \begin_inset VSpace bigskip
24895 \end_inset
24896
24897
24898 \end_layout
24899
24900 \begin_layout Standard
24901 \begin_inset Flex Multiple Columns
24902 status open
24903
24904 \begin_layout Plain Layout
24905 \begin_inset Argument 2
24906 status open
24907
24908 \begin_layout Plain Layout
24909 And the story continues and continues and continues and continues\SpecialChar ldots
24910
24911 \end_layout
24912
24913 \end_inset
24914
24915
24916 \size small
24917 On the evening of the crime, he returned from the club exactly at ten.
24918  His mother and sister were out spending the evening with a relation.
24919  The servant deposed that she heard him enter the front room on the second
24920  floor, generally used as his sitting-room.
24921  She had lit a fire there, and as it smoked she had opened the window.
24922  No sound was heard from the room until eleven-twenty, the hour of the return
24923  of Lady Maynooth and her daughter.
24924  Desiring to say good-night, she attempted to enter her son's room.
24925  The door was locked on the inside, and no answer could be got to their
24926  cries and knocking.
24927  Help was obtained, and the door forced.
24928  The unfortunate young man was found lying near the table.
24929  His head had been horribly mutilated by an expanding revolver bullet, but
24930  no weapon of any sort was to be found in the room.
24931 \end_layout
24932
24933 \end_inset
24934
24935
24936 \end_layout
24937
24938 \begin_layout Standard
24939 You can also use a section heading as the preface if you use a section command
24940  as \SpecialChar TeX
24941  Code.
24942  For example the command
24943 \end_layout
24944
24945 \begin_layout LyX-Code
24946
24947 \backslash
24948 subsection{subsection title}
24949 \end_layout
24950
24951 \begin_layout Standard
24952 creates a subsection.
24953  In this example the preface is a subsubsection:
24954 \end_layout
24955
24956 \begin_layout Standard
24957 \begin_inset Flex Multiple Columns
24958 status open
24959
24960 \begin_layout Plain Layout
24961 \begin_inset Argument 2
24962 status open
24963
24964 \begin_layout Plain Layout
24965 \begin_inset ERT
24966 status collapsed
24967
24968 \begin_layout Plain Layout
24969
24970
24971 \backslash
24972 subsubsection{
24973 \end_layout
24974
24975 \end_inset
24976
24977 This is a subsubsection heading as a preface
24978 \begin_inset ERT
24979 status collapsed
24980
24981 \begin_layout Plain Layout
24982
24983 }
24984 \end_layout
24985
24986 \end_inset
24987
24988
24989 \end_layout
24990
24991 \end_inset
24992
24993
24994 \size small
24995 A minute examination of the circumstances served only to make the case more
24996  complex.
24997  In the first place, no reason could be given why the young man should have
24998  fastened the door upon the inside.
24999  There was the possibility that the murderer had done this, and had afterwards
25000  escaped by the window.
25001  The drop was at least twenty feet, however, and a bed of crocuses in full
25002  bloom lay beneath.
25003  Neither the flowers nor the earth showed any sign of having been disturbed,
25004  nor were there any marks upon the narrow strip of grass which separated
25005  the house from the road.
25006  Apparently, therefore, it was the young man himself who had fastened the
25007  door.
25008  But how did he come by his death? No one could have climbed up to the window
25009  without leaving traces.
25010  Suppose a man had fired through the window, he would indeed be a remarkable
25011  shot who could with a revolver inflict so deadly a wound.
25012  Again, Park Lane is a frequented thoroughfare; there is a cab stand within
25013  a hundred yards of the house.
25014  No one had heard a shot.
25015 \end_layout
25016
25017 \end_inset
25018
25019
25020 \end_layout
25021
25022 \begin_layout Standard
25023 If there is less vertical space than 6
25024 \begin_inset space ~
25025 \end_inset
25026
25027 text lines is left on the page at the beginning of the multiple columns,
25028  a page break will be inserted before the multiple columns.
25029  Depending on the number of lines of the preface text, you might want to
25030  change this space.
25031  This is done by setting the cursor into the mulitcolumn inset behind the
25032  preface (if there is any) and using the menu 
25033 \family sans
25034 Insert\SpecialChar menuseparator
25035 Space
25036 \begin_inset space ~
25037 \end_inset
25038
25039 Before
25040 \begin_inset space ~
25041 \end_inset
25042
25043 Page
25044 \begin_inset space ~
25045 \end_inset
25046
25047 Break
25048 \family default
25049 .
25050  Insert into that inset the amount of space like e.
25051 \begin_inset space \thinspace{}
25052 \end_inset
25053
25054 g.
25055 \begin_inset space \space{}
25056 \end_inset
25057
25058
25059 \begin_inset Quotes eld
25060 \end_inset
25061
25062 5cm
25063 \begin_inset Quotes erd
25064 \end_inset
25065
25066 .
25067 \begin_inset Newline newline
25068 \end_inset
25069
25070 In this example the space is set to 7
25071 \begin_inset space ~
25072 \end_inset
25073
25074 text lines by using 
25075 \begin_inset Flex Code
25076 status collapsed
25077
25078 \begin_layout Plain Layout
25079 7
25080 \backslash
25081 baselineskip
25082 \end_layout
25083
25084 \end_inset
25085
25086  (where the command 
25087 \begin_inset Flex Code
25088 status collapsed
25089
25090 \begin_layout Plain Layout
25091
25092 \backslash
25093 baselineskip
25094 \end_layout
25095
25096 \end_inset
25097
25098  needs to be inserted as \SpecialChar TeX
25099  code):
25100 \end_layout
25101
25102 \begin_layout Standard
25103 \begin_inset Flex Multiple Columns
25104 status open
25105
25106 \begin_layout Plain Layout
25107 \begin_inset Argument 3
25108 status open
25109
25110 \begin_layout Plain Layout
25111 7
25112 \begin_inset ERT
25113 status collapsed
25114
25115 \begin_layout Plain Layout
25116
25117
25118 \backslash
25119 baselineskip
25120 \end_layout
25121
25122 \end_inset
25123
25124
25125 \end_layout
25126
25127 \end_inset
25128
25129
25130 \size small
25131 On the evening of the crime, he returned from the club exactly at ten.
25132  His mother and sister were out spending the evening with a relation.
25133  The servant deposed that she heard him enter the front room on the second
25134  floor, generally used as his sitting-room.
25135  She had lit a fire there, and as it smoked she had opened the window.
25136  No sound was heard from the room until eleven-twenty, the hour of the return
25137  of Lady Maynooth and her daughter.
25138  Desiring to say good-night, she attempted to enter her son's room.
25139  The door was locked on the inside, and no answer could be got to their
25140  cries and knocking.
25141  Help was obtained, and the door forced.
25142  The unfortunate young man was found lying near the table.
25143  His head had been horribly mutilated by an expanding revolver bullet, but
25144  no weapon of any sort was to be found in the room.
25145 \end_layout
25146
25147 \end_inset
25148
25149
25150 \end_layout
25151
25152 \begin_layout Subsubsection
25153 Surrounding Space
25154 \end_layout
25155
25156 \begin_layout Standard
25157 The amount of space before and after multiple columns can be changed by
25158  changing the length 
25159 \begin_inset Flex Code
25160 status collapsed
25161
25162 \begin_layout Plain Layout
25163
25164 \backslash
25165 multicolsep
25166 \end_layout
25167
25168 \end_inset
25169
25170 .
25171  For example the command
25172 \end_layout
25173
25174 \begin_layout LyX-Code
25175
25176 \backslash
25177 setlength{
25178 \backslash
25179 multicolsep}{3cm}
25180 \end_layout
25181
25182 \begin_layout Standard
25183 in \SpecialChar TeX
25184  Code changes its value to 3
25185 \begin_inset space \thinspace{}
25186 \end_inset
25187
25188 cm.
25189  The change must be made before the multiple columns' start.
25190  The predefined value is 13
25191 \begin_inset space \thinspace{}
25192 \end_inset
25193
25194 pt.
25195 \end_layout
25196
25197 \begin_layout Standard
25198 For this example 
25199 \begin_inset Flex Code
25200 status collapsed
25201
25202 \begin_layout Plain Layout
25203
25204 \backslash
25205 multicolsep
25206 \end_layout
25207
25208 \end_inset
25209
25210  was set to 2.5
25211 \begin_inset space \thinspace{}
25212 \end_inset
25213
25214 cm:
25215 \end_layout
25216
25217 \begin_layout Standard
25218 \begin_inset ERT
25219 status open
25220
25221 \begin_layout Plain Layout
25222
25223
25224 \backslash
25225 setlength{
25226 \backslash
25227 multicolsep}{2.5cm}
25228 \end_layout
25229
25230 \end_inset
25231
25232
25233 \end_layout
25234
25235 \begin_layout Standard
25236 \begin_inset Flex Multiple Columns
25237 status open
25238
25239 \begin_layout Plain Layout
25240
25241 \size small
25242 All day I turned these facts over in my mind, endeavouring to hit upon some
25243  theory which could reconcile them all, and to find that line of least resistanc
25244 e which my poor friend had declared to be the starting-point of every investigat
25245 ion.
25246  I confess that I made little progress.
25247  In the evening I strolled across the Park, and found myself about six o'clock
25248  at the Oxford Street end of Park Lane.
25249  A group of loafers upon the pavements, all staring up at a particular window,
25250  directed me to the house which I had come to see.
25251  A tall, thin man with coloured glasses, whom I strongly suspected of being
25252  a plain-clothes detective, was pointing out some theory of his own, while
25253  the others crowded round to listen to what he said.
25254  I got as near him as I could, but his observations seemed to me to be absurd,
25255  so I withdrew again in some disgust.
25256  As I did so I struck against an elderly, deformed man, who had been behind
25257  me, and I knocked down several books which he was carrying.
25258 \end_layout
25259
25260 \end_inset
25261
25262
25263 \end_layout
25264
25265 \begin_layout Standard
25266 \begin_inset Note Greyedout
25267 status open
25268
25269 \begin_layout Plain Layout
25270
25271 \series bold
25272 Note:
25273 \series default
25274  The values you set with 
25275 \begin_inset Flex Code
25276 status collapsed
25277
25278 \begin_layout Plain Layout
25279
25280 \backslash
25281 setlength
25282 \end_layout
25283
25284 \end_inset
25285
25286  will be used for all following multiple columns until you change them again.
25287 \end_layout
25288
25289 \end_inset
25290
25291
25292 \end_layout
25293
25294 \begin_layout Standard
25295 \begin_inset ERT
25296 status collapsed
25297
25298 \begin_layout Plain Layout
25299
25300
25301 \backslash
25302 setlength{
25303 \backslash
25304 multicolsep}{13pt}
25305 \end_layout
25306
25307 \end_inset
25308
25309
25310 \begin_inset Note Note
25311 status collapsed
25312
25313 \begin_layout Plain Layout
25314 go back to the default
25315 \end_layout
25316
25317 \end_inset
25318
25319
25320 \end_layout
25321
25322 \begin_layout Standard
25323 \begin_inset Newpage newpage
25324 \end_inset
25325
25326
25327 \end_layout
25328
25329 \begin_layout Subsubsection
25330 Column Breaks
25331 \end_layout
25332
25333 \begin_layout Standard
25334 A column break can be forced by inserting the command 
25335 \begin_inset Flex Code
25336 status collapsed
25337
25338 \begin_layout Plain Layout
25339
25340 \backslash
25341 columnbreak{}
25342 \end_layout
25343
25344 \end_inset
25345
25346  as \SpecialChar TeX
25347  Code to that position in the text where the column should be broken.
25348  Note that this leads in most cases to whitespace in the text.
25349 \begin_inset Newline newline
25350 \end_inset
25351
25352 Here is an example:
25353 \end_layout
25354
25355 \begin_layout Standard
25356 \begin_inset Flex Multiple Columns
25357 status open
25358
25359 \begin_layout Plain Layout
25360
25361 \size small
25362 \begin_inset Quotes eld
25363 \end_inset
25364
25365 You're surprised to see me, sir,
25366 \begin_inset Quotes erd
25367 \end_inset
25368
25369  said he, in a strange, croaking voice.
25370 \end_layout
25371
25372 \begin_layout Plain Layout
25373
25374 \size small
25375 I acknowledged that I was.
25376 \end_layout
25377
25378 \begin_layout Plain Layout
25379
25380 \size small
25381 \begin_inset Quotes eld
25382 \end_inset
25383
25384 Well, I've a conscience, sir, and when I chanced to see you go into this
25385  house, as I came hobbling after you, I thought to myself, I'll just step
25386  in and see that kind gentleman, and tell him that if I was a bit gruff
25387  in my manner there was not any harm meant, and that I am much obliged to
25388  him for picking up my books.
25389 \begin_inset Quotes erd
25390 \end_inset
25391
25392
25393 \end_layout
25394
25395 \begin_layout Plain Layout
25396
25397 \size small
25398 \begin_inset Quotes eld
25399 \end_inset
25400
25401 You make too much of a trifle,
25402 \begin_inset Quotes erd
25403 \end_inset
25404
25405  said I.
25406  
25407 \begin_inset Quotes eld
25408 \end_inset
25409
25410 May I ask how you knew who I was?
25411 \begin_inset Quotes erd
25412 \end_inset
25413
25414  AFTER THIS SENTENCE THE COLUMN BREAK IS FORCED.
25415 \begin_inset ERT
25416 status collapsed
25417
25418 \begin_layout Plain Layout
25419
25420
25421 \backslash
25422 columnbreak{}
25423 \end_layout
25424
25425 \end_inset
25426
25427
25428 \end_layout
25429
25430 \begin_layout Plain Layout
25431
25432 \size small
25433 \begin_inset Quotes eld
25434 \end_inset
25435
25436 Well, sir, if it isn't too great a liberty, I am a neighbour of yours, for
25437  you'll find my little bookshop at the corner of Church Street, and very
25438  happy to see you, I am sure.
25439  Maybe you collect yourself, sir.
25440  Here's 
25441 \noun on
25442 British
25443 \begin_inset space ~
25444 \end_inset
25445
25446 Birds
25447 \noun default
25448 , and 
25449 \noun on
25450 Catullus
25451 \noun default
25452 , and 
25453 \noun on
25454 The Holy War
25455 \noun default
25456
25457 \begin_inset space ~
25458 \end_inset
25459
25460 – a bargain, every one of them.
25461  With five volumes you could just fill that gap on that second shelf.
25462  It looks untidy, does it not, sir?
25463 \begin_inset Quotes erd
25464 \end_inset
25465
25466
25467 \end_layout
25468
25469 \end_inset
25470
25471
25472 \end_layout
25473
25474 \begin_layout Subsubsection
25475 Column Separation
25476 \end_layout
25477
25478 \begin_layout Standard
25479 The width of the columns is automatically calculated, but you can modify
25480  the space between the columns.
25481  This is done by changing the length 
25482 \begin_inset Flex Code
25483 status collapsed
25484
25485 \begin_layout Plain Layout
25486
25487 \backslash
25488 columnsep
25489 \end_layout
25490
25491 \end_inset
25492
25493 .
25494  Its predefined value is 10
25495 \begin_inset space \thinspace{}
25496 \end_inset
25497
25498 pt.
25499  Here is an example where 
25500 \begin_inset Flex Code
25501 status collapsed
25502
25503 \begin_layout Plain Layout
25504
25505 \backslash
25506 columnsep
25507 \end_layout
25508
25509 \end_inset
25510
25511  is set to 3
25512 \begin_inset space \thinspace{}
25513 \end_inset
25514
25515 cm:
25516 \end_layout
25517
25518 \begin_layout Standard
25519 \begin_inset ERT
25520 status open
25521
25522 \begin_layout Plain Layout
25523
25524
25525 \backslash
25526 setlength{
25527 \backslash
25528 columnsep}{3cm}
25529 \end_layout
25530
25531 \end_inset
25532
25533
25534 \end_layout
25535
25536 \begin_layout Standard
25537 \begin_inset Flex Multiple Columns
25538 status open
25539
25540 \begin_layout Plain Layout
25541
25542 \size small
25543 My observations of No.
25544 \begin_inset space \space{}
25545 \end_inset
25546
25547 427 Park Lane did little to clear up the problem in which I was interested.
25548  The house was separated from the street by a low wall and railing, the
25549  whole not more than five feet high.
25550  It was perfectly easy, therefore, for anyone to get into the garden, but
25551  the window was entirely inaccessible, since there was no water pipe or
25552  anything which could help the most active man to climb it.
25553  More puzzled than ever, I retraced my steps to Kensington.
25554  I had not been in my study five minutes when the maid entered to say that
25555  a person desired to see me.
25556  To my astonishment it was none other than my strange old book collector,
25557  his sharp, wizened face peering out from a frame of white hair, and his
25558  precious volumes, a dozen of them at least, wedged under his right arm.
25559 \end_layout
25560
25561 \end_inset
25562
25563
25564 \end_layout
25565
25566 \begin_layout Standard
25567 \begin_inset ERT
25568 status collapsed
25569
25570 \begin_layout Plain Layout
25571
25572
25573 \backslash
25574 setlength{
25575 \backslash
25576 columnsep}{10pt}
25577 \end_layout
25578
25579 \end_inset
25580
25581
25582 \begin_inset Note Note
25583 status collapsed
25584
25585 \begin_layout Plain Layout
25586 go back to the default
25587 \end_layout
25588
25589 \end_inset
25590
25591
25592 \end_layout
25593
25594 \begin_layout Subsubsection
25595 Vertical Lines
25596 \end_layout
25597
25598 \begin_layout Standard
25599 Between the columns a rule with a width of the length 
25600 \begin_inset Flex Code
25601 status collapsed
25602
25603 \begin_layout Plain Layout
25604
25605 \backslash
25606 columnseprule
25607 \end_layout
25608
25609 \end_inset
25610
25611  is placed.
25612  If this rule width is set to 0
25613 \begin_inset space \thinspace{}
25614 \end_inset
25615
25616 pt (this is the default), the rule is suppressed.
25617  In the following example the rule is 2
25618 \begin_inset space \thinspace{}
25619 \end_inset
25620
25621 pt wide:
25622 \end_layout
25623
25624 \begin_layout Standard
25625 \begin_inset ERT
25626 status open
25627
25628 \begin_layout Plain Layout
25629
25630
25631 \backslash
25632 setlength{
25633 \backslash
25634 columnseprule}{2pt}
25635 \end_layout
25636
25637 \end_inset
25638
25639
25640 \end_layout
25641
25642 \begin_layout Standard
25643 \begin_inset Flex Multiple Columns
25644 status open
25645
25646 \begin_layout Plain Layout
25647
25648 \size small
25649 \begin_inset Quotes eld
25650 \end_inset
25651
25652 You're surprised to see me, sir,
25653 \begin_inset Quotes erd
25654 \end_inset
25655
25656  said he, in a strange, croaking voice.
25657 \end_layout
25658
25659 \begin_layout Plain Layout
25660
25661 \size small
25662 I acknowledged that I was.
25663 \end_layout
25664
25665 \begin_layout Plain Layout
25666
25667 \size small
25668 \begin_inset Quotes eld
25669 \end_inset
25670
25671 Well, I've a conscience, sir, and when I chanced to see you go into this
25672  house, as I came hobbling after you, I thought to myself, I'll just step
25673  in and see that kind gentleman, and tell him that if I was a bit gruff
25674  in my manner there was not any harm meant, and that I am much obliged to
25675  him for picking up my books.
25676 \begin_inset Quotes erd
25677 \end_inset
25678
25679
25680 \end_layout
25681
25682 \begin_layout Plain Layout
25683
25684 \size small
25685 \begin_inset Quotes eld
25686 \end_inset
25687
25688 You make too much of a trifle,
25689 \begin_inset Quotes erd
25690 \end_inset
25691
25692  said I.
25693  
25694 \begin_inset Quotes eld
25695 \end_inset
25696
25697 May I ask how you knew who I was?
25698 \begin_inset Quotes erd
25699 \end_inset
25700
25701
25702 \end_layout
25703
25704 \begin_layout Plain Layout
25705
25706 \size small
25707 \begin_inset Quotes eld
25708 \end_inset
25709
25710 Well, sir, if it isn't too great a liberty, I am a neighbour of yours, for
25711  you'll find my little bookshop at the corner of Church Street, and very
25712  happy to see you, I am sure.
25713  Maybe you collect yourself, sir.
25714  Here's 
25715 \noun on
25716 British
25717 \begin_inset space ~
25718 \end_inset
25719
25720 Birds
25721 \noun default
25722 , and 
25723 \noun on
25724 Catullus
25725 \noun default
25726 , and 
25727 \noun on
25728 The Holy War
25729 \noun default
25730
25731 \begin_inset space ~
25732 \end_inset
25733
25734 – a bargain, every one of them.
25735  With five volumes you could just fill that gap on that second shelf.
25736  It looks untidy, does it not, sir?
25737 \begin_inset Quotes erd
25738 \end_inset
25739
25740
25741 \end_layout
25742
25743 \end_inset
25744
25745
25746 \end_layout
25747
25748 \begin_layout Standard
25749 \begin_inset VSpace defskip
25750 \end_inset
25751
25752
25753 \end_layout
25754
25755 \begin_layout Standard
25756 The rule can be colored by redefining the command 
25757 \begin_inset Flex Code
25758 status collapsed
25759
25760 \begin_layout Plain Layout
25761
25762 \backslash
25763 columnseprulecolor
25764 \end_layout
25765
25766 \end_inset
25767
25768 .
25769  This is done by inserting the command
25770 \end_layout
25771
25772 \begin_layout LyX-Code
25773
25774 \backslash
25775 renewcommand{
25776 \backslash
25777 columnseprulecolor}{
25778 \backslash
25779 color{red}}
25780 \end_layout
25781
25782 \begin_layout Standard
25783 as \SpecialChar TeX
25784  Code before the multicolumn inset.
25785  Replace 
25786 \begin_inset Flex Code
25787 status collapsed
25788
25789 \begin_layout Plain Layout
25790 red
25791 \end_layout
25792
25793 \end_inset
25794
25795  in this command by a color of your choice.
25796  You can use all pre- and self-defined colors.
25797  See the 
25798 \emph on
25799 EmbeddedObjects
25800 \emph default
25801  manual, section 
25802 \emph on
25803 Colored
25804 \begin_inset space ~
25805 \end_inset
25806
25807 Tables
25808 \emph default
25809  for more information about pre- and self-defined colors.
25810  To go back to the default color insert the command
25811 \end_layout
25812
25813 \begin_layout LyX-Code
25814
25815 \backslash
25816 renewcommand{
25817 \backslash
25818 columnseprulecolor}{
25819 \backslash
25820 normalcolor}
25821 \end_layout
25822
25823 \begin_layout Standard
25824 Here is the example with a cyan rule and 1
25825 \begin_inset space \thinspace{}
25826 \end_inset
25827
25828 cm column separation:
25829 \end_layout
25830
25831 \begin_layout Standard
25832 \begin_inset ERT
25833 status open
25834
25835 \begin_layout Plain Layout
25836
25837
25838 \backslash
25839 setlength{
25840 \backslash
25841 columnsep}{1cm}
25842 \end_layout
25843
25844 \begin_layout Plain Layout
25845
25846
25847 \backslash
25848 renewcommand{
25849 \backslash
25850 columnseprulecolor}{
25851 \backslash
25852 color{cyan}}
25853 \end_layout
25854
25855 \end_inset
25856
25857
25858 \end_layout
25859
25860 \begin_layout Standard
25861 \begin_inset Flex Multiple Columns
25862 status open
25863
25864 \begin_layout Plain Layout
25865
25866 \size small
25867 \begin_inset Quotes eld
25868 \end_inset
25869
25870 You're surprised to see me, sir,
25871 \begin_inset Quotes erd
25872 \end_inset
25873
25874  said he, in a strange, croaking voice.
25875 \end_layout
25876
25877 \begin_layout Plain Layout
25878
25879 \size small
25880 I acknowledged that I was.
25881 \end_layout
25882
25883 \begin_layout Plain Layout
25884
25885 \size small
25886 \begin_inset Quotes eld
25887 \end_inset
25888
25889 Well, I've a conscience, sir, and when I chanced to see you go into this
25890  house, as I came hobbling after you, I thought to myself, I'll just step
25891  in and see that kind gentleman, and tell him that if I was a bit gruff
25892  in my manner there was not any harm meant, and that I am much obliged to
25893  him for picking up my books.
25894 \begin_inset Quotes erd
25895 \end_inset
25896
25897
25898 \end_layout
25899
25900 \begin_layout Plain Layout
25901
25902 \size small
25903 \begin_inset Quotes eld
25904 \end_inset
25905
25906 You make too much of a trifle,
25907 \begin_inset Quotes erd
25908 \end_inset
25909
25910  said I.
25911  
25912 \begin_inset Quotes eld
25913 \end_inset
25914
25915 May I ask how you knew who I was?
25916 \begin_inset Quotes erd
25917 \end_inset
25918
25919
25920 \end_layout
25921
25922 \begin_layout Plain Layout
25923
25924 \size small
25925 \begin_inset Quotes eld
25926 \end_inset
25927
25928 Well, sir, if it isn't too great a liberty, I am a neighbour of yours, for
25929  you'll find my little bookshop at the corner of Church Street, and very
25930  happy to see you, I am sure.
25931  Maybe you collect yourself, sir.
25932  Here's 
25933 \noun on
25934 British
25935 \begin_inset space ~
25936 \end_inset
25937
25938 Birds
25939 \noun default
25940 , and 
25941 \noun on
25942 Catullus
25943 \noun default
25944 , and 
25945 \noun on
25946 The Holy War
25947 \noun default
25948
25949 \begin_inset space ~
25950 \end_inset
25951
25952 – a bargain, every one of them.
25953  With five volumes you could just fill that gap on that second shelf.
25954  It looks untidy, does it not, sir?
25955 \begin_inset Quotes erd
25956 \end_inset
25957
25958
25959 \end_layout
25960
25961 \end_inset
25962
25963
25964 \end_layout
25965
25966 \begin_layout Standard
25967 \begin_inset ERT
25968 status collapsed
25969
25970 \begin_layout Plain Layout
25971
25972
25973 \backslash
25974 setlength{
25975 \backslash
25976 columnseprule}{0pt}
25977 \end_layout
25978
25979 \begin_layout Plain Layout
25980
25981
25982 \backslash
25983 renewcommand{
25984 \backslash
25985 columnseprulecolor}{
25986 \backslash
25987 normalcolor}
25988 \end_layout
25989
25990 \end_inset
25991
25992
25993 \begin_inset Note Note
25994 status collapsed
25995
25996 \begin_layout Plain Layout
25997 go back to the default
25998 \end_layout
25999
26000 \end_inset
26001
26002
26003 \end_layout
26004
26005 \begin_layout Section
26006 Non-standard Paragraph Shapes
26007 \end_layout
26008
26009 \begin_layout Standard
26010 \noindent
26011 \SpecialChar LaTeX
26012  as well as any other text processor uses by default rectangular paragraphs.
26013  For special cases like for example posters, invitation cards or poems you
26014  can modify the paragraph shape to one of your choice.
26015  This can be done by using the \SpecialChar LaTeX
26016 -package 
26017 \begin_inset Flex Code
26018 status collapsed
26019
26020 \begin_layout Plain Layout
26021 \noindent
26022 shapepar
26023 \end_layout
26024
26025 \end_inset
26026
26027  which is loaded by using in the document settings the module 
26028 \family sans
26029 Custom paragraph shapes
26030 \family default
26031 .
26032 \end_layout
26033
26034 \begin_layout Subsection
26035 Predefined shapes
26036 \end_layout
26037
26038 \begin_layout Standard
26039
26040 \series bold
26041 shapepar
26042 \series default
26043  provides the following shapes:
26044 \end_layout
26045
26046 \begin_layout Standard
26047 \begin_inset Tabular
26048 <lyxtabular version="3" rows="13" columns="3">
26049 <features booktabs="true" islongtable="true" longtabularalignment="center">
26050 <column alignment="left" valignment="middle" width="16col%">
26051 <column alignment="left" valignment="middle" width="40col%">
26052 <column alignment="left" valignment="middle" width="35col%">
26053 <row endhead="true">
26054 <cell alignment="left" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
26055 \begin_inset Text
26056
26057 \begin_layout Plain Layout
26058
26059 \series bold
26060 \size small
26061 Name
26062 \end_layout
26063
26064 \end_inset
26065 </cell>
26066 <cell alignment="left" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
26067 \begin_inset Text
26068
26069 \begin_layout Plain Layout
26070
26071 \series bold
26072 \size small
26073 Description
26074 \end_layout
26075
26076 \end_inset
26077 </cell>
26078 <cell alignment="left" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
26079 \begin_inset Text
26080
26081 \begin_layout Plain Layout
26082
26083 \series bold
26084 \size small
26085 Annotation
26086 \end_layout
26087
26088 \end_inset
26089 </cell>
26090 </row>
26091 <row interlinespace="default">
26092 <cell alignment="left" valignment="top" usebox="none">
26093 \begin_inset Text
26094
26095 \begin_layout Plain Layout
26096
26097 \size small
26098 CDlabel
26099 \end_layout
26100
26101 \end_inset
26102 </cell>
26103 <cell alignment="left" valignment="top" usebox="none">
26104 \begin_inset Text
26105
26106 \begin_layout Plain Layout
26107
26108 \size small
26109 Circle with circular hole (in the size of a CD/DVD)
26110 \end_layout
26111
26112 \end_inset
26113 </cell>
26114 <cell alignment="left" valignment="top" usebox="none">
26115 \begin_inset Text
26116
26117 \begin_layout Plain Layout
26118
26119 \size small
26120 Cannot be scaled, take care there is not too much text
26121 \end_layout
26122
26123 \end_inset
26124 </cell>
26125 </row>
26126 <row interlinespace="default">
26127 <cell alignment="left" valignment="top" usebox="none">
26128 \begin_inset Text
26129
26130 \begin_layout Plain Layout
26131
26132 \size small
26133 Circle
26134 \end_layout
26135
26136 \end_inset
26137 </cell>
26138 <cell alignment="left" valignment="top" usebox="none">
26139 \begin_inset Text
26140
26141 \begin_layout Plain Layout
26142
26143 \size small
26144 Circle
26145 \end_layout
26146
26147 \end_inset
26148 </cell>
26149 <cell alignment="left" valignment="top" usebox="none">
26150 \begin_inset Text
26151
26152 \begin_layout Plain Layout
26153
26154 \size small
26155 Fragile, calculation might fail
26156 \end_layout
26157
26158 \end_inset
26159 </cell>
26160 </row>
26161 <row interlinespace="default">
26162 <cell alignment="left" valignment="top" usebox="none">
26163 \begin_inset Text
26164
26165 \begin_layout Plain Layout
26166
26167 \size small
26168 Diamond
26169 \end_layout
26170
26171 \end_inset
26172 </cell>
26173 <cell alignment="left" valignment="top" usebox="none">
26174 \begin_inset Text
26175
26176 \begin_layout Plain Layout
26177
26178 \size small
26179 Rhomboid (symbolizing a 
26180 \begin_inset Quotes eld
26181 \end_inset
26182
26183 diamond
26184 \begin_inset Quotes erd
26185 \end_inset
26186
26187 )
26188 \end_layout
26189
26190 \end_inset
26191 </cell>
26192 <cell alignment="left" valignment="top" usebox="none">
26193 \begin_inset Text
26194
26195 \begin_layout Plain Layout
26196
26197 \size small
26198 -
26199 \end_layout
26200
26201 \end_inset
26202 </cell>
26203 </row>
26204 <row interlinespace="default">
26205 <cell alignment="left" valignment="top" usebox="none">
26206 \begin_inset Text
26207
26208 \begin_layout Plain Layout
26209
26210 \size small
26211 Heart
26212 \end_layout
26213
26214 \end_inset
26215 </cell>
26216 <cell alignment="left" valignment="top" usebox="none">
26217 \begin_inset Text
26218
26219 \begin_layout Plain Layout
26220
26221 \size small
26222 Heart-like shape
26223 \end_layout
26224
26225 \end_inset
26226 </cell>
26227 <cell alignment="left" valignment="top" usebox="none">
26228 \begin_inset Text
26229
26230 \begin_layout Plain Layout
26231
26232 \size small
26233 -
26234 \end_layout
26235
26236 \end_inset
26237 </cell>
26238 </row>
26239 <row interlinespace="default">
26240 <cell alignment="left" valignment="top" usebox="none">
26241 \begin_inset Text
26242
26243 \begin_layout Plain Layout
26244
26245 \size small
26246 Hexagon
26247 \end_layout
26248
26249 \end_inset
26250 </cell>
26251 <cell alignment="left" valignment="top" usebox="none">
26252 \begin_inset Text
26253
26254 \begin_layout Plain Layout
26255
26256 \size small
26257 Hexagon
26258 \end_layout
26259
26260 \end_inset
26261 </cell>
26262 <cell alignment="left" valignment="top" usebox="none">
26263 \begin_inset Text
26264
26265 \begin_layout Plain Layout
26266
26267 \size small
26268 -
26269 \end_layout
26270
26271 \end_inset
26272 </cell>
26273 </row>
26274 <row interlinespace="default">
26275 <cell alignment="left" valignment="top" usebox="none">
26276 \begin_inset Text
26277
26278 \begin_layout Plain Layout
26279
26280 \size small
26281 Nut
26282 \end_layout
26283
26284 \end_inset
26285 </cell>
26286 <cell alignment="left" valignment="top" usebox="none">
26287 \begin_inset Text
26288
26289 \begin_layout Plain Layout
26290
26291 \size small
26292 Nut for bolt (hexagon with circular hole)
26293 \end_layout
26294
26295 \end_inset
26296 </cell>
26297 <cell alignment="left" valignment="top" usebox="none">
26298 \begin_inset Text
26299
26300 \begin_layout Plain Layout
26301
26302 \size small
26303 -
26304 \end_layout
26305
26306 \end_inset
26307 </cell>
26308 </row>
26309 <row interlinespace="default">
26310 <cell alignment="left" valignment="top" usebox="none">
26311 \begin_inset Text
26312
26313 \begin_layout Plain Layout
26314
26315 \size small
26316 Square
26317 \end_layout
26318
26319 \end_inset
26320 </cell>
26321 <cell alignment="left" valignment="top" usebox="none">
26322 \begin_inset Text
26323
26324 \begin_layout Plain Layout
26325
26326 \size small
26327 Square
26328 \end_layout
26329
26330 \end_inset
26331 </cell>
26332 <cell alignment="left" valignment="top" usebox="none">
26333 \begin_inset Text
26334
26335 \begin_layout Plain Layout
26336
26337 \size small
26338 -
26339 \end_layout
26340
26341 \end_inset
26342 </cell>
26343 </row>
26344 <row interlinespace="default">
26345 <cell alignment="left" valignment="top" usebox="none">
26346 \begin_inset Text
26347
26348 \begin_layout Plain Layout
26349
26350 \size small
26351 Star
26352 \end_layout
26353
26354 \end_inset
26355 </cell>
26356 <cell alignment="left" valignment="top" usebox="none">
26357 \begin_inset Text
26358
26359 \begin_layout Plain Layout
26360
26361 \size small
26362 Five-point star
26363 \end_layout
26364
26365 \end_inset
26366 </cell>
26367 <cell alignment="left" valignment="top" usebox="none">
26368 \begin_inset Text
26369
26370 \begin_layout Plain Layout
26371
26372 \size small
26373 -
26374 \end_layout
26375
26376 \end_inset
26377 </cell>
26378 </row>
26379 <row interlinespace="default">
26380 <cell alignment="left" valignment="top" usebox="none">
26381 \begin_inset Text
26382
26383 \begin_layout Plain Layout
26384
26385 \size small
26386 Candle
26387 \end_layout
26388
26389 \end_inset
26390 </cell>
26391 <cell alignment="left" valignment="top" usebox="none">
26392 \begin_inset Text
26393
26394 \begin_layout Plain Layout
26395
26396 \size small
26397 Burning candle
26398 \end_layout
26399
26400 \end_inset
26401 </cell>
26402 <cell alignment="left" valignment="top" usebox="none">
26403 \begin_inset Text
26404
26405 \begin_layout Plain Layout
26406
26407 \size small
26408 -
26409 \end_layout
26410
26411 \end_inset
26412 </cell>
26413 </row>
26414 <row interlinespace="default">
26415 <cell alignment="left" valignment="top" usebox="none">
26416 \begin_inset Text
26417
26418 \begin_layout Plain Layout
26419
26420 \size small
26421 Drop down/up
26422 \end_layout
26423
26424 \end_inset
26425 </cell>
26426 <cell alignment="left" valignment="top" usebox="none">
26427 \begin_inset Text
26428
26429 \begin_layout Plain Layout
26430
26431 \size small
26432 Normal/reversed rain drop
26433 \end_layout
26434
26435 \end_inset
26436 </cell>
26437 <cell alignment="left" valignment="top" usebox="none">
26438 \begin_inset Text
26439
26440 \begin_layout Plain Layout
26441
26442 \size small
26443 Fragile, calculation might fail
26444 \end_layout
26445
26446 \end_inset
26447 </cell>
26448 </row>
26449 <row interlinespace="default">
26450 <cell alignment="left" valignment="top" usebox="none">
26451 \begin_inset Text
26452
26453 \begin_layout Plain Layout
26454
26455 \size small
26456 \SpecialChar TeX
26457
26458 \end_layout
26459
26460 \end_inset
26461 </cell>
26462 <cell alignment="left" valignment="top" usebox="none">
26463 \begin_inset Text
26464
26465 \begin_layout Plain Layout
26466
26467 \size small
26468 The \SpecialChar TeX
26469  logo
26470 \end_layout
26471
26472 \end_inset
26473 </cell>
26474 <cell alignment="left" valignment="top" usebox="none">
26475 \begin_inset Text
26476
26477 \begin_layout Plain Layout
26478
26479 \size small
26480 -
26481 \end_layout
26482
26483 \end_inset
26484 </cell>
26485 </row>
26486 <row interlinespace="default">
26487 <cell alignment="left" valignment="top" bottomline="true" usebox="none">
26488 \begin_inset Text
26489
26490 \begin_layout Plain Layout
26491
26492 \size small
26493 Triangle up/down/
26494 \begin_inset Newline newline
26495 \end_inset
26496
26497 left/right
26498 \end_layout
26499
26500 \end_inset
26501 </cell>
26502 <cell alignment="left" valignment="top" bottomline="true" usebox="none">
26503 \begin_inset Text
26504
26505 \begin_layout Plain Layout
26506
26507 \size small
26508 Triangles in different orientations
26509 \end_layout
26510
26511 \end_inset
26512 </cell>
26513 <cell alignment="left" valignment="top" bottomline="true" usebox="none">
26514 \begin_inset Text
26515
26516 \begin_layout Plain Layout
26517
26518 \size small
26519 -
26520 \end_layout
26521
26522 \end_inset
26523 </cell>
26524 </row>
26525 </lyxtabular>
26526
26527 \end_inset
26528
26529
26530 \end_layout
26531
26532 \begin_layout Standard
26533 To use a shape for your paragraph, simply select it in \SpecialChar LyX
26534 's pull-down box
26535  for environments in the toolbar.
26536 \end_layout
26537
26538 \begin_layout Standard
26539 \begin_inset Newpage newpage
26540 \end_inset
26541
26542
26543 \end_layout
26544
26545 \begin_layout Standard
26546 Here is an example paragraph in the shape of a nut:
26547 \end_layout
26548
26549 \begin_layout Standard
26550 \begin_inset VSpace bigskip
26551 \end_inset
26552
26553
26554 \end_layout
26555
26556 \begin_layout Nut
26557
26558 \lang latin
26559 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26560  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26561  voluptua.
26562  At vero eos et accusam et justo duo dolores et ea rebum.
26563  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
26564  sit amet.
26565  Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26566  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26567  voluptua.
26568 \end_layout
26569
26570 \begin_layout Standard
26571 \begin_inset VSpace bigskip
26572 \end_inset
26573
26574
26575 \end_layout
26576
26577 \begin_layout Standard
26578 \begin_inset Note Greyedout
26579 status open
26580
26581 \begin_layout Plain Layout
26582
26583 \series bold
26584 Note
26585 \series default
26586
26587 \family sans
26588 shapepar
26589 \family default
26590  paragraphs cannot run over a page break.
26591 \end_layout
26592
26593 \end_inset
26594
26595
26596 \end_layout
26597
26598 \begin_layout Standard
26599 \begin_inset VSpace bigskip
26600 \end_inset
26601
26602
26603 \end_layout
26604
26605 \begin_layout Standard
26606 The package 
26607 \begin_inset Flex Code
26608 status collapsed
26609
26610 \begin_layout Plain Layout
26611 shapepar
26612 \end_layout
26613
26614 \end_inset
26615
26616  takes care that the shape will always be preserved, no matter how much
26617  text is in the paragraph.
26618  Therefore the paragraph size changes with the amount of contained text.
26619  This can lead to paragraph sizes exceeding the page margins.
26620  To demonstrate the size scaling, here is the same example paragraph but
26621  with twice as much text:
26622 \end_layout
26623
26624 \begin_layout Standard
26625 \begin_inset Newpage newpage
26626 \end_inset
26627
26628
26629 \end_layout
26630
26631 \begin_layout Nut
26632
26633 \lang latin
26634 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26635  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26636  voluptua.
26637  At vero eos et accusam et justo duo dolores et ea rebum.
26638  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
26639  sit amet.
26640  Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26641  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26642  voluptua.
26643  Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26644  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26645  voluptua.
26646  At vero eos et accusam et justo duo dolores et ea rebum.
26647  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
26648  sit amet.
26649  Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26650  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26651  voluptua.
26652 \end_layout
26653
26654 \begin_layout Standard
26655 \begin_inset VSpace bigskip
26656 \end_inset
26657
26658
26659 \end_layout
26660
26661 \begin_layout Standard
26662 An exception is the shape 
26663 \family sans
26664 CDlabel
26665 \family default
26666 .
26667  It cannot be scaled because it must fit the size of a CD/DVD.
26668  Therefore the amount of text that fits into the shape is limited.
26669 \begin_inset Newline newline
26670 \end_inset
26671
26672 The 
26673 \family sans
26674 drop
26675 \family default
26676  shapes and the 
26677 \family sans
26678 circle
26679 \family default
26680  shape are fragile, meaning that the calculation of their size can fail,
26681  depending on the amount of text.
26682  You will then get the \SpecialChar LaTeX
26683  error 
26684 \begin_inset Quotes eld
26685 \end_inset
26686
26687 Arithmetic overflow
26688 \begin_inset Quotes erd
26689 \end_inset
26690
26691 .
26692  In this case one can try to remove or add some text; if nothing works one
26693  has to use another shape.
26694 \end_layout
26695
26696 \begin_layout Standard
26697 \begin_inset VSpace bigskip
26698 \end_inset
26699
26700
26701 \end_layout
26702
26703 \begin_layout Standard
26704 For shapes with tips you will maybe see that \SpecialChar LaTeX
26705 's hyphenation routine fails
26706  for text in the tips.
26707  Therefore it is often necessary to add hyphenation points 
26708 \family sans
26709 (
26710 \begin_inset Info
26711 type  "shortcut"
26712 arg   "specialchar-insert hyphenation"
26713 \end_inset
26714
26715
26716 \family default
26717 ) to the corresponding text parts.
26718 \end_layout
26719
26720 \begin_layout Standard
26721 \begin_inset VSpace bigskip
26722 \end_inset
26723
26724
26725 \end_layout
26726
26727 \begin_layout Standard
26728 Shapepar paragraphs are either always centered or placed on the page so
26729  that their left border touches the left page margin.
26730  You can therefore not use the paragraph dialog to align such paragraphs.
26731  A solution is to put the paragraph into a minipage or parbox and align
26732  the box.
26733  The problem is hereby to find the right width for the box.
26734  Because if it is too wide and you center the box, the paragraph is not
26735  centered too because it sticks at the left side of the box.
26736  So you might have to play a bit with the width until it fits.
26737  Here are two heart-shaped paragraphs, the first one is not aligned, the
26738  second one is right-aligned:
26739 \end_layout
26740
26741 \begin_layout Standard
26742 \begin_inset Newpage newpage
26743 \end_inset
26744
26745
26746 \end_layout
26747
26748 \begin_layout Heart
26749 \noindent
26750
26751 \lang latin
26752 Lo\SpecialChar softhyphen
26753 rem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26754  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26755  voluptua.
26756  At vero eos et accusam et justo duo dolores et ea rebum.
26757  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
26758  sit amet.
26759 \end_layout
26760
26761 \begin_layout Standard
26762 \begin_inset VSpace bigskip
26763 \end_inset
26764
26765
26766 \end_layout
26767
26768 \begin_layout Standard
26769 \noindent
26770 \align right
26771 \begin_inset Box Frameless
26772 position "t"
26773 hor_pos "c"
26774 has_inner_box 1
26775 inner_pos "t"
26776 use_parbox 1
26777 use_makebox 0
26778 width "42col%"
26779 special "none"
26780 height "1in"
26781 height_special "totalheight"
26782 thickness "0.4pt"
26783 separation "3pt"
26784 shadowsize "4pt"
26785 framecolor "black"
26786 backgroundcolor "none"
26787 status open
26788
26789 \begin_layout Heart
26790 \noindent
26791
26792 \lang latin
26793 Lo\SpecialChar softhyphen
26794 rem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26795  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26796  voluptua.
26797  At vero eos et accusam et justo duo dolores et ea rebum.
26798  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
26799  sit amet.
26800 \end_layout
26801
26802 \end_inset
26803
26804
26805 \end_layout
26806
26807 \begin_layout Subsection
26808 Custom shapes
26809 \end_layout
26810
26811 \begin_layout Standard
26812 You can define any shape you want.
26813  Doing this manually is a lot of work because every coordinate must be specified.
26814  But there is a way to let the computer calculate the coordinates:
26815 \end_layout
26816
26817 \begin_layout Enumerate
26818 Install the program 
26819 \begin_inset CommandInset href
26820 LatexCommand href
26821 name "Jpgfdraw"
26822 target "https://www.ctan.org/tex-archive/graphics/jpgfdraw"
26823 literal "false"
26824
26825 \end_inset
26826
26827 .
26828 \end_layout
26829
26830 \begin_layout Enumerate
26831 In 
26832 \family sans
26833 Jpgfdraw
26834 \family default
26835  go to the menu 
26836 \family sans
26837 TeX/LaTeX\SpecialChar menuseparator
26838 Settings\SpecialChar menuseparator
26839 Set Normal Size
26840 \family default
26841  and select the font size you are using in your document.
26842  For example this document uses the size 12
26843 \begin_inset space \thinspace{}
26844 \end_inset
26845
26846 pt.
26847 \end_layout
26848
26849 \begin_layout Enumerate
26850 Draw a shape.
26851 \end_layout
26852
26853 \begin_layout Enumerate
26854 Use the menu 
26855 \family sans
26856 TeX/LaTeX\SpecialChar menuseparator
26857 Shapepar
26858 \family default
26859  to export the shape to coordinates.
26860  In the appearing dialog use either the outline of your shape for the coordinate
26861 s or the path itself.
26862 \begin_inset Foot
26863 status collapsed
26864
26865 \begin_layout Plain Layout
26866 For more information see 
26867 \begin_inset CommandInset href
26868 LatexCommand href
26869 target "http://www.dickimaw-books.com/apps/jpgfdraw/manual/shapepar.html"
26870 literal "false"
26871
26872 \end_inset
26873
26874
26875 \end_layout
26876
26877 \end_inset
26878
26879
26880 \end_layout
26881
26882 \begin_layout Standard
26883 The coordinates are written into a \SpecialChar TeX
26884  file.
26885  To use it for your \SpecialChar LyX
26886  document
26887 \end_layout
26888
26889 \begin_layout Enumerate
26890 Place the cursor before the first character of your paragraph (or into a
26891  new empty one).
26892 \end_layout
26893
26894 \begin_layout Enumerate
26895 Open in \SpecialChar LyX
26896  the menu 
26897 \family sans
26898 Insert\SpecialChar menuseparator
26899 File\SpecialChar menuseparator
26900 Child
26901 \begin_inset space ~
26902 \end_inset
26903
26904 Document
26905 \family default
26906 , select the file and use 
26907 \family sans
26908 Input
26909 \family default
26910  as 
26911 \family sans
26912 Include Type.
26913 \end_layout
26914
26915 \begin_layout Standard
26916 \begin_inset VSpace defskip
26917 \end_inset
26918
26919
26920 \end_layout
26921
26922 \begin_layout Standard
26923 \begin_inset Note Greyedout
26924 status open
26925
26926 \begin_layout Plain Layout
26927
26928 \series bold
26929 Note
26930 \series default
26931 : The changed shape only applies to the current paragraph; everything is
26932  reset to normal for the next paragraph.
26933  Therefore the shape definition file must be input into every paragraph
26934  with the desired shape.
26935 \end_layout
26936
26937 \end_inset
26938
26939
26940 \end_layout
26941
26942 \begin_layout Standard
26943 \begin_inset VSpace bigskip
26944 \end_inset
26945
26946
26947 \end_layout
26948
26949 \begin_layout Standard
26950 Here is an example:
26951 \end_layout
26952
26953 \begin_layout Standard
26954 \begin_inset VSpace bigskip
26955 \end_inset
26956
26957
26958 \end_layout
26959
26960 \begin_layout Standard
26961 \begin_inset CommandInset include
26962 LatexCommand input
26963 filename "SpecialParagraphShape.tex"
26964
26965 \end_inset
26966
26967
26968 \lang latin
26969 Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26970  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26971  voluptua.
26972  At vero eos et accusam et justo duo dolores et ea rebum.
26973  Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor
26974  sit amet.
26975  Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy
26976  eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam
26977  voluptua.
26978 \end_layout
26979
26980 \begin_layout Standard
26981 \begin_inset VSpace bigskip
26982 \end_inset
26983
26984
26985 \end_layout
26986
26987 \begin_layout Standard
26988
26989 \series bold
26990 A tip:
26991 \series default
26992  to draw complexer shapes in 
26993 \family sans
26994 Jpgfdraw
26995 \family default
26996  you can draw the shape in a program of your choice and import the resulting
26997  image to 
26998 \family sans
26999 Jpgfdraw
27000 \family default
27001 .
27002  Then you only need to draw a line or spline along the outline of the image.
27003 \end_layout
27004
27005 \begin_layout Standard
27006 \begin_inset VSpace bigskip
27007 \end_inset
27008
27009
27010 \end_layout
27011
27012 \begin_layout Standard
27013 The module 
27014 \family sans
27015 Custom paragraph shapes
27016 \family default
27017  also provides the two commands 
27018 \family sans
27019 shapepar
27020 \family default
27021  and 
27022 \family sans
27023 Shapepar
27024 \family default
27025  which can be used to define custom shapes coordinate by coordinate.
27026 \begin_inset Foot
27027 status collapsed
27028
27029 \begin_layout Plain Layout
27030 These commands are internally used for all shapes described here.
27031 \end_layout
27032
27033 \end_inset
27034
27035  For information how these styles are used and about further customization
27036  possibilities, have a look at the 
27037 \begin_inset CommandInset href
27038 LatexCommand href
27039 name "documentation"
27040 target "https://www.ctan.org/tex-archive/macros/latex/contrib/shapepar/shapepar.pdf"
27041 literal "false"
27042
27043 \end_inset
27044
27045  of the package 
27046 \begin_inset Flex Code
27047 status collapsed
27048
27049 \begin_layout Plain Layout
27050 shapepar
27051 \end_layout
27052
27053 \end_inset
27054
27055 .
27056 \end_layout
27057
27058 \end_body
27059 \end_document