* src/frontends/qt4/Menus.cpp:

* po/lyx_pot.py:
	- make flex insets in the menus translatable.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@25276 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Jürgen Spitzmüller 2008-06-16 15:19:31 +00:00
parent 162e176006
commit 93ab5a427d
2 changed files with 9 additions and 2 deletions

View File

@ -81,6 +81,7 @@ def layouts_l10n(input_files, output, base):
ListName = re.compile(r'\s*ListName\s+(.*)') ListName = re.compile(r'\s*ListName\s+(.*)')
CategoryName = re.compile(r'\s*Category\s+(.*)') CategoryName = re.compile(r'\s*Category\s+(.*)')
NameRE = re.compile(r'DeclareLyXModule.*{(.*)}') NameRE = re.compile(r'DeclareLyXModule.*{(.*)}')
InsetLayout = re.compile(r'^InsetLayout\s+(.*)')
DescBegin = re.compile(r'#+\s*DescriptionBegin\s*$') DescBegin = re.compile(r'#+\s*DescriptionBegin\s*$')
DescEnd = re.compile(r'#+\s*DescriptionEnd\s*$') DescEnd = re.compile(r'#+\s*DescriptionEnd\s*$')
@ -139,6 +140,12 @@ def layouts_l10n(input_files, output, base):
string = res.group(1) string = res.group(1)
writeString(out, src, base, lineno, string) writeString(out, src, base, lineno, string)
continue continue
res = InsetLayout.search(line)
if res != None:
string = res.group(1)
string = string.replace('_', ' ')
writeString(out, src, base, lineno, string)
continue
out.close() out.close()

View File

@ -849,8 +849,8 @@ void MenuDefinition::expandFlexInsert(Buffer const * buf, string s)
docstring const label = cit->first; docstring const label = cit->first;
if (cit->second.lyxtype() == s) if (cit->second.lyxtype() == s)
addWithStatusCheck(MenuItem(MenuItem::Command, addWithStatusCheck(MenuItem(MenuItem::Command,
toqstr(label), FuncRequest(LFUN_FLEX_INSERT, toqstr(translateIfPossible(label)),
label))); FuncRequest(LFUN_FLEX_INSERT, label)));
} }
} }