]> git.lyx.org Git - lyx.git/blob - lib/examples/docbook_article.lyx
Add Jean-Pierre Chr��tien to our list of contributers
[lyx.git] / lib / examples / docbook_article.lyx
1 #LyX 1.4.0cvs created this file. For more info see http://www.lyx.org/
2 \lyxformat 233
3 \textclass docbook
4 \language english
5 \inputencoding default
6 \fontscheme default
7 \graphics default
8 \paperfontsize default
9 \spacing single 
10 \papersize Default
11 \paperpackage a4
12 \use_geometry 0
13 \use_amsmath 0
14 \use_natbib 0
15 \use_numerical_citations 0
16 \use_jurabib 0
17 \use_bibtopic 0
18 \paperorientation portrait
19 \secnumdepth 3
20 \tocdepth 3
21 \paragraph_separation indent
22 \defskip medskip
23 \quotes_language english
24 \quotes_times 2
25 \papercolumns 1
26 \papersides 1
27 \paperpagestyle default
28 \tracking_changes 0
29 \end_header
30
31 \begin_layout SGML
32
33  
34 \begin_inset Note Note
35 status collapsed
36
37 \begin_layout Standard
38
39 Here goes the information about the article:
40 \end_layout
41
42 \begin_layout Standard
43
44 * title
45 \end_layout
46
47 \begin_layout Standard
48
49 * date
50 \end_layout
51
52 \begin_layout Standard
53
54 * author
55 \end_layout
56
57 \begin_layout Standard
58
59 + first name
60 \end_layout
61
62 \begin_layout Standard
63
64 + last name
65 \end_layout
66
67 \begin_layout Standard
68
69 * abstract
70 \end_layout
71
72 \end_inset 
73
74
75 \end_layout
76
77 \begin_layout Title
78
79 Docbook with LyX
80 \end_layout
81
82 \begin_layout Date
83
84 24 September 1999
85 \end_layout
86
87 \begin_layout Author
88
89
90 \begin_inset CharStyle Firstname
91 status inlined
92
93 \begin_layout Standard
94
95 José
96 \end_layout
97
98 \end_inset 
99
100
101 \begin_inset CharStyle Surname
102 status inlined
103
104 \begin_layout Standard
105
106 Matos
107 \end_layout
108
109 \end_inset 
110
111
112 \end_layout
113
114 \begin_layout Abstract
115
116 This is a small illustration of lyx's features using DocBook.
117 \end_layout
118
119 \begin_layout Abstract
120
121 The abstract can span several paragraphs.
122 \end_layout
123
124 \begin_layout Section
125
126
127 \begin_inset LatexCommand \label{first-section}
128
129 \end_inset 
130
131 Introduction
132 \end_layout
133
134 \begin_layout Standard
135
136 This file ilustrates the generation of docbook documents with LyX.
137 \end_layout
138
139 \begin_layout Standard
140
141 This will improve as soon as new features are available.
142 \end_layout
143
144 \begin_layout Section
145
146 Standard layouts
147 \end_layout
148
149 \begin_layout Standard
150
151 One of the goals is the support, as much as possible, of layouts used in
152  other textclass, for compatibility purposes.
153 \end_layout
154
155 \begin_layout Standard
156
157 Remember that this is work in progress, I would like to hear any comments,
158  good or 
159 \begin_inset Quotes eld
160 \end_inset 
161
162 bad
163 \begin_inset Quotes erd
164 \end_inset 
165
166 .
167 \end_layout
168
169 \begin_layout Subsection
170
171 Lists
172 \end_layout
173
174 \begin_layout Standard
175
176 This is an example with several nested lists.
177 \end_layout
178
179 \begin_layout Itemize
180
181 item 1
182 \end_layout
183
184 \begin_deeper 
185 \begin_layout Enumerate
186
187 item 2
188 \end_layout
189
190 \begin_layout Description
191
192 new item
193 \end_layout
194
195 \begin_deeper 
196 \begin_layout Enumerate
197
198 collection
199 \end_layout
200
201 \end_deeper 
202 \end_deeper 
203 \begin_layout Itemize
204
205 new set
206 \end_layout
207
208 \begin_layout Subsection
209
210 Code
211 \end_layout
212
213 \begin_layout Standard
214
215 Required steps to have a running lyx.
216 \end_layout
217
218 \begin_layout Quotation
219
220 Be carefull with your own code.
221 \end_layout
222
223 \begin_layout Quotation
224
225 The debugger.
226 \end_layout
227
228 \begin_layout Code
229
230 cat > env.out
231 \end_layout
232
233 \begin_layout Code
234
235 tar xvzf lyx.tgz
236 \end_layout
237
238 \begin_layout Code
239
240 cd lyx-1_0_x
241 \end_layout
242
243 \begin_layout Code
244
245 ./configure
246 \end_layout
247
248 \begin_layout Code
249
250 make
251 \end_layout
252
253 \begin_layout Code
254
255 make install
256 \end_layout
257
258 \begin_layout Subsection
259
260 Labels
261 \end_layout
262
263 \begin_layout Standard
264
265 If a label is the first element in any layout, that label will be merged
266  with that element.
267  See as an example 
268 \begin_inset LatexCommand \ref[first-section]{first-section}
269
270 \end_inset 
271
272 .
273 \end_layout
274
275 \begin_layout Subsection
276
277 Fonts
278 \end_layout
279
280 \begin_layout Standard
281
282 The only fonts supported are 
283 \emph on 
284 Emphasis
285 \emph default 
286  and 
287 \begin_inset CharStyle Literal
288 status inlined
289
290 \begin_layout Standard
291
292 SGML
293 \end_layout
294
295 \end_inset 
296
297 .
298 \end_layout
299
300 \begin_layout Subsection
301
302 Figures
303 \end_layout
304
305 \begin_layout Standard
306
307 One of the major changes in the docbook when compared with the linuxdoc
308  support are the figures support.
309  LyX only allows to view eps figures.
310  So you should have one of these if you want to take advantage of this feature.
311 \end_layout
312
313 \begin_layout Standard
314
315 Notice that when the docbook code is exported the filename extension is
316  stripped.
317  This enables that when the several backends are processed in sgmltools,
318  the corresponding extensions are added.
319  The default extension are eps for the print and gif for the html backend.
320 \end_layout
321
322 \begin_layout Standard
323
324
325 \begin_inset Float figure
326 placement htbp
327 wide false
328 sideways false
329 status open
330
331 \begin_layout Standard
332
333
334 \begin_inset Graphics
335         filename ../doc/platypus.eps
336         display grayscale
337         width 2cm
338         height 3cm
339         rotateAngle 45
340         rotateOrigin center
341
342 \end_inset 
343
344
345 \end_layout
346
347 \begin_layout Caption
348
349 Nice platypus
350 \end_layout
351
352 \end_inset 
353
354  
355 \end_layout
356
357 \begin_layout Standard
358
359 Wide figures are treated as normal figures.
360 \end_layout
361
362 \begin_layout Standard
363
364
365 \begin_inset Float figure
366 placement htbp
367 wide true
368 sideways false
369 status open
370
371 \begin_layout Standard
372
373
374 \begin_inset Graphics
375         filename ../doc/platypus.eps
376         display grayscale
377         width 2cm
378         height 3cm
379         rotateAngle 45
380         rotateOrigin center
381
382 \end_inset 
383
384
385 \end_layout
386
387 \begin_layout Caption
388
389 long, very long...
390  :-)
391 \end_layout
392
393 \end_inset 
394
395
396 \end_layout
397
398 \begin_layout Subsection
399
400 Tables
401 \end_layout
402
403 \begin_layout Standard
404
405 There is also basic support for tables.
406 \begin_inset Float table
407 placement htbp
408 wide false
409 sideways false
410 status open
411
412 \begin_layout Standard
413 \align center 
414
415 \begin_inset Tabular
416 <lyxtabular version="3" rows="3" columns="5">
417 <features>
418 <column alignment="center" valignment="top" leftline="true" width="0pt">
419 <column alignment="center" valignment="top" leftline="true" width="0pt">
420 <column alignment="center" valignment="top" leftline="true" width="0pt">
421 <column alignment="center" valignment="top" leftline="true" width="0pt">
422 <column alignment="center" valignment="top" leftline="true" rightline="true" width="0pt">
423 <row topline="true">
424 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
425 \begin_inset Text
426
427 \begin_layout Standard
428
429 \end_layout
430
431 \end_inset 
432 </cell>
433 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
434 \begin_inset Text
435
436 \begin_layout Standard
437
438 Software 1
439 \end_layout
440
441 \end_inset 
442 </cell>
443 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
444 \begin_inset Text
445
446 \begin_layout Standard
447
448 Software 2
449 \end_layout
450
451 \end_inset 
452 </cell>
453 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
454 \begin_inset Text
455
456 \begin_layout Standard
457
458 Software 3
459 \end_layout
460
461 \end_inset 
462 </cell>
463 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
464 \begin_inset Text
465
466 \begin_layout Standard
467
468 Software 4
469 \end_layout
470
471 \end_inset 
472 </cell>
473 </row>
474 <row topline="true">
475 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
476 \begin_inset Text
477
478 \begin_layout Standard
479
480 Plataform 1
481 \end_layout
482
483 \end_inset 
484 </cell>
485 <cell multicolumn="1" alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
486 \begin_inset Text
487
488 \begin_layout Standard
489
490 25 MB
491 \end_layout
492
493 \end_inset 
494 </cell>
495 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
496 \begin_inset Text
497
498 \begin_layout Standard
499
500 10 MB
501 \end_layout
502
503 \end_inset 
504 </cell>
505 <cell multicolumn="1" alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
506 \begin_inset Text
507
508 \begin_layout Standard
509
510 34 MB
511 \end_layout
512
513 \end_inset 
514 </cell>
515 <cell multicolumn="2" alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
516 \begin_inset Text
517
518 \begin_layout Standard
519
520 \end_layout
521
522 \end_inset 
523 </cell>
524 </row>
525 <row topline="true" bottomline="true">
526 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
527 \begin_inset Text
528
529 \begin_layout Standard
530
531 Plataform 2
532 \end_layout
533
534 \end_inset 
535 </cell>
536 <cell multicolumn="1" alignment="center" valignment="top" bottomline="true" leftline="true" usebox="none">
537 \begin_inset Text
538
539 \begin_layout Standard
540
541 \end_layout
542
543 \end_inset 
544 </cell>
545 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
546 \begin_inset Text
547
548 \begin_layout Standard
549
550 12 MB
551 \end_layout
552
553 \end_inset 
554 </cell>
555 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
556 \begin_inset Text
557
558 \begin_layout Standard
559
560 30 MB
561 \end_layout
562
563 \end_inset 
564 </cell>
565 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
566 \begin_inset Text
567
568 \begin_layout Standard
569
570 35 MB
571 \end_layout
572
573 \end_inset 
574 </cell>
575 </row>
576 </lyxtabular>
577
578 \end_inset 
579
580
581 \end_layout
582
583 \begin_layout Caption
584
585 Nice Formal Table
586 \end_layout
587
588 \end_inset 
589
590  
591 \end_layout
592
593 \begin_layout Standard
594
595 As it happens with the figures the wide tables are treated as normal tables.
596 \end_layout
597
598 \begin_layout Subsection
599
600 Margins
601 \end_layout
602
603 \begin_layout Standard
604
605 There are some restrictions when using margins.
606  For further information on docbook allowed syntax consult the 
607 \begin_inset LatexCommand \url[docbook reference manual]{http://www.oasis-open.org/docbook/documentation/reference/}
608
609 \end_inset 
610
611 .
612 \end_layout
613
614 \begin_layout Quotation
615
616 It is also possible to insert margin notes inside some environments.
617 \end_layout
618
619 \begin_deeper 
620 \begin_layout SGML
621
622
623 \begin_inset Marginal
624 status collapsed
625
626 \begin_layout Standard
627
628 margin note
629 \end_layout
630
631 \begin_layout Standard
632
633 second par -> margin note
634 \end_layout
635
636 \begin_layout Standard
637
638 third par -> margin note
639 \end_layout
640
641 \end_inset 
642
643  
644 \end_layout
645
646 \end_deeper 
647 \begin_layout Quotation
648
649 Notice that the previous layout is at level 1 
650 \begin_inset Foot
651 status collapsed
652
653 \begin_layout Standard
654
655 This comes from a docbook restriction.
656  Sidebar can only appear inside "MSGTEXT", "CAUTION", "IMPORTANT", "NOTE",
657  "TIP", "WARNING", "BLOCKQUOTE".
658 \end_layout
659
660 \begin_layout Standard
661
662 These environments are easily added to the docbook layout.
663 \end_layout
664
665 \end_inset 
666
667  and so is the follow:
668 \end_layout
669
670 \begin_deeper 
671 \begin_layout SGML
672
673
674 \begin_inset Marginal
675 status collapsed
676
677 \begin_layout Standard
678
679 too marginal ;-)
680 \end_layout
681
682 \end_inset 
683
684  
685 \end_layout
686
687 \end_deeper 
688 \begin_layout Section
689
690 The road map
691 \end_layout
692
693 \begin_layout Standard
694
695 This is a small list of the remaining tasks:
696 \end_layout
697
698 \begin_layout Itemize
699
700 Expand the number of layouts
701 \end_layout
702
703 \begin_deeper 
704 \begin_layout Itemize
705
706 example
707 \end_layout
708
709 \begin_layout Itemize
710
711 note
712 \end_layout
713
714 \begin_layout Itemize
715
716 warning
717 \end_layout
718
719 \begin_layout Itemize
720
721 tip
722 \end_layout
723
724 \begin_layout Itemize
725
726 caution
727 \end_layout
728
729 \begin_layout Itemize
730
731 important
732 \end_layout
733
734 \end_deeper 
735 \begin_layout Itemize
736
737 Compose other layout files, besides article
738 \end_layout
739
740 \begin_deeper 
741 \begin_layout Enumerate
742
743 book
744 \end_layout
745
746 \begin_layout Enumerate
747
748 set (very unlikely)
749 \begin_inset Foot
750 status collapsed
751
752 \begin_layout Standard
753
754 I do not expect lyx to deal with colection of books, for now!
755 \end_layout
756
757 \end_inset 
758
759
760 \end_layout
761
762 \begin_layout Enumerate
763
764 refentry
765 \end_layout
766
767 \end_deeper 
768 \begin_layout Itemize
769
770 goodies
771 \end_layout
772
773 \begin_deeper 
774 \begin_layout Enumerate
775
776 including other lyx files
777 \end_layout
778
779 \begin_layout Enumerate
780
781 more advanced tables support
782 \end_layout
783
784 \end_deeper 
785 \begin_layout Itemize
786
787 better documentation
788 \end_layout
789
790 \begin_layout Standard
791
792 That's all.
793  ;-)
794 \end_layout
795
796 \end_document