Mercurial > mplayer.hg
annotate DOCS/tech/manpage.txt @ 8677:d4e8a3026bf7
Translation updates
Spanish: seru <seru@gmx.net>
Korean: DongCheon Park <pdc@kaist.ac.kr>
Portuguese: Fabio Pugliese Ornellas <fabio.ornellas@poli.usp.br>
author | diego |
---|---|
date | Tue, 31 Dec 2002 14:37:05 +0000 |
parents | e741609ec32a |
children | b3e78d22cae0 |
rev | line source |
---|---|
7286 | 1 A documentation about MPlayer's man page |
2 ======================================== | |
3 | |
4 | |
5 About the documentation | |
6 ----------------------- | |
7289 | 7 Yes it's true: This is the documentation about the documentation (man page). |
7286 | 8 This guide should be used as a reference for questions about the man page |
9 structure. It's not a strict guide but we recommend following it to get a | |
10 uniform man page. | |
11 | |
12 | |
13 What belongs to the man page? | |
14 ----------------------------- | |
15 - option descriptions (all) | |
16 - usage (options, config files, controls, slave mode) | |
17 - basic examples | |
18 | |
19 | |
20 What doesn't belong to the man page? | |
21 ------------------------------------ | |
22 - instructions of a process (installation, encoding, etc) | |
23 - detailed valuations or hints | |
24 - tutorials, guides | |
25 | |
26 | |
27 How should patches look like? | |
28 ----------------------------- | |
29 Follow the rules in patches.txt, they apply to the man page too. | |
30 Exceptions are: | |
31 - Cosmetic patches are allowed but should be done seperately from the real | |
32 changes, be marked as cosmetic changes and shouldn't change the general | |
33 style without reasons/permissions | |
34 - The same applies for spellchecks | |
35 | |
36 | |
7741 | 37 How do I create a html, text or other versions of the man page? |
38 --------------------------------------------------------------- | |
7286 | 39 The man pages was more or less designed for groff as it is the main tool for |
40 it. Therefore only groff produces acceptable results without changes. | |
7289 | 41 Additionaly, the SS variable should be set to either very low or very high |
7741 | 42 values to produce a better groff html output (IMHO due to a bug off gro2html). |
43 A setting of 4 looks readable IMHO. Here's an overview again: | |
7289 | 44 |
7741 | 45 - groff: Groff is the "official" tool to convert man pages afaik. |
46 To get good results you really need a recent version (1.18.2) | |
47 cat mplayer.1 | sed s/SS\ 20/SS\ 4/ | groff -man -Thtml - > manpage.html | |
8217 | 48 groff -rLL=64n -m man -Tascii mplayer.1 | col -bx > manpage.txt |
7741 | 49 Check -T for other output formats. |
7286 | 50 - man2html: You can view it over your cgi script: |
51 http://localhost/cgi-bin/man2html?mplayer | |
52 The output is unuseable as the script doesn't seem to | |
53 support the macro definitions. Maybe a manual change of all | |
54 leads to acceptable results. | |
7742 | 55 - rman: rman -f html mplayer.1 > manpage.rman.html |
7741 | 56 The output is ugly as rman doesn't understand many of the |
57 macros used. | |
58 - troffcvt: troff2html -man mplayer.1 > manpage.tcvt.html | |
59 The (good) output is similar to groff but it simplified... | |
7286 | 60 |
61 | |
62 The structure | |
63 ------------- | |
64 The options are divided into the the layer they belong to. The only exception | |
65 is the OSD/SUB section. Inside the section they're alphabetically ordered. | |
66 | |
67 (Header) | |
68 Not visible, copyright and author informations. | |
69 (Macro definitions) | |
70 Not visible, some macro defintions. | |
71 NAME | |
72 The manpage is used for both: mplayer and mencoder. | |
73 SYNOPSIS | |
74 A description of MPlayer's playtree. | |
75 DESCRIPTION | |
76 A general description of MPlayer, MEncoder, GMPlayer and its features. | |
77 GENERAL NOTES | |
78 Some general notes about the options and a description of the config file | |
79 format. | |
80 PLAYER OPTIONS (MPLAYER ONLY) | |
81 Option descriptions about the user interface (mplayer only). | |
82 DEMUXER/STREAM OPTIONS | |
83 Option descriptions about the demuxer and stream layer. | |
84 OSD/SUB OPTIONS | |
85 This section is special: It contains all description about subtitles and | |
86 OSD. It is independent of the usual layer separation and was created | |
87 because of its size. The options may therefore come from any layer. | |
88 AUDIO OUTPUT OPTIONS (MPLAYER ONLY) | |
89 Option descriptions about the audio output layer (ao) (mplayer only). | |
90 VIDEO OUTPUT OPTIONS (MPLAYER ONLY) | |
91 Option descriptions about the video output layer (vo) (mplayer only). | |
92 DECODING/FILTERING OPTIONS | |
93 Options about the decoding and filter layer (ad,vd,vf,pl). | |
94 ENCODING OPTIONS (MENCODER ONLY) | |
95 Encoding option descriptions (ve) (mencoder only). | |
96 KEYBOARD CONTROL | |
97 A description of MPlayer's input system and the default keyboard controls. | |
98 SLAVE MODE PROTOCOL | |
99 A description about the slave mode protocol (-slave). | |
100 FILES | |
101 A list and description of all installed/used files/directories. | |
102 EXAMPLES | |
103 Basic examples. Again: no long descriptions/processes. | |
104 BUGS | |
105 AUTHORS | |
106 STANDARD DISCLAIMER | |
107 | |
108 | |
109 The man page/groff format | |
110 ------------------------- | |
111 Just read this and rtfs: | |
112 http://www.tldp.org/HOWTO/mini/Man-Page.html | |
113 man 7 man | |
114 man 7 groff | |
115 | |
116 | |
117 Directives for the internal "style" | |
118 ----------------------------------- | |
119 It was kept simple but there are still certain directives/rules to get a | |
120 uniform man page. The best way is to read (and understand) the source. | |
121 | |
122 General: | |
123 - No line should contain more than 79 characters | |
7744
6d41f5e905e2
reversed some changes as they produced ugly html output
jonas
parents:
7742
diff
changeset
|
124 - Used commands: .TH, .SH, .TP, .IP, .PP, .[R]B, .I, .br, .RS, .RE, .na, |
6d41f5e905e2
reversed some changes as they produced ugly html output
jonas
parents:
7742
diff
changeset
|
125 .nh, .ad, .hy, macro definitions, comments and some more |
7741 | 126 - Don't forget the quotation marks around expressions, the backslash |
127 before a '-' if it's needed, etc... | |
7286 | 128 |
129 Option description: | |
130 - Option and/or suboption parameters should be short and descriptive. | |
131 - If the option is between a certain range, it should be specified at the | |
132 beginning (eg. <0\-100> or <\-100 \- 100>) | |
7741 | 133 - All optional things are between angular paranthesis ([]) |
7286 | 134 - Obsolete options are followed by (OBSOLETE), beta options by |
135 (BETA CODE), etc | |
136 - MPlayer only options in a section which isn't marked this way | |
137 are followed by (MPLAYER only) | |
138 - Add hints to other options if they belong to each other | |
139 eg. (\-vo zr only) or (see \-alang option too) | |
140 - If a non trivial default parameter exist, write it down | |
141 eg. (default: 24) | |
142 - Options inside a section are all alphabetically ordered | |
7289 | 143 - Examples and notes at the end of the description (before sub options) |
144 - The end of the suboptions _always_ has to be followed by a paragraphs | |
145 (BUG). | |
7286 | 146 |
147 Macro definitions (see beginning of man page): | |
148 - SS SS is the starting value of the suboption column | |
149 - .IPs Add new suboption (we use .TP for normal options and .IP for | |
150 the rest) | |
151 - .RSs Begin of suboptions, end with .RE | |
152 - .RSss Begin of suboptions in a suboption | |
153 - .REss End of suboptions in a suboption | |
154 | |
155 Options, sub options, examples structure: | |
156 - Normal options (note the '<' and '>'): | |
157 | |
158 [...] | |
159 .TP | |
160 .B \-option <parameters> | |
161 description | |
162 [...] | |
163 | |
7289 | 164 - Long sub options: |
7286 | 165 |
166 [...] | |
167 description. Available options are: | |
168 . | |
169 .RSs | |
170 .IPs "subopt1=<value>" | |
171 description1 | |
172 .IPs "subopt2=<value>" | |
173 description2 | |
174 [...] | |
175 .IPs "last subopt=<value>" | |
176 last description | |
177 .RE | |
178 . | |
179 [...] | |
180 | |
7289 | 181 - Short sub options: |
182 | |
183 [...] | |
184 description. Available options are: | |
185 | |
186 .DP 0 | |
187 .RSs | |
188 .IPs "subopt1=<value>" | |
189 description1 | |
190 .IPs "subopt2=<value>" | |
191 description2 | |
192 [...] | |
193 .IPs "last subopt=<value>" | |
194 last description | |
195 .RE | |
196 .DP 1 | |
197 . | |
198 [...] | |
199 | |
200 | |
7286 | 201 - Sub options in sub options: |
202 | |
203 [...] | |
204 .IPs "subopt1=<value>" | |
205 description1 | |
206 .RSss | |
207 subsubopt1: description1 | |
208 .br | |
209 subsubopt2: description2 | |
210 [...] | |
211 .REss | |
212 [...] | |
213 | |
7741 | 214 - Examples: |
7286 | 215 |
216 [...] | |
217 | |
218 .I EXAMPLE: | |
219 .PD 0 | |
220 .RSs | |
221 .IP "-option used parameters" | |
222 description | |
223 [...] | |
224 .RE | |
225 .PD 1 | |
7289 | 226 . |
7286 | 227 [...] |