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