diff --git a/po/lyx_pot.py b/po/lyx_pot.py index daeb2d1485..d1b4bdba69 100755 --- a/po/lyx_pot.py +++ b/po/lyx_pot.py @@ -81,6 +81,7 @@ def layouts_l10n(input_files, output, base): ListName = re.compile(r'\s*ListName\s+(.*)') CategoryName = re.compile(r'\s*Category\s+(.*)') NameRE = re.compile(r'DeclareLyXModule.*{(.*)}') + InsetLayout = re.compile(r'^InsetLayout\s+(.*)') DescBegin = re.compile(r'#+\s*DescriptionBegin\s*$') DescEnd = re.compile(r'#+\s*DescriptionEnd\s*$') @@ -139,6 +140,12 @@ def layouts_l10n(input_files, output, base): string = res.group(1) writeString(out, src, base, lineno, string) continue + res = InsetLayout.search(line) + if res != None: + string = res.group(1) + string = string.replace('_', ' ') + writeString(out, src, base, lineno, string) + continue out.close() diff --git a/src/frontends/qt4/Menus.cpp b/src/frontends/qt4/Menus.cpp index 7acb9e11b3..c124469e82 100644 --- a/src/frontends/qt4/Menus.cpp +++ b/src/frontends/qt4/Menus.cpp @@ -849,8 +849,8 @@ void MenuDefinition::expandFlexInsert(Buffer const * buf, string s) docstring const label = cit->first; if (cit->second.lyxtype() == s) addWithStatusCheck(MenuItem(MenuItem::Command, - toqstr(label), FuncRequest(LFUN_FLEX_INSERT, - label))); + toqstr(translateIfPossible(label)), + FuncRequest(LFUN_FLEX_INSERT, label))); } }