2 @cindex @code{msgen} program, usage
4 msgen [@var{option}] @var{inputfile}
7 @cindex generate translation catalog in English
8 The @code{msgen} program creates an English translation catalog. The
9 input file is the last created English PO file, or a PO Template file
10 (generally created by xgettext). Untranslated entries are assigned a
11 translation that is identical to the msgid.
13 Note: @samp{msginit --no-translator --locale=en} performs a very similar
14 task. The main difference is that @code{msginit} cares specially about
15 the header entry, whereas @code{msgen} doesn't.
17 @subsection Input file location
23 @item -D @var{directory}
24 @itemx --directory=@var{directory}
25 @opindex -D@r{, @code{msgen} option}
26 @opindex --directory@r{, @code{msgen} option}
27 Add @var{directory} to the list of directories. Source files are
28 searched relative to this list of directories. The resulting @file{.po}
29 file will be written relative to the current directory, though.
33 If @var{inputfile} is @samp{-}, standard input is read.
35 @subsection Output file location
39 @itemx --output-file=@var{file}
40 @opindex -o@r{, @code{msgen} option}
41 @opindex --output-file@r{, @code{msgen} option}
42 Write output to specified file.
46 The results are written to standard output if no output file is specified
49 @subsection Input file syntax
53 @itemx --properties-input
54 @opindex -P@r{, @code{msgen} option}
55 @opindex --properties-input@r{, @code{msgen} option}
56 Assume the input file is a Java ResourceBundle in Java @code{.properties}
57 syntax, not in PO file syntax.
59 @item --stringtable-input
60 @opindex --stringtable-input@r{, @code{msgen} option}
61 Assume the input file is a NeXTstep/GNUstep localized resource file in
62 @code{.strings} syntax, not in PO file syntax.
66 @subsection Output details
68 @c --no-escape and --escape omitted on purpose. They are not useful.
71 @item --lang=@var{catalogname}
72 @opindex --lang@r{, @code{msgen} option}
73 Specify the @samp{Language} field to be used in the header entry. See
74 @ref{Header Entry} for the meaning of this field. Note: The
75 @samp{Language-Team} and @samp{Plural-Forms} fields are not set by this
79 @itemx --color=@var{when}
80 @opindex --color@r{, @code{msgen} option}
81 Specify whether or when to use colors and other text attributes.
82 See @ref{The --color option} for details.
84 @item --style=@var{style_file}
85 @opindex --style@r{, @code{msgen} option}
86 Specify the CSS style rule file to use for @code{--color}.
87 See @ref{The --style option} for details.
90 @opindex --force-po@r{, @code{msgen} option}
91 Always write an output file even if it contains no message.
95 @opindex -i@r{, @code{msgen} option}
96 @opindex --indent@r{, @code{msgen} option}
97 Write the .po file using indented style.
100 @opindex --no-location@r{, @code{msgen} option}
101 Do not write @samp{#: @var{filename}:@var{line}} lines.
104 @itemx --add-location=@var{type}
105 @opindex --add-location@r{, @code{msgen} option}
106 Generate @samp{#: @var{filename}:@var{line}} lines (default).
108 The optional @var{type} can be either @samp{full}, @samp{file}, or
109 @samp{never}. If it is not given or @samp{full}, it generates the
110 lines with both file name and line number. If it is @samp{file}, the
111 line number part is omitted. If it is @samp{never}, it completely
112 suppresses the lines (same as @code{--no-location}).
115 @opindex --strict@r{, @code{msgen} option}
116 Write out a strict Uniforum conforming PO file. Note that this
117 Uniforum format should be avoided because it doesn't support the
121 @itemx --properties-output
122 @opindex -p@r{, @code{msgen} option}
123 @opindex --properties-output@r{, @code{msgen} option}
124 Write out a Java ResourceBundle in Java @code{.properties} syntax. Note
125 that this file format doesn't support plural forms and silently drops
128 @item --stringtable-output
129 @opindex --stringtable-output@r{, @code{msgen} option}
130 Write out a NeXTstep/GNUstep localized resource file in @code{.strings} syntax.
131 Note that this file format doesn't support plural forms.
133 @item -w @var{number}
134 @itemx --width=@var{number}
135 @opindex -w@r{, @code{msgen} option}
136 @opindex --width@r{, @code{msgen} option}
137 Set the output page width. Long strings in the output files will be
138 split across multiple lines in order to ensure that each line's width
139 (= number of screen columns) is less or equal to the given @var{number}.
142 @opindex --no-wrap@r{, @code{msgen} option}
143 Do not break long message lines. Message lines whose width exceeds the
144 output page width will not be split into several lines. Only file reference
145 lines which are wider than the output page width will be split.
149 @opindex -s@r{, @code{msgen} option}
150 @opindex --sort-output@r{, @code{msgen} option}
151 Generate sorted output. Note that using this option makes it much harder
152 for the translator to understand each message's context.
155 @itemx --sort-by-file
156 @opindex -F@r{, @code{msgen} option}
157 @opindex --sort-by-file@r{, @code{msgen} option}
158 Sort output by file location.
162 @subsection Informative output
167 @opindex -h@r{, @code{msgen} option}
168 @opindex --help@r{, @code{msgen} option}
169 Display this help and exit.
173 @opindex -V@r{, @code{msgen} option}
174 @opindex --version@r{, @code{msgen} option}
175 Output version information and exit.