gettext 2.3.9 → 3.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/.yardopts +1 -0
- data/README.rdoc +28 -23
- data/Rakefile +29 -21
- data/doc/text/news.md +57 -0
- data/gettext.gemspec +1 -1
- data/lib/gettext.rb +13 -29
- data/lib/gettext/cgi.rb +1 -1
- data/lib/gettext/{runtime/class_info.rb → class_info.rb} +1 -1
- data/lib/gettext/{runtime/locale_path.rb → locale_path.rb} +1 -2
- data/lib/gettext/{runtime/mo.rb → mo.rb} +18 -33
- data/lib/gettext/{tools/po.rb → po.rb} +1 -1
- data/lib/gettext/{tools/po_entry.rb → po_entry.rb} +8 -4
- data/lib/gettext/{tools/poparser.rb → po_parser.rb} +41 -44
- data/lib/gettext/{runtime/textdomain.rb → text_domain.rb} +6 -16
- data/lib/gettext/text_domain_group.rb +26 -0
- data/lib/gettext/{runtime/textdomain_manager.rb → text_domain_manager.rb} +40 -40
- data/lib/gettext/tools.rb +1 -182
- data/lib/gettext/tools/msgfmt.rb +1 -1
- data/lib/gettext/tools/msginit.rb +1 -1
- data/lib/gettext/tools/msgmerge.rb +2 -221
- data/lib/gettext/tools/parser/erb.rb +49 -30
- data/lib/gettext/tools/parser/glade.rb +44 -36
- data/lib/gettext/tools/parser/ruby.rb +126 -37
- data/lib/gettext/tools/task.rb +225 -0
- data/lib/gettext/tools/xgettext.rb +25 -28
- data/lib/gettext/version.rb +1 -1
- data/locale/bg/LC_MESSAGES/gettext.mo +0 -0
- data/locale/bs/LC_MESSAGES/gettext.mo +0 -0
- data/locale/ca/LC_MESSAGES/gettext.mo +0 -0
- data/locale/cs/LC_MESSAGES/gettext.mo +0 -0
- data/locale/de/LC_MESSAGES/gettext.mo +0 -0
- data/locale/el/LC_MESSAGES/gettext.mo +0 -0
- data/locale/eo/LC_MESSAGES/gettext.mo +0 -0
- data/locale/es/LC_MESSAGES/gettext.mo +0 -0
- data/locale/et/LC_MESSAGES/gettext.mo +0 -0
- data/locale/fr/LC_MESSAGES/gettext.mo +0 -0
- data/locale/hr/LC_MESSAGES/gettext.mo +0 -0
- data/locale/hu/LC_MESSAGES/gettext.mo +0 -0
- data/locale/it/LC_MESSAGES/gettext.mo +0 -0
- data/locale/ja/LC_MESSAGES/gettext.mo +0 -0
- data/locale/ko/LC_MESSAGES/gettext.mo +0 -0
- data/locale/lv/LC_MESSAGES/gettext.mo +0 -0
- data/locale/nb/LC_MESSAGES/gettext.mo +0 -0
- data/locale/nl/LC_MESSAGES/gettext.mo +0 -0
- data/locale/pt_BR/LC_MESSAGES/gettext.mo +0 -0
- data/locale/ru/LC_MESSAGES/gettext.mo +0 -0
- data/locale/sr/LC_MESSAGES/gettext.mo +0 -0
- data/locale/sv/LC_MESSAGES/gettext.mo +0 -0
- data/locale/uk/LC_MESSAGES/gettext.mo +0 -0
- data/locale/vi/LC_MESSAGES/gettext.mo +0 -0
- data/locale/zh/LC_MESSAGES/gettext.mo +0 -0
- data/locale/zh_TW/LC_MESSAGES/gettext.mo +0 -0
- data/po/gettext.pot +171 -97
- data/samples/hello.rb +3 -2
- data/samples/hello2.rb +2 -1
- data/samples/hello_gtk2.rb +4 -1
- data/samples/hello_gtk_builder.rb +32 -0
- data/samples/hello_gtk_builder.ui +46 -0
- data/samples/hello_noop.rb +2 -1
- data/samples/hello_plural.rb +2 -1
- data/samples/hello_tk.rb +2 -1
- data/src/{poparser.ry → po_parser.ry} +31 -35
- data/test/fixtures/N_.rb +1 -1
- data/test/fixtures/_/double_quote_in_double_quote.rb +32 -0
- data/test/fixtures/_/double_quote_in_single_quote.rb +32 -0
- data/test/fixtures/_/literal_concatenation_with_continuation_line.rb +36 -0
- data/test/fixtures/_/middle_new_line.rb +32 -0
- data/test/fixtures/_/multiple_lines_literal.rb +35 -0
- data/test/fixtures/_/multiple_messages_in_same_line.rb +32 -0
- data/test/fixtures/_/multiple_same_messages.rb +36 -0
- data/{lib/gettext/runtime/mofile.rb → test/fixtures/_/one_new_line.rb} +12 -6
- data/test/fixtures/{multi_textdomain.rb → multi_text_domain.rb} +1 -1
- data/test/fixtures/non_ascii.rb +1 -1
- data/test/fixtures/simple.rb +1 -1
- data/test/fixtures/untranslated.rb +1 -1
- data/test/gettext-test-utils.rb +1 -24
- data/test/po/ja/_.po +63 -13
- data/test/po/ja/non_ascii.po +2 -3
- data/test/po/ja/untranslated.po +1 -1
- data/test/test_class_info.rb +2 -2
- data/test/test_gettext.rb +11 -11
- data/test/test_mo.rb +2 -2
- data/test/test_parser.rb +93 -96
- data/test/test_po_entry.rb +237 -146
- data/test/test_po_parser.rb +107 -98
- data/test/test_string.rb +1 -1
- data/test/{test_textdomain_bind.rb → test_text_domain_bind.rb} +6 -6
- data/test/{test_textdomain_multi.rb → test_text_domain_multi.rb} +5 -5
- data/test/{test_textdomain_toplevel.rb → test_text_domain_toplevel.rb} +1 -1
- data/test/test_thread.rb +1 -1
- data/test/tools/files/simple_translation.rb +1 -1
- data/test/{parser → tools/parser}/test_ruby.rb +110 -14
- data/test/tools/test_msgmerge.rb +17 -276
- data/test/tools/test_po.rb +1 -1
- data/test/tools/test_xgettext.rb +175 -144
- metadata +59 -33
- data/lib/gettext/core_ext/iconv.rb +0 -110
- data/lib/gettext/core_ext/string.rb +0 -91
- data/lib/gettext/parser/erb.rb +0 -5
- data/lib/gettext/parser/glade.rb +0 -5
- data/lib/gettext/parser/ruby.rb +0 -172
- data/lib/gettext/runtime/textdomain_group.rb +0 -26
- data/lib/gettext/task.rb +0 -203
- data/lib/gettext/utils.rb +0 -39
- data/test/test_po_generation.rb +0 -45
- data/test/tools/test_tools.rb +0 -61
|
@@ -66,8 +66,14 @@ module GetText
|
|
|
66
66
|
end
|
|
67
67
|
end
|
|
68
68
|
|
|
69
|
+
# @return [Hash<Symbol, Object>] Options for parsing. Options
|
|
70
|
+
# are depend on each parser.
|
|
71
|
+
# @see RubyParser#parse
|
|
72
|
+
# @see ErbParser#parse
|
|
73
|
+
attr_reader :parse_options
|
|
74
|
+
|
|
69
75
|
def initialize #:nodoc:
|
|
70
|
-
@parsers = @@default_parsers
|
|
76
|
+
@parsers = @@default_parsers.dup
|
|
71
77
|
|
|
72
78
|
@input_files = nil
|
|
73
79
|
@output = nil
|
|
@@ -77,6 +83,8 @@ module GetText
|
|
|
77
83
|
@msgid_bugs_address = nil
|
|
78
84
|
@copyright_holder = nil
|
|
79
85
|
@output_encoding = nil
|
|
86
|
+
|
|
87
|
+
@parse_options = {}
|
|
80
88
|
end
|
|
81
89
|
|
|
82
90
|
# The parser object requires to have target?(path) and
|
|
@@ -88,7 +96,7 @@ module GetText
|
|
|
88
96
|
# def target?(path)
|
|
89
97
|
# File.extname(path) == ".foo" # *.foo file only.
|
|
90
98
|
# end
|
|
91
|
-
# def parse(path)
|
|
99
|
+
# def parse(path, options={})
|
|
92
100
|
# po = []
|
|
93
101
|
# # Simple entry
|
|
94
102
|
# entry = POEntry.new(:normal)
|
|
@@ -119,7 +127,7 @@ module GetText
|
|
|
119
127
|
# end
|
|
120
128
|
# end
|
|
121
129
|
#
|
|
122
|
-
# GetText::XGetText.add_parser(FooParser.new)
|
|
130
|
+
# GetText::Tools::XGetText.add_parser(FooParser.new)
|
|
123
131
|
#
|
|
124
132
|
# @param [#target?, #parse] parser
|
|
125
133
|
# It parses target file and extracts translate target entries from the
|
|
@@ -244,6 +252,13 @@ EOH
|
|
|
244
252
|
require out
|
|
245
253
|
end
|
|
246
254
|
|
|
255
|
+
parser.on("-c", "--add-comments[=TAG]",
|
|
256
|
+
_("If TAG is specified, place comment blocks starting with TAG and precedding keyword lines in output file"),
|
|
257
|
+
_("If TAG is not specified, place all comment blocks preceing keyword lines in output file"),
|
|
258
|
+
_("(default: %s)") % _("no TAG")) do |tag|
|
|
259
|
+
@parse_options[:comment_tag] = tag
|
|
260
|
+
end
|
|
261
|
+
|
|
247
262
|
parser.on("-d", "--debug", _("run in debugging mode")) do
|
|
248
263
|
$DEBUG = true
|
|
249
264
|
end
|
|
@@ -290,7 +305,12 @@ EOH
|
|
|
290
305
|
@parsers.each do |parser|
|
|
291
306
|
next unless parser.target?(path)
|
|
292
307
|
|
|
293
|
-
|
|
308
|
+
# For backward compatibility
|
|
309
|
+
if parser.method(:parse).arity == 1 or @parse_options.empty?
|
|
310
|
+
extracted_po = parser.parse(path)
|
|
311
|
+
else
|
|
312
|
+
extracted_po = parser.parse(path, @parse_options)
|
|
313
|
+
end
|
|
294
314
|
extracted_po.each do |po_entry|
|
|
295
315
|
if po_entry.kind_of?(Array)
|
|
296
316
|
po_entry = POEntry.new_from_ary(po_entry)
|
|
@@ -346,31 +366,8 @@ EOH
|
|
|
346
366
|
end
|
|
347
367
|
|
|
348
368
|
def encode(string)
|
|
349
|
-
|
|
350
|
-
string.encode(@output_encoding)
|
|
351
|
-
else
|
|
352
|
-
string # don't support
|
|
353
|
-
end
|
|
354
|
-
end
|
|
355
|
-
end
|
|
356
|
-
end
|
|
357
|
-
end
|
|
358
|
-
|
|
359
|
-
# This is the module for backward compatibility,
|
|
360
|
-
# but GetText::Tools::XGetText.run should be used.
|
|
361
|
-
module GetText
|
|
362
|
-
module RGetText
|
|
363
|
-
def run(paths=nil, out=STDOUT)
|
|
364
|
-
warn("Warning: This method is obsolete. " +
|
|
365
|
-
"Please use GetText::Tools::XGetText.run.")
|
|
366
|
-
if paths.nil?
|
|
367
|
-
GetText::Tools::XGetText.run(*ARGV)
|
|
368
|
-
elsif out == STDOUT
|
|
369
|
-
GetText::Tools::XGetText.run(paths)
|
|
370
|
-
else
|
|
371
|
-
GetText::Tools::XGetText.run("-o", out, paths)
|
|
369
|
+
string.encode(@output_encoding)
|
|
372
370
|
end
|
|
373
371
|
end
|
|
374
|
-
module_function :run
|
|
375
372
|
end
|
|
376
373
|
end
|
data/lib/gettext/version.rb
CHANGED
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
data/po/gettext.pot
CHANGED
|
@@ -6,10 +6,10 @@
|
|
|
6
6
|
#, fuzzy
|
|
7
7
|
msgid ""
|
|
8
8
|
msgstr ""
|
|
9
|
-
"Project-Id-Version: gettext
|
|
9
|
+
"Project-Id-Version: gettext 3.0.0\n"
|
|
10
10
|
"Report-Msgid-Bugs-To: \n"
|
|
11
|
-
"POT-Creation-Date: 2013-
|
|
12
|
-
"PO-Revision-Date: 2013-
|
|
11
|
+
"POT-Creation-Date: 2013-08-31 20:20+0900\n"
|
|
12
|
+
"PO-Revision-Date: 2013-08-31 20:20+0900\n"
|
|
13
13
|
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
|
14
14
|
"Language-Team: LANGUAGE <LL@li.org>\n"
|
|
15
15
|
"Language: \n"
|
|
@@ -18,6 +18,14 @@ msgstr ""
|
|
|
18
18
|
"Content-Transfer-Encoding: 8bit\n"
|
|
19
19
|
"Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n"
|
|
20
20
|
|
|
21
|
+
#: ../lib/gettext/text_domain_manager.rb:148
|
|
22
|
+
msgid "ngettext: 3rd parmeter is wrong: value = %{number}"
|
|
23
|
+
msgstr ""
|
|
24
|
+
|
|
25
|
+
#: ../lib/gettext/text_domain_manager.rb:154
|
|
26
|
+
msgid "ngettext: 3rd parameter should be a number, not nil."
|
|
27
|
+
msgstr ""
|
|
28
|
+
|
|
21
29
|
#: ../lib/gettext/tools/msgfmt.rb:65
|
|
22
30
|
msgid "no input files specified."
|
|
23
31
|
msgstr ""
|
|
@@ -31,41 +39,41 @@ msgid "Generate binary message catalog from textual translation description."
|
|
|
31
39
|
msgstr ""
|
|
32
40
|
|
|
33
41
|
#: ../lib/gettext/tools/msgfmt.rb:86
|
|
34
|
-
#: ../lib/gettext/tools/msgmerge.rb:
|
|
42
|
+
#: ../lib/gettext/tools/msgmerge.rb:271
|
|
35
43
|
#: ../lib/gettext/tools/msginit.rb:88
|
|
36
|
-
#: ../lib/gettext/tools/xgettext.rb:
|
|
44
|
+
#: ../lib/gettext/tools/xgettext.rb:218
|
|
37
45
|
msgid "Specific options:"
|
|
38
46
|
msgstr ""
|
|
39
47
|
|
|
40
48
|
#: ../lib/gettext/tools/msgfmt.rb:89
|
|
41
|
-
#: ../lib/gettext/tools/msgmerge.rb:
|
|
42
|
-
#: ../lib/gettext/tools/xgettext.rb:
|
|
49
|
+
#: ../lib/gettext/tools/msgmerge.rb:276
|
|
50
|
+
#: ../lib/gettext/tools/xgettext.rb:221
|
|
43
51
|
msgid "write output to specified file"
|
|
44
52
|
msgstr ""
|
|
45
53
|
|
|
46
54
|
#: ../lib/gettext/tools/msgfmt.rb:93
|
|
47
|
-
#: ../lib/gettext/tools/msgmerge.rb:
|
|
48
|
-
#: ../lib/gettext/tools/xgettext.rb:
|
|
55
|
+
#: ../lib/gettext/tools/msgmerge.rb:287
|
|
56
|
+
#: ../lib/gettext/tools/xgettext.rb:271
|
|
49
57
|
msgid "display version information and exit"
|
|
50
58
|
msgstr ""
|
|
51
59
|
|
|
52
|
-
#: ../lib/gettext/tools/msgmerge.rb:
|
|
60
|
+
#: ../lib/gettext/tools/msgmerge.rb:250
|
|
53
61
|
msgid "definition po is not given."
|
|
54
62
|
msgstr ""
|
|
55
63
|
|
|
56
|
-
#: ../lib/gettext/tools/msgmerge.rb:
|
|
64
|
+
#: ../lib/gettext/tools/msgmerge.rb:252
|
|
57
65
|
msgid "reference pot is not given."
|
|
58
66
|
msgstr ""
|
|
59
67
|
|
|
60
|
-
#: ../lib/gettext/tools/msgmerge.rb:
|
|
68
|
+
#: ../lib/gettext/tools/msgmerge.rb:260
|
|
61
69
|
msgid "Usage: %s def.po ref.pot [-o output.pot]"
|
|
62
70
|
msgstr ""
|
|
63
71
|
|
|
64
|
-
#: ../lib/gettext/tools/msgmerge.rb:
|
|
72
|
+
#: ../lib/gettext/tools/msgmerge.rb:263
|
|
65
73
|
msgid "Merges two Uniforum style .po files together. The def.po file is an existing PO file with translations. The ref.pot file is the last created PO file with up-to-date source references. ref.pot is generally created by rgettext."
|
|
66
74
|
msgstr ""
|
|
67
75
|
|
|
68
|
-
#: ../lib/gettext/tools/msgmerge.rb:
|
|
76
|
+
#: ../lib/gettext/tools/msgmerge.rb:282
|
|
69
77
|
#: ../lib/gettext/tools/msginit.rb:111
|
|
70
78
|
msgid "Display this help and exit"
|
|
71
79
|
msgstr ""
|
|
@@ -118,91 +126,83 @@ msgstr ""
|
|
|
118
126
|
msgid "'%{klass}' is ignored."
|
|
119
127
|
msgstr ""
|
|
120
128
|
|
|
121
|
-
#: ../lib/gettext/tools/xgettext.rb:
|
|
129
|
+
#: ../lib/gettext/tools/xgettext.rb:183
|
|
122
130
|
msgid "Error parsing %{path}"
|
|
123
131
|
msgstr ""
|
|
124
132
|
|
|
125
|
-
#: ../lib/gettext/tools/xgettext.rb:
|
|
133
|
+
#: ../lib/gettext/tools/xgettext.rb:194
|
|
126
134
|
msgid "no input files"
|
|
127
135
|
msgstr ""
|
|
128
136
|
|
|
129
|
-
#: ../lib/gettext/tools/xgettext.rb:
|
|
137
|
+
#: ../lib/gettext/tools/xgettext.rb:212
|
|
130
138
|
msgid "Usage: %s input.rb [-r parser.rb] [-o output.pot]"
|
|
131
139
|
msgstr ""
|
|
132
140
|
|
|
133
|
-
#: ../lib/gettext/tools/xgettext.rb:
|
|
141
|
+
#: ../lib/gettext/tools/xgettext.rb:215
|
|
134
142
|
msgid "Extract translatable strings from given input files."
|
|
135
143
|
msgstr ""
|
|
136
144
|
|
|
137
|
-
#: ../lib/gettext/tools/xgettext.rb:
|
|
145
|
+
#: ../lib/gettext/tools/xgettext.rb:226
|
|
138
146
|
msgid "set package name in output"
|
|
139
147
|
msgstr ""
|
|
140
148
|
|
|
141
|
-
#: ../lib/gettext/tools/xgettext.rb:
|
|
149
|
+
#: ../lib/gettext/tools/xgettext.rb:231
|
|
142
150
|
msgid "set package version in output"
|
|
143
151
|
msgstr ""
|
|
144
152
|
|
|
145
|
-
#: ../lib/gettext/tools/xgettext.rb:
|
|
153
|
+
#: ../lib/gettext/tools/xgettext.rb:236
|
|
146
154
|
msgid "set report address for msgid bugs"
|
|
147
155
|
msgstr ""
|
|
148
156
|
|
|
149
|
-
#: ../lib/gettext/tools/xgettext.rb:
|
|
157
|
+
#: ../lib/gettext/tools/xgettext.rb:241
|
|
150
158
|
msgid "set copyright holder in output"
|
|
151
159
|
msgstr ""
|
|
152
160
|
|
|
153
|
-
#: ../lib/gettext/tools/xgettext.rb:
|
|
161
|
+
#: ../lib/gettext/tools/xgettext.rb:246
|
|
154
162
|
msgid "set encoding for output"
|
|
155
163
|
msgstr ""
|
|
156
164
|
|
|
157
|
-
#: ../lib/gettext/tools/xgettext.rb:243
|
|
158
|
-
msgid "require the library before executing xgettext"
|
|
159
|
-
msgstr ""
|
|
160
|
-
|
|
161
|
-
#: ../lib/gettext/tools/xgettext.rb:247
|
|
162
|
-
msgid "run in debugging mode"
|
|
163
|
-
msgstr ""
|
|
164
|
-
|
|
165
165
|
#: ../lib/gettext/tools/xgettext.rb:251
|
|
166
|
-
msgid "
|
|
166
|
+
msgid "require the library before executing xgettext"
|
|
167
167
|
msgstr ""
|
|
168
168
|
|
|
169
|
-
#: ../lib/gettext/tools/xgettext.rb:
|
|
170
|
-
msgid "
|
|
169
|
+
#: ../lib/gettext/tools/xgettext.rb:256
|
|
170
|
+
msgid "If TAG is specified, place comment blocks starting with TAG and precedding keyword lines in output file"
|
|
171
171
|
msgstr ""
|
|
172
172
|
|
|
173
|
-
#: ../lib/gettext/tools/
|
|
174
|
-
msgid "
|
|
173
|
+
#: ../lib/gettext/tools/xgettext.rb:257
|
|
174
|
+
msgid "If TAG is not specified, place all comment blocks preceing keyword lines in output file"
|
|
175
175
|
msgstr ""
|
|
176
176
|
|
|
177
|
-
#: ../lib/gettext/
|
|
178
|
-
msgid "
|
|
177
|
+
#: ../lib/gettext/tools/xgettext.rb:258
|
|
178
|
+
msgid "(default: %s)"
|
|
179
179
|
msgstr ""
|
|
180
180
|
|
|
181
|
-
#: ../lib/gettext/
|
|
182
|
-
msgid "
|
|
181
|
+
#: ../lib/gettext/tools/xgettext.rb:258
|
|
182
|
+
msgid "no TAG"
|
|
183
183
|
msgstr ""
|
|
184
184
|
|
|
185
|
-
#: ../lib/gettext/tools.rb:
|
|
186
|
-
msgid "
|
|
185
|
+
#: ../lib/gettext/tools/xgettext.rb:262
|
|
186
|
+
msgid "run in debugging mode"
|
|
187
187
|
msgstr ""
|
|
188
188
|
|
|
189
|
-
#: ../lib/gettext/tools.rb:
|
|
190
|
-
msgid "
|
|
189
|
+
#: ../lib/gettext/tools/xgettext.rb:266
|
|
190
|
+
msgid "display this help and exit"
|
|
191
191
|
msgstr ""
|
|
192
192
|
|
|
193
|
-
#: ../lib/gettext/tools.rb:
|
|
194
|
-
msgid "
|
|
193
|
+
#: ../lib/gettext/tools/xgettext.rb:320
|
|
194
|
+
msgid "Warning: The empty \"\" msgid is reserved by gettext. So gettext(\"\") doesn't returns empty string but the header entry in po file."
|
|
195
195
|
msgstr ""
|
|
196
196
|
|
|
197
|
-
#: ../lib/gettext/tools.rb:
|
|
198
|
-
msgid "`%{
|
|
197
|
+
#: ../lib/gettext/tools/parser/glade.rb:32
|
|
198
|
+
msgid "`%{file}' is not glade-2.0 format."
|
|
199
199
|
msgstr ""
|
|
200
200
|
|
|
201
|
-
#: ../samples/hello_gtk2.rb:
|
|
201
|
+
#: ../samples/hello_gtk2.rb:25
|
|
202
202
|
msgid "hello, gtk world"
|
|
203
203
|
msgstr ""
|
|
204
204
|
|
|
205
|
-
#: ../samples/hello_tk.rb:
|
|
205
|
+
#: ../samples/hello_tk.rb:16
|
|
206
206
|
msgid "hello, tk world"
|
|
207
207
|
msgstr ""
|
|
208
208
|
|
|
@@ -218,14 +218,17 @@ msgstr ""
|
|
|
218
218
|
msgid "Hello World2"
|
|
219
219
|
msgstr ""
|
|
220
220
|
|
|
221
|
-
#: ../samples/hello_plural.rb:
|
|
222
|
-
msgid "
|
|
223
|
-
|
|
221
|
+
#: ../samples/hello_plural.rb:20
|
|
222
|
+
msgid ""
|
|
223
|
+
"There is an apple.\n"
|
|
224
|
+
msgid_plural ""
|
|
225
|
+
"There are %{num} apples.\n"
|
|
224
226
|
msgstr[0] ""
|
|
225
227
|
msgstr[1] ""
|
|
226
228
|
|
|
227
|
-
#: ../samples/hello.rb:
|
|
228
|
-
msgid "
|
|
229
|
+
#: ../samples/hello.rb:17
|
|
230
|
+
msgid ""
|
|
231
|
+
"Hello World\n"
|
|
229
232
|
msgstr ""
|
|
230
233
|
|
|
231
234
|
#: ../samples/hello_glade2.glade:9 ../test/fixtures/gladeparser.glade:8
|
|
@@ -240,22 +243,24 @@ msgstr ""
|
|
|
240
243
|
msgid "<Hello world>"
|
|
241
244
|
msgstr ""
|
|
242
245
|
|
|
243
|
-
#: ../samples/hello2.rb:
|
|
244
|
-
msgid "
|
|
246
|
+
#: ../samples/hello2.rb:19
|
|
247
|
+
msgid ""
|
|
248
|
+
"One is %{num}\n"
|
|
245
249
|
msgstr ""
|
|
246
250
|
|
|
247
|
-
#: ../samples/hello2.rb:
|
|
248
|
-
msgid "
|
|
251
|
+
#: ../samples/hello2.rb:20
|
|
252
|
+
msgid ""
|
|
253
|
+
"Hello %{world}\n"
|
|
249
254
|
msgstr ""
|
|
250
255
|
|
|
251
|
-
#: ../samples/hello2.rb:
|
|
256
|
+
#: ../samples/hello2.rb:20
|
|
252
257
|
msgid "World"
|
|
253
258
|
msgstr ""
|
|
254
259
|
|
|
255
|
-
#: ../test/
|
|
256
|
-
#: ../test/
|
|
257
|
-
#: ../test/
|
|
258
|
-
#: ../test/
|
|
260
|
+
#: ../test/test_text_domain_toplevel.rb:9
|
|
261
|
+
#: ../test/test_text_domain_toplevel.rb:15
|
|
262
|
+
#: ../test/test_text_domain_toplevel.rb:18
|
|
263
|
+
#: ../test/test_text_domain_toplevel.rb:23 ../test/test_gettext.rb:64
|
|
259
264
|
#: ../test/test_gettext.rb:297 ../test/test_gettext.rb:299
|
|
260
265
|
#: ../test/test_gettext.rb:302 ../test/test_gettext.rb:306
|
|
261
266
|
#: ../test/test_gettext.rb:309 ../test/test_gettext.rb:322
|
|
@@ -263,16 +268,16 @@ msgstr ""
|
|
|
263
268
|
#: ../test/test_gettext.rb:336 ../test/test_gettext.rb:339
|
|
264
269
|
#: ../test/test_gettext.rb:351 ../test/test_gettext.rb:358
|
|
265
270
|
#: ../test/test_thread.rb:23 ../test/fixtures/simple.rb:10
|
|
266
|
-
#: ../test/fixtures/
|
|
267
|
-
#: ../test/fixtures/
|
|
268
|
-
#: ../test/fixtures/
|
|
269
|
-
#: ../test/fixtures/
|
|
270
|
-
#: ../test/fixtures/
|
|
271
|
-
#: ../test/fixtures/
|
|
272
|
-
#: ../test/fixtures/
|
|
273
|
-
#: ../test/fixtures/
|
|
274
|
-
#: ../test/fixtures/
|
|
275
|
-
#: ../test/fixtures/
|
|
271
|
+
#: ../test/fixtures/multi_text_domain.rb:11
|
|
272
|
+
#: ../test/fixtures/multi_text_domain.rb:24
|
|
273
|
+
#: ../test/fixtures/multi_text_domain.rb:43
|
|
274
|
+
#: ../test/fixtures/multi_text_domain.rb:50
|
|
275
|
+
#: ../test/fixtures/multi_text_domain.rb:62
|
|
276
|
+
#: ../test/fixtures/multi_text_domain.rb:75
|
|
277
|
+
#: ../test/fixtures/multi_text_domain.rb:91
|
|
278
|
+
#: ../test/fixtures/multi_text_domain.rb:104
|
|
279
|
+
#: ../test/fixtures/multi_text_domain.rb:108
|
|
280
|
+
#: ../test/fixtures/multi_text_domain.rb:128
|
|
276
281
|
msgid "language"
|
|
277
282
|
msgstr ""
|
|
278
283
|
|
|
@@ -280,12 +285,12 @@ msgstr ""
|
|
|
280
285
|
msgid "a translation"
|
|
281
286
|
msgstr ""
|
|
282
287
|
|
|
283
|
-
#: ../test/test_gettext.rb:53 ../test/fixtures/
|
|
284
|
-
#: ../test/fixtures/
|
|
285
|
-
#: ../test/fixtures/
|
|
286
|
-
#: ../test/fixtures/
|
|
287
|
-
#: ../test/fixtures/
|
|
288
|
-
#: ../test/fixtures/
|
|
288
|
+
#: ../test/test_gettext.rb:53 ../test/fixtures/multi_text_domain.rb:14
|
|
289
|
+
#: ../test/fixtures/multi_text_domain.rb:27
|
|
290
|
+
#: ../test/fixtures/multi_text_domain.rb:54
|
|
291
|
+
#: ../test/fixtures/multi_text_domain.rb:65
|
|
292
|
+
#: ../test/fixtures/multi_text_domain.rb:78
|
|
293
|
+
#: ../test/fixtures/multi_text_domain.rb:116
|
|
289
294
|
msgid "LANGUAGE"
|
|
290
295
|
msgstr ""
|
|
291
296
|
|
|
@@ -368,26 +373,41 @@ msgstr[0] ""
|
|
|
368
373
|
msgstr[1] ""
|
|
369
374
|
|
|
370
375
|
#: ../test/fixtures/n_.rb:33
|
|
371
|
-
msgid "
|
|
372
|
-
|
|
376
|
+
msgid ""
|
|
377
|
+
"bbb\n"
|
|
378
|
+
msgid_plural ""
|
|
379
|
+
"ccc2\n"
|
|
380
|
+
"ccc2"
|
|
373
381
|
msgstr[0] ""
|
|
374
382
|
msgstr[1] ""
|
|
375
383
|
|
|
376
384
|
#: ../test/fixtures/n_.rb:37
|
|
377
|
-
msgid "
|
|
378
|
-
|
|
385
|
+
msgid ""
|
|
386
|
+
"ddd\n"
|
|
387
|
+
"ddd"
|
|
388
|
+
msgid_plural ""
|
|
389
|
+
"ddd2\n"
|
|
390
|
+
"ddd2"
|
|
379
391
|
msgstr[0] ""
|
|
380
392
|
msgstr[1] ""
|
|
381
393
|
|
|
382
394
|
#: ../test/fixtures/n_.rb:42
|
|
383
|
-
msgid "
|
|
384
|
-
|
|
395
|
+
msgid ""
|
|
396
|
+
"eee\n"
|
|
397
|
+
"eee\n"
|
|
398
|
+
msgid_plural ""
|
|
399
|
+
"eee2\n"
|
|
400
|
+
"eee2\n"
|
|
385
401
|
msgstr[0] ""
|
|
386
402
|
msgstr[1] ""
|
|
387
403
|
|
|
388
404
|
#: ../test/fixtures/n_.rb:48
|
|
389
|
-
msgid "
|
|
390
|
-
|
|
405
|
+
msgid ""
|
|
406
|
+
"ddd\n"
|
|
407
|
+
"eee\n"
|
|
408
|
+
msgid_plural ""
|
|
409
|
+
"ddd\n"
|
|
410
|
+
"eee2"
|
|
391
411
|
msgstr[0] ""
|
|
392
412
|
msgstr[1] ""
|
|
393
413
|
|
|
@@ -449,7 +469,7 @@ msgid_plural "rrr"
|
|
|
449
469
|
msgstr[0] ""
|
|
450
470
|
msgstr[1] ""
|
|
451
471
|
|
|
452
|
-
#. please provide translations for all
|
|
472
|
+
#. TRANSLATORS:please provide translations for all
|
|
453
473
|
#. the plural forms!
|
|
454
474
|
#: ../test/fixtures/n_.rb:97
|
|
455
475
|
msgid "comment"
|
|
@@ -457,10 +477,54 @@ msgid_plural "comments"
|
|
|
457
477
|
msgstr[0] ""
|
|
458
478
|
msgstr[1] ""
|
|
459
479
|
|
|
480
|
+
#: ../test/fixtures/_/double_quote_in_double_quote.rb:28
|
|
481
|
+
msgid "double \"quote\" in double quote"
|
|
482
|
+
msgstr ""
|
|
483
|
+
|
|
484
|
+
#: ../test/fixtures/_/multiple_same_messages.rb:28
|
|
485
|
+
#: ../test/fixtures/_/multiple_same_messages.rb:32
|
|
486
|
+
msgid "multiple same messages"
|
|
487
|
+
msgstr ""
|
|
488
|
+
|
|
489
|
+
#: ../test/fixtures/_/double_quote_in_single_quote.rb:28
|
|
490
|
+
msgid "double \"quote\" in single quote"
|
|
491
|
+
msgstr ""
|
|
492
|
+
|
|
493
|
+
#: ../test/fixtures/_/multiple_messages_in_same_line.rb:28
|
|
494
|
+
msgid "multiple"
|
|
495
|
+
msgstr ""
|
|
496
|
+
|
|
497
|
+
#: ../test/fixtures/_/multiple_messages_in_same_line.rb:28
|
|
498
|
+
msgid "in same line"
|
|
499
|
+
msgstr ""
|
|
500
|
+
|
|
501
|
+
#: ../test/fixtures/_/multiple_lines_literal.rb:28
|
|
502
|
+
msgid ""
|
|
503
|
+
"multiple\n"
|
|
504
|
+
"lines\n"
|
|
505
|
+
"literal\n"
|
|
506
|
+
msgstr ""
|
|
507
|
+
|
|
508
|
+
#:
|
|
509
|
+
#: ../test/fixtures/_/literal_concatenation_with_continuation_line.rb:28
|
|
510
|
+
msgid "literal concatenation with continuation line"
|
|
511
|
+
msgstr ""
|
|
512
|
+
|
|
513
|
+
#: ../test/fixtures/_/middle_new_line.rb:28
|
|
514
|
+
msgid ""
|
|
515
|
+
"middle\n"
|
|
516
|
+
"new line"
|
|
517
|
+
msgstr ""
|
|
518
|
+
|
|
460
519
|
#: ../test/fixtures/_/one_line.rb:28
|
|
461
520
|
msgid "one line"
|
|
462
521
|
msgstr ""
|
|
463
522
|
|
|
523
|
+
#: ../test/fixtures/_/one_new_line.rb:28
|
|
524
|
+
msgid ""
|
|
525
|
+
"one new line\n"
|
|
526
|
+
msgstr ""
|
|
527
|
+
|
|
464
528
|
#: ../test/fixtures/backslash.rb:27
|
|
465
529
|
msgid "You should escape '\\' as '\\\\'."
|
|
466
530
|
msgstr ""
|
|
@@ -545,15 +609,21 @@ msgid "untranslated"
|
|
|
545
609
|
msgstr ""
|
|
546
610
|
|
|
547
611
|
#: ../test/fixtures/N_.rb:14 ../test/fixtures/_.rb:34
|
|
548
|
-
msgid "
|
|
612
|
+
msgid ""
|
|
613
|
+
"aaa\n"
|
|
549
614
|
msgstr ""
|
|
550
615
|
|
|
551
616
|
#: ../test/fixtures/N_.rb:18 ../test/fixtures/_.rb:38
|
|
552
|
-
msgid "
|
|
617
|
+
msgid ""
|
|
618
|
+
"bbb\n"
|
|
619
|
+
"ccc"
|
|
553
620
|
msgstr ""
|
|
554
621
|
|
|
555
622
|
#: ../test/fixtures/N_.rb:22 ../test/fixtures/_.rb:42
|
|
556
|
-
msgid "
|
|
623
|
+
msgid ""
|
|
624
|
+
"bbb\n"
|
|
625
|
+
"ccc\n"
|
|
626
|
+
"ddd\n"
|
|
557
627
|
msgstr ""
|
|
558
628
|
|
|
559
629
|
#: ../test/fixtures/N_.rb:29 ../test/fixtures/N_.rb:33
|
|
@@ -574,7 +644,9 @@ msgid "lllmmm"
|
|
|
574
644
|
msgstr ""
|
|
575
645
|
|
|
576
646
|
#: ../test/fixtures/N_.rb:64 ../test/fixtures/_.rb:84
|
|
577
|
-
msgid "
|
|
647
|
+
msgid ""
|
|
648
|
+
"nnn\n"
|
|
649
|
+
"ooo"
|
|
578
650
|
msgstr ""
|
|
579
651
|
|
|
580
652
|
#: ../test/fixtures/gladeparser.glade:29
|
|
@@ -611,10 +683,12 @@ msgid "\\taaa"
|
|
|
611
683
|
msgstr ""
|
|
612
684
|
|
|
613
685
|
#: ../test/fixtures/_.rb:100
|
|
614
|
-
msgid "
|
|
686
|
+
msgid ""
|
|
687
|
+
"Here document1\n"
|
|
688
|
+
"Here document2\n"
|
|
615
689
|
msgstr ""
|
|
616
690
|
|
|
617
|
-
#. This is a proper name. See the gettext
|
|
691
|
+
#. TRANSLATORS: This is a proper name. See the gettext
|
|
618
692
|
#. manual, section Names. Note this is actually a non-ASCII
|
|
619
693
|
#. name: The first name is (with Unicode escapes)
|
|
620
694
|
#. "Fran\u00e7ois" or (with HTML entities) "François".
|
|
@@ -636,7 +710,7 @@ msgstr ""
|
|
|
636
710
|
msgid "This is a # including string."
|
|
637
711
|
msgstr ""
|
|
638
712
|
|
|
639
|
-
#: ../test/fixtures/
|
|
713
|
+
#: ../test/fixtures/multi_text_domain.rb:120
|
|
640
714
|
msgid "no data"
|
|
641
715
|
msgstr ""
|
|
642
716
|
|
|
@@ -664,7 +738,7 @@ msgstr ""
|
|
|
664
738
|
msgid "BBB"
|
|
665
739
|
msgstr ""
|
|
666
740
|
|
|
667
|
-
#. please translate 'name' in the context of 'program'.
|
|
741
|
+
#. TRANSLATORS:please translate 'name' in the context of 'program'.
|
|
668
742
|
#. Hint: the translation should NOT contain the translation of 'program'.
|
|
669
743
|
#: ../test/fixtures/p_.rb:55
|
|
670
744
|
msgctxt "program"
|