Mercurial > repos > rliterman > csp2
comparison CSP2/CSP2_env/env-d9b9114564458d9d-741b3de822f2aaca6c6caa4325c4afce/share/doc/gettext/gettext_10.html @ 68:5028fdace37b
planemo upload commit 2e9511a184a1ca667c7be0c6321a36dc4e3d116d
author | jpayne |
---|---|
date | Tue, 18 Mar 2025 16:23:26 -0400 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
67:0e9998148a16 | 68:5028fdace37b |
---|---|
1 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html401/loose.dtd"> | |
2 <html> | |
3 <!-- Created on February, 21 2024 by texi2html 1.78a --> | |
4 <!-- | |
5 Written by: Lionel Cons <Lionel.Cons@cern.ch> (original author) | |
6 Karl Berry <karl@freefriends.org> | |
7 Olaf Bachmann <obachman@mathematik.uni-kl.de> | |
8 and many others. | |
9 Maintained by: Many creative people. | |
10 Send bugs and suggestions to <texi2html-bug@nongnu.org> | |
11 | |
12 --> | |
13 <head> | |
14 <title>GNU gettext utilities: 10. Producing Binary MO Files</title> | |
15 | |
16 <meta name="description" content="GNU gettext utilities: 10. Producing Binary MO Files"> | |
17 <meta name="keywords" content="GNU gettext utilities: 10. Producing Binary MO Files"> | |
18 <meta name="resource-type" content="document"> | |
19 <meta name="distribution" content="global"> | |
20 <meta name="Generator" content="texi2html 1.78a"> | |
21 <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> | |
22 <style type="text/css"> | |
23 <!-- | |
24 a.summary-letter {text-decoration: none} | |
25 pre.display {font-family: serif} | |
26 pre.format {font-family: serif} | |
27 pre.menu-comment {font-family: serif} | |
28 pre.menu-preformatted {font-family: serif} | |
29 pre.smalldisplay {font-family: serif; font-size: smaller} | |
30 pre.smallexample {font-size: smaller} | |
31 pre.smallformat {font-family: serif; font-size: smaller} | |
32 pre.smalllisp {font-size: smaller} | |
33 span.roman {font-family:serif; font-weight:normal;} | |
34 span.sansserif {font-family:sans-serif; font-weight:normal;} | |
35 ul.toc {list-style: none} | |
36 --> | |
37 </style> | |
38 | |
39 | |
40 </head> | |
41 | |
42 <body lang="en" bgcolor="#FFFFFF" text="#000000" link="#0000FF" vlink="#800080" alink="#FF0000"> | |
43 | |
44 <table cellpadding="1" cellspacing="1" border="0"> | |
45 <tr><td valign="middle" align="left">[<a href="gettext_9.html#SEC87" title="Beginning of this chapter or previous chapter"> << </a>]</td> | |
46 <td valign="middle" align="left">[<a href="gettext_11.html#SEC197" title="Next chapter"> >> </a>]</td> | |
47 <td valign="middle" align="left"> </td> | |
48 <td valign="middle" align="left"> </td> | |
49 <td valign="middle" align="left"> </td> | |
50 <td valign="middle" align="left"> </td> | |
51 <td valign="middle" align="left"> </td> | |
52 <td valign="middle" align="left">[<a href="gettext_toc.html#SEC_Top" title="Cover (top) of document">Top</a>]</td> | |
53 <td valign="middle" align="left">[<a href="gettext_toc.html#SEC_Contents" title="Table of contents">Contents</a>]</td> | |
54 <td valign="middle" align="left">[<a href="gettext_21.html#SEC389" title="Index">Index</a>]</td> | |
55 <td valign="middle" align="left">[<a href="gettext_abt.html#SEC_About" title="About (help)"> ? </a>]</td> | |
56 </tr></table> | |
57 | |
58 <hr size="2"> | |
59 <a name="Binaries"></a> | |
60 <a name="SEC173"></a> | |
61 <h1 class="chapter"> <a href="gettext_toc.html#TOC166">10. Producing Binary MO Files</a> </h1> | |
62 | |
63 | |
64 | |
65 | |
66 <a name="msgfmt-Invocation"></a> | |
67 <a name="SEC174"></a> | |
68 <h2 class="section"> <a href="gettext_toc.html#TOC167">10.1 Invoking the <code>msgfmt</code> Program</a> </h2> | |
69 | |
70 | |
71 <table><tr><td> </td><td><pre class="example">msgfmt [<var>option</var>] <var>filename</var>.po … | |
72 </pre></td></tr></table> | |
73 | |
74 <a name="IDX928"></a> | |
75 <p>The <code>msgfmt</code> programs generates a binary message catalog from a textual | |
76 translation description. | |
77 </p> | |
78 | |
79 <a name="SEC175"></a> | |
80 <h3 class="subsection"> <a href="gettext_toc.html#TOC168">10.1.1 Input file location</a> </h3> | |
81 | |
82 <dl compact="compact"> | |
83 <dt> ‘<samp><var>filename</var>.po …</samp>’</dt> | |
84 <dt> ‘<samp>-D <var>directory</var></samp>’</dt> | |
85 <dt> ‘<samp>--directory=<var>directory</var></samp>’</dt> | |
86 <dd><a name="IDX929"></a> | |
87 <a name="IDX930"></a> | |
88 <p>Add <var>directory</var> to the list of directories. Source files are | |
89 searched relative to this list of directories. The resulting binary | |
90 file will be written relative to the current directory, though. | |
91 </p> | |
92 </dd> | |
93 </dl> | |
94 | |
95 <p>If an input file is ‘<samp>-</samp>’, standard input is read. | |
96 </p> | |
97 | |
98 <a name="SEC176"></a> | |
99 <h3 class="subsection"> <a href="gettext_toc.html#TOC169">10.1.2 Operation mode</a> </h3> | |
100 | |
101 <dl compact="compact"> | |
102 <dt> ‘<samp>-j</samp>’</dt> | |
103 <dt> ‘<samp>--java</samp>’</dt> | |
104 <dd><a name="IDX931"></a> | |
105 <a name="IDX932"></a> | |
106 <a name="IDX933"></a> | |
107 <p>Java mode: generate a Java <code>ResourceBundle</code> class. | |
108 </p> | |
109 </dd> | |
110 <dt> ‘<samp>--java2</samp>’</dt> | |
111 <dd><a name="IDX934"></a> | |
112 <p>Like –java, and assume Java2 (JDK 1.2 or higher). | |
113 </p> | |
114 </dd> | |
115 <dt> ‘<samp>--csharp</samp>’</dt> | |
116 <dd><a name="IDX935"></a> | |
117 <a name="IDX936"></a> | |
118 <p>C# mode: generate a .NET .dll file containing a subclass of | |
119 <code>GettextResourceSet</code>. | |
120 </p> | |
121 </dd> | |
122 <dt> ‘<samp>--csharp-resources</samp>’</dt> | |
123 <dd><a name="IDX937"></a> | |
124 <a name="IDX938"></a> | |
125 <p>C# resources mode: generate a .NET ‘<tt>.resources</tt>’ file. | |
126 </p> | |
127 </dd> | |
128 <dt> ‘<samp>--tcl</samp>’</dt> | |
129 <dd><a name="IDX939"></a> | |
130 <a name="IDX940"></a> | |
131 <p>Tcl mode: generate a tcl/msgcat ‘<tt>.msg</tt>’ file. | |
132 </p> | |
133 </dd> | |
134 <dt> ‘<samp>--qt</samp>’</dt> | |
135 <dd><a name="IDX941"></a> | |
136 <a name="IDX942"></a> | |
137 <p>Qt mode: generate a Qt ‘<tt>.qm</tt>’ file. | |
138 </p> | |
139 </dd> | |
140 <dt> ‘<samp>--desktop</samp>’</dt> | |
141 <dd><a name="IDX943"></a> | |
142 <a name="IDX944"></a> | |
143 <p>Desktop Entry mode: generate a ‘<tt>.desktop</tt>’ file. | |
144 </p> | |
145 </dd> | |
146 <dt> ‘<samp>--xml</samp>’</dt> | |
147 <dd><a name="IDX945"></a> | |
148 <a name="IDX946"></a> | |
149 <p>XML mode: generate an XML file. | |
150 </p> | |
151 </dd> | |
152 </dl> | |
153 | |
154 | |
155 <a name="SEC177"></a> | |
156 <h3 class="subsection"> <a href="gettext_toc.html#TOC170">10.1.3 Output file location</a> </h3> | |
157 | |
158 <dl compact="compact"> | |
159 <dt> ‘<samp>-o <var>file</var></samp>’</dt> | |
160 <dt> ‘<samp>--output-file=<var>file</var></samp>’</dt> | |
161 <dd><a name="IDX947"></a> | |
162 <a name="IDX948"></a> | |
163 <p>Write output to specified file. | |
164 </p> | |
165 </dd> | |
166 <dt> ‘<samp>--strict</samp>’</dt> | |
167 <dd><a name="IDX949"></a> | |
168 <p>Direct the program to work strictly following the Uniforum/Sun | |
169 implementation. Currently this only affects the naming of the output | |
170 file. If this option is not given the name of the output file is the | |
171 same as the domain name. If the strict Uniforum mode is enabled the | |
172 suffix ‘<tt>.mo</tt>’ is added to the file name if it is not already | |
173 present. | |
174 </p> | |
175 <p>We find this behaviour of Sun's implementation rather silly and so by | |
176 default this mode is <em>not</em> selected. | |
177 </p> | |
178 </dd> | |
179 </dl> | |
180 | |
181 <p>If the output <var>file</var> is ‘<samp>-</samp>’, output is written to standard output. | |
182 </p> | |
183 | |
184 <a name="SEC178"></a> | |
185 <h3 class="subsection"> <a href="gettext_toc.html#TOC171">10.1.4 Output file location in Java mode</a> </h3> | |
186 | |
187 <dl compact="compact"> | |
188 <dt> ‘<samp>-r <var>resource</var></samp>’</dt> | |
189 <dt> ‘<samp>--resource=<var>resource</var></samp>’</dt> | |
190 <dd><a name="IDX950"></a> | |
191 <a name="IDX951"></a> | |
192 <p>Specify the resource name. | |
193 </p> | |
194 </dd> | |
195 <dt> ‘<samp>-l <var>locale</var></samp>’</dt> | |
196 <dt> ‘<samp>--locale=<var>locale</var></samp>’</dt> | |
197 <dd><a name="IDX952"></a> | |
198 <a name="IDX953"></a> | |
199 <p>Specify the locale name, either a language specification of the form <var>ll</var> | |
200 or a combined language and country specification of the form <var>ll_CC</var>. | |
201 </p> | |
202 </dd> | |
203 <dt> ‘<samp>-d <var>directory</var></samp>’</dt> | |
204 <dd><a name="IDX954"></a> | |
205 <p>Specify the base directory of classes directory hierarchy. | |
206 </p> | |
207 </dd> | |
208 <dt> ‘<samp>--source</samp>’</dt> | |
209 <dd><a name="IDX955"></a> | |
210 <p>Produce a .java source file, instead of a compiled .class file. | |
211 </p> | |
212 </dd> | |
213 </dl> | |
214 | |
215 <p>The class name is determined by appending the locale name to the resource name, | |
216 separated with an underscore. The ‘<samp>-d</samp>’ option is mandatory. The class | |
217 is written under the specified directory. | |
218 </p> | |
219 | |
220 <a name="SEC179"></a> | |
221 <h3 class="subsection"> <a href="gettext_toc.html#TOC172">10.1.5 Output file location in C# mode</a> </h3> | |
222 | |
223 <dl compact="compact"> | |
224 <dt> ‘<samp>-r <var>resource</var></samp>’</dt> | |
225 <dt> ‘<samp>--resource=<var>resource</var></samp>’</dt> | |
226 <dd><a name="IDX956"></a> | |
227 <a name="IDX957"></a> | |
228 <p>Specify the resource name. | |
229 </p> | |
230 </dd> | |
231 <dt> ‘<samp>-l <var>locale</var></samp>’</dt> | |
232 <dt> ‘<samp>--locale=<var>locale</var></samp>’</dt> | |
233 <dd><a name="IDX958"></a> | |
234 <a name="IDX959"></a> | |
235 <p>Specify the locale name, either a language specification of the form <var>ll</var> | |
236 or a combined language and country specification of the form <var>ll_CC</var>. | |
237 </p> | |
238 </dd> | |
239 <dt> ‘<samp>-d <var>directory</var></samp>’</dt> | |
240 <dd><a name="IDX960"></a> | |
241 <p>Specify the base directory for locale dependent ‘<tt>.dll</tt>’ files. | |
242 </p> | |
243 </dd> | |
244 </dl> | |
245 | |
246 <p>The ‘<samp>-l</samp>’ and ‘<samp>-d</samp>’ options are mandatory. The ‘<tt>.dll</tt>’ file is | |
247 written in a subdirectory of the specified directory whose name depends on the | |
248 locale. | |
249 </p> | |
250 | |
251 <a name="SEC180"></a> | |
252 <h3 class="subsection"> <a href="gettext_toc.html#TOC173">10.1.6 Output file location in Tcl mode</a> </h3> | |
253 | |
254 <dl compact="compact"> | |
255 <dt> ‘<samp>-l <var>locale</var></samp>’</dt> | |
256 <dt> ‘<samp>--locale=<var>locale</var></samp>’</dt> | |
257 <dd><a name="IDX961"></a> | |
258 <a name="IDX962"></a> | |
259 <p>Specify the locale name, either a language specification of the form <var>ll</var> | |
260 or a combined language and country specification of the form <var>ll_CC</var>. | |
261 </p> | |
262 </dd> | |
263 <dt> ‘<samp>-d <var>directory</var></samp>’</dt> | |
264 <dd><a name="IDX963"></a> | |
265 <p>Specify the base directory of ‘<tt>.msg</tt>’ message catalogs. | |
266 </p> | |
267 </dd> | |
268 </dl> | |
269 | |
270 <p>The ‘<samp>-l</samp>’ and ‘<samp>-d</samp>’ options are mandatory. The ‘<tt>.msg</tt>’ file is | |
271 written in the specified directory. | |
272 </p> | |
273 | |
274 <a name="SEC181"></a> | |
275 <h3 class="subsection"> <a href="gettext_toc.html#TOC174">10.1.7 Desktop Entry mode operations</a> </h3> | |
276 | |
277 <dl compact="compact"> | |
278 <dt> ‘<samp>--template=<var>template</var></samp>’</dt> | |
279 <dd><a name="IDX964"></a> | |
280 <p>Specify a .desktop file used as a template. | |
281 </p> | |
282 </dd> | |
283 <dt> ‘<samp>-k[<var>keywordspec</var>]</samp>’</dt> | |
284 <dt> ‘<samp>--keyword[=<var>keywordspec</var>]</samp>’</dt> | |
285 <dd><a name="IDX965"></a> | |
286 <a name="IDX966"></a> | |
287 <p>Specify <var>keywordspec</var> as an additional keyword to be looked for. | |
288 Without a <var>keywordspec</var>, the option means to not use default keywords. | |
289 </p> | |
290 </dd> | |
291 <dt> ‘<samp>-l <var>locale</var></samp>’</dt> | |
292 <dt> ‘<samp>--locale=<var>locale</var></samp>’</dt> | |
293 <dd><a name="IDX967"></a> | |
294 <a name="IDX968"></a> | |
295 <p>Specify the locale name, either a language specification of the form <var>ll</var> | |
296 or a combined language and country specification of the form <var>ll_CC</var>. | |
297 </p> | |
298 </dd> | |
299 <dt> ‘<samp>-d <var>directory</var></samp>’</dt> | |
300 <dd><a name="IDX969"></a> | |
301 <p>Specify the directory where PO files are read. The directory must | |
302 contain the ‘<samp>LINGUAS</samp>’ file. | |
303 </p> | |
304 </dd> | |
305 </dl> | |
306 | |
307 <p>To generate a ‘<samp>.desktop</samp>’ file for a single locale, you can use it | |
308 as follows. | |
309 </p> | |
310 <table><tr><td> </td><td><pre class="example">msgfmt --desktop --template=<var>template</var> --locale=<var>locale</var> \ | |
311 -o <var>file</var> <var>filename</var>.po … | |
312 </pre></td></tr></table> | |
313 | |
314 <p>msgfmt provides a special "bulk" operation mode to process multiple | |
315 ‘<tt>.po</tt>’ files at a time. | |
316 </p> | |
317 <table><tr><td> </td><td><pre class="example">msgfmt --desktop --template=<var>template</var> -d <var>directory</var> -o <var>file</var> | |
318 </pre></td></tr></table> | |
319 | |
320 <p>msgfmt first reads the ‘<samp>LINGUAS</samp>’ file under <var>directory</var>, and | |
321 then processes all ‘<samp>.po</samp>’ files listed there. You can also limit | |
322 the locales to a subset, through the ‘<samp>LINGUAS</samp>’ environment | |
323 variable. | |
324 </p> | |
325 <p>For either operation modes, the ‘<samp>-o</samp>’ and ‘<samp>--template</samp>’ | |
326 options are mandatory. | |
327 </p> | |
328 | |
329 <a name="SEC182"></a> | |
330 <h3 class="subsection"> <a href="gettext_toc.html#TOC175">10.1.8 XML mode operations</a> </h3> | |
331 | |
332 <dl compact="compact"> | |
333 <dt> ‘<samp>--template=<var>template</var></samp>’</dt> | |
334 <dd><a name="IDX970"></a> | |
335 <p>Specify an XML file used as a template. | |
336 </p> | |
337 </dd> | |
338 <dt> ‘<samp>-L <var>name</var></samp>’</dt> | |
339 <dt> ‘<samp>--language=<var>name</var></samp>’</dt> | |
340 <dd><a name="IDX971"></a> | |
341 <a name="IDX972"></a> | |
342 <a name="IDX973"></a> | |
343 <p>Specifies the language of the input files. | |
344 </p> | |
345 </dd> | |
346 <dt> ‘<samp>-l <var>locale</var></samp>’</dt> | |
347 <dt> ‘<samp>--locale=<var>locale</var></samp>’</dt> | |
348 <dd><a name="IDX974"></a> | |
349 <a name="IDX975"></a> | |
350 <p>Specify the locale name, either a language specification of the form <var>ll</var> | |
351 or a combined language and country specification of the form <var>ll_CC</var>. | |
352 </p> | |
353 </dd> | |
354 <dt> ‘<samp>-d <var>directory</var></samp>’</dt> | |
355 <dd><a name="IDX976"></a> | |
356 <p>Specify the base directory of ‘<tt>.po</tt>’ message catalogs. | |
357 </p> | |
358 </dd> | |
359 </dl> | |
360 | |
361 <p>To generate an XML file for a single locale, you can use it as follows. | |
362 </p> | |
363 <table><tr><td> </td><td><pre class="example">msgfmt --xml --template=<var>template</var> --locale=<var>locale</var> \ | |
364 -o <var>file</var> <var>filename</var>.po … | |
365 </pre></td></tr></table> | |
366 | |
367 <p>msgfmt provides a special "bulk" operation mode to process multiple | |
368 ‘<tt>.po</tt>’ files at a time. | |
369 </p> | |
370 <table><tr><td> </td><td><pre class="example">msgfmt --xml --template=<var>template</var> -d <var>directory</var> -o <var>file</var> | |
371 </pre></td></tr></table> | |
372 | |
373 <p>msgfmt first reads the ‘<samp>LINGUAS</samp>’ file under <var>directory</var>, and | |
374 then processes all ‘<samp>.po</samp>’ files listed there. You can also limit | |
375 the locales to a subset, through the ‘<samp>LINGUAS</samp>’ environment | |
376 variable. | |
377 </p> | |
378 <p>For either operation modes, the ‘<samp>-o</samp>’ and ‘<samp>--template</samp>’ | |
379 options are mandatory. | |
380 </p> | |
381 | |
382 <a name="SEC183"></a> | |
383 <h3 class="subsection"> <a href="gettext_toc.html#TOC176">10.1.9 Input file syntax</a> </h3> | |
384 | |
385 <dl compact="compact"> | |
386 <dt> ‘<samp>-P</samp>’</dt> | |
387 <dt> ‘<samp>--properties-input</samp>’</dt> | |
388 <dd><a name="IDX977"></a> | |
389 <a name="IDX978"></a> | |
390 <p>Assume the input files are Java ResourceBundles in Java <code>.properties</code> | |
391 syntax, not in PO file syntax. | |
392 </p> | |
393 </dd> | |
394 <dt> ‘<samp>--stringtable-input</samp>’</dt> | |
395 <dd><a name="IDX979"></a> | |
396 <p>Assume the input files are NeXTstep/GNUstep localized resource files in | |
397 <code>.strings</code> syntax, not in PO file syntax. | |
398 </p> | |
399 </dd> | |
400 </dl> | |
401 | |
402 | |
403 <a name="SEC184"></a> | |
404 <h3 class="subsection"> <a href="gettext_toc.html#TOC177">10.1.10 Input file interpretation</a> </h3> | |
405 | |
406 <dl compact="compact"> | |
407 <dt> ‘<samp>-c</samp>’</dt> | |
408 <dt> ‘<samp>--check</samp>’</dt> | |
409 <dd><a name="IDX980"></a> | |
410 <a name="IDX981"></a> | |
411 <p>Perform all the checks implied by <code>--check-format</code>, <code>--check-header</code>, | |
412 <code>--check-domain</code>. | |
413 </p> | |
414 </dd> | |
415 <dt> ‘<samp>--check-format</samp>’</dt> | |
416 <dd><a name="IDX982"></a> | |
417 <a name="IDX983"></a> | |
418 <p>Check language dependent format strings. | |
419 </p> | |
420 <p>If the string represents a format string used in a | |
421 <code>printf</code>-like function both strings should have the same number of | |
422 ‘<samp>%</samp>’ format specifiers, with matching types. If the flag | |
423 <code>c-format</code> or <code>possible-c-format</code> appears in the special | |
424 comment <#,> for this entry a check is performed. For example, the | |
425 check will diagnose using ‘<samp>%.*s</samp>’ against ‘<samp>%s</samp>’, or ‘<samp>%d</samp>’ | |
426 against ‘<samp>%s</samp>’, or ‘<samp>%d</samp>’ against ‘<samp>%x</samp>’. It can even handle | |
427 positional parameters. | |
428 </p> | |
429 <p>Normally the <code>xgettext</code> program automatically decides whether a | |
430 string is a format string or not. This algorithm is not perfect, | |
431 though. It might regard a string as a format string though it is not | |
432 used in a <code>printf</code>-like function and so <code>msgfmt</code> might report | |
433 errors where there are none. | |
434 </p> | |
435 <p>To solve this problem the programmer can dictate the decision to the | |
436 <code>xgettext</code> program (see section <a href="gettext_15.html#SEC267">C Format Strings</a>). The translator should not | |
437 consider removing the flag from the <#,> line. This "fix" would be | |
438 reversed again as soon as <code>msgmerge</code> is called the next time. | |
439 </p> | |
440 </dd> | |
441 <dt> ‘<samp>--check-header</samp>’</dt> | |
442 <dd><a name="IDX984"></a> | |
443 <p>Verify presence and contents of the header entry. See section <a href="gettext_6.html#SEC52">Filling in the Header Entry</a>, | |
444 for a description of the various fields in the header entry. | |
445 </p> | |
446 </dd> | |
447 <dt> ‘<samp>--check-domain</samp>’</dt> | |
448 <dd><a name="IDX985"></a> | |
449 <p>Check for conflicts between domain directives and the <code>--output-file</code> | |
450 option | |
451 </p> | |
452 </dd> | |
453 <dt> ‘<samp>-C</samp>’</dt> | |
454 <dt> ‘<samp>--check-compatibility</samp>’</dt> | |
455 <dd><a name="IDX986"></a> | |
456 <a name="IDX987"></a> | |
457 <a name="IDX988"></a> | |
458 <p>Check that GNU msgfmt behaves like X/Open msgfmt. This will give an error | |
459 when attempting to use the GNU extensions. | |
460 </p> | |
461 </dd> | |
462 <dt> ‘<samp>--check-accelerators[=<var>char</var>]</samp>’</dt> | |
463 <dd><a name="IDX989"></a> | |
464 <a name="IDX990"></a> | |
465 <a name="IDX991"></a> | |
466 <a name="IDX992"></a> | |
467 <p>Check presence of keyboard accelerators for menu items. This is based on | |
468 the convention used in some GUIs that a keyboard accelerator in a menu | |
469 item string is designated by an immediately preceding ‘<samp>&</samp>’ character. | |
470 Sometimes a keyboard accelerator is also called "keyboard mnemonic". | |
471 This check verifies that if the untranslated string has exactly one | |
472 ‘<samp>&</samp>’ character, the translated string has exactly one ‘<samp>&</samp>’ as well. | |
473 If this option is given with a <var>char</var> argument, this <var>char</var> should | |
474 be a non-alphanumeric character and is used as keyboard accelerator mark | |
475 instead of ‘<samp>&</samp>’. | |
476 </p> | |
477 </dd> | |
478 <dt> ‘<samp>-f</samp>’</dt> | |
479 <dt> ‘<samp>--use-fuzzy</samp>’</dt> | |
480 <dd><a name="IDX993"></a> | |
481 <a name="IDX994"></a> | |
482 <a name="IDX995"></a> | |
483 <p>Use fuzzy entries in output. Note that using this option is usually wrong, | |
484 because fuzzy messages are exactly those which have not been validated by | |
485 a human translator. | |
486 </p> | |
487 </dd> | |
488 </dl> | |
489 | |
490 | |
491 <a name="SEC185"></a> | |
492 <h3 class="subsection"> <a href="gettext_toc.html#TOC178">10.1.11 Output details</a> </h3> | |
493 | |
494 <dl compact="compact"> | |
495 <dt> ‘<samp>--no-convert</samp>’</dt> | |
496 <dd><a name="IDX996"></a> | |
497 <p>Don't convert the messages to UTF-8 encoding. By default, messages are | |
498 converted to UTF-8 encoding before being stored in a MO file; this helps | |
499 avoiding conversions at run time, since nowadays most locales use the | |
500 UTF-8 encoding. | |
501 </p> | |
502 </dd> | |
503 <dt> ‘<samp>--no-redundancy</samp>’</dt> | |
504 <dd><a name="IDX997"></a> | |
505 <p>Don't pre-expand ISO C 99 <inttypes.h> format string directive macros. | |
506 By default, messages that are marked as <code>c-format</code> and contain | |
507 ISO C 99 <inttypes.h> format string directive macros are pre-expanded | |
508 for selected platforms, and these redundant expansions are stored in the | |
509 MO file. These redundant expansions make the translations of these | |
510 messages work with the <code>gettext</code> implementation in the <code>libc</code> | |
511 of that platform, without requiring GNU <code>gettext</code>'s <code>libintl</code>. | |
512 The platforms that benefit from this pre-expansion are those with the | |
513 musl libc. | |
514 </p> | |
515 </dd> | |
516 <dt> ‘<samp>-a <var>number</var></samp>’</dt> | |
517 <dt> ‘<samp>--alignment=<var>number</var></samp>’</dt> | |
518 <dd><a name="IDX998"></a> | |
519 <a name="IDX999"></a> | |
520 <p>Align strings to <var>number</var> bytes (default: 1). | |
521 </p> | |
522 </dd> | |
523 <dt> ‘<samp>--endianness=<var>byteorder</var></samp>’</dt> | |
524 <dd><a name="IDX1000"></a> | |
525 <p>Write out 32-bit numbers in the given byte order. The possible values are | |
526 <code>big</code> and <code>little</code>. The default is <code>little</code>. | |
527 </p> | |
528 <p>MO files of any endianness can be used on any platform. When a MO file has | |
529 an endianness other than the platform's one, the 32-bit numbers from the MO | |
530 file are swapped at runtime. The performance impact is negligible. | |
531 </p> | |
532 <p>This option can be useful to produce MO files that are optimized for one | |
533 platform. | |
534 </p> | |
535 </dd> | |
536 <dt> ‘<samp>--no-hash</samp>’</dt> | |
537 <dd><a name="IDX1001"></a> | |
538 <p>Don't include a hash table in the binary file. Lookup will be more expensive | |
539 at run time (binary search instead of hash table lookup). | |
540 </p> | |
541 </dd> | |
542 </dl> | |
543 | |
544 | |
545 <a name="SEC186"></a> | |
546 <h3 class="subsection"> <a href="gettext_toc.html#TOC179">10.1.12 Informative output</a> </h3> | |
547 | |
548 <dl compact="compact"> | |
549 <dt> ‘<samp>-h</samp>’</dt> | |
550 <dt> ‘<samp>--help</samp>’</dt> | |
551 <dd><a name="IDX1002"></a> | |
552 <a name="IDX1003"></a> | |
553 <p>Display this help and exit. | |
554 </p> | |
555 </dd> | |
556 <dt> ‘<samp>-V</samp>’</dt> | |
557 <dt> ‘<samp>--version</samp>’</dt> | |
558 <dd><a name="IDX1004"></a> | |
559 <a name="IDX1005"></a> | |
560 <p>Output version information and exit. | |
561 </p> | |
562 </dd> | |
563 <dt> ‘<samp>--statistics</samp>’</dt> | |
564 <dd><a name="IDX1006"></a> | |
565 <p>Print statistics about translations. When the option <code>--verbose</code> is used | |
566 in combination with <code>--statistics</code>, the input file name is printed in | |
567 front of the statistics line. | |
568 </p> | |
569 </dd> | |
570 <dt> ‘<samp>-v</samp>’</dt> | |
571 <dt> ‘<samp>--verbose</samp>’</dt> | |
572 <dd><a name="IDX1007"></a> | |
573 <a name="IDX1008"></a> | |
574 <p>Increase verbosity level. | |
575 </p> | |
576 </dd> | |
577 </dl> | |
578 | |
579 | |
580 <a name="msgunfmt-Invocation"></a> | |
581 <a name="SEC187"></a> | |
582 <h2 class="section"> <a href="gettext_toc.html#TOC180">10.2 Invoking the <code>msgunfmt</code> Program</a> </h2> | |
583 | |
584 | |
585 <table><tr><td> </td><td><pre class="example">msgunfmt [<var>option</var>] [<var>file</var>]... | |
586 </pre></td></tr></table> | |
587 | |
588 <a name="IDX1009"></a> | |
589 <p>The <code>msgunfmt</code> program converts a binary message catalog to a | |
590 Uniforum style .po file. | |
591 </p> | |
592 | |
593 <a name="SEC188"></a> | |
594 <h3 class="subsection"> <a href="gettext_toc.html#TOC181">10.2.1 Operation mode</a> </h3> | |
595 | |
596 <dl compact="compact"> | |
597 <dt> ‘<samp>-j</samp>’</dt> | |
598 <dt> ‘<samp>--java</samp>’</dt> | |
599 <dd><a name="IDX1010"></a> | |
600 <a name="IDX1011"></a> | |
601 <a name="IDX1012"></a> | |
602 <p>Java mode: input is a Java <code>ResourceBundle</code> class. | |
603 </p> | |
604 </dd> | |
605 <dt> ‘<samp>--csharp</samp>’</dt> | |
606 <dd><a name="IDX1013"></a> | |
607 <a name="IDX1014"></a> | |
608 <p>C# mode: input is a .NET .dll file containing a subclass of | |
609 <code>GettextResourceSet</code>. | |
610 </p> | |
611 </dd> | |
612 <dt> ‘<samp>--csharp-resources</samp>’</dt> | |
613 <dd><a name="IDX1015"></a> | |
614 <a name="IDX1016"></a> | |
615 <p>C# resources mode: input is a .NET ‘<tt>.resources</tt>’ file. | |
616 </p> | |
617 </dd> | |
618 <dt> ‘<samp>--tcl</samp>’</dt> | |
619 <dd><a name="IDX1017"></a> | |
620 <a name="IDX1018"></a> | |
621 <p>Tcl mode: input is a tcl/msgcat ‘<tt>.msg</tt>’ file. | |
622 </p> | |
623 </dd> | |
624 </dl> | |
625 | |
626 | |
627 <a name="SEC189"></a> | |
628 <h3 class="subsection"> <a href="gettext_toc.html#TOC182">10.2.2 Input file location</a> </h3> | |
629 | |
630 <dl compact="compact"> | |
631 <dt> ‘<samp><var>file</var> …</samp>’</dt> | |
632 <dd><p>Input .mo files. | |
633 </p> | |
634 </dd> | |
635 </dl> | |
636 | |
637 <p>If no input <var>file</var> is given or if it is ‘<samp>-</samp>’, standard input is read. | |
638 </p> | |
639 | |
640 <a name="SEC190"></a> | |
641 <h3 class="subsection"> <a href="gettext_toc.html#TOC183">10.2.3 Input file location in Java mode</a> </h3> | |
642 | |
643 <dl compact="compact"> | |
644 <dt> ‘<samp>-r <var>resource</var></samp>’</dt> | |
645 <dt> ‘<samp>--resource=<var>resource</var></samp>’</dt> | |
646 <dd><a name="IDX1019"></a> | |
647 <a name="IDX1020"></a> | |
648 <p>Specify the resource name. | |
649 </p> | |
650 </dd> | |
651 <dt> ‘<samp>-l <var>locale</var></samp>’</dt> | |
652 <dt> ‘<samp>--locale=<var>locale</var></samp>’</dt> | |
653 <dd><a name="IDX1021"></a> | |
654 <a name="IDX1022"></a> | |
655 <p>Specify the locale name, either a language specification of the form <var>ll</var> | |
656 or a combined language and country specification of the form <var>ll_CC</var>. | |
657 </p> | |
658 </dd> | |
659 </dl> | |
660 | |
661 <p>The class name is determined by appending the locale name to the resource name, | |
662 separated with an underscore. The class is located using the <code>CLASSPATH</code>. | |
663 </p> | |
664 | |
665 <a name="SEC191"></a> | |
666 <h3 class="subsection"> <a href="gettext_toc.html#TOC184">10.2.4 Input file location in C# mode</a> </h3> | |
667 | |
668 <dl compact="compact"> | |
669 <dt> ‘<samp>-r <var>resource</var></samp>’</dt> | |
670 <dt> ‘<samp>--resource=<var>resource</var></samp>’</dt> | |
671 <dd><a name="IDX1023"></a> | |
672 <a name="IDX1024"></a> | |
673 <p>Specify the resource name. | |
674 </p> | |
675 </dd> | |
676 <dt> ‘<samp>-l <var>locale</var></samp>’</dt> | |
677 <dt> ‘<samp>--locale=<var>locale</var></samp>’</dt> | |
678 <dd><a name="IDX1025"></a> | |
679 <a name="IDX1026"></a> | |
680 <p>Specify the locale name, either a language specification of the form <var>ll</var> | |
681 or a combined language and country specification of the form <var>ll_CC</var>. | |
682 </p> | |
683 </dd> | |
684 <dt> ‘<samp>-d <var>directory</var></samp>’</dt> | |
685 <dd><a name="IDX1027"></a> | |
686 <p>Specify the base directory for locale dependent ‘<tt>.dll</tt>’ files. | |
687 </p> | |
688 </dd> | |
689 </dl> | |
690 | |
691 <p>The ‘<samp>-l</samp>’ and ‘<samp>-d</samp>’ options are mandatory. The ‘<tt>.msg</tt>’ file is | |
692 located in a subdirectory of the specified directory whose name depends on the | |
693 locale. | |
694 </p> | |
695 | |
696 <a name="SEC192"></a> | |
697 <h3 class="subsection"> <a href="gettext_toc.html#TOC185">10.2.5 Input file location in Tcl mode</a> </h3> | |
698 | |
699 <dl compact="compact"> | |
700 <dt> ‘<samp>-l <var>locale</var></samp>’</dt> | |
701 <dt> ‘<samp>--locale=<var>locale</var></samp>’</dt> | |
702 <dd><a name="IDX1028"></a> | |
703 <a name="IDX1029"></a> | |
704 <p>Specify the locale name, either a language specification of the form <var>ll</var> | |
705 or a combined language and country specification of the form <var>ll_CC</var>. | |
706 </p> | |
707 </dd> | |
708 <dt> ‘<samp>-d <var>directory</var></samp>’</dt> | |
709 <dd><a name="IDX1030"></a> | |
710 <p>Specify the base directory of ‘<tt>.msg</tt>’ message catalogs. | |
711 </p> | |
712 </dd> | |
713 </dl> | |
714 | |
715 <p>The ‘<samp>-l</samp>’ and ‘<samp>-d</samp>’ options are mandatory. The ‘<tt>.msg</tt>’ file is | |
716 located in the specified directory. | |
717 </p> | |
718 | |
719 <a name="SEC193"></a> | |
720 <h3 class="subsection"> <a href="gettext_toc.html#TOC186">10.2.6 Output file location</a> </h3> | |
721 | |
722 <dl compact="compact"> | |
723 <dt> ‘<samp>-o <var>file</var></samp>’</dt> | |
724 <dt> ‘<samp>--output-file=<var>file</var></samp>’</dt> | |
725 <dd><a name="IDX1031"></a> | |
726 <a name="IDX1032"></a> | |
727 <p>Write output to specified file. | |
728 </p> | |
729 </dd> | |
730 </dl> | |
731 | |
732 <p>The results are written to standard output if no output file is specified | |
733 or if it is ‘<samp>-</samp>’. | |
734 </p> | |
735 | |
736 <a name="SEC194"></a> | |
737 <h3 class="subsection"> <a href="gettext_toc.html#TOC187">10.2.7 Output details</a> </h3> | |
738 | |
739 | |
740 <dl compact="compact"> | |
741 <dt> ‘<samp>--color</samp>’</dt> | |
742 <dt> ‘<samp>--color=<var>when</var></samp>’</dt> | |
743 <dd><a name="IDX1033"></a> | |
744 <p>Specify whether or when to use colors and other text attributes. | |
745 See <a href="gettext_9.html#SEC158">The <code>--color</code> option</a> for details. | |
746 </p> | |
747 </dd> | |
748 <dt> ‘<samp>--style=<var>style_file</var></samp>’</dt> | |
749 <dd><a name="IDX1034"></a> | |
750 <p>Specify the CSS style rule file to use for <code>--color</code>. | |
751 See <a href="gettext_9.html#SEC160">The <code>--style</code> option</a> for details. | |
752 </p> | |
753 </dd> | |
754 <dt> ‘<samp>--force-po</samp>’</dt> | |
755 <dd><a name="IDX1035"></a> | |
756 <p>Always write an output file even if it contains no message. | |
757 </p> | |
758 </dd> | |
759 <dt> ‘<samp>-i</samp>’</dt> | |
760 <dt> ‘<samp>--indent</samp>’</dt> | |
761 <dd><a name="IDX1036"></a> | |
762 <a name="IDX1037"></a> | |
763 <p>Write the .po file using indented style. | |
764 </p> | |
765 </dd> | |
766 <dt> ‘<samp>--strict</samp>’</dt> | |
767 <dd><a name="IDX1038"></a> | |
768 <p>Write out a strict Uniforum conforming PO file. Note that this | |
769 Uniforum format should be avoided because it doesn't support the | |
770 GNU extensions. | |
771 </p> | |
772 </dd> | |
773 <dt> ‘<samp>-p</samp>’</dt> | |
774 <dt> ‘<samp>--properties-output</samp>’</dt> | |
775 <dd><a name="IDX1039"></a> | |
776 <a name="IDX1040"></a> | |
777 <p>Write out a Java ResourceBundle in Java <code>.properties</code> syntax. Note | |
778 that this file format doesn't support plural forms and silently drops | |
779 obsolete messages. | |
780 </p> | |
781 </dd> | |
782 <dt> ‘<samp>--stringtable-output</samp>’</dt> | |
783 <dd><a name="IDX1041"></a> | |
784 <p>Write out a NeXTstep/GNUstep localized resource file in <code>.strings</code> syntax. | |
785 Note that this file format doesn't support plural forms. | |
786 </p> | |
787 </dd> | |
788 <dt> ‘<samp>-w <var>number</var></samp>’</dt> | |
789 <dt> ‘<samp>--width=<var>number</var></samp>’</dt> | |
790 <dd><a name="IDX1042"></a> | |
791 <a name="IDX1043"></a> | |
792 <p>Set the output page width. Long strings in the output files will be | |
793 split across multiple lines in order to ensure that each line's width | |
794 (= number of screen columns) is less or equal to the given <var>number</var>. | |
795 </p> | |
796 </dd> | |
797 <dt> ‘<samp>--no-wrap</samp>’</dt> | |
798 <dd><a name="IDX1044"></a> | |
799 <p>Do not break long message lines. Message lines whose width exceeds the | |
800 output page width will not be split into several lines. Only file reference | |
801 lines which are wider than the output page width will be split. | |
802 </p> | |
803 </dd> | |
804 <dt> ‘<samp>-s</samp>’</dt> | |
805 <dt> ‘<samp>--sort-output</samp>’</dt> | |
806 <dd><a name="IDX1045"></a> | |
807 <a name="IDX1046"></a> | |
808 <a name="IDX1047"></a> | |
809 <p>Generate sorted output. Note that using this option makes it much harder | |
810 for the translator to understand each message's context. | |
811 </p> | |
812 </dd> | |
813 </dl> | |
814 | |
815 | |
816 <a name="SEC195"></a> | |
817 <h3 class="subsection"> <a href="gettext_toc.html#TOC188">10.2.8 Informative output</a> </h3> | |
818 | |
819 <dl compact="compact"> | |
820 <dt> ‘<samp>-h</samp>’</dt> | |
821 <dt> ‘<samp>--help</samp>’</dt> | |
822 <dd><a name="IDX1048"></a> | |
823 <a name="IDX1049"></a> | |
824 <p>Display this help and exit. | |
825 </p> | |
826 </dd> | |
827 <dt> ‘<samp>-V</samp>’</dt> | |
828 <dt> ‘<samp>--version</samp>’</dt> | |
829 <dd><a name="IDX1050"></a> | |
830 <a name="IDX1051"></a> | |
831 <p>Output version information and exit. | |
832 </p> | |
833 </dd> | |
834 <dt> ‘<samp>-v</samp>’</dt> | |
835 <dt> ‘<samp>--verbose</samp>’</dt> | |
836 <dd><a name="IDX1052"></a> | |
837 <a name="IDX1053"></a> | |
838 <p>Increase verbosity level. | |
839 </p> | |
840 </dd> | |
841 </dl> | |
842 | |
843 | |
844 <a name="MO-Files"></a> | |
845 <a name="SEC196"></a> | |
846 <h2 class="section"> <a href="gettext_toc.html#TOC189">10.3 The Format of GNU MO Files</a> </h2> | |
847 | |
848 <p>The format of the generated MO files is best described by a picture, | |
849 which appears below. | |
850 </p> | |
851 <a name="IDX1054"></a> | |
852 <p>The first two words serve the identification of the file. The magic | |
853 number will always signal GNU MO files. The number is stored in the | |
854 byte order used when the MO file was generated, so the magic number | |
855 really is two numbers: <code>0x950412de</code> and <code>0xde120495</code>. | |
856 </p> | |
857 <p>The second word describes the current revision of the file format, | |
858 composed of a major and a minor revision number. The revision numbers | |
859 ensure that the readers of MO files can distinguish new formats from | |
860 old ones and handle their contents, as far as possible. For now the | |
861 major revision is 0 or 1, and the minor revision is also 0 or 1. More | |
862 revisions might be added in the future. A program seeing an unexpected | |
863 major revision number should stop reading the MO file entirely; whereas | |
864 an unexpected minor revision number means that the file can be read but | |
865 will not reveal its full contents, when parsed by a program that | |
866 supports only smaller minor revision numbers. | |
867 </p> | |
868 <p>The version is kept | |
869 separate from the magic number, instead of using different magic | |
870 numbers for different formats, mainly because ‘<tt>/etc/magic</tt>’ is | |
871 not updated often. | |
872 </p> | |
873 <p>Follow a number of pointers to later tables in the file, allowing | |
874 for the extension of the prefix part of MO files without having to | |
875 recompile programs reading them. This might become useful for later | |
876 inserting a few flag bits, indication about the charset used, new | |
877 tables, or other things. | |
878 </p> | |
879 <p>Then, at offset <var>O</var> and offset <var>T</var> in the picture, two tables | |
880 of string descriptors can be found. In both tables, each string | |
881 descriptor uses two 32 bits integers, one for the string length, | |
882 another for the offset of the string in the MO file, counting in bytes | |
883 from the start of the file. The first table contains descriptors | |
884 for the original strings, and is sorted so the original strings | |
885 are in increasing lexicographical order. The second table contains | |
886 descriptors for the translated strings, and is parallel to the first | |
887 table: to find the corresponding translation one has to access the | |
888 array slot in the second array with the same index. | |
889 </p> | |
890 <p>Having the original strings sorted enables the use of simple binary | |
891 search, for when the MO file does not contain an hashing table, or | |
892 for when it is not practical to use the hashing table provided in | |
893 the MO file. This also has another advantage, as the empty string | |
894 in a PO file GNU <code>gettext</code> is usually <em>translated</em> into | |
895 some system information attached to that particular MO file, and the | |
896 empty string necessarily becomes the first in both the original and | |
897 translated tables, making the system information very easy to find. | |
898 </p> | |
899 <a name="IDX1055"></a> | |
900 <p>The size <var>S</var> of the hash table can be zero. In this case, the | |
901 hash table itself is not contained in the MO file. Some people might | |
902 prefer this because a precomputed hashing table takes disk space, and | |
903 does not win <em>that</em> much speed. The hash table contains indices | |
904 to the sorted array of strings in the MO file. Conflict resolution is | |
905 done by double hashing. The precise hashing algorithm used is fairly | |
906 dependent on GNU <code>gettext</code> code, and is not documented here. | |
907 </p> | |
908 <p>As for the strings themselves, they follow the hash file, and each | |
909 is terminated with a <NUL>, and this <NUL> is not counted in | |
910 the length which appears in the string descriptor. The <code>msgfmt</code> | |
911 program has an option selecting the alignment for MO file strings. | |
912 With this option, each string is separately aligned so it starts at | |
913 an offset which is a multiple of the alignment value. On some RISC | |
914 machines, a correct alignment will speed things up. | |
915 </p> | |
916 <a name="IDX1056"></a> | |
917 <p>Contexts are stored by storing the concatenation of the context, a | |
918 <EOT> byte, and the original string, instead of the original string. | |
919 </p> | |
920 <a name="IDX1057"></a> | |
921 <p>Plural forms are stored by letting the plural of the original string | |
922 follow the singular of the original string, separated through a | |
923 <NUL> byte. The length which appears in the string descriptor | |
924 includes both. However, only the singular of the original string | |
925 takes part in the hash table lookup. The plural variants of the | |
926 translation are all stored consecutively, separated through a | |
927 <NUL> byte. Here also, the length in the string descriptor | |
928 includes all of them. | |
929 </p> | |
930 <a name="IDX1058"></a> | |
931 <p>The character encoding of the strings can be any standard ASCII-compatible | |
932 encoding, such as UTF-8, ISO-8859-1, EUC-JP, etc., as long as the | |
933 encoding's name is stated in the header entry (see section <a href="gettext_6.html#SEC52">Filling in the Header Entry</a>). | |
934 Starting with GNU <code>gettext</code> version 0.22, the MO files produced by | |
935 <code>msgfmt</code> have them in UTF-8 encoding, unless the <code>msgfmt</code> | |
936 option ‘<samp>--no-convert</samp>’ is used. | |
937 </p> | |
938 <p>Nothing prevents a MO file from having embedded <NUL>s in strings. | |
939 However, the program interface currently used already presumes | |
940 that strings are <NUL> terminated, so embedded <NUL>s are | |
941 somewhat useless. But the MO file format is general enough so other | |
942 interfaces would be later possible, if for example, we ever want to | |
943 implement wide characters right in MO files, where <NUL> bytes may | |
944 accidentally appear. (No, we don't want to have wide characters in MO | |
945 files. They would make the file unnecessarily large, and the | |
946 ‘<samp>wchar_t</samp>’ type being platform dependent, MO files would be | |
947 platform dependent as well.) | |
948 </p> | |
949 <p>This particular issue has been strongly debated in the GNU | |
950 <code>gettext</code> development forum, and it is expectable that MO file | |
951 format will evolve or change over time. It is even possible that many | |
952 formats may later be supported concurrently. But surely, we have to | |
953 start somewhere, and the MO file format described here is a good start. | |
954 Nothing is cast in concrete, and the format may later evolve fairly | |
955 easily, so we should feel comfortable with the current approach. | |
956 </p> | |
957 <table><tr><td> </td><td><pre class="example"> byte | |
958 +------------------------------------------+ | |
959 0 | magic number = 0x950412de | | |
960 | | | |
961 4 | file format revision = 0 | | |
962 | | | |
963 8 | number of strings | == N | |
964 | | | |
965 12 | offset of table with original strings | == O | |
966 | | | |
967 16 | offset of table with translation strings | == T | |
968 | | | |
969 20 | size of hashing table | == S | |
970 | | | |
971 24 | offset of hashing table | == H | |
972 | | | |
973 . . | |
974 . (possibly more entries later) . | |
975 . . | |
976 | | | |
977 O | length & offset 0th string ----------------. | |
978 O + 8 | length & offset 1st string ------------------. | |
979 ... ... | | | |
980 O + ((N-1)*8)| length & offset (N-1)th string | | | | |
981 | | | | | |
982 T | length & offset 0th translation ---------------. | |
983 T + 8 | length & offset 1st translation -----------------. | |
984 ... ... | | | | | |
985 T + ((N-1)*8)| length & offset (N-1)th translation | | | | | | |
986 | | | | | | | |
987 H | start hash table | | | | | | |
988 ... ... | | | | | |
989 H + S * 4 | end hash table | | | | | | |
990 | | | | | | | |
991 | NUL terminated 0th string <----------------' | | | | |
992 | | | | | | |
993 | NUL terminated 1st string <------------------' | | | |
994 | | | | | |
995 ... ... | | | |
996 | | | | | |
997 | NUL terminated 0th translation <---------------' | | |
998 | | | | |
999 | NUL terminated 1st translation <-----------------' | |
1000 | | | |
1001 ... ... | |
1002 | | | |
1003 +------------------------------------------+ | |
1004 </pre></td></tr></table> | |
1005 | |
1006 | |
1007 <table cellpadding="1" cellspacing="1" border="0"> | |
1008 <tr><td valign="middle" align="left">[<a href="#SEC173" title="Beginning of this chapter or previous chapter"> << </a>]</td> | |
1009 <td valign="middle" align="left">[<a href="gettext_11.html#SEC197" title="Next chapter"> >> </a>]</td> | |
1010 <td valign="middle" align="left"> </td> | |
1011 <td valign="middle" align="left"> </td> | |
1012 <td valign="middle" align="left"> </td> | |
1013 <td valign="middle" align="left"> </td> | |
1014 <td valign="middle" align="left"> </td> | |
1015 <td valign="middle" align="left">[<a href="gettext_toc.html#SEC_Top" title="Cover (top) of document">Top</a>]</td> | |
1016 <td valign="middle" align="left">[<a href="gettext_toc.html#SEC_Contents" title="Table of contents">Contents</a>]</td> | |
1017 <td valign="middle" align="left">[<a href="gettext_21.html#SEC389" title="Index">Index</a>]</td> | |
1018 <td valign="middle" align="left">[<a href="gettext_abt.html#SEC_About" title="About (help)"> ? </a>]</td> | |
1019 </tr></table> | |
1020 <p> | |
1021 <font size="-1"> | |
1022 This document was generated by <em>Bruno Haible</em> on <em>February, 21 2024</em> using <a href="https://www.nongnu.org/texi2html/"><em>texi2html 1.78a</em></a>. | |
1023 </font> | |
1024 <br> | |
1025 | |
1026 </p> | |
1027 </body> | |
1028 </html> |