我使用它来提取所有需要翻译的字符串:
xgettext -o $@ -k"Localizer.get" $^ --from-code=utf-8这些应该被提取出来:
Localizer.get("Could not find the config file. (This should *not* happen!)")这些不是:
SettingsWrapper.getString("date_format")但这两个文件最终都在我的.pot文件中:
msgid "date_format"
msgstr ""有什么方法可以把这件事搞清楚吗?
发布于 2011-10-10 21:55:10
在xgettext manual中,getString是Java的默认keyword specification。您将需要禁用默认关键字,并显式包括您想要启用的禁用的任何所需关键字规范。尝试将-k"Localizer.get"更改为-k -k"Localizer.get"。
https://stackoverflow.com/questions/7652827
复制相似问题