fix a qt extraction bug

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@5831 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Lars Gullik Bjønnes 2002-12-16 22:56:32 +00:00
parent c3ca9ada17
commit 4c180ccef6
3 changed files with 21 additions and 12 deletions

View File

@ -10,3 +10,5 @@ lyx.pot
layouts_l10n.pot
qt_l10n.pot
xforms_l10n.pot
default_ui_l10n.pot
languages_l10n.pot

View File

@ -1,3 +1,8 @@
2002-12-16 Lars Gullik Bjønnes <larsbj@gullik.net>
* Makefile.in.in (qt_l10n.pot): Fix a bug that resulted in too few
strings being extracted.
2002-12-14 Lars Gullik Bjønnes <larsbj@gullik.net>
* Makefile.in.in (languages_l10n.pot): new target

View File

@ -206,15 +206,18 @@ ${srcdir}/POTFILES.in: $(POTFILE_IN_DEPS)
l10n_pots: xforms_l10n.pot qt_l10n.pot layouts_l10n.pot languages_l10n.pot default_ui_l10n.pot
cat xforms_l10n.pot qt_l10n.pot layouts_l10n.pot languages_l10n.pot default_ui_l10n.pot | \
msguniq -o $(PACKAGE).po
cat xforms_l10n.pot qt_l10n.pot layouts_l10n.pot languages_l10n.pot default_ui_l10n.pot > lyxtmp.pot && \
msguniq -o $(PACKAGE).po lyxtmp.pot
xforms_l10n.pot: $(top_srcdir)/src/frontends/xforms/forms/*.fd
awk ' \
BEGIN { \
print "#, fuzzy"; \
print "msgid \"\""; \
print "msgstr \"\""; \
print "\"Content-Type: text/plain; charset=ISO-8859-1\\n\""; \
print "\"Content-Transfer-Encoding: 8bit\\n\""; \
print "\n"; \
} \
/label: / { \
if (NF > 1) { \
@ -228,16 +231,15 @@ xforms_l10n.pot: $(top_srcdir)/src/frontends/xforms/forms/*.fd
qt_l10n.pot: $(top_srcdir)/src/frontends/qt2/ui/*.ui
awk ' \
/<string>/ { \
if (NF > 1) { \
line=$$0; \
sub(/.*<string>/, "", line); \
sub(/<\/string>.*/, "", line); \
gsub(/&amp;/, "\\&", line); \
gsub(/&lt;/, "<", line); \
gsub(/&gt;/, ">", line); \
if (length(line) > 0) \
printf("#: %s:%d\nmsgid \"%s\"\nmsgstr \"\"\n\n",\
FILENAME, FNR, line); \
} \
}' \
`find $(top_srcdir)/src/frontends/qt2/ui -name \*.ui` > $@