[LyX features/features/indexmacros] Merge branch 'master' into features/indexmacros

Juergen Spitzmueller spitz at lyx.org
Tue Apr 19 10:26:40 UTC 2022


The branch, features/indexmacros, has been created.
        at  5093e39170f16fa685208f5ef1f9a6584f69c5dd (commit)

- Log -----------------------------------------------------------------

commit 5093e39170f16fa685208f5ef1f9a6584f69c5dd
Merge: 7d7b21e 50403c4
Author: Juergen Spitzmueller <spitz at lyx.org>
Date:   Tue Apr 19 11:54:11 2022 +0200

    Merge branch 'master' into features/indexmacros


commit 7d7b21ec3e60f0186929016d89a0dfeb4ad8c60f
Author: Juergen Spitzmueller <spitz at lyx.org>
Date:   Tue Apr 19 11:46:08 2022 +0200

    Introduce InsetIndexMacros
    
    This adds native macros for subindexes (!level), |see and |seealso
    as well as native support for ranges |( |) and pagination format
    -- e.g., |textbf -- via the index dialog
    
    Resolves #12478, #7232 and #5014
    
    The feature is complete (incl. tex2lyx) except for
    
    * file format change and lyx2lyx
    * docbook/xhtml
    * documentation

diff --git a/lib/layouts/stdinsets.inc b/lib/layouts/stdinsets.inc
index 074b274..4063c63 100644
--- a/lib/layouts/stdinsets.inc
+++ b/lib/layouts/stdinsets.inc
@@ -431,6 +431,36 @@ InsetLayout Index
 	PassThruChars         @|!
 End
 
+InsetLayout IndexMacro:see
+	LabelString           See
+	Decoration            classic
+	Font
+	  Size                Small
+	EndFont
+	LabelFont
+	  Color               indexlabel
+	  Size                Small
+	EndFont
+	MultiPar              false
+	CustomPars            false
+	ForcePlain            true
+End
+
+InsetLayout IndexMacro:seealso
+	CopyStyle             IndexMacro:see
+	LabelString           "See also"
+End
+
+InsetLayout IndexMacro:sortkey
+	CopyStyle             IndexMacro:see
+	LabelString           "Sort as"
+End
+
+InsetLayout IndexMacro:subindex
+	CopyStyle             IndexMacro:see
+	LabelString           "Subindex"
+End
+
 InsetLayout Box
 	LabelFont
 	  Color               foreground
diff --git a/lib/ui/stdcontext.inc b/lib/ui/stdcontext.inc
index ed9a9da..5929dbf 100644
--- a/lib/ui/stdcontext.inc
+++ b/lib/ui/stdcontext.inc
@@ -631,6 +631,23 @@ Menuset
 	Menu "context-index"
 		IndicesContext
 	End
+	
+	Menu "context-edit-index"
+		OptItem "Insert Subentry|b" "indexmacro-insert subindex"
+		OptItem "Insert Sortkey|k" "indexmacro-insert sortkey"
+		OptItem "Insert See Reference|e" "indexmacro-insert see"
+		OptItem "Insert See also Reference|a" "indexmacro-insert seealso"
+	End
+
+#
+# IndexMacro context menu
+#
+
+	Menu "context-indexmacro"
+		OptItem "See|e" "inset-modify changetype see"
+		OptItem "See also|a" "inset-modify changetype seealso"
+	End
+
 
 #
 # Index Lists context menu
diff --git a/lib/ui/stdmenus.inc b/lib/ui/stdmenus.inc
index ec5c5c0..2954b39 100644
--- a/lib/ui/stdmenus.inc
+++ b/lib/ui/stdmenus.inc
@@ -391,6 +391,7 @@ Menuset
 		Item "Label...|L" "label-insert"
 		Captions
 		Indices
+		OptSubmenu "Index Properties" "index_properties"
 		Item "Nomenclature Entry...|y" "nomencl-insert"
 		Separator
 		Item "Table...|T" "tabular-insert"
@@ -532,6 +533,13 @@ Menuset
 		Item "Double Frame|u" "box-insert Doublebox"
 	End
 
+	Menu "index_properties"
+		OptItem "Subentry|b" "indexmacro-insert subindex"
+		OptItem "Sortkey|k" "indexmacro-insert sortkey"
+		OptItem "See|e" "indexmacro-insert see"
+		OptItem "See also|a" "indexmacro-insert seealso"
+	End
+
 	Menu "insert_note"
 		Item "LyX Note|N" "note-insert Note"
 		Item "Comment|C" "note-insert Comment"
diff --git a/src/FuncCode.h b/src/FuncCode.h
index 8337c1f..6d7ed85 100644
--- a/src/FuncCode.h
+++ b/src/FuncCode.h
@@ -503,6 +503,8 @@ enum FuncCode
 	LFUN_FINISHED_DOWN,             // lasgouttes 20210629
 	LFUN_FINISHED_UP,               // lasgouttes 20210629
 	LFUN_BRANCH_SYNC_ALL,           // sanda 20220415
+	LFUN_INDEXMACRO_INSERT,         // spitz 20220220
+	// 395
 	LFUN_LASTACTION                 // end of the table
 };
 
diff --git a/src/LyXAction.cpp b/src/LyXAction.cpp
index 559d950..399b3c0 100644
--- a/src/LyXAction.cpp
+++ b/src/LyXAction.cpp
@@ -2323,6 +2323,16 @@ void LyXAction::init()
  */
 		{ LFUN_IN_MATHMACROTEMPLATE, "in-mathmacrotemplate", Noop, Math },
 
+/*!
+ * \var lyx::FuncCode lyx::LFUN_INDEXMACRO_INSERT
+ * \li Action: Inserts special Index macros into the document.
+ * \li Syntax: indexmacro-insert <type>
+ * \li Params: <type>: see, seealso, subindex, sortkey.
+ * \li Origin: spitz, 20 Feb 2022
+ * \endvar
+ */
+		{ LFUN_INDEXMACRO_INSERT, "indexmacro-insert", Noop, Edit },
+
 
 /*!
  * \var lyx::FuncCode lyx::LFUN_IPAMACRO_INSERT
diff --git a/src/Makefile.am b/src/Makefile.am
index 99a0f98..9a642d8 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -565,6 +565,7 @@ SOURCEFILESINSETS = \
 	insets/InsetHyperlink.cpp \
 	insets/InsetInclude.cpp \
 	insets/InsetIndex.cpp \
+	insets/InsetIndexMacro.cpp \
 	insets/InsetInfo.cpp \
 	insets/InsetIPA.cpp \
 	insets/InsetIPAMacro.cpp \
diff --git a/src/Text3.cpp b/src/Text3.cpp
index 185008b..bacc808 100644
--- a/src/Text3.cpp
+++ b/src/Text3.cpp
@@ -58,6 +58,7 @@
 #include "insets/InsetGraphics.h"
 #include "insets/InsetGraphicsParams.h"
 #include "insets/InsetInfo.h"
+#include "insets/InsetIndexMacro.h"
 #include "insets/InsetIPAMacro.h"
 #include "insets/InsetNewline.h"
 #include "insets/InsetQuotes.h"
@@ -2107,6 +2108,7 @@ void Text::dispatch(Cursor & cur, FuncRequest & cmd)
 	case LFUN_BRANCH_INSERT:
 	case LFUN_PHANTOM_INSERT:
 	case LFUN_ERT_INSERT:
+	case LFUN_INDEXMACRO_INSERT:
 	case LFUN_LISTING_INSERT:
 	case LFUN_MARGINALNOTE_INSERT:
 	case LFUN_ARGUMENT_INSERT:
@@ -3285,6 +3287,14 @@ bool Text::getStatus(Cursor & cur, FuncRequest const & cmd,
 		}
 		code = HYPERLINK_CODE;
 		break;
+	case LFUN_INDEXMACRO_INSERT: {
+		string const arg = cmd.getArg(0);
+		if (arg == "sortkey")
+			code = INDEXMACRO_SORTKEY_CODE;
+		else
+			code = INDEXMACRO_CODE;
+		break;
+	}
 	case LFUN_IPAMACRO_INSERT: {
 		string const arg = cmd.getArg(0);
 		if (arg == "deco")
diff --git a/src/factory.cpp b/src/factory.cpp
index 6f17797..4ab74da 100644
--- a/src/factory.cpp
+++ b/src/factory.cpp
@@ -34,6 +34,7 @@
 #include "insets/InsetHyperlink.h"
 #include "insets/InsetInclude.h"
 #include "insets/InsetIndex.h"
+#include "insets/InsetIndexMacro.cpp"
 #include "insets/InsetInfo.h"
 #include "insets/InsetIPA.h"
 #include "insets/InsetIPAMacro.h"
@@ -159,6 +160,16 @@ Inset * createInsetHelper(Buffer * buf, FuncRequest const & cmd)
 			return new InsetIPADeco(buf, arg2);
 		}
 
+		case LFUN_INDEXMACRO_INSERT: {
+			string const arg = cmd.getArg(0);
+			if (arg != "see" && arg != "seealso"
+			    && arg != "subindex" && arg != "sortkey") {
+				LYXERR0("LFUN_IPAMACRO_INSERT: wrong argument");
+				return nullptr;
+			}
+			return new InsetIndexMacro(buf, arg);
+		}
+
 		case LFUN_ERT_INSERT:
 			return new InsetERT(buf);
 
@@ -667,6 +678,9 @@ Inset * readInset(Lexer & lex, Buffer * buf)
 			inset.reset(new InsetCaption(buf, s));
 		} else if (tmptok == "Index") {
 			inset.reset(new InsetIndex(buf, InsetIndexParams()));
+		} else if (tmptok == "IndexMacro") {
+			string s = lex.getString();
+			inset.reset(new InsetIndexMacro(buf, s));
 		} else if (tmptok == "FloatList") {
 			inset.reset(new InsetFloatList(buf));
 		} else if (tmptok == "Info") {
diff --git a/src/frontends/qt/GuiIndex.cpp b/src/frontends/qt/GuiIndex.cpp
index 6264d6a..5e14580 100644
--- a/src/frontends/qt/GuiIndex.cpp
+++ b/src/frontends/qt/GuiIndex.cpp
@@ -20,6 +20,7 @@
 #include "BufferParams.h"
 #include "FuncRequest.h"
 #include "IndicesList.h"
+#include "insets/InsetIndex.h"
 
 #include <QPushButton>
 
@@ -37,6 +38,18 @@ GuiIndex::GuiIndex(GuiView & lv)
 		this, SLOT(slotButtonBox(QAbstractButton *)));
 	connect(indicesCO, SIGNAL(activated(int)), this, SLOT(change_adaptor()));
 
+	rangeCO->addItem(qt_("None"), InsetIndexParams::None);
+	rangeCO->addItem(qt_("Start"), InsetIndexParams::Start);
+	rangeCO->addItem(qt_("End"), InsetIndexParams::End);
+	connect(rangeCO, SIGNAL(activated(int)), this, SLOT(change_adaptor()));
+
+	pageFormatCO->addItem(qt_("Default"), toqstr("default"));
+	pageFormatCO->addItem(qt_("Bold"), toqstr("textbf"));
+	pageFormatCO->addItem(qt_("Italic"), toqstr("textit"));
+	pageFormatCO->addItem(qt_("Emphasized"), toqstr("emph"));
+	pageFormatCO->addItem(qt_("Custom"), toqstr("custom"));
+	connect(pageFormatCO, SIGNAL(activated(int)), this, SLOT(pageFormatChanged(int)));
+
 	bc().setPolicy(ButtonPolicy::NoRepeatedApplyReadOnlyPolicy);
 	bc().setOK(buttonBox->button(QDialogButtonBox::Ok));
 	bc().setCancel(buttonBox->button(QDialogButtonBox::Cancel));
@@ -49,11 +62,26 @@ void GuiIndex::change_adaptor()
 }
 
 
+void GuiIndex::pageFormatChanged(int i)
+{
+	QString const pf = pageFormatCO->itemData(i).toString();
+	pageFormatLE->setEnabled(pf == "custom");
+	change_adaptor();
+}
+
+
 void GuiIndex::updateContents()
 {
 	typedef IndicesList::const_iterator const_iterator;
 
-	IndicesList const & indiceslist = buffer().params().indiceslist();
+	BufferParams const & bp = buffer().masterBuffer()->params();
+	indicesGB->setEnabled(bp.use_indices);
+
+	QString const pf = pageFormatCO->itemData(
+		pageFormatCO->currentIndex()).toString();
+	pageFormatLE->setEnabled(pf == "custom");
+
+	IndicesList const & indiceslist = bp.indiceslist();
 	docstring const cur_index = params_.index;
 
 	indicesCO->clear();
@@ -64,8 +92,19 @@ void GuiIndex::updateContents()
 		indicesCO->addItem(toqstr(it->index()),
 			QVariant(toqstr(it->shortcut())));
 
-	int const pos = indicesCO->findData(toqstr(cur_index));
+	int pos = indicesCO->findData(toqstr(cur_index));
 	indicesCO->setCurrentIndex(pos);
+
+	pos = pageFormatCO->findData(toqstr(params_.pagefmt));
+	if (pos == -1) {
+		pos = pageFormatCO->findData("custom");
+		pageFormatLE->setText(toqstr(params_.pagefmt));
+	} else
+		pageFormatLE->clear();
+	pageFormatCO->setCurrentIndex(pos);
+
+	pos = rangeCO->findData(params_.range);
+	rangeCO->setCurrentIndex(pos);
 }
 
 
@@ -73,7 +112,15 @@ void GuiIndex::applyView()
 {
 	QString const index = indicesCO->itemData(
 		indicesCO->currentIndex()).toString();
+	int const range = rangeCO->itemData(
+		rangeCO->currentIndex()).toInt();
+	QString const pagefmt = pageFormatCO->itemData(
+		pageFormatCO->currentIndex()).toString();
 	params_.index = qstring_to_ucs4(index);
+	params_.range = InsetIndexParams::PageRange(range);
+	params_.pagefmt = (pagefmt == "custom") 
+			? fromqstr(pageFormatLE->text())
+			: fromqstr(pagefmt);
 }
 
 
diff --git a/src/frontends/qt/GuiIndex.h b/src/frontends/qt/GuiIndex.h
index bb99a22..0644644 100644
--- a/src/frontends/qt/GuiIndex.h
+++ b/src/frontends/qt/GuiIndex.h
@@ -31,6 +31,7 @@ public:
 
 private Q_SLOTS:
 	void change_adaptor();
+	void pageFormatChanged(int);
 
 private:
 	///  Apply changes
diff --git a/src/frontends/qt/ui/IndexUi.ui b/src/frontends/qt/ui/IndexUi.ui
index 95c2a71..a314489 100644
--- a/src/frontends/qt/ui/IndexUi.ui
+++ b/src/frontends/qt/ui/IndexUi.ui
@@ -6,8 +6,8 @@
    <rect>
     <x>0</x>
     <y>0</y>
-    <width>262</width>
-    <height>121</height>
+    <width>384</width>
+    <height>288</height>
    </rect>
   </property>
   <property name="windowTitle">
@@ -16,50 +16,119 @@
   <property name="sizeGripEnabled">
    <bool>true</bool>
   </property>
-  <layout class="QGridLayout" name="gridLayout">
+  <layout class="QGridLayout" name="gridLayout_3">
    <item row="0" column="0">
-    <layout class="QVBoxLayout">
-     <property name="spacing">
-      <number>6</number>
+    <widget class="QGroupBox" name="indicesGB">
+     <property name="title">
+      <string>Available I&ndexes</string>
      </property>
-     <property name="leftMargin">
-      <number>0</number>
-     </property>
-     <property name="topMargin">
-      <number>0</number>
-     </property>
-     <property name="rightMargin">
-      <number>0</number>
-     </property>
-     <property name="bottomMargin">
-      <number>0</number>
-     </property>
-     <item>
-      <widget class="QLabel" name="indicesLA">
-       <property name="text">
-        <string>Available I&ndexes:</string>
-       </property>
-       <property name="buddy">
-        <cstring>indicesCO</cstring>
-       </property>
-      </widget>
-     </item>
-     <item>
-      <widget class="QComboBox" name="indicesCO">
-       <property name="toolTip">
-        <string>Select the index this entry should be listed in.</string>
-       </property>
-      </widget>
-     </item>
-    </layout>
+     <layout class="QGridLayout" name="gridLayout">
+      <item row="0" column="0">
+       <widget class="QComboBox" name="indicesCO">
+        <property name="toolTip">
+         <string>Select the index this entry should be listed in.</string>
+        </property>
+       </widget>
+      </item>
+      <item row="0" column="1">
+       <spacer name="horizontalSpacer">
+        <property name="orientation">
+         <enum>Qt::Horizontal</enum>
+        </property>
+        <property name="sizeHint" stdset="0">
+         <size>
+          <width>40</width>
+          <height>20</height>
+         </size>
+        </property>
+       </spacer>
+      </item>
+     </layout>
+    </widget>
    </item>
    <item row="1" column="0">
+    <widget class="QGroupBox" name="paginationGB">
+     <property name="title">
+      <string>&Pagination</string>
+     </property>
+     <layout class="QGridLayout" name="gridLayout_2">
+      <item row="0" column="0">
+       <widget class="QLabel" name="rangeLA">
+        <property name="text">
+         <string>Page &Range:</string>
+        </property>
+        <property name="buddy">
+         <cstring>rangeCO</cstring>
+        </property>
+       </widget>
+      </item>
+      <item row="0" column="1">
+       <widget class="QComboBox" name="rangeCO">
+        <property name="toolTip">
+         <string>If the entry spans multiple pages, you can start or end the range here</string>
+        </property>
+       </widget>
+      </item>
+      <item row="0" column="2">
+       <spacer name="horizontalSpacer_2">
+        <property name="orientation">
+         <enum>Qt::Horizontal</enum>
+        </property>
+        <property name="sizeHint" stdset="0">
+         <size>
+          <width>112</width>
+          <height>20</height>
+         </size>
+        </property>
+       </spacer>
+      </item>
+      <item row="1" column="0">
+       <widget class="QLabel" name="pageFormatLA">
+        <property name="text">
+         <string>&Format:</string>
+        </property>
+        <property name="buddy">
+         <cstring>pageFormatCO</cstring>
+        </property>
+       </widget>
+      </item>
+      <item row="1" column="1">
+       <widget class="QComboBox" name="pageFormatCO">
+        <property name="toolTip">
+         <string>Customize the format of the page number here. Note that the format is not used with "See" and "See also" references.</string>
+        </property>
+       </widget>
+      </item>
+      <item row="1" column="2">
+       <widget class="QLineEdit" name="pageFormatLE">
+        <property name="toolTip">
+         <string>Enter custom command here (without leading backslash).</string>
+        </property>
+       </widget>
+      </item>
+     </layout>
+    </widget>
+   </item>
+   <item row="3" column="0">
     <widget class="QDialogButtonBox" name="buttonBox">
      <property name="standardButtons">
       <set>QDialogButtonBox::Cancel|QDialogButtonBox::Ok</set>
      </property>
     </widget>
    </item>
+   <item row="2" column="0">
+    <spacer name="verticalSpacer">
+     <property name="orientation">
+      <enum>Qt::Vertical</enum>
+     </property>
+     <property name="sizeHint" stdset="0">
+      <size>
+       <width>20</width>
+       <height>40</height>
+      </size>
+     </property>
+    </spacer>
+   </item>
   </layout>
  </widget>
  <tabstops>
diff --git a/src/insets/InsetCode.h b/src/insets/InsetCode.h
index 43ed4b5..0b60ebf 100644
--- a/src/insets/InsetCode.h
+++ b/src/insets/InsetCode.h
@@ -239,6 +239,10 @@ enum InsetCode {
 	///
 	COUNTER_CODE,
 	///
+	INDEXMACRO_CODE, // 110
+	///
+	INDEXMACRO_SORTKEY_CODE,
+	///
 	INSET_CODE_SIZE
 };
 
diff --git a/src/insets/InsetIndex.cpp b/src/insets/InsetIndex.cpp
index 8622263..8b69b6f 100644
--- a/src/insets/InsetIndex.cpp
+++ b/src/insets/InsetIndex.cpp
@@ -11,6 +11,7 @@
 #include <config.h>
 
 #include "InsetIndex.h"
+#include "InsetIndexMacro.h"
 
 #include "Buffer.h"
 #include "BufferParams.h"
@@ -19,10 +20,13 @@
 #include "Cursor.h"
 #include "DispatchResult.h"
 #include "Encoding.h"
+#include "ErrorList.h"
 #include "FuncRequest.h"
 #include "FuncStatus.h"
 #include "IndicesList.h"
+#include "InsetList.h"
 #include "Language.h"
+#include "LaTeX.h"
 #include "LaTeXFeatures.h"
 #include "Lexer.h"
 #include "output_latex.h"
@@ -37,6 +41,7 @@
 #include "support/FileName.h"
 #include "support/gettext.h"
 #include "support/lstrings.h"
+#include "support/Translator.h"
 
 #include "frontends/alert.h"
 
@@ -51,6 +56,62 @@ using namespace lyx::support;
 
 namespace lyx {
 
+namespace {
+
+typedef Translator<string, InsetIndexParams::PageRange> PageRangeTranslator;
+typedef Translator<docstring, InsetIndexParams::PageRange> PageRangeTranslatorLoc;
+
+PageRangeTranslator const init_insetindexpagerangetranslator()
+{
+	PageRangeTranslator translator("none", InsetIndexParams::None);
+	translator.addPair("start", InsetIndexParams::Start);
+	translator.addPair("end", InsetIndexParams::End);
+	return translator;
+}
+
+PageRangeTranslator const init_insetindexpagerangetranslator_latex()
+{
+	PageRangeTranslator translator("", InsetIndexParams::None);
+	translator.addPair("(", InsetIndexParams::Start);
+	translator.addPair(")", InsetIndexParams::End);
+	return translator;
+}
+
+
+PageRangeTranslatorLoc const init_insetindexpagerangetranslator_loc()
+{
+	PageRangeTranslatorLoc translator(docstring(), InsetIndexParams::None);
+	translator.addPair(_("Starts page range"), InsetIndexParams::Start);
+	translator.addPair(_("Ends page range"), InsetIndexParams::End);
+	return translator;
+}
+
+
+PageRangeTranslator const & insetindexpagerangetranslator()
+{
+	static PageRangeTranslator const prtranslator =
+			init_insetindexpagerangetranslator();
+	return prtranslator;
+}
+
+
+PageRangeTranslatorLoc const & insetindexpagerangetranslator_loc()
+{
+	static PageRangeTranslatorLoc const translator =
+			init_insetindexpagerangetranslator_loc();
+	return translator;
+}
+
+
+PageRangeTranslator const & insetindexpagerangetranslator_latex()
+{
+	static PageRangeTranslator const lttranslator =
+			init_insetindexpagerangetranslator_latex();
+	return lttranslator;
+}
+
+} // namespace anon
+
 /////////////////////////////////////////////////////////////////////
 //
 // InsetIndex
@@ -59,7 +120,7 @@ namespace lyx {
 
 
 InsetIndex::InsetIndex(Buffer * buf, InsetIndexParams const & params)
-        : InsetCollapsible(buf), params_(params)
+	: InsetCollapsible(buf), params_(params)
 {}
 
 
@@ -91,106 +152,108 @@ void InsetIndex::latex(otexstream & ios, OutputParams const & runparams_in) cons
 		return;
 	}
 
-	// For the sorting key, we use the plaintext version
-	odocstringstream ourplain;
-	InsetText::plaintext(ourplain, runparams);
-
-	// These are the LaTeX and plaintext representations
-	docstring latexstr = ourlatex.str();
-	docstring plainstr = ourplain.str();
-
-	// This will get what follows | if anything does,
-	// the command (e.g., see, textbf) for pagination
-	// formatting
-	docstring cmd;
-
-	// Check for the | separator to strip the cmd.
-	// This goes wrong on an escaped "|", but as the escape
-	// character can be changed in style files, we cannot
-	// prevent that.
-	size_t pos = latexstr.find(from_ascii("|"));
-	if (pos != docstring::npos) {
-		// Put the bit after "|" into cmd...
-		cmd = latexstr.substr(pos + 1);
-		// ...and erase that stuff from latexstr
-		latexstr = latexstr.erase(pos);
-		// ...as well as from plainstr
-		size_t ppos = plainstr.find(from_ascii("|"));
-		if (ppos < plainstr.size())
-			plainstr.erase(ppos);
-		else
-			LYXERR0("The `|' separator was not found in the plaintext version!");
-	}
+	if (hasSortKey()) {
+		getSortkey(os, runparams);
+		os << "@";
+		os << ourlatex.str();
+		getSubentries(os, runparams);
+		if (hasSeeRef()) {
+			os << "|";
+			os << insetindexpagerangetranslator_latex().find(params_.range);
+			getSeeRefs(os, runparams);
+		}
+	} else {
+		// We check whether we need a sort key.
+		// If so, we use the plaintext version
+		odocstringstream ourplain;
+		InsetText::plaintext(ourplain, runparams);
+
+		// These are the LaTeX and plaintext representations
+		docstring latexstr = ourlatex.str();
+		docstring plainstr = ourplain.str();
+	
+		// This will get what follows | if anything does,
+		// the command (e.g., see, textbf) for pagination
+		// formatting
+		docstring cmd;
+
+		if (hasSeeRef()) {
+			odocstringstream seeref;
+			otexstream otsee(seeref);
+			getSeeRefs(otsee, runparams);
+			cmd = seeref.str();
+		} else if (!params_.pagefmt.empty() && params_.pagefmt != "default") {
+			cmd = from_utf8(params_.pagefmt);
+		} else {
+			// Check for the | separator to strip the cmd.
+			// This goes wrong on an escaped "|", but as the escape
+			// character can be changed in style files, we cannot
+			// prevent that.
+			size_t pos = latexstr.find(from_ascii("|"));
+			if (pos != docstring::npos) {
+				// Put the bit after "|" into cmd...
+				cmd = latexstr.substr(pos + 1);
+				// ...and erase that stuff from latexstr
+				latexstr = latexstr.erase(pos);
+				// ...as well as from plainstr
+				size_t ppos = plainstr.find(from_ascii("|"));
+				if (ppos < plainstr.size())
+					plainstr.erase(ppos);
+				else
+					LYXERR0("The `|' separator was not found in the plaintext version!");
+			}
+		}
 
-	// Separate the entries and subentries, i.e., split on "!".
-	// This goes wrong on an escaped "!", but as the escape
-	// character can be changed in style files, we cannot
-	// prevent that.
-	std::vector<docstring> const levels =
-			getVectorFromString(latexstr, from_ascii("!"), true);
-	std::vector<docstring> const levels_plain =
-			getVectorFromString(plainstr, from_ascii("!"), true);
-
-	vector<docstring>::const_iterator it = levels.begin();
-	vector<docstring>::const_iterator end = levels.end();
-	vector<docstring>::const_iterator it2 = levels_plain.begin();
-	bool first = true;
-	for (; it != end; ++it) {
-		// The separator needs to be put back when
-		// writing the levels, except for the first level
-		if (!first)
-			os << '!';
-		else
-			first = false;
-
-		// Now here comes the reason for this whole procedure:
-		// We try to correctly sort macros and formatted strings.
-		// If we find a command, prepend a plain text
-		// version of the content to get sorting right,
-		// e.g. \index{LyX@\LyX}, \index{text@\textbf{text}}.
-		// We do this on all levels.
-		// We don't do it if the level already contains a '@', though.
-		if (contains(*it, '\\') && !contains(*it, '@')) {
-			// Plaintext might return nothing (e.g. for ERTs).
-			// In that case, we use LaTeX.
-			docstring const spart =
-					(it2 < levels_plain.end() && !(*it2).empty())
-					? *it2 : *it;
-			// Now we need to validate that all characters in
-			// the sorting part are representable in the current
-			// encoding. If not try the LaTeX macro which might
-			// or might not be a good choice, and issue a warning.
-			pair<docstring, docstring> spart_latexed =
-					runparams.encoding->latexString(spart, runparams.dryrun);
-			if (!spart_latexed.second.empty())
-				LYXERR0("Uncodable character in index entry. Sorting might be wrong!");
-			if (spart != spart_latexed.first && !runparams.dryrun) {
-				// FIXME: warning should be passed to the error dialog
-				frontend::Alert::warning(_("Index sorting failed"),
-							 bformat(_("LyX's automatic index sorting algorithm faced\n"
-								   "problems with the entry '%1$s'.\n"
-								   "Please specify the sorting of this entry manually, as\n"
-								   "explained in the User Guide."), spart));
+		odocstringstream subentries;
+		otexstream otsub(subentries);
+		getSubentries(otsub, runparams);
+		if (subentries.str().empty()) {
+			// Separate the entries and subentries, i.e., split on "!".
+			// This goes wrong on an escaped "!", but as the escape
+			// character can be changed in style files, we cannot
+			// prevent that.
+			std::vector<docstring> const levels =
+					getVectorFromString(latexstr, from_ascii("!"), true);
+			std::vector<docstring> const levels_plain =
+					getVectorFromString(plainstr, from_ascii("!"), true);
+		
+			vector<docstring>::const_iterator it = levels.begin();
+			vector<docstring>::const_iterator end = levels.end();
+			vector<docstring>::const_iterator it2 = levels_plain.begin();
+			bool first = true;
+			for (; it != end; ++it) {
+				// The separator needs to be put back when
+				// writing the levels, except for the first level
+				if (!first)
+					os << '!';
+				else
+					first = false;
+		
+				// Now here comes the reason for this whole procedure:
+				// We try to correctly sort macros and formatted strings.
+				// If we find a command, prepend a plain text
+				// version of the content to get sorting right,
+				// e.g. \index{LyX@\LyX}, \index{text@\textbf{text}}.
+				// We do this on all levels.
+				// We don't do it if the level already contains a '@', though.
+				// Plaintext might return nothing (e.g. for ERTs).
+				// In that case, we use LaTeX.
+				docstring const spart = (levels_plain.empty() || (*it2).empty()) ? *it : *it2;
+				processLatexSorting(os, runparams, *it, spart);
+				if (it2 < levels_plain.end())
+					++it2;
 			}
-			// Remove remaining \'s from the sort key
-			docstring ppart = subst(spart_latexed.first, from_ascii("\\"), docstring());
-			// Plain quotes need to be escaped, however (#10649), as this
-			// is the default escape character
-			ppart = subst(ppart, from_ascii("\""), from_ascii("\\\""));
-
-			// Now insert the sortkey, separated by '@'.
-			os << ppart;
-			os << '@';
+		} else {
+			processLatexSorting(os, runparams, latexstr, plainstr);
+			os << subentries.str();
+		}
+
+		// At last, re-insert the command, separated by "|"
+		if (!cmd.empty()) {
+			os << "|"
+			   << insetindexpagerangetranslator_latex().find(params_.range)
+			   << cmd;
 		}
-		// Insert the actual level text
-		docstring const tpart = *it;
-		os << tpart;
-		if (it2 < levels_plain.end())
-			++it2;
-	}
-	// At last, re-insert the command, separated by "|"
-	if (!cmd.empty()) {
-		os << "|" << cmd;
 	}
 	os << '}';
 
@@ -203,6 +266,45 @@ void InsetIndex::latex(otexstream & ios, OutputParams const & runparams_in) cons
 }
 
 
+void InsetIndex::processLatexSorting(otexstream & os, OutputParams const & runparams,
+				docstring const latex, docstring const spart) const
+{
+	if (contains(latex, '\\') && !contains(latex, '@')) {
+		// Now we need to validate that all characters in
+		// the sorting part are representable in the current
+		// encoding. If not try the LaTeX macro which might
+		// or might not be a good choice, and issue a warning.
+		pair<docstring, docstring> spart_latexed =
+				runparams.encoding->latexString(spart, runparams.dryrun);
+		if (!spart_latexed.second.empty())
+			LYXERR0("Uncodable character in index entry. Sorting might be wrong!");
+		if (spart != spart_latexed.first && !runparams.dryrun) {
+			TeXErrors terr;
+			ErrorList & errorList = buffer().errorList("Export");
+			docstring const s = bformat(_("LyX's automatic index sorting algorithm faced "
+						      "problems with the entry '%1$s'.\n"
+						      "Please specify the sorting of this entry manually, as "
+						      "explained in the User Guide."), spart);
+			Paragraph const & par = buffer().paragraphs().front();
+			errorList.push_back(ErrorItem(_("Index sorting failed"), s,
+						      {par.id(), 0}, {par.id(), -1}));
+			buffer().bufferErrors(terr, errorList);
+		}
+		// Remove remaining \'s from the sort key
+		docstring ppart = subst(spart_latexed.first, from_ascii("\\"), docstring());
+		// Plain quotes need to be escaped, however (#10649), as this
+		// is the default escape character
+		ppart = subst(ppart, from_ascii("\""), from_ascii("\\\""));
+
+		// Now insert the sortkey, separated by '@'.
+		os << ppart;
+		os << '@';
+	}
+	// Insert the actual level text
+	os << latex;
+}
+
+
 void InsetIndex::docbook(XMLStream & xs, OutputParams const & runparams) const
 {
 	// Get the content of the inset as LaTeX, as some things may be encoded as ERT (like {}).
@@ -445,6 +547,8 @@ void InsetIndex::doDispatch(Cursor & cur, FuncRequest & cmd)
 		InsetIndex::string2params(to_utf8(cmd.argument()), params);
 		cur.recordUndoInset(this);
 		params_.index = params.index;
+		params_.range = params.range;
+		params_.pagefmt = params.pagefmt;
 		// what we really want here is a TOC update, but that means
 		// a full buffer update
 		cur.forceBufferUpdate();
@@ -485,6 +589,9 @@ bool InsetIndex::getStatus(Cursor & cur, FuncRequest const & cmd,
 		flag.setEnabled(realbuffer.params().use_indices);
 		return true;
 	}
+	
+	case LFUN_INDEXMACRO_INSERT:
+		return macrosPossible(cmd.getArg(0));
 
 	default:
 		return InsetCollapsible::getStatus(cur, cmd, flag);
@@ -492,6 +599,125 @@ bool InsetIndex::getStatus(Cursor & cur, FuncRequest const & cmd,
 }
 
 
+void InsetIndex::getSortkey(otexstream & os, OutputParams const & runparams) const
+{
+	Paragraph const & par = paragraphs().front();
+	InsetList::const_iterator it = par.insetList().begin();
+	for (; it != par.insetList().end(); ++it) {
+		Inset & inset = *it->inset;
+		if (inset.lyxCode() == INDEXMACRO_SORTKEY_CODE) {
+			InsetIndexMacro const & iim =
+				static_cast<InsetIndexMacro const &>(inset);
+			iim.getLatex(os, runparams);
+			return;
+		}
+	}
+}
+
+
+void InsetIndex::getSubentries(otexstream & os, OutputParams const & runparams) const
+{
+	Paragraph const & par = paragraphs().front();
+	InsetList::const_iterator it = par.insetList().begin();
+	int i = 0;
+	for (; it != par.insetList().end(); ++it) {
+		Inset & inset = *it->inset;
+		if (inset.lyxCode() == INDEXMACRO_CODE) {
+			InsetIndexMacro const & iim =
+				static_cast<InsetIndexMacro const &>(inset);
+			if (iim.params().type == InsetIndexMacroParams::Subindex) {
+				++i;
+				if (i > 2)
+					return;
+				os << "!";
+				iim.getLatex(os, runparams);
+			}
+		}
+	}
+}
+
+
+void InsetIndex::getSeeRefs(otexstream & os, OutputParams const & runparams) const
+{
+	Paragraph const & par = paragraphs().front();
+	InsetList::const_iterator it = par.insetList().begin();
+	for (; it != par.insetList().end(); ++it) {
+		Inset & inset = *it->inset;
+		if (inset.lyxCode() == INDEXMACRO_CODE) {
+			InsetIndexMacro const & iim =
+				static_cast<InsetIndexMacro const &>(inset);
+			if (iim.params().type == InsetIndexMacroParams::See
+			    || iim.params().type == InsetIndexMacroParams::Seealso) {
+				iim.getLatex(os, runparams);
+				return;
+			}
+		}
+	}
+}
+
+
+bool InsetIndex::hasSeeRef() const
+{
+	Paragraph const & par = paragraphs().front();
+	InsetList::const_iterator it = par.insetList().begin();
+	for (; it != par.insetList().end(); ++it) {
+		Inset & inset = *it->inset;
+		if (inset.lyxCode() == INDEXMACRO_CODE) {
+			InsetIndexMacro const & iim =
+				static_cast<InsetIndexMacro const &>(inset);
+			if (iim.params().type == InsetIndexMacroParams::See
+			    || iim.params().type == InsetIndexMacroParams::Seealso)
+				return true;
+		}
+	}
+	return false;
+}
+
+
+bool InsetIndex::hasSortKey() const
+{
+	Paragraph const & par = paragraphs().front();
+	InsetList::const_iterator it = par.insetList().begin();
+	for (; it != par.insetList().end(); ++it) {
+		Inset & inset = *it->inset;
+		if (inset.lyxCode() == INDEXMACRO_SORTKEY_CODE)
+			return true;
+	}
+	return false;
+}
+
+
+bool InsetIndex::macrosPossible(string const type) const
+{
+	if (type != "see" && type != "seealso"
+	    && type != "sortkey" && type != "subindex")
+		return false;
+
+	Paragraph const & par = paragraphs().front();
+	InsetList::const_iterator it = par.insetList().begin();
+	int subidxs = 0;
+	for (; it != par.insetList().end(); ++it) {
+		Inset & inset = *it->inset;
+		if (type == "sortkey" && inset.lyxCode() == INDEXMACRO_SORTKEY_CODE)
+			return false;
+		if (inset.lyxCode() == INDEXMACRO_CODE) {
+			InsetIndexMacro const & iim = static_cast<InsetIndexMacro const &>(inset);
+			if ((type == "see" || type == "seealso")
+			     && (iim.params().type == InsetIndexMacroParams::See
+				 || iim.params().type == InsetIndexMacroParams::Seealso))
+				return false;
+			if (type == "subindex"
+			     && iim.params().type == InsetIndexMacroParams::Subindex) {
+				++subidxs;
+				if (subidxs > 1)
+					return false;
+			}
+		}
+	}
+	return true;
+}
+
+
 ColorCode InsetIndex::labelColor() const
 {
 	if (params_.index.empty() || params_.index == from_ascii("idx"))
@@ -520,7 +746,21 @@ docstring InsetIndex::toolTip(BufferView const &, int, int) const
 		tip += ")";
 	}
 	tip += ": ";
-	return toolTipText(tip);
+	docstring res = toolTipText(tip);
+	if (!insetindexpagerangetranslator_loc().find(params_.range).empty())
+		res += "\n" + insetindexpagerangetranslator_loc().find(params_.range);
+	if (!params_.pagefmt.empty() && params_.pagefmt != "default") {
+		res += "\n" + _("Pagination format:") + " ";
+		if (params_.pagefmt == "textbf")
+			res += _("bold");
+		else if (params_.pagefmt == "textit")
+			res += _("italic");
+		else if (params_.pagefmt == "emph")
+			res += _("emphasized");
+		else
+			res += from_utf8(params_.pagefmt);
+	}
+	return res;
 }
 
 
@@ -541,9 +781,14 @@ docstring const InsetIndex::buttonLabel(BufferView const & bv) const
 		label += ")";
 	}
 
+	docstring res;
 	if (!il.contentaslabel() || geometry(bv) != ButtonOnly)
-		return label;
-	return getNewLabel(label);
+		res = label;
+	else
+		res = getNewLabel(label);
+	if (!insetindexpagerangetranslator_latex().find(params_.range).empty())
+		res += " " + from_ascii(insetindexpagerangetranslator_latex().find(params_.range));
+	return res;
 }
 
 
@@ -621,12 +866,33 @@ string InsetIndex::contextMenuName() const
 }
 
 
+string InsetIndex::contextMenu(BufferView const & bv, int x, int y) const
+{
+	// We override the implementation of InsetCollapsible,
+	// because we have eytra entries.
+	string owncm = "context-edit-index;";
+	return owncm + InsetCollapsible::contextMenu(bv, x, y);
+}
+
+
 bool InsetIndex::hasSettings() const
 {
-	return buffer().masterBuffer()->params().use_indices;
+	return true;
 }
 
 
+bool InsetIndex::insetAllowed(InsetCode code) const
+{
+	switch (code) {
+	case INDEXMACRO_CODE:
+	case INDEXMACRO_SORTKEY_CODE:
+		return true;
+	case INDEX_CODE:
+		return false;
+	default:
+		return InsetCollapsible::insetAllowed(code);
+	}
+}
 
 
 /////////////////////////////////////////////////////////////////////
@@ -644,6 +910,12 @@ void InsetIndexParams::write(ostream & os) const
 	else
 		os << "idx";
 	os << '\n';
+	os << "range "
+	   << insetindexpagerangetranslator().find(range)
+	   << '\n';
+	os << "pageformat "
+	   << pagefmt
+	   << '\n';
 }
 
 
@@ -653,6 +925,16 @@ void InsetIndexParams::read(Lexer & lex)
 		index = lex.getDocString();
 	else
 		index = from_ascii("idx");
+	if (lex.checkFor("range")) {
+		string st = lex.getString();
+		if (lex.eatLine()) {
+			st = lex.getString();
+			range = insetindexpagerangetranslator().find(lex.getString());
+		}
+	}
+	if (lex.checkFor("pageformat") && lex.eatLine()) {
+		pagefmt = lex.getString();
+	}
 }
 
 
diff --git a/src/insets/InsetIndex.h b/src/insets/InsetIndex.h
index b064cc7..97a82ba 100644
--- a/src/insets/InsetIndex.h
+++ b/src/insets/InsetIndex.h
@@ -21,15 +21,24 @@ namespace lyx {
 
 class InsetIndexParams {
 public:
+	enum PageRange {
+		None,
+		Start,
+		End
+	};
 	///
 	explicit InsetIndexParams(docstring const & b = docstring())
-		: index(b) {}
+		: index(b), range(None), pagefmt("default") {}
 	///
 	void write(std::ostream & os) const;
 	///
 	void read(Lexer & lex);
 	///
 	docstring index;
+	///
+	PageRange range;
+	///
+	std::string pagefmt;
 };
 
 
@@ -63,6 +72,9 @@ private:
 	///
 	void latex(otexstream &, OutputParams const &) const override;
 	///
+	void processLatexSorting(otexstream &, OutputParams const &,
+				 docstring const, docstring const) const;
+	///
 	bool showInsetDialog(BufferView *) const override;
 	///
 	bool getStatus(Cursor &, FuncRequest const &, FuncStatus &) const override;
@@ -80,11 +92,27 @@ private:
 	/// Updates needed features for this inset.
 	void validate(LaTeXFeatures & features) const override;
 	///
+	void getSortkey(otexstream &, OutputParams const &) const;
+	///
+	void getSubentries(otexstream &, OutputParams const &) const;
+	///
+	void getSeeRefs(otexstream &, OutputParams const &) const;
+	///
+	bool hasSeeRef() const;
+	///
+	bool hasSortKey() const;
+	///
+	bool macrosPossible(std::string const type) const;
+	///
 	std::string contextMenuName() const override;
 	///
+	std::string contextMenu(BufferView const &, int, int) const override;
+	///
 	Inset * clone() const override { return new InsetIndex(*this); }
 	/// Is the content of this inset part of the immediate text sequence?
 	bool isPartOfTextSequence() const override { return false; }
+	///
+	bool insetAllowed(InsetCode code) const override;
 
 	///
 	friend class InsetIndexParams;
diff --git a/src/insets/InsetIndexMacro.cpp b/src/insets/InsetIndexMacro.cpp
new file mode 100644
index 0000000..2bfbc91
--- /dev/null
+++ b/src/insets/InsetIndexMacro.cpp
@@ -0,0 +1,384 @@
+/**
+ * \file InsetIndexMacro.cpp
+ * This file is part of LyX, the document processor.
+ * Licence details can be found in the file COPYING.
+ *
+ * \author Jürgen Spitzmüller
+ *
+ * Full author contact details are available in file CREDITS.
+ */
+
+#include <config.h>
+
+#include "InsetIndexMacro.h"
+
+#include "Buffer.h"
+#include "BufferParams.h"
+#include "Cursor.h"
+#include "Dimension.h"
+#include "Encoding.h"
+#include "ErrorList.h"
+#include "FontInfo.h"
+#include "FuncRequest.h"
+#include "FuncStatus.h"
+#include "InsetLayout.h"
+#include "InsetList.h"
+#include "LaTeX.h"
+#include "LaTeXFeatures.h"
+#include "Lexer.h"
+#include "MetricsInfo.h"
+#include "xml.h"
+#include "texstream.h"
+
+#include "frontends/alert.h"
+
+#include "support/debug.h"
+#include "support/docstream.h"
+#include "support/gettext.h"
+#include "support/lstrings.h"
+#include "support/Translator.h"
+
+using namespace std;
+using namespace lyx::support;
+
+namespace lyx {
+
+namespace {
+
+typedef Translator<string, InsetIndexMacroParams::Type> InsetIndexMacroTranslator;
+typedef Translator<docstring, InsetIndexMacroParams::Type> InsetIndexMacroTranslatorLoc;
+
+InsetIndexMacroTranslator const init_insetindexmacrotranslator()
+{
+	InsetIndexMacroTranslator translator("see", InsetIndexMacroParams::See);
+	translator.addPair("seealso", InsetIndexMacroParams::Seealso);
+	translator.addPair("subindex", InsetIndexMacroParams::Subindex);
+	translator.addPair("sortkey", InsetIndexMacroParams::Sortkey);
+	return translator;
+}
+
+
+InsetIndexMacroTranslatorLoc const init_insetindexmacrotranslator_loc()
+{
+	InsetIndexMacroTranslatorLoc translator(_("See"), InsetIndexMacroParams::See);
+	translator.addPair(_("See also"), InsetIndexMacroParams::Seealso);
+	translator.addPair(_("Subindex"), InsetIndexMacroParams::Subindex);
+	translator.addPair(_("Sort as"), InsetIndexMacroParams::Sortkey);
+	return translator;
+}
+
+
+InsetIndexMacroTranslator const & insetindexmacrotranslator()
+{
+	static InsetIndexMacroTranslator const macrotranslator =
+			init_insetindexmacrotranslator();
+	return macrotranslator;
+}
+
+
+InsetIndexMacroTranslatorLoc const & insetindexmacrotranslator_loc()
+{
+	static InsetIndexMacroTranslatorLoc const translator =
+			init_insetindexmacrotranslator_loc();
+	return translator;
+}
+
+} // namespace
+
+
+InsetIndexMacroParams::InsetIndexMacroParams()
+	: type(See)
+{}
+
+
+void InsetIndexMacroParams::write(ostream & os) const
+{
+	string const label = insetindexmacrotranslator().find(type);
+	os << "IndexMacro " << label << "\n";
+}
+
+
+void InsetIndexMacroParams::read(Lexer & lex)
+{
+	string label;
+	lex >> label;
+	if (lex)
+		type = insetindexmacrotranslator().find(label);
+}
+
+
+/////////////////////////////////////////////////////////////////////
+//
+// InsetIndexMacro
+//
+/////////////////////////////////////////////////////////////////////
+
+InsetIndexMacro::InsetIndexMacro(Buffer * buf, string const & label)
+	: InsetCollapsible(buf)
+{
+	setDrawFrame(true);
+	setFrameColor(Color_insetframe);
+	params_.type = insetindexmacrotranslator().find(label);
+}
+
+
+InsetIndexMacro::~InsetIndexMacro()
+{}
+
+
+docstring InsetIndexMacro::layoutName() const
+{
+	return from_ascii("IndexMacro:" + insetindexmacrotranslator().find(params_.type));
+}
+
+InsetCode InsetIndexMacro::lyxCode() const
+{
+	return params_.type == InsetIndexMacroParams::Sortkey
+			? INDEXMACRO_SORTKEY_CODE
+			: INDEXMACRO_CODE;
+}
+
+
+void InsetIndexMacro::write(ostream & os) const
+{
+	params_.write(os);
+	InsetCollapsible::write(os);
+}
+
+
+void InsetIndexMacro::read(Lexer & lex)
+{
+	params_.read(lex);
+	InsetCollapsible::read(lex);
+}
+
+
+void InsetIndexMacro::getLatex(otexstream & os, OutputParams const & runparams) const
+{
+	if (params_.type == InsetIndexMacroParams::Subindex) {
+		if (hasSortKey()) {
+			getSortkey(os, runparams);
+			os << "@";
+		} else {
+			odocstringstream ourlatex;
+			otexstream ots(ourlatex);
+			InsetText::latex(ots, runparams);
+			odocstringstream ourplain;
+			InsetText::plaintext(ourplain, runparams);
+			// These are the LaTeX and plaintext representations
+			docstring latexstr = ourlatex.str();
+			docstring plainstr = ourplain.str();
+			processLatexSorting(os, runparams, latexstr, plainstr);
+		}
+		return;
+	}
+
+	if (params_.type == InsetIndexMacroParams::See)
+		os << "see{";
+	else if (params_.type == InsetIndexMacroParams::Seealso)
+		os << "seealso{";
+
+	InsetCollapsible::latex(os, runparams);
+
+	if (params_.type == InsetIndexMacroParams::See
+	     || params_.type == InsetIndexMacroParams::Seealso)
+		os << "}";
+}
+
+
+int InsetIndexMacro::getPlaintext(odocstringstream & os,
+			    OutputParams const & runparams, size_t max_length) const
+{
+	return InsetText::plaintext(os, runparams, max_length);
+}
+
+
+void InsetIndexMacro::getDocbook(XMLStream & xs, OutputParams const & runparams) const
+{
+	InsetText::docbook(xs, runparams);
+}
+
+
+docstring InsetIndexMacro::getXhtml(XMLStream & xs, OutputParams const & runparams) const
+{
+	return InsetText::xhtml(xs, runparams);
+}
+
+
+void InsetIndexMacro::doDispatch(Cursor & cur, FuncRequest & cmd)
+{
+	switch (cmd.action()) {
+
+	case LFUN_INSET_MODIFY: {
+		if (cmd.getArg(0) == "changetype") {
+			cur.recordUndoInset(this);
+			params_.type = insetindexmacrotranslator().find(cmd.getArg(1));
+			break;
+		}
+		InsetCollapsible::doDispatch(cur, cmd);
+		break;
+	}
+
+	default:
+		InsetCollapsible::doDispatch(cur, cmd);
+		break;
+	}
+}
+
+
+bool InsetIndexMacro::getStatus(Cursor & cur, FuncRequest const & cmd,
+				FuncStatus & flag) const
+{
+	switch (cmd.action()) {
+
+	case LFUN_INSET_MODIFY:
+		if (cmd.getArg(0) == "changetype") {
+			docstring const newtype = from_utf8(cmd.getArg(1));
+			bool const enabled = (params_.type == InsetIndexMacroParams::See
+					      || params_.type == InsetIndexMacroParams::Seealso)
+					    && (newtype == "see" || newtype == "seealso");
+			flag.setEnabled(enabled);
+			flag.setOnOff(
+				newtype == from_ascii(insetindexmacrotranslator().find(params_.type)));
+			return true;
+		}
+		return InsetCollapsible::getStatus(cur, cmd, flag);
+
+	default:
+		return InsetCollapsible::getStatus(cur, cmd, flag);
+	}
+}
+
+
+void InsetIndexMacro::processLatexSorting(otexstream & os, OutputParams const & runparams,
+				docstring const latex, docstring const plain) const
+{
+	if (contains(latex, '\\') && !contains(latex, '@')) {
+		// Plaintext might return nothing (e.g. for ERTs).
+		// In that case, we use LaTeX.
+		docstring const spart = (plain.empty()) ? latex : plain;
+		// Now we need to validate that all characters in
+		// the sorting part are representable in the current
+		// encoding. If not try the LaTeX macro which might
+		// or might not be a good choice, and issue a warning.
+		pair<docstring, docstring> spart_latexed =
+				runparams.encoding->latexString(spart, runparams.dryrun);
+		if (!spart_latexed.second.empty())
+			LYXERR0("Uncodable character in index entry. Sorting might be wrong!");
+		if (spart != spart_latexed.first && !runparams.dryrun) {
+			TeXErrors terr;
+			ErrorList & errorList = buffer().errorList("Export");
+			docstring const s = bformat(_("LyX's automatic index sorting algorithm faced "
+						      "problems with the sub-entry '%1$s'.\n"
+						      "Please specify the sorting of this entry manually, as "
+						      "explained in the User Guide."), spart);
+			Paragraph const & par = buffer().paragraphs().front();
+			errorList.push_back(ErrorItem(_("Index sorting failed"), s,
+						      {par.id(), 0}, {par.id(), -1}));
+			buffer().bufferErrors(terr, errorList);
+		}
+		// Remove remaining \'s from the sort key
+		docstring ppart = subst(spart_latexed.first, from_ascii("\\"), docstring());
+		// Plain quotes need to be escaped, however (#10649), as this
+		// is the default escape character
+		ppart = subst(ppart, from_ascii("\""), from_ascii("\\\""));
+
+		// Now insert the sortkey, separated by '@'.
+		os << ppart;
+		os << '@';
+	}
+	// Insert the actual level text
+	os << latex;
+}
+
+
+docstring InsetIndexMacro::toolTip(BufferView const &, int, int) const
+{
+	return insetindexmacrotranslator_loc().find(params_.type);
+}
+
+
+string InsetIndexMacro::params2string(InsetIndexMacroParams const & params)
+{
+	ostringstream data;
+	data << "IndexMacro" << ' ';
+	params.write(data);
+	return data.str();
+}
+
+
+void InsetIndexMacro::string2params(string const & in, InsetIndexMacroParams & params)
+{
+	params = InsetIndexMacroParams();
+
+	if (in.empty())
+		return;
+
+	istringstream data(in);
+	Lexer lex;
+	lex.setStream(data);
+	lex.setContext("InsetIndexMacro::string2params");
+	lex >> "IndexMacro" >> "see";
+
+	params.read(lex);
+}
+
+
+bool InsetIndexMacro::hasSortKey() const
+{
+	Paragraph const & par = paragraphs().front();
+	InsetList::const_iterator it = par.insetList().begin();
+	for (; it != par.insetList().end(); ++it) {
+		Inset & inset = *it->inset;
+		if (inset.lyxCode() == INDEXMACRO_SORTKEY_CODE)
+			return true;
+	}
+	return false;
+}
+
+
+void InsetIndexMacro::getSortkey(otexstream & os, OutputParams const & runparams) const
+{
+	Paragraph const & par = paragraphs().front();
+	InsetList::const_iterator it = par.insetList().begin();
+	for (; it != par.insetList().end(); ++it) {
+		Inset & inset = *it->inset;
+		if (inset.lyxCode() == INDEXMACRO_SORTKEY_CODE) {
+			InsetIndexMacro const & iim =
+				static_cast<InsetIndexMacro const &>(inset);
+			iim.getLatex(os, runparams);
+			return;
+		}
+	}
+}
+
+
+string InsetIndexMacro::contextMenuName() const
+{
+	return "context-indexmacro";
+}
+
+
+string InsetIndexMacro::contextMenu(BufferView const & bv, int x, int y) const
+{
+	// We override the implementation of InsetCollapsible,
+	// because we have eytra entries.
+	string owncm = "context-edit-index;";
+	return owncm + InsetCollapsible::contextMenu(bv, x, y);
+}
+
+
+bool InsetIndexMacro::insetAllowed(InsetCode code) const
+{
+	switch (code) {
+	case INDEX_CODE:
+		return false;
+	case INDEXMACRO_SORTKEY_CODE:
+		return (params_.type == InsetIndexMacroParams::Subindex
+			&& !hasSortKey());
+	default:
+		return InsetCollapsible::insetAllowed(code);
+	}
+}
+
+} // namespace lyx
diff --git a/src/insets/InsetIndexMacro.h b/src/insets/InsetIndexMacro.h
new file mode 100644
index 0000000..4122621
--- /dev/null
+++ b/src/insets/InsetIndexMacro.h
@@ -0,0 +1,125 @@
+// -*- C++ -*-
+/**
+ * \file InsetIndexMacro.h
+ * This file is part of LyX, the document processor.
+ * Licence details can be found in the file COPYING.
+ *
+ * \author Jürgen Spitzmüller
+ *
+ * Full author contact details are available in file CREDITS.
+ */
+
+#ifndef INSET_INSETMACRO_H
+#define INSET_INSETMACRO_H
+
+
+#include "Inset.h"
+#include "InsetCollapsible.h"
+
+
+namespace lyx {
+
+class LaTeXFeatures;
+
+class InsetIndexMacroParams
+{
+public:
+	enum Type {
+		See,
+		Seealso,
+		Subindex,
+		Sortkey
+	};
+	///
+	InsetIndexMacroParams();
+	///
+	void write(std::ostream & os) const;
+	///
+	void read(Lexer & lex);
+	///
+	Type type;
+};
+
+/////////////////////////////////////////////////////////////////////////
+//
+// InsetIndexMacro
+//
+/////////////////////////////////////////////////////////////////////////
+
+/// Used to insert index references
+class InsetIndexMacro : public InsetCollapsible
+{
+public:
+	///
+	InsetIndexMacro(Buffer *, std::string const &);
+	///
+	~InsetIndexMacro();
+	///
+	static std::string params2string(InsetIndexMacroParams const &);
+	///
+	static void string2params(std::string const &, InsetIndexMacroParams &);
+	///
+	InsetIndexMacroParams const & params() const { return params_; }
+	///
+	void getLatex(otexstream &, OutputParams const &) const;
+	///
+	int getPlaintext(odocstringstream &, OutputParams const &, size_t) const;
+	///
+	void getDocbook(XMLStream &, OutputParams const &) const;
+private:
+	///
+	InsetCode lyxCode() const override;
+	///
+	docstring layoutName() const override;
+	///
+	void write(std::ostream &) const override;
+	///
+	void read(Lexer & lex) override;
+	///
+	bool neverIndent() const override { return true; }
+	/// We do not output anything directly to the stream
+	void latex(otexstream &, OutputParams const &) const override {};
+	/// We do not output anything directly to the stream
+	int plaintext(odocstringstream &, OutputParams const &, size_t) const override { return 0; };
+	/// We do not output anything directly to the stream
+	void docbook(XMLStream &, OutputParams const &) const override {};
+	/// We do not output anything directly to the stream
+	docstring xhtml(XMLStream &, OutputParams const &) const override { return docstring(); };
+	///
+	docstring getXhtml(XMLStream &, OutputParams const &) const;
+	///
+	bool allowSpellCheck() const override { return false; }
+	///
+	bool insetAllowed(InsetCode code) const override;
+	///
+	bool getStatus(Cursor &, FuncRequest const &, FuncStatus &) const override;
+	///
+	void doDispatch(Cursor & cur, FuncRequest & cmd) override;
+	///
+	docstring toolTip(BufferView const & bv, int x, int y) const override;
+	///
+	void processLatexSorting(otexstream &, OutputParams const &,
+			    docstring const, docstring const) const;
+	///
+	bool hasSortKey() const;
+	///
+	void getSortkey(otexstream &, OutputParams const &) const;
+	///
+	std::string contextMenuName() const override;
+	///
+	std::string contextMenu(BufferView const &, int, int) const override;
+	///
+	Inset * clone() const override { return new InsetIndexMacro(*this); }
+	/// used by the constructors
+	void init();
+	///
+	friend class InsetIndexMacroParams;
+
+	///
+	InsetIndexMacroParams params_;
+};
+
+
+} // namespace lyx
+
+#endif
diff --git a/src/insets/InsetText.cpp b/src/insets/InsetText.cpp
index 1767f2c..c67e934 100644
--- a/src/insets/InsetText.cpp
+++ b/src/insets/InsetText.cpp
@@ -1040,6 +1040,10 @@ bool InsetText::insetAllowed(InsetCode code) const
 	case QUOTE_CODE:
 	case COUNTER_CODE:
 		return true;
+	// These are only allowed in index insets
+	case INDEXMACRO_CODE:
+	case INDEXMACRO_SORTKEY_CODE:
+		return false;
 	default:
 		return !isPassThru();
 	}
diff --git a/src/tex2lyx/Parser.cpp b/src/tex2lyx/Parser.cpp
index e4eb9b4..2cfac87 100644
--- a/src/tex2lyx/Parser.cpp
+++ b/src/tex2lyx/Parser.cpp
@@ -486,7 +486,40 @@ bool Parser::hasOpt(string const & l)
 }
 
 
-Parser::Arg Parser::getFullArg(char left, char right, bool allow_escaping)
+bool Parser::hasIdxMacros(string const & c, string const & e)
+{
+	// Check for index entry separator (! or @),
+	// consider escaping via "
+	// \p e marks a terminating delimiter¸
+
+	// remember current position
+	unsigned int oldpos = pos_;
+	// skip spaces and comments
+	bool retval = false;
+	while (good()) {
+		get_token();
+		if (isParagraph()) {
+			putback();
+			break;
+		}
+		if (curr_token().cat() == catEnd)
+			break;
+		if (!e.empty() && curr_token().asInput() == e
+		    && prev_token().asInput() != "\"")
+			break;
+		if (curr_token().asInput() == c
+		    && prev_token().asInput() != "\"") {
+			retval = true;
+			break;
+		}
+		continue;
+	}
+	pos_ = oldpos;
+	return retval;
+}
+
+
+Parser::Arg Parser::getFullArg(char left, char right, bool allow_escaping, char e)
 {
 	skip_spaces(true);
 
@@ -495,25 +528,28 @@ Parser::Arg Parser::getFullArg(char left, char right, bool allow_escaping)
 	if (! good())
 		return make_pair(false, string());
 
-	int group_level = 0;
+	int group_level = (left == '{') ? 1 : 0;
 	string result;
 	Token t = get_token();
 
-	if (t.cat() == catComment || t.cat() == catEscape ||
-	    t.character() != left) {
+	if (left != char()
+	    && (t.cat() == catComment || t.cat() == catEscape
+		|| t.character() != left)) {
 		putback();
 		return make_pair(false, string());
 	} else {
 		while (good()) {
 			t = get_token();
 			// honor grouping
-			if (left != '{' && t.cat() == catBegin) {
+			if (t.cat() == catBegin) {
 				++group_level;
-				continue;
+				if (left != '{')
+					continue;
 			}
-			if (left != '{' && t.cat() == catEnd) {
+			if (group_level > 0 && t.cat() == catEnd) {
 				--group_level;
-				continue;
+				if (left != '{')
+					continue;
 			}
 			// Ignore comments
 			if (t.cat() == catComment) {
@@ -525,6 +561,10 @@ Parser::Arg Parser::getFullArg(char left, char right, bool allow_escaping)
 				if (t.cat() != catEscape && t.character() == right
 				    && group_level == 0)
 					break;
+			} else if (e != char()) {
+				if (prev_token().character() != e && t.character() == right
+				    && group_level == 0)
+					break;
 			} else {
 				if (t.character() == right) {
 					if (t.cat() == catEscape)
@@ -540,9 +580,9 @@ Parser::Arg Parser::getFullArg(char left, char right, bool allow_escaping)
 }
 
 
-string Parser::getArg(char left, char right, bool allow_escaping)
+string Parser::getArg(char left, char right, bool allow_escaping, char e)
 {
-	return getFullArg(left, right, allow_escaping).second;
+	return getFullArg(left, right, allow_escaping, e).second;
 }
 
 
diff --git a/src/tex2lyx/Parser.h b/src/tex2lyx/Parser.h
index a99b40f..ec2fc3c 100644
--- a/src/tex2lyx/Parser.h
+++ b/src/tex2lyx/Parser.h
@@ -215,17 +215,22 @@ public:
 
 	/// Does an optional argument follow after the current token?
 	bool hasOpt(std::string const & l = "[");
+	/// Does this index entry has levels?
+	bool hasIdxMacros(std::string const & c,
+			  std::string const & e = std::string());
 	///
 	typedef std::pair<bool, std::string> Arg;
 	/*!
 	 * Get an argument enclosed by \p left and \p right.
 	 * If \p allow_escaping is true, a right delimiter escaped by a
 	 * backslash does not count as delimiter, but is included in the
-	 * argument.
+	 * argument. The \p e allows for a different escape character
+	 * (used in index insets)
 	 * \returns whether an argument was found in \p Arg.first and the
 	 * argument in \p Arg.second. \see getArg().
 	 */
-	Arg getFullArg(char left, char right, bool allow_escaping = true);
+	Arg getFullArg(char left, char right, bool allow_escaping = true,
+		       char e = char());
 	/*!
 	 * Get an argument enclosed by \p left and \p right.
 	 * If \p allow_escaping is true, a right delimiter escaped by a
@@ -236,7 +241,8 @@ public:
 	 * getFullArg() if you need to know whether there was an empty
 	 * argument or no argument at all.
 	 */
-	std::string getArg(char left, char right, bool allow_escaping = true);
+	std::string getArg(char left, char right, bool allow_escaping = true,
+			   char e = char());
 	/*!
 	 * Like getOpt(), but distinguishes between a missing argument ""
 	 * and an empty argument "[]".
diff --git a/src/tex2lyx/tex2lyx.h b/src/tex2lyx/tex2lyx.h
index f720cf1..4152911 100644
--- a/src/tex2lyx/tex2lyx.h
+++ b/src/tex2lyx/tex2lyx.h
@@ -48,7 +48,8 @@ extern std::string rgbcolor2code(std::string const & name);
 std::string translate_len(std::string const &);
 
 void parse_text(Parser & p, std::ostream & os, unsigned flags, bool outer,
-		Context & context, std::string const & rdelim = "");
+		Context & context, std::string const & rdelim = "",
+		std::string const & rdelimesc = "");
 void check_comment_bib(std::ostream & os, Context & context);
 
 void fix_child_filename(std::string & name);
@@ -68,7 +69,8 @@ std::string find_file(std::string const & name, std::string const & path,
 void parse_text_in_inset(Parser & p, std::ostream & os, unsigned flags,
                          bool outer, Context & context,
                          InsetLayout const * layout = nullptr,
-                         std::string const & rdelim = "");
+                         std::string const & rdelim = "",
+			 std::string const & rdelimesc = "");
 
 /// Guess document language from \p p if CJK is used.
 /// \p lang is used for all non-CJK contents.
diff --git a/src/tex2lyx/text.cpp b/src/tex2lyx/text.cpp
index 545515f..b661e6f 100644
--- a/src/tex2lyx/text.cpp
+++ b/src/tex2lyx/text.cpp
@@ -55,7 +55,7 @@ void output_arguments(ostream &, Parser &, bool, bool, const string &, Context &
 
 void parse_text_in_inset(Parser & p, ostream & os, unsigned flags, bool outer,
 		Context & context, InsetLayout const * layout,
-		string const & rdelim)
+		string const & rdelim, string const & rdelimesc)
 {
 	bool const forcePlainLayout =
 		layout ? layout->forcePlainLayout() : false;
@@ -78,7 +78,7 @@ void parse_text_in_inset(Parser & p, ostream & os, unsigned flags, bool outer,
 		parse_text(p, oss, FLAG_RDELIM, outer, dummy,
 			   string(1, context.latexparam.back()));
 	}
-	parse_text(p, os, flags, outer, newcontext, rdelim);
+	parse_text(p, os, flags, outer, newcontext, rdelim, rdelimesc);
 	if (layout)
 		output_arguments(os, p, outer, false, "post", newcontext,
 		                 layout->postcommandargs());
@@ -91,7 +91,8 @@ namespace {
 
 void parse_text_in_inset(Parser & p, ostream & os, unsigned flags, bool outer,
 		Context const & context, string const & name,
-		string const & rdelim = string())
+		string const & rdelim = string(),
+		string const & rdelimesc = string())
 {
 	InsetLayout const * layout = 0;
 	DocumentClass::InsetLayouts::const_iterator it =
@@ -99,17 +100,18 @@ void parse_text_in_inset(Parser & p, ostream & os, unsigned flags, bool outer,
 	if (it != context.textclass.insetLayouts().end())
 		layout = &(it->second);
 	Context newcontext = context;
-	parse_text_in_inset(p, os, flags, outer, newcontext, layout, rdelim);
+	parse_text_in_inset(p, os, flags, outer, newcontext, layout, rdelim, rdelimesc);
 }
 
 /// parses a paragraph snippet, useful for example for \\emph{...}
 void parse_text_snippet(Parser & p, ostream & os, unsigned flags, bool outer,
-		Context & context)
+			Context & context, string const & rdelim = string(),
+			string const & rdelimesc = string())
 {
 	Context newcontext(context);
 	// Don't inherit the paragraph-level extra stuff
 	newcontext.par_extra_stuff.clear();
-	parse_text(p, os, flags, outer, newcontext);
+	parse_text(p, os, flags, outer, newcontext, rdelim, rdelimesc);
 	// Make sure that we don't create invalid .lyx files
 	context.need_layout = newcontext.need_layout;
 	context.need_end_layout = newcontext.need_end_layout;
@@ -1506,6 +1508,218 @@ void parse_outer_box(Parser & p, ostream & os, unsigned flags, bool outer,
 }
 
 
+void parse_index_entry(Parser & p, ostream & os, Context & context, string const & kind)
+{
+	// write inset header
+	begin_inset(os, "Index ");
+	os << kind;
+
+	// Parse for post argument (|...)
+	p.pushPosition();
+	string const marg = p.getArg('{', '}');
+	p.popPosition();
+	char lc = char();
+	bool inpost = false;
+	bool startrange = false;
+	bool endrange = false;
+	string post;
+	for (string::const_iterator it = marg.begin(), et = marg.end(); it != et; ++it) {
+		char c = *it;
+		if (inpost) {
+			if (post.empty() && c == '(')
+				startrange = true;
+			else if (post.empty() && c == ')')
+				endrange = true;
+			else
+				post += c;
+		}
+		if (!inpost && (c == '|' && lc != '"'))
+			inpost = true;
+		lc = c;
+	}
+	if (startrange)
+		os << "\nrange start";
+	else if (endrange)
+		os << "\nrange end";
+	else
+		os << "\nrange none";
+	bool const see = prefixIs(post, "see{");
+	bool const seealso = prefixIs(post, "seealso{");
+	if (!post.empty() && !see && !seealso)
+		os << "\npageformat " << post;
+	else
+		os << "\npageformat default";
+	os << "\nstatus collapsed\n";
+
+	bool main = true;
+	// save position
+	p.pushPosition();
+	// Check for levels
+	if (p.hasIdxMacros("!")) {
+		// Index entry with levels
+		while (p.hasIdxMacros("!")) {
+			if (main) {
+				// swallow brace
+				p.get_token();
+				os << "\\begin_layout Plain Layout\n";
+			} else {
+				begin_inset(os, "IndexMacro subindex");
+				os << "\nstatus collapsed\n";
+			}
+			// Check for (level-specific) sortkey
+			if (p.hasIdxMacros("@", "!")) {
+				if (!main)
+					os << "\\begin_layout Plain Layout\n";
+				begin_inset(os, "IndexMacro sortkey");
+				os << "\nstatus collapsed\n";
+				parse_text_in_inset(p, os, FLAG_RDELIM, false, context, "IndexMacro sortkey", "@", "\"");
+				end_inset(os);
+			}
+			parse_text_snippet(p, os, FLAG_RDELIM, false, context, "!", "\"");
+			if (!main) {
+				os << "\n\\end_layout\n";
+				end_inset(os);
+			}
+			main = false;
+		}
+		if (!main) {
+			begin_inset(os, "IndexMacro subindex");
+			os << "\nstatus collapsed\n";
+		}
+		// Final level
+		// Check for (level-specific) sortkey
+		if (p.hasIdxMacros("@", "!")) {
+			if (main) {
+				// swallow brace
+				p.get_token();
+			}
+			os << "\\begin_layout Plain Layout\n";
+			begin_inset(os, "IndexMacro sortkey");
+			os << "\nstatus collapsed\n";
+			parse_text_in_inset(p, os, FLAG_RDELIM, false, context, "IndexMacro sortkey", "@", "\"");
+			end_inset(os);
+			if (post.empty() && !startrange && !endrange) {
+				parse_text_snippet(p, os, FLAG_BRACE_LAST, false, context);
+				p.dropPosition();
+			} else {
+				// Handle post-argument
+				parse_text_snippet(p, os, FLAG_RDELIM, false, context, "|", "\"");
+				if (see || seealso) {
+					while (p.next_token().character() != '{' && p.good())
+						p.get_token();
+					// this ends the subinset, as the see[also] insets
+					// must come at main index inset
+					os << "\n\\end_layout\n";
+					end_inset(os);
+					if (see)
+						begin_inset(os, "IndexMacro see");
+					else
+						begin_inset(os, "IndexMacro seealso");
+					os << "\nstatus collapsed\n";
+					os << "\\begin_layout Plain Layout\n";
+					parse_text_snippet(p, os, FLAG_ITEM, false, context);
+				}
+				p.popPosition();
+				// swallow argument
+				p.getArg('{', '}');
+			}
+			os << "\n\\end_layout\n";
+		} else {
+			if (post.empty() && !startrange && !endrange) {
+				parse_text_in_inset(p, os, FLAG_BRACE_LAST, false, context, "IndexMacro subindex");
+				p.dropPosition();
+			} else {
+				// Handle post-argument
+				if (see || seealso) {
+					os << "\\begin_layout Plain Layout\n";
+					parse_text_snippet(p, os, FLAG_RDELIM, false, context, "|", "\"");
+					while (p.next_token().character() != '{' && p.good())
+						p.get_token();
+					// this ends the subinset, as the see[also] insets
+					// must come at main index inset
+					os << "\n\\end_layout\n";
+					end_inset(os);
+					if (see)
+						begin_inset(os, "IndexMacro see");
+					else
+						begin_inset(os, "IndexMacro seealso");
+					os << "\nstatus collapsed\n";
+					parse_text_in_inset(p, os, FLAG_ITEM, false, context, "IndexMacro see");
+				} else
+					parse_text_in_inset(p, os, FLAG_RDELIM, false, context, "Index", "|", "\"");
+				p.popPosition();
+				// swallow argument
+				p.getArg('{', '}');
+			}
+		}
+		if (!main)
+			end_inset(os);
+		os << "\n\\end_layout\n";
+	} else {
+		// Index without any levels
+		// Check for sortkey
+		if (p.hasIdxMacros("@", "!")) {
+			// swallow brace
+			p.get_token();
+			os << "\\begin_layout Plain Layout\n";
+			begin_inset(os, "IndexMacro sortkey");
+			os << "\nstatus collapsed\n";
+			parse_text_in_inset(p, os, FLAG_RDELIM, false, context, "IndexMacro sortkey", "@", "\"");
+			end_inset(os);
+			if (post.empty() && !startrange && !endrange) {
+				parse_text_snippet(p, os, FLAG_BRACE_LAST, false, context);
+				p.dropPosition();
+			} else {
+				parse_text_snippet(p, os, FLAG_RDELIM, false, context, "|", "\"");
+				if (see || seealso) {
+					while (p.next_token().character() != '{' && p.good())
+						p.get_token();
+					if (see)
+						begin_inset(os, "IndexMacro see");
+					else
+						begin_inset(os, "IndexMacro seealso");
+					os << "\nstatus collapsed\n";
+					parse_text_in_inset(p, os, FLAG_ITEM, false, context, "IndexMacro see");
+					end_inset(os);
+				}
+				p.popPosition();
+				// swallow argument
+				p.getArg('{', '}');
+			}
+			os << "\n\\end_layout\n";
+		} else {
+			if (post.empty() && !startrange && !endrange) {
+				parse_text_in_inset(p, os, FLAG_ITEM, false, context, "Index");
+				p.dropPosition();
+			} else {
+				// Handle post-argument
+				// swallow brace
+				p.get_token();
+				if (see || seealso) {
+					os << "\\begin_layout Plain Layout\n";
+					parse_text_snippet(p, os, FLAG_RDELIM, false, context, "|", "\"");
+					while (p.next_token().character() != '{' && p.good())
+						p.get_token();
+					if (see)
+						begin_inset(os, "IndexMacro see");
+					else
+						begin_inset(os, "IndexMacro seealso");
+					os << "\nstatus collapsed\n";
+					parse_text_in_inset(p, os, FLAG_ITEM, false, context, "IndexMacro see");
+					end_inset(os);
+					os << "\n\\end_layout\n";
+				} else
+					parse_text_in_inset(p, os, FLAG_RDELIM, false, context, "Index", "|", "\"");
+				p.popPosition();
+				// swallow argument
+				p.getArg('{', '}');
+			}
+		}
+	}
+	end_inset(os);
+}
+
+
 void parse_listings(Parser & p, ostream & os, Context & parent_context,
 		    bool in_line, bool use_minted)
 {
@@ -2901,7 +3115,7 @@ void fix_child_filename(string & name)
 
 
 void parse_text(Parser & p, ostream & os, unsigned flags, bool outer,
-		Context & context, string const & rdelim)
+		Context & context, string const & rdelim, string const & rdelimesc)
 {
 	Layout const * newlayout = 0;
 	InsetLayout const * newinsetlayout = 0;
@@ -2990,7 +3204,8 @@ void parse_text(Parser & p, ostream & os, unsigned flags, bool outer,
 		if (rdelim.size() > 1)
 			tok += p.next_token().asInput();
 		if (t.cat() != catEscape && !rdelim.empty()
-		    && tok == rdelim && (flags & FLAG_RDELIM)) {
+		    && tok == rdelim && (flags & FLAG_RDELIM)
+		    && (rdelimesc.empty() || p.prev_token().asInput() != rdelimesc)) {
 		    	if (rdelim.size() > 1)
 		    		p.get_token(); // eat rdelim
 			return;
@@ -4712,10 +4927,7 @@ void parse_text(Parser & p, ostream & os, unsigned flags, bool outer,
 			string const arg = (t.cs() == "sindex" && p.hasOpt()) ?
 				p.getArg('[', ']') : "";
 			string const kind = arg.empty() ? "idx" : arg;
-			begin_inset(os, "Index ");
-			os << kind << "\nstatus collapsed\n";
-			parse_text_in_inset(p, os, FLAG_ITEM, false, context, "Index");
-			end_inset(os);
+			parse_index_entry(p, os, context, kind);
 			if (kind != "idx")
 				preamble.registerAutomaticallyLoadedPackage("splitidx");
 			continue;

commit 50403c4ecf08e50069ce48d794cc75b7490a2281
Author: Jean-Marc Lasgouttes <lasgouttes at lyx.org>
Date:   Mon Apr 18 18:13:17 2022 +0200

    Improve selection when selecting out of inset by the left
    
    1/ put cusror in some display inset
    2/ use shift-left until the cursor exits the inset
    3/ see how the selection extends on the right.
    
    This is not really a selection drawing bug, but rather the fact that
    the anchor will be normalized to the first position after the inset,
    which is in the next row.
    
    This can be avoided by using the boundary property.
    
    See discussion in bug #12520.

diff --git a/src/Cursor.cpp b/src/Cursor.cpp
index d2190e7..ce02812 100644
--- a/src/Cursor.cpp
+++ b/src/Cursor.cpp
@@ -322,6 +322,7 @@ DocIterator CursorData::selectionEnd() const
 	if (di.depth() > depth()) {
 		di.resize(depth());
 		++di.pos();
+		di.boundary(true);
 	}
 	return di;
 }

commit 335f158896c067caa138fa7bcf9a9b38fcca1e35
Author: Pavel Sanda <sanda at lyx.org>
Date:   Sun Apr 17 00:49:35 2022 +0200

    * RELEASE-NOTES

diff --git a/lib/RELEASE-NOTES b/lib/RELEASE-NOTES
index 97c740c..344e6b1 100644
--- a/lib/RELEASE-NOTES
+++ b/lib/RELEASE-NOTES
@@ -146,6 +146,8 @@
 * tabular-feature: added toggle parameters "toggle-all-lines", "toggle-border-lines"
   and "toggle-inner-lines"
 
+* branch-sync-all: Open/close all insets of selected branch (depending on its activation status).
+
 
 !!!The following LyX functions have been removed in 2.4:
 
diff --git a/src/LyXAction.cpp b/src/LyXAction.cpp
index f232e51..559d950 100644
--- a/src/LyXAction.cpp
+++ b/src/LyXAction.cpp
@@ -454,7 +454,7 @@ void LyXAction::init()
 
 /*!
  * \var lyx::FuncCode lyx::LFUN_BRANCH_SYNC_ALL
- * \li Action: Open/close all insets of selected branch (depending on its selection status).
+ * \li Action: Open/close all insets of selected branch (depending on its activation status).
  * \li Syntax: branch-sync-all
  * \li Origin: sanda, 15 April 2022
  * \endvar

commit a4f5f245f8245976ca4a0fdda4a43b96a159754c
Author: Pavel Sanda <sanda at lyx.org>
Date:   Sun Apr 17 00:38:17 2022 +0200

    forgotten bit

diff --git a/src/LyXAction.cpp b/src/LyXAction.cpp
index c88c1b9..f232e51 100644
--- a/src/LyXAction.cpp
+++ b/src/LyXAction.cpp
@@ -455,7 +455,7 @@ void LyXAction::init()
 /*!
  * \var lyx::FuncCode lyx::LFUN_BRANCH_SYNC_ALL
  * \li Action: Open/close all insets of selected branch (depending on its selection status).
- * \li Syntax: branch-toggle-all
+ * \li Syntax: branch-sync-all
  * \li Origin: sanda, 15 April 2022
  * \endvar
  */

commit 5ba4d54b6303db27182f7ab1b7a0337f98546af2
Author: Pavel Sanda <sanda at lyx.org>
Date:   Sun Apr 17 00:37:22 2022 +0200

    *doc - branch-sync-all

diff --git a/lib/doc/UserGuide.lyx b/lib/doc/UserGuide.lyx
index 4cf4ce5..30a6ad3 100644
--- a/lib/doc/UserGuide.lyx
+++ b/lib/doc/UserGuide.lyx
@@ -8973,12 +8973,14 @@ Verbatim
 \end_layout
 
 \begin_layout Verbatim
+
 This is Verbatim.
 \end_layout
 
 \begin_layout Verbatim
 \noindent
 \align block
+
 The following 2 lines are empty:
 \end_layout
 
@@ -8991,6 +8993,7 @@ The following 2 lines are empty:
 \end_layout
 
 \begin_layout Verbatim
+
 Almost everything is allowed in Verbatim:"%&$§#~'`
 \backslash
 }][{|
@@ -9014,6 +9017,7 @@ Verbatim
 \end_layout
 
 \begin_layout Verbatim*
+
 This is Verbatim*.
 \end_layout
 
@@ -35518,8 +35522,19 @@ Exam-Question-Answer.pdf
 \end_layout
 
 \begin_layout Standard
-There are also inverted branch insets, whose content is output just in case
- the branch is 
+
+\change_inserted 5863208 1650147989
+It is also possible to 
+\change_deleted 5863208 1650147965
+There are also 
+\change_unchanged
+invert
+\change_deleted 5863208 1650147967
+ed
+\change_inserted 5863208 1650147977
+ just some
+\change_unchanged
+ branch insets, whose content is output just in case the branch is 
 \emph on
 not
 \emph default
@@ -35787,6 +35802,23 @@ Customization
 Flex insets and InsetLayout
 \emph default
 ).
+\change_inserted 5863208 1650148012
+
+\end_layout
+
+\begin_layout Standard
+
+\change_inserted 5863208 1650148601
+In case one extensively needs syncing activation branch status with open/close
+ status of all branch insets in the document we provide 
+\family typewriter
+branch-sync-all
+\family default
+ \SpecialChar LyX
+ function, which can be bound to keyboard shortcut or added to user-defined
+ context menu of branch inset.
+\change_unchanged
+
 \end_layout
 
 \begin_layout Section

commit 02ffd6dd70be2a376b5d09b55099aa75338a2889
Author: Pavel Sanda <sanda at lyx.org>
Date:   Sun Apr 17 00:16:19 2022 +0200

    Allow syncing open/close status of branch inset with it's activation status.
    
    This was kicked out by 742b39f4 (the code in inset toggle survived).
    https://www.mail-archive.com/lyx-devel@lists.lyx.org/msg217311.html

diff --git a/src/FuncCode.h b/src/FuncCode.h
index 20231eb..8337c1f 100644
--- a/src/FuncCode.h
+++ b/src/FuncCode.h
@@ -502,6 +502,7 @@ enum FuncCode
 	LFUN_SPELLING_REMOVE_LOCAL,     // jspitzm 20210307
 	LFUN_FINISHED_DOWN,             // lasgouttes 20210629
 	LFUN_FINISHED_UP,               // lasgouttes 20210629
+	LFUN_BRANCH_SYNC_ALL,           // sanda 20220415
 	LFUN_LASTACTION                 // end of the table
 };
 
diff --git a/src/LyXAction.cpp b/src/LyXAction.cpp
index ea60f53..c88c1b9 100644
--- a/src/LyXAction.cpp
+++ b/src/LyXAction.cpp
@@ -453,6 +453,15 @@ void LyXAction::init()
 		{ LFUN_BRANCH_INSERT, "branch-insert", Noop, Edit },
 
 /*!
+ * \var lyx::FuncCode lyx::LFUN_BRANCH_SYNC_ALL
+ * \li Action: Open/close all insets of selected branch (depending on its selection status).
+ * \li Syntax: branch-toggle-all
+ * \li Origin: sanda, 15 April 2022
+ * \endvar
+ */
+		{ LFUN_BRANCH_SYNC_ALL, "branch-sync-all", AtPoint, Buffer },
+
+/*!
  * \var lyx::FuncCode lyx::LFUN_BRANCH_INVERT
  * \li Action: Toggles inversion status of branch inset.
  * \li Syntax: branch-invert
diff --git a/src/insets/InsetBranch.cpp b/src/insets/InsetBranch.cpp
index 7a102ce..a30930a 100644
--- a/src/insets/InsetBranch.cpp
+++ b/src/insets/InsetBranch.cpp
@@ -224,9 +224,12 @@ void InsetBranch::doDispatch(Cursor & cur, FuncRequest & cmd)
 	case LFUN_BRANCH_ADD:
 		lyx::dispatch(FuncRequest(LFUN_BRANCH_ADD, params_.branch));
 		break;
+	case LFUN_BRANCH_SYNC_ALL:
+		lyx::dispatch(FuncRequest(LFUN_INSET_FORALL, "Branch:" + params_.branch + " inset-toggle assign"));
+		break;
 	case LFUN_INSET_TOGGLE:
 		if (cmd.argument() == "assign")
-			setStatus(cur, isBranchSelected() ? Open : Collapsed);
+			setStatus(cur, (isBranchSelected(true) != params_.inverted) ? Open : Collapsed);
 		else
 			InsetCollapsible::doDispatch(cur, cmd);
 		break;
@@ -276,6 +279,10 @@ bool InsetBranch::getStatus(Cursor & cur, FuncRequest const & cmd,
 		flag.setEnabled(buffer().parent() && isBranchSelected());
 		break;
 
+	case LFUN_BRANCH_SYNC_ALL:
+		flag.setEnabled(known_branch);
+		break;
+
 	case LFUN_INSET_TOGGLE:
 		if (cmd.argument() == "assign")
 			flag.setEnabled(true);

commit 28b206665fb7a90d0998f927cec003fcef9c573e
Author: Kornel Benko <kornel at lyx.org>
Date:   Sat Apr 16 15:10:33 2022 +0200

    FindAdv: Convert '\%' in a regex to '%'
    
    Regex contents comes from handling hullRegexp, so we
    have to reverse some its handling, among others also for the char '%'

diff --git a/src/lyxfind.cpp b/src/lyxfind.cpp
index 015e437..2ea1e88 100644
--- a/src/lyxfind.cpp
+++ b/src/lyxfind.cpp
@@ -838,7 +838,7 @@ string correctRegex(string t, bool withformat)
 	 * and \{, \}, \[, \] => {, }, [, ]
 	 */
 	string s("");
-	regex wordre("(\\\\)*(\\\\(([A-Za-z]+|[\\{\\}])( |\\{\\})?|[\\[\\]\\{\\}]))");
+	regex wordre("(\\\\)*(\\\\(([A-Za-z]+|[\\{\\}%])( |\\{\\})?|[\\[\\]\\{\\}]))");
 	size_t lastpos = 0;
 	smatch sub;
 	bool backslashed = false;
@@ -893,6 +893,8 @@ string correctRegex(string t, bool withformat)
 				replace = "{";
 			else if (sub.str(4) == "}")
 				replace = "}";
+			else if (sub.str(4) == "%")
+				replace = "%";
 			else {
 				AccentsIterator it_ac = accents.find(sub.str(4));
 				if (it_ac == accents.end()) {

commit 965b2cdc73ffa8e3c3d842bd1b3cb3c148118db6
Author: Kornel Benko <kornel at lyx.org>
Date:   Fri Apr 15 17:18:40 2022 +0200

    Findadv: Correct findadv-combined test
    
    Replaced some 'CP' commands with 'CN' comments.

diff --git a/development/autotests/findadv-combined-in.txt b/development/autotests/findadv-combined-in.txt
index c273a13..bbcb14d 100644
--- a/development/autotests/findadv-combined-in.txt
+++ b/development/autotests/findadv-combined-in.txt
@@ -65,7 +65,7 @@ CP: Putting selection at .*idx: 0 par: 2 pos: 8\n with len: 1
 #
 CN: Part 007
 KK: \C\[F21]\C\[F20]\\[\[Return]
-CP: Escaped : '\['
+CN: Escaped : '\['
 CP: Putting selection at .*idx: 0 par: 3 pos: 3\n with len: 1
 #
 CN: Part 008
@@ -108,47 +108,47 @@ CP: Putting selection at .*idx: 0 par: 0 pos: 3\n with len: 1
 #
 CN: Part 102
 KK: \C\[F21]\C\[F20]\\(\[Return]
-CP: Escaped : '\('
+CN: Escaped : '\('
 CP: Putting selection at .*idx: 0 par: 1 pos: 1\n with len: 1
 #
 CN: Part 103
 KK: \C\[F21]\C\[F20]\\)\[Return]
-CP: Escaped : '\)'
+CN: Escaped : '\)'
 CP: Putting selection at .*idx: 0 par: 1 pos: 2\n with len: 1
 #
 CN: Part 104
 KK: \C\[F21]\C\[F20]\\\\\[Return]
-CP: Escaped : '\\'
+CN: Escaped : '\\'
 CP: Putting selection at .*idx: 0 par: 2 pos: 0\n with len: 1
 #
 CN: Part 105
 KK: \C\[F21]\C\[F20]%\[Return]
-CP: Escaped : '%'
+CN: Escaped : '%'
 CP: Putting selection at .*idx: 0 par: 2 pos: 7\n with len: 1
 #
 CN: Part 105
 KK: \C\[F21]\C\[F20]\\^\[Return]
-CP: Escaped : '\^'
+CN: Escaped : '\^'
 CP: Putting selection at .*idx: 0 par: 2 pos: 8\n with len: 1
 #
 CN: Part 106
 KK: \C\[F21]\C\[F20]\\{\[Return]
-CP: Escaping: '\backslash\{'
+CN: Escaping: '\backslash\{'
 CP: Putting selection at .*idx: 0 par: 3 pos: 5\n with len: 1
 #
 CN: Part 107
 KK: \C\[F21]\C\[F20]\\}\[Return]
-CP: Escaping: '\backslash\}'
+CN: Escaping: '\backslash\}'
 CP: Putting selection at .*idx: 0 par: 3 pos: 6\n with len: 1
 #
 CN: Part 108
 KK: \C\[F21]\C\[F20]\\]\[Return]
-CP: Escaped : '\]'
+CN: Escaped : '\]'
 CP: Putting selection at .*idx: 0 par: 4 pos: 4\n with len: 1
 #
 CN: Part 109
 KK: \C\[F21]\C\[F20]\\@\[Return]
-CP: Escaped : '\@'
+CN: Escaped : '\@'
 CP: Putting selection at .*idx: 0 par: 4 pos: 10\n with len: 1
 
 #

commit 45756a50b4e47c3fe182e77f8e976011db7cc070
Author: Kornel Benko <kornel at lyx.org>
Date:   Fri Apr 15 17:09:08 2022 +0200

    FindAdv: Handling of '%' in searched string while not ignoring format
    
    Difficult to decide, when to remove the sequence '%\n'.
    The sequence is OK for latex output as a command separator,
    but must be removed in searched string.
    
    Alas, not all occurences are wrong. Sigh.

diff --git a/src/lyxfind.cpp b/src/lyxfind.cpp
index 6ef7cd3..015e437 100644
--- a/src/lyxfind.cpp
+++ b/src/lyxfind.cpp
@@ -3878,14 +3878,9 @@ string MatchStringAdv::normalize(docstring const & s, bool ignore_format) const
 	// Remove \n at begin
 	while (!t.empty() && t[0] == '\n')
 		t = t.substr(1);
-	// Remove [%]*\n at end
+	// Remove \n* at end
 	while (!t.empty() && t[t.size() - 1] == '\n') {
-		size_t count = 1;
-		if (!ignore_format) {
-			while ((t.size() > 1 + count) && (t[t.size() - 1 - count] == '%'))
-				count++;
-		}
-		t = t.substr(0, t.size() - count);
+		t = t.substr(0, t.size() - 1);
 	}
 	size_t pos;
 	// Handle all other '\n'

commit 18a1207c2d1c9cf3716bcda93281f8da5f345bc1
Author: Juergen Spitzmueller <spitz at lyx.org>
Date:   Thu Apr 14 10:27:10 2022 +0200

    de.po

diff --git a/po/de.gmo b/po/de.gmo
index df61191..cd9723d 100644
Binary files a/po/de.gmo and b/po/de.gmo differ
diff --git a/po/de.po b/po/de.po
index 43362d9..44e5e09 100644
--- a/po/de.po
+++ b/po/de.po
@@ -94,15 +94,15 @@ msgid ""
 msgstr ""
 "Project-Id-Version: LyX 2.4git\n"
 "Report-Msgid-Bugs-To: lyx-devel at lists.lyx.org\n"
-"POT-Creation-Date: 2022-02-19 14:24+0100\n"
-"PO-Revision-Date: 2022-02-19 14:31+0100\n"
+"POT-Creation-Date: 2022-04-14 10:20+0200\n"
+"PO-Revision-Date: 2022-04-14 10:26+0200\n"
 "Last-Translator: Jürgen Spitzmüller <spitz at lyx.org>\n"
 "Language-Team: Deutsch <lyx-docs at lists.lyx.org>\n"
 "Language: de\n"
 "MIME-Version: 1.0\n"
 "Content-Type: text/plain; charset=UTF-8\n"
 "Content-Transfer-Encoding: 8bit\n"
-"X-Generator: Gtranslator 40.0\n"
+"X-Generator: Gtranslator 41.0\n"
 "Plural-Forms: nplurals=2; plural=n != 1;\n"
 
 #: src/frontends/qt/ui/AboutUi.ui:27
@@ -3711,10 +3711,10 @@ msgstr "Doppelt"
 #: src/frontends/qt/GuiHSpace.cpp:57 src/frontends/qt/GuiPrefs.cpp:816
 #: src/frontends/qt/GuiPrefs.cpp:844 src/frontends/qt/GuiPrefs.cpp:871
 #: src/frontends/qt/GuiPrefs.cpp:2329 src/frontends/qt/GuiPrefs.cpp:2352
-#: src/frontends/qt/GuiPrintNomencl.cpp:51 src/insets/InsetInfo.cpp:236
-#: src/insets/InsetInfo.cpp:246 src/insets/InsetInfo.cpp:250
-#: src/insets/InsetInfo.cpp:259 src/insets/InsetInfo.cpp:321
-#: src/insets/InsetInfo.cpp:343
+#: src/frontends/qt/GuiPrintNomencl.cpp:51 src/insets/InsetInfo.cpp:237
+#: src/insets/InsetInfo.cpp:247 src/insets/InsetInfo.cpp:251
+#: src/insets/InsetInfo.cpp:260 src/insets/InsetInfo.cpp:322
+#: src/insets/InsetInfo.cpp:344
 msgid "Custom"
 msgstr "Benutzerdefiniert"
 
@@ -4486,7 +4486,7 @@ msgstr "&Aktiv"
 msgid "Ctrl"
 msgstr "Strg-Taste"
 
-#: src/frontends/qt/ui/PrefInputUi.ui:249 src/insets/InsetInfo.cpp:863
+#: src/frontends/qt/ui/PrefInputUi.ui:249 src/insets/InsetInfo.cpp:892
 msgid "Shift"
 msgstr "Umschalttaste"
 
@@ -6387,7 +6387,7 @@ msgid "Footnote"
 msgstr "Fußnote"
 
 #: lib/citeengines/biblatex-natbib.citeengine:144
-#: lib/citeengines/biblatex.citeengine:134
+#: lib/citeengines/biblatex.citeengine:134 lib/layouts/stdinsets.inc:51
 msgid "Foot"
 msgstr "Fußnote"
 
@@ -7432,9 +7432,9 @@ msgstr "IEEE Transactions"
 #: lib/layouts/scrlttr2.layout:19 lib/layouts/siamltex.layout:37
 #: lib/layouts/sigplanconf.layout:41 lib/layouts/simplecv.layout:18
 #: lib/layouts/slides.layout:61 lib/layouts/stdclass.inc:28
-#: lib/layouts/stdinsets.inc:688 lib/layouts/stdletter.inc:12
+#: lib/layouts/stdinsets.inc:689 lib/layouts/stdletter.inc:12
 #: lib/layouts/svcommon.inc:26 lib/layouts/tufte-book.layout:35
-#: src/insets/InsetRef.cpp:597
+#: src/insets/InsetRef.cpp:599
 msgid "Standard"
 msgstr "Standard"
 
@@ -7505,7 +7505,7 @@ msgstr "Kleinschreibung"
 #: lib/layouts/siamltex.layout:222 lib/layouts/sigplanconf.layout:150
 #: lib/layouts/stdtitle.inc:37 lib/layouts/svcommon.inc:370
 #: lib/layouts/svmult.layout:89 lib/layouts/svprobth.layout:93
-#: lib/layouts/tufte-book.layout:55 src/insets/InsetInfo.cpp:283
+#: lib/layouts/tufte-book.layout:55 src/insets/InsetInfo.cpp:284
 msgid "Author"
 msgstr "Autor"
 
@@ -8065,7 +8065,7 @@ msgstr "Unterunterabschnitt"
 #: lib/layouts/scrclass.inc:240 lib/layouts/scrlettr.layout:203
 #: lib/layouts/scrlttr2.layout:322 lib/layouts/siamltex.layout:246
 #: lib/layouts/stdtitle.inc:62 lib/layouts/svcommon.inc:406
-#: lib/layouts/tufte-book.layout:60 src/insets/InsetInfo.cpp:284
+#: lib/layouts/tufte-book.layout:60 src/insets/InsetInfo.cpp:285
 msgid "Date"
 msgstr "Datum"
 
@@ -8513,7 +8513,7 @@ msgstr "American Chemical Society (ACS)"
 #: lib/layouts/scrclass.inc:142 lib/layouts/scrclass.inc:155
 #: lib/layouts/scrclass.inc:168 lib/layouts/scrclass.inc:324
 #: lib/layouts/scrclass.inc:349 lib/layouts/siamltex.layout:206
-#: lib/layouts/simplecv.layout:52 lib/layouts/stdinsets.inc:695
+#: lib/layouts/simplecv.layout:52 lib/layouts/stdinsets.inc:696
 #: lib/layouts/stdsections.inc:32 lib/layouts/stdsections.inc:76
 #: lib/layouts/stdsections.inc:117 lib/layouts/tufte-book.layout:98
 #: lib/layouts/tufte-book.layout:129 lib/layouts/tufte-handout.layout:40
@@ -9509,7 +9509,7 @@ msgstr "Spezialabschnitt*"
 
 #: lib/layouts/amsart.layout:98 lib/layouts/beamer.layout:336
 #: lib/layouts/beamer.layout:398 lib/layouts/beamer.layout:460
-#: lib/layouts/memoir.layout:248 lib/layouts/stdinsets.inc:713
+#: lib/layouts/memoir.layout:248 lib/layouts/stdinsets.inc:714
 #: lib/layouts/stdstarsections.inc:15 lib/layouts/stdstarsections.inc:30
 #: lib/layouts/stdstarsections.inc:45 lib/layouts/stdstarsections.inc:60
 #: lib/layouts/stdstarsections.inc:75 lib/layouts/stdstarsections.inc:90
@@ -9729,13 +9729,13 @@ msgid "Centered"
 msgstr "Zentriert"
 
 #: lib/layouts/apa.layout:285 lib/layouts/apax.inc:384
-#: lib/layouts/stdinsets.inc:689 src/insets/InsetCaption.cpp:436
+#: lib/layouts/stdinsets.inc:690 src/insets/InsetCaption.cpp:436
 msgid "standard"
 msgstr "Standard"
 
 #: lib/layouts/apa.layout:292 lib/layouts/apax.inc:391
 #: lib/layouts/scrclass.inc:325 lib/layouts/scrclass.inc:350
-#: lib/layouts/stdinsets.inc:696
+#: lib/layouts/stdinsets.inc:697
 msgid "The caption as it appears in the list of figures/tables"
 msgstr "Die Legende, wie sie im Abbildungs-/Tabellenverzeichnis erscheint"
 
@@ -12231,7 +12231,7 @@ msgstr ""
 "Gleichungsnummer die Abschnittsnummer voran, bspw. '(2.1)'."
 
 #: lib/layouts/eqs-within-sections.module:17 lib/layouts/scrbook.layout:29
-#: lib/layouts/stdcounters.inc:81 src/insets/InsetRef.cpp:598
+#: lib/layouts/stdcounters.inc:81 src/insets/InsetRef.cpp:600
 #: src/mathed/InsetMathRef.cpp:372
 msgid "Equation"
 msgstr "Gleichung"
@@ -12538,7 +12538,7 @@ msgid "Size the photo is resized to"
 msgstr "Ausgabegröße des Bildes"
 
 #: lib/layouts/europecv.layout:185 src/frontends/qt/GuiDocument.cpp:136
-#: src/insets/InsetRef.cpp:599
+#: src/insets/InsetRef.cpp:601
 msgid "Page"
 msgstr "Seite"
 
@@ -15786,7 +15786,7 @@ msgstr "CheckBox"
 msgid "ChoiceMenu"
 msgstr "Auswahlmenü"
 
-#: lib/layouts/pdfform.module:90 src/insets/InsetRef.cpp:604
+#: lib/layouts/pdfform.module:90 src/insets/InsetRef.cpp:606
 msgid "Label"
 msgstr "Beschriftung"
 
@@ -17091,10 +17091,6 @@ msgstr "Listing"
 msgid "Margin"
 msgstr "Rand"
 
-#: lib/layouts/stdinsets.inc:51
-msgid "foot"
-msgstr "Fußnote"
-
 #: lib/layouts/stdinsets.inc:177
 msgid "Greyedout"
 msgstr "Grauschrift"
@@ -17125,23 +17121,23 @@ msgstr "Stichwort"
 msgid "Argument"
 msgstr "Argument"
 
-#: lib/layouts/stdinsets.inc:715
+#: lib/layouts/stdinsets.inc:716
 msgid "unlabelled"
 msgstr "ohne Marke"
 
-#: lib/layouts/stdinsets.inc:722
+#: lib/layouts/stdinsets.inc:723
 msgid "Preview"
 msgstr "Vorschau"
 
-#: lib/layouts/stdinsets.inc:756 lib/layouts/stdinsets.inc:764
+#: lib/layouts/stdinsets.inc:757 lib/layouts/stdinsets.inc:765
 msgid "see equation[[nomencl]]"
 msgstr "siehe Gleichung"
 
-#: lib/layouts/stdinsets.inc:757 lib/layouts/stdinsets.inc:765
+#: lib/layouts/stdinsets.inc:758 lib/layouts/stdinsets.inc:766
 msgid "page[[nomencl]]"
 msgstr "Seite"
 
-#: lib/layouts/stdinsets.inc:758 lib/layouts/stdinsets.inc:766
+#: lib/layouts/stdinsets.inc:759 lib/layouts/stdinsets.inc:767
 msgid "Nomenclature[[output]]"
 msgstr "Nomenklatur"
 
@@ -19658,19 +19654,19 @@ msgstr "Als Querverweis kopieren|k"
 
 #: lib/ui/stdcontext.inc:61 lib/ui/stdcontext.inc:375 lib/ui/stdmenus.inc:108
 #: lib/ui/stdtoolbars.inc:86 src/Text3.cpp:1584
-#: src/mathed/InsetMathNest.cpp:555
+#: src/mathed/InsetMathNest.cpp:561
 msgid "Cut"
 msgstr "Ausschneiden"
 
 #: lib/ui/stdcontext.inc:62 lib/ui/stdcontext.inc:376 lib/ui/stdmenus.inc:109
-#: lib/ui/stdtoolbars.inc:87 src/BufferView.cpp:2269
+#: lib/ui/stdtoolbars.inc:87 src/BufferView.cpp:2270
 msgid "Copy"
 msgstr "Kopieren"
 
 #: lib/ui/stdcontext.inc:63 lib/ui/stdcontext.inc:377 lib/ui/stdmenus.inc:110
 #: lib/ui/stdtoolbars.inc:88 src/Text3.cpp:1528
 #: src/frontends/qt/GuiToolbar.cpp:441 src/mathed/InsetMathGrid.cpp:1565
-#: src/mathed/InsetMathNest.cpp:533
+#: src/mathed/InsetMathNest.cpp:539
 msgid "Paste"
 msgstr "Einfügen"
 
@@ -21840,16 +21836,16 @@ msgid "Toggle right line"
 msgstr "Rechte Linie an/aus"
 
 #: lib/ui/stdtoolbars.inc:167
-msgid "Set border lines"
-msgstr "Äußere Linien setzen"
+msgid "Toggle border lines"
+msgstr "Rahmenlinien an/aus"
 
 #: lib/ui/stdtoolbars.inc:168
-msgid "Set all lines"
-msgstr "Alle Linien setzen"
+msgid "Toggle inner lines"
+msgstr "Innere Linien an/aus"
 
 #: lib/ui/stdtoolbars.inc:169
-msgid "Set inner lines"
-msgstr "Innere Linien setzen"
+msgid "Toggle all lines"
+msgstr "Alle Linien an/aus"
 
 #: lib/ui/stdtoolbars.inc:170
 msgid "Unset all lines"
@@ -22046,7 +22042,7 @@ msgstr "Trennzeichen (feste Größe)"
 msgid "Miscellaneous (extended)"
 msgstr "Verschiedenes (erweitert)"
 
-#: lib/ui/stdtoolbars.inc:237 src/TocBackend.cpp:300
+#: lib/ui/stdtoolbars.inc:237 src/TocBackend.cpp:303
 msgid "Math Macros"
 msgstr "Mathe-Makros"
 
@@ -26982,7 +26978,7 @@ msgstr "Beispiel (roh)"
 msgid "Gnuplot"
 msgstr "Gnuplot"
 
-#: lib/examples/Articles:0 src/TocBackend.cpp:299
+#: lib/examples/Articles:0 src/TocBackend.cpp:302
 #: src/frontends/qt/GuiExternal.cpp:86
 msgid "External Material"
 msgstr "Externes Material"
@@ -26992,10 +26988,6 @@ msgid "Feynman Diagrams"
 msgstr "Feynman-Diagramme"
 
 #: lib/examples/Articles:0
-msgid "Instant Preview"
-msgstr "Eingebettete Vorschau"
-
-#: lib/examples/Articles:0
 msgid "Itemize Bullets"
 msgstr "Auflistungszeichen"
 
@@ -27016,6 +27008,10 @@ msgid "XY-Pic"
 msgstr "XY-Pic"
 
 #: lib/examples/Articles:0
+msgid "Instant Preview"
+msgstr "Eingebettete Vorschau"
+
+#: lib/examples/Articles:0
 msgid "Graphics and Insets"
 msgstr "Grafiken und Einfügungen"
 
@@ -27036,14 +27032,6 @@ msgid "Localization Test"
 msgstr "Ãœbersetzungstest"
 
 #: lib/examples/Articles:0
-msgid "Hazard and Precautionary Statements"
-msgstr "H- und P-Sätze"
-
-#: lib/examples/Articles:0
-msgid "LilyPond Book"
-msgstr "LilyPond-Buch"
-
-#: lib/examples/Articles:0
 msgid "Multilingual Captions"
 msgstr "Mehrsprachige Legenden"
 
@@ -27055,6 +27043,14 @@ msgstr "Noweb2LyX"
 msgid "Noweb Listerrors"
 msgstr "Noweb-Fehlerbericht"
 
+#: lib/examples/Articles:0
+msgid "LilyPond Book"
+msgstr "LilyPond-Buch"
+
+#: lib/examples/Articles:0
+msgid "Hazard and Precautionary Statements"
+msgstr "H- und P-Sätze"
+
 #: lib/examples/Articles:0 src/frontends/qt/GuiDocument.cpp:1775
 msgid "Modules"
 msgstr "Module"
@@ -27084,10 +27080,6 @@ msgid "Multilingual Typesetting with platex"
 msgstr "Mehrsprachige Dokumente mit platex"
 
 #: lib/examples/Articles:0
-msgid "Hebrew Article (KOMA-Script)"
-msgstr "Hebräischer Aufsatz (KOMA-Script)"
-
-#: lib/examples/Articles:0
 msgid "IEEE Transactions Conference"
 msgstr "IEEE Transactions Conference"
 
@@ -27104,6 +27096,10 @@ msgid "Springers Global Journal Template (V. 3)"
 msgstr "Springers globale Vorlage für Zeitschriften (V. 3)"
 
 #: lib/examples/Articles:0
+msgid "Hebrew Article (KOMA-Script)"
+msgstr "Hebräischer Aufsatz (KOMA-Script)"
+
+#: lib/examples/Articles:0
 msgid "00 Main File"
 msgstr "00 Hauptdatei"
 
@@ -27542,7 +27538,7 @@ msgstr "iconv-Konvertierung fehlgeschlagen"
 msgid "conversion failed"
 msgstr "Konvertierung fehlgeschlagen"
 
-#: src/Buffer.cpp:1917 src/insets/InsetGraphics.cpp:905
+#: src/Buffer.cpp:1917 src/insets/InsetGraphics.cpp:919
 msgid "Uncodable character in file path"
 msgstr "Unkodierbares Zeichen im Dateipfad"
 
@@ -27647,13 +27643,13 @@ msgid "Error viewing the output file."
 msgstr "Fehler bei der Ansicht der Ausgabedatei."
 
 #: src/Buffer.cpp:3370 src/frontends/qt/GuiView.cpp:2706
-#: src/frontends/qt/Validator.cpp:241 src/insets/ExternalSupport.cpp:394
-#: src/insets/InsetGraphics.cpp:692 src/insets/InsetInclude.cpp:606
+#: src/frontends/qt/Validator.cpp:245 src/insets/ExternalSupport.cpp:394
+#: src/insets/InsetGraphics.cpp:693 src/insets/InsetInclude.cpp:606
 msgid "Invalid filename"
 msgstr "Ungültiger Dateiname"
 
 #: src/Buffer.cpp:3371 src/insets/ExternalSupport.cpp:395
-#: src/insets/InsetGraphics.cpp:693 src/insets/InsetInclude.cpp:607
+#: src/insets/InsetGraphics.cpp:694 src/insets/InsetInclude.cpp:607
 msgid ""
 "The following filename will cause troubles when running the exported file "
 "through LaTeX: "
@@ -27662,12 +27658,12 @@ msgstr ""
 "exportierten Datei ausgeführt wird: "
 
 #: src/Buffer.cpp:3376 src/insets/ExternalSupport.cpp:400
-#: src/insets/InsetGraphics.cpp:700 src/insets/InsetInclude.cpp:611
+#: src/insets/InsetGraphics.cpp:701 src/insets/InsetInclude.cpp:611
 msgid "Problematic filename for DVI"
 msgstr "Problematischer Dateiname für DVI"
 
 #: src/Buffer.cpp:3377 src/insets/ExternalSupport.cpp:401
-#: src/insets/InsetGraphics.cpp:701 src/insets/InsetInclude.cpp:612
+#: src/insets/InsetGraphics.cpp:702 src/insets/InsetInclude.cpp:612
 msgid ""
 "The following filename can cause troubles when running the exported file "
 "through LaTeX and opening the resulting DVI: "
@@ -27900,16 +27896,16 @@ msgstr ""
 "%1$s ist schreibgeschützt.\n"
 "Bitte speichern Sie die Datei unter einem neuen Namen."
 
-#: src/Buffer.cpp:5206 src/insets/InsetCaption.cpp:404
+#: src/Buffer.cpp:5213 src/insets/InsetCaption.cpp:404
 msgid "Senseless!!! "
 msgstr "Sinnlos!!! "
 
-#: src/Buffer.cpp:5470
+#: src/Buffer.cpp:5477
 #, c-format
 msgid "Document %1$s reloaded."
 msgstr "Dokument %1$s neu geladen."
 
-#: src/Buffer.cpp:5473
+#: src/Buffer.cpp:5480
 #, c-format
 msgid "Could not reload document %1$s."
 msgstr "Kann Dokument %1$s nicht neu laden."
@@ -28027,23 +28023,23 @@ msgid "greyedout inset text"
 msgstr "Grauschrift-Einfügungstext"
 
 #: src/BufferParams.cpp:1718 src/BufferParams.cpp:1872
-#: src/BufferParams.cpp:2315 src/Encoding.cpp:253 src/Paragraph.cpp:3014
+#: src/BufferParams.cpp:2315 src/Encoding.cpp:264 src/Paragraph.cpp:3014
 #: src/frontends/qt/LaTeXHighlighter.cpp:143
 #: src/frontends/qt/LaTeXHighlighter.cpp:257
 #: src/insets/InsetCommandParams.cpp:508 src/insets/InsetCommandParams.cpp:516
-#: src/insets/InsetGraphics.cpp:886 src/insets/InsetGraphics.cpp:894
+#: src/insets/InsetGraphics.cpp:900 src/insets/InsetGraphics.cpp:908
 #: src/insets/InsetListings.cpp:299 src/insets/InsetListings.cpp:307
-#: src/insets/InsetListings.cpp:332 src/mathed/MathExtern.cpp:1440
-#: src/mathed/MathExtern.cpp:1514
+#: src/insets/InsetListings.cpp:332 src/mathed/MathExtern.cpp:1444
+#: src/mathed/MathExtern.cpp:1518
 msgid "LyX Warning: "
 msgstr "LyX-Warnung: "
 
 #: src/BufferParams.cpp:1719 src/BufferParams.cpp:1873
-#: src/BufferParams.cpp:2316 src/Encoding.cpp:254 src/Paragraph.cpp:3015
+#: src/BufferParams.cpp:2316 src/Encoding.cpp:265 src/Paragraph.cpp:3015
 #: src/insets/InsetCommandParams.cpp:509 src/insets/InsetCommandParams.cpp:517
-#: src/insets/InsetGraphics.cpp:887 src/insets/InsetGraphics.cpp:895
+#: src/insets/InsetGraphics.cpp:901 src/insets/InsetGraphics.cpp:909
 #: src/insets/InsetListings.cpp:300 src/insets/InsetListings.cpp:308
-#: src/mathed/MathExtern.cpp:1441 src/mathed/MathExtern.cpp:1515
+#: src/mathed/MathExtern.cpp:1445 src/mathed/MathExtern.cpp:1519
 msgid "uncodable character"
 msgstr "unkodierbares Zeichen"
 
@@ -28221,7 +28217,7 @@ msgstr "Das Dokument wurde extern bearbeitet"
 msgid "This portion of the document is deleted."
 msgstr "Dieser Teil des Dokuments wird gelöscht."
 
-#: src/BufferView.cpp:1191 src/BufferView.cpp:2254
+#: src/BufferView.cpp:1191 src/BufferView.cpp:2255
 #: src/frontends/qt/GuiView.cpp:4296 src/frontends/qt/GuiView.cpp:4384
 msgid "Absolute filename expected."
 msgstr "Ein absoluter Dateipfad wird erwartet."
@@ -28298,42 +28294,42 @@ msgstr "Ein Zeichen (ohne Leerzeichen)"
 msgid "Statistics"
 msgstr "Statistik"
 
-#: src/BufferView.cpp:2112
+#: src/BufferView.cpp:2113
 #, c-format
 msgid ""
 "`inset-forall' interrupted because number of actions is larger than %1$d"
 msgstr ""
 ",inset-forall` wurde abgebrochen, da die Zahl der Aktionen %1$d übersteigt"
 
-#: src/BufferView.cpp:2114
+#: src/BufferView.cpp:2115
 #, c-format
 msgid "Applied \"%1$s\" to %2$d insets"
 msgstr "Der Befehl \"%1$s\" wurde auf %2$d Einfügungen angewandt"
 
-#: src/BufferView.cpp:2122
+#: src/BufferView.cpp:2123
 msgid "Branch name"
 msgstr "Name des Zweigs"
 
-#: src/BufferView.cpp:2129 src/frontends/qt/GuiBranches.cpp:225
+#: src/BufferView.cpp:2130 src/frontends/qt/GuiBranches.cpp:225
 msgid "Branch already exists"
 msgstr "Zweig existiert bereits"
 
-#: src/BufferView.cpp:3056
+#: src/BufferView.cpp:3057
 #, c-format
 msgid "Inserting document %1$s..."
 msgstr "Füge Dokument %1$s ein..."
 
-#: src/BufferView.cpp:3072
+#: src/BufferView.cpp:3073
 #, c-format
 msgid "Document %1$s inserted."
 msgstr "Dokument %1$s ist eingefügt."
 
-#: src/BufferView.cpp:3074
+#: src/BufferView.cpp:3075
 #, c-format
 msgid "Could not insert document %1$s"
 msgstr "Das Dokument %1$s konnte nicht eingefügt werden"
 
-#: src/BufferView.cpp:3569
+#: src/BufferView.cpp:3570
 #, c-format
 msgid ""
 "Could not read the specified document\n"
@@ -28344,11 +28340,11 @@ msgstr ""
 "konnte aufgrund des folgenden Fehlers\n"
 "nicht gelesen werden: %2$s"
 
-#: src/BufferView.cpp:3571
+#: src/BufferView.cpp:3572
 msgid "Could not read file"
 msgstr "Die Datei konnte nicht gelesen werden"
 
-#: src/BufferView.cpp:3578
+#: src/BufferView.cpp:3579
 #, c-format
 msgid ""
 "%1$s\n"
@@ -28357,17 +28353,17 @@ msgstr ""
 "%1$s\n"
 "ist nicht lesbar."
 
-#: src/BufferView.cpp:3579 src/frontends/qt/qt_helpers.cpp:311
-#: src/frontends/qt/qt_helpers.cpp:314 src/frontends/qt/qt_helpers.cpp:320
+#: src/BufferView.cpp:3580 src/frontends/qt/qt_helpers.cpp:322
+#: src/frontends/qt/qt_helpers.cpp:325 src/frontends/qt/qt_helpers.cpp:331
 #: src/output.cpp:39
 msgid "Could not open file"
 msgstr "Die Datei konnte nicht geöffnet werden"
 
-#: src/BufferView.cpp:3586
+#: src/BufferView.cpp:3587
 msgid "Reading not UTF-8 encoded file"
 msgstr "Lese nicht-UTF-8-kodierte Datei"
 
-#: src/BufferView.cpp:3587
+#: src/BufferView.cpp:3588
 msgid ""
 "The file is not UTF-8 encoded.\n"
 "It will be read as local 8Bit-encoded.\n"
@@ -30479,11 +30475,11 @@ msgstr ""
 msgid "Unknown Inset"
 msgstr "Unbekannte Einfügung"
 
-#: src/Text.cpp:554 src/insets/InsetTabular.cpp:473
+#: src/Text.cpp:554 src/insets/InsetTabular.cpp:476
 msgid "Change tracking author index missing"
 msgstr "Autorindex für die Änderungsverfolgung fehlt"
 
-#: src/Text.cpp:555 src/insets/InsetTabular.cpp:474
+#: src/Text.cpp:555 src/insets/InsetTabular.cpp:477
 #, c-format
 msgid ""
 "A change tracking author information for index %1$d is missing. This can "
@@ -30584,7 +30580,7 @@ msgstr "Mathe-Editor-Modus"
 msgid "No valid math formula"
 msgstr "Keine gültige Matheformel"
 
-#: src/Text3.cpp:210 src/mathed/InsetMathNest.cpp:1032
+#: src/Text3.cpp:210 src/mathed/InsetMathNest.cpp:1038
 msgid "Already in regular expression mode"
 msgstr "Bereits im Regexp-Modus"
 
@@ -30604,7 +30600,7 @@ msgstr " unbekannt"
 msgid "Table Style "
 msgstr "Tabellenstil"
 
-#: src/Text3.cpp:2385 src/frontends/qt/GuiApplication.cpp:1873
+#: src/Text3.cpp:2385 src/frontends/qt/GuiApplication.cpp:1887
 msgid "Missing argument"
 msgstr "Fehlendes Argument"
 
@@ -30761,53 +30757,57 @@ msgstr ""
 msgid "Error reading cite engine %1$s\n"
 msgstr "Fehler beim Lesen der Zitierformatdatei %1$s\n"
 
-#: src/TocBackend.cpp:270 src/insets/InsetIndex.cpp:517
+#: src/TocBackend.cpp:69 src/insets/InsetInclude.cpp:1373
+msgid "MISSING: "
+msgstr "NICHT VORHANDEN:"
+
+#: src/TocBackend.cpp:273 src/insets/InsetIndex.cpp:517
 #: src/insets/InsetIndex.cpp:538
 msgid "unknown type!"
 msgstr "unbekannter Typ!"
 
-#: src/TocBackend.cpp:273
+#: src/TocBackend.cpp:276
 #, c-format
 msgid "Index Entries (%1$s)"
 msgstr "Stichwörter (%1$s)"
 
-#: src/TocBackend.cpp:289 src/insets/InsetTOC.cpp:75
+#: src/TocBackend.cpp:292 src/insets/InsetTOC.cpp:75
 msgid "Table of Contents"
 msgstr "Inhaltsverzeichnis"
 
-#: src/TocBackend.cpp:290
+#: src/TocBackend.cpp:293
 msgid "Changes"
 msgstr "Änderungen"
 
-#: src/TocBackend.cpp:291
+#: src/TocBackend.cpp:294
 msgid "Senseless"
 msgstr "Sinnlos"
 
-#: src/TocBackend.cpp:292
+#: src/TocBackend.cpp:295
 msgid "Citations"
 msgstr "Literaturverweise"
 
-#: src/TocBackend.cpp:293
+#: src/TocBackend.cpp:296
 msgid "Labels and References"
 msgstr "Marken und Querverweise"
 
-#: src/TocBackend.cpp:294
+#: src/TocBackend.cpp:297
 msgid "Broken References and Citations"
 msgstr "Ungültige Literatur- und Querverweise"
 
-#: src/TocBackend.cpp:296 src/frontends/qt/GuiDocument.cpp:1774
+#: src/TocBackend.cpp:299 src/frontends/qt/GuiDocument.cpp:1774
 msgid "Child Documents"
 msgstr "Unterdokumente"
 
-#: src/TocBackend.cpp:297
+#: src/TocBackend.cpp:300
 msgid "Graphics[[listof]]"
 msgstr "Grafiken"
 
-#: src/TocBackend.cpp:298
+#: src/TocBackend.cpp:301
 msgid "Equations"
 msgstr "Gleichungen"
 
-#: src/TocBackend.cpp:301
+#: src/TocBackend.cpp:304
 msgid "Nomenclature Entries"
 msgstr "Nomenklatureinträge"
 
@@ -31020,15 +31020,15 @@ msgstr ""
 
 #: src/VCBackend.cpp:1522 src/VCBackend.cpp:1526
 #: src/frontends/qt/FindAndReplace.cpp:381 src/frontends/qt/GuiPrefs.cpp:1895
-#: src/lyxfind.cpp:303 src/lyxfind.cpp:330 src/lyxfind.cpp:351
-#: src/lyxfind.cpp:694 src/lyxfind.cpp:722
+#: src/lyxfind.cpp:310 src/lyxfind.cpp:337 src/lyxfind.cpp:358
+#: src/lyxfind.cpp:701 src/lyxfind.cpp:729
 msgid "&Yes"
 msgstr "&Ja"
 
 #: src/VCBackend.cpp:1522 src/VCBackend.cpp:1526
 #: src/frontends/qt/FindAndReplace.cpp:381 src/frontends/qt/GuiPrefs.cpp:1895
-#: src/lyxfind.cpp:303 src/lyxfind.cpp:330 src/lyxfind.cpp:351
-#: src/lyxfind.cpp:694 src/lyxfind.cpp:722
+#: src/lyxfind.cpp:310 src/lyxfind.cpp:337 src/lyxfind.cpp:358
+#: src/lyxfind.cpp:701 src/lyxfind.cpp:729
 msgid "&No"
 msgstr "&Nein"
 
@@ -31165,7 +31165,7 @@ msgid "Dings 4"
 msgstr "Dings 4"
 
 #: src/frontends/qt/ButtonController.cpp:222
-#: src/frontends/qt/GuiApplication.cpp:1997 src/frontends/qt/GuiCompare.cpp:193
+#: src/frontends/qt/GuiApplication.cpp:2011 src/frontends/qt/GuiCompare.cpp:193
 #: src/frontends/qt/GuiSymbols.cpp:346
 msgid "Cancel"
 msgstr "Abbrechen"
@@ -31237,8 +31237,8 @@ msgstr "Erweiterte Suche läuft (drücken Sie ESC, um abzubrechen) ..."
 msgid "Advanced search cancelled by user"
 msgstr "Erweiterte Suche durch den Benutzer abgebrochen"
 
-#: src/frontends/qt/FindAndReplace.cpp:380 src/lyxfind.cpp:350
-#: src/lyxfind.cpp:693 src/lyxfind.cpp:721
+#: src/frontends/qt/FindAndReplace.cpp:380 src/lyxfind.cpp:357
+#: src/lyxfind.cpp:700 src/lyxfind.cpp:728
 msgid "Wrap search?"
 msgstr "Von vorne suchen?"
 
@@ -31391,89 +31391,89 @@ msgstr "Python-Aufruf: %1$s"
 msgid "About LyX"
 msgstr "Ãœber LyX"
 
-#: src/frontends/qt/GuiApplication.cpp:736
+#: src/frontends/qt/GuiApplication.cpp:750
 msgid "About %1"
 msgstr "Ãœber %1"
 
-#: src/frontends/qt/GuiApplication.cpp:737 src/frontends/qt/GuiPrefs.cpp:3528
+#: src/frontends/qt/GuiApplication.cpp:751 src/frontends/qt/GuiPrefs.cpp:3528
 msgid "Preferences"
 msgstr "Einstellungen"
 
-#: src/frontends/qt/GuiApplication.cpp:738
+#: src/frontends/qt/GuiApplication.cpp:752
 msgid "Reconfigure"
 msgstr "Neu konfigurieren"
 
-#: src/frontends/qt/GuiApplication.cpp:739
+#: src/frontends/qt/GuiApplication.cpp:753
 msgid "Restore Defaults"
 msgstr "Voreinstellungen"
 
-#: src/frontends/qt/GuiApplication.cpp:740
+#: src/frontends/qt/GuiApplication.cpp:754
 msgid "Quit %1"
 msgstr "%1 beenden"
 
-#: src/frontends/qt/GuiApplication.cpp:741 src/frontends/qt/GuiInclude.cpp:318
+#: src/frontends/qt/GuiApplication.cpp:755 src/frontends/qt/GuiInclude.cpp:318
 #: src/frontends/qt/GuiInclude.cpp:328 src/frontends/qt/GuiInclude.cpp:333
 msgid "&OK"
 msgstr "&OK"
 
-#: src/frontends/qt/GuiApplication.cpp:743
+#: src/frontends/qt/GuiApplication.cpp:757
 msgid "Apply"
 msgstr "Anwenden"
 
-#: src/frontends/qt/GuiApplication.cpp:744
+#: src/frontends/qt/GuiApplication.cpp:758
 msgid "Reset"
 msgstr "Zurücksetzen"
 
-#: src/frontends/qt/GuiApplication.cpp:745
+#: src/frontends/qt/GuiApplication.cpp:759
 msgid "Open"
 msgstr "Öffnen"
 
-#: src/frontends/qt/GuiApplication.cpp:1270
+#: src/frontends/qt/GuiApplication.cpp:1284
 msgid "Nothing to do"
 msgstr "Nichts zu tun"
 
-#: src/frontends/qt/GuiApplication.cpp:1276
+#: src/frontends/qt/GuiApplication.cpp:1290
 msgid "Unknown action"
 msgstr "Unbekannte Aktion"
 
-#: src/frontends/qt/GuiApplication.cpp:1320
+#: src/frontends/qt/GuiApplication.cpp:1334
 msgid "Command not handled"
 msgstr "Befehl wurde nicht ausgeführt"
 
-#: src/frontends/qt/GuiApplication.cpp:1326
+#: src/frontends/qt/GuiApplication.cpp:1340
 msgid "Command disabled"
 msgstr "Befehl ist deaktiviert"
 
-#: src/frontends/qt/GuiApplication.cpp:1434
+#: src/frontends/qt/GuiApplication.cpp:1448
 #, c-format
 msgid "Bad debug value `%1$s'."
 msgstr "Falscher Debug-Wert ,%1$s'."
 
-#: src/frontends/qt/GuiApplication.cpp:1463 src/frontends/qt/GuiView.cpp:2214
+#: src/frontends/qt/GuiApplication.cpp:1477 src/frontends/qt/GuiView.cpp:2214
 msgid "Command not allowed without a buffer open"
 msgstr "Dieser Befehl ist nur bei geöffnetem Dokument möglich"
 
-#: src/frontends/qt/GuiApplication.cpp:1470
+#: src/frontends/qt/GuiApplication.cpp:1484
 msgid "the <LFUN-COMMAND> argument of buffer-forall is not valid"
 msgstr "Das <LFUN-COMMAND>-Argument des Befehls 'buffer-forall' ist ungültig."
 
-#: src/frontends/qt/GuiApplication.cpp:1547
+#: src/frontends/qt/GuiApplication.cpp:1561
 msgid "Wrong focus!"
 msgstr "Fokusfehler!"
 
-#: src/frontends/qt/GuiApplication.cpp:1681
+#: src/frontends/qt/GuiApplication.cpp:1695
 msgid "Running configure..."
 msgstr "Neukonfiguration wird durchgeführt..."
 
-#: src/frontends/qt/GuiApplication.cpp:1691
+#: src/frontends/qt/GuiApplication.cpp:1705
 msgid "Reloading configuration..."
 msgstr "Konfiguration wird neu geladen..."
 
-#: src/frontends/qt/GuiApplication.cpp:1701
+#: src/frontends/qt/GuiApplication.cpp:1715
 msgid "System reconfiguration failed"
 msgstr "Neukonfiguration des Systems fehlgeschlagen"
 
-#: src/frontends/qt/GuiApplication.cpp:1702
+#: src/frontends/qt/GuiApplication.cpp:1716
 msgid ""
 "The system reconfiguration has failed.\n"
 "Default textclass is used but LyX may\n"
@@ -31485,11 +31485,11 @@ msgstr ""
 "der Lage, korrekt zu arbeiten.\n"
 "Bitte rekonfigurieren Sie nochmals, wenn nötig."
 
-#: src/frontends/qt/GuiApplication.cpp:1707
+#: src/frontends/qt/GuiApplication.cpp:1721
 msgid "System reconfigured"
 msgstr "Das System wurde neu konfiguriert"
 
-#: src/frontends/qt/GuiApplication.cpp:1708
+#: src/frontends/qt/GuiApplication.cpp:1722
 msgid ""
 "The system has been reconfigured.\n"
 "You need to restart LyX to make use of any\n"
@@ -31499,59 +31499,59 @@ msgstr ""
 "Sie müssen LyX neu starten, um die aktualisierten\n"
 "Spezifikationen für die Dokumentklassen zu nutzen."
 
-#: src/frontends/qt/GuiApplication.cpp:1789
+#: src/frontends/qt/GuiApplication.cpp:1803
 msgid "Exiting."
 msgstr "LyX wird beendet."
 
-#: src/frontends/qt/GuiApplication.cpp:1885
+#: src/frontends/qt/GuiApplication.cpp:1899
 #, c-format
 msgid "Opening help file %1$s..."
 msgstr "Hilfe-Datei %1$s wird geöffnet..."
 
-#: src/frontends/qt/GuiApplication.cpp:1905
+#: src/frontends/qt/GuiApplication.cpp:1919
 msgid "Wrong argument. Must be 'examples' or 'templates'."
 msgstr "Falsches Argument: muss 'examples' oder 'templates' sein."
 
-#: src/frontends/qt/GuiApplication.cpp:1919
+#: src/frontends/qt/GuiApplication.cpp:1933
 msgid "Syntax: set-color <lyx_name> <x11_name> <x11_darkname>"
 msgstr "Syntax: set-color <lyx_name> <x11_name> <x11_darkname>"
 
-#: src/frontends/qt/GuiApplication.cpp:1939
+#: src/frontends/qt/GuiApplication.cpp:1953
 #, c-format
 msgid "Set-color \"%1$s\" failed - color is undefined or may not be redefined"
 msgstr ""
 "Set-color \"%1$s\" ist fehlgeschlagen -- die Farbe ist nicht definiert oder "
 "darf nicht umdefiniert werden."
 
-#: src/frontends/qt/GuiApplication.cpp:2044
+#: src/frontends/qt/GuiApplication.cpp:2058
 #, c-format
 msgid "Cannot iterate more than %1$d times"
 msgstr "Mehr als %1$d Wiederholungen sind nicht möglich."
 
-#: src/frontends/qt/GuiApplication.cpp:2144
+#: src/frontends/qt/GuiApplication.cpp:2158
 #, c-format
 msgid "Applied \"%1$s\" to %2$d buffer(s)"
 msgstr "Der Befehl \"%1$s\" wurde auf %2$d Dateien (Pufferspeicher) angewandt"
 
-#: src/frontends/qt/GuiApplication.cpp:2230
+#: src/frontends/qt/GuiApplication.cpp:2244
 #, c-format
 msgid "Document defaults saved in %1$s"
 msgstr "Dokument-Standardeinstellungen gespeichert in %1$s"
 
-#: src/frontends/qt/GuiApplication.cpp:2234
+#: src/frontends/qt/GuiApplication.cpp:2248
 msgid "Unable to save document defaults"
 msgstr "Die Dokument-Standardeinstellungen können nicht gespeichert werden"
 
-#: src/frontends/qt/GuiApplication.cpp:2474
-#: src/frontends/qt/GuiApplication.cpp:2489
+#: src/frontends/qt/GuiApplication.cpp:2488
+#: src/frontends/qt/GuiApplication.cpp:2503
 msgid "Unknown function."
 msgstr "Unbekannte Funktion."
 
-#: src/frontends/qt/GuiApplication.cpp:3024
+#: src/frontends/qt/GuiApplication.cpp:3038
 msgid "The current document was closed."
 msgstr "Das aktuelle Dokument wurde geschlossen."
 
-#: src/frontends/qt/GuiApplication.cpp:3034
+#: src/frontends/qt/GuiApplication.cpp:3048
 msgid ""
 "LyX has caught an exception, it will now attempt to save all unsaved "
 "documents and exit.\n"
@@ -31563,12 +31563,12 @@ msgstr ""
 "\n"
 "Exception: "
 
-#: src/frontends/qt/GuiApplication.cpp:3038
-#: src/frontends/qt/GuiApplication.cpp:3044
+#: src/frontends/qt/GuiApplication.cpp:3052
+#: src/frontends/qt/GuiApplication.cpp:3058
 msgid "Software exception Detected"
 msgstr "Softwareausnahme erkannt"
 
-#: src/frontends/qt/GuiApplication.cpp:3042
+#: src/frontends/qt/GuiApplication.cpp:3056
 msgid ""
 "LyX has caught some really weird exception, it will now attempt to save all "
 "unsaved documents and exit."
@@ -31576,12 +31576,12 @@ msgstr ""
 "LyX hat einen ziemlich seltsamen Fehler entdeckt. Das Programm wird jetzt "
 "versuchen, alle ungespeicherten Dateien zu speichern, und dann beendet."
 
-#: src/frontends/qt/GuiApplication.cpp:3348
-#: src/frontends/qt/GuiApplication.cpp:3360
+#: src/frontends/qt/GuiApplication.cpp:3362
+#: src/frontends/qt/GuiApplication.cpp:3374
 msgid "Could not find UI definition file"
 msgstr "Die Benutzeroberflächen-Definitionsdatei konnte nicht gefunden werden"
 
-#: src/frontends/qt/GuiApplication.cpp:3349
+#: src/frontends/qt/GuiApplication.cpp:3363
 #, c-format
 msgid ""
 "Error while reading the included file\n"
@@ -31592,13 +31592,13 @@ msgstr ""
 "%1$s.\n"
 "Bitte überprüfen Sie Ihre Installation."
 
-#: src/frontends/qt/GuiApplication.cpp:3355
+#: src/frontends/qt/GuiApplication.cpp:3369
 msgid "Could not find default UI file"
 msgstr ""
 "Die Standard-Benutzeroberflächen-Definitionsdatei konnte nicht gefunden "
 "werden"
 
-#: src/frontends/qt/GuiApplication.cpp:3356
+#: src/frontends/qt/GuiApplication.cpp:3370
 msgid ""
 "LyX could not find the default UI file!\n"
 "Please check your installation."
@@ -31607,7 +31607,7 @@ msgstr ""
 "für die Benutzeroberfläche!\n"
 "Bitte überprüfen Sie Ihre Installation."
 
-#: src/frontends/qt/GuiApplication.cpp:3361
+#: src/frontends/qt/GuiApplication.cpp:3375
 #, c-format
 msgid ""
 "Error while reading the configuration file\n"
@@ -33999,7 +33999,7 @@ msgstr "&Gehe zurück"
 msgid "Jump back to the original cursor location"
 msgstr "Springe zur ursprünglichen Cursor-Platzierung zurück"
 
-#: src/frontends/qt/GuiRef.cpp:467 src/frontends/qt/GuiRef.cpp:487
+#: src/frontends/qt/GuiRef.cpp:471 src/frontends/qt/GuiRef.cpp:491
 msgid "<No prefix>"
 msgstr "<Ohne Präfix>"
 
@@ -35448,11 +35448,11 @@ msgstr "%1$s aktualisieren"
 msgid "View %1$s"
 msgstr "%1$s ansehen"
 
-#: src/frontends/qt/Validator.cpp:214
+#: src/frontends/qt/Validator.cpp:218
 msgid "space"
 msgstr "Leerzeichen"
 
-#: src/frontends/qt/Validator.cpp:242
+#: src/frontends/qt/Validator.cpp:246
 msgid ""
 "LyX does not provide LaTeX support for file names containing any of these "
 "characters:\n"
@@ -35460,48 +35460,48 @@ msgstr ""
 "LyX bietet keine LaTeX-Unterstützung für Dateinamen, die eines der folgenden "
 "Zeichen enthalten:\n"
 
-#: src/frontends/qt/qt_helpers.cpp:280
+#: src/frontends/qt/qt_helpers.cpp:291
 msgid "Invalid URL"
 msgstr "Ungültige URL"
 
-#: src/frontends/qt/qt_helpers.cpp:281
+#: src/frontends/qt/qt_helpers.cpp:292
 #, c-format
 msgid "The URL `%1$s' could not be resolved."
 msgstr "Die URL ,%1$s` konnte nicht aufgelöst werden."
 
-#: src/frontends/qt/qt_helpers.cpp:287
+#: src/frontends/qt/qt_helpers.cpp:298
 msgid "URL could not be accessed"
 msgstr "URL nicht zugänglich."
 
-#: src/frontends/qt/qt_helpers.cpp:288
+#: src/frontends/qt/qt_helpers.cpp:299
 #, c-format
 msgid "The URL `%1$s' could not be opened although it exists!"
 msgstr "Die URL ,%1$s` konnte nicht geöffnet werden, obwohl sie existiert!"
 
-#: src/frontends/qt/qt_helpers.cpp:312
+#: src/frontends/qt/qt_helpers.cpp:323
 msgid "The lyxpaperview script failed."
 msgstr "Das Skript lyxpaperview ist fehlgeschlagen."
 
-#: src/frontends/qt/qt_helpers.cpp:315
+#: src/frontends/qt/qt_helpers.cpp:326
 #, c-format
 msgid "No file was found using the pattern `%1$s'."
 msgstr "Mit dem Suchmuster ,%1$s` konnte keine Datei gefunden werden."
 
-#: src/frontends/qt/qt_helpers.cpp:321
+#: src/frontends/qt/qt_helpers.cpp:332
 #, c-format
 msgid "The target `%1$s' could not be resolved."
 msgstr "Das Verweisziel ,%1$s` konnte nicht aufgelöst werden."
 
-#: src/frontends/qt/qt_helpers.cpp:357
+#: src/frontends/qt/qt_helpers.cpp:368
 msgid "Could not update TeX information"
 msgstr "Die TeX-Informationen konnten nicht aktualisiert werden"
 
-#: src/frontends/qt/qt_helpers.cpp:358
+#: src/frontends/qt/qt_helpers.cpp:369
 #, c-format
 msgid "The script `%1$s' failed."
 msgstr "Das Skript ,%1$s` ist fehlgeschlagen."
 
-#: src/frontends/qt/qt_helpers.cpp:606
+#: src/frontends/qt/qt_helpers.cpp:617
 msgid "All Files "
 msgstr "Alle Dateien "
 
@@ -35900,15 +35900,15 @@ msgstr "FEHLER: Unbekannter Gleitobjekt-Typ: %1$s"
 msgid "float"
 msgstr "Gleitobjekt"
 
-#: src/insets/InsetFloat.cpp:911
+#: src/insets/InsetFloat.cpp:914
 msgid "Float: "
 msgstr "Gleitobjekt: "
 
-#: src/insets/InsetFloat.cpp:914
+#: src/insets/InsetFloat.cpp:917
 msgid "Subfloat: "
 msgstr "Untergleitobjekt: "
 
-#: src/insets/InsetFloat.cpp:924
+#: src/insets/InsetFloat.cpp:927
 msgid " (sideways)"
 msgstr " (seitwärts)"
 
@@ -35925,7 +35925,7 @@ msgstr "LyX kann keine Liste mit %1$s erzeugen"
 msgid "footnote"
 msgstr "Fußnote"
 
-#: src/insets/InsetGraphics.cpp:562 src/insets/InsetInclude.cpp:787
+#: src/insets/InsetGraphics.cpp:563 src/insets/InsetInclude.cpp:787
 #, c-format
 msgid ""
 "Could not copy the file\n"
@@ -35936,12 +35936,25 @@ msgstr ""
 "%1$s\n"
 "konnte nicht in das temporäre Verzeichnis kopiert werden."
 
-#: src/insets/InsetGraphics.cpp:778 src/insets/InsetGraphics.cpp:1015
+#: src/insets/InsetGraphics.cpp:779 src/insets/InsetGraphics.cpp:1029
 #, c-format
 msgid "No conversion of %1$s is needed after all"
 msgstr "Es ist keine Konvertierung von %1$s notwendig"
 
-#: src/insets/InsetGraphics.cpp:906
+#: src/insets/InsetGraphics.cpp:832
+msgid "Graphic not specified. Falling back to `draft' mode."
+msgstr "Keine Grafikdatei angegeben. Verwende 'Draft'-Modus."
+
+#: src/insets/InsetGraphics.cpp:833
+#, c-format
+msgid "Graphic `%1$s' was not found. Falling back to `draft' mode."
+msgstr "Die Grafikdatei `%1$s' wurde nicht gefunden. Verwende 'Draft'-Modus."
+
+#: src/insets/InsetGraphics.cpp:836
+msgid "Graphic not found!"
+msgstr "Grafik nicht gefunden!"
+
+#: src/insets/InsetGraphics.cpp:920
 #, c-format
 msgid ""
 "The following characters in one of the graphic paths are\n"
@@ -35953,7 +35966,7 @@ msgstr ""
 "%1$s. \n"
 "Sie müssen entweder die Kodierung oder den Pfad anpassen."
 
-#: src/insets/InsetGraphics.cpp:931
+#: src/insets/InsetGraphics.cpp:945
 #, c-format
 msgid "Graphics file: %1$s"
 msgstr "Grafikdatei: %1$s"
@@ -36150,10 +36163,6 @@ msgstr ""
 "Betroffene Datei:\n"
 "%1$s"
 
-#: src/insets/InsetInclude.cpp:1373
-msgid "MISSING: "
-msgstr "NICHT VORHANDEN:"
-
 #: src/insets/InsetIndex.cpp:169
 msgid "Index sorting failed"
 msgstr "Indexsortierung fehlgeschlagen"
@@ -36187,276 +36196,276 @@ msgstr "Alle Indexe"
 msgid "subindex"
 msgstr "Unterindex"
 
-#: src/insets/InsetInfo.cpp:194
+#: src/insets/InsetInfo.cpp:195
 msgid "No long date format (language unknown)!"
 msgstr "Kein langes Datumsformat (Sprache unbekannt)!"
 
-#: src/insets/InsetInfo.cpp:197
+#: src/insets/InsetInfo.cpp:198
 msgid "No medium date format (language unknown)!"
 msgstr "Kein mittleres Datumsformat (Sprache unbekannt)!"
 
-#: src/insets/InsetInfo.cpp:200
+#: src/insets/InsetInfo.cpp:201
 msgid "No short date format (language unknown)!"
 msgstr "Kein kurzes Datumsformat (Sprache unbekannt)!"
 
-#: src/insets/InsetInfo.cpp:229
+#: src/insets/InsetInfo.cpp:230
 msgid "Please select a valid type!"
 msgstr "Bitte wählen Sie einen gültigen Typ!"
 
-#: src/insets/InsetInfo.cpp:269
+#: src/insets/InsetInfo.cpp:270
 msgid "File name (with extension)"
 msgstr "Dateiname (mit Endung)"
 
-#: src/insets/InsetInfo.cpp:270
+#: src/insets/InsetInfo.cpp:271
 msgid "File name (without extension)"
 msgstr "Dateiname (ohne Endung)"
 
-#: src/insets/InsetInfo.cpp:271
+#: src/insets/InsetInfo.cpp:272
 msgid "File path"
 msgstr "Dateipfad"
 
-#: src/insets/InsetInfo.cpp:272
+#: src/insets/InsetInfo.cpp:273
 msgid "Used text class"
 msgstr "Verwendete Textklasse"
 
-#: src/insets/InsetInfo.cpp:277 src/insets/InsetInfo.cpp:1116
+#: src/insets/InsetInfo.cpp:278 src/insets/InsetInfo.cpp:1145
 msgid "No version control!"
 msgstr "Keine Versionskontrolle!"
 
-#: src/insets/InsetInfo.cpp:280
+#: src/insets/InsetInfo.cpp:281
 msgid "Revision[[Version Control]]"
 msgstr "Revision"
 
-#: src/insets/InsetInfo.cpp:281
+#: src/insets/InsetInfo.cpp:282
 msgid "Abbreviated revision[[Version Control]]"
 msgstr "Abgekürzte Revision"
 
-#: src/insets/InsetInfo.cpp:282
+#: src/insets/InsetInfo.cpp:283
 msgid "Tree revision"
 msgstr "Baumrevision"
 
-#: src/insets/InsetInfo.cpp:285
+#: src/insets/InsetInfo.cpp:286
 msgid "Time[[of day]]"
 msgstr "Uhrzeit"
 
-#: src/insets/InsetInfo.cpp:290
+#: src/insets/InsetInfo.cpp:291
 msgid "LyX version"
 msgstr "LyX-Version"
 
-#: src/insets/InsetInfo.cpp:291
+#: src/insets/InsetInfo.cpp:292
 msgid "LyX layout format"
 msgstr "LyX-Layoutformat"
 
-#: src/insets/InsetInfo.cpp:494
+#: src/insets/InsetInfo.cpp:495
 msgid "Invalid information inset"
 msgstr "Ungültige Informationseinfügung"
 
-#: src/insets/InsetInfo.cpp:497
+#: src/insets/InsetInfo.cpp:498
 #, c-format
 msgid "The keybard shortcut for the function '%1$s'"
 msgstr "Das Tastenkürzel für die LyX-Funktion '%1$s'"
 
-#: src/insets/InsetInfo.cpp:501
+#: src/insets/InsetInfo.cpp:502
 #, c-format
 msgid "The keybard shortcuts for the function '%1$s'"
 msgstr "Die Tastenkürzel für die LyX-Funktion '%1$s'"
 
-#: src/insets/InsetInfo.cpp:505
+#: src/insets/InsetInfo.cpp:506
 #, c-format
 msgid "The menu location for the function '%1$s'"
 msgstr "Der Menüeintrag für die LyX-Funktion '%1$s'"
 
-#: src/insets/InsetInfo.cpp:509
+#: src/insets/InsetInfo.cpp:510
 #, c-format
 msgid "The localization for the string '%1$s'"
 msgstr "Die Lokalisierung für '%1$s'"
 
-#: src/insets/InsetInfo.cpp:513
+#: src/insets/InsetInfo.cpp:514
 #, c-format
 msgid "The toolbar icon for the function '%1$s'"
 msgstr "Das Werkzeugleistensymbol für die LyX-Funktion '%1$s'"
 
-#: src/insets/InsetInfo.cpp:517
+#: src/insets/InsetInfo.cpp:518
 #, c-format
 msgid "The preference setting for the preference key '%1$s'"
 msgstr "Die LyX-Einstellung für den Einstellungsschlüssel '%1$s'"
 
-#: src/insets/InsetInfo.cpp:521
+#: src/insets/InsetInfo.cpp:522
 #, c-format
 msgid "Availability of the LaTeX package '%1$s'"
 msgstr "Verfügbarkeit des LaTeX-Pakets '%1$s'"
 
-#: src/insets/InsetInfo.cpp:525
+#: src/insets/InsetInfo.cpp:526
 #, c-format
 msgid "Availability of the LaTeX class '%1$s'"
 msgstr "Verfügbarkeit der LaTeX-Klasse '%1$s'"
 
-#: src/insets/InsetInfo.cpp:530
+#: src/insets/InsetInfo.cpp:531
 msgid "The name of this file (incl. extension)"
 msgstr "Der Name dieser Datei (inkl. Endung)"
 
-#: src/insets/InsetInfo.cpp:532
+#: src/insets/InsetInfo.cpp:533
 msgid "The name of this file (without extension)"
 msgstr "Der Name dieser Datei (ohne Endung)"
 
-#: src/insets/InsetInfo.cpp:534
+#: src/insets/InsetInfo.cpp:535
 msgid "The path where this file is saved"
 msgstr "Der Pfad, an dem diese Datei gespeichert ist"
 
-#: src/insets/InsetInfo.cpp:536
+#: src/insets/InsetInfo.cpp:537
 msgid "The class this document uses"
 msgstr "Die Klasse, die dieses Dokument verwendet"
 
-#: src/insets/InsetInfo.cpp:540
+#: src/insets/InsetInfo.cpp:541
 msgid "Version control revision"
 msgstr "Versionskontrolle: Revision"
 
-#: src/insets/InsetInfo.cpp:542
+#: src/insets/InsetInfo.cpp:543
 msgid "Version control abbreviated revision"
 msgstr "Versionskontrolle: Abgekürzte Revision"
 
-#: src/insets/InsetInfo.cpp:544
+#: src/insets/InsetInfo.cpp:545
 msgid "Version control tree revision"
 msgstr "Versionskontrolle: Tree-Revision"
 
-#: src/insets/InsetInfo.cpp:546
+#: src/insets/InsetInfo.cpp:547
 msgid "Version control author"
 msgstr "Versionskontrolle: Autor"
 
-#: src/insets/InsetInfo.cpp:548
+#: src/insets/InsetInfo.cpp:549
 msgid "Version control date"
 msgstr "Versionskontrolle: Datum"
 
-#: src/insets/InsetInfo.cpp:550
+#: src/insets/InsetInfo.cpp:551
 msgid "Version control time"
 msgstr "Versionskontrolle: Uhrzeit"
 
-#: src/insets/InsetInfo.cpp:554
+#: src/insets/InsetInfo.cpp:555
 msgid "The current LyX version"
 msgstr "Die aktuelle LyX-Version"
 
-#: src/insets/InsetInfo.cpp:556
+#: src/insets/InsetInfo.cpp:557
 msgid "The current LyX layout format"
 msgstr "Das aktuelle Format der LyX-Layoutdateien"
 
-#: src/insets/InsetInfo.cpp:559
+#: src/insets/InsetInfo.cpp:560
 msgid "The current date"
 msgstr "Das aktuelle Datum"
 
-#: src/insets/InsetInfo.cpp:562
+#: src/insets/InsetInfo.cpp:563
 msgid "The date of last save"
 msgstr "Das Datum der letzten gespeicherten Änderung"
 
-#: src/insets/InsetInfo.cpp:565
+#: src/insets/InsetInfo.cpp:566
 msgid "A static date"
 msgstr "Ein festes Datum"
 
-#: src/insets/InsetInfo.cpp:568
+#: src/insets/InsetInfo.cpp:569
 msgid "The current time"
 msgstr "Die aktuelle Uhrzeit"
 
-#: src/insets/InsetInfo.cpp:571
+#: src/insets/InsetInfo.cpp:572
 msgid "The time of last save"
 msgstr "Die Uhrzeit der letzten gespeicherten Änderung"
 
-#: src/insets/InsetInfo.cpp:574
+#: src/insets/InsetInfo.cpp:575
 msgid "A static time"
 msgstr "Eine feste Zeitangabe"
 
-#: src/insets/InsetInfo.cpp:601
+#: src/insets/InsetInfo.cpp:602
 msgid "Missing \\end_inset at this point."
 msgstr "Fehlendes \\end_inset an dieser Stelle."
 
-#: src/insets/InsetInfo.cpp:795
+#: src/insets/InsetInfo.cpp:824
 msgid "Unknown Info!"
 msgstr "Unbekannte Info-Einfügung!"
 
-#: src/insets/InsetInfo.cpp:804 src/insets/InsetInfo.cpp:991
+#: src/insets/InsetInfo.cpp:833 src/insets/InsetInfo.cpp:1020
 #, c-format
 msgid "Unknown action %1$s"
 msgstr "Aktion '%1$s' unbekannt"
 
-#: src/insets/InsetInfo.cpp:810 src/insets/InsetInfo.cpp:920
-#: src/insets/InsetInfo.cpp:929 src/insets/InsetInfo.cpp:937
+#: src/insets/InsetInfo.cpp:839 src/insets/InsetInfo.cpp:949
+#: src/insets/InsetInfo.cpp:958 src/insets/InsetInfo.cpp:966
 msgid "undefined"
 msgstr "undefiniert"
 
-#: src/insets/InsetInfo.cpp:833 src/insets/InsetInfo.cpp:883
+#: src/insets/InsetInfo.cpp:862 src/insets/InsetInfo.cpp:912
 msgid "Return[[Key]]"
 msgstr "Return"
 
-#: src/insets/InsetInfo.cpp:838
+#: src/insets/InsetInfo.cpp:867
 msgid "Tab[[Key]]"
 msgstr "Tab"
 
-#: src/insets/InsetInfo.cpp:843
+#: src/insets/InsetInfo.cpp:872
 msgid "PgUp"
 msgstr "Bild hoch"
 
-#: src/insets/InsetInfo.cpp:848
+#: src/insets/InsetInfo.cpp:877
 msgid "PgDown"
 msgstr "Bild runter"
 
-#: src/insets/InsetInfo.cpp:853
+#: src/insets/InsetInfo.cpp:882
 msgid "Backtab"
 msgstr "Rücktab"
 
-#: src/insets/InsetInfo.cpp:858
+#: src/insets/InsetInfo.cpp:887
 msgid "Tab"
 msgstr "Tab"
 
-#: src/insets/InsetInfo.cpp:868
+#: src/insets/InsetInfo.cpp:897
 msgid "CapsLock"
 msgstr "Feststelltaste"
 
-#: src/insets/InsetInfo.cpp:873
+#: src/insets/InsetInfo.cpp:902
 msgid "Control[[Key]]"
 msgstr "Control"
 
-#: src/insets/InsetInfo.cpp:878
+#: src/insets/InsetInfo.cpp:907
 msgid "Command[[Key]]"
 msgstr "Command"
 
-#: src/insets/InsetInfo.cpp:888
+#: src/insets/InsetInfo.cpp:917
 msgid "Option[[Key]]"
 msgstr "Option"
 
-#: src/insets/InsetInfo.cpp:893
+#: src/insets/InsetInfo.cpp:922
 msgid "Delete[[Key]]"
 msgstr "Rücktaste"
 
-#: src/insets/InsetInfo.cpp:898
+#: src/insets/InsetInfo.cpp:927
 msgid "Fn+Del"
 msgstr "Fn+Rücktaste"
 
-#: src/insets/InsetInfo.cpp:903
+#: src/insets/InsetInfo.cpp:932
 msgid "Esc"
 msgstr "Esc"
 
-#: src/insets/InsetInfo.cpp:947
+#: src/insets/InsetInfo.cpp:976
 msgid "not set"
 msgstr "nicht eingestellt"
 
-#: src/insets/InsetInfo.cpp:959 src/insets/InsetInfo.cpp:976
+#: src/insets/InsetInfo.cpp:988 src/insets/InsetInfo.cpp:1005
 msgid "yes"
 msgstr "ja"
 
-#: src/insets/InsetInfo.cpp:962 src/insets/InsetInfo.cpp:979
+#: src/insets/InsetInfo.cpp:991 src/insets/InsetInfo.cpp:1008
 msgid "no"
 msgstr "nein"
 
-#: src/insets/InsetInfo.cpp:1002
+#: src/insets/InsetInfo.cpp:1031
 #, c-format
 msgid "Can't determine menu entry for action %1$s in batch mode"
 msgstr ""
 "Der Menüeintrag für den Befehl %1$s kann im Batch-Mode nicht bestimmt werden"
 
-#: src/insets/InsetInfo.cpp:1010
+#: src/insets/InsetInfo.cpp:1039
 #, c-format
 msgid "No menu entry for action %1$s"
 msgstr "Kein Menüeintrag für die Aktion %1$s"
 
-#: src/insets/InsetInfo.cpp:1135
+#: src/insets/InsetInfo.cpp:1164
 #, c-format
 msgid "%1$s[[vcs data]] unknown"
 msgstr "%1$s unbekannt"
@@ -36819,7 +36828,7 @@ msgstr "Beschreibung: "
 msgid "Sorting: "
 msgstr "Sortierung: "
 
-#: src/insets/InsetNote.cpp:252
+#: src/insets/InsetNote.cpp:269
 msgid "note"
 msgstr "Notiz"
 
@@ -36867,51 +36876,51 @@ msgstr "%1$sText"
 msgid "text%1$s"
 msgstr "Text%1$s"
 
-#: src/insets/InsetRef.cpp:597
+#: src/insets/InsetRef.cpp:599
 msgid "Ref"
 msgstr "Querverweis"
 
-#: src/insets/InsetRef.cpp:598
+#: src/insets/InsetRef.cpp:600
 msgid "EqRef"
 msgstr "(Querverweis)"
 
-#: src/insets/InsetRef.cpp:599 src/mathed/InsetMathRef.cpp:373
+#: src/insets/InsetRef.cpp:601 src/mathed/InsetMathRef.cpp:373
 msgid "Page Number"
 msgstr "Seitennummer"
 
-#: src/insets/InsetRef.cpp:600 src/mathed/InsetMathRef.cpp:374
+#: src/insets/InsetRef.cpp:602 src/mathed/InsetMathRef.cpp:374
 msgid "Textual Page Number"
 msgstr "Seitennummer in Textform"
 
-#: src/insets/InsetRef.cpp:600
+#: src/insets/InsetRef.cpp:602
 msgid "TextPage"
 msgstr "TextSeite"
 
-#: src/insets/InsetRef.cpp:601 src/mathed/InsetMathRef.cpp:375
+#: src/insets/InsetRef.cpp:603 src/mathed/InsetMathRef.cpp:375
 msgid "Standard+Textual Page"
 msgstr "Standard+Seite in Textform"
 
-#: src/insets/InsetRef.cpp:601
+#: src/insets/InsetRef.cpp:603
 msgid "Ref+Text"
 msgstr "Querverweis+Text"
 
-#: src/insets/InsetRef.cpp:602 src/mathed/InsetMathRef.cpp:377
+#: src/insets/InsetRef.cpp:604 src/mathed/InsetMathRef.cpp:377
 msgid "Reference to Name"
 msgstr "Referenz auf Namen"
 
-#: src/insets/InsetRef.cpp:602
+#: src/insets/InsetRef.cpp:604
 msgid "NameRef"
 msgstr "Namen-Querverweis"
 
-#: src/insets/InsetRef.cpp:603
+#: src/insets/InsetRef.cpp:605
 msgid "Formatted"
 msgstr "Formatiert"
 
-#: src/insets/InsetRef.cpp:603
+#: src/insets/InsetRef.cpp:605
 msgid "Format"
 msgstr "Format"
 
-#: src/insets/InsetRef.cpp:604 src/mathed/InsetMathRef.cpp:378
+#: src/insets/InsetRef.cpp:606 src/mathed/InsetMathRef.cpp:378
 msgid "Label Only"
 msgstr "Nur Marke"
 
@@ -36985,11 +36994,11 @@ msgstr "Geschützter horizontaler Abstand (%1$s)"
 msgid "Unknown TOC type"
 msgstr "Unbekannter Inhaltsverzeichnis-Typ"
 
-#: src/insets/InsetTabular.cpp:464
+#: src/insets/InsetTabular.cpp:467
 msgid "Change tracking data incomplete"
 msgstr "Unvollständige Daten für Änderungsmarkierung"
 
-#: src/insets/InsetTabular.cpp:465
+#: src/insets/InsetTabular.cpp:468
 msgid ""
 "Change tracking information for tabular row/column is incomplete. I will "
 "ignore this."
@@ -36997,15 +37006,15 @@ msgstr ""
 "Die Informationen für die Änderungen von Tabellenzeilen- oder -spalten sind "
 "unvollständig. Sie werden ignoriert."
 
-#: src/insets/InsetTabular.cpp:5607
+#: src/insets/InsetTabular.cpp:5636
 msgid "Column movement not supported with multi-columns."
 msgstr "Verschieben von Spalten mit Mehrfachspalten leider nicht möglich."
 
-#: src/insets/InsetTabular.cpp:5625
+#: src/insets/InsetTabular.cpp:5654
 msgid "Row movement not supported with multi-rows."
 msgstr "Verschieben von Zeilen mit Mehrfachzeilen leider nicht möglich."
 
-#: src/insets/InsetTabular.cpp:6127
+#: src/insets/InsetTabular.cpp:6175
 msgid "Selection size should match clipboard content."
 msgstr ""
 "Die Anzahl der ausgewählten Zellen stimmt nicht mit dem Inhalt der "
@@ -37013,15 +37022,15 @@ msgstr ""
 
 # , c-format
 # , c-format
-#: src/insets/InsetText.cpp:1380
+#: src/insets/InsetText.cpp:1381
 msgid "[contains tracked changes]"
 msgstr "[enthält verfolgte Änderungen]"
 
-#: src/insets/InsetWrap.cpp:68
+#: src/insets/InsetWrap.cpp:64
 msgid "Wrap: "
 msgstr "Umflossenes Gleitobjekt: "
 
-#: src/insets/InsetWrap.cpp:201
+#: src/insets/InsetWrap.cpp:197
 msgid "wrap"
 msgstr "Umflossenes Gleitobjekt"
 
@@ -37081,15 +37090,15 @@ msgstr "Vorschau bereit"
 msgid "Preview failed"
 msgstr "Die Vorschau ist fehlgeschlagen"
 
-#: src/lyxfind.cpp:268
+#: src/lyxfind.cpp:275
 msgid "Search error"
 msgstr "Fehler beim Suchen"
 
-#: src/lyxfind.cpp:268
+#: src/lyxfind.cpp:275
 msgid "Search string is empty"
 msgstr "Die Such-Zeichenkette ist leer"
 
-#: src/lyxfind.cpp:300
+#: src/lyxfind.cpp:307
 msgid ""
 "The search string matches the selection, and search is limited to "
 "selection.\n"
@@ -37099,11 +37108,11 @@ msgstr ""
 "Suche ist auf die Auswahl begrenzt.\n"
 "Außerhalb weitersuchen?"
 
-#: src/lyxfind.cpp:302 src/lyxfind.cpp:329
+#: src/lyxfind.cpp:309 src/lyxfind.cpp:336
 msgid "Search outside selection?"
 msgstr "Außerhalb der Auswahl suchen?"
 
-#: src/lyxfind.cpp:327
+#: src/lyxfind.cpp:334
 msgid ""
 "The search string was not found within the selection.\n"
 "Continue search outside?"
@@ -37111,7 +37120,7 @@ msgstr ""
 "Der gesuchte Ausdruck wurde innerhalb der Auswahl nicht gefunden.\n"
 "Außerhalb weitersuchen?"
 
-#: src/lyxfind.cpp:345 src/lyxfind.cpp:691
+#: src/lyxfind.cpp:352 src/lyxfind.cpp:698
 msgid ""
 "End of file reached while searching forward.\n"
 "Continue searching from the beginning?"
@@ -37119,7 +37128,7 @@ msgstr ""
 "Das Ende des Dokuments wurde bei der Vorwärtssuche erreicht.\n"
 "Suche am Anfang fortsetzen?"
 
-#: src/lyxfind.cpp:348 src/lyxfind.cpp:719
+#: src/lyxfind.cpp:355 src/lyxfind.cpp:726
 msgid ""
 "Beginning of file reached while searching backward.\n"
 "Continue searching from the end?"
@@ -37127,62 +37136,62 @@ msgstr ""
 "Der Anfang des Dokuments wurde bei der Rückwärtssuche erreicht.\n"
 "Suche am Ende fortsetzen?"
 
-#: src/lyxfind.cpp:364
+#: src/lyxfind.cpp:371
 msgid "Search reached end of document, continuing from beginning."
 msgstr "Das Ende des Dokuments wurde erreicht, suche vom Anfang ab weiter."
 
-#: src/lyxfind.cpp:365
+#: src/lyxfind.cpp:372
 msgid "Search reached beginning of document, continuing from end."
 msgstr "Der Anfang des Dokuments wurde erreicht, suche vom Ende ab weiter."
 
-#: src/lyxfind.cpp:664
+#: src/lyxfind.cpp:671
 msgid "String not found in selection."
 msgstr "Der gesuchte Ausdruck wurde in der Auswahl nicht gefunden."
 
-#: src/lyxfind.cpp:666
+#: src/lyxfind.cpp:673
 msgid "String not found."
 msgstr "Die Zeichenkette wurde nicht gefunden."
 
-#: src/lyxfind.cpp:669
+#: src/lyxfind.cpp:676
 msgid "String found."
 msgstr "Zeichenkette gefunden."
 
-#: src/lyxfind.cpp:671
+#: src/lyxfind.cpp:678
 msgid "String has been replaced."
 msgstr "Die Zeichenkette wurde ersetzt."
 
-#: src/lyxfind.cpp:674
+#: src/lyxfind.cpp:681
 #, c-format
 msgid "%1$d strings have been replaced in the selection."
 msgstr "%1$d Zeichenketten wurden in der Auswahl ersetzt."
 
-#: src/lyxfind.cpp:675
+#: src/lyxfind.cpp:682
 #, c-format
 msgid "%1$d strings have been replaced."
 msgstr "%1$d Zeichenketten wurden ersetzt."
 
-#: src/lyxfind.cpp:4508
+#: src/lyxfind.cpp:4683
 msgid "One match has been replaced."
 msgstr "Ein Treffer wurde ersetzt."
 
-#: src/lyxfind.cpp:4511
+#: src/lyxfind.cpp:4686
 msgid "Two matches have been replaced."
 msgstr "Zwei Treffer wurden ersetzt."
 
-#: src/lyxfind.cpp:4514
+#: src/lyxfind.cpp:4689
 #, c-format
 msgid "%1$d matches have been replaced."
 msgstr "%1$d Treffer wurden ersetzt."
 
-#: src/lyxfind.cpp:4520
+#: src/lyxfind.cpp:4695
 msgid "Match not found."
 msgstr "Die Zeichenkette wurde nicht gefunden!"
 
-#: src/lyxfind.cpp:4526
+#: src/lyxfind.cpp:4701
 msgid "Match has been replaced."
 msgstr "Die Zeichenkette wurde ersetzt."
 
-#: src/lyxfind.cpp:4528
+#: src/lyxfind.cpp:4703
 msgid "Match found."
 msgstr "Die Zeichenkette wurde gefunden!"
 
@@ -37303,19 +37312,19 @@ msgstr "Mathe-Makro: \\%1$s"
 msgid "Invalid macro! \\%1$s"
 msgstr "Ungültiges Makro! \\%1$s"
 
-#: src/mathed/InsetMathNest.cpp:1018
+#: src/mathed/InsetMathNest.cpp:1024
 msgid "create new math text environment ($...$)"
 msgstr "Neue Mathe-Textumgebung erzeugen ($...$)"
 
-#: src/mathed/InsetMathNest.cpp:1021
+#: src/mathed/InsetMathNest.cpp:1027
 msgid "entered math text mode (textrm)"
 msgstr "Mathe-Textmodus betreten (textrm)"
 
-#: src/mathed/InsetMathNest.cpp:1043
+#: src/mathed/InsetMathNest.cpp:1049
 msgid "Regular expression editor mode"
 msgstr "Bearbeitungsmodus für reguläre Ausdrücke"
 
-#: src/mathed/InsetMathNest.cpp:1948
+#: src/mathed/InsetMathNest.cpp:1954
 #, c-format
 msgid "Cannot apply %1$s here."
 msgstr "%1$s kann hier nicht angewendet werden."
@@ -37379,11 +37388,11 @@ msgstr ""
 "Das angegebene Dokument %1$s\n"
 "konnte nicht geöffnet werden."
 
-#: src/output_latex.cpp:1658
+#: src/output_latex.cpp:1662
 msgid "Error in latexParagraphs"
 msgstr "Fehler in latexParagraphs"
 
-#: src/output_latex.cpp:1659
+#: src/output_latex.cpp:1663
 #, c-format
 msgid ""
 "You are using at least one layout (%1$s) intended for the title, after using "
@@ -37530,111 +37539,111 @@ msgstr "Lesen der Konfigurationsdateien"
 msgid "Custom keyboard definition"
 msgstr "Eigene Tastaturdefinition"
 
-#: src/support/debug.cpp:50
-msgid "LaTeX generation/execution"
-msgstr "LaTeX-Erzeugung/Ausführung"
+#: src/support/debug.cpp:50 src/support/debug.cpp:51
+msgid "Output source file generation/processing"
+msgstr "Erzeugung/Verarbeitung der Ausgabequelldatei"
 
-#: src/support/debug.cpp:51
+#: src/support/debug.cpp:52
 msgid "Math editor"
 msgstr "Mathe-Editor"
 
-#: src/support/debug.cpp:52
+#: src/support/debug.cpp:53
 msgid "Font handling"
 msgstr "Schrift-Handhabung"
 
-#: src/support/debug.cpp:53
+#: src/support/debug.cpp:54
 msgid "Textclass files reading"
 msgstr "Lesen der Textklassen-Dateien"
 
-#: src/support/debug.cpp:54
+#: src/support/debug.cpp:55
 msgid "Version control"
 msgstr "Versionskontrolle"
 
-#: src/support/debug.cpp:55
+#: src/support/debug.cpp:56
 msgid "External control interface"
 msgstr "Externe Kontroll-Schnittstelle"
 
-#: src/support/debug.cpp:56
+#: src/support/debug.cpp:57
 msgid "Undo/Redo mechanism"
 msgstr "Undo/Redo-Mechanismus"
 
-#: src/support/debug.cpp:57
+#: src/support/debug.cpp:58
 msgid "User commands"
 msgstr "Benutzerbefehle"
 
-#: src/support/debug.cpp:58
+#: src/support/debug.cpp:59
 msgid "The LyX Lexer"
 msgstr "Der LyX-Lexxer"
 
-#: src/support/debug.cpp:59
+#: src/support/debug.cpp:60
 msgid "Dependency information"
 msgstr "Informationen zu Abhängigkeiten"
 
-#: src/support/debug.cpp:60
+#: src/support/debug.cpp:61
 msgid "LyX Insets"
 msgstr "LyX-Einfügungen"
 
-#: src/support/debug.cpp:61
+#: src/support/debug.cpp:62
 msgid "Files used by LyX"
 msgstr "Von LyX verwendete Dateien"
 
-#: src/support/debug.cpp:62
+#: src/support/debug.cpp:63
 msgid "Workarea events"
 msgstr "Ereignisse im Arbeitsbereich"
 
-#: src/support/debug.cpp:63
+#: src/support/debug.cpp:64
 msgid "Clipboard handling"
 msgstr "Zwischenablage"
 
-#: src/support/debug.cpp:64
+#: src/support/debug.cpp:65
 msgid "Graphics conversion and loading"
 msgstr "Laden und Konvertierung einer Grafik"
 
-#: src/support/debug.cpp:65
+#: src/support/debug.cpp:66
 msgid "Change tracking"
 msgstr "Änderungsverfolgung"
 
-#: src/support/debug.cpp:66
+#: src/support/debug.cpp:67
 msgid "External template/inset messages"
 msgstr "Externe Vorlagen/Einfügungs-Meldungen"
 
-#: src/support/debug.cpp:67
+#: src/support/debug.cpp:68
 msgid "RowPainter profiling"
 msgstr "RowPainter-Profiling"
 
-#: src/support/debug.cpp:68
+#: src/support/debug.cpp:69
 msgid "Scrolling debugging"
 msgstr "Fehlersuche mit Scrolling"
 
-#: src/support/debug.cpp:69
+#: src/support/debug.cpp:70
 msgid "Math macros"
 msgstr "Mathe-Makros"
 
-#: src/support/debug.cpp:70
+#: src/support/debug.cpp:71
 msgid "RTL/Bidi"
 msgstr "RTL/Bidi"
 
-#: src/support/debug.cpp:71
+#: src/support/debug.cpp:72
 msgid "Locale/Internationalisation"
 msgstr "Spracheinstellungen/Internationalisierung"
 
-#: src/support/debug.cpp:72
+#: src/support/debug.cpp:73
 msgid "Selection copy/paste mechanism"
 msgstr "Auswahl kopieren/einfügen Mechanismus"
 
-#: src/support/debug.cpp:73
+#: src/support/debug.cpp:74
 msgid "Find and replace mechanism"
 msgstr "Mechanismus für Suchen und Ersetzen"
 
-#: src/support/debug.cpp:74
+#: src/support/debug.cpp:75
 msgid "Developers' general debug messages"
 msgstr "Allgemeine Testmeldungen der Entwickler"
 
-#: src/support/debug.cpp:75 src/support/debug.cpp:76
+#: src/support/debug.cpp:76 src/support/debug.cpp:77
 msgid "All debugging messages"
 msgstr "Alle Testmeldungen"
 
-#: src/support/debug.cpp:183
+#: src/support/debug.cpp:184
 #, c-format
 msgid "Debugging `%1$s' (%2$s)"
 msgstr "Testen von ,%1$s` (%2$s)"
@@ -37772,6 +37781,15 @@ msgstr ""
 msgid "Unknown user"
 msgstr "Unbekannter Benutzer"
 
+#~ msgid "foot"
+#~ msgstr "Fußnote"
+
+#~ msgid "Set all lines"
+#~ msgstr "Alle Linien setzen"
+
+#~ msgid "LaTeX generation/execution"
+#~ msgstr "LaTeX-Erzeugung/Ausführung"
+
 #~ msgid "Running MakeIndex for nomencl."
 #~ msgstr "MakeIndex wird für nomencl ausgeführt."
 

commit 5ac8a0b9ae4d04b5539a29f564571db2bddde6e7
Author: Pavel Sanda <sanda at lyx.org>
Date:   Wed Apr 13 11:36:49 2022 +0200

    Update status of layouttranslations

diff --git a/lib/layouttranslations.review b/lib/layouttranslations.review
index d44271e..1e81a98 100644
--- a/lib/layouttranslations.review
+++ b/lib/layouttranslations.review
@@ -22,12 +22,12 @@ ro sr
 (30.11.2017, LyX 2.3.0 release )
 Additionally to the top ones, these languages should be reviewed for the following strings
 "List of Listings"
-bg ca da es fi gl he ko nb nn pl ro sl sr tr zh_CN zh_TW
+ca da es fi gl he ko nb nn pl ro sl sr tr zh_CN zh_TW
 
 "Nomenclature[[output]]" -> The string that is output to PDF for the nomenclature list
 "see equation[[nomencl]]"
 "page[[nomencl]]"
-bg ca da fi gl he ja ko nb nn pl ro sl sr tr zh_CN zh_TW
+ca da fi gl he ja ko nb nn pl ro sl sr tr zh_CN zh_TW
 
 -----
 LyX 2.4.0 release
@@ -35,7 +35,7 @@ LyX 2.4.0 release
 "Notes[[Endnotes]]" -> The header string of endnotes (with "Endnotes (Basic)" and "Footnotes as Endnotes
 (Basic)" modules). This is to be distinguished from "Notes" used by the Notes inset (which is more an
 annotation than a list of (end)notes)
-ar bg cs el en es eu fi fr he hu ja nb nl nn pl pt_BR pt_PT sv tr uk zh_CN zh_TW
+ar cs el en es eu fi fr he hu ja nb nl nn pl pt_BR pt_PT sv tr uk zh_CN zh_TW
 Note that the localized enotez package has the following translations that probably should be used:
 Catalan: Notes
 Croatian: Bilje\v{s}ke

commit 968379b6444e05b1efc2657eadb26102c6a9b866
Author: Pavel Sanda <sanda at lyx.org>
Date:   Wed Apr 13 11:33:28 2022 +0200

    Backport bg strings

diff --git a/po/bg.po b/po/bg.po
index 8a470b3..4d805ef 100644
--- a/po/bg.po
+++ b/po/bg.po
@@ -7598,7 +7598,7 @@ msgstr "Резюме"
 #: lib/layouts/theorems-ams-extended.module:348
 #: lib/layouts/theorems-counters-extended-bytype.inc:28
 msgid "Acknowledgement"
-msgstr "Благодарност"
+msgstr "Благодарности"
 
 #: lib/layouts/AEA.layout:131 lib/layouts/egs.layout:627
 #: lib/layouts/theorems-ams-extended-bytype.module:349
@@ -8207,7 +8207,7 @@ msgstr "Решение \\thesolution."
 #: lib/layouts/theorems-ams-extended.module:308
 #: lib/layouts/theorems-counters-extended-bytype.inc:25 lib/examples/Articles:0
 msgid "Summary"
-msgstr "обобщение"
+msgstr "Обобщение"
 
 # src/ext_l10n.h:191
 #: lib/layouts/AEA.layout:333 src/frontends/qt/Menus.cpp:1803
@@ -11140,7 +11140,7 @@ msgstr "Дефиниция"
 #: lib/layouts/theorems-without-preamble.inc:469
 #: lib/layouts/theorems-without-preamble.inc:472
 msgid "Note"
-msgstr "бележка"
+msgstr "Бележка"
 
 # src/ext_l10n.h:175
 #: lib/layouts/apax.inc:323
@@ -13957,7 +13957,7 @@ msgstr "Бележка в края"
 #: lib/layouts/foottoend.module:20 lib/layouts/foottoend.module:23
 #: lib/layouts/memoir.layout:319 lib/layouts/memoir.layout:322
 msgid "Notes[[Endnotes]]"
-msgstr "Бележки в края"
+msgstr "Бележки"
 
 # src/ext_l10n.h:438
 #: lib/layouts/enotez.module:2

commit 8471b97fd4fcb40573531187de9c9422abc89415
Author: Pavel Sanda <sanda at lyx.org>
Date:   Wed Apr 13 11:32:45 2022 +0200

    * layouttranslations updates from Veselin

diff --git a/lib/layouttranslations b/lib/layouttranslations
index 5d6d3c1..6825a61 100644
--- a/lib/layouttranslations
+++ b/lib/layouttranslations
@@ -53,7 +53,7 @@ Translation ar
 End
 
 Translation bg
-	"Acknowledgement" "Благодарност"
+	"Acknowledgement" "Благодарности"
 	"Algorithm" "Aлгоритъм"
 	"Assumption" "Допускане"
 	"Axiom" "Аксиома"
@@ -81,8 +81,8 @@ Translation bg
 	"Listings[[List of Listings]]" "Списъци"
 	"Nomenclature[[output]]" "Речник на означенията"
 	"Notation" "Означение"
-	"Note" "бележка"
-	"Notes[[Endnotes]]" "Бележки в края"
+	"Note" "Бележка"
+	"Notes[[Endnotes]]" "Бележки"
 	"Problem" "Задача"
 	"Proof" "Доказателство"
 	"Property" "Своиство"
@@ -91,7 +91,7 @@ Translation bg
 	"Remark" "Забележка"
 	"Scheme" "Чертеж"
 	"Solution" "Решение"
-	"Summary" "обобщение"
+	"Summary" "Обобщение"
 	"Tableau" "Таблица"
 	"Theorem" "Теорема"
 	"page[[nomencl]]" "стр."

commit c2229d388b622a65029d0566f5eca53b43d92528
Author: Kornel Benko <kornel at lyx.org>
Date:   Tue Apr 12 18:02:12 2022 +0200

    Find: Renamend for_searchAdv to for_serach in src/OutputParams.h
    
    Since this variable is used by quick find too, the naming was misleading

diff --git a/src/OutputParams.h b/src/OutputParams.h
index 65a58e5..64ab2f3 100644
--- a/src/OutputParams.h
+++ b/src/OutputParams.h
@@ -433,7 +433,7 @@ public:
 		SearchNonOutput = 8
 	};
 		
-	int for_searchAdv = NoSearch;
+	int for_search = NoSearch;
 
 	/// Are we generating this material for instant preview?
 	bool for_preview = false;
diff --git a/src/Paragraph.cpp b/src/Paragraph.cpp
index 7746597..434e515 100644
--- a/src/Paragraph.cpp
+++ b/src/Paragraph.cpp
@@ -1209,10 +1209,10 @@ void Paragraph::Private::latexSpecialChar(otexstream & os,
 {
 	char_type const c = owner_->getUChar(bparams, runparams, i);
 
-	if (style.pass_thru || runparams.pass_thru || (runparams.for_searchAdv != OutputParams::NoSearch)
+	if (style.pass_thru || runparams.pass_thru || (runparams.for_search != OutputParams::NoSearch)
 	    || contains(style.pass_thru_chars, c)
 	    || contains(runparams.pass_thru_chars, c)) {
-		if (runparams.for_searchAdv != OutputParams::NoSearch) {
+		if (runparams.for_search != OutputParams::NoSearch) {
 			if (c == '\\')
 				os << "\\\\";
 			else if (c == '{')
@@ -2640,10 +2640,10 @@ void Paragraph::latex(BufferParams const & bparams,
 
 		// Check whether a display math inset follows
 		bool output_changes;
-		if (runparams.for_searchAdv == OutputParams::NoSearch)
+		if (runparams.for_search == OutputParams::NoSearch)
 			output_changes = bparams.output_changes;
 		else
-			output_changes = ((runparams.for_searchAdv & OutputParams::SearchWithDeleted) != 0);
+			output_changes = ((runparams.for_search & OutputParams::SearchWithDeleted) != 0);
 		if (c == META_INSET
 		    && i >= start_pos && (end_pos == -1 || i < end_pos)) {
 			if (isDeleted(i))
@@ -4586,7 +4586,7 @@ int Paragraph::find(docstring const & str, bool cs, bool mw,
 			odocstringstream os;
 			if (inset->lyxCode() == lyx::QUOTE_CODE) {
 				OutputParams op(0);
-				op.for_searchAdv = OutputParams::SearchQuick;
+				op.for_search = OutputParams::SearchQuick;
 				inset->plaintext(os, op);
 			}
 			else {
diff --git a/src/insets/InsetBibtex.cpp b/src/insets/InsetBibtex.cpp
index 5f6b967..4e02b62 100644
--- a/src/insets/InsetBibtex.cpp
+++ b/src/insets/InsetBibtex.cpp
@@ -983,7 +983,7 @@ int InsetBibtex::plaintext(odocstringstream & os,
 	// We could output more information here, e.g., what databases are included
 	// and information about options. But I don't necessarily see any reason to
 	// do this right now.
-	if (op.for_tooltip || op.for_toc || op.for_searchAdv != OutputParams::NoSearch) {
+	if (op.for_tooltip || op.for_toc || op.for_search != OutputParams::NoSearch) {
 		os << '[' << reflabel << ']' << '\n';
 		return PLAINTEXT_NEWLINE;
 	}
diff --git a/src/insets/InsetBranch.cpp b/src/insets/InsetBranch.cpp
index 2b60ca6..7a102ce 100644
--- a/src/insets/InsetBranch.cpp
+++ b/src/insets/InsetBranch.cpp
@@ -314,7 +314,7 @@ bool InsetBranch::producesOutput() const
 
 void InsetBranch::latex(otexstream & os, OutputParams const & runparams) const
 {
-	if (producesOutput() || ((runparams.for_searchAdv & OutputParams::SearchNonOutput) != 0)) {
+	if (producesOutput() || ((runparams.for_search & OutputParams::SearchNonOutput) != 0)) {
 		OutputParams rp = runparams;
 		rp.inbranch = true;
 		InsetText::latex(os, rp);
@@ -328,7 +328,7 @@ void InsetBranch::latex(otexstream & os, OutputParams const & runparams) const
 int InsetBranch::plaintext(odocstringstream & os,
 			   OutputParams const & runparams, size_t max_length) const
 {
-	if (!producesOutput() && ((runparams.for_searchAdv & OutputParams::SearchNonOutput) == 0))
+	if (!producesOutput() && ((runparams.for_search & OutputParams::SearchNonOutput) == 0))
 		return 0;
 
 	int len = InsetText::plaintext(os, runparams, max_length);
diff --git a/src/insets/InsetInclude.cpp b/src/insets/InsetInclude.cpp
index 30eacd7..9ee08a3 100644
--- a/src/insets/InsetInclude.cpp
+++ b/src/insets/InsetInclude.cpp
@@ -1006,14 +1006,14 @@ int InsetInclude::plaintext(odocstringstream & os,
 {
 	// just write the filename if we're making a tooltip or toc entry,
 	// or are generating this for advanced search
-	if (op.for_tooltip || op.for_toc || op.for_searchAdv != OutputParams::NoSearch) {
+	if (op.for_tooltip || op.for_toc || op.for_search != OutputParams::NoSearch) {
 		os << '[' << screenLabel() << '\n'
 		   << ltrim(getParam("filename")) << "\n]";
 		return PLAINTEXT_NEWLINE + 1; // one char on a separate line
 	}
 
 	if (isVerbatim(params()) || isListings(params())) {
-		if (op.for_searchAdv != OutputParams::NoSearch) {
+		if (op.for_search != OutputParams::NoSearch) {
 			os << '[' << screenLabel() << ']';
 		}
 		else {
diff --git a/src/insets/InsetIndex.cpp b/src/insets/InsetIndex.cpp
index fe0890c..8622263 100644
--- a/src/insets/InsetIndex.cpp
+++ b/src/insets/InsetIndex.cpp
@@ -85,7 +85,7 @@ void InsetIndex::latex(otexstream & ios, OutputParams const & runparams_in) cons
 	odocstringstream ourlatex;
 	otexstream ots(ourlatex);
 	InsetText::latex(ots, runparams);
-	if (runparams.for_searchAdv != OutputParams::NoSearch) {
+	if (runparams.for_search != OutputParams::NoSearch) {
 		// No need for special handling, if we are only searching for some patterns
 		os << ourlatex.str() << "}";
 		return;
diff --git a/src/insets/InsetNote.cpp b/src/insets/InsetNote.cpp
index 0324ca8..45d89d0 100644
--- a/src/insets/InsetNote.cpp
+++ b/src/insets/InsetNote.cpp
@@ -207,12 +207,12 @@ bool InsetNote::isMacroScope() const
 void InsetNote::latex(otexstream & os, OutputParams const & runparams_in) const
 {
 	if (params_.type != InsetNoteParams::Greyedout
-	    && runparams_in.for_searchAdv != OutputParams::NoSearch
-	    && (runparams_in.for_searchAdv & OutputParams::SearchNonOutput) == 0)
+	    && runparams_in.for_search != OutputParams::NoSearch
+	    && (runparams_in.for_search & OutputParams::SearchNonOutput) == 0)
 		return;
 
 	if (params_.type == InsetNoteParams::Note) {
-		if ((runparams_in.for_searchAdv & OutputParams::SearchNonOutput) != 0) {
+		if ((runparams_in.for_search & OutputParams::SearchNonOutput) != 0) {
 			OutputParams runparams(runparams_in);
 			InsetCollapsible::latex(os, runparams);
 			runparams_in.encoding = runparams.encoding;
@@ -251,11 +251,11 @@ void InsetNote::latex(otexstream & os, OutputParams const & runparams_in) const
 int InsetNote::plaintext(odocstringstream & os,
 			 OutputParams const & runparams_in, size_t max_length) const
 {
-	if ((runparams_in.for_searchAdv & OutputParams::SearchNonOutput) == 0) {
+	if ((runparams_in.for_search & OutputParams::SearchNonOutput) == 0) {
 		if (params_.type == InsetNoteParams::Note)
 			return 0;
 		else if (params_.type == InsetNoteParams::Comment
-		    && (runparams_in.for_searchAdv != OutputParams::NoSearch))
+		    && (runparams_in.for_search != OutputParams::NoSearch))
 			return 0;
 	}
 
@@ -265,10 +265,10 @@ int InsetNote::plaintext(odocstringstream & os,
 		// Ignore files that are exported inside a comment
 		runparams.exportdata.reset(new ExportData);
 	}
-	if ((runparams_in.for_searchAdv & OutputParams::SearchNonOutput) == 0)
+	if ((runparams_in.for_search & OutputParams::SearchNonOutput) == 0)
 		os << '[' << buffer().B_("note") << ":\n";
 	InsetText::plaintext(os, runparams, max_length);
-	if ((runparams_in.for_searchAdv & OutputParams::SearchNonOutput) == 0)
+	if ((runparams_in.for_search & OutputParams::SearchNonOutput) == 0)
 		os << "\n]";
 
 	return PLAINTEXT_NEWLINE + 1; // one char on a separate line
diff --git a/src/insets/InsetQuotes.cpp b/src/insets/InsetQuotes.cpp
index 67ad767..1882769 100644
--- a/src/insets/InsetQuotes.cpp
+++ b/src/insets/InsetQuotes.cpp
@@ -851,7 +851,7 @@ void InsetQuotes::latex(otexstream & os, OutputParams const & runparams) const
 	docstring qstr;
 
 	// In pass-thru context, we output plain quotes
-	if (runparams.pass_thru || runparams.for_searchAdv != OutputParams::NoSearch)
+	if (runparams.pass_thru || runparams.for_search != OutputParams::NoSearch)
 		qstr = (level_ == QuoteLevel::Primary) ? from_ascii("\"") : from_ascii("'");
 	else if (style == QuoteStyle::Plain && fontspec_) {
 		// For XeTeX and LuaTeX,we need to disable mapping to get straight
@@ -944,7 +944,7 @@ void InsetQuotes::latex(otexstream & os, OutputParams const & runparams) const
 int InsetQuotes::plaintext(odocstringstream & os,
         OutputParams const & op, size_t) const
 {
-	if (op.for_searchAdv == OutputParams::NoSearch) {
+	if (op.for_search == OutputParams::NoSearch) {
 		docstring const str = displayString();
 		os << str;
 		return str.size();
diff --git a/src/insets/InsetSpace.cpp b/src/insets/InsetSpace.cpp
index 1a2eb09..92d4c43 100644
--- a/src/insets/InsetSpace.cpp
+++ b/src/insets/InsetSpace.cpp
@@ -579,27 +579,27 @@ void InsetSpace::latex(otexstream & os, OutputParams const & runparams) const
 {
 	switch (params_.kind) {
 	case InsetSpaceParams::NORMAL:
-		os << (runparams.free_spacing && (runparams.for_searchAdv == OutputParams::NoSearch) ? " " : "\\ ");
+		os << (runparams.free_spacing && (runparams.for_search == OutputParams::NoSearch) ? " " : "\\ ");
 		break;
 	case InsetSpaceParams::PROTECTED:
 		if (runparams.local_font &&
 		    runparams.local_font->language()->lang() == "polutonikogreek")
 			// in babel's polutonikogreek, ~ is active
-			os << (runparams.free_spacing && (runparams.for_searchAdv == OutputParams::NoSearch) ? " " : "\\nobreakspace{}");
+			os << (runparams.free_spacing && (runparams.for_search == OutputParams::NoSearch) ? " " : "\\nobreakspace{}");
 		else
-			os << (runparams.free_spacing && (runparams.for_searchAdv == OutputParams::NoSearch) ? ' ' : '~');
+			os << (runparams.free_spacing && (runparams.for_search == OutputParams::NoSearch) ? ' ' : '~');
 		break;
 	case InsetSpaceParams::VISIBLE:
-		os << (runparams.free_spacing && (runparams.for_searchAdv == OutputParams::NoSearch) ? " " : "\\textvisiblespace{}");
+		os << (runparams.free_spacing && (runparams.for_search == OutputParams::NoSearch) ? " " : "\\textvisiblespace{}");
 		break;
 	case InsetSpaceParams::THIN:
-		if (runparams.for_searchAdv != OutputParams::NoSearch)
+		if (runparams.for_search != OutputParams::NoSearch)
 			os << "\\thinspace{}";
 		else
 			os << (runparams.free_spacing ? " " : "\\,");
 		break;
 	case InsetSpaceParams::MEDIUM:
-		if (runparams.for_searchAdv != OutputParams::NoSearch)
+		if (runparams.for_search != OutputParams::NoSearch)
 			os << "\\medspace{}";
 		else if (params_.math)
 			os << (runparams.free_spacing ? " " : "\\:");
@@ -607,7 +607,7 @@ void InsetSpace::latex(otexstream & os, OutputParams const & runparams) const
 			os << (runparams.free_spacing ? " " : "\\medspace{}");
 		break;
 	case InsetSpaceParams::THICK:
-		if (runparams.for_searchAdv != OutputParams::NoSearch)
+		if (runparams.for_search != OutputParams::NoSearch)
 			os << "\\thickspace{}";
 		else if (params_.math)
 			os << (runparams.free_spacing ? " " : "\\;");
@@ -615,49 +615,49 @@ void InsetSpace::latex(otexstream & os, OutputParams const & runparams) const
 			os << (runparams.free_spacing ? " " : "\\thickspace{}");
 		break;
 	case InsetSpaceParams::QUAD:
-		os << (runparams.free_spacing && (runparams.for_searchAdv != OutputParams::NoSearch) ? " " : "\\quad{}");
+		os << (runparams.free_spacing && (runparams.for_search != OutputParams::NoSearch) ? " " : "\\quad{}");
 		break;
 	case InsetSpaceParams::QQUAD:
-		os << (runparams.free_spacing && (runparams.for_searchAdv != OutputParams::NoSearch) ? " " : "\\qquad{}");
+		os << (runparams.free_spacing && (runparams.for_search != OutputParams::NoSearch) ? " " : "\\qquad{}");
 		break;
 	case InsetSpaceParams::ENSPACE:
-		os << (runparams.free_spacing && (runparams.for_searchAdv != OutputParams::NoSearch) ? " " : "\\enspace{}");
+		os << (runparams.free_spacing && (runparams.for_search != OutputParams::NoSearch) ? " " : "\\enspace{}");
 		break;
 	case InsetSpaceParams::ENSKIP:
-		os << (runparams.free_spacing && (runparams.for_searchAdv != OutputParams::NoSearch) ? " " : "\\enskip{}");
+		os << (runparams.free_spacing && (runparams.for_search != OutputParams::NoSearch) ? " " : "\\enskip{}");
 		break;
 	case InsetSpaceParams::NEGTHIN:
-		os << (runparams.free_spacing && (runparams.for_searchAdv != OutputParams::NoSearch) ? " " : "\\negthinspace{}");
+		os << (runparams.free_spacing && (runparams.for_search != OutputParams::NoSearch) ? " " : "\\negthinspace{}");
 		break;
 	case InsetSpaceParams::NEGMEDIUM:
-		os << (runparams.free_spacing && (runparams.for_searchAdv != OutputParams::NoSearch) ? " " : "\\negmedspace{}");
+		os << (runparams.free_spacing && (runparams.for_search != OutputParams::NoSearch) ? " " : "\\negmedspace{}");
 		break;
 	case InsetSpaceParams::NEGTHICK:
-		os << (runparams.free_spacing && (runparams.for_searchAdv != OutputParams::NoSearch) ? " " : "\\negthickspace{}");
+		os << (runparams.free_spacing && (runparams.for_search != OutputParams::NoSearch) ? " " : "\\negthickspace{}");
 		break;
 	case InsetSpaceParams::HFILL:
-		os << (runparams.free_spacing && (runparams.for_searchAdv != OutputParams::NoSearch) ? " " : "\\hfill{}");
+		os << (runparams.free_spacing && (runparams.for_search != OutputParams::NoSearch) ? " " : "\\hfill{}");
 		break;
 	case InsetSpaceParams::HFILL_PROTECTED:
-		os << (runparams.free_spacing && (runparams.for_searchAdv != OutputParams::NoSearch) ? " " : "\\hspace*{\\fill}");
+		os << (runparams.free_spacing && (runparams.for_search != OutputParams::NoSearch) ? " " : "\\hspace*{\\fill}");
 		break;
 	case InsetSpaceParams::DOTFILL:
-		os << (runparams.free_spacing && (runparams.for_searchAdv != OutputParams::NoSearch) ? " " : "\\dotfill{}");
+		os << (runparams.free_spacing && (runparams.for_search != OutputParams::NoSearch) ? " " : "\\dotfill{}");
 		break;
 	case InsetSpaceParams::HRULEFILL:
-		os << (runparams.free_spacing && (runparams.for_searchAdv != OutputParams::NoSearch) ? " " : "\\hrulefill{}");
+		os << (runparams.free_spacing && (runparams.for_search != OutputParams::NoSearch) ? " " : "\\hrulefill{}");
 		break;
 	case InsetSpaceParams::LEFTARROWFILL:
-		os << (runparams.free_spacing && (runparams.for_searchAdv != OutputParams::NoSearch) ? " " : "\\leftarrowfill{}");
+		os << (runparams.free_spacing && (runparams.for_search != OutputParams::NoSearch) ? " " : "\\leftarrowfill{}");
 		break;
 	case InsetSpaceParams::RIGHTARROWFILL:
-		os << (runparams.free_spacing && (runparams.for_searchAdv != OutputParams::NoSearch) ? " " : "\\rightarrowfill{}");
+		os << (runparams.free_spacing && (runparams.for_search != OutputParams::NoSearch) ? " " : "\\rightarrowfill{}");
 		break;
 	case InsetSpaceParams::UPBRACEFILL:
-		os << (runparams.free_spacing && (runparams.for_searchAdv != OutputParams::NoSearch) ? " " : "\\upbracefill{}");
+		os << (runparams.free_spacing && (runparams.for_search != OutputParams::NoSearch) ? " " : "\\upbracefill{}");
 		break;
 	case InsetSpaceParams::DOWNBRACEFILL:
-		os << (runparams.free_spacing && (runparams.for_searchAdv != OutputParams::NoSearch) ? " " : "\\downbracefill{}");
+		os << (runparams.free_spacing && (runparams.for_search != OutputParams::NoSearch) ? " " : "\\downbracefill{}");
 		break;
 	case InsetSpaceParams::CUSTOM:
 		if (runparams.free_spacing)
diff --git a/src/lyxfind.cpp b/src/lyxfind.cpp
index c3f2b77..6ef7cd3 100644
--- a/src/lyxfind.cpp
+++ b/src/lyxfind.cpp
@@ -1098,11 +1098,11 @@ static docstring buffer_to_latex(Buffer & buffer)
 	// No side effect of file copying and image conversion
 	runparams.dryrun = true;
 	if (ignoreFormats.getDeleted())
-		runparams.for_searchAdv = OutputParams::SearchWithoutDeleted;
+		runparams.for_search = OutputParams::SearchWithoutDeleted;
 	else
-		runparams.for_searchAdv = OutputParams::SearchWithDeleted;
+		runparams.for_search = OutputParams::SearchWithDeleted;
 	if (ignoreFormats.getNonContent()) {
-		runparams.for_searchAdv |= OutputParams::SearchNonOutput;
+		runparams.for_search |= OutputParams::SearchNonOutput;
 	}
 	pit_type const endpit = buffer.paragraphs().size();
 	for (pit_type pit = 0; pit != endpit; ++pit) {
@@ -1174,13 +1174,13 @@ static docstring stringifySearchBuffer(Buffer & buffer, FindAndReplaceOptions co
 		int option = AS_STR_INSETS |AS_STR_PLAINTEXT;
 		if (ignoreFormats.getDeleted()) {
 			option |= AS_STR_SKIPDELETE;
-			runparams.for_searchAdv = OutputParams::SearchWithoutDeleted;
+			runparams.for_search = OutputParams::SearchWithoutDeleted;
 		}
 		else {
-			runparams.for_searchAdv = OutputParams::SearchWithDeleted;
+			runparams.for_search = OutputParams::SearchWithDeleted;
 		}
 		if (ignoreFormats.getNonContent()) {
-			runparams.for_searchAdv |= OutputParams::SearchNonOutput;
+			runparams.for_search |= OutputParams::SearchNonOutput;
 		}
 		string t("");
 		for (pos_type pit = pos_type(0); pit < (pos_type)buffer.paragraphs().size(); ++pit) {
@@ -3952,13 +3952,13 @@ docstring stringifyFromCursor(DocIterator const & cur, int len)
 		int option = AS_STR_INSETS | AS_STR_PLAINTEXT;
 		if (ignoreFormats.getDeleted()) {
 			option |= AS_STR_SKIPDELETE;
-			runparams.for_searchAdv = OutputParams::SearchWithoutDeleted;
+			runparams.for_search = OutputParams::SearchWithoutDeleted;
 		}
 		else {
-			runparams.for_searchAdv = OutputParams::SearchWithDeleted;
+			runparams.for_search = OutputParams::SearchWithDeleted;
 		}
 		if (ignoreFormats.getNonContent()) {
-			runparams.for_searchAdv |= OutputParams::SearchNonOutput;
+			runparams.for_search |= OutputParams::SearchNonOutput;
 		}
 		LYXERR(Debug::FIND, "Stringifying with cur: "
 		       << cur << ", from pos: " << cur.pos() << ", end: " << end);
@@ -4006,13 +4006,13 @@ docstring latexifyFromCursor(DocIterator const & cur, int len)
 	// No side effect of file copying and image conversion
 	runparams.dryrun = true;
 	if (ignoreFormats.getDeleted()) {
-		runparams.for_searchAdv = OutputParams::SearchWithoutDeleted;
+		runparams.for_search = OutputParams::SearchWithoutDeleted;
 	}
 	else {
-		runparams.for_searchAdv = OutputParams::SearchWithDeleted;
+		runparams.for_search = OutputParams::SearchWithDeleted;
 	}
 	if (ignoreFormats.getNonContent()) {
-		runparams.for_searchAdv |= OutputParams::SearchNonOutput;
+		runparams.for_search |= OutputParams::SearchNonOutput;
 	}
 
 	if (cur.inTexted()) {
diff --git a/src/mathed/InsetMathHull.cpp b/src/mathed/InsetMathHull.cpp
index 805f84c..e266ec8 100644
--- a/src/mathed/InsetMathHull.cpp
+++ b/src/mathed/InsetMathHull.cpp
@@ -2359,7 +2359,7 @@ int InsetMathHull::plaintext(odocstringstream & os,
 	Encoding const * const enc = encodings.fromLyXName("utf8");
 
 	TeXMathStream::OutputType ot;
-	if (op.for_searchAdv == OutputParams::NoSearch)
+	if (op.for_search == OutputParams::NoSearch)
 		ot = TeXMathStream::wsDefault;
 	else
 		ot = TeXMathStream::wsSearchAdv;
diff --git a/src/mathed/InsetMathNest.cpp b/src/mathed/InsetMathNest.cpp
index 4f21924..d4759a0 100644
--- a/src/mathed/InsetMathNest.cpp
+++ b/src/mathed/InsetMathNest.cpp
@@ -359,7 +359,7 @@ void InsetMathNest::normalize(NormalStream & os) const
 void InsetMathNest::latex(otexstream & os, OutputParams const & runparams) const
 {
 	TeXMathStream::OutputType ot;
-	if (runparams.for_searchAdv != OutputParams::NoSearch)
+	if (runparams.for_search != OutputParams::NoSearch)
 		ot = TeXMathStream::wsSearchAdv;
 	else if (runparams.dryrun)
 		ot = TeXMathStream::wsDryrun;
diff --git a/src/output_latex.cpp b/src/output_latex.cpp
index 61537c8..358aae5 100644
--- a/src/output_latex.cpp
+++ b/src/output_latex.cpp
@@ -462,10 +462,10 @@ void TeXEnvironment(Buffer const & buf, Text const & text,
 		// Do not output empty environments if the whole paragraph has
 		// been deleted with ct and changes are not output.
 		bool output_changes;
-		if (runparams.for_searchAdv == OutputParams::NoSearch)
+		if (runparams.for_search == OutputParams::NoSearch)
 			output_changes = buf.params().output_changes;
 		else
-			output_changes = ((runparams.for_searchAdv & OutputParams::SearchWithDeleted) != 0);
+			output_changes = ((runparams.for_search & OutputParams::SearchWithDeleted) != 0);
 		if (size_t(pit + 1) < paragraphs.size()) {
 			ParagraphList::const_iterator nextpar = paragraphs.iterator_at(pit + 1);
 			Paragraph const & cpar = paragraphs.at(pit);
@@ -578,7 +578,7 @@ void getArgInsets(otexstream & os, OutputParams const & runparams, Layout::LaTeX
 			}
 		}
 	}
-	if ((runparams.for_searchAdv != OutputParams::NoSearch) && argnr > 1) {
+	if ((runparams.for_search != OutputParams::NoSearch) && argnr > 1) {
 		// Mark end of arguments for findadv() only
 		os << "\\endarguments{}";
 	}
@@ -746,7 +746,7 @@ void parStartCommand(Paragraph const & par, otexstream & os,
 		break;
 	case LATEX_ITEM_ENVIRONMENT:
 	case LATEX_LIST_ENVIRONMENT:
-		if (runparams.for_searchAdv != OutputParams::NoSearch) {
+		if (runparams.for_search != OutputParams::NoSearch) {
 			os << "\\" + style.itemcommand() << "{" << style.latexname() << "}";
 		}
 		else {
@@ -758,7 +758,7 @@ void parStartCommand(Paragraph const & par, otexstream & os,
 		}
 		break;
 	case LATEX_ENVIRONMENT:
-		if (runparams.for_searchAdv != OutputParams::NoSearch) {
+		if (runparams.for_search != OutputParams::NoSearch) {
 			os << "\\latexenvironment{" << style.latexname() << "}{";
 		}
 		break;
@@ -796,7 +796,7 @@ void TeXOnePar(Buffer const & buf,
 
 	// Do not output empty commands if the whole paragraph has
 	// been deleted with ct and changes are not output.
-	if (((runparams_in.for_searchAdv & OutputParams::SearchWithDeleted) == 0) && style.latextype != LATEX_ENVIRONMENT
+	if (((runparams_in.for_search & OutputParams::SearchWithDeleted) == 0) && style.latextype != LATEX_ENVIRONMENT
 	    && !par.empty() && par.isDeleted(0, par.size()) && !bparams.output_changes)
 		return;
 
@@ -936,7 +936,7 @@ void TeXOnePar(Buffer const & buf,
 	bool const have_prior_nptpar =
 			prior_nontitle_par && !prior_nontitle_par->isPassThru();
 	Language const * const prev_language =
-		runparams_in.for_searchAdv != OutputParams::NoSearch
+		runparams_in.for_search != OutputParams::NoSearch
 			? languages.getLanguage("ignore")
 			: (have_prior_nptpar)
 				? (use_prev_env_language 
@@ -988,7 +988,7 @@ void TeXOnePar(Buffer const & buf,
 		&& !(have_prior_nptpar
 		     && (prev_language->rightToLeft() != par_language->rightToLeft()));
 	bool const localswitch =
-			(runparams_in.for_searchAdv != OutputParams::NoSearch
+			(runparams_in.for_search != OutputParams::NoSearch
 			|| text.inset().forceLocalFontSwitch()
 			|| (using_begin_end && text.inset().forcePlainLayout())
 			|| in_polyglossia_rtl_env)
@@ -1003,7 +1003,7 @@ void TeXOnePar(Buffer const & buf,
 	bool const localswitch_needed = localswitch && par_lang != outer_lang;
 
 	// localswitches need to be closed and reopened at each par
-	if ((runparams_in.for_searchAdv != OutputParams::NoSearch) || ((par_lang != prev_lang || localswitch_needed)
+	if ((runparams_in.for_search != OutputParams::NoSearch) || ((par_lang != prev_lang || localswitch_needed)
 	     // check if we already put language command in TeXEnvironment()
 	     && !(style.isEnvironment()
 		  && (pit == 0 || (priorpar->layout() != par.layout()
@@ -1071,7 +1071,7 @@ void TeXOnePar(Buffer const & buf,
 			// With CJK, the CJK tag has to be closed first (see below)
 			if ((runparams.encoding->package() != Encoding::CJK
 				 || bparams.useNonTeXFonts
-				 || (runparams.for_searchAdv != OutputParams::NoSearch))
+				 || (runparams.for_search != OutputParams::NoSearch))
 			    && (par_lang != openLanguageName(state) || localswitch || intitle_command)
 			    && !par_lang.empty()) {
 				string bc = use_polyglossia ?
@@ -1312,7 +1312,7 @@ void TeXOnePar(Buffer const & buf,
 		// when the paragraph uses CJK, the language has to be closed earlier
 		if ((font.language()->encoding()->package() != Encoding::CJK)
 			|| bparams.useNonTeXFonts
-			|| (runparams_in.for_searchAdv != OutputParams::NoSearch)) {
+			|| (runparams_in.for_search != OutputParams::NoSearch)) {
 			if (lang_end_command.empty()) {
 				// If this is a child, we should restore the
 				// master language after the last paragraph.
@@ -1708,10 +1708,10 @@ void latexParagraphs(Buffer const & buf,
 		// Do not output empty environments if the whole paragraph has
 		// been deleted with ct and changes are not output.
 		bool output_changes;
-		if (runparams.for_searchAdv == OutputParams::NoSearch)
+		if (runparams.for_search == OutputParams::NoSearch)
 			output_changes = bparams.output_changes;
 		else
-			output_changes = ((runparams.for_searchAdv & OutputParams::SearchWithDeleted) != 0);
+			output_changes = ((runparams.for_search & OutputParams::SearchWithDeleted) != 0);
 		bool const lastpar = size_t(pit + 1) >= paragraphs.size();
 		if (!lastpar) {
 			ParagraphList::const_iterator nextpar = paragraphs.iterator_at(pit + 1);
@@ -1854,7 +1854,7 @@ pair<bool, int> switchEncoding(odocstream & os, BufferParams const & bparams,
 		|| oldEnc.package() == Encoding::japanese
 		|| oldEnc.package() == Encoding::none
 		|| newEnc.package() == Encoding::none
-		|| (runparams.for_searchAdv != OutputParams::NoSearch))
+		|| (runparams.for_search != OutputParams::NoSearch))
 		return make_pair(false, 0);
 	// FIXME We ignore encoding switches from/to encodings that do
 	// neither support the inputenc package nor the CJK package here.

commit 9d6e704183009221ae3996608728537cfb772238
Author: Stephan Witt <switt at lyx.org>
Date:   Sat Apr 9 09:19:46 2022 +0200

    Improved package build script for MacOS. Handle compiler standard for Qt6.

diff --git a/development/LyX-Mac-binary-release.sh b/development/LyX-Mac-binary-release.sh
index 017a610..cc7320d 100644
--- a/development/LyX-Mac-binary-release.sh
+++ b/development/LyX-Mac-binary-release.sh
@@ -284,9 +284,9 @@ while [ $# -gt 0 ]; do
 		LyxOnlyPackage=$(echo ${1}|cut -d= -f2)
 		shift
 		;;
-	--enable-cxx11)
+	--enable-cxx11|--enable-cxx-mode=*)
 		LyXConfigureOptions="${LyXConfigureOptions} ${1}"
-		EnableCXX11="--enable-cxx11"
+		EnableCXXMode="${1}"
 		shift
 		;;
 	--*)
@@ -374,6 +374,12 @@ case "${QtVersion}" in
 6*)
 	QtLibraries=${QtLibraries:-"QtCore5Compat QtDBus QtSvg QtXml QtPrintSupport QtSvgWidgets QtWidgets QtGui QtNetwork QtConcurrent QtCore"}
 	QtFrameworkVersion="A"
+	case "${EnableCXXMode}" in
+	--enable-cxx11|--enable-cxx-mode=11)
+		echo Warning: Adjust cxx standard "${EnableCXXMode}" for Qt 6. C++17 or better is required.
+		EnableCXXMode="--enable-cxx-mode=17"
+		;;
+	esac
 	;;
 *)
 	QtLibraries=${QtLibraries:-"QtSvg QtXml QtGui QtNetwork QtCore"}
@@ -412,6 +418,19 @@ esac
 MYCFLAGS="-mmacosx-version-min=${MACOSX_DEPLOYMENT_TARGET}"
 MYLDFLAGS="-mmacosx-version-min=${MACOSX_DEPLOYMENT_TARGET}"
 
+case "${EnableCXXMode}" in
+--enable-cxx11|--enable-cxx-mode=11)
+	export CC=cc
+	export CXX="c++ -stdlib=libc++"
+	export CXXFLAGS=-std=c++11
+	;;
+--enable-cxx-mode=17)
+	export CC=cc
+	export CXX="c++ -stdlib=libc++"
+	export CXXFLAGS=-std=c++17
+	;;
+esac
+
 build_qt() {
 	echo Build Qt library ${QtSourceDir}
 	if [ "${QtInstallDir}" = "${QtBuildDir}" ]; then
@@ -641,14 +660,6 @@ build_lyx() {
 		rm -rf "${LyxAppPrefix}"
 	fi
 
-	case "${EnableCXX11}" in
-	"--enable-cxx11")
-		export CC=cc
-		export CXX="c++ -stdlib=libc++"
-		export CXXFLAGS=-std=c++11
-		;;
-	esac
-
 	# -------------------------------------
 	# Automate configure check
 	# -------------------------------------

commit 8338d1032ddb79007d3cf74ffee22a4f8da9d90d
Author: Kornel Benko <kornel at lyx.org>
Date:   Sat Apr 9 09:11:38 2022 +0200

    FindQuick: Amend 4bd38d8a: Remove now unneeded code

diff --git a/src/Paragraph.cpp b/src/Paragraph.cpp
index 1e9f1fb..7746597 100644
--- a/src/Paragraph.cpp
+++ b/src/Paragraph.cpp
@@ -4560,32 +4560,6 @@ void Paragraph::changeCase(BufferParams const & bparams, pos_type pos,
 	}
 }
 
-static char_type matchquote(char_type in)
-{
-	switch (in) {
-		case 0x2018:	// Left Single Quotation Mark
-		case 0x2019:	// Right Single Quotation Mark
-		case 0x201a:	// Single Low-9 Quotation Mark
-		case 0x201b:	// Single High-Reversed-9 Quotation Mark 
-		case 0x2039:	// Single Left-Pointing Angle Quotation Mark
-		case 0x203a:	// Single Right-Pointing Angle Quotation Mark
-			return '\'';
-		case 0x00bb:	// Right-Pointing Double Angle Quotation Mark
-		case 0x00ab:	// Left-Pointing Double Angle Quotation Mark
-		case 0x201e:	// Double Low-9 Quotation Mark 
-		case 0x201c:	// Left Double Quotation Mark 
-		case 0x201d:	// Right Double Quotation Mark 
-		case 0x201f:	// Double High-Reversed-9 Quotation Mark 
-		case 0x2e42:	// Double Low-Reversed-9 Quotation Mark
-		case 0x301e:	// Double Prime Quotation Mark
-		case 0x301d:	// Reversed Double Prime Quotation Mark
-		case 0x301f:	// Low Double Prime Quotation Mark
-			return '"';
-		default:
-			return in;
-	}
-}
-
 int Paragraph::find(docstring const & str, bool cs, bool mw,
 		pos_type start_pos, bool del) const
 {
@@ -4622,9 +4596,8 @@ int Paragraph::find(docstring const & str, bool cs, bool mw,
 			if (!insetstring.empty()) {
 				int const insetstringsize = insetstring.length();
 				for (int j = 0; j < insetstringsize && pos < parsize; ++i, ++j) {
-					char_type ij = matchquote(insetstring[j]);
-					if ((cs && str[i] != ij)
-					    || (!cs && uppercase(str[i]) != uppercase(ij))) {
+					if ((cs && str[i] != insetstring[j])
+					    || (!cs && uppercase(str[i]) != uppercase(insetstring[j]))) {
 						nonmatch = true;
 						break;
 					}
@@ -4634,7 +4607,7 @@ int Paragraph::find(docstring const & str, bool cs, bool mw,
 		}
 		if (nonmatch || i == strsize)
 			break;
-		char_type dp = matchquote(d->text_[pos]);
+		char_type dp = d->text_[pos];
 		if (cs && str[i] != dp)
 			break;
 		if (!cs && uppercase(str[i]) != uppercase(dp))

commit 4bd38d8a09044172b107be30744456012b80fb4f
Author: Kornel Benko <kornel at lyx.org>
Date:   Sat Apr 9 08:52:24 2022 +0200

    FindQuick: Handle quotes special (as in findadv)

diff --git a/src/OutputParams.h b/src/OutputParams.h
index d00ec02..65a58e5 100644
--- a/src/OutputParams.h
+++ b/src/OutputParams.h
@@ -429,6 +429,7 @@ public:
 		NoSearch = 0,
 		SearchWithDeleted = 1,
 		SearchWithoutDeleted = 2,
+		SearchQuick = 4,
 		SearchNonOutput = 8
 	};
 		
diff --git a/src/Paragraph.cpp b/src/Paragraph.cpp
index e37a123..1e9f1fb 100644
--- a/src/Paragraph.cpp
+++ b/src/Paragraph.cpp
@@ -4610,7 +4610,14 @@ int Paragraph::find(docstring const & str, bool cs, bool mw,
 			if (!inset->isLetter() && !inset->isChar())
 				break;
 			odocstringstream os;
-			inset->toString(os);
+			if (inset->lyxCode() == lyx::QUOTE_CODE) {
+				OutputParams op(0);
+				op.for_searchAdv = OutputParams::SearchQuick;
+				inset->plaintext(os, op);
+			}
+			else {
+				inset->toString(os);
+			}
 			docstring const insetstring = os.str();
 			if (!insetstring.empty()) {
 				int const insetstringsize = insetstring.length();

commit 801768af9242ff1aca8735a0226e4c78becded00
Author: Kornel Benko <kornel at lyx.org>
Date:   Fri Apr 8 19:56:41 2022 +0200

    FindQuick: Amend 1f7d90d6: Add some not handled quotation marks

diff --git a/src/Paragraph.cpp b/src/Paragraph.cpp
index 92bb883..e37a123 100644
--- a/src/Paragraph.cpp
+++ b/src/Paragraph.cpp
@@ -4563,16 +4563,24 @@ void Paragraph::changeCase(BufferParams const & bparams, pos_type pos,
 static char_type matchquote(char_type in)
 {
 	switch (in) {
-		case 0x2018:
-		case 0x201a:
-		case 0x203a:
-		case 0x2039:
-			return '\'';	// ‘ ‚ › ‹
-		case 0x00bb:
-		case 0x00ab:
-		case 0x201e:
-		case 0x201c:
-			return '"';	// » « „ “
+		case 0x2018:	// Left Single Quotation Mark
+		case 0x2019:	// Right Single Quotation Mark
+		case 0x201a:	// Single Low-9 Quotation Mark
+		case 0x201b:	// Single High-Reversed-9 Quotation Mark 
+		case 0x2039:	// Single Left-Pointing Angle Quotation Mark
+		case 0x203a:	// Single Right-Pointing Angle Quotation Mark
+			return '\'';
+		case 0x00bb:	// Right-Pointing Double Angle Quotation Mark
+		case 0x00ab:	// Left-Pointing Double Angle Quotation Mark
+		case 0x201e:	// Double Low-9 Quotation Mark 
+		case 0x201c:	// Left Double Quotation Mark 
+		case 0x201d:	// Right Double Quotation Mark 
+		case 0x201f:	// Double High-Reversed-9 Quotation Mark 
+		case 0x2e42:	// Double Low-Reversed-9 Quotation Mark
+		case 0x301e:	// Double Prime Quotation Mark
+		case 0x301d:	// Reversed Double Prime Quotation Mark
+		case 0x301f:	// Low Double Prime Quotation Mark
+			return '"';
 		default:
 			return in;
 	}

commit 7cb700bf675ca255f3fcbe2fa07d04f0d359ed7b
Author: Jean-Marc Lasgouttes <lasgouttes at lyx.org>
Date:   Fri Apr 8 11:51:53 2022 +0200

    Fix crash with countExpanders in Qt6
    
    It is not a good idea to contruct a QChar from a char_type that is
    really 32bits.
    
    Use lyx::isSpace, which already catters for this case.
    
    Since this code does not depend on qt anymore, move it to
    support::countExpanders.
    
    Get rid of Row::countSeparators, which is not used anymore.
    
    Fixes bug #12519.

diff --git a/src/Row.cpp b/src/Row.cpp
index f2d4aaf..3d5ab90 100644
--- a/src/Row.cpp
+++ b/src/Row.cpp
@@ -42,19 +42,11 @@ using frontend::FontMetrics;
 static double const MAX_SPACE_STRETCH = 1.5; //em
 
 
-int Row::Element::countSeparators() const
-{
-	if (type != STRING)
-		return 0;
-	return count(str.begin(), str.end(), ' ');
-}
-
-
 int Row::Element::countExpanders() const
 {
 	if (type != STRING)
 		return 0;
-	return theFontMetrics(font).countExpanders(str);
+	return support::countExpanders(str);
 }
 
 
@@ -385,16 +377,6 @@ int Row::right_x() const
 }
 
 
-int Row::countSeparators() const
-{
-	int n = 0;
-	const_iterator const end = elements_.end();
-	for (const_iterator cit = elements_.begin() ; cit != end ; ++cit)
-		n += cit->countSeparators();
-	return n;
-}
-
-
 bool Row::setExtraWidth(int w)
 {
 	if (w < 0)
diff --git a/src/Row.h b/src/Row.h
index 4c4bfce..6583fb2 100644
--- a/src/Row.h
+++ b/src/Row.h
@@ -66,9 +66,6 @@ public:
 			: type(t), pos(p), endpos(p + 1), font(f), change(ch) {}
 
 
-		// Return the number of separator in the element (only STRING type)
-		int countSeparators() const;
-
 		// Return total width of element, including separator overhead
 		// FIXME: Cache this value or the number of expanders?
 		double full_width() const { return dim.wid + extra * countExpanders(); }
@@ -238,8 +235,6 @@ public:
 	/// The offset of the right-most cursor position on the row
 	int right_x() const;
 
-	// Return the number of separators in the row
-	int countSeparators() const;
 	// Set the extra spacing for every expanding character in STRING-type
 	// elements.  \param w is the total amount of extra width for the row to be
 	// distributed among expanders.  \return false if the justification fails.
diff --git a/src/frontends/FontMetrics.h b/src/frontends/FontMetrics.h
index 66cd22d..f395270 100644
--- a/src/frontends/FontMetrics.h
+++ b/src/frontends/FontMetrics.h
@@ -168,10 +168,6 @@ public:
 		int & width,
 		int & ascent,
 		int & descent) const = 0;
-
-	/// return the number of expanding characters taken into account for
-	/// increased inter-word spacing during justification
-	virtual int countExpanders(docstring const & str) const = 0;
 };
 
 
diff --git a/src/frontends/qt/GuiFontMetrics.cpp b/src/frontends/qt/GuiFontMetrics.cpp
index e7f61c6..cb9f5af 100644
--- a/src/frontends/qt/GuiFontMetrics.cpp
+++ b/src/frontends/qt/GuiFontMetrics.cpp
@@ -18,10 +18,10 @@
 #include "Dimension.h"
 
 #include "support/convert.h"
+#include "support/debug.h"
 #include "support/lassert.h"
 #include "support/lstrings.h" // for breakString_helper with qt4
 #include "support/lyxlib.h"
-#include "support/debug.h"
 
 #define DISABLE_PMPROF
 #include "support/pmprof.h"
@@ -467,27 +467,6 @@ int GuiFontMetrics::x2pos(docstring const & s, int & x, bool const rtl,
 }
 
 
-int GuiFontMetrics::countExpanders(docstring const & str) const
-{
-	// Numbers of characters that are expanded by inter-word spacing.  These
-	// characters are spaces, except for characters 09-0D which are treated
-	// specially.  (From a combination of testing with the notepad found in qt's
-	// examples, and reading the source code.)  In addition, consecutive spaces
-	// only count as one expander.
-	bool wasspace = false;
-	int nexp = 0;
-	for (char_type c : str)
-		if (c > 0x0d && QChar(c).isSpace()) {
-			if (!wasspace) {
-				++nexp;
-				wasspace = true;
-			}
-		} else
-			wasspace = false;
-	return nexp;
-}
-
-
 namespace {
 
 const int brkStrOffset = 1 + BIDI_OFFSET;
diff --git a/src/frontends/qt/GuiFontMetrics.h b/src/frontends/qt/GuiFontMetrics.h
index 9501eb8..82c5839 100644
--- a/src/frontends/qt/GuiFontMetrics.h
+++ b/src/frontends/qt/GuiFontMetrics.h
@@ -92,7 +92,6 @@ public:
 		int & ascent,
 		int & descent) const override;
 
-	int countExpanders(docstring const & str) const override;
 	///
 	int width(QString const & str) const;
 
diff --git a/src/frontends/qt/GuiPainter.cpp b/src/frontends/qt/GuiPainter.cpp
index cf9cd7c..b243c6e 100644
--- a/src/frontends/qt/GuiPainter.cpp
+++ b/src/frontends/qt/GuiPainter.cpp
@@ -26,6 +26,7 @@
 #include "support/debug.h"
 #include "support/lassert.h"
 #include "support/lyxlib.h"
+#include "support/lstrings.h"
 
 #include <algorithm>
 
@@ -329,7 +330,7 @@ void GuiPainter::text(int x, int y, docstring const & s,
 	if (tw == 0.0)
 		// Take into account space stretching (word spacing)
 		textwidth = fm.width(s) +
-			static_cast<int>(fm.countExpanders(s) * wordspacing);
+			static_cast<int>(countExpanders(s) * wordspacing);
 	else
 		textwidth = static_cast<int>(tw);
 
diff --git a/src/support/lstrings.cpp b/src/support/lstrings.cpp
index 351c977..b9c23f5 100644
--- a/src/support/lstrings.cpp
+++ b/src/support/lstrings.cpp
@@ -1495,6 +1495,27 @@ string from_percent_encoding(string const & in)
 }
 
 
+int countExpanders(docstring const & str)
+{
+	// Numbers of characters that are expanded by inter-word spacing.  These
+	// characters are spaces, except for characters 09-0D which are treated
+	// specially.  (From a combination of testing with the notepad found in qt's
+	// examples, and reading the source code.)  In addition, consecutive spaces
+	// only count as one expander.
+	bool wasspace = false;
+	int nexp = 0;
+	for (char_type c : str)
+		if (c > 0x0d && isSpace(c)) {
+			if (!wasspace) {
+				++nexp;
+				wasspace = true;
+			}
+		} else
+			wasspace = false;
+	return nexp;
+}
+
+
 docstring bformat(docstring const & fmt, int arg1)
 {
 	LATTEST(contains(fmt, from_ascii("%1$d")));
diff --git a/src/support/lstrings.h b/src/support/lstrings.h
index 3d42bb6..390d29c 100644
--- a/src/support/lstrings.h
+++ b/src/support/lstrings.h
@@ -368,6 +368,11 @@ docstring to_percent_encoding(docstring const & in, docstring const & ex = docst
 /// Returns a string decoded from an URI/URL-style percent-encoded string \p in.
 std::string from_percent_encoding(std::string const & in);
 
+/// returns the number of expanding characters taken into account for
+/// increased inter-word spacing during justification
+int countExpanders(docstring const & str);
+
+
 docstring bformat(docstring const & fmt, int arg1);
 docstring bformat(docstring const & fmt, long arg1);
 #ifdef HAVE_LONG_LONG_INT

commit 1f7d90d6367010d32f77a536a246e8fed9b3d381
Author: Kornel Benko <kornel at lyx.org>
Date:   Fri Apr 8 08:40:32 2022 +0200

    Find: Advanced + Quick:
    
    Expand list of quotes to include also '» « › ‹'
    Enable quick find to search for quotes too

diff --git a/src/Paragraph.cpp b/src/Paragraph.cpp
index be133b1..92bb883 100644
--- a/src/Paragraph.cpp
+++ b/src/Paragraph.cpp
@@ -4560,6 +4560,23 @@ void Paragraph::changeCase(BufferParams const & bparams, pos_type pos,
 	}
 }
 
+static char_type matchquote(char_type in)
+{
+	switch (in) {
+		case 0x2018:
+		case 0x201a:
+		case 0x203a:
+		case 0x2039:
+			return '\'';	// ‘ ‚ › ‹
+		case 0x00bb:
+		case 0x00ab:
+		case 0x201e:
+		case 0x201c:
+			return '"';	// » « „ “
+		default:
+			return in;
+	}
+}
 
 int Paragraph::find(docstring const & str, bool cs, bool mw,
 		pos_type start_pos, bool del) const
@@ -4590,8 +4607,9 @@ int Paragraph::find(docstring const & str, bool cs, bool mw,
 			if (!insetstring.empty()) {
 				int const insetstringsize = insetstring.length();
 				for (int j = 0; j < insetstringsize && pos < parsize; ++i, ++j) {
-					if ((cs && str[i] != insetstring[j])
-					    || (!cs && uppercase(str[i]) != uppercase(insetstring[j]))) {
+					char_type ij = matchquote(insetstring[j]);
+					if ((cs && str[i] != ij)
+					    || (!cs && uppercase(str[i]) != uppercase(ij))) {
 						nonmatch = true;
 						break;
 					}
@@ -4601,9 +4619,10 @@ int Paragraph::find(docstring const & str, bool cs, bool mw,
 		}
 		if (nonmatch || i == strsize)
 			break;
-		if (cs && str[i] != d->text_[pos])
+		char_type dp = matchquote(d->text_[pos]);
+		if (cs && str[i] != dp)
 			break;
-		if (!cs && uppercase(str[i]) != uppercase(d->text_[pos]))
+		if (!cs && uppercase(str[i]) != uppercase(dp))
 			break;
 	}
 
diff --git a/src/lyxfind.cpp b/src/lyxfind.cpp
index 0f02a39..c3f2b77 100644
--- a/src/lyxfind.cpp
+++ b/src/lyxfind.cpp
@@ -913,10 +913,10 @@ string correctRegex(string t, bool withformat)
 	else if (lastpos < t.length())
 		s += t.substr(lastpos, t.length() - lastpos);
 	// Handle quotes in regex
-	// substitute all '„', '“' with '"'
-	// and all '‚', '‘' with "\'"
-	static std::regex plainquotes { R"(„|“)" };
-	static std::regex innerquotes { R"(‚|‘)" };
+	// substitute all '„', '“', '»', '«' with '"'
+	// and all '‚', '‘', '›', '‹' with "\'"
+	static std::regex plainquotes { R"(„|“|»|«)" };
+	static std::regex innerquotes { R"(‚|‘|›|‹)" };
 	t = std::regex_replace(s, plainquotes, R"(")");
 	s = std::regex_replace(t, innerquotes, R"(')");
 	//LYXERR0("correctRegex output '" << s << "'");

commit aa66663364c44047bd97c919a651b8adcaf7617a
Author: Kornel Benko <kornel at lyx.org>
Date:   Wed Apr 6 19:00:20 2022 +0200

    FindAdv: Amend 58f70b9d
    
    Consider plain-quotes, inner-quotes
    1 independent if in regex or text
    2 independent of quote style
    3 independent of using dynamic marks

diff --git a/src/insets/InsetQuotes.cpp b/src/insets/InsetQuotes.cpp
index 3dfed9e..67ad767 100644
--- a/src/insets/InsetQuotes.cpp
+++ b/src/insets/InsetQuotes.cpp
@@ -942,11 +942,20 @@ void InsetQuotes::latex(otexstream & os, OutputParams const & runparams) const
 
 
 int InsetQuotes::plaintext(odocstringstream & os,
-        OutputParams const &, size_t) const
+        OutputParams const & op, size_t) const
 {
-	docstring const str = displayString();
-	os << str;
-	return str.size();
+	if (op.for_searchAdv == OutputParams::NoSearch) {
+		docstring const str = displayString();
+		os << str;
+		return str.size();
+	}
+	else {
+		if (level_ == QuoteLevel::Primary)
+			os << from_ascii("\"");
+		else
+			os << from_ascii("'");
+		return 1;
+	}
 }
 
 
diff --git a/src/lyxfind.cpp b/src/lyxfind.cpp
index 64da365..0f02a39 100644
--- a/src/lyxfind.cpp
+++ b/src/lyxfind.cpp
@@ -909,9 +909,16 @@ string correctRegex(string t, bool withformat)
 		lastpos = sub.position(2) + sub.length(2);
 	}
 	if (lastpos == 0)
-		return t;
+		s = t;
 	else if (lastpos < t.length())
 		s += t.substr(lastpos, t.length() - lastpos);
+	// Handle quotes in regex
+	// substitute all '„', '“' with '"'
+	// and all '‚', '‘' with "\'"
+	static std::regex plainquotes { R"(„|“)" };
+	static std::regex innerquotes { R"(‚|‘)" };
+	t = std::regex_replace(s, plainquotes, R"(")");
+	s = std::regex_replace(t, innerquotes, R"(')");
 	//LYXERR0("correctRegex output '" << s << "'");
 	return s;
 }

commit 58f70b9da1c4137a9c9831dfade8239b33288bbf
Author: Kornel Benko <kornel at lyx.org>
Date:   Tue Apr 5 17:04:51 2022 +0200

    FindAdv: Handle search for quotes
    
    Double quotes will be found if using the string '"' in pattern.
    Single quotes needs "'" in pattern.

diff --git a/src/insets/InsetQuotes.cpp b/src/insets/InsetQuotes.cpp
index dc6dbba..3dfed9e 100644
--- a/src/insets/InsetQuotes.cpp
+++ b/src/insets/InsetQuotes.cpp
@@ -851,7 +851,7 @@ void InsetQuotes::latex(otexstream & os, OutputParams const & runparams) const
 	docstring qstr;
 
 	// In pass-thru context, we output plain quotes
-	if (runparams.pass_thru)
+	if (runparams.pass_thru || runparams.for_searchAdv != OutputParams::NoSearch)
 		qstr = (level_ == QuoteLevel::Primary) ? from_ascii("\"") : from_ascii("'");
 	else if (style == QuoteStyle::Plain && fontspec_) {
 		// For XeTeX and LuaTeX,we need to disable mapping to get straight

commit 31ac9ed59ff7d4eb22dfc2520fb216baf74115b7
Author: Juergen Spitzmueller <spitz at lyx.org>
Date:   Mon Apr 4 12:02:25 2022 +0200

    Fix indentation

diff --git a/src/lyxfind.cpp b/src/lyxfind.cpp
index c4b6b96..64da365 100644
--- a/src/lyxfind.cpp
+++ b/src/lyxfind.cpp
@@ -892,7 +892,7 @@ string correctRegex(string t, bool withformat)
 			else if (sub.str(4) == "{") // transforms '\{' into '{'
 				replace = "{";
 			else if (sub.str(4) == "}")
-                                replace = "}";
+				replace = "}";
 			else {
 				AccentsIterator it_ac = accents.find(sub.str(4));
 				if (it_ac == accents.end()) {
@@ -961,8 +961,8 @@ public:
 	enum range {
 		newIsTooFar,
 		newIsBetter,
-                newIsInvalid
-        };
+		newIsInvalid
+	};
 	int match_len;
 	int match_prefix;
 	int match2end;
@@ -976,16 +976,16 @@ public:
 
 static MatchResult::range interpretMatch(MatchResult &oldres, MatchResult &newres)
 {
-  if (newres.match2end < oldres.match2end)
-    return MatchResult::newIsTooFar;
-  if (newres.match_len < oldres.match_len)
-    return MatchResult::newIsTooFar;
-
-  if (newres.match_len == oldres.match_len) {
-    if (newres.match2end == oldres.match2end)
-      return MatchResult::newIsBetter;
-  }
-  return MatchResult::newIsInvalid;
+	if (newres.match2end < oldres.match2end)
+		return MatchResult::newIsTooFar;
+	if (newres.match_len < oldres.match_len)
+		return MatchResult::newIsTooFar;
+
+	if (newres.match_len == oldres.match_len) {
+		if (newres.match2end == oldres.match2end)
+			return MatchResult::newIsBetter;
+	}
+	return MatchResult::newIsInvalid;
 }
 
 /** The class performing a match between a position in the document and the FindAdvOptions.
@@ -1071,13 +1071,12 @@ vector <string> MatchStringAdv::matches = vector <string>(10);
 
 void MatchStringAdv::FillResults(MatchResult &found_mr)
 {
-  if (found_mr.match_len > 0) {
-    valid_matches = found_mr.result.size();
-    for (size_t i = 0; i < found_mr.result.size(); i++)
-      matches[i] = found_mr.result[i];
-  }
-  else
-    valid_matches = 0;
+	if (found_mr.match_len > 0) {
+		valid_matches = found_mr.result.size();
+		for (size_t i = 0; i < found_mr.result.size(); i++)
+			matches[i] = found_mr.result[i];
+	} else
+		valid_matches = 0;
 }
 
 static docstring buffer_to_latex(Buffer & buffer)
@@ -1202,12 +1201,12 @@ static size_t identifyLeading(string const & s)
 	// Kornel: Added textsl, textsf, textit, texttt and noun
 	// + allow to search for colored text too
 	while (regex_replace(t, t, "^\\\\(("
-	                     "(author|title|subtitle|subject|publishers|dedication|uppertitleback|lowertitleback|extratitle|"
-	                       "lyxaddress|lyxrightaddress|"
-	                       "footnotesize|tiny|scriptsize|small|large|Large|LARGE|huge|Huge|"
-	                       "emph|noun|minisec|text(bf|md|sl|sf|it|tt))|"
-	                     "((textcolor|foreignlanguage|latexenvironment)\\{[a-z]+\\*?\\})|"
-	                     "(u|uu)line|(s|x)out|uwave)|((sub)?(((sub)?section)|paragraph)|part|chapter)\\*?)\\{", "")
+			     "(author|title|subtitle|subject|publishers|dedication|uppertitleback|lowertitleback|extratitle|"
+			     "lyxaddress|lyxrightaddress|"
+			     "footnotesize|tiny|scriptsize|small|large|Large|LARGE|huge|Huge|"
+			     "emph|noun|minisec|text(bf|md|sl|sf|it|tt))|"
+			     "((textcolor|foreignlanguage|latexenvironment)\\{[a-z]+\\*?\\})|"
+			     "(u|uu)line|(s|x)out|uwave)|((sub)?(((sub)?section)|paragraph)|part|chapter)\\*?)\\{", "")
 	       || regex_replace(t, t, "^\\$", "")
 	       || regex_replace(t, t, "^\\\\\\[", "")
 	       || regex_replace(t, t, "^ ?\\\\item\\{[a-z]+\\}", "")
@@ -1271,169 +1270,170 @@ static Features identifyFeatures(string const & s)
  * defines values features of a key "\\[a-z]+{"
  */
 class KeyInfo {
- public:
-  enum KeyType {
-    /* Char type with content discarded
-     * like \hspace{1cm} */
-    noContent,
-    /* Char, like \backslash */
-    isChar,
-    /* replace starting backslash with '#' */
-    isText,
-    /* \part, \section*, ... */
-    isSectioning,
-    /* title, author etc */
-    isTitle,
-    /* \foreignlanguage{ngerman}, ... */
-    isMain,
-    /* inside \code{}
-     * to discard language in content */
-    noMain,
-    isRegex,
-    /* \begin{eqnarray}...\end{eqnarray}, ... $...$ */
-    isMath,
-    /* fonts, colors, markups, ... */
-    isStandard,
-    /* footnotesize, ... large, ...
-     * Ignore all of them */
-    isSize,
-    invalid,
-    /* inputencoding, ...
-     * Discard also content, because they do not help in search */
-    doRemove,
-    /* twocolumns, ...
-     * like remove, but also all arguments */
-    removeWithArg,
-    /* item, listitem */
-    isList,
-    /* tex, latex, ... like isChar */
-    isIgnored,
-    /* like \lettrine[lines=5]{}{} */
-    cleanToStart,
-    // like isStandard, but always remove head
-    headRemove,
-    /* End of arguments marker for lettrine,
-     * so that they can be ignored */
-    endArguments
-  };
- KeyInfo() = default;
- KeyInfo(KeyType type, int parcount, bool disable)
-   : keytype(type),
-    parenthesiscount(parcount),
-    disabled(disable) {}
-  KeyType keytype = invalid;
-  string head;
-  int _tokensize = -1;
-  int _tokenstart = -1;
-  int _dataStart = -1;
-  int _dataEnd = -1;
-  int parenthesiscount = 1;
-  bool disabled = false;
-  bool used = false;                    /* by pattern */
+public:
+	enum KeyType {
+		/* Char type with content discarded
+		 * like \hspace{1cm} */
+		noContent,
+		/* Char, like \backslash */
+		isChar,
+		/* replace starting backslash with '#' */
+		isText,
+		/* \part, \section*, ... */
+		isSectioning,
+		/* title, author etc */
+		isTitle,
+		/* \foreignlanguage{ngerman}, ... */
+		isMain,
+		/* inside \code{}
+		 * to discard language in content */
+		noMain,
+		isRegex,
+		/* \begin{eqnarray}...\end{eqnarray}, ... $...$ */
+		isMath,
+		/* fonts, colors, markups, ... */
+		isStandard,
+		/* footnotesize, ... large, ...
+		 * Ignore all of them */
+		isSize,
+		invalid,
+		/* inputencoding, ...
+		 * Discard also content, because they do not help in search */
+		doRemove,
+		/* twocolumns, ...
+		 * like remove, but also all arguments */
+		removeWithArg,
+		/* item, listitem */
+		isList,
+		/* tex, latex, ... like isChar */
+		isIgnored,
+		/* like \lettrine[lines=5]{}{} */
+		cleanToStart,
+		// like isStandard, but always remove head
+		headRemove,
+		/* End of arguments marker for lettrine,
+		 * so that they can be ignored */
+		endArguments
+	};
+	KeyInfo() = default;
+	KeyInfo(KeyType type, int parcount, bool disable)
+		: keytype(type),
+		  parenthesiscount(parcount),
+		  disabled(disable) {}
+	KeyType keytype = invalid;
+	string head;
+	int _tokensize = -1;
+	int _tokenstart = -1;
+	int _dataStart = -1;
+	int _dataEnd = -1;
+	int parenthesiscount = 1;
+	bool disabled = false;
+	bool used = false; /* by pattern */
 };
 
 class Border {
- public:
- Border(int l=0, int u=0) : low(l), upper(u) {}
-  int low;
-  int upper;
+public:
+	Border(int l=0, int u=0) : low(l), upper(u) {}
+	int low;
+	int upper;
 };
 
 #define MAXOPENED 30
 class Intervall {
-  bool isPatternString_;
+	bool isPatternString_;
 public:
-  explicit Intervall(bool isPattern, string const & p) :
-        isPatternString_(isPattern), par(p), ignoreidx(-1), actualdeptindex(0),
-        hasTitle(false), langcount(0)
-  {
-    depts[0] = 0;
-    closes[0] = 0;
-  }
-
-  string par;
-  int ignoreidx;
-  static vector<Border> borders;
-  int depts[MAXOPENED];
-  int closes[MAXOPENED];
-  int actualdeptindex;
-  int previousNotIgnored(int) const;
-  int nextNotIgnored(int) const;
-  void handleOpenP(int i);
-  void handleCloseP(int i, bool closingAllowed);
-  void resetOpenedP(int openPos);
-  void addIntervall(int upper);
-  void addIntervall(int low, int upper); /* if explicit */
-  void removeAccents();
-  void setForDefaultLang(KeyInfo const & defLang) const;
-  int findclosing(int start, int end, char up, char down, int repeat);
-  void handleParentheses(int lastpos, bool closingAllowed);
-  bool hasTitle;
-  int langcount;	// Number of disabled language specs up to current position in actual interval
-  int isOpeningPar(int pos) const;
-  string titleValue;
-  void output(ostringstream &os, int lastpos);
-  // string show(int lastpos);
+	explicit Intervall(bool isPattern, string const & p)
+		: isPatternString_(isPattern), par(p), ignoreidx(-1),
+		  actualdeptindex(0), hasTitle(false), langcount(0)
+	{
+		depts[0] = 0;
+		closes[0] = 0;
+	}
+
+	string par;
+	int ignoreidx;
+	static vector<Border> borders;
+	int depts[MAXOPENED];
+	int closes[MAXOPENED];
+	int actualdeptindex;
+	int previousNotIgnored(int) const;
+	int nextNotIgnored(int) const;
+	void handleOpenP(int i);
+	void handleCloseP(int i, bool closingAllowed);
+	void resetOpenedP(int openPos);
+	void addIntervall(int upper);
+	void addIntervall(int low, int upper); /* if explicit */
+	void removeAccents();
+	void setForDefaultLang(KeyInfo const & defLang) const;
+	int findclosing(int start, int end, char up, char down, int repeat);
+	void handleParentheses(int lastpos, bool closingAllowed);
+	bool hasTitle;
+	// Number of disabled language specs up
+	// to current position in actual interval
+	int langcount;
+	int isOpeningPar(int pos) const;
+	string titleValue;
+	void output(ostringstream &os, int lastpos);
+	// string show(int lastpos);
 };
 
 vector<Border> Intervall::borders = vector<Border>(30);
 
 int Intervall::isOpeningPar(int pos) const
 {
-  if ((pos < 0) || (size_t(pos) >= par.size()))
-    return 0;
-  if (par[pos] != '{')
-    return 0;
-  if (size_t(pos) + 2 >= par.size())
-    return 1;
-  if (par[pos+2] != '}')
-    return 1;
-  if (par[pos+1] == '[' || par[pos+1] == ']')
-    return 3;
-  return 1;
+	if ((pos < 0) || (size_t(pos) >= par.size()))
+		return 0;
+	if (par[pos] != '{')
+		return 0;
+	if (size_t(pos) + 2 >= par.size())
+		return 1;
+	if (par[pos+2] != '}')
+		return 1;
+	if (par[pos+1] == '[' || par[pos+1] == ']')
+		return 3;
+	return 1;
 }
 
 void Intervall::setForDefaultLang(KeyInfo const & defLang) const
 {
-  // Enable the use of first token again
-  if (ignoreidx >= 0) {
-    int value = defLang._tokenstart + defLang._tokensize;
-    int borderidx = 0;
-    if (hasTitle) {
-      borderidx = 1;
-    }
-    if (value > 0) {
-      if (borders[borderidx].low < value)
-        borders[borderidx].low = value;
-      if (borders[borderidx].upper < value)
-        borders[borderidx].upper = value;
-    }
-  }
+	// Enable the use of first token again
+	if (ignoreidx >= 0) {
+		int value = defLang._tokenstart + defLang._tokensize;
+		int borderidx = 0;
+		if (hasTitle)
+			borderidx = 1;
+		if (value > 0) {
+			if (borders[borderidx].low < value)
+				borders[borderidx].low = value;
+			if (borders[borderidx].upper < value)
+				borders[borderidx].upper = value;
+		}
+	}
 }
 
 static void checkDepthIndex(int val)
 {
-  static int maxdepthidx = MAXOPENED-2;
-  static int lastmaxdepth = 0;
-  if (val > lastmaxdepth) {
-    LYXERR(Debug::INFO, "Depth reached " << val);
-    lastmaxdepth = val;
-  }
-  if (val > maxdepthidx) {
-    maxdepthidx = val;
-    LYXERR(Debug::INFO, "maxdepthidx now " << val);
-  }
+	static int maxdepthidx = MAXOPENED-2;
+	static int lastmaxdepth = 0;
+	if (val > lastmaxdepth) {
+		LYXERR(Debug::INFO, "Depth reached " << val);
+		lastmaxdepth = val;
+	}
+	if (val > maxdepthidx) {
+		maxdepthidx = val;
+		LYXERR(Debug::INFO, "maxdepthidx now " << val);
+	}
 }
 
 #if 0
 // Not needed, because borders are now dynamically expanded
 static void checkIgnoreIdx(int val)
 {
-  static int lastmaxignore = -1;
-  if ((lastmaxignore < val) && (size_t(val+1) >= borders.size())) {
-    LYXERR(Debug::INFO, "IgnoreIdx reached " << val);
-    lastmaxignore = val;
-  }
+	static int lastmaxignore = -1;
+	if ((lastmaxignore < val) && (size_t(val+1) >= borders.size())) {
+		LYXERR(Debug::INFO, "IgnoreIdx reached " << val);
+		lastmaxignore = val;
+	}
 }
 #endif
 
@@ -1443,114 +1443,114 @@ static void checkIgnoreIdx(int val)
  */
 void Intervall::addIntervall(int low, int upper)
 {
-  int idx;
-  if (low == upper) return;
-  for (idx = ignoreidx+1; idx > 0; --idx) {
-    if (low > borders[idx-1].upper) {
-      break;
-    }
-  }
-  Border br(low, upper);
-  if (idx > ignoreidx) {
-    if (borders.size() <= size_t(idx)) {
-      borders.push_back(br);
-    }
-    else {
-      borders[idx] = br;
-    }
-    ignoreidx = idx;
-    // checkIgnoreIdx(ignoreidx);
-    return;
-  }
-  else {
-    // Expand only if one of the new bound is inside the interwall
-    // We know here that br.low > borders[idx-1].upper
-    if (br.upper < borders[idx].low) {
-      // We have to insert at this pos
-      if (size_t(ignoreidx+1) >= borders.size()) {
-        borders.push_back(borders[ignoreidx]);
-      }
-      else {
-        borders[ignoreidx+1] = borders[ignoreidx];
-      }
-      for (int i = ignoreidx; i > idx; --i) {
-        borders[i] = borders[i-1];
-      }
-      borders[idx] = br;
-      ignoreidx += 1;
-      // checkIgnoreIdx(ignoreidx);
-      return;
-    }
-    // Here we know, that we are overlapping
-    if (br.low > borders[idx].low)
-      br.low = borders[idx].low;
-    // check what has to be concatenated
-    int count = 0;
-    for (int i = idx; i <= ignoreidx; i++) {
-      if (br.upper >= borders[i].low) {
-        count++;
-        if (br.upper < borders[i].upper)
-          br.upper = borders[i].upper;
-      }
-      else {
-        break;
-      }
-    }
-    // count should be >= 1 here
-    borders[idx] = br;
-    if (count > 1) {
-      for (int i = idx + count; i <= ignoreidx; i++) {
-        borders[i-count+1] = borders[i];
-      }
-      ignoreidx -= count - 1;
-      return;
-    }
-  }
+	int idx;
+	if (low == upper) return;
+	for (idx = ignoreidx+1; idx > 0; --idx) {
+		if (low > borders[idx-1].upper) {
+			break;
+		}
+	}
+	Border br(low, upper);
+	if (idx > ignoreidx) {
+		if (borders.size() <= size_t(idx)) {
+			borders.push_back(br);
+		}
+		else {
+			borders[idx] = br;
+		}
+		ignoreidx = idx;
+		// checkIgnoreIdx(ignoreidx);
+		return;
+	}
+	else {
+		// Expand only if one of the new bound is inside the interwall
+		// We know here that br.low > borders[idx-1].upper
+		if (br.upper < borders[idx].low) {
+			// We have to insert at this pos
+			if (size_t(ignoreidx+1) >= borders.size()) {
+				borders.push_back(borders[ignoreidx]);
+			}
+			else {
+				borders[ignoreidx+1] = borders[ignoreidx];
+			}
+			for (int i = ignoreidx; i > idx; --i) {
+				borders[i] = borders[i-1];
+			}
+			borders[idx] = br;
+			ignoreidx += 1;
+			// checkIgnoreIdx(ignoreidx);
+			return;
+		}
+		// Here we know, that we are overlapping
+		if (br.low > borders[idx].low)
+			br.low = borders[idx].low;
+		// check what has to be concatenated
+		int count = 0;
+		for (int i = idx; i <= ignoreidx; i++) {
+			if (br.upper >= borders[i].low) {
+				count++;
+				if (br.upper < borders[i].upper)
+					br.upper = borders[i].upper;
+			}
+			else {
+				break;
+			}
+		}
+		// count should be >= 1 here
+		borders[idx] = br;
+		if (count > 1) {
+			for (int i = idx + count; i <= ignoreidx; i++) {
+				borders[i-count+1] = borders[i];
+			}
+			ignoreidx -= count - 1;
+			return;
+		}
+	}
 }
 
 static void buildaccent(string n, string param, string values)
 {
-  stringstream s(n);
-  string name;
-  const char delim = '|';
-  while (getline(s, name, delim)) {
-    size_t start = 0;
-    for (char c : param) {
-      string key = name + "{" + c + "}";
-      // get the corresponding utf8-value
-      if ((values[start] & 0xc0) != 0xc0) {
-        // should not happen, utf8 encoding starts at least with 11xxxxxx
-        // but value for '\dot{i}' is 'i', which is ascii
-        if ((values[start] & 0x80) == 0) {
-          // is ascii
-          accents[key] = values.substr(start, 1);
-          // LYXERR(Debug::INFO, "" << key << "=" << accents[key]);
-        }
-        start++;
-        continue;
-      }
-      for (int j = 1; ;j++) {
-        if (start + j >= values.size()) {
-          accents[key] = values.substr(start, j);
-          start = values.size() - 1;
-          break;
-        }
-        else if ((values[start+j] & 0xc0) != 0x80) {
-          // This is the first byte of following utf8 char
-          accents[key] = values.substr(start, j);
-          start += j;
-          // LYXERR(Debug::INFO, "" << key << "=" << accents[key]);
-          break;
-        }
-      }
-    }
-  }
+	stringstream s(n);
+	string name;
+	const char delim = '|';
+	while (getline(s, name, delim)) {
+		size_t start = 0;
+		for (char c : param) {
+			string key = name + "{" + c + "}";
+			// get the corresponding utf8-value
+			if ((values[start] & 0xc0) != 0xc0) {
+				// should not happen, utf8 encoding starts at least with 11xxxxxx
+				// but value for '\dot{i}' is 'i', which is ascii
+				if ((values[start] & 0x80) == 0) {
+					// is ascii
+					accents[key] = values.substr(start, 1);
+					// LYXERR(Debug::INFO, "" << key << "=" << accents[key]);
+				}
+				start++;
+				continue;
+			}
+			for (int j = 1; ;j++) {
+				if (start + j >= values.size()) {
+					accents[key] = values.substr(start, j);
+					start = values.size() - 1;
+					break;
+				}
+				else if ((values[start+j] & 0xc0) != 0x80) {
+					// This is the first byte of following utf8 char
+					accents[key] = values.substr(start, j);
+					start += j;
+					// LYXERR(Debug::INFO, "" << key << "=" << accents[key]);
+					break;
+				}
+			}
+		}
+	}
 }
 
 // Helper function
 static string getutf8(unsigned uchar)
 {
-	#define maxc 5
+#define maxc 5
 	string ret = string();
 	char c[maxc] = {0};
 	if (uchar <= 0x7f) {
@@ -1581,385 +1581,385 @@ static string getutf8(unsigned uchar)
 
 static void addAccents(string latex_in, string unicode_out)
 {
-  latex_in = latex_in.substr(1);
-  AccentsIterator it_ac = accents.find(latex_in);
-  if (it_ac == accents.end()) {
-    accents[latex_in] = unicode_out;
-  }
-  else {
-    LYXERR0("Key " << latex_in  << " already set");
-  }
+	latex_in = latex_in.substr(1);
+	AccentsIterator it_ac = accents.find(latex_in);
+	if (it_ac == accents.end()) {
+		accents[latex_in] = unicode_out;
+	}
+	else {
+		LYXERR0("Key " << latex_in  << " already set");
+	}
 }
 
 void static fillMissingUnicodesymbols()
 {
-  addAccents("\\pounds", getutf8(0x00a3));
-  addAccents("\\textsterling", getutf8(0x00a3));
-  addAccents("\\textyen", getutf8(0x00a5));
-  addAccents("\\yen", getutf8(0x00a5));
-  addAccents("\\textsection", getutf8(0x00a7));
-  addAccents("\\mathsection", getutf8(0x00a7));
-  addAccents("\\textcopyright", getutf8(0x00a9));
-  addAccents("\\copyright", getutf8(0x00a9));
-  addAccents("\\textlnot", getutf8(0x00ac));
-  addAccents("\\neg", getutf8(0x00ac));
-  addAccents("\\textregistered", getutf8(0x00ae));
-  addAccents("\\circledR", getutf8(0x00ae));
-  addAccents("\\textpm", getutf8(0x00b1));
-  addAccents("\\pm", getutf8(0x00b1));
-  addAccents("\\textparagraph", getutf8(0x00b6));
-  addAccents("\\mathparagraph", getutf8(0x00b6));
-  addAccents("\\textperiodcentered", getutf8(0x00b7));
-  addAccents("\\texttimes", getutf8(0x00d7));
-  addAccents("\\times", getutf8(0x00d7));
-  addAccents("\\O", getutf8(0x00d8));
-  addAccents("\\dh", getutf8(0x00f0));
-  addAccents("\\eth", getutf8(0x00f0));
-  addAccents("\\textdiv", getutf8(0x00f7));
-  addAccents("\\div", getutf8(0x00f7));
-  addAccents("\\o", getutf8(0x00f8));
-  addAccents("\\textcrlambda", getutf8(0x019b));
-  addAccents("\\j", getutf8(0x0237));
-  addAccents("\\textrevepsilon", getutf8(0x025c));
-  addAccents("\\textbaru", getutf8(0x0289));
-  addAccents("\\textquoteleft", getutf8(0x02bb));
-  addAccents("\\textGamma", getutf8(0x0393));
-  addAccents("\\Gamma", getutf8(0x0393));
-  addAccents("\\textDelta", getutf8(0x0394));
-  addAccents("\\Delta", getutf8(0x0394));
-  addAccents("\\textTheta", getutf8(0x0398));
-  addAccents("\\Theta", getutf8(0x0398));
-  addAccents("\\textLambda", getutf8(0x039b));
-  addAccents("\\Lambda", getutf8(0x039b));
-  addAccents("\\textXi", getutf8(0x039e));
-  addAccents("\\Xi", getutf8(0x039e));
-  addAccents("\\textPi", getutf8(0x03a0));
-  addAccents("\\Pi", getutf8(0x03a0));
-  addAccents("\\textSigma", getutf8(0x03a3));
-  addAccents("\\Sigma", getutf8(0x03a3));
-  addAccents("\\textUpsilon", getutf8(0x03a5));
-  addAccents("\\Upsilon", getutf8(0x03a5));
-  addAccents("\\textPhi", getutf8(0x03a6));
-  addAccents("\\Phi", getutf8(0x03a6));
-  addAccents("\\textPsi", getutf8(0x03a8));
-  addAccents("\\Psi", getutf8(0x03a8));
-  addAccents("\\textOmega", getutf8(0x03a9));
-  addAccents("\\Omega", getutf8(0x03a9));
-  addAccents("\\textalpha", getutf8(0x03b1));
-  addAccents("\\alpha", getutf8(0x03b1));
-  addAccents("\\textbeta", getutf8(0x03b2));
-  addAccents("\\beta", getutf8(0x03b2));
-  addAccents("\\textgamma", getutf8(0x03b3));
-  addAccents("\\gamma", getutf8(0x03b3));
-  addAccents("\\textdelta", getutf8(0x03b4));
-  addAccents("\\delta", getutf8(0x03b4));
-  addAccents("\\textepsilon", getutf8(0x03b5));
-  addAccents("\\varepsilon", getutf8(0x03b5));
-  addAccents("\\textzeta", getutf8(0x03b6));
-  addAccents("\\zeta", getutf8(0x03b6));
-  addAccents("\\texteta", getutf8(0x03b7));
-  addAccents("\\eta", getutf8(0x03b7));
-  addAccents("\\texttheta", getutf8(0x03b8));
-  addAccents("\\theta", getutf8(0x03b8));
-  addAccents("\\textiota", getutf8(0x03b9));
-  addAccents("\\iota", getutf8(0x03b9));
-  addAccents("\\textkappa", getutf8(0x03ba));
-  addAccents("\\kappa", getutf8(0x03ba));
-  addAccents("\\textlambda", getutf8(0x03bb));
-  addAccents("\\lambda", getutf8(0x03bb));
-  addAccents("\\textmu", getutf8(0x03bc));
-  addAccents("\\mu", getutf8(0x03bc));
-  addAccents("\\textnu", getutf8(0x03bd));
-  addAccents("\\nu", getutf8(0x03bd));
-  addAccents("\\textxi", getutf8(0x03be));
-  addAccents("\\xi", getutf8(0x03be));
-  addAccents("\\textpi", getutf8(0x03c0));
-  addAccents("\\pi", getutf8(0x03c0));
-  addAccents("\\textrho", getutf8(0x03c1));
-  addAccents("\\rho", getutf8(0x03c1));
-  addAccents("\\textfinalsigma", getutf8(0x03c2));
-  addAccents("\\varsigma", getutf8(0x03c2));
-  addAccents("\\textsigma", getutf8(0x03c3));
-  addAccents("\\sigma", getutf8(0x03c3));
-  addAccents("\\texttau", getutf8(0x03c4));
-  addAccents("\\tau", getutf8(0x03c4));
-  addAccents("\\textupsilon", getutf8(0x03c5));
-  addAccents("\\upsilon", getutf8(0x03c5));
-  addAccents("\\textphi", getutf8(0x03c6));
-  addAccents("\\varphi", getutf8(0x03c6));
-  addAccents("\\textchi", getutf8(0x03c7));
-  addAccents("\\chi", getutf8(0x03c7));
-  addAccents("\\textpsi", getutf8(0x03c8));
-  addAccents("\\psi", getutf8(0x03c8));
-  addAccents("\\textomega", getutf8(0x03c9));
-  addAccents("\\omega", getutf8(0x03c9));
-  addAccents("\\textdigamma", getutf8(0x03dd));
-  addAccents("\\digamma", getutf8(0x03dd));
-  addAccents("\\hebalef", getutf8(0x05d0));
-  addAccents("\\aleph", getutf8(0x05d0));
-  addAccents("\\hebbet", getutf8(0x05d1));
-  addAccents("\\beth", getutf8(0x05d1));
-  addAccents("\\hebgimel", getutf8(0x05d2));
-  addAccents("\\gimel", getutf8(0x05d2));
-  addAccents("\\hebdalet", getutf8(0x05d3));
-  addAccents("\\daleth", getutf8(0x05d3));
-  addAccents("\\hebhe", getutf8(0x05d4));
-  addAccents("\\hebvav", getutf8(0x05d5));
-  addAccents("\\hebzayin", getutf8(0x05d6));
-  addAccents("\\hebhet", getutf8(0x05d7));
-  addAccents("\\hebtet", getutf8(0x05d8));
-  addAccents("\\hebyod", getutf8(0x05d9));
-  addAccents("\\hebfinalkaf", getutf8(0x05da));
-  addAccents("\\hebkaf", getutf8(0x05db));
-  addAccents("\\heblamed", getutf8(0x05dc));
-  addAccents("\\hebfinalmem", getutf8(0x05dd));
-  addAccents("\\hebmem", getutf8(0x05de));
-  addAccents("\\hebfinalnun", getutf8(0x05df));
-  addAccents("\\hebnun", getutf8(0x05e0));
-  addAccents("\\hebsamekh", getutf8(0x05e1));
-  addAccents("\\hebayin", getutf8(0x05e2));
-  addAccents("\\hebfinalpe", getutf8(0x05e3));
-  addAccents("\\hebpe", getutf8(0x05e4));
-  addAccents("\\hebfinaltsadi", getutf8(0x05e5));
-  addAccents("\\hebtsadi", getutf8(0x05e6));
-  addAccents("\\hebqof", getutf8(0x05e7));
-  addAccents("\\hebresh", getutf8(0x05e8));
-  addAccents("\\hebshin", getutf8(0x05e9));
-  addAccents("\\hebtav", getutf8(0x05ea));
-
-  // Thai characters
-  addAccents("\\thaiKoKai", getutf8(0x0e01));
-  addAccents("\\thaiKhoKhai", getutf8(0x0e02));
-  addAccents("\\thaiKhoKhuat", getutf8(0x0e03));
-  addAccents("\\thaiKhoKhwai", getutf8(0x0e04));
-  addAccents("\\thaiKhoKhon", getutf8(0x0e05));
-  addAccents("\\thaiKhoRakhang", getutf8(0x0e06));
-  addAccents("\\thaiNgoNgu", getutf8(0x0e07));
-  addAccents("\\thaiChoChan", getutf8(0x0e08));
-  addAccents("\\thaiChoChing", getutf8(0x0e09));
-  addAccents("\\thaiChoChang", getutf8(0x0e0a));
-  addAccents("\\thaiSoSo", getutf8(0x0e0b));
-  addAccents("\\thaiChoChoe", getutf8(0x0e0c));
-  addAccents("\\thaiYoYing", getutf8(0x0e0d));
-  addAccents("\\thaiDoChada", getutf8(0x0e0e));
-  addAccents("\\thaiToPatak", getutf8(0x0e0f));
-  addAccents("\\thaiThoThan", getutf8(0x0e10));
-  addAccents("\\thaiThoNangmontho", getutf8(0x0e11));
-  addAccents("\\thaiThoPhuthao", getutf8(0x0e12));
-  addAccents("\\thaiNoNen", getutf8(0x0e13));
-  addAccents("\\thaiDoDek", getutf8(0x0e14));
-  addAccents("\\thaiToTao", getutf8(0x0e15));
-  addAccents("\\thaiThoThung", getutf8(0x0e16));
-  addAccents("\\thaiThoThahan", getutf8(0x0e17));
-  addAccents("\\thaiThoThong", getutf8(0x0e18));
-  addAccents("\\thaiNoNu", getutf8(0x0e19));
-  addAccents("\\thaiBoBaimai", getutf8(0x0e1a));
-  addAccents("\\thaiPoPla", getutf8(0x0e1b));
-  addAccents("\\thaiPhoPhung", getutf8(0x0e1c));
-  addAccents("\\thaiFoFa", getutf8(0x0e1d));
-  addAccents("\\thaiPhoPhan", getutf8(0x0e1e));
-  addAccents("\\thaiFoFan", getutf8(0x0e1f));
-  addAccents("\\thaiPhoSamphao", getutf8(0x0e20));
-  addAccents("\\thaiMoMa", getutf8(0x0e21));
-  addAccents("\\thaiYoYak", getutf8(0x0e22));
-  addAccents("\\thaiRoRua", getutf8(0x0e23));
-  addAccents("\\thaiRu", getutf8(0x0e24));
-  addAccents("\\thaiLoLing", getutf8(0x0e25));
-  addAccents("\\thaiLu", getutf8(0x0e26));
-  addAccents("\\thaiWoWaen", getutf8(0x0e27));
-  addAccents("\\thaiSoSala", getutf8(0x0e28));
-  addAccents("\\thaiSoRusi", getutf8(0x0e29));
-  addAccents("\\thaiSoSua", getutf8(0x0e2a));
-  addAccents("\\thaiHoHip", getutf8(0x0e2b));
-  addAccents("\\thaiLoChula", getutf8(0x0e2c));
-  addAccents("\\thaiOAng", getutf8(0x0e2d));
-  addAccents("\\thaiHoNokhuk", getutf8(0x0e2e));
-  addAccents("\\thaiPaiyannoi", getutf8(0x0e2f));
-  addAccents("\\thaiSaraA", getutf8(0x0e30));
-  addAccents("\\thaiMaiHanakat", getutf8(0x0e31));
-  addAccents("\\thaiSaraAa", getutf8(0x0e32));
-  addAccents("\\thaiSaraAm", getutf8(0x0e33));
-  addAccents("\\thaiSaraI", getutf8(0x0e34));
-  addAccents("\\thaiSaraIi", getutf8(0x0e35));
-  addAccents("\\thaiSaraUe", getutf8(0x0e36));
-  addAccents("\\thaiSaraUee", getutf8(0x0e37));
-  addAccents("\\thaiSaraU", getutf8(0x0e38));
-  addAccents("\\thaiSaraUu", getutf8(0x0e39));
-  addAccents("\\thaiPhinthu", getutf8(0x0e3a));
-  addAccents("\\thaiSaraE", getutf8(0x0e40));
-  addAccents("\\thaiSaraAe", getutf8(0x0e41));
-  addAccents("\\thaiSaraO", getutf8(0x0e42));
-  addAccents("\\thaiSaraAiMaimuan", getutf8(0x0e43));
-  addAccents("\\thaiSaraAiMaimalai", getutf8(0x0e44));
-  addAccents("\\thaiLakkhangyao", getutf8(0x0e45));
-  addAccents("\\thaiMaiyamok", getutf8(0x0e46));
-  addAccents("\\thaiMaitaikhu", getutf8(0x0e47));
-  addAccents("\\thaiMaiEk", getutf8(0x0e48));
-  addAccents("\\thaiMaiTho", getutf8(0x0e49));
-  addAccents("\\thaiMaiTri", getutf8(0x0e4a));
-  addAccents("\\thaiMaiChattawa", getutf8(0x0e4b));
-  addAccents("\\thaiThanthakhat", getutf8(0x0e4c));
-  addAccents("\\thaiNikhahit", getutf8(0x0e4d));
-  addAccents("\\thaiYamakkan", getutf8(0x0e4e));
-  addAccents("\\thaiFongman", getutf8(0x0e4f));
-  addAccents("\\thaizero", getutf8(0x0e50));
-  addAccents("\\thaione", getutf8(0x0e51));
-  addAccents("\\thaitwo", getutf8(0x0e52));
-  addAccents("\\thaithree", getutf8(0x0e53));
-  addAccents("\\thaifour", getutf8(0x0e54));
-  addAccents("\\thaifive", getutf8(0x0e55));
-  addAccents("\\thaisix", getutf8(0x0e56));
-  addAccents("\\thaiseven", getutf8(0x0e57));
-  addAccents("\\thaieight", getutf8(0x0e58));
-  addAccents("\\thainine", getutf8(0x0e59));
-  addAccents("\\thaiAngkhankhu", getutf8(0x0e5a));
-  addAccents("\\thaiKhomut", getutf8(0x0e5b));
-  addAccents("\\dag", getutf8(0x2020));
-  addAccents("\\dagger", getutf8(0x2020));
-  addAccents("\\textdagger", getutf8(0x2020));
-  addAccents("\\ddag", getutf8(0x2021));
-  addAccents("\\ddagger", getutf8(0x2021));
-  addAccents("\\textdaggerdbl", getutf8(0x2021));
-  addAccents("\\textbullet", getutf8(0x2022));
-  addAccents("\\bullet", getutf8(0x2022));
-  addAccents("\\dots", getutf8(0x2026));
-  addAccents("\\ldots", getutf8(0x2026));
-  addAccents("\\textellipsis", getutf8(0x2026));
-  addAccents("\\textasciiacute", getutf8(0x2032));
-  addAccents("\\prime", getutf8(0x2032));
-  addAccents("\\textacutedbl", getutf8(0x2033));
-  addAccents("\\dprime", getutf8(0x2033));
-  addAccents("\\textasciigrave", getutf8(0x2035));
-  addAccents("\\backprime", getutf8(0x2035));
-  addAccents("\\textsubcircum{ }", getutf8(0x2038));
-  addAccents("\\caretinsert", getutf8(0x2038));
-  addAccents("\\textasteriskcentered", getutf8(0x204e));
-  addAccents("\\ast", getutf8(0x204e));
-  addAccents("\\textmho", getutf8(0x2127));
-  addAccents("\\mho", getutf8(0x2127));
-  addAccents("\\textleftarrow", getutf8(0x2190));
-  addAccents("\\leftarrow", getutf8(0x2190));
-  addAccents("\\textuparrow", getutf8(0x2191));
-  addAccents("\\uparrow", getutf8(0x2191));
-  addAccents("\\textrightarrow", getutf8(0x2192));
-  addAccents("\\rightarrow", getutf8(0x2192));
-  addAccents("\\textdownarrow", getutf8(0x2193));
-  addAccents("\\downarrow", getutf8(0x2193));
-  addAccents("\\textglobrise", getutf8(0x2197));
-  addAccents("\\nearrow", getutf8(0x2197));
-  addAccents("\\textglobfall", getutf8(0x2198));
-  addAccents("\\searrow", getutf8(0x2198));
-  addAccents("\\textsurd", getutf8(0x221a));
-  addAccents("\\surd", getutf8(0x221a));
-  addAccents("\\textbigcircle", getutf8(0x25ef));
-  addAccents("\\bigcirc", getutf8(0x25ef));
-  addAccents("\\FiveStar", getutf8(0x2605));
-  addAccents("\\bigstar", getutf8(0x2605));
-  addAccents("\\FiveStarOpen", getutf8(0x2606));
-  addAccents("\\bigwhitestar", getutf8(0x2606));
-  addAccents("\\Checkmark", getutf8(0x2713));
-  addAccents("\\checkmark", getutf8(0x2713));
-  addAccents("\\CrossMaltese", getutf8(0x2720));
-  addAccents("\\maltese", getutf8(0x2720));
-  addAccents("\\textlangle", getutf8(0x27e8));
-  addAccents("\\langle", getutf8(0x27e8));
-  addAccents("\\textrangle", getutf8(0x27e9));
-  addAccents("\\rangle", getutf8(0x27e9));
+	addAccents("\\pounds", getutf8(0x00a3));
+	addAccents("\\textsterling", getutf8(0x00a3));
+	addAccents("\\textyen", getutf8(0x00a5));
+	addAccents("\\yen", getutf8(0x00a5));
+	addAccents("\\textsection", getutf8(0x00a7));
+	addAccents("\\mathsection", getutf8(0x00a7));
+	addAccents("\\textcopyright", getutf8(0x00a9));
+	addAccents("\\copyright", getutf8(0x00a9));
+	addAccents("\\textlnot", getutf8(0x00ac));
+	addAccents("\\neg", getutf8(0x00ac));
+	addAccents("\\textregistered", getutf8(0x00ae));
+	addAccents("\\circledR", getutf8(0x00ae));
+	addAccents("\\textpm", getutf8(0x00b1));
+	addAccents("\\pm", getutf8(0x00b1));
+	addAccents("\\textparagraph", getutf8(0x00b6));
+	addAccents("\\mathparagraph", getutf8(0x00b6));
+	addAccents("\\textperiodcentered", getutf8(0x00b7));
+	addAccents("\\texttimes", getutf8(0x00d7));
+	addAccents("\\times", getutf8(0x00d7));
+	addAccents("\\O", getutf8(0x00d8));
+	addAccents("\\dh", getutf8(0x00f0));
+	addAccents("\\eth", getutf8(0x00f0));
+	addAccents("\\textdiv", getutf8(0x00f7));
+	addAccents("\\div", getutf8(0x00f7));
+	addAccents("\\o", getutf8(0x00f8));
+	addAccents("\\textcrlambda", getutf8(0x019b));
+	addAccents("\\j", getutf8(0x0237));
+	addAccents("\\textrevepsilon", getutf8(0x025c));
+	addAccents("\\textbaru", getutf8(0x0289));
+	addAccents("\\textquoteleft", getutf8(0x02bb));
+	addAccents("\\textGamma", getutf8(0x0393));
+	addAccents("\\Gamma", getutf8(0x0393));
+	addAccents("\\textDelta", getutf8(0x0394));
+	addAccents("\\Delta", getutf8(0x0394));
+	addAccents("\\textTheta", getutf8(0x0398));
+	addAccents("\\Theta", getutf8(0x0398));
+	addAccents("\\textLambda", getutf8(0x039b));
+	addAccents("\\Lambda", getutf8(0x039b));
+	addAccents("\\textXi", getutf8(0x039e));
+	addAccents("\\Xi", getutf8(0x039e));
+	addAccents("\\textPi", getutf8(0x03a0));
+	addAccents("\\Pi", getutf8(0x03a0));
+	addAccents("\\textSigma", getutf8(0x03a3));
+	addAccents("\\Sigma", getutf8(0x03a3));
+	addAccents("\\textUpsilon", getutf8(0x03a5));
+	addAccents("\\Upsilon", getutf8(0x03a5));
+	addAccents("\\textPhi", getutf8(0x03a6));
+	addAccents("\\Phi", getutf8(0x03a6));
+	addAccents("\\textPsi", getutf8(0x03a8));
+	addAccents("\\Psi", getutf8(0x03a8));
+	addAccents("\\textOmega", getutf8(0x03a9));
+	addAccents("\\Omega", getutf8(0x03a9));
+	addAccents("\\textalpha", getutf8(0x03b1));
+	addAccents("\\alpha", getutf8(0x03b1));
+	addAccents("\\textbeta", getutf8(0x03b2));
+	addAccents("\\beta", getutf8(0x03b2));
+	addAccents("\\textgamma", getutf8(0x03b3));
+	addAccents("\\gamma", getutf8(0x03b3));
+	addAccents("\\textdelta", getutf8(0x03b4));
+	addAccents("\\delta", getutf8(0x03b4));
+	addAccents("\\textepsilon", getutf8(0x03b5));
+	addAccents("\\varepsilon", getutf8(0x03b5));
+	addAccents("\\textzeta", getutf8(0x03b6));
+	addAccents("\\zeta", getutf8(0x03b6));
+	addAccents("\\texteta", getutf8(0x03b7));
+	addAccents("\\eta", getutf8(0x03b7));
+	addAccents("\\texttheta", getutf8(0x03b8));
+	addAccents("\\theta", getutf8(0x03b8));
+	addAccents("\\textiota", getutf8(0x03b9));
+	addAccents("\\iota", getutf8(0x03b9));
+	addAccents("\\textkappa", getutf8(0x03ba));
+	addAccents("\\kappa", getutf8(0x03ba));
+	addAccents("\\textlambda", getutf8(0x03bb));
+	addAccents("\\lambda", getutf8(0x03bb));
+	addAccents("\\textmu", getutf8(0x03bc));
+	addAccents("\\mu", getutf8(0x03bc));
+	addAccents("\\textnu", getutf8(0x03bd));
+	addAccents("\\nu", getutf8(0x03bd));
+	addAccents("\\textxi", getutf8(0x03be));
+	addAccents("\\xi", getutf8(0x03be));
+	addAccents("\\textpi", getutf8(0x03c0));
+	addAccents("\\pi", getutf8(0x03c0));
+	addAccents("\\textrho", getutf8(0x03c1));
+	addAccents("\\rho", getutf8(0x03c1));
+	addAccents("\\textfinalsigma", getutf8(0x03c2));
+	addAccents("\\varsigma", getutf8(0x03c2));
+	addAccents("\\textsigma", getutf8(0x03c3));
+	addAccents("\\sigma", getutf8(0x03c3));
+	addAccents("\\texttau", getutf8(0x03c4));
+	addAccents("\\tau", getutf8(0x03c4));
+	addAccents("\\textupsilon", getutf8(0x03c5));
+	addAccents("\\upsilon", getutf8(0x03c5));
+	addAccents("\\textphi", getutf8(0x03c6));
+	addAccents("\\varphi", getutf8(0x03c6));
+	addAccents("\\textchi", getutf8(0x03c7));
+	addAccents("\\chi", getutf8(0x03c7));
+	addAccents("\\textpsi", getutf8(0x03c8));
+	addAccents("\\psi", getutf8(0x03c8));
+	addAccents("\\textomega", getutf8(0x03c9));
+	addAccents("\\omega", getutf8(0x03c9));
+	addAccents("\\textdigamma", getutf8(0x03dd));
+	addAccents("\\digamma", getutf8(0x03dd));
+	addAccents("\\hebalef", getutf8(0x05d0));
+	addAccents("\\aleph", getutf8(0x05d0));
+	addAccents("\\hebbet", getutf8(0x05d1));
+	addAccents("\\beth", getutf8(0x05d1));
+	addAccents("\\hebgimel", getutf8(0x05d2));
+	addAccents("\\gimel", getutf8(0x05d2));
+	addAccents("\\hebdalet", getutf8(0x05d3));
+	addAccents("\\daleth", getutf8(0x05d3));
+	addAccents("\\hebhe", getutf8(0x05d4));
+	addAccents("\\hebvav", getutf8(0x05d5));
+	addAccents("\\hebzayin", getutf8(0x05d6));
+	addAccents("\\hebhet", getutf8(0x05d7));
+	addAccents("\\hebtet", getutf8(0x05d8));
+	addAccents("\\hebyod", getutf8(0x05d9));
+	addAccents("\\hebfinalkaf", getutf8(0x05da));
+	addAccents("\\hebkaf", getutf8(0x05db));
+	addAccents("\\heblamed", getutf8(0x05dc));
+	addAccents("\\hebfinalmem", getutf8(0x05dd));
+	addAccents("\\hebmem", getutf8(0x05de));
+	addAccents("\\hebfinalnun", getutf8(0x05df));
+	addAccents("\\hebnun", getutf8(0x05e0));
+	addAccents("\\hebsamekh", getutf8(0x05e1));
+	addAccents("\\hebayin", getutf8(0x05e2));
+	addAccents("\\hebfinalpe", getutf8(0x05e3));
+	addAccents("\\hebpe", getutf8(0x05e4));
+	addAccents("\\hebfinaltsadi", getutf8(0x05e5));
+	addAccents("\\hebtsadi", getutf8(0x05e6));
+	addAccents("\\hebqof", getutf8(0x05e7));
+	addAccents("\\hebresh", getutf8(0x05e8));
+	addAccents("\\hebshin", getutf8(0x05e9));
+	addAccents("\\hebtav", getutf8(0x05ea));
+
+	// Thai characters
+	addAccents("\\thaiKoKai", getutf8(0x0e01));
+	addAccents("\\thaiKhoKhai", getutf8(0x0e02));
+	addAccents("\\thaiKhoKhuat", getutf8(0x0e03));
+	addAccents("\\thaiKhoKhwai", getutf8(0x0e04));
+	addAccents("\\thaiKhoKhon", getutf8(0x0e05));
+	addAccents("\\thaiKhoRakhang", getutf8(0x0e06));
+	addAccents("\\thaiNgoNgu", getutf8(0x0e07));
+	addAccents("\\thaiChoChan", getutf8(0x0e08));
+	addAccents("\\thaiChoChing", getutf8(0x0e09));
+	addAccents("\\thaiChoChang", getutf8(0x0e0a));
+	addAccents("\\thaiSoSo", getutf8(0x0e0b));
+	addAccents("\\thaiChoChoe", getutf8(0x0e0c));
+	addAccents("\\thaiYoYing", getutf8(0x0e0d));
+	addAccents("\\thaiDoChada", getutf8(0x0e0e));
+	addAccents("\\thaiToPatak", getutf8(0x0e0f));
+	addAccents("\\thaiThoThan", getutf8(0x0e10));
+	addAccents("\\thaiThoNangmontho", getutf8(0x0e11));
+	addAccents("\\thaiThoPhuthao", getutf8(0x0e12));
+	addAccents("\\thaiNoNen", getutf8(0x0e13));
+	addAccents("\\thaiDoDek", getutf8(0x0e14));
+	addAccents("\\thaiToTao", getutf8(0x0e15));
+	addAccents("\\thaiThoThung", getutf8(0x0e16));
+	addAccents("\\thaiThoThahan", getutf8(0x0e17));
+	addAccents("\\thaiThoThong", getutf8(0x0e18));
+	addAccents("\\thaiNoNu", getutf8(0x0e19));
+	addAccents("\\thaiBoBaimai", getutf8(0x0e1a));
+	addAccents("\\thaiPoPla", getutf8(0x0e1b));
+	addAccents("\\thaiPhoPhung", getutf8(0x0e1c));
+	addAccents("\\thaiFoFa", getutf8(0x0e1d));
+	addAccents("\\thaiPhoPhan", getutf8(0x0e1e));
+	addAccents("\\thaiFoFan", getutf8(0x0e1f));
+	addAccents("\\thaiPhoSamphao", getutf8(0x0e20));
+	addAccents("\\thaiMoMa", getutf8(0x0e21));
+	addAccents("\\thaiYoYak", getutf8(0x0e22));
+	addAccents("\\thaiRoRua", getutf8(0x0e23));
+	addAccents("\\thaiRu", getutf8(0x0e24));
+	addAccents("\\thaiLoLing", getutf8(0x0e25));
+	addAccents("\\thaiLu", getutf8(0x0e26));
+	addAccents("\\thaiWoWaen", getutf8(0x0e27));
+	addAccents("\\thaiSoSala", getutf8(0x0e28));
+	addAccents("\\thaiSoRusi", getutf8(0x0e29));
+	addAccents("\\thaiSoSua", getutf8(0x0e2a));
+	addAccents("\\thaiHoHip", getutf8(0x0e2b));
+	addAccents("\\thaiLoChula", getutf8(0x0e2c));
+	addAccents("\\thaiOAng", getutf8(0x0e2d));
+	addAccents("\\thaiHoNokhuk", getutf8(0x0e2e));
+	addAccents("\\thaiPaiyannoi", getutf8(0x0e2f));
+	addAccents("\\thaiSaraA", getutf8(0x0e30));
+	addAccents("\\thaiMaiHanakat", getutf8(0x0e31));
+	addAccents("\\thaiSaraAa", getutf8(0x0e32));
+	addAccents("\\thaiSaraAm", getutf8(0x0e33));
+	addAccents("\\thaiSaraI", getutf8(0x0e34));
+	addAccents("\\thaiSaraIi", getutf8(0x0e35));
+	addAccents("\\thaiSaraUe", getutf8(0x0e36));
+	addAccents("\\thaiSaraUee", getutf8(0x0e37));
+	addAccents("\\thaiSaraU", getutf8(0x0e38));
+	addAccents("\\thaiSaraUu", getutf8(0x0e39));
+	addAccents("\\thaiPhinthu", getutf8(0x0e3a));
+	addAccents("\\thaiSaraE", getutf8(0x0e40));
+	addAccents("\\thaiSaraAe", getutf8(0x0e41));
+	addAccents("\\thaiSaraO", getutf8(0x0e42));
+	addAccents("\\thaiSaraAiMaimuan", getutf8(0x0e43));
+	addAccents("\\thaiSaraAiMaimalai", getutf8(0x0e44));
+	addAccents("\\thaiLakkhangyao", getutf8(0x0e45));
+	addAccents("\\thaiMaiyamok", getutf8(0x0e46));
+	addAccents("\\thaiMaitaikhu", getutf8(0x0e47));
+	addAccents("\\thaiMaiEk", getutf8(0x0e48));
+	addAccents("\\thaiMaiTho", getutf8(0x0e49));
+	addAccents("\\thaiMaiTri", getutf8(0x0e4a));
+	addAccents("\\thaiMaiChattawa", getutf8(0x0e4b));
+	addAccents("\\thaiThanthakhat", getutf8(0x0e4c));
+	addAccents("\\thaiNikhahit", getutf8(0x0e4d));
+	addAccents("\\thaiYamakkan", getutf8(0x0e4e));
+	addAccents("\\thaiFongman", getutf8(0x0e4f));
+	addAccents("\\thaizero", getutf8(0x0e50));
+	addAccents("\\thaione", getutf8(0x0e51));
+	addAccents("\\thaitwo", getutf8(0x0e52));
+	addAccents("\\thaithree", getutf8(0x0e53));
+	addAccents("\\thaifour", getutf8(0x0e54));
+	addAccents("\\thaifive", getutf8(0x0e55));
+	addAccents("\\thaisix", getutf8(0x0e56));
+	addAccents("\\thaiseven", getutf8(0x0e57));
+	addAccents("\\thaieight", getutf8(0x0e58));
+	addAccents("\\thainine", getutf8(0x0e59));
+	addAccents("\\thaiAngkhankhu", getutf8(0x0e5a));
+	addAccents("\\thaiKhomut", getutf8(0x0e5b));
+	addAccents("\\dag", getutf8(0x2020));
+	addAccents("\\dagger", getutf8(0x2020));
+	addAccents("\\textdagger", getutf8(0x2020));
+	addAccents("\\ddag", getutf8(0x2021));
+	addAccents("\\ddagger", getutf8(0x2021));
+	addAccents("\\textdaggerdbl", getutf8(0x2021));
+	addAccents("\\textbullet", getutf8(0x2022));
+	addAccents("\\bullet", getutf8(0x2022));
+	addAccents("\\dots", getutf8(0x2026));
+	addAccents("\\ldots", getutf8(0x2026));
+	addAccents("\\textellipsis", getutf8(0x2026));
+	addAccents("\\textasciiacute", getutf8(0x2032));
+	addAccents("\\prime", getutf8(0x2032));
+	addAccents("\\textacutedbl", getutf8(0x2033));
+	addAccents("\\dprime", getutf8(0x2033));
+	addAccents("\\textasciigrave", getutf8(0x2035));
+	addAccents("\\backprime", getutf8(0x2035));
+	addAccents("\\textsubcircum{ }", getutf8(0x2038));
+	addAccents("\\caretinsert", getutf8(0x2038));
+	addAccents("\\textasteriskcentered", getutf8(0x204e));
+	addAccents("\\ast", getutf8(0x204e));
+	addAccents("\\textmho", getutf8(0x2127));
+	addAccents("\\mho", getutf8(0x2127));
+	addAccents("\\textleftarrow", getutf8(0x2190));
+	addAccents("\\leftarrow", getutf8(0x2190));
+	addAccents("\\textuparrow", getutf8(0x2191));
+	addAccents("\\uparrow", getutf8(0x2191));
+	addAccents("\\textrightarrow", getutf8(0x2192));
+	addAccents("\\rightarrow", getutf8(0x2192));
+	addAccents("\\textdownarrow", getutf8(0x2193));
+	addAccents("\\downarrow", getutf8(0x2193));
+	addAccents("\\textglobrise", getutf8(0x2197));
+	addAccents("\\nearrow", getutf8(0x2197));
+	addAccents("\\textglobfall", getutf8(0x2198));
+	addAccents("\\searrow", getutf8(0x2198));
+	addAccents("\\textsurd", getutf8(0x221a));
+	addAccents("\\surd", getutf8(0x221a));
+	addAccents("\\textbigcircle", getutf8(0x25ef));
+	addAccents("\\bigcirc", getutf8(0x25ef));
+	addAccents("\\FiveStar", getutf8(0x2605));
+	addAccents("\\bigstar", getutf8(0x2605));
+	addAccents("\\FiveStarOpen", getutf8(0x2606));
+	addAccents("\\bigwhitestar", getutf8(0x2606));
+	addAccents("\\Checkmark", getutf8(0x2713));
+	addAccents("\\checkmark", getutf8(0x2713));
+	addAccents("\\CrossMaltese", getutf8(0x2720));
+	addAccents("\\maltese", getutf8(0x2720));
+	addAccents("\\textlangle", getutf8(0x27e8));
+	addAccents("\\langle", getutf8(0x27e8));
+	addAccents("\\textrangle", getutf8(0x27e9));
+	addAccents("\\rangle", getutf8(0x27e9));
 }
 
 static void buildAccentsMap()
 {
-  accents["imath"] = "ı";
-  accents["i"] = "ı";
-  accents["jmath"] = "È·";
-  accents["cdot"] = "·";
-  accents["textasciicircum"] = "^";
-  accents["mathcircumflex"] = "^";
-  accents["sim"] = "~";
-  accents["guillemotright"] = "»";
-  accents["guillemotleft"] = "«";
-  accents["hairspace"]     = getutf8(0xf0000);	// select from free unicode plane 15
-  accents["thinspace"]     = getutf8(0xf0002);	// and used _only_ by findadv
-  accents["negthinspace"]  = getutf8(0xf0003);	// to omit backslashed latex macros
-  accents["medspace"]      = getutf8(0xf0004);	// See https://en.wikipedia.org/wiki/Private_Use_Areas
-  accents["negmedspace"]   = getutf8(0xf0005);
-  accents["thickspace"]    = getutf8(0xf0006);
-  accents["negthickspace"] = getutf8(0xf0007);
-  accents["lyx"]           = getutf8(0xf0010);	// Used logos
-  accents["LyX"]           = getutf8(0xf0010);
-  accents["tex"]           = getutf8(0xf0011);
-  accents["TeX"]           = getutf8(0xf0011);
-  accents["latex"]         = getutf8(0xf0012);
-  accents["LaTeX"]         = getutf8(0xf0012);
-  accents["latexe"]        = getutf8(0xf0013);
-  accents["LaTeXe"]        = getutf8(0xf0013);
-  accents["lyxarrow"]      = getutf8(0xf0020);
-  accents["braceleft"]     = getutf8(0xf0030);
-  accents["braceright"]    = getutf8(0xf0031);
-  accents["backslash lyx"]           = getutf8(0xf0010);	// Used logos inserted with starting \backslash
-  accents["backslash LyX"]           = getutf8(0xf0010);
-  accents["backslash tex"]           = getutf8(0xf0011);
-  accents["backslash TeX"]           = getutf8(0xf0011);
-  accents["backslash latex"]         = getutf8(0xf0012);
-  accents["backslash LaTeX"]         = getutf8(0xf0012);
-  accents["backslash latexe"]        = getutf8(0xf0013);
-  accents["backslash LaTeXe"]        = getutf8(0xf0013);
-  accents["backslash lyxarrow"]      = getutf8(0xf0020);
-  accents["ddot{\\imath}"] = "ï";
-  buildaccent("ddot", "aAeEhHiIoOtuUwWxXyY",
-                      "äÄëËḧḦïÏöÖẗüÜẅẄẍẌÿŸ");	// umlaut
-  buildaccent("dot|.", "aAbBcCdDeEfFGghHIimMnNoOpPrRsStTwWxXyYzZ",
-                       "ȧȦḃḂċĊḋḊėĖḟḞĠġḣḢİİṁṀṅṄȯȮṗṖṙṘṡṠṫṪẇẆẋẊẏẎżŻ");	// dot{i} can only happen if ignoring case, but there is no lowercase of 'İ'
-  accents["acute{\\imath}"] = "í";
-  buildaccent("acute", "aAcCeEgGkKlLmMoOnNpPrRsSuUwWyYzZiI",
-                       "áÁćĆéÉǵǴḱḰĺĹḿḾóÓńŃṕṔŕŔśŚúÚẃẂýÝźŹíÍ");
-  buildaccent("dacute|H|h", "oOuU", "őŐűŰ");	// double acute
-  buildaccent("mathring|r", "aAuUwy",
-                            "åÅůŮẘẙ");	// ring
-  accents["check{\\imath}"] = "ǐ";
-  accents["check{\\jmath}"] = "Ç°";
-  buildaccent("check|v", "cCdDaAeEiIoOuUgGkKhHlLnNrRsSTtzZ",
-                         "čČďĎǎǍěĚǐǏǒǑǔǓǧǦǩǨȟȞľĽňŇřŘšŠŤťžŽ");	// caron
-  accents["hat{\\imath}"] = "î";
-  accents["hat{\\jmath}"] = "ĵ";
-  buildaccent("hat|^", "aAcCeEgGhHiIjJoOsSuUwWyYzZ",
-                       "âÂĉĈêÊĝĜĥĤîÎĵĴôÔŝŜûÛŵŴŷŶẑẐ");	// circ
-  accents["bar{\\imath}"] = "Ä«";
-  buildaccent("bar|=", "aAeEiIoOuUyY",
-                       "āĀēĒīĪōŌūŪȳȲ");	// macron
-  accents["tilde{\\imath}"] = "Ä©";
-  buildaccent("tilde", "aAeEiInNoOuUvVyY",
-                       "ãÃẽẼĩĨñÑõÕũŨṽṼỹỸ");	// tilde
-  accents["breve{\\imath}"] = "Ä­";
-  buildaccent("breve|u", "aAeEgGiIoOuU",
-                         "ăĂĕĔğĞĭĬŏŎŭŬ");	// breve
-  accents["grave{\\imath}"] = "ì";
-  buildaccent("grave|`", "aAeEiIoOuUnNwWyY",
-                         "àÀèÈìÌòÒùÙǹǸẁẀỳỲ");	// grave
-  buildaccent("subdot|d", "BbDdHhKkLlMmNnRrSsTtVvWwZzAaEeIiOoUuYy",
-                          "ḄḅḌḍḤḥḲḳḶḷṂṃṆṇṚṛṢṣṬṭṾṿẈẉẒẓẠạẸẹỊịỌọỤụỴỵ");	// dot below
-  buildaccent("ogonek|k", "AaEeIiUuOo",
-                          "ĄąĘęĮįŲųǪǫ");	// ogonek
-  buildaccent("cedilla|c", "CcGgKkLlNnRrSsTtEeDdHh",
-                           "ÇçĢģĶķĻļŅņŖŗŞşŢţȨȩḐḑḨḩ");	// cedilla
-  buildaccent("subring|textsubring", "Aa",
-                                     "Ḁḁ");	// subring
-  buildaccent("subhat|textsubcircum", "DdEeLlNnTtUu",
-                                      "ḒḓḘḙḼḽṊṋṰṱṶṷ");	// subcircum
-  buildaccent("subtilde|textsubtilde", "EeIiUu",
-                                       "ḚḛḬḭṴṵ");	// subtilde
-  accents["dgrave{\\imath}"] = "ȉ";
-  accents["textdoublegrave{\\i}"] = "ȉ";
-  buildaccent("dgrave|textdoublegrave", "AaEeIiOoRrUu",
-                                        "ȀȁȄȅȈȉȌȍȐȑȔȕ"); // double grave
-  accents["rcap{\\imath}"] = "È‹";
-  accents["textroundcap{\\i}"] = "È‹";
-  buildaccent("rcap|textroundcap", "AaEeIiOoRrUu",
-                                   "ȂȃȆȇȊȋȎȏȒȓȖȗ"); // inverted breve
-  buildaccent("slashed", "oO",
-                         "øØ"); // slashed
-  fillMissingUnicodesymbols(); // Add some still not handled entries contained in 'unicodesynbols'
-  // LYXERR0("Number of accents " << accents.size());
+	accents["imath"] = "ı";
+	accents["i"] = "ı";
+	accents["jmath"] = "È·";
+	accents["cdot"] = "·";
+	accents["textasciicircum"] = "^";
+	accents["mathcircumflex"] = "^";
+	accents["sim"] = "~";
+	accents["guillemotright"] = "»";
+	accents["guillemotleft"] = "«";
+	accents["hairspace"]     = getutf8(0xf0000);	// select from free unicode plane 15
+	accents["thinspace"]     = getutf8(0xf0002);	// and used _only_ by findadv
+	accents["negthinspace"]  = getutf8(0xf0003);	// to omit backslashed latex macros
+	accents["medspace"]      = getutf8(0xf0004);	// See https://en.wikipedia.org/wiki/Private_Use_Areas
+	accents["negmedspace"]   = getutf8(0xf0005);
+	accents["thickspace"]    = getutf8(0xf0006);
+	accents["negthickspace"] = getutf8(0xf0007);
+	accents["lyx"]           = getutf8(0xf0010);	// Used logos
+	accents["LyX"]           = getutf8(0xf0010);
+	accents["tex"]           = getutf8(0xf0011);
+	accents["TeX"]           = getutf8(0xf0011);
+	accents["latex"]         = getutf8(0xf0012);
+	accents["LaTeX"]         = getutf8(0xf0012);
+	accents["latexe"]        = getutf8(0xf0013);
+	accents["LaTeXe"]        = getutf8(0xf0013);
+	accents["lyxarrow"]      = getutf8(0xf0020);
+	accents["braceleft"]     = getutf8(0xf0030);
+	accents["braceright"]    = getutf8(0xf0031);
+	accents["backslash lyx"]           = getutf8(0xf0010);	// Used logos inserted with starting \backslash
+	accents["backslash LyX"]           = getutf8(0xf0010);
+	accents["backslash tex"]           = getutf8(0xf0011);
+	accents["backslash TeX"]           = getutf8(0xf0011);
+	accents["backslash latex"]         = getutf8(0xf0012);
+	accents["backslash LaTeX"]         = getutf8(0xf0012);
+	accents["backslash latexe"]        = getutf8(0xf0013);
+	accents["backslash LaTeXe"]        = getutf8(0xf0013);
+	accents["backslash lyxarrow"]      = getutf8(0xf0020);
+	accents["ddot{\\imath}"] = "ï";
+	buildaccent("ddot", "aAeEhHiIoOtuUwWxXyY",
+		    "äÄëËḧḦïÏöÖẗüÜẅẄẍẌÿŸ");	// umlaut
+	buildaccent("dot|.", "aAbBcCdDeEfFGghHIimMnNoOpPrRsStTwWxXyYzZ",
+		    "ȧȦḃḂċĊḋḊėĖḟḞĠġḣḢİİṁṀṅṄȯȮṗṖṙṘṡṠṫṪẇẆẋẊẏẎżŻ");	// dot{i} can only happen if ignoring case, but there is no lowercase of 'İ'
+	accents["acute{\\imath}"] = "í";
+	buildaccent("acute", "aAcCeEgGkKlLmMoOnNpPrRsSuUwWyYzZiI",
+		    "áÁćĆéÉǵǴḱḰĺĹḿḾóÓńŃṕṔŕŔśŚúÚẃẂýÝźŹíÍ");
+	buildaccent("dacute|H|h", "oOuU", "őŐűŰ");	// double acute
+	buildaccent("mathring|r", "aAuUwy",
+		    "åÅůŮẘẙ");	// ring
+	accents["check{\\imath}"] = "ǐ";
+	accents["check{\\jmath}"] = "Ç°";
+	buildaccent("check|v", "cCdDaAeEiIoOuUgGkKhHlLnNrRsSTtzZ",
+		    "čČďĎǎǍěĚǐǏǒǑǔǓǧǦǩǨȟȞľĽňŇřŘšŠŤťžŽ");	// caron
+	accents["hat{\\imath}"] = "î";
+	accents["hat{\\jmath}"] = "ĵ";
+	buildaccent("hat|^", "aAcCeEgGhHiIjJoOsSuUwWyYzZ",
+		    "âÂĉĈêÊĝĜĥĤîÎĵĴôÔŝŜûÛŵŴŷŶẑẐ");	// circ
+	accents["bar{\\imath}"] = "Ä«";
+	buildaccent("bar|=", "aAeEiIoOuUyY",
+		    "āĀēĒīĪōŌūŪȳȲ");	// macron
+	accents["tilde{\\imath}"] = "Ä©";
+	buildaccent("tilde", "aAeEiInNoOuUvVyY",
+		    "ãÃẽẼĩĨñÑõÕũŨṽṼỹỸ");	// tilde
+	accents["breve{\\imath}"] = "Ä­";
+	buildaccent("breve|u", "aAeEgGiIoOuU",
+		    "ăĂĕĔğĞĭĬŏŎŭŬ");	// breve
+	accents["grave{\\imath}"] = "ì";
+	buildaccent("grave|`", "aAeEiIoOuUnNwWyY",
+		    "àÀèÈìÌòÒùÙǹǸẁẀỳỲ");	// grave
+	buildaccent("subdot|d", "BbDdHhKkLlMmNnRrSsTtVvWwZzAaEeIiOoUuYy",
+		    "ḄḅḌḍḤḥḲḳḶḷṂṃṆṇṚṛṢṣṬṭṾṿẈẉẒẓẠạẸẹỊịỌọỤụỴỵ");	// dot below
+	buildaccent("ogonek|k", "AaEeIiUuOo",
+		    "ĄąĘęĮįŲųǪǫ");	// ogonek
+	buildaccent("cedilla|c", "CcGgKkLlNnRrSsTtEeDdHh",
+		    "ÇçĢģĶķĻļŅņŖŗŞşŢţȨȩḐḑḨḩ");	// cedilla
+	buildaccent("subring|textsubring", "Aa",
+		    "Ḁḁ");	// subring
+	buildaccent("subhat|textsubcircum", "DdEeLlNnTtUu",
+		    "ḒḓḘḙḼḽṊṋṰṱṶṷ");	// subcircum
+	buildaccent("subtilde|textsubtilde", "EeIiUu",
+		    "ḚḛḬḭṴṵ");	// subtilde
+	accents["dgrave{\\imath}"] = "ȉ";
+	accents["textdoublegrave{\\i}"] = "ȉ";
+	buildaccent("dgrave|textdoublegrave", "AaEeIiOoRrUu",
+		    "ȀȁȄȅȈȉȌȍȐȑȔȕ"); // double grave
+	accents["rcap{\\imath}"] = "È‹";
+	accents["textroundcap{\\i}"] = "È‹";
+	buildaccent("rcap|textroundcap", "AaEeIiOoRrUu",
+		    "ȂȃȆȇȊȋȎȏȒȓȖȗ"); // inverted breve
+	buildaccent("slashed", "oO",
+		    "øØ"); // slashed
+	fillMissingUnicodesymbols(); // Add some still not handled entries contained in 'unicodesynbols'
+	// LYXERR0("Number of accents " << accents.size());
 }
 
 /*
@@ -1968,94 +1968,94 @@ static void buildAccentsMap()
  */
 void Intervall::removeAccents()
 {
-  if (accents.empty())
-    buildAccentsMap();
-  static regex const accre("\\\\("
-      "([\\S]|[A-Za-z]+)\\{[^\\{\\}]+\\}"
-      "|("
-	 "(backslash ([lL]y[xX]|[tT]e[xX]|[lL]a[tT]e[xX]e?|lyxarrow))"
-	"|[A-Za-z]+"
-      ")"
-      "(?![a-zA-Z]))");
-  smatch sub;
-  for (sregex_iterator itacc(par.begin(), par.end(), accre), end; itacc != end; ++itacc) {
-    sub = *itacc;
-    string key = sub.str(1);
-    AccentsIterator it_ac = accents.find(key);
-    if (it_ac != accents.end()) {
-      string val = it_ac->second;
-      size_t pos = sub.position(size_t(0));
-      for (size_t i = 0; i < val.size(); i++) {
-        par[pos+i] = val[i];
-      }
-      // Remove possibly following space too
-      if (par[pos+sub.str(0).size()] == ' ')
-        addIntervall(pos+val.size(), pos + sub.str(0).size()+1);
-      else
-        addIntervall(pos+val.size(), pos + sub.str(0).size());
-      for (size_t i = pos+val.size(); i < pos + sub.str(0).size(); i++) {
-        // remove traces of any remaining chars
-        par[i] = ' ';
-      }
-    }
-    else {
-      LYXERR(Debug::INFO, "Not added accent for \"" << key << "\"");
-    }
-  }
+	if (accents.empty())
+		buildAccentsMap();
+	static regex const accre("\\\\("
+				 "([\\S]|[A-Za-z]+)\\{[^\\{\\}]+\\}"
+				 "|("
+				 "(backslash ([lL]y[xX]|[tT]e[xX]|[lL]a[tT]e[xX]e?|lyxarrow))"
+				 "|[A-Za-z]+"
+				 ")"
+				 "(?![a-zA-Z]))");
+	smatch sub;
+	for (sregex_iterator itacc(par.begin(), par.end(), accre), end; itacc != end; ++itacc) {
+		sub = *itacc;
+		string key = sub.str(1);
+		AccentsIterator it_ac = accents.find(key);
+		if (it_ac != accents.end()) {
+			string val = it_ac->second;
+			size_t pos = sub.position(size_t(0));
+			for (size_t i = 0; i < val.size(); i++) {
+				par[pos+i] = val[i];
+			}
+			// Remove possibly following space too
+			if (par[pos+sub.str(0).size()] == ' ')
+				addIntervall(pos+val.size(), pos + sub.str(0).size()+1);
+			else
+				addIntervall(pos+val.size(), pos + sub.str(0).size());
+			for (size_t i = pos+val.size(); i < pos + sub.str(0).size(); i++) {
+				// remove traces of any remaining chars
+				par[i] = ' ';
+			}
+		}
+		else {
+			LYXERR(Debug::INFO, "Not added accent for \"" << key << "\"");
+		}
+	}
 }
 
 void Intervall::handleOpenP(int i)
 {
-  actualdeptindex++;
-  depts[actualdeptindex] = i+1;
-  closes[actualdeptindex] = -1;
-  checkDepthIndex(actualdeptindex);
+	actualdeptindex++;
+	depts[actualdeptindex] = i+1;
+	closes[actualdeptindex] = -1;
+	checkDepthIndex(actualdeptindex);
 }
 
 void Intervall::handleCloseP(int i, bool closingAllowed)
 {
-  if (actualdeptindex <= 0) {
-    if (! closingAllowed)
-      LYXERR(Debug::FIND, "Bad closing parenthesis in latex");  /* should not happen, but the latex input may be wrong */
-    // if we are at the very end
-    addIntervall(i, i+1);
-  }
-  else {
-    closes[actualdeptindex] = i+1;
-    actualdeptindex--;
-  }
+	if (actualdeptindex <= 0) {
+		if (! closingAllowed)
+			LYXERR(Debug::FIND, "Bad closing parenthesis in latex");  /* should not happen, but the latex input may be wrong */
+		// if we are at the very end
+		addIntervall(i, i+1);
+	}
+	else {
+		closes[actualdeptindex] = i+1;
+		actualdeptindex--;
+	}
 }
 
 void Intervall::resetOpenedP(int openPos)
 {
-  // Used as initializer for foreignlanguage entry
-  actualdeptindex = 1;
-  depts[1] = openPos+1;
-  closes[1] = -1;
+	// Used as initializer for foreignlanguage entry
+	actualdeptindex = 1;
+	depts[1] = openPos+1;
+	closes[1] = -1;
 }
 
 int Intervall::previousNotIgnored(int start) const
 {
-    int idx = 0;                          /* int intervalls */
-    for (idx = ignoreidx; idx >= 0; --idx) {
-      if (start > borders[idx].upper)
-        return start;
-      if (start >= borders[idx].low)
-        start = borders[idx].low-1;
-    }
-    return start;
+	int idx = 0;                          /* int intervalls */
+	for (idx = ignoreidx; idx >= 0; --idx) {
+		if (start > borders[idx].upper)
+			return start;
+		if (start >= borders[idx].low)
+			start = borders[idx].low-1;
+	}
+	return start;
 }
 
 int Intervall::nextNotIgnored(int start) const
 {
-    int idx = 0;                          /* int intervalls */
-    for (idx = 0; idx <= ignoreidx; idx++) {
-      if (start < borders[idx].low)
-        return start;
-      if (start < borders[idx].upper)
-        start = borders[idx].upper;
-    }
-    return start;
+	int idx = 0;                          /* int intervalls */
+	for (idx = 0; idx <= ignoreidx; idx++) {
+		if (start < borders[idx].low)
+			return start;
+		if (start < borders[idx].upper)
+			start = borders[idx].upper;
+	}
+	return start;
 }
 
 typedef unordered_map<string, KeyInfo> KeysMap;
@@ -2064,713 +2064,713 @@ typedef vector< KeyInfo> Entries;
 static KeysMap keys = unordered_map<string, KeyInfo>();
 
 class LatexInfo {
- private:
-  int entidx_;
-  Entries entries_;
-  Intervall interval_;
-  void buildKeys(bool);
-  void buildEntries(bool);
-  void makeKey(const string &, KeyInfo, bool isPatternString);
-  void processRegion(int start, int region_end); /*  remove {} parts */
-  void removeHead(KeyInfo const &, int count=0);
+private:
+	int entidx_;
+	Entries entries_;
+	Intervall interval_;
+	void buildKeys(bool);
+	void buildEntries(bool);
+	void makeKey(const string &, KeyInfo, bool isPatternString);
+	void processRegion(int start, int region_end); /*  remove {} parts */
+	void removeHead(KeyInfo const &, int count=0);
 
- public:
- LatexInfo(string const & par, bool isPatternString)
-         : entidx_(-1), interval_(isPatternString, par)
-  {
-    buildKeys(isPatternString);
-    entries_ = vector<KeyInfo>();
-    buildEntries(isPatternString);
-  }
-  int getFirstKey() {
-    entidx_ = 0;
-    if (entries_.empty()) {
-      return -1;
-    }
-    if (entries_[0].keytype == KeyInfo::isTitle) {
-      interval_.hasTitle = true;
-      if (! entries_[0].disabled) {
-        interval_.titleValue = entries_[0].head;
-      }
-      else {
-        interval_.titleValue = "";
-      }
-      removeHead(entries_[0]);
-      if (entries_.size() > 1)
-        return 1;
-      else
-        return -1;
-    }
-    return 0;
-  }
-  int getNextKey() {
-    entidx_++;
-    if (int(entries_.size()) > entidx_) {
-      return entidx_;
-    }
-    else {
-      return -1;
-    }
-  }
-  bool setNextKey(int idx) {
-    if ((idx == entidx_) && (entidx_ >= 0)) {
-      entidx_--;
-      return true;
-    }
-    else
-      return false;
-  }
-  int find(int start, KeyInfo::KeyType keytype) const {
-    if (start < 0)
-      return -1;
-    int tmpIdx = start;
-    while (tmpIdx < int(entries_.size())) {
-      if (entries_[tmpIdx].keytype == keytype)
-        return tmpIdx;
-      tmpIdx++;
-    }
-    return -1;
-  }
-  int process(ostringstream & os, KeyInfo const & actual);
-  int dispatch(ostringstream & os, int previousStart, KeyInfo & actual);
-  // string show(int lastpos) { return interval.show(lastpos);}
-  int nextNotIgnored(int start) { return interval_.nextNotIgnored(start);}
-  KeyInfo &getKeyInfo(int keyinfo) {
-    static KeyInfo invalidInfo = KeyInfo();
-    if ((keyinfo < 0) || ( keyinfo >= int(entries_.size())))
-      return invalidInfo;
-    else
-      return entries_[keyinfo];
-  }
-  void setForDefaultLang(KeyInfo const & defLang) {interval_.setForDefaultLang(defLang);}
-  void addIntervall(int low, int up) { interval_.addIntervall(low, up); }
+public:
+	LatexInfo(string const & par, bool isPatternString)
+		: entidx_(-1), interval_(isPatternString, par)
+	{
+		buildKeys(isPatternString);
+		entries_ = vector<KeyInfo>();
+		buildEntries(isPatternString);
+	}
+	int getFirstKey() {
+		entidx_ = 0;
+		if (entries_.empty()) {
+			return -1;
+		}
+		if (entries_[0].keytype == KeyInfo::isTitle) {
+			interval_.hasTitle = true;
+			if (! entries_[0].disabled) {
+				interval_.titleValue = entries_[0].head;
+			}
+			else {
+				interval_.titleValue = "";
+			}
+			removeHead(entries_[0]);
+			if (entries_.size() > 1)
+				return 1;
+			else
+				return -1;
+		}
+		return 0;
+	}
+	int getNextKey() {
+		entidx_++;
+		if (int(entries_.size()) > entidx_) {
+			return entidx_;
+		}
+		else {
+			return -1;
+		}
+	}
+	bool setNextKey(int idx) {
+		if ((idx == entidx_) && (entidx_ >= 0)) {
+			entidx_--;
+			return true;
+		}
+		else
+			return false;
+	}
+	int find(int start, KeyInfo::KeyType keytype) const {
+		if (start < 0)
+			return -1;
+		int tmpIdx = start;
+		while (tmpIdx < int(entries_.size())) {
+			if (entries_[tmpIdx].keytype == keytype)
+				return tmpIdx;
+			tmpIdx++;
+		}
+		return -1;
+	}
+	int process(ostringstream & os, KeyInfo const & actual);
+	int dispatch(ostringstream & os, int previousStart, KeyInfo & actual);
+	// string show(int lastpos) { return interval.show(lastpos);}
+	int nextNotIgnored(int start) { return interval_.nextNotIgnored(start);}
+	KeyInfo &getKeyInfo(int keyinfo) {
+		static KeyInfo invalidInfo = KeyInfo();
+		if ((keyinfo < 0) || ( keyinfo >= int(entries_.size())))
+			return invalidInfo;
+		else
+			return entries_[keyinfo];
+	}
+	void setForDefaultLang(KeyInfo const & defLang) {interval_.setForDefaultLang(defLang);}
+	void addIntervall(int low, int up) { interval_.addIntervall(low, up); }
 };
 
 
 int Intervall::findclosing(int start, int end, char up = '{', char down = '}', int repeat = 1)
 {
-  int skip = 0;
-  int depth = 0;
-  for (int i = start; i < end; i += 1 + skip) {
-    char c;
-    c = par[i];
-    skip = 0;
-    if (c == '\\') skip = 1;
-    else if (c == up) {
-      depth++;
-    }
-    else if (c == down) {
-      if (depth == 0) {
-        repeat--;
-        if ((repeat <= 0) || (par[i+1] != up))
-          return i;
-      }
-      --depth;
-    }
-  }
-  return end;
+	int skip = 0;
+	int depth = 0;
+	for (int i = start; i < end; i += 1 + skip) {
+		char c;
+		c = par[i];
+		skip = 0;
+		if (c == '\\') skip = 1;
+		else if (c == up) {
+			depth++;
+		}
+		else if (c == down) {
+			if (depth == 0) {
+				repeat--;
+				if ((repeat <= 0) || (par[i+1] != up))
+					return i;
+			}
+			--depth;
+		}
+	}
+	return end;
 }
 
 class MathInfo {
-  class MathEntry {
-  public:
-    string wait;
-    size_t mathEnd;
-    size_t mathpostfixsize;
-    size_t mathStart;
-    size_t mathprefixsize;
-    size_t mathSize;
-  };
-  size_t actualIdx_;
-  vector<MathEntry> entries_;
- public:
-  MathInfo() {
-    actualIdx_ = 0;
-  }
-  void insert(string const & wait, size_t start, size_t prefixsize, size_t end, size_t postfixsize) {
-    MathEntry m = MathEntry();
-    m.wait = wait;
-    m.mathStart = start;
-    m.mathprefixsize = prefixsize;
-    m.mathEnd = end + postfixsize;
-    m.mathpostfixsize = postfixsize;
-    m.mathSize = m.mathEnd - m.mathStart;
-    entries_.push_back(m);
-  }
-  bool empty() const { return entries_.empty(); }
-  size_t getEndPos() const {
-    if (entries_.empty() || (actualIdx_ >= entries_.size())) {
-      return 0;
-    }
-    return entries_[actualIdx_].mathEnd;
-  }
-  size_t getStartPos() const {
-    if (entries_.empty() || (actualIdx_ >= entries_.size())) {
-      return 100000;                    /*  definitely enough? */
-    }
-    return entries_[actualIdx_].mathStart;
-  }
-  size_t getPrefixSize() const {
-    if (entries_.empty() || (actualIdx_ >= entries_.size())) {
-      return 0;
-    }
-    return entries_[actualIdx_].mathprefixsize;
-  }
-  size_t getPostfixSize() const {
-    if (entries_.empty() || (actualIdx_ >= entries_.size())) {
-      return 0;
-    }
-    return entries_[actualIdx_].mathpostfixsize;
-  }
-  size_t getFirstPos() {
-    actualIdx_ = 0;
-    return getStartPos();
-  }
-  size_t getSize() const {
-    if (entries_.empty() || (actualIdx_ >= entries_.size())) {
-      return size_t(0);
-    }
-    return entries_[actualIdx_].mathSize;
-  }
-  void incrEntry() { actualIdx_++; }
+	class MathEntry {
+	public:
+		string wait;
+		size_t mathEnd;
+		size_t mathpostfixsize;
+		size_t mathStart;
+		size_t mathprefixsize;
+		size_t mathSize;
+	};
+	size_t actualIdx_;
+	vector<MathEntry> entries_;
+public:
+	MathInfo() {
+		actualIdx_ = 0;
+	}
+	void insert(string const & wait, size_t start, size_t prefixsize, size_t end, size_t postfixsize) {
+		MathEntry m = MathEntry();
+		m.wait = wait;
+		m.mathStart = start;
+		m.mathprefixsize = prefixsize;
+		m.mathEnd = end + postfixsize;
+		m.mathpostfixsize = postfixsize;
+		m.mathSize = m.mathEnd - m.mathStart;
+		entries_.push_back(m);
+	}
+	bool empty() const { return entries_.empty(); }
+	size_t getEndPos() const {
+		if (entries_.empty() || (actualIdx_ >= entries_.size())) {
+			return 0;
+		}
+		return entries_[actualIdx_].mathEnd;
+	}
+	size_t getStartPos() const {
+		if (entries_.empty() || (actualIdx_ >= entries_.size())) {
+			return 100000;                    /*  definitely enough? */
+		}
+		return entries_[actualIdx_].mathStart;
+	}
+	size_t getPrefixSize() const {
+		if (entries_.empty() || (actualIdx_ >= entries_.size())) {
+			return 0;
+		}
+		return entries_[actualIdx_].mathprefixsize;
+	}
+	size_t getPostfixSize() const {
+		if (entries_.empty() || (actualIdx_ >= entries_.size())) {
+			return 0;
+		}
+		return entries_[actualIdx_].mathpostfixsize;
+	}
+	size_t getFirstPos() {
+		actualIdx_ = 0;
+		return getStartPos();
+	}
+	size_t getSize() const {
+		if (entries_.empty() || (actualIdx_ >= entries_.size())) {
+			return size_t(0);
+		}
+		return entries_[actualIdx_].mathSize;
+	}
+	void incrEntry() { actualIdx_++; }
 };
 
 void LatexInfo::buildEntries(bool isPatternString)
 {
-  static regex const rmath("(\\\\)*(\\$|\\\\\\[|\\\\\\]|\\\\(begin|end)\\{((eqnarray|equation|flalign|gather|multline|align|x?x?alignat)\\*?\\})(\\{[0-9]+\\})?)");
-  static regex const rkeys("(\\\\)*(\\$|\\\\\\[|\\\\\\]|\\\\((([a-zA-Z]+\\*?)(\\{([a-z]+\\*?)\\}|=[0-9]+[a-z]+)?)))");
-  static bool disableLanguageOverride = false;
-  smatch sub, submath;
-  bool evaluatingRegexp = false;
-  MathInfo mi;
-  bool evaluatingMath = false;
-  bool evaluatingCode = false;
-  size_t codeEnd = 0;
-  bool evaluatingOptional = false;
-  size_t optionalEnd = 0;
-  int codeStart = -1;
-  KeyInfo found;
-  bool math_end_waiting = false;
-  size_t math_pos = 10000;
-  size_t math_prefix_size = 1;
-  string math_end;
-  static vector<string> usedText = vector<string>();
-  static bool removeMathHull = false;
-
-  interval_.removeAccents();
-
-  for (sregex_iterator itmath(interval_.par.begin(), interval_.par.end(), rmath), end; itmath != end; ++itmath) {
-    submath = *itmath;
-    if ((submath.position(2) - submath.position(0)) %2 == 1) {
-      // prefixed by odd count of '\\'
-      continue;
-    }
-    if (math_end_waiting) {
-      size_t pos = submath.position(size_t(2));
-      if ((math_end == "$") &&
-          (submath.str(2) == "$")) {
-        mi.insert("$", math_pos, 1, pos, 1);
-        math_end_waiting = false;
-      }
-      else if ((math_end == "\\]") &&
-               (submath.str(2) == "\\]")) {
-        mi.insert("\\]", math_pos, 2, pos, 2);
-        math_end_waiting = false;
-      }
-      else if ((submath.str(3).compare("end") == 0) &&
-          (submath.str(5).compare(math_end) == 0)) {
-        mi.insert(math_end, math_pos, math_prefix_size, pos, submath.str(2).length());
-        math_end_waiting = false;
-      }
-      else
-        continue;
-    }
-    else {
-      if (submath.str(3).compare("begin") == 0) {
-        math_end_waiting = true;
-        math_end = submath.str(5);
-        math_pos = submath.position(size_t(2));
-        math_prefix_size = submath.str(2).length();
-      }
-      else if (submath.str(2).compare("\\[") == 0) {
-        math_end_waiting = true;
-        math_end = "\\]";
-        math_pos = submath.position(size_t(2));
-      }
-      else if (submath.str(2) == "$") {
-        size_t pos = submath.position(size_t(2));
-        math_end_waiting = true;
-        math_end = "$";
-        math_pos = pos;
-      }
-    }
-  }
-  // Ignore language if there is math somewhere in pattern-string
-  if (isPatternString) {
-    for (auto s: usedText) {
-      // Remove entries created in previous search runs
-      keys.erase(s);
-    }
-    usedText = vector<string>();
-    if (! mi.empty()) {
-      // Disable language
-      keys["foreignlanguage"].disabled = true;
-      disableLanguageOverride = true;
-      removeMathHull = false;
-    }
-    else {
-      removeMathHull = true;	// used later if not isPatternString
-      disableLanguageOverride = false;
-    }
-  }
-  else {
-    if (disableLanguageOverride) {
-      keys["foreignlanguage"].disabled = true;
-    }
-  }
-  math_pos = mi.getFirstPos();
-  for (sregex_iterator it(interval_.par.begin(), interval_.par.end(), rkeys), end; it != end; ++it) {
-    sub = *it;
-    if ((sub.position(2) - sub.position(0)) %2 == 1) {
-      // prefixed by odd count of '\\'
-      continue;
-    }
-    string key = sub.str(5);
-    if (key == "") {
-      if (sub.str(2)[0] == '\\')
-        key = sub.str(2)[1];
-      else {
-        key = sub.str(2);
-      }
-    }
-    KeysIterator it_key = keys.find(key);
-    if (it_key != keys.end()) {
-      if (it_key->second.keytype == KeyInfo::headRemove) {
-        KeyInfo found1 = it_key->second;
-        found1.disabled = true;
-        found1.head = "\\" + key + "{";
-        found1._tokenstart = sub.position(size_t(2));
-        found1._tokensize = found1.head.length();
-        found1._dataStart = found1._tokenstart + found1.head.length();
-        int endpos = interval_.findclosing(found1._dataStart, interval_.par.length(), '{', '}', 1);
-        found1._dataEnd = endpos;
-        removeHead(found1);
-        continue;
-      }
-    }
-    if (evaluatingRegexp) {
-      if (sub.str(3).compare("endregexp") == 0) {
-        evaluatingRegexp = false;
-        // found._tokenstart already set
-        found._dataEnd = sub.position(size_t(2)) + 13;
-        found._dataStart = found._dataEnd;
-        found._tokensize = found._dataEnd - found._tokenstart;
-        found.parenthesiscount = 0;
-        found.head = interval_.par.substr(found._tokenstart, found._tokensize);
-      }
-      else {
-        continue;
-      }
-    }
-    else {
-      if (evaluatingMath) {
-        if (size_t(sub.position(size_t(2))) < mi.getEndPos())
-          continue;
-        evaluatingMath = false;
-        mi.incrEntry();
-        math_pos = mi.getStartPos();
-      }
-      if (it_key == keys.end()) {
-        found = KeyInfo(KeyInfo::isStandard, 0, true);
-        LYXERR(Debug::INFO, "Undefined key " << key << " ==> will be used as text");
-        found = KeyInfo(KeyInfo::isText, 0, false);
-        if (isPatternString) {
-          found.keytype = KeyInfo::isChar;
-          found.disabled = false;
-          found.used = true;
-        }
-        keys[key] = found;
-        usedText.push_back(key);
-      }
-      else
-        found = keys[key];
-      if (key.compare("regexp") == 0) {
-        evaluatingRegexp = true;
-        found._tokenstart = sub.position(size_t(2));
-        found._tokensize = 0;
-        continue;
-      }
-    }
-    // Handle the other params of key
-    if (found.keytype == KeyInfo::isIgnored)
-      continue;
-    else if (found.keytype == KeyInfo::isMath) {
-      if (size_t(sub.position(size_t(2))) == math_pos) {
-        found = keys[key];
-        found._tokenstart = sub.position(size_t(2));
-        found._tokensize = mi.getSize();
-        found._dataEnd = found._tokenstart + found._tokensize;
-        found._dataStart = found._dataEnd;
-        found.parenthesiscount = 0;
-        found.head = interval_.par.substr(found._tokenstart, found._tokensize);
-	if (removeMathHull) {
-	  interval_.addIntervall(found._tokenstart, found._tokenstart + mi.getPrefixSize());
-	  interval_.addIntervall(found._dataEnd - mi.getPostfixSize(), found._dataEnd);
+	static regex const rmath("(\\\\)*(\\$|\\\\\\[|\\\\\\]|\\\\(begin|end)\\{((eqnarray|equation|flalign|gather|multline|align|x?x?alignat)\\*?\\})(\\{[0-9]+\\})?)");
+	static regex const rkeys("(\\\\)*(\\$|\\\\\\[|\\\\\\]|\\\\((([a-zA-Z]+\\*?)(\\{([a-z]+\\*?)\\}|=[0-9]+[a-z]+)?)))");
+	static bool disableLanguageOverride = false;
+	smatch sub, submath;
+	bool evaluatingRegexp = false;
+	MathInfo mi;
+	bool evaluatingMath = false;
+	bool evaluatingCode = false;
+	size_t codeEnd = 0;
+	bool evaluatingOptional = false;
+	size_t optionalEnd = 0;
+	int codeStart = -1;
+	KeyInfo found;
+	bool math_end_waiting = false;
+	size_t math_pos = 10000;
+	size_t math_prefix_size = 1;
+	string math_end;
+	static vector<string> usedText = vector<string>();
+	static bool removeMathHull = false;
+
+	interval_.removeAccents();
+
+	for (sregex_iterator itmath(interval_.par.begin(), interval_.par.end(), rmath), end; itmath != end; ++itmath) {
+		submath = *itmath;
+		if ((submath.position(2) - submath.position(0)) %2 == 1) {
+			// prefixed by odd count of '\\'
+			continue;
+		}
+		if (math_end_waiting) {
+			size_t pos = submath.position(size_t(2));
+			if ((math_end == "$") &&
+					(submath.str(2) == "$")) {
+				mi.insert("$", math_pos, 1, pos, 1);
+				math_end_waiting = false;
+			}
+			else if ((math_end == "\\]") &&
+				 (submath.str(2) == "\\]")) {
+				mi.insert("\\]", math_pos, 2, pos, 2);
+				math_end_waiting = false;
+			}
+			else if ((submath.str(3).compare("end") == 0) &&
+				 (submath.str(5).compare(math_end) == 0)) {
+				mi.insert(math_end, math_pos, math_prefix_size, pos, submath.str(2).length());
+				math_end_waiting = false;
+			}
+			else
+				continue;
+		}
+		else {
+			if (submath.str(3).compare("begin") == 0) {
+				math_end_waiting = true;
+				math_end = submath.str(5);
+				math_pos = submath.position(size_t(2));
+				math_prefix_size = submath.str(2).length();
+			}
+			else if (submath.str(2).compare("\\[") == 0) {
+				math_end_waiting = true;
+				math_end = "\\]";
+				math_pos = submath.position(size_t(2));
+			}
+			else if (submath.str(2) == "$") {
+				size_t pos = submath.position(size_t(2));
+				math_end_waiting = true;
+				math_end = "$";
+				math_pos = pos;
+			}
+		}
+	}
+	// Ignore language if there is math somewhere in pattern-string
+	if (isPatternString) {
+		for (auto s: usedText) {
+			// Remove entries created in previous search runs
+			keys.erase(s);
+		}
+		usedText = vector<string>();
+		if (! mi.empty()) {
+			// Disable language
+			keys["foreignlanguage"].disabled = true;
+			disableLanguageOverride = true;
+			removeMathHull = false;
+		}
+		else {
+			removeMathHull = true;	// used later if not isPatternString
+			disableLanguageOverride = false;
+		}
 	}
 	else {
-	  // Treate all math constructs as simple math
-	  interval_.par[found._tokenstart] = '$';
-	  interval_.par[found._dataEnd - mi.getPostfixSize()] = '$';
-	  interval_.addIntervall(found._tokenstart + 1, found._tokenstart + mi.getPrefixSize());
-	  interval_.addIntervall(found._dataEnd - mi.getPostfixSize() + 1, found._dataEnd);
-	}
-        evaluatingMath = true;
-      }
-      else {
-        // begin|end of unknown env, discard
-        // First handle tables
-        // longtable|tabular
-        bool discardComment;
-        found = keys[key];
-        found.keytype = KeyInfo::doRemove;
-        if ((sub.str(7).compare("longtable") == 0) ||
-            (sub.str(7).compare("tabular") == 0)) {
-          discardComment = true;        /* '%' */
-        }
-        else {
-          discardComment = false;
-          static regex const removeArgs("^(multicols|multipar|sectionbox|subsectionbox|tcolorbox)$");
-          smatch sub2;
-          string token = sub.str(7);
-          if (regex_match(token, sub2, removeArgs)) {
-            found.keytype = KeyInfo::removeWithArg;
-          }
-        }
-        // discard spaces before pos(2)
-        int pos = sub.position(size_t(2));
-        int count;
-        for (count = 0; pos - count > 0; count++) {
-          char c = interval_.par[pos-count-1];
-          if (discardComment) {
-            if ((c != ' ') && (c != '%'))
-              break;
-          }
-          else if (c != ' ')
-            break;
-        }
-        found._tokenstart = pos - count;
-        if (sub.str(3).compare(0, 5, "begin") == 0) {
-          size_t pos1 = pos + sub.str(2).length();
-          if (sub.str(7).compare("cjk") == 0) {
-            pos1 = interval_.findclosing(pos1+1, interval_.par.length()) + 1;
-            if ((interval_.par[pos1] == '{') && (interval_.par[pos1+1] == '}'))
-              pos1 += 2;
-            found.keytype = KeyInfo::isMain;
-            found._dataStart = pos1;
-            found._dataEnd = interval_.par.length();
-            found.disabled = keys["foreignlanguage"].disabled;
-            found.used = keys["foreignlanguage"].used;
-            found._tokensize = pos1 - found._tokenstart;
-            found.head = interval_.par.substr(found._tokenstart, found._tokensize);
-          }
-          else {
-            // Swallow possible optional params
-            while (interval_.par[pos1] == '[') {
-              pos1 = interval_.findclosing(pos1+1, interval_.par.length(), '[', ']')+1;
-            }
-            // Swallow also the eventual parameter
-            if (interval_.par[pos1] == '{') {
-              found._dataEnd = interval_.findclosing(pos1+1, interval_.par.length()) + 1;
-            }
-            else {
-              found._dataEnd = pos1;
-            }
-            found._dataStart = found._dataEnd;
-            found._tokensize = count + found._dataEnd - pos;
-            found.parenthesiscount = 0;
-            found.head = interval_.par.substr(found._tokenstart, found._tokensize);
-            found.disabled = true;
-          }
-        }
-        else {
-          // Handle "\end{...}"
-          found._dataStart = pos + sub.str(2).length();
-          found._dataEnd = found._dataStart;
-          found._tokensize = count + found._dataEnd - pos;
-          found.parenthesiscount = 0;
-          found.head = interval_.par.substr(found._tokenstart, found._tokensize);
-          found.disabled = true;
-        }
-      }
-    }
-    else if (found.keytype != KeyInfo::isRegex) {
-      found._tokenstart = sub.position(size_t(2));
-      if (found.parenthesiscount == 0) {
-        // Probably to be discarded
-        size_t following_pos = sub.position(size_t(2)) + sub.str(5).length() + 1;
-        char following = interval_.par[following_pos];
-        if (following == ' ')
-          found.head = "\\" + sub.str(5) + " ";
-        else if (following == '=') {
-          // like \uldepth=1000pt
-          found.head = sub.str(2);
-        }
-        else
-          found.head = "\\" + key;
-        found._tokensize = found.head.length();
-        found._dataEnd = found._tokenstart + found._tokensize;
-        found._dataStart = found._dataEnd;
-      }
-      else {
-        int params = found._tokenstart + key.length() + 1;
-        if (evaluatingOptional) {
-          if (size_t(found._tokenstart) > optionalEnd) {
-            evaluatingOptional = false;
-          }
-          else {
-            found.disabled = true;
-          }
-        }
-        int optend = params;
-        while (interval_.par[optend] == '[') {
-          // discard optional parameters
-          optend = interval_.findclosing(optend+1, interval_.par.length(), '[', ']') + 1;
-        }
-        if (optend > params) {
-          key += interval_.par.substr(params, optend-params);
-          evaluatingOptional = true;
-          optionalEnd = optend;
-          if (found.keytype == KeyInfo::isSectioning) {
-            // Remove optional values (but still keep in header)
-            interval_.addIntervall(params, optend);
-          }
-        }
-        string token = sub.str(7);
-        int closings;
-        if (interval_.par[optend] != '{') {
-          closings = 0;
-          found.parenthesiscount = 0;
-          found.head = "\\" + key;
-        }
-        else
-          closings = found.parenthesiscount;
-        if (found.parenthesiscount == 1) {
-          found.head = "\\" + key + "{";
-        }
-        else if (found.parenthesiscount > 1) {
-          if (token != "") {
-            found.head = sub.str(2) + "{";
-            closings = found.parenthesiscount - 1;
-          }
-          else {
-            found.head = "\\" + key + "{";
-          }
-        }
-        found._tokensize = found.head.length();
-        found._dataStart = found._tokenstart + found.head.length();
-        if (found.keytype == KeyInfo::doRemove) {
-          if (closings > 0) {
-            size_t endpar = 2 + interval_.findclosing(found._dataStart, interval_.par.length(), '{', '}', closings);
-            if (endpar >= interval_.par.length())
-              found._dataStart = interval_.par.length();
-            else
-              found._dataStart = endpar;
-            found._tokensize = found._dataStart - found._tokenstart;
-          }
-          else {
-            found._dataStart = found._tokenstart + found._tokensize;
-          }
-          closings = 0;
-        }
-        if (interval_.par.substr(found._dataStart, 15).compare("\\endarguments{}") == 0) {
-          found._dataStart += 15;
-        }
-        size_t endpos;
-        if (closings < 1)
-          endpos = found._dataStart - 1;
-        else
-          endpos = interval_.findclosing(found._dataStart, interval_.par.length(), '{', '}', closings);
-        if (found.keytype == KeyInfo::isList) {
-          // Check if it really is list env
-          static regex const listre("^([a-z]+)$");
-          smatch sub2;
-          if (!regex_match(token, sub2, listre)) {
-            // Change the key of this entry. It is not in a list/item environment
-            found.keytype = KeyInfo::endArguments;
-          }
-        }
-        if (found.keytype == KeyInfo::noMain) {
-          evaluatingCode = true;
-          codeEnd = endpos;
-          codeStart = found._dataStart;
-        }
-        else if (evaluatingCode) {
-          if (size_t(found._dataStart) > codeEnd)
-            evaluatingCode = false;
-          else if (found.keytype == KeyInfo::isMain) {
-            // Disable this key, treate it as standard
-            found.keytype = KeyInfo::isStandard;
-            found.disabled = true;
-            if ((codeEnd +1 >= interval_.par.length()) &&
-                (found._tokenstart == codeStart)) {
-              // trickery, because the code inset starts
-              // with \selectlanguage ...
-              codeEnd = endpos;
-              if (entries_.size() > 1) {
-                entries_[entries_.size()-1]._dataEnd = codeEnd;
-              }
-            }
-          }
-        }
-        if ((endpos == interval_.par.length()) &&
-            (found.keytype == KeyInfo::doRemove)) {
-          // Missing closing => error in latex-input?
-          // therefore do not delete remaining data
-          found._dataStart -= 1;
-          found._dataEnd = found._dataStart;
-        }
-        else
-          found._dataEnd = endpos;
-      }
-      if (isPatternString) {
-        keys[key].used = true;
-      }
-    }
-    entries_.push_back(found);
-  }
+		if (disableLanguageOverride) {
+			keys["foreignlanguage"].disabled = true;
+		}
+	}
+	math_pos = mi.getFirstPos();
+	for (sregex_iterator it(interval_.par.begin(), interval_.par.end(), rkeys), end; it != end; ++it) {
+		sub = *it;
+		if ((sub.position(2) - sub.position(0)) %2 == 1) {
+			// prefixed by odd count of '\\'
+			continue;
+		}
+		string key = sub.str(5);
+		if (key == "") {
+			if (sub.str(2)[0] == '\\')
+				key = sub.str(2)[1];
+			else {
+				key = sub.str(2);
+			}
+		}
+		KeysIterator it_key = keys.find(key);
+		if (it_key != keys.end()) {
+			if (it_key->second.keytype == KeyInfo::headRemove) {
+				KeyInfo found1 = it_key->second;
+				found1.disabled = true;
+				found1.head = "\\" + key + "{";
+				found1._tokenstart = sub.position(size_t(2));
+				found1._tokensize = found1.head.length();
+				found1._dataStart = found1._tokenstart + found1.head.length();
+				int endpos = interval_.findclosing(found1._dataStart, interval_.par.length(), '{', '}', 1);
+				found1._dataEnd = endpos;
+				removeHead(found1);
+				continue;
+			}
+		}
+		if (evaluatingRegexp) {
+			if (sub.str(3).compare("endregexp") == 0) {
+				evaluatingRegexp = false;
+				// found._tokenstart already set
+				found._dataEnd = sub.position(size_t(2)) + 13;
+				found._dataStart = found._dataEnd;
+				found._tokensize = found._dataEnd - found._tokenstart;
+				found.parenthesiscount = 0;
+				found.head = interval_.par.substr(found._tokenstart, found._tokensize);
+			}
+			else {
+				continue;
+			}
+		}
+		else {
+			if (evaluatingMath) {
+				if (size_t(sub.position(size_t(2))) < mi.getEndPos())
+					continue;
+				evaluatingMath = false;
+				mi.incrEntry();
+				math_pos = mi.getStartPos();
+			}
+			if (it_key == keys.end()) {
+				found = KeyInfo(KeyInfo::isStandard, 0, true);
+				LYXERR(Debug::INFO, "Undefined key " << key << " ==> will be used as text");
+				found = KeyInfo(KeyInfo::isText, 0, false);
+				if (isPatternString) {
+					found.keytype = KeyInfo::isChar;
+					found.disabled = false;
+					found.used = true;
+				}
+				keys[key] = found;
+				usedText.push_back(key);
+			}
+			else
+				found = keys[key];
+			if (key.compare("regexp") == 0) {
+				evaluatingRegexp = true;
+				found._tokenstart = sub.position(size_t(2));
+				found._tokensize = 0;
+				continue;
+			}
+		}
+		// Handle the other params of key
+		if (found.keytype == KeyInfo::isIgnored)
+			continue;
+		else if (found.keytype == KeyInfo::isMath) {
+			if (size_t(sub.position(size_t(2))) == math_pos) {
+				found = keys[key];
+				found._tokenstart = sub.position(size_t(2));
+				found._tokensize = mi.getSize();
+				found._dataEnd = found._tokenstart + found._tokensize;
+				found._dataStart = found._dataEnd;
+				found.parenthesiscount = 0;
+				found.head = interval_.par.substr(found._tokenstart, found._tokensize);
+				if (removeMathHull) {
+					interval_.addIntervall(found._tokenstart, found._tokenstart + mi.getPrefixSize());
+					interval_.addIntervall(found._dataEnd - mi.getPostfixSize(), found._dataEnd);
+				}
+				else {
+					// Treate all math constructs as simple math
+					interval_.par[found._tokenstart] = '$';
+					interval_.par[found._dataEnd - mi.getPostfixSize()] = '$';
+					interval_.addIntervall(found._tokenstart + 1, found._tokenstart + mi.getPrefixSize());
+					interval_.addIntervall(found._dataEnd - mi.getPostfixSize() + 1, found._dataEnd);
+				}
+				evaluatingMath = true;
+			}
+			else {
+				// begin|end of unknown env, discard
+				// First handle tables
+				// longtable|tabular
+				bool discardComment;
+				found = keys[key];
+				found.keytype = KeyInfo::doRemove;
+				if ((sub.str(7).compare("longtable") == 0) ||
+						(sub.str(7).compare("tabular") == 0)) {
+					discardComment = true;        /* '%' */
+				}
+				else {
+					discardComment = false;
+					static regex const removeArgs("^(multicols|multipar|sectionbox|subsectionbox|tcolorbox)$");
+					smatch sub2;
+					string token = sub.str(7);
+					if (regex_match(token, sub2, removeArgs)) {
+						found.keytype = KeyInfo::removeWithArg;
+					}
+				}
+				// discard spaces before pos(2)
+				int pos = sub.position(size_t(2));
+				int count;
+				for (count = 0; pos - count > 0; count++) {
+					char c = interval_.par[pos-count-1];
+					if (discardComment) {
+						if ((c != ' ') && (c != '%'))
+							break;
+					}
+					else if (c != ' ')
+						break;
+				}
+				found._tokenstart = pos - count;
+				if (sub.str(3).compare(0, 5, "begin") == 0) {
+					size_t pos1 = pos + sub.str(2).length();
+					if (sub.str(7).compare("cjk") == 0) {
+						pos1 = interval_.findclosing(pos1+1, interval_.par.length()) + 1;
+						if ((interval_.par[pos1] == '{') && (interval_.par[pos1+1] == '}'))
+							pos1 += 2;
+						found.keytype = KeyInfo::isMain;
+						found._dataStart = pos1;
+						found._dataEnd = interval_.par.length();
+						found.disabled = keys["foreignlanguage"].disabled;
+						found.used = keys["foreignlanguage"].used;
+						found._tokensize = pos1 - found._tokenstart;
+						found.head = interval_.par.substr(found._tokenstart, found._tokensize);
+					}
+					else {
+						// Swallow possible optional params
+						while (interval_.par[pos1] == '[') {
+							pos1 = interval_.findclosing(pos1+1, interval_.par.length(), '[', ']')+1;
+						}
+						// Swallow also the eventual parameter
+						if (interval_.par[pos1] == '{') {
+							found._dataEnd = interval_.findclosing(pos1+1, interval_.par.length()) + 1;
+						}
+						else {
+							found._dataEnd = pos1;
+						}
+						found._dataStart = found._dataEnd;
+						found._tokensize = count + found._dataEnd - pos;
+						found.parenthesiscount = 0;
+						found.head = interval_.par.substr(found._tokenstart, found._tokensize);
+						found.disabled = true;
+					}
+				}
+				else {
+					// Handle "\end{...}"
+					found._dataStart = pos + sub.str(2).length();
+					found._dataEnd = found._dataStart;
+					found._tokensize = count + found._dataEnd - pos;
+					found.parenthesiscount = 0;
+					found.head = interval_.par.substr(found._tokenstart, found._tokensize);
+					found.disabled = true;
+				}
+			}
+		}
+		else if (found.keytype != KeyInfo::isRegex) {
+			found._tokenstart = sub.position(size_t(2));
+			if (found.parenthesiscount == 0) {
+				// Probably to be discarded
+				size_t following_pos = sub.position(size_t(2)) + sub.str(5).length() + 1;
+				char following = interval_.par[following_pos];
+				if (following == ' ')
+					found.head = "\\" + sub.str(5) + " ";
+				else if (following == '=') {
+					// like \uldepth=1000pt
+					found.head = sub.str(2);
+				}
+				else
+					found.head = "\\" + key;
+				found._tokensize = found.head.length();
+				found._dataEnd = found._tokenstart + found._tokensize;
+				found._dataStart = found._dataEnd;
+			}
+			else {
+				int params = found._tokenstart + key.length() + 1;
+				if (evaluatingOptional) {
+					if (size_t(found._tokenstart) > optionalEnd) {
+						evaluatingOptional = false;
+					}
+					else {
+						found.disabled = true;
+					}
+				}
+				int optend = params;
+				while (interval_.par[optend] == '[') {
+					// discard optional parameters
+					optend = interval_.findclosing(optend+1, interval_.par.length(), '[', ']') + 1;
+				}
+				if (optend > params) {
+					key += interval_.par.substr(params, optend-params);
+					evaluatingOptional = true;
+					optionalEnd = optend;
+					if (found.keytype == KeyInfo::isSectioning) {
+						// Remove optional values (but still keep in header)
+						interval_.addIntervall(params, optend);
+					}
+				}
+				string token = sub.str(7);
+				int closings;
+				if (interval_.par[optend] != '{') {
+					closings = 0;
+					found.parenthesiscount = 0;
+					found.head = "\\" + key;
+				}
+				else
+					closings = found.parenthesiscount;
+				if (found.parenthesiscount == 1) {
+					found.head = "\\" + key + "{";
+				}
+				else if (found.parenthesiscount > 1) {
+					if (token != "") {
+						found.head = sub.str(2) + "{";
+						closings = found.parenthesiscount - 1;
+					}
+					else {
+						found.head = "\\" + key + "{";
+					}
+				}
+				found._tokensize = found.head.length();
+				found._dataStart = found._tokenstart + found.head.length();
+				if (found.keytype == KeyInfo::doRemove) {
+					if (closings > 0) {
+						size_t endpar = 2 + interval_.findclosing(found._dataStart, interval_.par.length(), '{', '}', closings);
+						if (endpar >= interval_.par.length())
+							found._dataStart = interval_.par.length();
+						else
+							found._dataStart = endpar;
+						found._tokensize = found._dataStart - found._tokenstart;
+					}
+					else {
+						found._dataStart = found._tokenstart + found._tokensize;
+					}
+					closings = 0;
+				}
+				if (interval_.par.substr(found._dataStart, 15).compare("\\endarguments{}") == 0) {
+					found._dataStart += 15;
+				}
+				size_t endpos;
+				if (closings < 1)
+					endpos = found._dataStart - 1;
+				else
+					endpos = interval_.findclosing(found._dataStart, interval_.par.length(), '{', '}', closings);
+				if (found.keytype == KeyInfo::isList) {
+					// Check if it really is list env
+					static regex const listre("^([a-z]+)$");
+					smatch sub2;
+					if (!regex_match(token, sub2, listre)) {
+						// Change the key of this entry. It is not in a list/item environment
+						found.keytype = KeyInfo::endArguments;
+					}
+				}
+				if (found.keytype == KeyInfo::noMain) {
+					evaluatingCode = true;
+					codeEnd = endpos;
+					codeStart = found._dataStart;
+				}
+				else if (evaluatingCode) {
+					if (size_t(found._dataStart) > codeEnd)
+						evaluatingCode = false;
+					else if (found.keytype == KeyInfo::isMain) {
+						// Disable this key, treate it as standard
+						found.keytype = KeyInfo::isStandard;
+						found.disabled = true;
+						if ((codeEnd +1 >= interval_.par.length()) &&
+								(found._tokenstart == codeStart)) {
+							// trickery, because the code inset starts
+							// with \selectlanguage ...
+							codeEnd = endpos;
+							if (entries_.size() > 1) {
+								entries_[entries_.size()-1]._dataEnd = codeEnd;
+							}
+						}
+					}
+				}
+				if ((endpos == interval_.par.length()) &&
+						(found.keytype == KeyInfo::doRemove)) {
+					// Missing closing => error in latex-input?
+					// therefore do not delete remaining data
+					found._dataStart -= 1;
+					found._dataEnd = found._dataStart;
+				}
+				else
+					found._dataEnd = endpos;
+			}
+			if (isPatternString) {
+				keys[key].used = true;
+			}
+		}
+		entries_.push_back(found);
+	}
 }
 
 void LatexInfo::makeKey(const string &keysstring, KeyInfo keyI, bool isPatternString)
 {
-  stringstream s(keysstring);
-  string key;
-  const char delim = '|';
-  while (getline(s, key, delim)) {
-    KeyInfo keyII(keyI);
-    if (isPatternString) {
-      keyII.used = false;
-    }
-    else if ( !keys[key].used)
-      keyII.disabled = true;
-    keys[key] = keyII;
-  }
+	stringstream s(keysstring);
+	string key;
+	const char delim = '|';
+	while (getline(s, key, delim)) {
+		KeyInfo keyII(keyI);
+		if (isPatternString) {
+			keyII.used = false;
+		}
+		else if ( !keys[key].used)
+			keyII.disabled = true;
+		keys[key] = keyII;
+	}
 }
 
 void LatexInfo::buildKeys(bool isPatternString)
 {
 
-  static bool keysBuilt = false;
-  if (keysBuilt && !isPatternString) return;
-
-  // Keys to ignore in any case
-  makeKey("text|textcyrillic|lyxmathsym|ensuremath", KeyInfo(KeyInfo::headRemove, 1, true), true);
-  // Known standard keys with 1 parameter.
-  // Split is done, if not at start of region
-  makeKey("textsf|textss|texttt", KeyInfo(KeyInfo::isStandard, 1, ignoreFormats.getFamily()), isPatternString);
-  makeKey("textbf",               KeyInfo(KeyInfo::isStandard, 1, ignoreFormats.getSeries()), isPatternString);
-  makeKey("textit|textsc|textsl", KeyInfo(KeyInfo::isStandard, 1, ignoreFormats.getShape()), isPatternString);
-  makeKey("uuline|uline|uwave",   KeyInfo(KeyInfo::isStandard, 1, ignoreFormats.getUnderline()), isPatternString);
-  makeKey("emph|noun",            KeyInfo(KeyInfo::isStandard, 1, ignoreFormats.getMarkUp()), isPatternString);
-  makeKey("sout|xout",            KeyInfo(KeyInfo::isStandard, 1, ignoreFormats.getStrikeOut()), isPatternString);
-
-  makeKey("section|subsection|subsubsection|paragraph|subparagraph|minisec",
-          KeyInfo(KeyInfo::isSectioning, 1, ignoreFormats.getSectioning()), isPatternString);
-  makeKey("section*|subsection*|subsubsection*|paragraph*",
-          KeyInfo(KeyInfo::isSectioning, 1, ignoreFormats.getSectioning()), isPatternString);
-  makeKey("part|part*|chapter|chapter*", KeyInfo(KeyInfo::isSectioning, 1, ignoreFormats.getSectioning()), isPatternString);
-  makeKey("title|subtitle|author|subject|publishers|dedication|uppertitleback|lowertitleback|extratitle|lyxaddress|lyxrightaddress", KeyInfo(KeyInfo::isTitle, 1, ignoreFormats.getFrontMatter()), isPatternString);
-  // Regex
-  makeKey("regexp", KeyInfo(KeyInfo::isRegex, 1, false), isPatternString);
-
-  // Split is done, if not at start of region
-  makeKey("textcolor", KeyInfo(KeyInfo::isStandard, 2, ignoreFormats.getColor()), isPatternString);
-  makeKey("latexenvironment", KeyInfo(KeyInfo::isStandard, 2, false), isPatternString);
-
-  // Split is done always.
-  makeKey("foreignlanguage", KeyInfo(KeyInfo::isMain, 2, ignoreFormats.getLanguage()), isPatternString);
-
-  // Known charaters
-  // No split
-  makeKey("backslash|textbackslash|slash",  KeyInfo(KeyInfo::isChar, 0, false), isPatternString);
-  makeKey("textasciicircum|textasciitilde", KeyInfo(KeyInfo::isChar, 0, false), isPatternString);
-  makeKey("textasciiacute|texemdash",       KeyInfo(KeyInfo::isChar, 0, false), isPatternString);
-  makeKey("dots|ldots",                     KeyInfo(KeyInfo::isChar, 0, false), isPatternString);
-  // Spaces
-  makeKey("quad|qquad|hfill|dotfill",               KeyInfo(KeyInfo::isChar, 0, false), isPatternString);
-  makeKey("textvisiblespace|nobreakspace",          KeyInfo(KeyInfo::isChar, 0, false), isPatternString);
-  makeKey("negthickspace|negmedspace|negthinspace", KeyInfo(KeyInfo::isChar, 0, false), isPatternString);
-  makeKey("thickspace|medspace|thinspace",          KeyInfo(KeyInfo::isChar, 0, false), isPatternString);
-  // Skip
-  // makeKey("enskip|smallskip|medskip|bigskip|vfill", KeyInfo(KeyInfo::isChar, 0, false), isPatternString);
-  // Custom space/skip, remove the content (== length value)
-  makeKey("vspace|vspace*|hspace|hspace*|mspace", KeyInfo(KeyInfo::noContent, 1, false), isPatternString);
-  // Found in fr/UserGuide.lyx
-  makeKey("og|fg", KeyInfo(KeyInfo::isChar, 0, false), isPatternString);
-  // quotes
-  makeKey("textquotedbl|quotesinglbase|lyxarrow", KeyInfo(KeyInfo::isChar, 0, false), isPatternString);
-  makeKey("textquotedblleft|textquotedblright", KeyInfo(KeyInfo::isChar, 0, false), isPatternString);
-  // Known macros to remove (including their parameter)
-  // No split
-  makeKey("input|inputencoding|label|ref|index|bibitem", KeyInfo(KeyInfo::doRemove, 1, false), isPatternString);
-  makeKey("addtocounter|setlength",                 KeyInfo(KeyInfo::noContent, 2, true), isPatternString);
-  // handle like standard keys with 1 parameter.
-  makeKey("url|href|vref|thanks", KeyInfo(KeyInfo::isStandard, 1, false), isPatternString);
-
-  // Ignore deleted text
-  makeKey("lyxdeleted", KeyInfo(KeyInfo::doRemove, 3, false), isPatternString);
-  // but preserve added text
-  makeKey("lyxadded", KeyInfo(KeyInfo::doRemove, 2, false), isPatternString);
-
-  // Macros to remove, but let the parameter survive
-  // No split
-  makeKey("menuitem|textmd|textrm", KeyInfo(KeyInfo::isStandard, 1, true), isPatternString);
-
-  // Remove language spec from content of these insets
-  makeKey("code", KeyInfo(KeyInfo::noMain, 1, false), isPatternString);
-
-  // Same effect as previous, parameter will survive (because there is no one anyway)
-  // No split
-  makeKey("noindent|textcompwordmark|maketitle", KeyInfo(KeyInfo::isStandard, 0, true), isPatternString);
-  // Remove table decorations
-  makeKey("hline|tabularnewline|toprule|bottomrule|midrule", KeyInfo(KeyInfo::doRemove, 0, true), isPatternString);
-  // Discard shape-header.
-  // For footnote or shortcut too, because of lang settings
-  // and wrong handling if used 'KeyInfo::noMain'
-  makeKey("circlepar|diamondpar|heartpar|nutpar",  KeyInfo(KeyInfo::isStandard, 1, true), isPatternString);
-  makeKey("trianglerightpar|hexagonpar|starpar",   KeyInfo(KeyInfo::isStandard, 1, true), isPatternString);
-  makeKey("triangleuppar|triangledownpar|droppar", KeyInfo(KeyInfo::isStandard, 1, true), isPatternString);
-  makeKey("triangleleftpar|shapepar|dropuppar",    KeyInfo(KeyInfo::isStandard, 1, true), isPatternString);
-  makeKey("hphantom|vphantom|note|footnote|shortcut|include|includegraphics",     KeyInfo(KeyInfo::isStandard, 1, true), isPatternString);
-  makeKey("parbox", KeyInfo(KeyInfo::doRemove, 1, true), isPatternString);
-  // like ('tiny{}' or '\tiny ' ... )
-  makeKey("footnotesize|tiny|scriptsize|small|large|Large|LARGE|huge|Huge", KeyInfo(KeyInfo::isSize, 0, false), isPatternString);
-
-  // Survives, like known character
-  // makeKey("lyx|LyX|latex|LaTeX|latexe|LaTeXe|tex|TeX", KeyInfo(KeyInfo::isChar, 0, false), isPatternString);
-  makeKey("tableofcontents", KeyInfo(KeyInfo::isChar, 0, false), isPatternString);
-  makeKey("item|listitem", KeyInfo(KeyInfo::isList, 1, false), isPatternString);
-
-  makeKey("begin|end", KeyInfo(KeyInfo::isMath, 1, false), isPatternString);
-  makeKey("[|]", KeyInfo(KeyInfo::isMath, 1, false), isPatternString);
-  makeKey("$", KeyInfo(KeyInfo::isMath, 1, false), isPatternString);
-
-  makeKey("par|uldepth|ULdepth|protect|nobreakdash|medskip|relax", KeyInfo(KeyInfo::isStandard, 0, true), isPatternString);
-  // Remove RTL/LTR marker
-  makeKey("l|r|textlr|textfr|textar|beginl|endl", KeyInfo(KeyInfo::isStandard, 0, true), isPatternString);
-  makeKey("lettrine", KeyInfo(KeyInfo::cleanToStart, 0, true), isPatternString);
-  makeKey("lyxslide", KeyInfo(KeyInfo::isSectioning, 1, true), isPatternString);
-  makeKey("endarguments", KeyInfo(KeyInfo::endArguments, 0, true), isPatternString);
-  makeKey("twocolumn", KeyInfo(KeyInfo::removeWithArg, 2, true), isPatternString);
-  makeKey("tnotetext|ead|fntext|cortext|address", KeyInfo(KeyInfo::removeWithArg, 0, true), isPatternString);
-  makeKey("lyxend", KeyInfo(KeyInfo::isStandard, 0, true), isPatternString);
-  if (isPatternString) {
-    // Allow the first searched string to rebuild the keys too
-    keysBuilt = false;
-  }
-  else {
-    // no need to rebuild again
-    keysBuilt = true;
-  }
+	static bool keysBuilt = false;
+	if (keysBuilt && !isPatternString) return;
+
+	// Keys to ignore in any case
+	makeKey("text|textcyrillic|lyxmathsym|ensuremath", KeyInfo(KeyInfo::headRemove, 1, true), true);
+	// Known standard keys with 1 parameter.
+	// Split is done, if not at start of region
+	makeKey("textsf|textss|texttt", KeyInfo(KeyInfo::isStandard, 1, ignoreFormats.getFamily()), isPatternString);
+	makeKey("textbf",               KeyInfo(KeyInfo::isStandard, 1, ignoreFormats.getSeries()), isPatternString);
+	makeKey("textit|textsc|textsl", KeyInfo(KeyInfo::isStandard, 1, ignoreFormats.getShape()), isPatternString);
+	makeKey("uuline|uline|uwave",   KeyInfo(KeyInfo::isStandard, 1, ignoreFormats.getUnderline()), isPatternString);
+	makeKey("emph|noun",            KeyInfo(KeyInfo::isStandard, 1, ignoreFormats.getMarkUp()), isPatternString);
+	makeKey("sout|xout",            KeyInfo(KeyInfo::isStandard, 1, ignoreFormats.getStrikeOut()), isPatternString);
+
+	makeKey("section|subsection|subsubsection|paragraph|subparagraph|minisec",
+		KeyInfo(KeyInfo::isSectioning, 1, ignoreFormats.getSectioning()), isPatternString);
+	makeKey("section*|subsection*|subsubsection*|paragraph*",
+		KeyInfo(KeyInfo::isSectioning, 1, ignoreFormats.getSectioning()), isPatternString);
+	makeKey("part|part*|chapter|chapter*", KeyInfo(KeyInfo::isSectioning, 1, ignoreFormats.getSectioning()), isPatternString);
+	makeKey("title|subtitle|author|subject|publishers|dedication|uppertitleback|lowertitleback|extratitle|lyxaddress|lyxrightaddress", KeyInfo(KeyInfo::isTitle, 1, ignoreFormats.getFrontMatter()), isPatternString);
+	// Regex
+	makeKey("regexp", KeyInfo(KeyInfo::isRegex, 1, false), isPatternString);
+
+	// Split is done, if not at start of region
+	makeKey("textcolor", KeyInfo(KeyInfo::isStandard, 2, ignoreFormats.getColor()), isPatternString);
+	makeKey("latexenvironment", KeyInfo(KeyInfo::isStandard, 2, false), isPatternString);
+
+	// Split is done always.
+	makeKey("foreignlanguage", KeyInfo(KeyInfo::isMain, 2, ignoreFormats.getLanguage()), isPatternString);
+
+	// Known charaters
+	// No split
+	makeKey("backslash|textbackslash|slash",  KeyInfo(KeyInfo::isChar, 0, false), isPatternString);
+	makeKey("textasciicircum|textasciitilde", KeyInfo(KeyInfo::isChar, 0, false), isPatternString);
+	makeKey("textasciiacute|texemdash",       KeyInfo(KeyInfo::isChar, 0, false), isPatternString);
+	makeKey("dots|ldots",                     KeyInfo(KeyInfo::isChar, 0, false), isPatternString);
+	// Spaces
+	makeKey("quad|qquad|hfill|dotfill",               KeyInfo(KeyInfo::isChar, 0, false), isPatternString);
+	makeKey("textvisiblespace|nobreakspace",          KeyInfo(KeyInfo::isChar, 0, false), isPatternString);
+	makeKey("negthickspace|negmedspace|negthinspace", KeyInfo(KeyInfo::isChar, 0, false), isPatternString);
+	makeKey("thickspace|medspace|thinspace",          KeyInfo(KeyInfo::isChar, 0, false), isPatternString);
+	// Skip
+	// makeKey("enskip|smallskip|medskip|bigskip|vfill", KeyInfo(KeyInfo::isChar, 0, false), isPatternString);
+	// Custom space/skip, remove the content (== length value)
+	makeKey("vspace|vspace*|hspace|hspace*|mspace", KeyInfo(KeyInfo::noContent, 1, false), isPatternString);
+	// Found in fr/UserGuide.lyx
+	makeKey("og|fg", KeyInfo(KeyInfo::isChar, 0, false), isPatternString);
+	// quotes
+	makeKey("textquotedbl|quotesinglbase|lyxarrow", KeyInfo(KeyInfo::isChar, 0, false), isPatternString);
+	makeKey("textquotedblleft|textquotedblright", KeyInfo(KeyInfo::isChar, 0, false), isPatternString);
+	// Known macros to remove (including their parameter)
+	// No split
+	makeKey("input|inputencoding|label|ref|index|bibitem", KeyInfo(KeyInfo::doRemove, 1, false), isPatternString);
+	makeKey("addtocounter|setlength",                 KeyInfo(KeyInfo::noContent, 2, true), isPatternString);
+	// handle like standard keys with 1 parameter.
+	makeKey("url|href|vref|thanks", KeyInfo(KeyInfo::isStandard, 1, false), isPatternString);
+
+	// Ignore deleted text
+	makeKey("lyxdeleted", KeyInfo(KeyInfo::doRemove, 3, false), isPatternString);
+	// but preserve added text
+	makeKey("lyxadded", KeyInfo(KeyInfo::doRemove, 2, false), isPatternString);
+
+	// Macros to remove, but let the parameter survive
+	// No split
+	makeKey("menuitem|textmd|textrm", KeyInfo(KeyInfo::isStandard, 1, true), isPatternString);
+
+	// Remove language spec from content of these insets
+	makeKey("code", KeyInfo(KeyInfo::noMain, 1, false), isPatternString);
+
+	// Same effect as previous, parameter will survive (because there is no one anyway)
+	// No split
+	makeKey("noindent|textcompwordmark|maketitle", KeyInfo(KeyInfo::isStandard, 0, true), isPatternString);
+	// Remove table decorations
+	makeKey("hline|tabularnewline|toprule|bottomrule|midrule", KeyInfo(KeyInfo::doRemove, 0, true), isPatternString);
+	// Discard shape-header.
+	// For footnote or shortcut too, because of lang settings
+	// and wrong handling if used 'KeyInfo::noMain'
+	makeKey("circlepar|diamondpar|heartpar|nutpar",  KeyInfo(KeyInfo::isStandard, 1, true), isPatternString);
+	makeKey("trianglerightpar|hexagonpar|starpar",   KeyInfo(KeyInfo::isStandard, 1, true), isPatternString);
+	makeKey("triangleuppar|triangledownpar|droppar", KeyInfo(KeyInfo::isStandard, 1, true), isPatternString);
+	makeKey("triangleleftpar|shapepar|dropuppar",    KeyInfo(KeyInfo::isStandard, 1, true), isPatternString);
+	makeKey("hphantom|vphantom|note|footnote|shortcut|include|includegraphics",     KeyInfo(KeyInfo::isStandard, 1, true), isPatternString);
+	makeKey("parbox", KeyInfo(KeyInfo::doRemove, 1, true), isPatternString);
+	// like ('tiny{}' or '\tiny ' ... )
+	makeKey("footnotesize|tiny|scriptsize|small|large|Large|LARGE|huge|Huge", KeyInfo(KeyInfo::isSize, 0, false), isPatternString);
+
+	// Survives, like known character
+	// makeKey("lyx|LyX|latex|LaTeX|latexe|LaTeXe|tex|TeX", KeyInfo(KeyInfo::isChar, 0, false), isPatternString);
+	makeKey("tableofcontents", KeyInfo(KeyInfo::isChar, 0, false), isPatternString);
+	makeKey("item|listitem", KeyInfo(KeyInfo::isList, 1, false), isPatternString);
+
+	makeKey("begin|end", KeyInfo(KeyInfo::isMath, 1, false), isPatternString);
+	makeKey("[|]", KeyInfo(KeyInfo::isMath, 1, false), isPatternString);
+	makeKey("$", KeyInfo(KeyInfo::isMath, 1, false), isPatternString);
+
+	makeKey("par|uldepth|ULdepth|protect|nobreakdash|medskip|relax", KeyInfo(KeyInfo::isStandard, 0, true), isPatternString);
+	// Remove RTL/LTR marker
+	makeKey("l|r|textlr|textfr|textar|beginl|endl", KeyInfo(KeyInfo::isStandard, 0, true), isPatternString);
+	makeKey("lettrine", KeyInfo(KeyInfo::cleanToStart, 0, true), isPatternString);
+	makeKey("lyxslide", KeyInfo(KeyInfo::isSectioning, 1, true), isPatternString);
+	makeKey("endarguments", KeyInfo(KeyInfo::endArguments, 0, true), isPatternString);
+	makeKey("twocolumn", KeyInfo(KeyInfo::removeWithArg, 2, true), isPatternString);
+	makeKey("tnotetext|ead|fntext|cortext|address", KeyInfo(KeyInfo::removeWithArg, 0, true), isPatternString);
+	makeKey("lyxend", KeyInfo(KeyInfo::isStandard, 0, true), isPatternString);
+	if (isPatternString) {
+		// Allow the first searched string to rebuild the keys too
+		keysBuilt = false;
+	}
+	else {
+		// no need to rebuild again
+		keysBuilt = true;
+	}
 }
 
 /*
@@ -2779,555 +2779,555 @@ void LatexInfo::buildKeys(bool isPatternString)
  */
 void Intervall::handleParentheses(int lastpos, bool closingAllowed)
 {
-  int skip = 0;
-  for (int i = depts[actualdeptindex]; i < lastpos; i+= 1 + skip) {
-    char c;
-    c = par[i];
-    skip = 0;
-    if (c == '\\') skip = 1;
-    else if (c == '{') {
-      handleOpenP(i);
-    }
-    else if (c == '}') {
-      handleCloseP(i, closingAllowed);
-    }
-  }
+	int skip = 0;
+	for (int i = depts[actualdeptindex]; i < lastpos; i+= 1 + skip) {
+		char c;
+		c = par[i];
+		skip = 0;
+		if (c == '\\') skip = 1;
+		else if (c == '{') {
+			handleOpenP(i);
+		}
+		else if (c == '}') {
+			handleCloseP(i, closingAllowed);
+		}
+	}
 }
 
 #if (0)
 string Intervall::show(int lastpos)
 {
-  int idx = 0;                          /* int intervalls */
-  string s;
-  int i = 0;
-  for (idx = 0; idx <= ignoreidx; idx++) {
-    while (i < lastpos) {
-      int printsize;
-      if (i <= borders[idx].low) {
-        if (borders[idx].low > lastpos)
-          printsize = lastpos - i;
-        else
-          printsize = borders[idx].low - i;
-        s += par.substr(i, printsize);
-        i += printsize;
-        if (i >= borders[idx].low)
-          i = borders[idx].upper;
-      }
-      else {
-        i = borders[idx].upper;
-        break;
-      }
-    }
-  }
-  if (lastpos > i) {
-    s += par.substr(i, lastpos-i);
-  }
-  return s;
+	int idx = 0;                          /* int intervalls */
+	string s;
+	int i = 0;
+	for (idx = 0; idx <= ignoreidx; idx++) {
+		while (i < lastpos) {
+			int printsize;
+			if (i <= borders[idx].low) {
+				if (borders[idx].low > lastpos)
+					printsize = lastpos - i;
+				else
+					printsize = borders[idx].low - i;
+				s += par.substr(i, printsize);
+				i += printsize;
+				if (i >= borders[idx].low)
+					i = borders[idx].upper;
+			}
+			else {
+				i = borders[idx].upper;
+				break;
+			}
+		}
+	}
+	if (lastpos > i) {
+		s += par.substr(i, lastpos-i);
+	}
+	return s;
 }
 #endif
 
 void Intervall::output(ostringstream &os, int lastpos)
 {
-  // get number of chars to output
-  int idx = 0;                          /* int intervalls */
-  int i = 0;
-  int printed = 0;
-  string startTitle = titleValue;
-  for (idx = 0; idx <= ignoreidx; idx++) {
-    if (i < lastpos) {
-      if (i <= borders[idx].low) {
-        int printsize;
-        if (borders[idx].low > lastpos)
-          printsize = lastpos - i;
-        else
-          printsize = borders[idx].low - i;
-        if (printsize > 0) {
-          os << startTitle << par.substr(i, printsize);
-          i += printsize;
-          printed += printsize;
-          startTitle = "";
-        }
-        handleParentheses(i, false);
-        if (i >= borders[idx].low)
-          i = borders[idx].upper;
-      }
-      else {
-        i = borders[idx].upper;
-      }
-    }
-    else
-      break;
-  }
-  if (lastpos > i) {
-    os << startTitle << par.substr(i, lastpos-i);
-    printed += lastpos-i;
-  }
-  handleParentheses(lastpos, false);
-  int startindex;
-  if (keys["foreignlanguage"].disabled)
-    startindex = actualdeptindex-langcount;
-  else
-    startindex = actualdeptindex;
-  for (int i = startindex; i > 0; --i) {
-    os << "}";
-  }
-  if (hasTitle && (printed > 0))
-    os << "}";
-  if (! isPatternString_)
-    os << "\n";
-  handleParentheses(lastpos, true); /* extra closings '}' allowed here */
+	// get number of chars to output
+	int idx = 0;                          /* int intervalls */
+	int i = 0;
+	int printed = 0;
+	string startTitle = titleValue;
+	for (idx = 0; idx <= ignoreidx; idx++) {
+		if (i < lastpos) {
+			if (i <= borders[idx].low) {
+				int printsize;
+				if (borders[idx].low > lastpos)
+					printsize = lastpos - i;
+				else
+					printsize = borders[idx].low - i;
+				if (printsize > 0) {
+					os << startTitle << par.substr(i, printsize);
+					i += printsize;
+					printed += printsize;
+					startTitle = "";
+				}
+				handleParentheses(i, false);
+				if (i >= borders[idx].low)
+					i = borders[idx].upper;
+			}
+			else {
+				i = borders[idx].upper;
+			}
+		}
+		else
+			break;
+	}
+	if (lastpos > i) {
+		os << startTitle << par.substr(i, lastpos-i);
+		printed += lastpos-i;
+	}
+	handleParentheses(lastpos, false);
+	int startindex;
+	if (keys["foreignlanguage"].disabled)
+		startindex = actualdeptindex-langcount;
+	else
+		startindex = actualdeptindex;
+	for (int i = startindex; i > 0; --i) {
+		os << "}";
+	}
+	if (hasTitle && (printed > 0))
+		os << "}";
+	if (! isPatternString_)
+		os << "\n";
+	handleParentheses(lastpos, true); /* extra closings '}' allowed here */
 }
 
 void LatexInfo::processRegion(int start, int region_end)
 {
-  while (start < region_end) {          /* Let {[} and {]} survive */
-    int cnt = interval_.isOpeningPar(start);
-    if (cnt == 1) {
-      // Closing is allowed past the region
-      int closing = interval_.findclosing(start+1, interval_.par.length());
-      interval_.addIntervall(start, start+1);
-      interval_.addIntervall(closing, closing+1);
-    }
-    else if (cnt == 3)
-      start += 2;
-    start = interval_.nextNotIgnored(start+1);
-  }
+	while (start < region_end) {          /* Let {[} and {]} survive */
+		int cnt = interval_.isOpeningPar(start);
+		if (cnt == 1) {
+			// Closing is allowed past the region
+			int closing = interval_.findclosing(start+1, interval_.par.length());
+			interval_.addIntervall(start, start+1);
+			interval_.addIntervall(closing, closing+1);
+		}
+		else if (cnt == 3)
+			start += 2;
+		start = interval_.nextNotIgnored(start+1);
+	}
 }
 
 void LatexInfo::removeHead(KeyInfo const & actual, int count)
 {
-  if (actual.parenthesiscount == 0) {
-    // "{\tiny{} ...}" ==> "{{} ...}"
-    interval_.addIntervall(actual._tokenstart-count, actual._tokenstart + actual._tokensize);
-  }
-  else {
-    // Remove header hull, that is "\url{abcd}" ==> "abcd"
-    interval_.addIntervall(actual._tokenstart - count, actual._dataStart);
-    interval_.addIntervall(actual._dataEnd, actual._dataEnd+1);
-  }
+	if (actual.parenthesiscount == 0) {
+		// "{\tiny{} ...}" ==> "{{} ...}"
+		interval_.addIntervall(actual._tokenstart-count, actual._tokenstart + actual._tokensize);
+	}
+	else {
+		// Remove header hull, that is "\url{abcd}" ==> "abcd"
+		interval_.addIntervall(actual._tokenstart - count, actual._dataStart);
+		interval_.addIntervall(actual._dataEnd, actual._dataEnd+1);
+	}
 }
 
 int LatexInfo::dispatch(ostringstream &os, int previousStart, KeyInfo &actual)
 {
-  int nextKeyIdx = 0;
-  switch (actual.keytype)
-  {
-    case KeyInfo::isTitle: {
-      removeHead(actual);
-      nextKeyIdx = getNextKey();
-      break;
-    }
-    case KeyInfo::cleanToStart: {
-      actual._dataEnd = actual._dataStart;
-      nextKeyIdx = getNextKey();
-      // Search for end of arguments
-      int tmpIdx = find(nextKeyIdx, KeyInfo::endArguments);
-      if (tmpIdx > 0) {
-        for (int i = nextKeyIdx; i <= tmpIdx; i++) {
-          entries_[i].disabled = true;
-        }
-        actual._dataEnd = entries_[tmpIdx]._dataEnd;
-      }
-      while (interval_.par[actual._dataEnd] == ' ')
-        actual._dataEnd++;
-      interval_.addIntervall(0, actual._dataEnd+1);
-      interval_.actualdeptindex = 0;
-      interval_.depts[0] = actual._dataEnd+1;
-      interval_.closes[0] = -1;
-      break;
-    }
-    case KeyInfo::isText:
-      interval_.par[actual._tokenstart] = '#';
-      //interval_.addIntervall(actual._tokenstart, actual._tokenstart+1);
-      nextKeyIdx = getNextKey();
-      break;
-    case KeyInfo::noContent: {          /* char like "\hspace{2cm}" */
-      if (actual.disabled)
-        interval_.addIntervall(actual._tokenstart, actual._dataEnd);
-      else
-        interval_.addIntervall(actual._dataStart, actual._dataEnd);
-    }
-      // fall through
-    case KeyInfo::isChar: {
-      nextKeyIdx = getNextKey();
-      break;
-    }
-    case KeyInfo::isSize: {
-      if (actual.disabled || (interval_.par[actual._dataStart] != '{') || (interval_.par[actual._dataStart-1] == ' ')) {
-        if (actual.parenthesiscount == 0)
-          interval_.addIntervall(actual._tokenstart, actual._dataEnd);
-        else {
-          interval_.addIntervall(actual._tokenstart, actual._dataEnd+1);
-        }
-        nextKeyIdx = getNextKey();
-      } else {
-        // Here _dataStart points to '{', so correct it
-        actual._dataStart += 1;
-        actual._tokensize += 1;
-        actual.parenthesiscount = 1;
-        if (interval_.par[actual._dataStart] == '}') {
-          // Determine the end if used like '{\tiny{}...}'
-          actual._dataEnd = interval_.findclosing(actual._dataStart+1, interval_.par.length()) + 1;
-          interval_.addIntervall(actual._dataStart, actual._dataStart+1);
-        }
-        else {
-          // Determine the end if used like '\tiny{...}'
-          actual._dataEnd = interval_.findclosing(actual._dataStart, interval_.par.length()) + 1;
-        }
-        // Split on this key if not at start
-        int start = interval_.nextNotIgnored(previousStart);
-        if (start < actual._tokenstart) {
-          interval_.output(os, actual._tokenstart);
-          interval_.addIntervall(start, actual._tokenstart);
-        }
-        // discard entry if at end of actual
-        nextKeyIdx = process(os, actual);
-      }
-      break;
-    }
-    case KeyInfo::endArguments: {
-      // Remove trailing '{}' too
-      actual._dataStart += 1;
-      actual._dataEnd += 1;
-      interval_.addIntervall(actual._tokenstart, actual._dataEnd+1);
-      nextKeyIdx = getNextKey();
-      break;
-    }
-    case KeyInfo::noMain:
-      // fall through
-    case KeyInfo::isStandard: {
-      if (actual.disabled) {
-        removeHead(actual);
-        processRegion(actual._dataStart, actual._dataStart+1);
-        nextKeyIdx = getNextKey();
-      } else {
-        // Split on this key if not at datastart of calling entry
-        int start = interval_.nextNotIgnored(previousStart);
-        if (start < actual._tokenstart) {
-          interval_.output(os, actual._tokenstart);
-          interval_.addIntervall(start, actual._tokenstart);
-        }
-        // discard entry if at end of actual
-        nextKeyIdx = process(os, actual);
-      }
-      break;
-    }
-    case KeyInfo::removeWithArg: {
-      nextKeyIdx = getNextKey();
-      // Search for end of arguments
-      int tmpIdx = find(nextKeyIdx, KeyInfo::endArguments);
-      if (tmpIdx > 0) {
-        for (int i = nextKeyIdx; i <= tmpIdx; i++) {
-          entries_[i].disabled = true;
-        }
-        actual._dataEnd = entries_[tmpIdx]._dataEnd;
-      }
-      interval_.addIntervall(actual._tokenstart, actual._dataEnd+1);
-      break;
-    }
-    case KeyInfo::doRemove: {
-      // Remove the key with all parameters and following spaces
-      size_t pos;
-      size_t start;
-      if (interval_.par[actual._dataEnd-1] == ' ' || interval_.par[actual._dataEnd-1] == '}')
-        start = actual._dataEnd;
-      else
-        start = actual._dataEnd+1;
-      for (pos = start; pos < interval_.par.length(); pos++) {
-        if ((interval_.par[pos] != ' ') && (interval_.par[pos] != '%'))
-          break;
-      }
-      // Remove also enclosing parentheses [] and {}
-      int numpars = 0;
-      int spaces = 0;
-      while (actual._tokenstart > numpars) {
-        if (pos+numpars >= interval_.par.size())
-          break;
-        else if (interval_.par[pos+numpars] == ']' && interval_.par[actual._tokenstart-numpars-1] == '[')
-          numpars++;
-        else if (interval_.par[pos+numpars] == '}' && interval_.par[actual._tokenstart-numpars-1] == '{')
-          numpars++;
-        else
-          break;
-      }
-      if (numpars > 0) {
-        if (interval_.par[pos+numpars] == ' ')
-          spaces++;
-      }
-
-      interval_.addIntervall(actual._tokenstart-numpars, pos+numpars+spaces);
-      nextKeyIdx = getNextKey();
-      break;
-    }
-    case KeyInfo::isList: {
-      // Discard space before _tokenstart
-      int count;
-      for (count = 0; count < actual._tokenstart; count++) {
-        if (interval_.par[actual._tokenstart-count-1] != ' ')
-          break;
-      }
-      nextKeyIdx = getNextKey();
-      int tmpIdx = find(nextKeyIdx, KeyInfo::endArguments);
-      if (tmpIdx > 0) {
-        // Special case: \item is not a list, but a command (like in Style Author_Biography in maa-monthly.layout)
-        // with arguments
-        // How else can we catch this one?
-        for (int i = nextKeyIdx; i <= tmpIdx; i++) {
-          entries_[i].disabled = true;
-        }
-        actual._dataEnd = entries_[tmpIdx]._dataEnd;
-      }
-      else if (nextKeyIdx > 0) {
-        // Ignore any lang entries inside data region
-        for (int i = nextKeyIdx; i < int(entries_.size()) && entries_[i]._tokenstart < actual._dataEnd; i++) {
-          if (entries_[i].keytype == KeyInfo::isMain)
-            entries_[i].disabled = true;
-        }
-      }
-      if (actual.disabled) {
-        interval_.addIntervall(actual._tokenstart-count, actual._dataEnd+1);
-      }
-      else {
-        interval_.addIntervall(actual._tokenstart-count, actual._tokenstart);
-      }
-      if (interval_.par[actual._dataEnd+1] == '[') {
-        int posdown = interval_.findclosing(actual._dataEnd+2, interval_.par.length(), '[', ']');
-        if ((interval_.par[actual._dataEnd+2] == '{') &&
-            (interval_.par[posdown-1] == '}')) {
-          interval_.addIntervall(actual._dataEnd+1,actual._dataEnd+3);
-          interval_.addIntervall(posdown-1, posdown+1);
-        }
-        else {
-          interval_.addIntervall(actual._dataEnd+1, actual._dataEnd+2);
-          interval_.addIntervall(posdown, posdown+1);
-        }
-        int blk = interval_.nextNotIgnored(actual._dataEnd+1);
-        if (blk > posdown) {
-          // Discard at most 1 space after empty item
-          int count;
-          for (count = 0; count < 1; count++) {
-            if (interval_.par[blk+count] != ' ')
-              break;
-          }
-          if (count > 0)
-            interval_.addIntervall(blk, blk+count);
-        }
-      }
-      break;
-    }
-    case KeyInfo::isSectioning: {
-      // Discard spaces before _tokenstart
-      int count;
-      int val = actual._tokenstart;
-      for (count = 0; count < actual._tokenstart;) {
-        val = interval_.previousNotIgnored(val-1);
-        if (val < 0 || interval_.par[val] != ' ')
-          break;
-        else {
-          count = actual._tokenstart - val;
-        }
-      }
-      if (actual.disabled) {
-        removeHead(actual, count);
-        nextKeyIdx = getNextKey();
-      } else {
-        interval_.addIntervall(actual._tokenstart-count, actual._tokenstart);
-        nextKeyIdx = process(os, actual);
-      }
-      break;
-    }
-    case KeyInfo::isMath: {
-      // Same as regex, use the content unchanged
-      nextKeyIdx = getNextKey();
-      break;
-    }
-    case KeyInfo::isRegex: {
-      // DO NOT SPLIT ON REGEX
-      // Do not disable
-      nextKeyIdx = getNextKey();
-      break;
-    }
-    case KeyInfo::isIgnored: {
-      // Treat like a character for now
-      nextKeyIdx = getNextKey();
-      break;
-    }
-    case KeyInfo::isMain: {
-      if (interval_.par.substr(actual._dataStart, 2) == "% ")
-        interval_.addIntervall(actual._dataStart, actual._dataStart+2);
-      if (actual._tokenstart > 0) {
-        int prev = interval_.previousNotIgnored(actual._tokenstart - 1);
-        if ((prev >= 0) && interval_.par[prev] == '%')
-          interval_.addIntervall(prev, prev+1);
-      }
-      if (actual.disabled) {
-        removeHead(actual);
-        interval_.langcount++;
-        if ((interval_.par.substr(actual._dataStart, 3) == " \\[") ||
-            (interval_.par.substr(actual._dataStart, 8) == " \\begin{")) {
-          // Discard also the space before math-equation
-          interval_.addIntervall(actual._dataStart, actual._dataStart+1);
-        }
-        nextKeyIdx = getNextKey();
-        // interval.resetOpenedP(actual._dataStart-1);
-      }
-      else {
-        if (actual._tokenstart < 26) {
-          // for the first (and maybe dummy) language
-          interval_.setForDefaultLang(actual);
-        }
-        interval_.resetOpenedP(actual._dataStart-1);
-      }
-      break;
-    }
-    case KeyInfo::invalid:
-    case KeyInfo::headRemove:
-      // These two cases cannot happen, already handled
-      // fall through
-    default: {
-      // LYXERR(Debug::INFO, "Unhandled keytype");
-      nextKeyIdx = getNextKey();
-      break;
-    }
-  }
-  return nextKeyIdx;
+	int nextKeyIdx = 0;
+	switch (actual.keytype)
+	{
+	case KeyInfo::isTitle: {
+		removeHead(actual);
+		nextKeyIdx = getNextKey();
+		break;
+	}
+	case KeyInfo::cleanToStart: {
+		actual._dataEnd = actual._dataStart;
+		nextKeyIdx = getNextKey();
+		// Search for end of arguments
+		int tmpIdx = find(nextKeyIdx, KeyInfo::endArguments);
+		if (tmpIdx > 0) {
+			for (int i = nextKeyIdx; i <= tmpIdx; i++) {
+				entries_[i].disabled = true;
+			}
+			actual._dataEnd = entries_[tmpIdx]._dataEnd;
+		}
+		while (interval_.par[actual._dataEnd] == ' ')
+			actual._dataEnd++;
+		interval_.addIntervall(0, actual._dataEnd+1);
+		interval_.actualdeptindex = 0;
+		interval_.depts[0] = actual._dataEnd+1;
+		interval_.closes[0] = -1;
+		break;
+	}
+	case KeyInfo::isText:
+		interval_.par[actual._tokenstart] = '#';
+		//interval_.addIntervall(actual._tokenstart, actual._tokenstart+1);
+		nextKeyIdx = getNextKey();
+		break;
+	case KeyInfo::noContent: {          /* char like "\hspace{2cm}" */
+		if (actual.disabled)
+			interval_.addIntervall(actual._tokenstart, actual._dataEnd);
+		else
+			interval_.addIntervall(actual._dataStart, actual._dataEnd);
+	}
+		// fall through
+	case KeyInfo::isChar: {
+		nextKeyIdx = getNextKey();
+		break;
+	}
+	case KeyInfo::isSize: {
+		if (actual.disabled || (interval_.par[actual._dataStart] != '{') || (interval_.par[actual._dataStart-1] == ' ')) {
+			if (actual.parenthesiscount == 0)
+				interval_.addIntervall(actual._tokenstart, actual._dataEnd);
+			else {
+				interval_.addIntervall(actual._tokenstart, actual._dataEnd+1);
+			}
+			nextKeyIdx = getNextKey();
+		} else {
+			// Here _dataStart points to '{', so correct it
+			actual._dataStart += 1;
+			actual._tokensize += 1;
+			actual.parenthesiscount = 1;
+			if (interval_.par[actual._dataStart] == '}') {
+				// Determine the end if used like '{\tiny{}...}'
+				actual._dataEnd = interval_.findclosing(actual._dataStart+1, interval_.par.length()) + 1;
+				interval_.addIntervall(actual._dataStart, actual._dataStart+1);
+			}
+			else {
+				// Determine the end if used like '\tiny{...}'
+				actual._dataEnd = interval_.findclosing(actual._dataStart, interval_.par.length()) + 1;
+			}
+			// Split on this key if not at start
+			int start = interval_.nextNotIgnored(previousStart);
+			if (start < actual._tokenstart) {
+				interval_.output(os, actual._tokenstart);
+				interval_.addIntervall(start, actual._tokenstart);
+			}
+			// discard entry if at end of actual
+			nextKeyIdx = process(os, actual);
+		}
+		break;
+	}
+	case KeyInfo::endArguments: {
+		// Remove trailing '{}' too
+		actual._dataStart += 1;
+		actual._dataEnd += 1;
+		interval_.addIntervall(actual._tokenstart, actual._dataEnd+1);
+		nextKeyIdx = getNextKey();
+		break;
+	}
+	case KeyInfo::noMain:
+		// fall through
+	case KeyInfo::isStandard: {
+		if (actual.disabled) {
+			removeHead(actual);
+			processRegion(actual._dataStart, actual._dataStart+1);
+			nextKeyIdx = getNextKey();
+		} else {
+			// Split on this key if not at datastart of calling entry
+			int start = interval_.nextNotIgnored(previousStart);
+			if (start < actual._tokenstart) {
+				interval_.output(os, actual._tokenstart);
+				interval_.addIntervall(start, actual._tokenstart);
+			}
+			// discard entry if at end of actual
+			nextKeyIdx = process(os, actual);
+		}
+		break;
+	}
+	case KeyInfo::removeWithArg: {
+		nextKeyIdx = getNextKey();
+		// Search for end of arguments
+		int tmpIdx = find(nextKeyIdx, KeyInfo::endArguments);
+		if (tmpIdx > 0) {
+			for (int i = nextKeyIdx; i <= tmpIdx; i++) {
+				entries_[i].disabled = true;
+			}
+			actual._dataEnd = entries_[tmpIdx]._dataEnd;
+		}
+		interval_.addIntervall(actual._tokenstart, actual._dataEnd+1);
+		break;
+	}
+	case KeyInfo::doRemove: {
+		// Remove the key with all parameters and following spaces
+		size_t pos;
+		size_t start;
+		if (interval_.par[actual._dataEnd-1] == ' ' || interval_.par[actual._dataEnd-1] == '}')
+			start = actual._dataEnd;
+		else
+			start = actual._dataEnd+1;
+		for (pos = start; pos < interval_.par.length(); pos++) {
+			if ((interval_.par[pos] != ' ') && (interval_.par[pos] != '%'))
+				break;
+		}
+		// Remove also enclosing parentheses [] and {}
+		int numpars = 0;
+		int spaces = 0;
+		while (actual._tokenstart > numpars) {
+			if (pos+numpars >= interval_.par.size())
+				break;
+			else if (interval_.par[pos+numpars] == ']' && interval_.par[actual._tokenstart-numpars-1] == '[')
+				numpars++;
+			else if (interval_.par[pos+numpars] == '}' && interval_.par[actual._tokenstart-numpars-1] == '{')
+				numpars++;
+			else
+				break;
+		}
+		if (numpars > 0) {
+			if (interval_.par[pos+numpars] == ' ')
+				spaces++;
+		}
+
+		interval_.addIntervall(actual._tokenstart-numpars, pos+numpars+spaces);
+		nextKeyIdx = getNextKey();
+		break;
+	}
+	case KeyInfo::isList: {
+		// Discard space before _tokenstart
+		int count;
+		for (count = 0; count < actual._tokenstart; count++) {
+			if (interval_.par[actual._tokenstart-count-1] != ' ')
+				break;
+		}
+		nextKeyIdx = getNextKey();
+		int tmpIdx = find(nextKeyIdx, KeyInfo::endArguments);
+		if (tmpIdx > 0) {
+			// Special case: \item is not a list, but a command (like in Style Author_Biography in maa-monthly.layout)
+			// with arguments
+			// How else can we catch this one?
+			for (int i = nextKeyIdx; i <= tmpIdx; i++) {
+				entries_[i].disabled = true;
+			}
+			actual._dataEnd = entries_[tmpIdx]._dataEnd;
+		}
+		else if (nextKeyIdx > 0) {
+			// Ignore any lang entries inside data region
+			for (int i = nextKeyIdx; i < int(entries_.size()) && entries_[i]._tokenstart < actual._dataEnd; i++) {
+				if (entries_[i].keytype == KeyInfo::isMain)
+					entries_[i].disabled = true;
+			}
+		}
+		if (actual.disabled) {
+			interval_.addIntervall(actual._tokenstart-count, actual._dataEnd+1);
+		}
+		else {
+			interval_.addIntervall(actual._tokenstart-count, actual._tokenstart);
+		}
+		if (interval_.par[actual._dataEnd+1] == '[') {
+			int posdown = interval_.findclosing(actual._dataEnd+2, interval_.par.length(), '[', ']');
+			if ((interval_.par[actual._dataEnd+2] == '{') &&
+					(interval_.par[posdown-1] == '}')) {
+				interval_.addIntervall(actual._dataEnd+1,actual._dataEnd+3);
+				interval_.addIntervall(posdown-1, posdown+1);
+			}
+			else {
+				interval_.addIntervall(actual._dataEnd+1, actual._dataEnd+2);
+				interval_.addIntervall(posdown, posdown+1);
+			}
+			int blk = interval_.nextNotIgnored(actual._dataEnd+1);
+			if (blk > posdown) {
+				// Discard at most 1 space after empty item
+				int count;
+				for (count = 0; count < 1; count++) {
+					if (interval_.par[blk+count] != ' ')
+						break;
+				}
+				if (count > 0)
+					interval_.addIntervall(blk, blk+count);
+			}
+		}
+		break;
+	}
+	case KeyInfo::isSectioning: {
+		// Discard spaces before _tokenstart
+		int count;
+		int val = actual._tokenstart;
+		for (count = 0; count < actual._tokenstart;) {
+			val = interval_.previousNotIgnored(val-1);
+			if (val < 0 || interval_.par[val] != ' ')
+				break;
+			else {
+				count = actual._tokenstart - val;
+			}
+		}
+		if (actual.disabled) {
+			removeHead(actual, count);
+			nextKeyIdx = getNextKey();
+		} else {
+			interval_.addIntervall(actual._tokenstart-count, actual._tokenstart);
+			nextKeyIdx = process(os, actual);
+		}
+		break;
+	}
+	case KeyInfo::isMath: {
+		// Same as regex, use the content unchanged
+		nextKeyIdx = getNextKey();
+		break;
+	}
+	case KeyInfo::isRegex: {
+		// DO NOT SPLIT ON REGEX
+		// Do not disable
+		nextKeyIdx = getNextKey();
+		break;
+	}
+	case KeyInfo::isIgnored: {
+		// Treat like a character for now
+		nextKeyIdx = getNextKey();
+		break;
+	}
+	case KeyInfo::isMain: {
+		if (interval_.par.substr(actual._dataStart, 2) == "% ")
+			interval_.addIntervall(actual._dataStart, actual._dataStart+2);
+		if (actual._tokenstart > 0) {
+			int prev = interval_.previousNotIgnored(actual._tokenstart - 1);
+			if ((prev >= 0) && interval_.par[prev] == '%')
+				interval_.addIntervall(prev, prev+1);
+		}
+		if (actual.disabled) {
+			removeHead(actual);
+			interval_.langcount++;
+			if ((interval_.par.substr(actual._dataStart, 3) == " \\[") ||
+					(interval_.par.substr(actual._dataStart, 8) == " \\begin{")) {
+				// Discard also the space before math-equation
+				interval_.addIntervall(actual._dataStart, actual._dataStart+1);
+			}
+			nextKeyIdx = getNextKey();
+			// interval.resetOpenedP(actual._dataStart-1);
+		}
+		else {
+			if (actual._tokenstart < 26) {
+				// for the first (and maybe dummy) language
+				interval_.setForDefaultLang(actual);
+			}
+			interval_.resetOpenedP(actual._dataStart-1);
+		}
+		break;
+	}
+	case KeyInfo::invalid:
+	case KeyInfo::headRemove:
+		// These two cases cannot happen, already handled
+		// fall through
+	default: {
+		// LYXERR(Debug::INFO, "Unhandled keytype");
+		nextKeyIdx = getNextKey();
+		break;
+	}
+	}
+	return nextKeyIdx;
 }
 
 int LatexInfo::process(ostringstream & os, KeyInfo const & actual )
 {
-  int end = interval_.nextNotIgnored(actual._dataEnd);
-  int oldStart = actual._dataStart;
-  int nextKeyIdx = getNextKey();
-  while (true) {
-    if ((nextKeyIdx < 0) ||
-        (entries_[nextKeyIdx]._tokenstart >= actual._dataEnd) ||
-        (entries_[nextKeyIdx].keytype == KeyInfo::invalid)) {
-      if (oldStart <= end) {
-        processRegion(oldStart, end);
-        oldStart = end+1;
-      }
-      break;
-    }
-    KeyInfo &nextKey = getKeyInfo(nextKeyIdx);
-
-    if ((nextKey.keytype == KeyInfo::isMain) && !nextKey.disabled) {
-      (void) dispatch(os, actual._dataStart, nextKey);
-      end = nextKey._tokenstart;
-      break;
-    }
-    processRegion(oldStart, nextKey._tokenstart);
-    nextKeyIdx = dispatch(os, actual._dataStart, nextKey);
-
-    oldStart = nextKey._dataEnd+1;
-  }
-  // now nextKey is either invalid or is outside of actual._dataEnd
-  // output the remaining and discard myself
-  if (oldStart <= end) {
-    processRegion(oldStart, end);
-  }
-  if (interval_.par.size() > (size_t) end && interval_.par[end] == '}') {
-    end += 1;
-    // This is the normal case.
-    // But if using the firstlanguage, the closing may be missing
-  }
-  // get minimum of 'end' and  'actual._dataEnd' in case that the nextKey.keytype was 'KeyInfo::isMain'
-  int output_end;
-  if (actual._dataEnd < end)
-    output_end = interval_.nextNotIgnored(actual._dataEnd);
-  else if (interval_.par.size() > (size_t) end)
-    output_end = interval_.nextNotIgnored(end);
-  else
-    output_end = interval_.par.size();
-  if ((actual.keytype == KeyInfo::isMain) && actual.disabled) {
-    interval_.addIntervall(actual._tokenstart, actual._tokenstart+actual._tokensize);
-  }
-  // Remove possible empty data
-  int dstart = interval_.nextNotIgnored(actual._dataStart);
-  while (interval_.isOpeningPar(dstart) == 1) {
-    interval_.addIntervall(dstart, dstart+1);
-    int dend = interval_.findclosing(dstart+1, output_end);
-    interval_.addIntervall(dend, dend+1);
-    dstart = interval_.nextNotIgnored(dstart+1);
-  }
-  if (dstart < output_end)
-    interval_.output(os, output_end);
-  if (nextKeyIdx < 0)
-    interval_.addIntervall(0, end);
-  else
-    interval_.addIntervall(actual._tokenstart, end);
-  return nextKeyIdx;
+	int end = interval_.nextNotIgnored(actual._dataEnd);
+	int oldStart = actual._dataStart;
+	int nextKeyIdx = getNextKey();
+	while (true) {
+		if ((nextKeyIdx < 0) ||
+				(entries_[nextKeyIdx]._tokenstart >= actual._dataEnd) ||
+				(entries_[nextKeyIdx].keytype == KeyInfo::invalid)) {
+			if (oldStart <= end) {
+				processRegion(oldStart, end);
+				oldStart = end+1;
+			}
+			break;
+		}
+		KeyInfo &nextKey = getKeyInfo(nextKeyIdx);
+
+		if ((nextKey.keytype == KeyInfo::isMain) && !nextKey.disabled) {
+			(void) dispatch(os, actual._dataStart, nextKey);
+			end = nextKey._tokenstart;
+			break;
+		}
+		processRegion(oldStart, nextKey._tokenstart);
+		nextKeyIdx = dispatch(os, actual._dataStart, nextKey);
+
+		oldStart = nextKey._dataEnd+1;
+	}
+	// now nextKey is either invalid or is outside of actual._dataEnd
+	// output the remaining and discard myself
+	if (oldStart <= end) {
+		processRegion(oldStart, end);
+	}
+	if (interval_.par.size() > (size_t) end && interval_.par[end] == '}') {
+		end += 1;
+		// This is the normal case.
+		// But if using the firstlanguage, the closing may be missing
+	}
+	// get minimum of 'end' and  'actual._dataEnd' in case that the nextKey.keytype was 'KeyInfo::isMain'
+	int output_end;
+	if (actual._dataEnd < end)
+		output_end = interval_.nextNotIgnored(actual._dataEnd);
+	else if (interval_.par.size() > (size_t) end)
+		output_end = interval_.nextNotIgnored(end);
+	else
+		output_end = interval_.par.size();
+	if ((actual.keytype == KeyInfo::isMain) && actual.disabled) {
+		interval_.addIntervall(actual._tokenstart, actual._tokenstart+actual._tokensize);
+	}
+	// Remove possible empty data
+	int dstart = interval_.nextNotIgnored(actual._dataStart);
+	while (interval_.isOpeningPar(dstart) == 1) {
+		interval_.addIntervall(dstart, dstart+1);
+		int dend = interval_.findclosing(dstart+1, output_end);
+		interval_.addIntervall(dend, dend+1);
+		dstart = interval_.nextNotIgnored(dstart+1);
+	}
+	if (dstart < output_end)
+		interval_.output(os, output_end);
+	if (nextKeyIdx < 0)
+		interval_.addIntervall(0, end);
+	else
+		interval_.addIntervall(actual._tokenstart, end);
+	return nextKeyIdx;
 }
 
 string splitOnKnownMacros(string par, bool isPatternString)
 {
-  ostringstream os;
-  LatexInfo li(par, isPatternString);
-  // LYXERR(Debug::INFO, "Berfore split: " << par);
-  KeyInfo DummyKey = KeyInfo(KeyInfo::KeyType::isMain, 2, true);
-  DummyKey.head = "";
-  DummyKey._tokensize = 0;
-  DummyKey._dataStart = 0;
-  DummyKey._dataEnd = par.length();
-  DummyKey.disabled = true;
-  int firstkeyIdx = li.getFirstKey();
-  string s;
-  if (firstkeyIdx >= 0) {
-    KeyInfo firstKey = li.getKeyInfo(firstkeyIdx);
-    DummyKey._tokenstart = firstKey._tokenstart;
-    int nextkeyIdx;
-    if ((firstKey.keytype != KeyInfo::isMain) || firstKey.disabled) {
-      // Use dummy firstKey
-      firstKey = DummyKey;
-      (void) li.setNextKey(firstkeyIdx);
-    }
-    else {
-      if (par.substr(firstKey._dataStart, 2) == "% ")
-        li.addIntervall(firstKey._dataStart, firstKey._dataStart+2);
-    }
-    nextkeyIdx = li.process(os, firstKey);
-    while (nextkeyIdx >= 0) {
-      // Check for a possible gap between the last
-      // entry and this one
-      int datastart = li.nextNotIgnored(firstKey._dataStart);
-      KeyInfo &nextKey = li.getKeyInfo(nextkeyIdx);
-      if ((nextKey._tokenstart > datastart)) {
-        // Handle the gap
-        firstKey._dataStart = datastart;
-        firstKey._dataEnd = par.length();
-        (void) li.setNextKey(nextkeyIdx);
-        // Fake the last opened parenthesis
-        li.setForDefaultLang(firstKey);
-        nextkeyIdx = li.process(os, firstKey);
-      }
-      else {
-        if (nextKey.keytype != KeyInfo::isMain) {
-          firstKey._dataStart = datastart;
-          firstKey._dataEnd = nextKey._dataEnd+1;
-          (void) li.setNextKey(nextkeyIdx);
-          li.setForDefaultLang(firstKey);
-          nextkeyIdx = li.process(os, firstKey);
-        }
-        else {
-          nextkeyIdx = li.process(os, nextKey);
-        }
-      }
-    }
-    // Handle the remaining
-    firstKey._dataStart = li.nextNotIgnored(firstKey._dataStart);
-    firstKey._dataEnd = par.length();
-    // Check if ! empty
-    if ((firstKey._dataStart < firstKey._dataEnd) &&
-        (par[firstKey._dataStart] != '}')) {
-      li.setForDefaultLang(firstKey);
-      (void) li.process(os, firstKey);
-    }
-    s = os.str();
-    // return string definitelly impossible to match, but should be known
-  }
-  else
-    s = par;                            /* no known macros found */
-  // LYXERR(Debug::INFO, "After split: " << s);
-  return s;
+	ostringstream os;
+	LatexInfo li(par, isPatternString);
+	// LYXERR(Debug::INFO, "Berfore split: " << par);
+	KeyInfo DummyKey = KeyInfo(KeyInfo::KeyType::isMain, 2, true);
+	DummyKey.head = "";
+	DummyKey._tokensize = 0;
+	DummyKey._dataStart = 0;
+	DummyKey._dataEnd = par.length();
+	DummyKey.disabled = true;
+	int firstkeyIdx = li.getFirstKey();
+	string s;
+	if (firstkeyIdx >= 0) {
+		KeyInfo firstKey = li.getKeyInfo(firstkeyIdx);
+		DummyKey._tokenstart = firstKey._tokenstart;
+		int nextkeyIdx;
+		if ((firstKey.keytype != KeyInfo::isMain) || firstKey.disabled) {
+			// Use dummy firstKey
+			firstKey = DummyKey;
+			(void) li.setNextKey(firstkeyIdx);
+		}
+		else {
+			if (par.substr(firstKey._dataStart, 2) == "% ")
+				li.addIntervall(firstKey._dataStart, firstKey._dataStart+2);
+		}
+		nextkeyIdx = li.process(os, firstKey);
+		while (nextkeyIdx >= 0) {
+			// Check for a possible gap between the last
+			// entry and this one
+			int datastart = li.nextNotIgnored(firstKey._dataStart);
+			KeyInfo &nextKey = li.getKeyInfo(nextkeyIdx);
+			if ((nextKey._tokenstart > datastart)) {
+				// Handle the gap
+				firstKey._dataStart = datastart;
+				firstKey._dataEnd = par.length();
+				(void) li.setNextKey(nextkeyIdx);
+				// Fake the last opened parenthesis
+				li.setForDefaultLang(firstKey);
+				nextkeyIdx = li.process(os, firstKey);
+			}
+			else {
+				if (nextKey.keytype != KeyInfo::isMain) {
+					firstKey._dataStart = datastart;
+					firstKey._dataEnd = nextKey._dataEnd+1;
+					(void) li.setNextKey(nextkeyIdx);
+					li.setForDefaultLang(firstKey);
+					nextkeyIdx = li.process(os, firstKey);
+				}
+				else {
+					nextkeyIdx = li.process(os, nextKey);
+				}
+			}
+		}
+		// Handle the remaining
+		firstKey._dataStart = li.nextNotIgnored(firstKey._dataStart);
+		firstKey._dataEnd = par.length();
+		// Check if ! empty
+		if ((firstKey._dataStart < firstKey._dataEnd) &&
+				(par[firstKey._dataStart] != '}')) {
+			li.setForDefaultLang(firstKey);
+			(void) li.process(os, firstKey);
+		}
+		s = os.str();
+		// return string definitelly impossible to match, but should be known
+	}
+	else
+		s = par;                            /* no known macros found */
+	// LYXERR(Debug::INFO, "After split: " << s);
+	return s;
 }
 
 /*
@@ -3520,7 +3520,7 @@ static void modifyRegexForMatchWord(string &t)
 	}
 	else if (lastpos < t.length())
 		s += t.substr(lastpos, t.length() - lastpos);
-      t = "\\b" + s + "\\b";
+	t = "\\b" + s + "\\b";
 }
 
 MatchStringAdv::MatchStringAdv(lyx::Buffer & buf, FindAndReplaceOptions & opt)
@@ -3665,7 +3665,7 @@ MatchResult MatchStringAdv::findAux(DocIterator const & cur, int len, bool at_be
 
 	mres.searched_size = len;
 	if (at_begin &&
-		(opt.restr == FindAndReplaceOptions::R_ONLY_MATHS && !cur.inMathed()) )
+			(opt.restr == FindAndReplaceOptions::R_ONLY_MATHS && !cur.inMathed()) )
 		return mres;
 
 	docstring docstr = stringifyFromForSearch(opt, cur, len);
@@ -3796,23 +3796,23 @@ MatchResult MatchStringAdv::findAux(DocIterator const & cur, int len, bool at_be
 		mres.pos = m[2].first - m[0].first;;
 #endif
 		if (mres.match2end < 0)
-		  mres.match_len = 0;
+			mres.match_len = 0;
 		mres.leadsize = leadingsize;
 #if QTSEARCH
 		if (mres.match_len > 0) {
-		  string a0 = match.captured(0).mid(mres.pos + mres.match_prefix, mres.match_len).toStdString();
-		  mres.result.push_back(a0);
-		  for (int i = 3; i <= match.lastCapturedIndex(); i++) {
-		    mres.result.push_back(match.captured(i).toStdString());
-		  }
+			string a0 = match.captured(0).mid(mres.pos + mres.match_prefix, mres.match_len).toStdString();
+			mres.result.push_back(a0);
+			for (int i = 3; i <= match.lastCapturedIndex(); i++) {
+				mres.result.push_back(match.captured(i).toStdString());
+			}
 		}
 #else
 		if (mres.match_len > 0) {
-		  string a0 = m[0].str().substr(mres.pos + mres.match_prefix, mres.match_len);
-		  mres.result.push_back(a0);
-		  for (size_t i = 3; i < m.size(); i++) {
-		    mres.result.push_back(m[i]);
-		  }
+			string a0 = m[0].str().substr(mres.pos + mres.match_prefix, mres.match_len);
+			mres.result.push_back(a0);
+			for (size_t i = 3; i < m.size(); i++) {
+				mres.result.push_back(m[i]);
+			}
 		}
 #endif
 		return mres;
@@ -3842,25 +3842,25 @@ MatchResult MatchStringAdv::operator()(DocIterator const & cur, int len, bool at
 #if 0
 static bool simple_replace(string &t, string from, string to)
 {
-  regex repl("(\\\\)*(" + from + ")");
-  string s("");
-  size_t lastpos = 0;
-  smatch sub;
-  for (sregex_iterator it(t.begin(), t.end(), repl), end; it != end; ++it) {
-    sub = *it;
-    if ((sub.position(2) - sub.position(0)) % 2 == 1)
-      continue;
-    if (lastpos < (size_t) sub.position(2))
-      s += t.substr(lastpos, sub.position(2) - lastpos);
-    s += to;
-    lastpos = sub.position(2) + sub.length(2);
-  }
-  if (lastpos == 0)
-    return false;
-  else if (lastpos < t.length())
-    s += t.substr(lastpos, t.length() - lastpos);
-  t = s;
-  return true;
+	regex repl("(\\\\)*(" + from + ")");
+	string s("");
+	size_t lastpos = 0;
+	smatch sub;
+	for (sregex_iterator it(t.begin(), t.end(), repl), end; it != end; ++it) {
+		sub = *it;
+		if ((sub.position(2) - sub.position(0)) % 2 == 1)
+			continue;
+		if (lastpos < (size_t) sub.position(2))
+			s += t.substr(lastpos, sub.position(2) - lastpos);
+		s += to;
+		lastpos = sub.position(2) + sub.length(2);
+	}
+	if (lastpos == 0)
+		return false;
+	else if (lastpos < t.length())
+		s += t.substr(lastpos, t.length() - lastpos);
+	t = s;
+	return true;
 }
 #endif
 
@@ -3934,7 +3934,7 @@ docstring stringifyFromCursor(DocIterator const & cur, int len)
 		// TODO what about searching beyond/across paragraph breaks ?
 		// TODO Try adding a AS_STR_INSERTS as last arg
 		pos_type end = ( len == -1 || cur.pos() + len > int(par.size()) ) ?
-			int(par.size()) : cur.pos() + len;
+					int(par.size()) : cur.pos() + len;
 		// OutputParams runparams(&cur.buffer()->params().encoding());
 		OutputParams runparams(encodings.fromLyXName("utf8"));
 		runparams.nice = true;
@@ -3954,17 +3954,17 @@ docstring stringifyFromCursor(DocIterator const & cur, int len)
 			runparams.for_searchAdv |= OutputParams::SearchNonOutput;
 		}
 		LYXERR(Debug::FIND, "Stringifying with cur: "
-			<< cur << ", from pos: " << cur.pos() << ", end: " << end);
+		       << cur << ", from pos: " << cur.pos() << ", end: " << end);
 		return from_utf8(latexNamesToUtf8(par.asString(cur.pos(), end,
-								option,
-								&runparams)));
+							       option,
+							       &runparams)));
 	} else if (cur.inMathed()) {
 		CursorSlice cs = cur.top();
 		MathData md = cs.cell();
 		MathData::const_iterator it_end =
-			(( len == -1 || cs.pos() + len > int(md.size()))
-			 ? md.end()
-			 : md.begin() + cs.pos() + len );
+				(( len == -1 || cs.pos() + len > int(md.size()))
+				 ? md.end()
+				 : md.begin() + cs.pos() + len );
 		MathData md2;
 		for (MathData::const_iterator it = md.begin() + cs.pos(); it != it_end; ++it)
 			md2.push_back(*it);
@@ -4032,9 +4032,9 @@ docstring latexifyFromCursor(DocIterator const & cur, int len)
 		CursorSlice const & cs = cur.top();
 		MathData md = cs.cell();
 		MathData::const_iterator it_end =
-			((len == -1 || cs.pos() + len > int(md.size()))
-			 ? md.end()
-			 : md.begin() + cs.pos() + len);
+				((len == -1 || cs.pos() + len > int(md.size()))
+				 ? md.end()
+				 : md.begin() + cs.pos() + len);
 		MathData md2;
 		for (MathData::const_iterator it = md.begin() + cs.pos();
 		     it != it_end; ++it)
@@ -4088,9 +4088,9 @@ static void displayMResult(MatchResult &mres, string from, DocIterator & cur)
 	for (size_t i = 0; i < mres.result.size(); i++)
 		LYXERR0( "Match " << i << " = \"" << mres.result[i] << "\"");
 }
-	#define displayMres(s, txt, cur) displayMResult(s, txt, cur);
+#define displayMres(s, txt, cur) displayMResult(s, txt, cur);
 #else
-	#define displayMres(s, txt, cur)
+#define displayMres(s, txt, cur)
 #endif
 
 /** Finalize an advanced find operation, advancing the cursor to the innermost
@@ -4159,85 +4159,85 @@ MatchResult findAdvFinalize(DocIterator & cur, MatchStringAdv const & match, Mat
 	// Compute the match length
 	int len = 1;
 	if (cur.pos() + len > cur.lastpos())
-	  return fail;
+		return fail;
 
 	LASSERT(match.use_regexp, /**/);
 	{
-          int minl = 1;
-          int maxl = cur.lastpos() - cur.pos();
-          // Greedy behaviour while matching regexps
-          while (maxl > minl) {
-            MatchResult mres2;
-            mres2 = match(cur, len, at_begin);
-            displayMres(mres2, "Finalize loop", cur);
-            int actual_match_len = mres2.match_len;
-            if (actual_match_len >= max_match.match_len) {
-              // actual_match_len > max_match _can_ happen,
-              // if the search area splits
-              // some following word so that the regex
-              // (e.g. 'r.*r\b' matches 'r' from the middle of the
-              // splitted word)
-              // This means, the len value is too big
-	      actual_match_len = max_match.match_len;
-	      max_match = mres2;
-	      max_match.match_len = actual_match_len;
-              maxl = len;
-              if (maxl - minl < 4)
-                len = (maxl + minl)/2;
-              else
-                len = minl + (maxl - minl + 3)/4;
-            }
-            else {
-              // (actual_match_len < max_match.match_len)
-              minl = len + 1;
-              len = (maxl + minl)/2;
-            }
-          }
-	  len = minl;
-          old_cur = cur;
-          // Search for real start of matched characters
-          while (len > 1) {
-            MatchResult actual_match;
-            do {
-              cur.forwardPos();
-            } while (cur.depth() > old_cur.depth()); /* Skip inner insets */
-            if (cur.depth() < old_cur.depth()) {
-              // Outer inset?
-              LYXERR(Debug::INFO, "cur.depth() < old_cur.depth(), this should never happen");
-              break;
-            }
-            if (cur.pos() != old_cur.pos()) {
-              // OK, forwarded 1 pos in actual inset
-              actual_match = match(cur, len-1, at_begin);
-              if (actual_match.match_len == max_match.match_len) {
-                // Ha, got it! The shorter selection has the same match length
-                len--;
-                old_cur = cur;
-		max_match = actual_match;
-              }
-              else {
-                // OK, the shorter selection matches less chars, revert to previous value
-                cur = old_cur;
-                break;
-              }
-            }
-            else {
-              LYXERR(Debug::INFO, "cur.pos() == old_cur.pos(), this should never happen");
-              actual_match = match(cur, len, at_begin);
-              if (actual_match.match_len == max_match.match_len) {
-                old_cur = cur;
-                max_match = actual_match;
-              }
-            }
-          }
-          if (len == 0)
-            return fail;
-          else {
-            max_match.pos_len = len;
-	    displayMres(max_match, "SEARCH RESULT", cur)
-            return max_match;
-          }
-        }
+		int minl = 1;
+		int maxl = cur.lastpos() - cur.pos();
+		// Greedy behaviour while matching regexps
+		while (maxl > minl) {
+			MatchResult mres2;
+			mres2 = match(cur, len, at_begin);
+			displayMres(mres2, "Finalize loop", cur);
+			int actual_match_len = mres2.match_len;
+			if (actual_match_len >= max_match.match_len) {
+				// actual_match_len > max_match _can_ happen,
+				// if the search area splits
+				// some following word so that the regex
+				// (e.g. 'r.*r\b' matches 'r' from the middle of the
+				// splitted word)
+				// This means, the len value is too big
+				actual_match_len = max_match.match_len;
+				max_match = mres2;
+				max_match.match_len = actual_match_len;
+				maxl = len;
+				if (maxl - minl < 4)
+					len = (maxl + minl)/2;
+				else
+					len = minl + (maxl - minl + 3)/4;
+			}
+			else {
+				// (actual_match_len < max_match.match_len)
+				minl = len + 1;
+				len = (maxl + minl)/2;
+			}
+		}
+		len = minl;
+		old_cur = cur;
+		// Search for real start of matched characters
+		while (len > 1) {
+			MatchResult actual_match;
+			do {
+				cur.forwardPos();
+			} while (cur.depth() > old_cur.depth()); /* Skip inner insets */
+			if (cur.depth() < old_cur.depth()) {
+				// Outer inset?
+				LYXERR(Debug::INFO, "cur.depth() < old_cur.depth(), this should never happen");
+				break;
+			}
+			if (cur.pos() != old_cur.pos()) {
+				// OK, forwarded 1 pos in actual inset
+				actual_match = match(cur, len-1, at_begin);
+				if (actual_match.match_len == max_match.match_len) {
+					// Ha, got it! The shorter selection has the same match length
+					len--;
+					old_cur = cur;
+					max_match = actual_match;
+				}
+				else {
+					// OK, the shorter selection matches less chars, revert to previous value
+					cur = old_cur;
+					break;
+				}
+			}
+			else {
+				LYXERR(Debug::INFO, "cur.pos() == old_cur.pos(), this should never happen");
+				actual_match = match(cur, len, at_begin);
+				if (actual_match.match_len == max_match.match_len) {
+					old_cur = cur;
+					max_match = actual_match;
+				}
+			}
+		}
+		if (len == 0)
+			return fail;
+		else {
+			max_match.pos_len = len;
+			displayMres(max_match, "SEARCH RESULT", cur)
+					return max_match;
+		}
+	}
 }
 
 /// Finds forward
@@ -4256,7 +4256,7 @@ int findForwardAdv(DocIterator & cur, MatchStringAdv & match)
 		if (repeat)
 			msg = "Repeated";
 		displayMres(mres, msg + " findForwardAdv", cur)
-		int match_len = mres.match_len;
+				int match_len = mres.match_len;
 		if ((mres.pos > 100000) || (mres.match2end > 100000) || (match_len > 100000)) {
 			LYXERR(Debug::INFO, "BIG LENGTHS: " << mres.pos << ", " << match_len << ", " << mres.match2end);
 			match_len = 0;
@@ -4291,7 +4291,7 @@ int findForwardAdv(DocIterator & cur, MatchStringAdv & match)
 				cur.pos() = cur.pos() + increment;
 				MatchResult mres2 = match(cur, -1, false);
 				displayMres(mres2, "findForwardAdv loop", cur)
-				switch (interpretMatch(mres, mres2)) {
+						switch (interpretMatch(mres, mres2)) {
 					case MatchResult::newIsTooFar:
 						// behind the expected match
 						firstInvalid = increment;
@@ -4316,12 +4316,12 @@ int findForwardAdv(DocIterator & cur, MatchStringAdv & match)
 						firstInvalid--;
 						increment = increment*3/4;
 						cur = old_cur;
-					break;
+						break;
 				}
 			}
 			if (mres.match_len > 0) {
 				if (mres.match_prefix + mres.pos - mres.leadsize > 0) {
-					// The match seems to indicate some deeper level 
+					// The match seems to indicate some deeper level
 					repeat = true;
 					orig_cur = cur;
 					orig_mres = mres;
@@ -4439,7 +4439,7 @@ docstring stringifyFromForSearch(FindAndReplaceOptions const & opt,
 				 DocIterator const & cur, int len)
 {
 	if (cur.pos() < 0 || cur.pos() > cur.lastpos())
-	        return docstring();
+		return docstring();
 	if (!opt.ignoreformat)
 		return latexifyFromCursor(cur, len);
 	else
@@ -4448,10 +4448,10 @@ docstring stringifyFromForSearch(FindAndReplaceOptions const & opt,
 
 
 FindAndReplaceOptions::FindAndReplaceOptions(
-	docstring const & _find_buf_name, bool _casesensitive,
-	bool _matchword, bool _forward, bool _expandmacros, bool _ignoreformat,
-	docstring const & _repl_buf_name, bool _keep_case,
-	SearchScope _scope, SearchRestriction _restr, bool _replace_all)
+		docstring const & _find_buf_name, bool _casesensitive,
+		bool _matchword, bool _forward, bool _expandmacros, bool _ignoreformat,
+		docstring const & _repl_buf_name, bool _keep_case,
+		SearchScope _scope, SearchRestriction _restr, bool _replace_all)
 	: find_buf_name(_find_buf_name), casesensitive(_casesensitive), matchword(_matchword),
 	  forward(_forward), expandmacros(_expandmacros), ignoreformat(_ignoreformat),
 	  repl_buf_name(_repl_buf_name), keep_case(_keep_case), scope(_scope), restr(_restr), replace_all(_replace_all)
@@ -4516,30 +4516,30 @@ static void changeFirstCase(Buffer & buffer, TextCase first_case, TextCase other
 
 static bool replaceMatches(string &t, int maxmatchnum, vector <string> const & replacements)
 {
-  // Should replace the string "$" + std::to_string(matchnum) with replacement
-  // if the char '$' is not prefixed with odd number of char '\\'
-  static regex const rematch("(\\\\)*(\\$\\$([0-9]))");
-  string s;
-  size_t lastpos = 0;
-  smatch sub;
-  for (sregex_iterator it(t.begin(), t.end(), rematch), end; it != end; ++it) {
-    sub = *it;
-    if ((sub.position(2) - sub.position(0)) % 2 == 1)
-      continue;
-    int num = stoi(sub.str(3), nullptr, 10);
-    if (num >= maxmatchnum)
-      continue;
-    if (lastpos < (size_t) sub.position(2))
-      s += t.substr(lastpos, sub.position(2) - lastpos);
-    s += replacements[num];
-    lastpos = sub.position(2) + sub.length(2);
-  }
-  if (lastpos == 0)
-    return false;
-  else if (lastpos < t.length())
-    s += t.substr(lastpos, t.length() - lastpos);
-  t = s;
-  return true;
+	// Should replace the string "$" + std::to_string(matchnum) with replacement
+	// if the char '$' is not prefixed with odd number of char '\\'
+	static regex const rematch("(\\\\)*(\\$\\$([0-9]))");
+	string s;
+	size_t lastpos = 0;
+	smatch sub;
+	for (sregex_iterator it(t.begin(), t.end(), rematch), end; it != end; ++it) {
+		sub = *it;
+		if ((sub.position(2) - sub.position(0)) % 2 == 1)
+			continue;
+		int num = stoi(sub.str(3), nullptr, 10);
+		if (num >= maxmatchnum)
+			continue;
+		if (lastpos < (size_t) sub.position(2))
+			s += t.substr(lastpos, sub.position(2) - lastpos);
+		s += replacements[num];
+		lastpos = sub.position(2) + sub.length(2);
+	}
+	if (lastpos == 0)
+		return false;
+	else if (lastpos < t.length())
+		s += t.substr(lastpos, t.length() - lastpos);
+	t = s;
+	return true;
 }
 
 ///
@@ -4547,15 +4547,15 @@ static int findAdvReplace(BufferView * bv, FindAndReplaceOptions const & opt, Ma
 {
 	Cursor & cur = bv->cursor();
 	if (opt.repl_buf_name.empty()
-	    || theBufferList().getBuffer(FileName(to_utf8(opt.repl_buf_name)), true) == 0
-	    || theBufferList().getBuffer(FileName(to_utf8(opt.find_buf_name)), true) == 0)
+			|| theBufferList().getBuffer(FileName(to_utf8(opt.repl_buf_name)), true) == 0
+			|| theBufferList().getBuffer(FileName(to_utf8(opt.find_buf_name)), true) == 0)
 		return 0;
 
 	DocIterator sel_beg = cur.selectionBegin();
 	DocIterator sel_end = cur.selectionEnd();
 	if (&sel_beg.inset() != &sel_end.inset()
-	    || sel_beg.pit() != sel_end.pit()
-	    || sel_beg.idx() != sel_end.idx())
+			|| sel_beg.pit() != sel_end.pit()
+			|| sel_beg.idx() != sel_end.idx())
 		return 0;
 	int sel_len = sel_end.pos() - sel_beg.pos();
 	LYXERR(Debug::FIND, "sel_beg: " << sel_beg << ", sel_end: " << sel_end
@@ -4590,8 +4590,8 @@ static int findAdvReplace(BufferView * bv, FindAndReplaceOptions const & opt, Ma
 	cap::cutSelection(cur, false);
 	if (cur.inTexted()) {
 		repl_buffer.changeLanguage(
-			repl_buffer.language(),
-			cur.getFont().language());
+					repl_buffer.language(),
+					cur.getFont().language());
 		LYXERR(Debug::FIND, "Replacing by pasteParagraphList()ing repl_buffer");
 		LYXERR(Debug::FIND, "Before pasteParagraphList() cur=" << cur << endl);
 		cap::pasteParagraphList(cur, repl_buffer.paragraphs(),
@@ -4672,15 +4672,15 @@ bool findAdv(BufferView * bv, FindAndReplaceOptions & opt)
 		if (num_replaced > 0) {
 			switch (num_replaced)
 			{
-				case 1:
-					bv->message(_("One match has been replaced."));
-					break;
-				case 2:
-					bv->message(_("Two matches have been replaced."));
-					break;
-				default:
-					bv->message(bformat(_("%1$d matches have been replaced."), num_replaced));
-					break;
+			case 1:
+				bv->message(_("One match has been replaced."));
+				break;
+			case 2:
+				bv->message(_("Two matches have been replaced."));
+				break;
+			default:
+				bv->message(bformat(_("%1$d matches have been replaced."), num_replaced));
+				break;
 			}
 			num_replaced = 0;
 		}

commit bbf21502bf38f1435b3727e7b03915b442d2edd5
Author: Juergen Spitzmueller <spitz at lyx.org>
Date:   Mon Apr 4 11:43:55 2022 +0200

    Initialize member

diff --git a/src/lyxfind.cpp b/src/lyxfind.cpp
index 5ceb345..c4b6b96 100644
--- a/src/lyxfind.cpp
+++ b/src/lyxfind.cpp
@@ -1060,7 +1060,7 @@ private:
 	int close_wildcards;
 public:
 	// Are we searching with regular expressions ?
-	bool use_regexp;
+	bool use_regexp = false;
 	static int valid_matches;
 	static vector <string> matches;
 	void FillResults(MatchResult &found_mr);

commit 681334ce20987beae57c55f9a1796b2eefd41944
Author: Kornel Benko <kornel at lyx.org>
Date:   Mon Apr 4 10:46:55 2022 +0200

    FindAdv: Amend 6e7fd68c: Handle InsetNoteParams::Comment too

diff --git a/src/insets/InsetNote.cpp b/src/insets/InsetNote.cpp
index 40194fa..0324ca8 100644
--- a/src/insets/InsetNote.cpp
+++ b/src/insets/InsetNote.cpp
@@ -251,12 +251,16 @@ void InsetNote::latex(otexstream & os, OutputParams const & runparams_in) const
 int InsetNote::plaintext(odocstringstream & os,
 			 OutputParams const & runparams_in, size_t max_length) const
 {
-	if (params_.type == InsetNoteParams::Note
-	    && (runparams_in.for_searchAdv & OutputParams::SearchNonOutput) == 0)
-		return 0;
+	if ((runparams_in.for_searchAdv & OutputParams::SearchNonOutput) == 0) {
+		if (params_.type == InsetNoteParams::Note)
+			return 0;
+		else if (params_.type == InsetNoteParams::Comment
+		    && (runparams_in.for_searchAdv != OutputParams::NoSearch))
+			return 0;
+	}
 
 	OutputParams runparams(runparams_in);
-	if (params_.type == InsetNoteParams::Comment) {
+	if (params_.type != InsetNoteParams::Greyedout) {
 		runparams.inComment = true;
 		// Ignore files that are exported inside a comment
 		runparams.exportdata.reset(new ExportData);

commit 6e7fd68c798a8e5855f7e3a9ab6fd7014995f80d
Author: Kornel Benko <kornel at lyx.org>
Date:   Sun Apr 3 19:03:47 2022 +0200

    FindAdv: Allow to search in LyX-Note also if ignoring format

diff --git a/src/insets/InsetNote.cpp b/src/insets/InsetNote.cpp
index d36b0d6..40194fa 100644
--- a/src/insets/InsetNote.cpp
+++ b/src/insets/InsetNote.cpp
@@ -251,7 +251,8 @@ void InsetNote::latex(otexstream & os, OutputParams const & runparams_in) const
 int InsetNote::plaintext(odocstringstream & os,
 			 OutputParams const & runparams_in, size_t max_length) const
 {
-	if (params_.type == InsetNoteParams::Note)
+	if (params_.type == InsetNoteParams::Note
+	    && (runparams_in.for_searchAdv & OutputParams::SearchNonOutput) == 0)
 		return 0;
 
 	OutputParams runparams(runparams_in);
@@ -260,9 +261,11 @@ int InsetNote::plaintext(odocstringstream & os,
 		// Ignore files that are exported inside a comment
 		runparams.exportdata.reset(new ExportData);
 	}
-	os << '[' << buffer().B_("note") << ":\n";
+	if ((runparams_in.for_searchAdv & OutputParams::SearchNonOutput) == 0)
+		os << '[' << buffer().B_("note") << ":\n";
 	InsetText::plaintext(os, runparams, max_length);
-	os << "\n]";
+	if ((runparams_in.for_searchAdv & OutputParams::SearchNonOutput) == 0)
+		os << "\n]";
 
 	return PLAINTEXT_NEWLINE + 1; // one char on a separate line
 }

commit c559b69fe1d37471b840857baba952482995c97d
Author: Kornel Benko <kornel at lyx.org>
Date:   Sun Apr 3 18:05:15 2022 +0200

    FindAdv: Amend 4125f6a9
    
    Variables regexError and regexError only defined
    when searching via QT-version >= 5

diff --git a/src/lyxfind.cpp b/src/lyxfind.cpp
index bd76966..5ceb345 100644
--- a/src/lyxfind.cpp
+++ b/src/lyxfind.cpp
@@ -3436,12 +3436,12 @@ static bool previous_single_replace = true;
 
 void MatchStringAdv::CreateRegexp(FindAndReplaceOptions const & opt, string regexp_str, string regexp2_str, string par_as_string)
 {
+#if QTSEARCH
 	if (regexp_str.empty() || regexp2_str.empty()) {
 		regexIsValid = false;
 		regexError = "Invalid empty regex";
 		return;
 	}
-#if QTSEARCH
 	// Handle \w properly
 	QRegularExpression::PatternOptions popts = QRegularExpression::UseUnicodePropertiesOption | QRegularExpression::MultilineOption;
 	if (! opt.casesensitive) {

commit 4125f6a9d344674dc2910fe60ddd30c3011e2f86
Author: Kornel Benko <kornel at lyx.org>
Date:   Sun Apr 3 13:21:02 2022 +0200

    FindAdv: Omit possible empty patterns
    
    Normally this is done by the GUI, but searching for e.g. LyX-Comment
    allows empty patterns.

diff --git a/src/lyxfind.cpp b/src/lyxfind.cpp
index be11b16..bd76966 100644
--- a/src/lyxfind.cpp
+++ b/src/lyxfind.cpp
@@ -2740,7 +2740,7 @@ void LatexInfo::buildKeys(bool isPatternString)
   makeKey("trianglerightpar|hexagonpar|starpar",   KeyInfo(KeyInfo::isStandard, 1, true), isPatternString);
   makeKey("triangleuppar|triangledownpar|droppar", KeyInfo(KeyInfo::isStandard, 1, true), isPatternString);
   makeKey("triangleleftpar|shapepar|dropuppar",    KeyInfo(KeyInfo::isStandard, 1, true), isPatternString);
-  makeKey("hphantom|vphantom|footnote|shortcut|include|includegraphics",     KeyInfo(KeyInfo::isStandard, 1, true), isPatternString);
+  makeKey("hphantom|vphantom|note|footnote|shortcut|include|includegraphics",     KeyInfo(KeyInfo::isStandard, 1, true), isPatternString);
   makeKey("parbox", KeyInfo(KeyInfo::doRemove, 1, true), isPatternString);
   // like ('tiny{}' or '\tiny ' ... )
   makeKey("footnotesize|tiny|scriptsize|small|large|Large|LARGE|huge|Huge", KeyInfo(KeyInfo::isSize, 0, false), isPatternString);
@@ -3322,10 +3322,7 @@ string splitOnKnownMacros(string par, bool isPatternString)
       (void) li.process(os, firstKey);
     }
     s = os.str();
-    if (s.empty()) {
-      // return string definitelly impossible to match
-      s = "\\foreignlanguage{ignore}{ }";
-    }
+    // return string definitelly impossible to match, but should be known
   }
   else
     s = par;                            /* no known macros found */
@@ -3439,6 +3436,11 @@ static bool previous_single_replace = true;
 
 void MatchStringAdv::CreateRegexp(FindAndReplaceOptions const & opt, string regexp_str, string regexp2_str, string par_as_string)
 {
+	if (regexp_str.empty() || regexp2_str.empty()) {
+		regexIsValid = false;
+		regexError = "Invalid empty regex";
+		return;
+	}
 #if QTSEARCH
 	// Handle \w properly
 	QRegularExpression::PatternOptions popts = QRegularExpression::UseUnicodePropertiesOption | QRegularExpression::MultilineOption;
@@ -3526,6 +3528,10 @@ MatchStringAdv::MatchStringAdv(lyx::Buffer & buf, FindAndReplaceOptions & opt)
 {
 	Buffer & find_buf = *theBufferList().getBuffer(FileName(to_utf8(opt.find_buf_name)), true);
 	docstring const & ds = stringifySearchBuffer(find_buf, opt);
+	if (ds.empty() ) {
+		CreateRegexp(opt, "", "", "");
+		return;
+	}
 	use_regexp = lyx::to_utf8(ds).find("\\regexp{") != std::string::npos;
 	if (opt.replace_all && previous_single_replace) {
 		previous_single_replace = false;
@@ -3543,6 +3549,10 @@ MatchStringAdv::MatchStringAdv(lyx::Buffer & buf, FindAndReplaceOptions & opt)
 	size_t lead_size = 0;
 	// correct the language settings
 	par_as_string = correctlanguagesetting(par_as_string, true, !opt.ignoreformat, &buf);
+	if (par_as_string.empty()) {
+		CreateRegexp(opt, "", "", "");
+		return;
+	}
 	opt.matchAtStart = false;
 	if (!use_regexp) {
 		identifyClosing(par_as_string); // Removes math closings ($, ], ...) at end of string

commit e7ed8213ac47f52471130687613d5c15e3d0a023
Author: Thibaut Cuvelier <tcuvelier at lyx.org>
Date:   Sun Apr 3 03:41:02 2022 +0200

    DocBook: fix a test to ensure that the DocBook document is valid.
    
    A book cannot directly contain paragraphs, they must be within a chapter.

diff --git a/autotests/export/xhtml/table_borders.lyx b/autotests/export/xhtml/table_borders.lyx
index 7b59f5f..76bfe2c 100644
--- a/autotests/export/xhtml/table_borders.lyx
+++ b/autotests/export/xhtml/table_borders.lyx
@@ -101,6 +101,10 @@
 Check HTML export
 \end_layout
 
+\begin_layout Chapter
+Some borders are bolder than others
+\end_layout
+
 \begin_layout Standard
 \begin_inset Tabular
 <lyxtabular version="3" rows="4" columns="3">

commit 26300c565fd3eeca9ee398b17c2bceedef31b5f5
Author: Thibaut Cuvelier <tcuvelier at lyx.org>
Date:   Sat Apr 2 04:03:12 2022 +0200

    MathML: fix validity for fractions with units.
    
    https://www.lyx.org/trac/ticket/12513
    
    Contributed by lynx.

diff --git a/src/mathed/InsetMathFrac.cpp b/src/mathed/InsetMathFrac.cpp
index e58a787..3ad0dfe 100644
--- a/src/mathed/InsetMathFrac.cpp
+++ b/src/mathed/InsetMathFrac.cpp
@@ -543,17 +543,20 @@ void InsetMathFrac::mathmlize(MathMLStream & ms) const
 		break;
 
 	case UNIT:
-		// FIXME This is not right, because we still output mi, etc,
-		// when we output the cell. So we need to prevent that somehow.
-		if (nargs() == 2)
-			ms << cell(0)
-			   << MTag("mstyle mathvariant='normal'") 
-			   << cell(1) 
-			   << ETag("mstyle");
-		else
-			ms << MTag("mstyle mathvariant='normal'")
-			   << cell(0)
-			   << ETag("mstyle");
+		if (nargs() == 2) {
+			ms << MTag("mrow");
+			ms << cell(0);
+			SetMode textmode(ms, true);
+			ms << MTagInline("mstyle mathvariant='normal'");
+			ms << cell(1);
+			ms << ETagInline("mstyle");
+			ms << ETag("mrow");
+		} else {
+			SetMode textmode(ms, true);
+			ms << MTag("mstyle mathvariant='normal'");
+			ms << cell(0);
+			ms << ETag("mstyle");
+		}
 	}
 }
 

commit 4feb6aaea95670caa5b1292a0f618c2c8777343a
Author: Kornel Benko <kornel at lyx.org>
Date:   Sat Apr 2 17:01:02 2022 +0200

    Make clang happy
    
    Omitting 'error: comparison of integer expressions of different signedness'

diff --git a/src/lyxfind.cpp b/src/lyxfind.cpp
index 53058dd..be11b16 100644
--- a/src/lyxfind.cpp
+++ b/src/lyxfind.cpp
@@ -3863,7 +3863,7 @@ string MatchStringAdv::normalize(docstring const & s, bool ignore_format) const
 		t = t.substr(1);
 	// Remove [%]*\n at end
 	while (!t.empty() && t[t.size() - 1] == '\n') {
-		int count = 1;
+		size_t count = 1;
 		if (!ignore_format) {
 			while ((t.size() > 1 + count) && (t[t.size() - 1 - count] == '%'))
 				count++;
@@ -3892,7 +3892,7 @@ string MatchStringAdv::normalize(docstring const & s, bool ignore_format) const
 				t.replace(pos, 1, " ");
 			}
 			if (!ignore_format) {
-				int count = 0;
+				size_t count = 0;
 				while ((pos > count + 1) && (t[pos - 1 -count] == '%')) {
 					count++;
 				}

commit 0ab862f9425fe8f4fe9f831c8347df56e1d9fc06
Author: Juergen Spitzmueller <spitz at lyx.org>
Date:   Sat Apr 2 12:05:18 2022 +0200

    Amend d96135a9dcc5

diff --git a/src/insets/InsetNote.cpp b/src/insets/InsetNote.cpp
index 05253de..d36b0d6 100644
--- a/src/insets/InsetNote.cpp
+++ b/src/insets/InsetNote.cpp
@@ -207,6 +207,7 @@ bool InsetNote::isMacroScope() const
 void InsetNote::latex(otexstream & os, OutputParams const & runparams_in) const
 {
 	if (params_.type != InsetNoteParams::Greyedout
+	    && runparams_in.for_searchAdv != OutputParams::NoSearch
 	    && (runparams_in.for_searchAdv & OutputParams::SearchNonOutput) == 0)
 		return;
 

commit d96135a9dcc54ab1e6283863f4534ef5530c2faa
Author: Juergen Spitzmueller <spitz at lyx.org>
Date:   Sat Apr 2 11:19:55 2022 +0200

    Amend bcad19e504f845
    
    Allow searching in notes and comments if non-output-content is true

diff --git a/src/insets/InsetNote.cpp b/src/insets/InsetNote.cpp
index adacef3..05253de 100644
--- a/src/insets/InsetNote.cpp
+++ b/src/insets/InsetNote.cpp
@@ -206,9 +206,19 @@ bool InsetNote::isMacroScope() const
 
 void InsetNote::latex(otexstream & os, OutputParams const & runparams_in) const
 {
-	if (params_.type == InsetNoteParams::Note)
+	if (params_.type != InsetNoteParams::Greyedout
+	    && (runparams_in.for_searchAdv & OutputParams::SearchNonOutput) == 0)
 		return;
 
+	if (params_.type == InsetNoteParams::Note) {
+		if ((runparams_in.for_searchAdv & OutputParams::SearchNonOutput) != 0) {
+			OutputParams runparams(runparams_in);
+			InsetCollapsible::latex(os, runparams);
+			runparams_in.encoding = runparams.encoding;
+		}
+		return;
+	}
+
 	OutputParams runparams(runparams_in);
 	if (params_.type == InsetNoteParams::Comment) {
 		runparams.inComment = true;
diff --git a/src/insets/InsetText.cpp b/src/insets/InsetText.cpp
index af1847c..1767f2c 100644
--- a/src/insets/InsetText.cpp
+++ b/src/insets/InsetText.cpp
@@ -485,12 +485,6 @@ void InsetText::latex(otexstream & os, OutputParams const & runparams) const
 	// environment. Standard collapsible insets should not
 	// redefine this, non-standard ones may call this.
 	InsetLayout const & il = getLayout();
-	if (runparams.for_searchAdv != OutputParams::NoSearch &&
-	    (runparams.for_searchAdv & OutputParams::SearchNonOutput) == 0 &&
-	    !il.latexname().empty() &&
-	    il.latextype() == InsetLaTeXType::ENVIRONMENT &&
-	    il.latexname() == "comment")
-		return;
 
 	if (il.forceOwnlines())
 		os << breakln;

commit 50374e38e1ef69aacdddeb771bc7716657338437
Author: Thibaut Cuvelier <tcuvelier at lyx.org>
Date:   Sat Apr 2 03:31:15 2022 +0200

    XHTML/CALS tables: create helper functions to share more code.

diff --git a/src/insets/InsetTabular.cpp b/src/insets/InsetTabular.cpp
index 8251333..749c244 100644
--- a/src/insets/InsetTabular.cpp
+++ b/src/insets/InsetTabular.cpp
@@ -3809,6 +3809,66 @@ docstring Tabular::xmlRow(XMLStream & xs, row_type row, OutputParams const & run
 }
 
 
+void Tabular::xmlHeader(XMLStream & xs, OutputParams const & runparams) const
+{
+	// Output the header of the table. For both HTML and CALS, this is surrounded by a thead.
+	bool const have_first_head = haveLTFirstHead(false);
+	// if we have a first head, then we are going to ignore the
+	// headers for the additional pages, since there aren't any
+	// in HTML or DocBook.
+	bool const have_head = !have_first_head && haveLTHead(false);
+
+	if (have_head || have_first_head) {
+		xs << xml::StartTag("thead") << xml::CR();
+		for (row_type r = 0; r < nrows(); ++r) {
+			if (((have_first_head && row_info[r].endfirsthead) ||
+			     (have_head && row_info[r].endhead)) &&
+			    !row_info[r].caption) {
+				xmlRow(xs, r, runparams, true, false, buffer().params().docbook_table_output);
+			}
+		}
+		xs << xml::EndTag("thead");
+		xs << xml::CR();
+	}
+}
+
+
+void Tabular::xmlFooter(XMLStream & xs, OutputParams const & runparams) const
+{
+	// Output the footer of the table. For both HTML and CALS, this is surrounded by a tfoot and output just after
+	// the header (and before the body).
+	bool const have_last_foot = haveLTLastFoot(false);
+	bool const have_foot = !have_last_foot && haveLTFoot(false);
+
+	if (have_foot || have_last_foot) {
+		xs << xml::StartTag("tfoot") << xml::CR();
+		for (row_type r = 0; r < nrows(); ++r) {
+			if (((have_last_foot && row_info[r].endlastfoot) ||
+			     (have_foot && row_info[r].endfoot)) &&
+			    !row_info[r].caption) {
+				xmlRow(xs, r, runparams, false, false, buffer().params().docbook_table_output);
+			}
+		}
+		xs << xml::EndTag("tfoot");
+		xs << xml::CR();
+	}
+}
+
+
+void Tabular::xmlBody(XMLStream & xs, OutputParams const & runparams) const
+{
+	// Output the main part of the table. The tbody container is mandatory for CALS, but optional for HTML (only if
+	// there is no header and no footer). It never hurts to have it, though.
+	xs << xml::StartTag("tbody");
+	xs << xml::CR();
+	for (row_type r = 0; r < nrows(); ++r)
+		if (isValidRow(r))
+			xmlRow(xs, r, runparams, false, false, buffer().params().docbook_table_output);
+	xs << xml::EndTag("tbody");
+	xs << xml::CR();
+}
+
+
 void Tabular::docbook(XMLStream & xs, OutputParams const & runparams) const
 {
 	// Some tables are inline. Likely limitation: cannot output a table within a table; is that really a limitation?
@@ -3848,52 +3908,9 @@ void Tabular::docbook(XMLStream & xs, OutputParams const & runparams) const
 		}
 	}
 
-	// Output the header of the table. For both HTML and CALS, this is surrounded by a thead.
-	bool const havefirsthead = haveLTFirstHead(false);
-	// if we have a first head, then we are going to ignore the
-	// headers for the additional pages, since there aren't any
-	// in DocBook. this test accomplishes that.
-	bool const havehead = !havefirsthead && haveLTHead(false);
-	if (havehead || havefirsthead) {
-		xs << xml::StartTag("thead") << xml::CR();
-		for (row_type r = 0; r < nrows(); ++r) {
-			if (((havefirsthead && row_info[r].endfirsthead) ||
-			     (havehead && row_info[r].endhead)) &&
-			    !row_info[r].caption) {
-				xmlRow(xs, r, runparams, true, false, buffer().params().docbook_table_output);
-			}
-		}
-		xs << xml::EndTag("thead");
-		xs << xml::CR();
-	}
-
-	// Output the footer of the table. For both HTML and CALS, this is surrounded by a tfoot and output just after
-	// the header (and before the body).
-	bool const havelastfoot = haveLTLastFoot(false);
-	// as before.
-	bool const havefoot = !havelastfoot && haveLTFoot(false);
-	if (havefoot || havelastfoot) {
-		xs << xml::StartTag("tfoot") << xml::CR();
-		for (row_type r = 0; r < nrows(); ++r) {
-			if (((havelastfoot && row_info[r].endlastfoot) ||
-			     (havefoot && row_info[r].endfoot)) &&
-			    !row_info[r].caption) {
-				xmlRow(xs, r, runparams, false, false, buffer().params().docbook_table_output);
-			}
-		}
-		xs << xml::EndTag("tfoot");
-		xs << xml::CR();
-	}
-
-	// Output the main part of the table. The tbody container is mandatory for CALS, but optional for HTML (only if
-	// there is no header and no footer). It never hurts to have it, though.
-	xs << xml::StartTag("tbody");
-	xs << xml::CR();
-	for (row_type r = 0; r < nrows(); ++r)
-		if (isValidRow(r))
-			xmlRow(xs, r, runparams, false, false, buffer().params().docbook_table_output);
-	xs << xml::EndTag("tbody");
-	xs << xml::CR();
+	xmlHeader(xs, runparams);
+	xmlFooter(xs, runparams);
+	xmlBody(xs, runparams);
 
 	// If this method started the table tag, also make it close it.
 	if (!runparams.docbook_in_table) {
@@ -3938,48 +3955,10 @@ docstring Tabular::xhtml(XMLStream & xs, OutputParams const & runparams) const
 	xs << xml::StartTag("table");
 	xs << xml::CR();
 
-	// output header info
-	bool const havefirsthead = haveLTFirstHead(false);
-	// if we have a first head, then we are going to ignore the
-	// headers for the additional pages, since there aren't any
-	// in XHTML. this test accomplishes that.
-	bool const havehead = !havefirsthead && haveLTHead(false);
-	if (havehead || havefirsthead) {
-		xs << xml::StartTag("thead");
-		xs << xml::CR();
-		for (row_type r = 0; r < nrows(); ++r) {
-			if (((havefirsthead && row_info[r].endfirsthead) ||
-			     (havehead && row_info[r].endhead)) &&
-			    !row_info[r].caption) {
-				ret += xmlRow(xs, r, runparams, true);
-			}
-		}
-		xs << xml::EndTag("thead");
-		xs << xml::CR();
-	}
-	// output footer info
-	bool const havelastfoot = haveLTLastFoot(false);
-	// as before.
-	bool const havefoot = !havelastfoot && haveLTFoot(false);
-	if (havefoot || havelastfoot) {
-		xs << xml::StartTag("tfoot") << xml::CR();
-		for (row_type r = 0; r < nrows(); ++r) {
-			if (((havelastfoot && row_info[r].endlastfoot) ||
-			     (havefoot && row_info[r].endfoot)) &&
-			    !row_info[r].caption) {
-				ret += xmlRow(xs, r, runparams);
-			}
-		}
-		xs << xml::EndTag("tfoot");
-		xs << xml::CR();
-	}
+	xmlHeader(xs, runparams);
+	xmlFooter(xs, runparams);
+	xmlBody(xs, runparams);
 
-	xs << xml::StartTag("tbody") << xml::CR();
-	for (row_type r = 0; r < nrows(); ++r)
-		if (isValidRow(r))
-			ret += xmlRow(xs, r, runparams);
-	xs << xml::EndTag("tbody");
-	xs << xml::CR();
 	xs << xml::EndTag("table");
 	xs << xml::CR();
 	if (is_long_tabular) {
diff --git a/src/insets/InsetTabular.h b/src/insets/InsetTabular.h
index 0fbafa8..08b626f 100644
--- a/src/insets/InsetTabular.h
+++ b/src/insets/InsetTabular.h
@@ -957,6 +957,9 @@ public:
 	docstring xmlRow(XMLStream & xs, row_type row, OutputParams const &,
 	                 bool header = false, bool is_xhtml = true,
 					 BufferParams::TableOutput docbook_table_output = BufferParams::TableOutput::HTMLTable) const;
+	void xmlHeader(XMLStream & xs, OutputParams const &) const;
+	void xmlFooter(XMLStream & xs, OutputParams const &) const;
+	void xmlBody(XMLStream & xs, OutputParams const &) const;
 	XmlRowWiseBorders computeXmlBorders(row_type row) const;
 	std::vector<std::string> computeCssStylePerCell(row_type row, col_type col, idx_type cell) const;
 

commit 88f767e4922a0c4cdb39b24d6b6e2a41d1d8dc4a
Author: Thibaut Cuvelier <tcuvelier at lyx.org>
Date:   Sat Apr 2 02:56:32 2022 +0200

    CALS tables: base implementation of row separators on the new code from XHTML.

diff --git a/src/insets/InsetTabular.cpp b/src/insets/InsetTabular.cpp
index 77bb970..8251333 100644
--- a/src/insets/InsetTabular.cpp
+++ b/src/insets/InsetTabular.cpp
@@ -3738,7 +3738,17 @@ docstring Tabular::xmlRow(XMLStream & xs, row_type row, OutputParams const & run
 	Tabular::XmlRowWiseBorders const borders = computeXmlBorders(row);
 	idx_type cell = getFirstCellInRow(row);
 
-	xs << xml::StartTag(row_tag);
+	std::string row_attr;
+	bool cals_row_has_rowsep = false; // TODO: is this required? Is it possible that only a/several cells request a row separator, but not the complete row?
+	// CALS only: all cases where there should be a line *below* this row.
+	if (is_cals_table && (row_info[row].bottom_space_default || bottomLine(cell))) {
+		if (borders.completeBorderBelow) {
+			row_attr = "rowsep='1'";
+			cals_row_has_rowsep = true;
+		}
+	}
+
+	xs << xml::StartTag(row_tag, row_attr);
 	xs << xml::CR();
 	for (col_type c = 0; c < ncols(); ++c, ++cell) {
 		if (isPartOfMultiColumn(row, c) || isPartOfMultiRow(row, c))
@@ -3757,22 +3767,25 @@ docstring Tabular::xmlRow(XMLStream & xs, row_type row, OutputParams const & run
 			attr << "' ";
 		}
 
-		attr << getHAlignAsXmlAttribute(cell, false) << " " << getVAlignAsXmlAttribute(cell);
+		if (is_cals_table) {
+			if (!cals_row_has_rowsep && bottomLine(cell))
+				attr << "rowsep='1' ";
+		}
 
-		attr << getHAlignAsXmlAttribute(cell, false) << " " << getVAlignAsXmlAttribute(cell) << " ";
+		attr << getHAlignAsXmlAttribute(cell, false) << " " << getVAlignAsXmlAttribute(cell);
 
 		if (is_xhtml_table) {
 			if (isMultiColumn(cell))
-				attr << "colspan='" << columnSpan(cell) << "'";
+				attr << " colspan='" << columnSpan(cell) << "'";
 			else if (isMultiRow(cell))
-				attr << "rowspan='" << rowSpan(cell) << "'";
+				attr << " rowspan='" << rowSpan(cell) << "'";
 		} else if (is_cals_table) {
 			if (isMultiColumn(cell))
-				attr << "namest='c" << c << " nameend='c" << (c + columnSpan(cell)) << "'";
+				attr << " namest='c" << c << " nameend='c" << (c + columnSpan(cell)) << "'";
 			else if (isMultiRow(cell))
-				attr << "morerows='" << rowSpan(cell) << "'";
-			else if (!is_xhtml && docbook_table_output == BufferParams::TableOutput::CALSTable)
-				attr << "colname='c" << (c + 1) << "'"; // CALS column numbering starts at 1.
+				attr << " morerows='" << rowSpan(cell) << "'";
+			else
+				attr << " colname='c" << (c + 1) << "'"; // CALS column numbering starts at 1.
 		}
 
 		// Render the cell as either XHTML or DocBook.
@@ -3808,13 +3821,13 @@ void Tabular::docbook(XMLStream & xs, OutputParams const & runparams) const
 	// "Formal" tables have a title and use the tag <table>; the distinction with <informaltable> is done outside.
 	// HTML has the caption first with titles forbidden, and CALS has a title first.
 	if (haveLTCaption()) {
-		std::string tag = ((buffer().params().docbook_table_output) == BufferParams::HTMLTable) ? "caption" : "title";
+		std::string caption_tag = ((buffer().params().docbook_table_output) == BufferParams::HTMLTable) ? "caption" : "title";
 
-		xs << xml::StartTag(tag);
+		xs << xml::StartTag(caption_tag);
 		for (row_type r = 0; r < nrows(); ++r)
 			if (row_info[r].caption)
 				xmlRow(xs, r, runparams, false, false, buffer().params().docbook_table_output);
-		xs << xml::EndTag(tag);
+		xs << xml::EndTag(caption_tag);
 		xs << xml::CR();
 	}
 

commit 8b9c162f515c9666a8a4c5ca26052d710b15d89b
Author: Thibaut Cuvelier <tcuvelier at lyx.org>
Date:   Sat Apr 2 02:54:12 2022 +0200

    CALS tables: fix implementation of multirow/col.

diff --git a/src/insets/InsetTabular.cpp b/src/insets/InsetTabular.cpp
index 478ecf1..77bb970 100644
--- a/src/insets/InsetTabular.cpp
+++ b/src/insets/InsetTabular.cpp
@@ -3731,6 +3731,7 @@ docstring Tabular::xmlRow(XMLStream & xs, row_type row, OutputParams const & run
 {
 	docstring ret;
 	const bool is_xhtml_table = is_xhtml || docbook_table_output == BufferParams::TableOutput::HTMLTable;
+	const bool is_cals_table = !is_xhtml && docbook_table_output == BufferParams::TableOutput::CALSTable;
 
 	std::string const row_tag = is_xhtml_table ? "tr" : "row";
 	std::string const cell_tag = is_xhtml_table ? (header ? "th" : "td") : "entry";
@@ -3758,16 +3759,21 @@ docstring Tabular::xmlRow(XMLStream & xs, row_type row, OutputParams const & run
 
 		attr << getHAlignAsXmlAttribute(cell, false) << " " << getVAlignAsXmlAttribute(cell);
 
-		if (isMultiColumn(cell))
-			attr << " colspan='" << columnSpan(cell) << "'";
-		else if (isMultiRow(cell))
-			attr << " rowspan='" << rowSpan(cell) << "'";
-		else if (!is_xhtml && docbook_table_output == BufferParams::TableOutput::CALSTable)
-			attr << " colname='c" << (c + 1) << "'"; // CALS column numbering starts at 1.
+		attr << getHAlignAsXmlAttribute(cell, false) << " " << getVAlignAsXmlAttribute(cell) << " ";
 
-		// All cases where there should be a line *below* this row.
-		if (!is_xhtml && docbook_table_output == BufferParams::TableOutput::CALSTable && row_info[row].bottom_space_default)
-			attr << " rowsep='1'";
+		if (is_xhtml_table) {
+			if (isMultiColumn(cell))
+				attr << "colspan='" << columnSpan(cell) << "'";
+			else if (isMultiRow(cell))
+				attr << "rowspan='" << rowSpan(cell) << "'";
+		} else if (is_cals_table) {
+			if (isMultiColumn(cell))
+				attr << "namest='c" << c << " nameend='c" << (c + columnSpan(cell)) << "'";
+			else if (isMultiRow(cell))
+				attr << "morerows='" << rowSpan(cell) << "'";
+			else if (!is_xhtml && docbook_table_output == BufferParams::TableOutput::CALSTable)
+				attr << "colname='c" << (c + 1) << "'"; // CALS column numbering starts at 1.
+		}
 
 		// Render the cell as either XHTML or DocBook.
 		xs << xml::StartTag(cell_tag, attr.str(), true);

commit 544adb065b89afa27002dc8b391ee7c907e200ac
Author: Thibaut Cuvelier <tcuvelier at lyx.org>
Date:   Fri Apr 1 21:15:13 2022 +0200

    XHTML tables: fix borders and implement booktabs.
    
    https://www.lyx.org/trac/ticket/10154
    
    Contributed by raccoon.

diff --git a/autotests/export/xhtml/table_borders.lyx b/autotests/export/xhtml/table_borders.lyx
new file mode 100644
index 0000000..7b59f5f
--- /dev/null
+++ b/autotests/export/xhtml/table_borders.lyx
@@ -0,0 +1,235 @@
+#LyX 2.4 created this file. For more info see https://www.lyx.org/
+\lyxformat 609
+\begin_document
+\begin_header
+\save_transient_properties true
+\origin unavailable
+\textclass scrbook
+\begin_preamble
+% Added by lyx2lyx
+\setlength{\parskip}{\medskipamount}
+\setlength{\parindent}{0pt}
+\end_preamble
+\use_default_options true
+\maintain_unincluded_children no
+\language ngerman
+\language_package default
+\inputencoding auto-legacy
+\fontencoding auto
+\font_roman "lmodern" "default"
+\font_sans "lmss" "default"
+\font_typewriter "lmtt" "default"
+\font_math "auto" "auto"
+\font_default_family default
+\use_non_tex_fonts false
+\font_sc false
+\font_roman_osf false
+\font_sans_osf false
+\font_typewriter_osf false
+\font_sf_scale 100 100
+\font_tt_scale 100 100
+\use_microtype false
+\use_dash_ligatures true
+\graphics default
+\default_output_format default
+\output_sync 0
+\bibtex_command default
+\index_command default
+\paperfontsize default
+\spacing single
+\use_hyperref false
+\papersize default
+\use_geometry false
+\use_package amsmath 1
+\use_package amssymb 1
+\use_package cancel 1
+\use_package esint 1
+\use_package mathdots 0
+\use_package mathtools 0
+\use_package mhchem 1
+\use_package stackrel 1
+\use_package stmaryrd 1
+\use_package undertilde 0
+\cite_engine basic
+\cite_engine_type default
+\biblio_style plain
+\use_bibtopic false
+\use_indices false
+\paperorientation portrait
+\suppress_date false
+\justification true
+\use_refstyle 0
+\use_minted 0
+\use_lineno 0
+\branch Test
+\selected 1
+\filename_suffix 0
+\color #e9c792 #16386d
+\end_branch
+\index Stichwortverzeichnis
+\shortcut idx
+\color #008000
+\end_index
+\secnumdepth 3
+\tocdepth 3
+\paragraph_separation indent
+\paragraph_indentation default
+\is_math_indent 0
+\math_numbering_side default
+\quotes_style english
+\dynamic_quotes 0
+\papercolumns 1
+\papersides 1
+\paperpagestyle default
+\tablestyle default
+\tracking_changes false
+\output_changes false
+\change_bars false
+\postpone_fragile_content false
+\html_math_output 0
+\html_css_as_file 0
+\html_be_strict false
+\docbook_table_output 0
+\docbook_mathml_prefix 1
+\html_latex_start <span class='latex'>
+\html_latex_end </span>
+\end_header
+
+\begin_body
+
+\begin_layout Title
+Check HTML export
+\end_layout
+
+\begin_layout Standard
+\begin_inset Tabular
+<lyxtabular version="3" rows="4" columns="3">
+<features tabularvalignment="middle">
+<column alignment="center" valignment="top" width="3cm">
+<column alignment="center" valignment="top">
+<column alignment="center" valignment="top">
+<row>
+<cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+a
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+d
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+s
+\end_layout
+
+\end_inset
+</cell>
+</row>
+<row>
+<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\end_layout
+
+\end_inset
+</cell>
+</row>
+<row>
+<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\end_layout
+
+\end_inset
+</cell>
+</row>
+<row>
+<cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\end_layout
+
+\end_inset
+</cell>
+</row>
+</lyxtabular>
+
+\end_inset
+
+
+\end_layout
+
+\end_body
+\end_document
diff --git a/autotests/export/xhtml/table_borders.xhtml b/autotests/export/xhtml/table_borders.xhtml
new file mode 100644
index 0000000..7e0602e
--- /dev/null
+++ b/autotests/export/xhtml/table_borders.xhtml
@@ -0,0 +1,91 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1 plus MathML 2.0//EN" "http://www.w3.org/Math/DTD/mathml2/xhtml-math11-f.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta name="GENERATOR" content="LyX 2.4.0dev" />
+<meta http-equiv="Content-type" content="text/html;charset=UTF-8" />
+<title>Check HTML export</title>
+<style type='text/css'>
+/* Layout-provided Styles */
+h1.title {
+font-family: sans-serif;
+font-weight: bold;
+font-size: x-large;
+margin-bottom: 1ex;
+text-align: center;
+
+}
+h1.chapter {
+font-family: sans-serif;
+font-weight: bold;
+font-size: x-large;
+margin-top: 2ex;
+margin-bottom: 0.8ex;
+text-align: left;
+
+}
+div.standard {
+	text-indent: 2em;
+	margin-bottom: 2ex;
+}
+div.plain_layout {
+text-align: left;
+
+}
+table {
+	border-collapse: collapse;
+	display: inline-block;
+}
+td {
+	padding: 0.5ex;
+}
+
+
+</style>
+</head>
+<body dir="auto">
+<h1 class="title" id='magicparlabel-1'>Check HTML export</h1>
+<section>
+<h1 class="chapter" id='magicparlabel-2'><span class="chapter_label">1</span> here<a id="sec_ere__dsd" /></h1>
+<div class="standard" id='magicparlabel-3'>see <a href="#sec_ere__dsd">1</a></div>
+
+<div class="standard" id='magicparlabel-4'><table>
+<tbody>
+<tr>
+<td style='width: 3cm; border-bottom: 3.000000px double; border-left: 1px solid; border-top: 1.000000px solid' align='center' valign='top'><div class="plain_layout" id='magicparlabel-26'>a</div>
+</td>
+<td style='border-bottom: 3.000000px double; border-left: 1px solid; border-top: 1.000000px solid' align='center' valign='top'><div class="plain_layout" id='magicparlabel-29'>d</div>
+</td>
+<td style='border-bottom: 3.000000px double; border-right: 1px solid; border-left: 1px solid; border-top: 1.000000px solid' align='center' valign='top'><div class="plain_layout" id='magicparlabel-32'>s</div>
+</td>
+</tr>
+<tr>
+<td style='width: 3cm; border-left: 1px solid; border-top: 1.000000px solid' align='center' valign='top'>
+</td>
+<td style='border-left: 1px solid; border-top: 1.000000px solid' align='center' valign='top'>
+</td>
+<td style='border-right: 1px solid; border-left: 1px solid; border-top: 1.000000px solid' align='center' valign='top'>
+</td>
+</tr>
+<tr>
+<td style='width: 3cm; border-left: 1px solid; border-top: 1.000000px solid' align='center' valign='top'>
+</td>
+<td style='border-left: 1px solid; border-top: 1.000000px solid' align='center' valign='top'>
+</td>
+<td style='border-right: 1px solid; border-left: 1px solid; border-top: 1.000000px solid' align='center' valign='top'>
+</td>
+</tr>
+<tr>
+<td style='width: 3cm; border-bottom: 1.000000px solid; border-left: 1px solid; border-top: 1.000000px solid' align='center' valign='top'>
+</td>
+<td style='border-bottom: 1.000000px solid; border-left: 1px solid; border-top: 1.000000px solid' align='center' valign='top'>
+</td>
+<td style='border-bottom: 1.000000px solid; border-right: 1px solid; border-left: 1px solid; border-top: 1.000000px solid' align='center' valign='top'>
+</td>
+</tr>
+</tbody>
+</table>
+</div>
+</section>
+</body>
+</html>
diff --git a/lib/layouts/stdinsets.inc b/lib/layouts/stdinsets.inc
index 32a0af3..074b274 100644
--- a/lib/layouts/stdinsets.inc
+++ b/lib/layouts/stdinsets.inc
@@ -776,7 +776,6 @@ InsetLayout Tabular
 			display: inline-block;
 		}
 		td {
-			border: 1px solid black;
 			padding: 0.5ex;
 		}
 	EndHTMLStyle
diff --git a/src/insets/InsetTabular.cpp b/src/insets/InsetTabular.cpp
index 0832054..478ecf1 100644
--- a/src/insets/InsetTabular.cpp
+++ b/src/insets/InsetTabular.cpp
@@ -3654,6 +3654,77 @@ std::string Tabular::getHAlignAsXmlAttribute(idx_type cell, bool is_xhtml) const
 	}
 }
 
+Tabular::XmlRowWiseBorders Tabular::computeXmlBorders(row_type row) const
+{
+	Tabular::XmlRowWiseBorders borders;
+
+	// Determine whether borders are required.
+	for (col_type c = 0; c < ncols(); ++c) {
+		if (row < nrows() - 1) {
+			if (!bottomLine(cellIndex(row, c))
+			    || !topLine(cellIndex(row + 1, c))) {
+				borders.completeBorder = false;
+			}
+			if (!bottomLine(cellIndex(row, c))
+			    && !topLine(cellIndex(row + 1, c))) {
+				borders.completeBorderBelow = false;
+			}
+		} else if (row == nrows() - 1 && !bottomLine(cellIndex(row, c))) {
+			borders.completeBorderBelow = false;
+		}
+
+		if ((row > 0 && !bottomLine(cellIndex(row - 1, c)) && !topLine(cellIndex(row, c))) ||
+		    (row == 0 && !topLine(cellIndex(row, c)))) {
+			borders.completeBorderAbove = false;
+		}
+	}
+
+	// Size of booktabs borders.
+	if (use_booktabs) {
+		if (borders.completeBorderAbove)
+			borders.borderTopWidth = row == 0 ? 2 : 1.5;
+		if (borders.completeBorderBelow) {
+			borders.borderBottomWidth = row == nrows() - 1 ? 2 : 1.5;
+			borders.borderBottomWidthComplete = 3 * borders.borderBottomWidth;
+		}
+	}
+
+	return borders;
+}
+
+
+std::vector<std::string> Tabular::computeCssStylePerCell(row_type row, col_type col, idx_type cell) const
+{
+	std::vector<std::string> styles;
+
+	// Fixed width.
+	Length const col_width = column_info[col].p_width;
+	if (!col_width.zero())
+		styles.emplace_back("width: " + col_width.asHTMLString());
+
+	// Borders and booktabs.
+	const Tabular::XmlRowWiseBorders borders = computeXmlBorders(row);
+
+	if (bottomLine(cell)) {
+		if (row < nrows() - 1 && borders.completeBorder)
+			styles.emplace_back("border-bottom: " + to_string(borders.borderBottomWidthComplete) + "px double");
+		else
+			styles.emplace_back("border-bottom: " + to_string(borders.borderBottomWidth) + "px solid");
+	}
+	if (rightLine(cell)) {
+		if (col < ncols() - 1 && leftLine(cell + 1))
+			styles.emplace_back("border-right: 3px double");
+		else
+			styles.emplace_back("border-right: 1px solid");
+	}
+	if (leftLine(cell))
+		styles.emplace_back("border-left: 1px solid");
+	if (topLine(cell))
+		styles.emplace_back("border-top: " + to_string(borders.borderTopWidth) + "px solid");
+
+	return styles;
+}
+
 
 docstring Tabular::xmlRow(XMLStream & xs, row_type row, OutputParams const & runparams,
 	bool header, bool is_xhtml, BufferParams::TableOutput docbook_table_output) const
@@ -3663,22 +3734,26 @@ docstring Tabular::xmlRow(XMLStream & xs, row_type row, OutputParams const & run
 
 	std::string const row_tag = is_xhtml_table ? "tr" : "row";
 	std::string const cell_tag = is_xhtml_table ? (header ? "th" : "td") : "entry";
+	Tabular::XmlRowWiseBorders const borders = computeXmlBorders(row);
 	idx_type cell = getFirstCellInRow(row);
 
 	xs << xml::StartTag(row_tag);
 	xs << xml::CR();
-	for (col_type c = 0; c < ncols(); ++c) {
+	for (col_type c = 0; c < ncols(); ++c, ++cell) {
 		if (isPartOfMultiColumn(row, c) || isPartOfMultiRow(row, c))
 			continue;
 
 		stringstream attr;
 
 		if (is_xhtml_table) {
-			Length const cwidth = column_info[c].p_width;
-			if (!cwidth.zero()) {
-				string const hwidth = cwidth.asHTMLString();
-				attr << "style='width: " << hwidth << ";' ";
-			}
+			const std::vector<std::string> styles = computeCssStylePerCell(row, c, cell);
+			attr << "style='" ;
+	        for (auto it = styles.begin(); it != styles.end(); ++it) {
+				attr << *it;
+				if (it != styles.end() - 1)
+					attr << "; ";
+	        }
+			attr << "' ";
 		}
 
 		attr << getHAlignAsXmlAttribute(cell, false) << " " << getVAlignAsXmlAttribute(cell);
@@ -3707,7 +3782,6 @@ docstring Tabular::xmlRow(XMLStream & xs, row_type row, OutputParams const & run
 		}
 		xs << xml::EndTag(cell_tag);
 		xs << xml::CR();
-		++cell;
 	}
 	xs << xml::EndTag(row_tag);
 	xs << xml::CR();
diff --git a/src/insets/InsetTabular.h b/src/insets/InsetTabular.h
index 8a99ef4..0fbafa8 100644
--- a/src/insets/InsetTabular.h
+++ b/src/insets/InsetTabular.h
@@ -850,6 +850,24 @@ public:
 	///
 	typedef std::vector<ColumnData> column_vector;
 
+private:
+	// Determines the style of borders, per row.
+	class XmlRowWiseBorders {
+	public:
+		// Whether to draw double bottom line.
+		bool completeBorder = true;
+
+		// Whether to draw booktabs' thicker lines.
+		bool completeBorderAbove = true;
+		bool completeBorderBelow = true;
+
+		// Size of the borders.
+		double borderBottomWidth = 1.0;
+		double borderBottomWidthComplete = 3.0;
+		double borderTopWidth = 1.0;
+	};
+
+public:
 	///
 	idx_type numberofcells;
 	///
@@ -939,6 +957,8 @@ public:
 	docstring xmlRow(XMLStream & xs, row_type row, OutputParams const &,
 	                 bool header = false, bool is_xhtml = true,
 					 BufferParams::TableOutput docbook_table_output = BufferParams::TableOutput::HTMLTable) const;
+	XmlRowWiseBorders computeXmlBorders(row_type row) const;
+	std::vector<std::string> computeCssStylePerCell(row_type row, col_type col, idx_type cell) const;
 
 	/// Transforms the vertical alignment of the given cell as a prebaked XML attribute (for HTML and CALS).
 	std::string getHAlignAsXmlAttribute(idx_type cell, bool is_xhtml = true) const;

commit 838157392a8ddfbd3db604bf62f30f6c839d70b3
Author: Thibaut Cuvelier <tcuvelier at lyx.org>
Date:   Fri Apr 1 20:39:02 2022 +0200

    XHTML/DocBook tables: slight refactoring.

diff --git a/src/insets/InsetTabular.cpp b/src/insets/InsetTabular.cpp
index 8c571d6..0832054 100644
--- a/src/insets/InsetTabular.cpp
+++ b/src/insets/InsetTabular.cpp
@@ -3659,9 +3659,10 @@ docstring Tabular::xmlRow(XMLStream & xs, row_type row, OutputParams const & run
 	bool header, bool is_xhtml, BufferParams::TableOutput docbook_table_output) const
 {
 	docstring ret;
+	const bool is_xhtml_table = is_xhtml || docbook_table_output == BufferParams::TableOutput::HTMLTable;
 
-	std::string const row_tag = (is_xhtml || docbook_table_output == BufferParams::TableOutput::HTMLTable) ? "tr" : "row";
-	std::string const cell_tag = (is_xhtml || docbook_table_output == BufferParams::TableOutput::HTMLTable) ? (header ? "th" : "td") : "entry";
+	std::string const row_tag = is_xhtml_table ? "tr" : "row";
+	std::string const cell_tag = is_xhtml_table ? (header ? "th" : "td") : "entry";
 	idx_type cell = getFirstCellInRow(row);
 
 	xs << xml::StartTag(row_tag);
@@ -3672,7 +3673,7 @@ docstring Tabular::xmlRow(XMLStream & xs, row_type row, OutputParams const & run
 
 		stringstream attr;
 
-		if (is_xhtml || docbook_table_output == BufferParams::TableOutput::HTMLTable) {
+		if (is_xhtml_table) {
 			Length const cwidth = column_info[c].p_width;
 			if (!cwidth.zero()) {
 				string const hwidth = cwidth.asHTMLString();

commit 72f630cb8f370f2ab2b600be7c16f49fd8f1f276
Author: Thibaut Cuvelier <tcuvelier at lyx.org>
Date:   Fri Apr 1 04:40:10 2022 +0200

    DocBook: remove unused variable.

diff --git a/src/insets/InsetTabular.cpp b/src/insets/InsetTabular.cpp
index 1124331..8c571d6 100644
--- a/src/insets/InsetTabular.cpp
+++ b/src/insets/InsetTabular.cpp
@@ -3717,8 +3717,6 @@ docstring Tabular::xmlRow(XMLStream & xs, row_type row, OutputParams const & run
 
 void Tabular::docbook(XMLStream & xs, OutputParams const & runparams) const
 {
-	docstring ret;
-
 	// Some tables are inline. Likely limitation: cannot output a table within a table; is that really a limitation?
 	if (!runparams.docbook_in_table) { // Check on the *outer* set of parameters, so that the table can be closed
 		// properly at the end of this function.

commit 5488bebb303f47ba94621dfd1c05d3a54c6db16c
Author: Thibaut Cuvelier <tcuvelier at lyx.org>
Date:   Fri Apr 1 04:37:48 2022 +0200

    XHTML/DocBook: merge code paths to generate a row in a table.

diff --git a/src/insets/InsetTabular.cpp b/src/insets/InsetTabular.cpp
index 0d45855..1124331 100644
--- a/src/insets/InsetTabular.cpp
+++ b/src/insets/InsetTabular.cpp
@@ -3612,13 +3612,6 @@ void Tabular::latex(otexstream & os, OutputParams const & runparams) const
 }
 
 
-void Tabular::docbookRow(XMLStream & xs, row_type row,
-		   OutputParams const & runparams, bool header) const
-{
-	docbookRow(xs, row, runparams, header, buffer().params().docbook_table_output);
-}
-
-
 std::string Tabular::getVAlignAsXmlAttribute(idx_type cell) const
 {
 	switch (getVAlignment(cell)) {
@@ -3662,10 +3655,13 @@ std::string Tabular::getHAlignAsXmlAttribute(idx_type cell, bool is_xhtml) const
 }
 
 
-void Tabular::docbookRow(XMLStream & xs, row_type row, OutputParams const & runparams, bool header, BufferParams::TableOutput docbook_table_output) const
+docstring Tabular::xmlRow(XMLStream & xs, row_type row, OutputParams const & runparams,
+	bool header, bool is_xhtml, BufferParams::TableOutput docbook_table_output) const
 {
-	std::string const row_tag = (docbook_table_output == BufferParams::TableOutput::HTMLTable) ? "tr" : "row";
-	std::string const cell_tag = (docbook_table_output == BufferParams::TableOutput::HTMLTable) ? (header ? "th" : "td") : "entry";
+	docstring ret;
+
+	std::string const row_tag = (is_xhtml || docbook_table_output == BufferParams::TableOutput::HTMLTable) ? "tr" : "row";
+	std::string const cell_tag = (is_xhtml || docbook_table_output == BufferParams::TableOutput::HTMLTable) ? (header ? "th" : "td") : "entry";
 	idx_type cell = getFirstCellInRow(row);
 
 	xs << xml::StartTag(row_tag);
@@ -3676,7 +3672,7 @@ void Tabular::docbookRow(XMLStream & xs, row_type row, OutputParams const & runp
 
 		stringstream attr;
 
-		if (docbook_table_output == BufferParams::TableOutput::HTMLTable) {
+		if (is_xhtml || docbook_table_output == BufferParams::TableOutput::HTMLTable) {
 			Length const cwidth = column_info[c].p_width;
 			if (!cwidth.zero()) {
 				string const hwidth = cwidth.asHTMLString();
@@ -3690,24 +3686,32 @@ void Tabular::docbookRow(XMLStream & xs, row_type row, OutputParams const & runp
 			attr << " colspan='" << columnSpan(cell) << "'";
 		else if (isMultiRow(cell))
 			attr << " rowspan='" << rowSpan(cell) << "'";
-		else if (docbook_table_output == BufferParams::TableOutput::CALSTable)
+		else if (!is_xhtml && docbook_table_output == BufferParams::TableOutput::CALSTable)
 			attr << " colname='c" << (c + 1) << "'"; // CALS column numbering starts at 1.
 
 		// All cases where there should be a line *below* this row.
-		if (docbook_table_output == BufferParams::TableOutput::CALSTable && row_info[row].bottom_space_default)
+		if (!is_xhtml && docbook_table_output == BufferParams::TableOutput::CALSTable && row_info[row].bottom_space_default)
 			attr << " rowsep='1'";
 
-		OutputParams rp = runparams;
-		rp.docbook_in_par = false;
-		rp.docbook_force_pars = true;
+		// Render the cell as either XHTML or DocBook.
 		xs << xml::StartTag(cell_tag, attr.str(), true);
-		cellInset(cell)->docbook(xs, rp);
+		if (is_xhtml) {
+			ret += cellInset(cell)->xhtml(xs, runparams);
+		} else {
+			// DocBook: no return value for this function.
+			OutputParams rp = runparams;
+			rp.docbook_in_par = false;
+			rp.docbook_force_pars = true;
+			cellInset(cell)->docbook(xs, rp);
+		}
 		xs << xml::EndTag(cell_tag);
 		xs << xml::CR();
 		++cell;
 	}
 	xs << xml::EndTag(row_tag);
 	xs << xml::CR();
+
+	return ret;
 }
 
 
@@ -3730,7 +3734,7 @@ void Tabular::docbook(XMLStream & xs, OutputParams const & runparams) const
 		xs << xml::StartTag(tag);
 		for (row_type r = 0; r < nrows(); ++r)
 			if (row_info[r].caption)
-				docbookRow(xs, r, runparams);
+				xmlRow(xs, r, runparams, false, false, buffer().params().docbook_table_output);
 		xs << xml::EndTag(tag);
 		xs << xml::CR();
 	}
@@ -3764,7 +3768,7 @@ void Tabular::docbook(XMLStream & xs, OutputParams const & runparams) const
 			if (((havefirsthead && row_info[r].endfirsthead) ||
 			     (havehead && row_info[r].endhead)) &&
 			    !row_info[r].caption) {
-				docbookRow(xs, r, runparams, true);
+				xmlRow(xs, r, runparams, true, false, buffer().params().docbook_table_output);
 			}
 		}
 		xs << xml::EndTag("thead");
@@ -3782,7 +3786,7 @@ void Tabular::docbook(XMLStream & xs, OutputParams const & runparams) const
 			if (((havelastfoot && row_info[r].endlastfoot) ||
 			     (havefoot && row_info[r].endfoot)) &&
 			    !row_info[r].caption) {
-				docbookRow(xs, r, runparams); // TODO: HTML vs CALS
+				xmlRow(xs, r, runparams, false, false, buffer().params().docbook_table_output);
 			}
 		}
 		xs << xml::EndTag("tfoot");
@@ -3795,7 +3799,7 @@ void Tabular::docbook(XMLStream & xs, OutputParams const & runparams) const
 	xs << xml::CR();
 	for (row_type r = 0; r < nrows(); ++r)
 		if (isValidRow(r))
-			docbookRow(xs, r, runparams);
+			xmlRow(xs, r, runparams, false, false, buffer().params().docbook_table_output);
 	xs << xml::EndTag("tbody");
 	xs << xml::CR();
 
@@ -3807,43 +3811,6 @@ void Tabular::docbook(XMLStream & xs, OutputParams const & runparams) const
 }
 
 
-docstring Tabular::xhtmlRow(XMLStream & xs, row_type row,
-			   OutputParams const & runparams, bool header) const
-{
-	docstring ret;
-	string const celltag = header ? "th" : "td";
-	idx_type cell = getFirstCellInRow(row);
-
-	xs << xml::StartTag("tr");
-	for (col_type c = 0; c < ncols(); ++c) {
-		if (isPartOfMultiColumn(row, c) || isPartOfMultiRow(row, c))
-			continue;
-
-		stringstream attr;
-
-		Length const cwidth = column_info[c].p_width;
-		if (!cwidth.zero()) {
-			string const hwidth = cwidth.asHTMLString();
-			attr << "style=\"width: " << hwidth << ";\" ";
-		}
-
-		attr << getHAlignAsXmlAttribute(cell, true) << " " << getVAlignAsXmlAttribute(cell);
-
-		if (isMultiColumn(cell))
-			attr << " colspan='" << columnSpan(cell) << "'";
-		else if (isMultiRow(cell))
-			attr << " rowspan='" << rowSpan(cell) << "'";
-
-		xs << xml::StartTag(celltag, attr.str(), true) << xml::CR();
-		ret += cellInset(cell)->xhtml(xs, runparams);
-		xs << xml::EndTag(celltag) << xml::CR();
-		++cell;
-	}
-	xs << xml::EndTag("tr");
-	return ret;
-}
-
-
 docstring Tabular::xhtml(XMLStream & xs, OutputParams const & runparams) const
 {
 	docstring ret;
@@ -3870,7 +3837,7 @@ docstring Tabular::xhtml(XMLStream & xs, OutputParams const & runparams) const
 			xs << xml::CR();
 			for (row_type r = 0; r < nrows(); ++r)
 				if (row_info[r].caption)
-					ret += xhtmlRow(xs, r, runparams);
+					ret += xmlRow(xs, r, runparams);
 			xs << xml::EndTag("div");
 			xs << xml::CR();
 		}
@@ -3892,7 +3859,7 @@ docstring Tabular::xhtml(XMLStream & xs, OutputParams const & runparams) const
 			if (((havefirsthead && row_info[r].endfirsthead) ||
 			     (havehead && row_info[r].endhead)) &&
 			    !row_info[r].caption) {
-				ret += xhtmlRow(xs, r, runparams, true);
+				ret += xmlRow(xs, r, runparams, true);
 			}
 		}
 		xs << xml::EndTag("thead");
@@ -3908,7 +3875,7 @@ docstring Tabular::xhtml(XMLStream & xs, OutputParams const & runparams) const
 			if (((havelastfoot && row_info[r].endlastfoot) ||
 			     (havefoot && row_info[r].endfoot)) &&
 			    !row_info[r].caption) {
-				ret += xhtmlRow(xs, r, runparams);
+				ret += xmlRow(xs, r, runparams);
 			}
 		}
 		xs << xml::EndTag("tfoot");
@@ -3918,7 +3885,7 @@ docstring Tabular::xhtml(XMLStream & xs, OutputParams const & runparams) const
 	xs << xml::StartTag("tbody") << xml::CR();
 	for (row_type r = 0; r < nrows(); ++r)
 		if (isValidRow(r))
-			ret += xhtmlRow(xs, r, runparams);
+			ret += xmlRow(xs, r, runparams);
 	xs << xml::EndTag("tbody");
 	xs << xml::CR();
 	xs << xml::EndTag("table");
diff --git a/src/insets/InsetTabular.h b/src/insets/InsetTabular.h
index 217aaa5..8a99ef4 100644
--- a/src/insets/InsetTabular.h
+++ b/src/insets/InsetTabular.h
@@ -935,14 +935,10 @@ public:
 				idx_type cell, row_type row, col_type column,
 				std::vector<unsigned int> const &,
 				bool onlydata, size_t max_length) const;
-	/// auxiliary function for DocBook
-	void docbookRow(XMLStream &, row_type, OutputParams const &,
-					bool header = false) const;
-	void docbookRow(XMLStream &, row_type, OutputParams const &,
-					bool header, BufferParams::TableOutput docbook_table_output) const;
-	///
-	docstring xhtmlRow(XMLStream & xs, row_type, OutputParams const &,
-	                   bool header = false) const;
+	///
+	docstring xmlRow(XMLStream & xs, row_type row, OutputParams const &,
+	                 bool header = false, bool is_xhtml = true,
+					 BufferParams::TableOutput docbook_table_output = BufferParams::TableOutput::HTMLTable) const;
 
 	/// Transforms the vertical alignment of the given cell as a prebaked XML attribute (for HTML and CALS).
 	std::string getHAlignAsXmlAttribute(idx_type cell, bool is_xhtml = true) const;

commit fa5db30d411d4c03cd2bc25de4cecb6d130b3a09
Author: Thibaut Cuvelier <tcuvelier at lyx.org>
Date:   Fri Apr 1 04:37:33 2022 +0200

    Remove debug output.

diff --git a/src/insets/InsetERT.cpp b/src/insets/InsetERT.cpp
index b3e73ff..00f497f 100644
--- a/src/insets/InsetERT.cpp
+++ b/src/insets/InsetERT.cpp
@@ -158,8 +158,6 @@ void InsetERT::docbook(XMLStream & xs, OutputParams const & runparams) const
 			os_trimmed.insert(4, from_ascii("}"));
 		}
 
-		std::cout << to_utf8(os_trimmed) << std::endl;
-
 		// Look into the global table of Unicode characters if there is a match.
 		bool termination;
 		docstring rem;

commit 46c6c40bea6ac75474b712b718b5903a8451bd31
Author: Pavel Sanda <sanda at lyx.org>
Date:   Fri Apr 1 23:05:04 2022 +0200

    * layouttranslations for bg

diff --git a/lib/layouttranslations b/lib/layouttranslations
index a85e72c..5d6d3c1 100644
--- a/lib/layouttranslations
+++ b/lib/layouttranslations
@@ -53,7 +53,7 @@ Translation ar
 End
 
 Translation bg
-	"Acknowledgement" "Признателност"
+	"Acknowledgement" "Благодарност"
 	"Algorithm" "Aлгоритъм"
 	"Assumption" "Допускане"
 	"Axiom" "Аксиома"
@@ -82,7 +82,7 @@ Translation bg
 	"Nomenclature[[output]]" "Речник на означенията"
 	"Notation" "Означение"
 	"Note" "бележка"
-	"Notes[[Endnotes]]" "Notes"
+	"Notes[[Endnotes]]" "Бележки в края"
 	"Problem" "Задача"
 	"Proof" "Доказателство"
 	"Property" "Своиство"

commit d1f8c48d1b27c0590037d3fd715d0ede6df44d4d
Author: Pavel Sanda <sanda at lyx.org>
Date:   Fri Apr 1 22:56:57 2022 +0200

    * bash_completion from Hernan Solari

diff --git a/lib/scripts/bash_completion b/lib/scripts/bash_completion
index 4d7b914..4e08fc0 100644
--- a/lib/scripts/bash_completion
+++ b/lib/scripts/bash_completion
@@ -34,8 +34,14 @@ _lyx()
 	fi
 
 	case "$last" in
-	--export|-e)
-		_filedir '+(pdf[1234]|PDF[1234]|pdf|PDF|ps|PS|xhtml|XHTML)';;
+		# check for export fmt. Short list presented
+	--export|-e|-E|--export-to)
+		COMPREPLY=( $(compgen -W 'latex pdflatex luatex xetex xhtml' -- $cur) );;
+	--import|-i)
+		# check for import format. Short list presented
+		# (-i | --import) requireas a second input _filedir 
+		# must point to *tex | *text | *xhtml depending on choice
+		COMPREPLY=( $(compgen -W 'latex text luatex xetex xhtml' -- $cur) );;
 	-dbg)
 		# check for multiple debug commands
 		if [[ $cur == *,* ]]; then #
@@ -46,6 +52,34 @@ _lyx()
 		fi;;
 	--force-overwrite|-f)
 		COMPREPLY=( $( compgen -W 'all main none' -- $cur ) );;
+
+	latex|xetex|luatex|text|xhtml)
+		# we need to know if previous token was -i or -E
+		if [[ $COMP_CWORD > 2 ]]; then
+			prev=${COMP_WORDS[$(($COMP_CWORD - 2))]}
+		else
+			prev=''
+		fi
+		if (test $prev=="-i")|(test $prev=="-E"); then
+			case $last in
+				text)
+					_filedir '@(txt)' ;;
+				latex|luatex|xetex)
+					_filedir '@(tex)' ;;
+				xhtml)
+					_filedir '@(xhtml)' ;;
+			esac
+		fi;;
+	pdflatex)
+		# we need to know if previous token was -E
+		if [[ $COMP_CWORD > 2 ]]; then
+			prev=${COMP_WORDS[$(($COMP_CWORD - 2))]}
+		else
+			prev=''
+		fi
+		if test $prev == "-E"; then
+					_filedir '@(pdf)' 
+		fi;;
 	*)
           case "$cur" in
           -*)
@@ -58,7 +92,7 @@ _lyx()
 	  
           *)
 		# LyX files
-                _filedir '@(lyx)' 
+		_filedir '@(lyx)' 
           esac
 	esac
 
@@ -66,3 +100,4 @@ _lyx()
 	test $g -eq 0 && shopt -u extglob
 
 } && complete -F _lyx $filenames lyx
+

commit 9804b544e9ab1775f219f1439bbe174b671f5871
Author: Pavel Sanda <sanda at lyx.org>
Date:   Fri Apr 1 22:55:41 2022 +0200

    Add Hernan to credits

diff --git a/lib/generate_contributions.py b/lib/generate_contributions.py
index 86ba4a8..d45db09 100755
--- a/lib/generate_contributions.py
+++ b/lib/generate_contributions.py
@@ -1915,7 +1915,15 @@ contributors = [
                  "m=151306079714476",
                  "12 December 2017",
                  u"Russian localization and documentation, bug reports and fixes, updating of code"),
-     
+
+     contributor(u"Hernán Gustavo Solari",
+                 "hgsolari () gmail ! com",
+                 "GPL",
+                 "Re: Bug#1008257: lyx: bash-completion not working",
+                 "m=164864464510820",
+                 "30 March 2022",
+                 u"bash-completion fixes"),
+
      contributor(u"Giovanni Sora",
                  "g.sora () tiscali ! it",
                  "GPL",

commit bcad19e504f845f8fe08d4d62b46e0fdbc67145e
Author: Kornel Benko <kornel at lyx.org>
Date:   Fri Apr 1 20:14:47 2022 +0200

    FindAdv: Handle latex-output for comment-environment
    
    Disable if in search-adv modus and not searching in not-printed contents,
    enable otherwise

diff --git a/src/insets/InsetText.cpp b/src/insets/InsetText.cpp
index a452184..af1847c 100644
--- a/src/insets/InsetText.cpp
+++ b/src/insets/InsetText.cpp
@@ -485,6 +485,13 @@ void InsetText::latex(otexstream & os, OutputParams const & runparams) const
 	// environment. Standard collapsible insets should not
 	// redefine this, non-standard ones may call this.
 	InsetLayout const & il = getLayout();
+	if (runparams.for_searchAdv != OutputParams::NoSearch &&
+	    (runparams.for_searchAdv & OutputParams::SearchNonOutput) == 0 &&
+	    !il.latexname().empty() &&
+	    il.latextype() == InsetLaTeXType::ENVIRONMENT &&
+	    il.latexname() == "comment")
+		return;
+
 	if (il.forceOwnlines())
 		os << breakln;
 	bool needendgroup = false;

commit 83e65161a8a12be72aa6ba5b5037e378b2730051
Author: Kornel Benko <kornel at lyx.org>
Date:   Fri Apr 1 13:45:57 2022 +0200

    FindAdv: Ignore comment-feature (but not its content)
    
    TODO: Handle 'comment' like other features, but this needs more thinking.

diff --git a/src/lyxfind.cpp b/src/lyxfind.cpp
index 61749d4..53058dd 100644
--- a/src/lyxfind.cpp
+++ b/src/lyxfind.cpp
@@ -1037,7 +1037,7 @@ private:
 	 ** @todo Normalization should also expand macros, if the corresponding
 	 ** search option was checked.
 	 **/
-	string normalize(docstring const & s) const;
+	string normalize(docstring const & s, bool ignore_fomat) const;
 	// normalized string to search
 	string par_as_string;
 	// regular expression to use for searching
@@ -3029,7 +3029,7 @@ int LatexInfo::dispatch(ostringstream &os, int previousStart, KeyInfo &actual)
       // Remove the key with all parameters and following spaces
       size_t pos;
       size_t start;
-      if (interval_.par[actual._dataEnd-1] == ' ')
+      if (interval_.par[actual._dataEnd-1] == ' ' || interval_.par[actual._dataEnd-1] == '}')
         start = actual._dataEnd;
       else
         start = actual._dataEnd+1;
@@ -3536,7 +3536,7 @@ MatchStringAdv::MatchStringAdv(lyx::Buffer & buf, FindAndReplaceOptions & opt)
 		previous_single_replace = true;
 	}
 	// When using regexp, braces are hacked already by escape_for_regex()
-	par_as_string = normalize(ds);
+	par_as_string = normalize(ds, opt.ignoreformat);
 	open_braces = 0;
 	close_wildcards = 0;
 
@@ -3660,7 +3660,7 @@ MatchResult MatchStringAdv::findAux(DocIterator const & cur, int len, bool at_be
 
 	docstring docstr = stringifyFromForSearch(opt, cur, len);
 	string str;
-	str = normalize(docstr);
+	str = normalize(docstr, opt.ignoreformat);
 	if (!opt.ignoreformat) {
 		str = correctlanguagesetting(str, false, !opt.ignoreformat);
 		// remove closing '}' and '\n' to allow for use of '$' in regex
@@ -3854,16 +3854,22 @@ static bool simple_replace(string &t, string from, string to)
 }
 #endif
 
-string MatchStringAdv::normalize(docstring const & s) const
+string MatchStringAdv::normalize(docstring const & s, bool ignore_format) const
 {
 	string t;
 	t = lyx::to_utf8(s);
 	// Remove \n at begin
 	while (!t.empty() && t[0] == '\n')
 		t = t.substr(1);
-	// Remove \n at end
-	while (!t.empty() && t[t.size() - 1] == '\n')
-		t = t.substr(0, t.size() - 1);
+	// Remove [%]*\n at end
+	while (!t.empty() && t[t.size() - 1] == '\n') {
+		int count = 1;
+		if (!ignore_format) {
+			while ((t.size() > 1 + count) && (t[t.size() - 1 - count] == '%'))
+				count++;
+		}
+		t = t.substr(0, t.size() - count);
+	}
 	size_t pos;
 	// Handle all other '\n'
 	while ((pos = t.find("\n")) != string::npos) {
@@ -3876,13 +3882,24 @@ string MatchStringAdv::normalize(docstring const & s) const
 				t.replace(pos-2, 3, "");
 			}
 		}
-		else if (!isAlnumASCII(t[pos+1]) || !isAlnumASCII(t[pos-1])) {
-			// '\n' adjacent to non-alpha-numerics, discard
-			t.replace(pos, 1, "");
-		}
 		else {
-			// Replace all other \n with spaces
-			t.replace(pos, 1, " ");
+			if (!isAlnumASCII(t[pos+1]) || !isAlnumASCII(t[pos-1])) {
+				// '\n' adjacent to non-alpha-numerics, discard
+				t.replace(pos, 1, "");
+			}
+			else {
+				// Replace all other \n with spaces
+				t.replace(pos, 1, " ");
+			}
+			if (!ignore_format) {
+				int count = 0;
+				while ((pos > count + 1) && (t[pos - 1 -count] == '%')) {
+					count++;
+				}
+				if (count > 0) {
+					t.replace(pos - count, count, "");
+				}
+			}
 		}
 	}
 	// Remove stale empty \emph{}, \textbf{} and similar blocks from latexify

commit 1aa449785e075425dec69c7887e1c42d5ebccd36
Author: Juergen Spitzmueller <spitz at lyx.org>
Date:   Fri Apr 1 11:34:26 2022 +0200

    Indentation

diff --git a/src/lyxfind.cpp b/src/lyxfind.cpp
index 35fdd68..61749d4 100644
--- a/src/lyxfind.cpp
+++ b/src/lyxfind.cpp
@@ -192,7 +192,7 @@ IgnoreFormats ignoreFormats;
 
 void setIgnoreFormat(string const & type, bool value, bool fromUser)
 {
-  ignoreFormats.setIgnoreFormat(type, value, fromUser);
+	ignoreFormats.setIgnoreFormat(type, value, fromUser);
 }
 
 

commit 898007fecdb0d9d4119b9548fa62f2ec783f51e8
Author: Juergen Spitzmueller <spitz at lyx.org>
Date:   Fri Apr 1 09:27:55 2022 +0200

    bg.po: update from Veselin

diff --git a/po/bg.po b/po/bg.po
index 85af081..8a470b3 100644
--- a/po/bg.po
+++ b/po/bg.po
@@ -6,7 +6,7 @@ msgid ""
 msgstr ""
 "Project-Id-Version: LyX 2.3.x\n"
 "Report-Msgid-Bugs-To: lyx-devel at lists.lyx.org\n"
-"POT-Creation-Date: 2021-03-05 15:06-0500\n"
+"POT-Creation-Date: 2022-02-16 12:05+0200\n"
 "PO-Revision-Date: 2019-04-23 13:49+0300\n"
 "Last-Translator: V. Jeliazkov <vveesskkoo at google.com>\n"
 "Language-Team: Bulgarian <lyx-docs at lists.lyx.org>\n"
@@ -23,33 +23,30 @@ msgstr "Версия"
 
 # src/lyxfunc.C:1132
 #: src/frontends/qt/ui/AboutUi.ui:150
-#, fuzzy
 msgid "Library directory"
-msgstr "Директория за библиотеките: "
+msgstr "Директория с библиотеките"
 
 #: src/frontends/qt/ui/AboutUi.ui:162
 msgid "Open library directory in file browser"
-msgstr ""
+msgstr "Отваряне на директорията с библиотеките"
 
 #: src/frontends/qt/ui/AboutUi.ui:165
 msgid "[[do]]&Open"
-msgstr ""
+msgstr "&Отваряне"
 
 # src/lyxfunc.C:1132
 #: src/frontends/qt/ui/AboutUi.ui:200
-#, fuzzy
 msgid "User directory"
-msgstr "Потребителска директория: "
+msgstr "Директория на потребителя"
 
 #: src/frontends/qt/ui/AboutUi.ui:231
 msgid "Open user directory in file browser"
-msgstr ""
+msgstr "Отваряне на директорията с файлов мениджър"
 
 # src/LyXAction.C:144
 #: src/frontends/qt/ui/AboutUi.ui:234
-#, fuzzy
 msgid "[[do]]O&pen"
-msgstr "&Разширен"
+msgstr "О&тваряне"
 
 # src/credits.C:72
 #: src/frontends/qt/ui/AboutUi.ui:263
@@ -65,7 +62,7 @@ msgstr "Авторски права"
 # src/ext_l10n.h:131
 #: src/frontends/qt/ui/AboutUi.ui:313
 msgid "Build Info"
-msgstr "Настройки при компилиране"
+msgstr "Компилиране"
 
 # src/LColor.C:97
 #: src/frontends/qt/ui/AboutUi.ui:338
@@ -74,23 +71,21 @@ msgstr "Бележки към изданието"
 
 #: src/frontends/qt/ui/AboutUi.ui:383
 msgid "Copy version information to clipboard"
-msgstr ""
+msgstr "Копиране на информацията за версията в буфера"
 
 # src/LyXAction.C:303
 #: src/frontends/qt/ui/AboutUi.ui:386
-#, fuzzy
 msgid "Copy &Version Info"
-msgstr "Вмъкни бел. в поле"
+msgstr "Копиране на версията"
 
 # src/ext_l10n.h:186
 #: src/frontends/qt/ui/BibitemUi.ui:26 src/frontends/qt/ui/BibitemUi.ui:45
-#, fuzzy
 msgid "The bibliography key"
-msgstr "Библиография"
+msgstr "Библиографски ключ"
 
 #: src/frontends/qt/ui/BibitemUi.ui:29
 msgid "Ke&y:"
-msgstr "&Ключ"
+msgstr "&Ключ:"
 
 # src/frontends/xforms/FormPreferences.C:1278
 #: src/frontends/qt/ui/BibitemUi.ui:52 src/frontends/qt/ui/BibitemUi.ui:76
@@ -108,19 +103,17 @@ msgstr "Eтикет:"
 
 # src/lyx_gui_misc.C:430
 #: src/frontends/qt/ui/BibitemUi.ui:83
-#, fuzzy
 msgid "&Year:"
-msgstr "годена"
+msgstr "&Година"
 
 #: src/frontends/qt/ui/BibitemUi.ui:96
 msgid "The year with \"Author (Year)\" citations (without parentheses)."
-msgstr ""
+msgstr "Цитати с годината „Автор (година)“ без скоби."
 
 # src/ext_l10n.h:175
 #: src/frontends/qt/ui/BibitemUi.ui:105 src/frontends/qt/GuiBibitem.cpp:64
-#, fuzzy
 msgid "A&ll Author Names:"
-msgstr "Автор"
+msgstr "Пълно име на автора:"
 
 #: src/frontends/qt/ui/BibitemUi.ui:115
 msgid ""
@@ -128,6 +121,9 @@ msgid ""
 "full list for author-year citation, you can put the full list here and the "
 "abbreviated list above."
 msgstr ""
+"Ако желаете да използвате съкратен списък с автори с „и др.“ накрая, както и "
+"пълен списък с цитати автор-година можете да поставите пълния списък тук, а "
+"съкратения отгоре."
 
 #: src/frontends/qt/ui/BibitemUi.ui:122 src/frontends/qt/GuiBibitem.cpp:93
 msgid ""
@@ -173,8 +169,8 @@ msgid "Provides available cite style variants."
 msgstr "Осигуряване на наличните стилове за цитирания."
 
 # src/form1.C:129 src/sp_form.C:58
-#: src/frontends/qt/ui/BiblioUi.ui:118 src/frontends/qt/GuiPrefs.cpp:729
-#: src/frontends/qt/GuiPrefs.cpp:858
+#: src/frontends/qt/ui/BiblioUi.ui:118 src/frontends/qt/GuiPrefs.cpp:733
+#: src/frontends/qt/GuiPrefs.cpp:862
 msgid "Opt&ions:"
 msgstr "&опции: "
 
@@ -308,8 +304,8 @@ msgstr "Избиране на програма за съставяне на ли
 
 # src/form1.C:129 src/sp_form.C:58
 #: src/frontends/qt/ui/BiblioUi.ui:424 src/frontends/qt/ui/PrefLatexUi.ui:103
-#: src/frontends/qt/ui/PrefLatexUi.ui:205 src/frontends/qt/GuiPrefs.cpp:754
-#: src/frontends/qt/GuiPrefs.cpp:885
+#: src/frontends/qt/ui/PrefLatexUi.ui:205 src/frontends/qt/GuiPrefs.cpp:758
+#: src/frontends/qt/GuiPrefs.cpp:889
 msgid "Op&tions:"
 msgstr "Опции:"
 
@@ -317,6 +313,7 @@ msgstr "Опции:"
 msgid ""
 "Define options such as --min-crossrefs (see the documentation of BibTeX)"
 msgstr ""
+"Дефиниране на опции като --min-crossrefs (виж документацията на BibTeX)"
 
 # src/insets/insetbib.C:339
 #: src/frontends/qt/ui/BibtexUi.ui:23
@@ -365,9 +362,8 @@ msgstr "&Премахване"
 
 # src/frontends/gnome/FormCitation.C:560
 #: src/frontends/qt/ui/BibtexUi.ui:107
-#, fuzzy
 msgid "Move the selected database up (Ctrl-Up)"
-msgstr "Преместване избрания файл нагоре (Ctrl-горна стрелка)"
+msgstr "Преместване избраната база дании нагоре (Ctrl-горна стрелка)"
 
 # src/frontends/kde/refdlg.C:81 src/frontends/kde/tocdlg.C:43
 #: src/frontends/qt/ui/BibtexUi.ui:110 src/frontends/qt/ui/CitationUi.ui:191
@@ -377,9 +373,8 @@ msgstr "Преместване на&горе"
 
 # src/frontends/gnome/FormCitation.C:560
 #: src/frontends/qt/ui/BibtexUi.ui:130
-#, fuzzy
 msgid "Move the selected database down (Ctrl-Down)"
-msgstr "Преместване на избрания файл надолу (Ctrl-долна стрелка)"
+msgstr "Преместване на избраната база дании надолу (Ctrl-долна стрелка)"
 
 # src/ext_l10n.h:398
 #: src/frontends/qt/ui/BibtexUi.ui:133 src/frontends/qt/ui/CitationUi.ui:214
@@ -389,13 +384,11 @@ msgstr "Преместване на&долу"
 
 # src/ext_l10n.h:94
 #: src/frontends/qt/ui/BibtexUi.ui:160
-#, fuzzy
 msgid "Edit selected database externally"
-msgstr "Външен материал(x)...|x"
+msgstr "Редактиране на базата данни с външна програма"
 
 # src/MenuBackend.C:444 src/ext_l10n.h:2 src/ext_l10n.h:5
 #: src/frontends/qt/ui/BibtexUi.ui:163
-#, fuzzy
 msgid "&Edit..."
 msgstr "&Редактиране"
 
@@ -450,9 +443,9 @@ msgid "Add L&ocal..."
 msgstr "Добавяне на друг"
 
 # src/form1.C:129 src/sp_form.C:58
-#: src/frontends/qt/ui/BibtexUi.ui:304 lib/layouts/beamer.layout:518
-#: lib/layouts/beamer.layout:547 lib/layouts/beamer.layout:558
-#: lib/layouts/beamer.layout:586 lib/layouts/beamer.layout:689
+#: src/frontends/qt/ui/BibtexUi.ui:304 lib/layouts/beamer.layout:520
+#: lib/layouts/beamer.layout:549 lib/layouts/beamer.layout:560
+#: lib/layouts/beamer.layout:588 lib/layouts/beamer.layout:691
 #: lib/layouts/chessboard.module:31 lib/layouts/chessboard.module:61
 #: lib/layouts/chessboard.module:139 lib/layouts/fixme.module:68
 #: lib/layouts/fixme.module:103 lib/layouts/fixme.module:146
@@ -505,9 +498,8 @@ msgstr "Добавяне на лит. списък към съдържаниет
 
 # src/ext_l10n.h:215
 #: src/frontends/qt/ui/BibtexUi.ui:383
-#, fuzzy
 msgid "Custo&m:"
-msgstr "потребителско"
+msgstr "От потребителя:"
 
 #: src/frontends/qt/ui/BibtexUi.ui:393
 msgid ""
@@ -568,9 +560,9 @@ msgstr "Избиране тип на вътрешното оформление"
 #: src/frontends/qt/ui/ListingsUi.ui:105 src/frontends/qt/ui/TabularUi.ui:1200
 #: src/frontends/qt/ui/TabularUi.ui:1219 src/frontends/qt/ui/TabularUi.ui:1267
 #: src/frontends/qt/GuiBox.cpp:420 src/frontends/qt/GuiBox.cpp:630
-#: src/frontends/qt/GuiDocument.cpp:124 src/frontends/qt/GuiGraphics.cpp:576
-#: src/frontends/qt/GuiMathMatrix.cpp:33 src/frontends/qt/GuiPrefs.cpp:2285
-#: src/frontends/qt/GuiPrefs.cpp:2308
+#: src/frontends/qt/GuiDocument.cpp:124 src/frontends/qt/GuiGraphics.cpp:582
+#: src/frontends/qt/GuiMathMatrix.cpp:33 src/frontends/qt/GuiPrefs.cpp:2327
+#: src/frontends/qt/GuiPrefs.cpp:2350
 msgid "None"
 msgstr "няма"
 
@@ -647,17 +639,17 @@ msgstr "&Рамка:"
 # src/frontends/kde/dlg/paraextradlgdata.C:142
 #: src/frontends/qt/ui/BoxUi.ui:204 src/frontends/qt/ui/BoxUi.ui:234
 #: src/frontends/qt/ui/TabularUi.ui:213 src/frontends/qt/ui/TabularUi.ui:404
-#: lib/ui/stdcontext.inc:462 src/frontends/qt/GuiMathMatrix.cpp:54
+#: lib/ui/stdcontext.inc:482 src/frontends/qt/GuiMathMatrix.cpp:54
 msgid "Top"
 msgstr "отгоре"
 
 # src/frontends/kde/dlg/paraextradlgdata.C:155
 #: src/frontends/qt/ui/BoxUi.ui:209 src/frontends/qt/ui/BoxUi.ui:239
 #: src/frontends/qt/ui/TabularUi.ui:218 src/frontends/qt/ui/TabularUi.ui:409
-#: lib/ui/stdcontext.inc:463 src/frontends/qt/GuiMathMatrix.cpp:55
-#: src/frontends/qt/GuiTabular.cpp:250
+#: lib/ui/stdcontext.inc:483 src/frontends/qt/GuiMathMatrix.cpp:55
+#: src/frontends/qt/GuiTabular.cpp:256
 msgid "Middle"
-msgstr "центриране"
+msgstr "център"
 
 # src/frontends/kde/dlg/paraextradlgdata.C:168
 #: src/frontends/qt/ui/BoxUi.ui:214 src/frontends/qt/ui/BoxUi.ui:244
@@ -677,7 +669,7 @@ msgstr "центриране"
 #: lib/layouts/g-brief2.layout:593 lib/layouts/g-brief2.layout:613
 #: lib/layouts/g-brief2.layout:634 lib/layouts/g-brief2.layout:654
 #: lib/layouts/g-brief2.layout:674 lib/layouts/g-brief2.layout:694
-#: lib/layouts/g-brief2.layout:714 lib/ui/stdcontext.inc:464
+#: lib/layouts/g-brief2.layout:714 lib/ui/stdcontext.inc:484
 #: src/frontends/qt/GuiMathMatrix.cpp:56
 msgid "Bottom"
 msgstr "отдолу"
@@ -691,35 +683,35 @@ msgstr "запълване"
 # src/frontends/kde/dlg/parageneraldlgdata.C:120
 #: src/frontends/qt/ui/BoxUi.ui:265 src/frontends/qt/ui/ListingsUi.ui:110
 #: src/frontends/qt/ui/TabularUi.ui:344 src/frontends/qt/ui/TabularUi.ui:1553
-#: src/frontends/qt/ui/WrapUi.ui:47 src/frontends/qt/GuiDocument.cpp:1542
-#: src/frontends/qt/GuiParagraph.cpp:115 src/frontends/qt/GuiTabular.cpp:1036
+#: src/frontends/qt/ui/WrapUi.ui:47 src/frontends/qt/GuiDocument.cpp:1554
+#: src/frontends/qt/GuiParagraph.cpp:115 src/frontends/qt/GuiTabular.cpp:1042
 msgid "Left"
 msgstr "ляво"
 
 # src/frontends/kde/dlg/parageneraldlgdata.C:107
 #: src/frontends/qt/ui/BoxUi.ui:270 src/frontends/qt/ui/TabularUi.ui:349
 #: src/frontends/qt/GuiExternal.cpp:78 src/frontends/qt/GuiGraphics.cpp:73
-#: src/frontends/qt/GuiParagraph.cpp:117 src/frontends/qt/GuiTabular.cpp:1037
+#: src/frontends/qt/GuiParagraph.cpp:117 src/frontends/qt/GuiTabular.cpp:1043
 msgid "Center"
-msgstr "центриране"
+msgstr "център"
 
 # src/frontends/kde/dlg/parageneraldlgdata.C:133
 #: src/frontends/qt/ui/BoxUi.ui:275 src/frontends/qt/ui/ListingsUi.ui:115
 #: src/frontends/qt/ui/TabularUi.ui:354 src/frontends/qt/ui/WrapUi.ui:52
-#: src/frontends/qt/GuiDocument.cpp:1544 src/frontends/qt/GuiParagraph.cpp:116
-#: src/frontends/qt/GuiTabular.cpp:1038
+#: src/frontends/qt/GuiDocument.cpp:1556 src/frontends/qt/GuiParagraph.cpp:116
+#: src/frontends/qt/GuiTabular.cpp:1044
 msgid "Right"
 msgstr "дясно"
 
 # src/ext_l10n.h:219
 #: src/frontends/qt/ui/BoxUi.ui:299 src/frontends/qt/ui/CharacterUi.ui:145
 msgid "Decoration"
-msgstr "Украса"
+msgstr "Мат. знаци"
 
 # src/ext_l10n.h:219
 #: src/frontends/qt/ui/BoxUi.ui:308
 msgid "Decoration box types"
-msgstr "Видове украса на рамките"
+msgstr "Знаци за мат. изрази"
 
 # src/frontends/kde/parageneraldlg.C:40 src/frontends/kde/parageneraldlg.C:47
 #: src/frontends/qt/ui/BoxUi.ui:318
@@ -743,7 +735,7 @@ msgstr "Отстояние "
 # src/ext_l10n.h:219
 #: src/frontends/qt/ui/BoxUi.ui:358
 msgid "&Decoration:"
-msgstr "&Украса"
+msgstr "&Форма"
 
 # src/frontends/xforms/form_document.C:262
 #: src/frontends/qt/ui/BoxUi.ui:368
@@ -785,9 +777,8 @@ msgstr "Изберете подходящото разклонение"
 # src/frontends/xforms/FormPreferences.C:226
 # src/frontends/xforms/FormPreferences.C:255
 #: src/frontends/qt/ui/BranchUi.ui:37
-#, fuzzy
 msgid "Inverted"
-msgstr "Конвертори"
+msgstr "обърнато"
 
 #: src/frontends/qt/ui/BranchesUi.ui:35
 msgid ""
@@ -814,7 +805,7 @@ msgstr "Изтриване на избраното разклонение."
 
 # src/frontends/kde/dlg/paradlgdata.C:82
 #: src/frontends/qt/ui/BranchesUi.ui:74 src/frontends/qt/ui/IndicesUi.ui:165
-#: src/Buffer.cpp:4722 src/Buffer.cpp:4735
+#: src/Buffer.cpp:4733 src/Buffer.cpp:4746
 msgid "&Remove"
 msgstr "&Премахване"
 
@@ -871,14 +862,13 @@ msgstr "&Ново"
 
 #: src/frontends/qt/ui/BranchesUi.ui:169
 msgid "Reset branch color to default (standard background)"
-msgstr ""
+msgstr "Задавене цвят на разклонението по подразбиране (стандартен фон)"
 
 # src/frontends/xforms/form_preferences.C:600
 # src/frontends/xforms/form_preferences.C:687
 #: src/frontends/qt/ui/BranchesUi.ui:172
-#, fuzzy
 msgid "R&eset Color"
-msgstr "Презареждане"
+msgstr "&Цветове по подразбиране"
 
 # src/frontends/gnome/FormCitation.C:560
 #: src/frontends/qt/ui/BranchesUnknownUi.ui:25
@@ -905,18 +895,18 @@ msgstr "Добавяне на всички"
 # src/frontends/kde/dlg/printdlgdata.C:133
 # src/frontends/kde/dlg/tabcreatedlgdata.C:60 src/frontends/kde/indexdlg.C:65
 # src/frontends/kde/refdlg.C:92 src/frontends/kde/urldlg.C:58
-#: src/frontends/qt/ui/BranchesUnknownUi.ui:58 src/Buffer.cpp:1457
-#: src/Buffer.cpp:4696 src/Buffer.cpp:4790 src/LyXVC.cpp:114 src/LyXVC.cpp:310
+#: src/frontends/qt/ui/BranchesUnknownUi.ui:58 src/Buffer.cpp:1458
+#: src/Buffer.cpp:4707 src/Buffer.cpp:4817 src/LyXVC.cpp:114 src/LyXVC.cpp:310
 #: src/buffer_funcs.cpp:56 src/frontends/qt/GuiBranches.cpp:226
-#: src/frontends/qt/GuiClipboard.cpp:252 src/frontends/qt/GuiDocument.cpp:2834
-#: src/frontends/qt/GuiParagraph.cpp:177 src/frontends/qt/GuiPrefs.cpp:3365
-#: src/frontends/qt/GuiView.cpp:2683 src/frontends/qt/GuiView.cpp:2915
-#: src/frontends/qt/GuiView.cpp:2939 src/frontends/qt/GuiView.cpp:2953
-#: src/frontends/qt/GuiView.cpp:3055 src/frontends/qt/GuiView.cpp:3100
-#: src/frontends/qt/GuiView.cpp:3155 src/frontends/qt/GuiView.cpp:3389
-#: src/frontends/qt/GuiView.cpp:3403 src/frontends/qt/GuiView.cpp:3505
-#: src/frontends/qt/GuiView.cpp:3530 src/frontends/qt/GuiView.cpp:4234
-#: src/frontends/qt/GuiView.cpp:4241 src/insets/InsetBibtex.cpp:153
+#: src/frontends/qt/GuiClipboard.cpp:252 src/frontends/qt/GuiDocument.cpp:2852
+#: src/frontends/qt/GuiParagraph.cpp:177 src/frontends/qt/GuiPrefs.cpp:3414
+#: src/frontends/qt/GuiView.cpp:2875 src/frontends/qt/GuiView.cpp:3107
+#: src/frontends/qt/GuiView.cpp:3131 src/frontends/qt/GuiView.cpp:3145
+#: src/frontends/qt/GuiView.cpp:3247 src/frontends/qt/GuiView.cpp:3292
+#: src/frontends/qt/GuiView.cpp:3347 src/frontends/qt/GuiView.cpp:3581
+#: src/frontends/qt/GuiView.cpp:3595 src/frontends/qt/GuiView.cpp:3697
+#: src/frontends/qt/GuiView.cpp:3722 src/frontends/qt/GuiView.cpp:4426
+#: src/frontends/qt/GuiView.cpp:4433 src/insets/InsetBibtex.cpp:153
 msgid "&Cancel"
 msgstr "&Отказване"
 
@@ -932,7 +922,7 @@ msgstr "&Неопределени разклонения:"
 
 # src/insets/insetbib.C:69 src/insets/insetbib.C:70 src/insets/insetbib.C:210
 # src/insets/insetbib.C:211
-#: src/frontends/qt/ui/BulletsUi.ui:17 src/frontends/qt/ui/PDFSupportUi.ui:421
+#: src/frontends/qt/ui/BulletsUi.ui:17 src/frontends/qt/ui/PDFSupportUi.ui:406
 msgid "&Level:"
 msgstr "&Ниво:"
 
@@ -962,20 +952,20 @@ msgstr "&Размер:"
 #: src/frontends/qt/GuiCharacter.cpp:85 src/frontends/qt/GuiCharacter.cpp:98
 #: src/frontends/qt/GuiCharacter.cpp:136 src/frontends/qt/GuiCharacter.cpp:147
 #: src/frontends/qt/GuiCharacter.cpp:190 src/frontends/qt/GuiCharacter.cpp:241
-#: src/frontends/qt/GuiDocument.cpp:120 src/frontends/qt/GuiDocument.cpp:858
-#: src/frontends/qt/GuiDocument.cpp:878 src/frontends/qt/GuiDocument.cpp:1048
-#: src/frontends/qt/GuiDocument.cpp:1133 src/frontends/qt/GuiDocument.cpp:1179
-#: src/frontends/qt/GuiDocument.cpp:1190 src/frontends/qt/GuiDocument.cpp:1418
-#: src/frontends/qt/GuiDocument.cpp:1536 src/frontends/qt/GuiDocument.cpp:1543
-#: src/frontends/qt/GuiDocument.cpp:2576 src/frontends/qt/GuiDocument.cpp:2663
-#: src/frontends/qt/GuiDocument.cpp:2664 src/frontends/qt/GuiDocument.cpp:2665
-#: src/frontends/qt/GuiDocument.cpp:2685 src/frontends/qt/GuiDocument.cpp:2692
-#: src/frontends/qt/GuiDocument.cpp:2699 src/frontends/qt/GuiDocument.cpp:2789
-#: src/frontends/qt/GuiDocument.cpp:3398 src/frontends/qt/GuiDocument.cpp:4888
+#: src/frontends/qt/GuiDocument.cpp:120 src/frontends/qt/GuiDocument.cpp:866
+#: src/frontends/qt/GuiDocument.cpp:886 src/frontends/qt/GuiDocument.cpp:1058
+#: src/frontends/qt/GuiDocument.cpp:1143 src/frontends/qt/GuiDocument.cpp:1189
+#: src/frontends/qt/GuiDocument.cpp:1200 src/frontends/qt/GuiDocument.cpp:1430
+#: src/frontends/qt/GuiDocument.cpp:1548 src/frontends/qt/GuiDocument.cpp:1555
+#: src/frontends/qt/GuiDocument.cpp:2590 src/frontends/qt/GuiDocument.cpp:2677
+#: src/frontends/qt/GuiDocument.cpp:2678 src/frontends/qt/GuiDocument.cpp:2679
+#: src/frontends/qt/GuiDocument.cpp:2703 src/frontends/qt/GuiDocument.cpp:2710
+#: src/frontends/qt/GuiDocument.cpp:2717 src/frontends/qt/GuiDocument.cpp:2807
+#: src/frontends/qt/GuiDocument.cpp:3413 src/frontends/qt/GuiDocument.cpp:4908
 #: src/frontends/qt/GuiExternal.cpp:76 src/frontends/qt/GuiGraphics.cpp:71
-#: src/frontends/qt/GuiIndices.cpp:58 src/frontends/qt/GuiListings.cpp:156
-#: src/frontends/qt/GuiListings.cpp:163 src/frontends/qt/GuiPrefs.cpp:2437
-#: src/frontends/qt/GuiPrefs.cpp:2583 src/frontends/qt/GuiPrintNomencl.cpp:47
+#: src/frontends/qt/GuiIndices.cpp:58 src/frontends/qt/GuiListings.cpp:160
+#: src/frontends/qt/GuiListings.cpp:167 src/frontends/qt/GuiPrefs.cpp:2483
+#: src/frontends/qt/GuiPrefs.cpp:2629 src/frontends/qt/GuiPrintNomencl.cpp:47
 #: src/frontends/qt/GuiTabularCreate.cpp:107
 #: src/frontends/qt/GuiViewSource.cpp:341
 msgid "Default"
@@ -983,43 +973,43 @@ msgstr "по подразбиране"
 
 # src/lyxfont.C:56
 #: src/frontends/qt/ui/BulletsUi.ui:142 src/FontInfo.cpp:55
-#: src/frontends/qt/GuiCharacter.cpp:65 src/frontends/qt/GuiListings.cpp:156
+#: src/frontends/qt/GuiCharacter.cpp:65 src/frontends/qt/GuiListings.cpp:160
 msgid "Tiny"
 msgstr "Дребен"
 
 # src/lyxfont.C:56
 #: src/frontends/qt/ui/BulletsUi.ui:147 src/FontInfo.cpp:55
-#: src/frontends/qt/GuiCharacter.cpp:66 src/frontends/qt/GuiListings.cpp:156
+#: src/frontends/qt/GuiCharacter.cpp:66 src/frontends/qt/GuiListings.cpp:160
 msgid "Smallest"
 msgstr "Най-малък"
 
 # src/lyxfont.C:56
 #: src/frontends/qt/ui/BulletsUi.ui:152 src/FontInfo.cpp:55
-#: src/frontends/qt/GuiCharacter.cpp:67 src/frontends/qt/GuiListings.cpp:156
+#: src/frontends/qt/GuiCharacter.cpp:67 src/frontends/qt/GuiListings.cpp:160
 msgid "Smaller"
 msgstr "По-малък"
 
 # src/lyxfont.C:56
 #: src/frontends/qt/ui/BulletsUi.ui:157 src/FontInfo.cpp:55
-#: src/frontends/qt/GuiCharacter.cpp:68 src/frontends/qt/GuiListings.cpp:156
+#: src/frontends/qt/GuiCharacter.cpp:68 src/frontends/qt/GuiListings.cpp:160
 msgid "Small"
 msgstr "Малък"
 
 # src/frontends/kde/paraextradlg.C:25 src/lyxfont.C:56
 #: src/frontends/qt/ui/BulletsUi.ui:162 src/FontInfo.cpp:55
-#: src/frontends/qt/GuiCharacter.cpp:69 src/frontends/qt/GuiListings.cpp:156
+#: src/frontends/qt/GuiCharacter.cpp:69 src/frontends/qt/GuiListings.cpp:160
 msgid "Normal"
 msgstr "Нормален"
 
 # src/lyxfont.C:56
 #: src/frontends/qt/ui/BulletsUi.ui:167 src/FontInfo.cpp:55
-#: src/frontends/qt/GuiCharacter.cpp:70 src/frontends/qt/GuiListings.cpp:157
+#: src/frontends/qt/GuiCharacter.cpp:70 src/frontends/qt/GuiListings.cpp:161
 msgid "Large"
 msgstr "Голям"
 
 # src/lyxfont.C:57
 #: src/frontends/qt/ui/BulletsUi.ui:172 src/FontInfo.cpp:56
-#: src/frontends/qt/GuiCharacter.cpp:71 src/frontends/qt/GuiListings.cpp:157
+#: src/frontends/qt/GuiCharacter.cpp:71 src/frontends/qt/GuiListings.cpp:161
 msgid "Larger"
 msgstr "По-голям"
 
@@ -1042,35 +1032,30 @@ msgid "Huger"
 msgstr "Грамаден"
 
 #: src/frontends/qt/ui/ChangeTrackingUi.ui:20
-#, fuzzy
 msgid "If checked, additions and deletions will be tracked in the document"
 msgstr ""
-"Само ако е отметнато бележките и коментарите се проверяват за правописни "
-"грешки"
+"Ако е отметнато процеса на добавяне и изтриване се проследява в документа"
 
 # src/ext_l10n.h:31
 #: src/frontends/qt/ui/ChangeTrackingUi.ui:23
-#, fuzzy
 msgid "&Track changes"
-msgstr "Проследяване на промените"
+msgstr "&Проследяване на промените"
 
 #: src/frontends/qt/ui/ChangeTrackingUi.ui:30
 msgid "If checked, changes will be shown in the PDF/DVI/PS output"
-msgstr ""
+msgstr "Ако е отметнато промените се показват в крайния документ (PDF/DVI/PS)"
 
 #: src/frontends/qt/ui/ChangeTrackingUi.ui:33
-#, fuzzy
 msgid "&Show changes in output"
-msgstr "Показване на промените в крайния документ"
+msgstr "П&оказване на промените в крайния документ"
 
 #: src/frontends/qt/ui/ChangeTrackingUi.ui:40
 msgid "Use change bars in addition to change tracking markup"
-msgstr ""
+msgstr "Използване на вертикални черти в допълнение към открояване на промените"
 
 #: src/frontends/qt/ui/ChangeTrackingUi.ui:43
-#, fuzzy
 msgid "Use change &bars in output"
-msgstr "Показване на промените в крайния документ"
+msgstr "Използване на черти в крайния документ"
 
 # src/LyXAction.C:263
 #: src/frontends/qt/ui/ChangesUi.ui:38
@@ -1183,15 +1168,14 @@ msgid "Strike-through text"
 msgstr "Зачертаване (задраскване) на текса"
 
 # src/frontends/xforms/FormPreferences.C:223
-#: src/frontends/qt/ui/CharacterUi.ui:254 src/frontends/qt/GuiPrefs.cpp:211
+#: src/frontends/qt/ui/CharacterUi.ui:254 src/frontends/qt/GuiPrefs.cpp:215
 msgid "Language Settings"
 msgstr "Езикови настройки"
 
 # диалогов прозорец
 # src/layout_forms.C:64
 #: src/frontends/qt/ui/CharacterUi.ui:265 src/frontends/qt/ui/LanguageUi.ui:22
-#: src/frontends/qt/ui/LyXFilesUi.ui:94
-#: src/frontends/qt/ui/SpellcheckerUi.ui:57
+#: src/frontends/qt/ui/SpellcheckerUi.ui:28
 #: src/frontends/qt/ui/ThesaurusUi.ui:23
 msgid "&Language:"
 msgstr "&Език:"
@@ -1202,8 +1186,8 @@ msgstr "&Език:"
 #: lib/layouts/bicaption.module:16 lib/layouts/europasscv.layout:440
 #: lib/layouts/europasscv.layout:475 lib/layouts/europasscv.layout:482
 #: lib/layouts/europecv.layout:321 lib/layouts/europecv.layout:327
-#: lib/layouts/moderncv.layout:580 src/frontends/qt/GuiDocument.cpp:1767
-#: src/frontends/qt/GuiPrefs.cpp:2388 src/frontends/qt/Menus.cpp:920
+#: lib/layouts/moderncv.layout:580 src/frontends/qt/GuiDocument.cpp:1781
+#: src/frontends/qt/GuiPrefs.cpp:2430 src/frontends/qt/Menus.cpp:938
 msgid "Language"
 msgstr "eзик"
 
@@ -1300,17 +1284,17 @@ msgstr ""
 # src/frontends/gnome/FormCitation.C:560
 #: src/frontends/qt/ui/CitationUi.ui:188
 msgid "Move the selected citation up (Ctrl-Up)"
-msgstr "Преместване избрания файл нагоре (Ctrl-горна стрелка)"
+msgstr "Преместване избраната препратка нагоре (Ctrl-горна стрелка)"
 
 # src/frontends/gnome/FormCitation.C:560
 #: src/frontends/qt/ui/CitationUi.ui:211
 msgid "Move the selected citation down (Ctrl-Down)"
-msgstr "Преместване на избрания файл надолу (Ctrl-долна стрелка)"
+msgstr "Преместване на избраната препратка надолу (Ctrl-долна стрелка)"
 
 # src/frontends/xforms/FormCitation.C:37
 #: src/frontends/qt/ui/CitationUi.ui:232
 msgid "Selected &Citations:"
-msgstr "Избрани цитирания:"
+msgstr "Избрани препратки:"
 
 # src/frontends/xforms/FormPreferences.C:252
 #: src/frontends/qt/ui/CitationUi.ui:276
@@ -1319,7 +1303,7 @@ msgstr "Форматиране"
 
 #: src/frontends/qt/ui/CitationUi.ui:289
 msgid "Citation st&yle:"
-msgstr "&Стил цитиране:"
+msgstr "&Стил препратки:"
 
 #: src/frontends/qt/ui/CitationUi.ui:299 src/frontends/qt/GuiCitation.cpp:303
 msgid "Text befo&re:"
@@ -1417,7 +1401,7 @@ msgstr "Цветни бележки:"
 
 # src/LyXAction.C:263
 #: src/frontends/qt/ui/ColorUi.ui:118 src/frontends/qt/ui/ColorUi.ui:256
-#: src/frontends/qt/GuiDocument.cpp:2205 src/frontends/qt/GuiDocument.cpp:2235
+#: src/frontends/qt/GuiDocument.cpp:2219 src/frontends/qt/GuiDocument.cpp:2249
 msgid "&Change..."
 msgstr "&Избор на цвят"
 
@@ -1443,9 +1427,8 @@ msgstr "Сравняване на ревизии"
 
 # src/ext_l10n.h:323
 #: src/frontends/qt/ui/CompareHistoryUi.ui:34
-#, fuzzy
 msgid "Revisions ba&ck"
-msgstr "Въпрос"
+msgstr "&Ревизии назад"
 
 # src/ext_l10n.h:24
 #: src/frontends/qt/ui/CompareHistoryUi.ui:87
@@ -1454,13 +1437,12 @@ msgstr "Между ревизии"
 
 #: src/frontends/qt/ui/CompareHistoryUi.ui:100
 msgid "Old:"
-msgstr ""
+msgstr "Първи:"
 
 # src/LColor.C:63
 #: src/frontends/qt/ui/CompareHistoryUi.ui:135
-#, fuzzy
 msgid "New:"
-msgstr "текст"
+msgstr "Втори:"
 
 # src/frontends/xforms/FormDocument.C:273 src/insets/figinset.C:1975
 # src/insets/insetexternal.C:143 src/lyxfunc.C:3105 src/lyxfunc.C:3181
@@ -1470,9 +1452,8 @@ msgid "Old Documen&t:"
 msgstr "&Първи документ:"
 
 #: src/frontends/qt/ui/CompareUi.ui:51
-#, fuzzy
 msgid "Specify the original version of the document here (comparison source)"
-msgstr "Посочете първоначалната версия на документа (източник)"
+msgstr "Посочете първоначалната версия на документа (източника)"
 
 # src/frontends/xforms/form_preferences.C:843
 # src/frontends/xforms/form_preferences.C:853
@@ -1492,9 +1473,8 @@ msgid "&New Document:"
 msgstr "&Втори документ:"
 
 #: src/frontends/qt/ui/CompareUi.ui:87
-#, fuzzy
 msgid "Specify the modified version of the document here (comparison target)"
-msgstr "Посочете променената версия на документа (цел на сравнението)"
+msgstr "Посочете променената версия на документа (целта на сравнението)"
 
 # src/frontends/xforms/form_preferences.C:843
 # src/frontends/xforms/form_preferences.C:853
@@ -1517,7 +1497,7 @@ msgstr "Избиране на документа от които да се вз
 
 # src/insets/insetinclude.C:117 src/lyx_cb.C:197 src/lyxfunc.C:3054
 # src/lyxfunc.C:3156 src/lyxfunc.C:3212 src/lyxfunc.C:3288
-#: src/frontends/qt/ui/CompareUi.ui:120 src/frontends/qt/GuiDocument.cpp:781
+#: src/frontends/qt/ui/CompareUi.ui:120 src/frontends/qt/GuiDocument.cpp:789
 msgid "Document Settings"
 msgstr "Настройки на документа"
 
@@ -1547,39 +1527,37 @@ msgstr "Активиране проследяване на промените в
 
 # src/form1.C:237
 #: src/frontends/qt/ui/CounterUi.ui:22
-#, fuzzy
 msgid "C&ounter:"
-msgstr "В&ъншно:"
+msgstr "&Брояч:"
 
 # src/lyxfunc.C:3159
 #: src/frontends/qt/ui/CounterUi.ui:38
-#, fuzzy
 msgid "Select counter to modify"
-msgstr "Изберане на документ за отваряне"
+msgstr "Изберане на брояч за настройка"
 
 # src/ext_l10n.h:344
 #: src/frontends/qt/ui/CounterUi.ui:45
-#, fuzzy
 msgid "&Action:"
-msgstr "Раздел"
+msgstr "&Действие:"
 
 #: src/frontends/qt/ui/CounterUi.ui:63
 msgid "Select the action to perform on selected counter"
-msgstr ""
+msgstr "Избиране на действие, което да се приложи към избрания брояч"
 
 #: src/frontends/qt/ui/CounterUi.ui:79
 msgid ""
 "If checked, modification affects the counter only in the LyX workarea, not "
 "in the output"
 msgstr ""
+"Ако е отметнато, промените засягат брояча само в работната среда на LyX, но "
+"не и в крайния документ"
 
 #: src/frontends/qt/ui/CounterUi.ui:85
-#, fuzzy
 msgid "&Workarea only"
-msgstr "Събития от работната среда"
+msgstr "&Само в работната среда"
 
 # src/frontends/xforms/form_toc.C:40
-#: src/frontends/qt/ui/DelimiterUi.ui:122 src/frontends/qt/GuiDelimiter.cpp:375
+#: src/frontends/qt/ui/DelimiterUi.ui:122 src/frontends/qt/GuiDelimiter.cpp:376
 msgid "TeX Code: "
 msgstr "TeX код:"
 
@@ -1616,9 +1594,8 @@ msgid "Use Class Defaults"
 msgstr "Възстановяване по подразбиране"
 
 #: src/frontends/qt/ui/DocumentUi.ui:109
-#, fuzzy
 msgid "Save settings as defaults for new documents"
-msgstr "Запазване на настройките в LyX като подразбиращи се за докмента"
+msgstr "Запазване на настройките като подразбиращи се за нови докменти"
 
 # src/ext_l10n.h:130
 #: src/frontends/qt/ui/DocumentUi.ui:112
@@ -1627,7 +1604,7 @@ msgstr "Запазване по подразбиране"
 
 # src/frontends/xforms/FormGraphics.C:36
 # src/frontends/xforms/FormGraphics.C:359
-#: src/frontends/qt/ui/ERTUi.ui:38 src/frontends/qt/GuiPrefs.cpp:1297
+#: src/frontends/qt/ui/ERTUi.ui:38 src/frontends/qt/GuiPrefs.cpp:1323
 msgid "Display"
 msgstr "Изглед"
 
@@ -1647,16 +1624,15 @@ msgstr "Показва целия изходен код на LaTex"
 
 # src/LyXAction.C:144
 #: src/frontends/qt/ui/ERTUi.ui:72
-#, fuzzy
 msgid "[[is]]O&pen"
-msgstr "&Разширен"
+msgstr "&Отваряне"
 
 #: src/frontends/qt/ui/ErrorListUi.ui:38
 msgid ""
 "Selecting an error will show the error message in the panel below and the "
 "cursor will jump to the location in the document where the error occurred."
 msgstr ""
-"Посочване на ред с грешка ще покаже описанието и в долния панел, а курсура в "
+"Избиране на ред с грешка ще покаже описанието и в долния панел, а курсура в "
 "документа ще се позиционира на мястото където е настъпила грешката."
 
 # src/importer.C:58
@@ -1693,7 +1669,7 @@ msgstr "Показване на резултата"
 # src/frontends/kde/dlg/printdlgdata.C:246
 #: src/frontends/qt/ui/ExternalUi.ui:45
 msgid "F&ile"
-msgstr "(&F)Файл"
+msgstr "Файл"
 
 # src/form1.C:245
 #: src/frontends/qt/ui/ExternalUi.ui:66 src/frontends/qt/ui/ExternalUi.ui:73
@@ -1792,9 +1768,8 @@ msgstr "Задава центъра на въртене"
 
 # src/ext_l10n.h:191
 #: src/frontends/qt/ui/ExternalUi.ui:426
-#, fuzzy
 msgid "Ori&gin:"
-msgstr "Заглавие"
+msgstr "Начало:"
 
 # src/form1.C:133
 #: src/frontends/qt/ui/ExternalUi.ui:446
@@ -1807,18 +1782,18 @@ msgid "Scale"
 msgstr "Мащаб"
 
 #: src/frontends/qt/ui/ExternalUi.ui:494 src/frontends/qt/ui/GraphicsUi.ui:153
-#: src/frontends/qt/GuiGraphics.cpp:476
+#: src/frontends/qt/GuiGraphics.cpp:482
 msgid "Height of image in output"
 msgstr "Крайна височина на изображението"
 
 #: src/frontends/qt/ui/ExternalUi.ui:504 src/frontends/qt/ui/GraphicsUi.ui:121
-#: src/frontends/qt/GuiGraphics.cpp:475
+#: src/frontends/qt/GuiGraphics.cpp:481
 msgid "Width of image in output"
 msgstr "Крайна ширина на изображението"
 
 #: src/frontends/qt/ui/ExternalUi.ui:527
 msgid "Maintain aspect ratio with largest dimension"
-msgstr ""
+msgstr "Запазване на съотношението при най-голям размер"
 
 #: src/frontends/qt/ui/ExternalUi.ui:530 src/frontends/qt/ui/GraphicsUi.ui:199
 msgid "&Maintain aspect ratio"
@@ -1831,11 +1806,11 @@ msgstr "Изрязване"
 
 #: src/frontends/qt/ui/ExternalUi.ui:577
 msgid "Clip to bounding box values"
-msgstr ""
+msgstr "Свиване до размера на ограничителната рамка"
 
 #: src/frontends/qt/ui/ExternalUi.ui:580
 msgid "Clip to &bounding box"
-msgstr ""
+msgstr "Свиване до размера на рамката"
 
 # src/ext_l10n.h:63
 #: src/frontends/qt/ui/ExternalUi.ui:587 src/frontends/qt/ui/GraphicsUi.ui:390
@@ -1854,7 +1829,7 @@ msgstr "&Горен десен ъгъл:"
 
 #: src/frontends/qt/ui/ExternalUi.ui:617
 msgid "Get bounding box from the (EPS) file"
-msgstr ""
+msgstr "Взимане на очертаващата рамка от EPS файла"
 
 # src/frontends/xforms/form_preferences.C:923
 #: src/frontends/qt/ui/ExternalUi.ui:620 src/frontends/qt/ui/GraphicsUi.ui:485
@@ -1867,9 +1842,8 @@ msgstr "y"
 
 # src/frontends/kde/dlg/parageneraldlgdata.C:151
 #: src/frontends/qt/ui/FindAndReplaceUi.ui:14
-#, fuzzy
 msgid "TabWidget"
-msgstr "Ширина на етикет"
+msgstr "Подпрозорец"
 
 # src/frontends/gnome/FormCitation.C:453
 #: src/frontends/qt/ui/FindAndReplaceUi.ui:21
@@ -1878,9 +1852,8 @@ msgstr "Търсене"
 
 # src/frontends/gnome/FormCitation.C:453
 #: src/frontends/qt/ui/FindAndReplaceUi.ui:55
-#, fuzzy
 msgid "Search fo&r:"
-msgstr "Грешка при търсене"
+msgstr "Търсене за:"
 
 # src/form1.C:290
 #: src/frontends/qt/ui/FindAndReplaceUi.ui:92
@@ -1901,10 +1874,9 @@ msgstr "Ограничава търсенето само до цели думи"
 
 # src/ext_l10n.h:263
 #: src/frontends/qt/ui/FindAndReplaceUi.ui:153
-#: src/frontends/qt/ui/SearchUi.ui:217 src/frontends/qt/GuiSearch.cpp:101
-#, fuzzy
+#: src/frontends/qt/ui/SearchUi.ui:241 src/frontends/qt/GuiSearch.cpp:102
 msgid "Wh&ole words"
-msgstr "Цели думи"
+msgstr "&Цели думи"
 
 #: src/frontends/qt/ui/FindAndReplaceUi.ui:160
 msgid "Perform a case-sensitive search"
@@ -1917,28 +1889,24 @@ msgstr "&Различ. на малки и големи букви"
 
 #: src/frontends/qt/ui/FindAndReplaceUi.ui:205
 #: src/frontends/qt/FindAndReplace.cpp:648
-#, fuzzy
 msgid "Find next occurrence (Enter, backwards: Shift+Enter)"
-msgstr "Търсене на следващото съвпадение - клавиша „Нов ред“"
+msgstr "Търсене на следващо съвпадение - клавиша „Нов ред“, назад: „Изместване“ + „Нов ред“"
 
 #: src/frontends/qt/ui/FindAndReplaceUi.ui:208
-#: src/frontends/qt/ui/SearchUi.ui:172 src/frontends/qt/FindAndReplace.cpp:647
-#, fuzzy
+#: src/frontends/qt/ui/SearchUi.ui:190 src/frontends/qt/FindAndReplace.cpp:647
 msgid "Find &>"
-msgstr "Следващо търсене"
+msgstr "Търсене &>"
 
 #: src/frontends/qt/ui/FindAndReplaceUi.ui:221
 #: src/frontends/qt/FindAndReplace.cpp:650
-#, fuzzy
 msgid "Replace and find next occurrence (Enter, backwards: Shift+Enter)"
-msgstr "Търсене и замяна на следващото съвпадение - клавиша „Нов ред“"
+msgstr "Замяна и търсене на следващо съвпадение - клавиша „Нов ред“, назад: „Изместване“ + „Нов ред“"
 
 # src/sp_form.C:86
 #: src/frontends/qt/ui/FindAndReplaceUi.ui:224
 #: src/frontends/qt/FindAndReplace.cpp:649
-#, fuzzy
 msgid "Rep&lace >"
-msgstr "Замяна"
+msgstr "Замяна >"
 
 # src/lyx_cb.C:230
 #: src/frontends/qt/ui/FindAndReplaceUi.ui:234
@@ -1947,15 +1915,14 @@ msgstr "Замяна на всички съвпадения наведнъж"
 
 # src/form1.C:314
 #: src/frontends/qt/ui/FindAndReplaceUi.ui:237
-#: src/frontends/qt/ui/SearchUi.ui:50
+#: src/frontends/qt/ui/SearchUi.ui:68
 msgid "Replace &All"
 msgstr "Замяна на &всички"
 
 # src/ext_l10n.h:344
 #: src/frontends/qt/ui/FindAndReplaceUi.ui:264
-#, fuzzy
 msgid "Settin&gs"
-msgstr "Настройки на програмата"
+msgstr "&Настройки"
 
 #: src/frontends/qt/ui/FindAndReplaceUi.ui:279
 msgid "The scope to which the search horizon is restricted"
@@ -2022,7 +1989,6 @@ msgstr "В целия текст"
 
 # src/LColor.C:81
 #: src/frontends/qt/ui/FindAndReplaceUi.ui:399
-#, fuzzy
 msgid "E&xpand macros"
 msgstr "Развиване на макросите"
 
@@ -2041,7 +2007,6 @@ msgstr "Запазване на първото съвпадение при за
 # src/frontends/xforms/FormPreferences.C:252
 #: src/frontends/qt/ui/FloatPlacementUi.ui:14
 #: src/frontends/qt/ui/OutputUi.ui:14 src/frontends/qt/ui/PDFSupportUi.ui:14
-#, fuzzy
 msgid "Form"
 msgstr "Формати"
 
@@ -2085,7 +2050,7 @@ msgstr "Центриране на съдържанието"
 #: src/frontends/qt/ui/FloatPlacementUi.ui:117
 #: src/frontends/qt/ui/ParagraphUi.ui:124 src/frontends/qt/ui/TabularUi.ui:1560
 msgid "&Center"
-msgstr "центриране"
+msgstr "център"
 
 #: src/frontends/qt/ui/FloatPlacementUi.ui:124
 msgid "Right-align float contents"
@@ -2159,7 +2124,6 @@ msgstr "&Пренебрегване правилата на LaTeX"
 
 # src/bufferview_funcs.C:267
 #: src/frontends/qt/ui/FontUi.ui:14
-#, fuzzy
 msgid "FontUi"
 msgstr "Шрифт:"
 
@@ -2185,7 +2149,7 @@ msgstr "&LaTeX кодиране:"
 
 #: src/frontends/qt/ui/FontUi.ui:101
 msgid "Specify the font encoding (e.g., T1)."
-msgstr ""
+msgstr "Посочване кодирането на шриф (напр. T1)."
 
 # src/frontends/xforms/form_preferences.C:105 src/lyxfont.C:42
 #: src/frontends/qt/ui/FontUi.ui:110
@@ -2197,6 +2161,8 @@ msgid ""
 "Select the roman (serif) typeface. To filter the list of fonts, just start "
 "typing while the list is expanded."
 msgstr ""
+"Избиране на шрифт със серифно (римско) начертаване. За филтриране на списъка "
+"започнете да пишете докато списъка се разширява."
 
 #: src/frontends/qt/ui/FontUi.ui:142
 msgid "Use a real small caps shape, if the font provides one"
@@ -2227,12 +2193,10 @@ msgstr "Опции:"
 
 #: src/frontends/qt/ui/FontUi.ui:194 src/frontends/qt/ui/FontUi.ui:302
 #: src/frontends/qt/ui/FontUi.ui:410
-#, fuzzy
 msgid ""
 "Here you can insert additional options (as provided by the font package)"
 msgstr ""
-"Тук можете да въведете допълнителни параметри за избрания библиографски "
-"пакет."
+"Тук можете да въведете допълнителни параметри предоставени от пакета за шрифт."
 
 # src/frontends/xforms/form_preferences.C:108
 #: src/frontends/qt/ui/FontUi.ui:205
@@ -2244,6 +2208,8 @@ msgid ""
 "Select the Sans Serif (grotesque) typeface. To filter the list of fonts, "
 "just start typing while the list is expanded."
 msgstr ""
+"Избиране на безсерифно (grotesque) начертаване. За филтриране на списъка от "
+"шрифтове започнете да пишете докато списъка се разширява."
 
 # src/frontends/xforms/form_tabular.C:453
 #: src/frontends/qt/ui/FontUi.ui:237
@@ -2258,9 +2224,8 @@ msgstr ""
 
 # src/lyxfunc.C:3128
 #: src/frontends/qt/ui/FontUi.ui:267
-#, fuzzy
 msgid "Use old st&yle figures"
-msgstr "Използване на цифри с различна височина"
+msgstr "Използване на цифри встар стил"
 
 # src/frontends/xforms/form_preferences.C:111 src/lyxfont.C:42
 #: src/frontends/qt/ui/FontUi.ui:313
@@ -2286,9 +2251,8 @@ msgstr ""
 
 # src/lyxfunc.C:3128
 #: src/frontends/qt/ui/FontUi.ui:375
-#, fuzzy
 msgid "Use old style &figures"
-msgstr "Използване на цифри с различна височина"
+msgstr "Използване на цифри в стар стил"
 
 # src/frontends/xforms/FormPreferences.C:261
 #: src/frontends/qt/ui/FontUi.ui:421
@@ -2298,7 +2262,7 @@ msgstr "За &математика:"
 # src/frontends/kde/printdlg.C:35
 #: src/frontends/qt/ui/FontUi.ui:431
 msgid "Select the math typeface"
-msgstr "Избор на шрифт за математически изрази"
+msgstr "Избор на начертаване за математически изрази"
 
 # src/frontends/gnome/FormCitation.C:527
 #: src/frontends/qt/ui/FontUi.ui:438
@@ -2345,7 +2309,7 @@ msgstr ""
 
 #: src/frontends/qt/ui/FontUi.ui:480
 msgid "Disallow l&ine breaks after dashes"
-msgstr "Забрана на нав ред след тирета (обикновено и дълго)"
+msgstr "Забрана на нав ред след тире (обикновено и дълго)"
 
 # src/frontends/xforms/FormGraphics.C:36
 # src/frontends/xforms/FormGraphics.C:359
@@ -2370,7 +2334,7 @@ msgstr ""
 "настройка."
 
 # src/form1.C:157 src/frontends/xforms/form_graphics.C:46
-#: src/frontends/qt/ui/GraphicsUi.ui:166 src/frontends/qt/GuiGraphics.cpp:474
+#: src/frontends/qt/ui/GraphicsUi.ui:166 src/frontends/qt/GuiGraphics.cpp:480
 msgid "Set &height:"
 msgstr "&Височина"
 
@@ -2389,7 +2353,7 @@ msgstr ""
 # src/form1.C:161 src/frontends/kde/dlg/paraextradlgdata.C:91
 # src/frontends/xforms/form_graphics.C:44
 # src/frontends/xforms/form_paragraph.C:219
-#: src/frontends/qt/ui/GraphicsUi.ui:186 src/frontends/qt/GuiGraphics.cpp:473
+#: src/frontends/qt/ui/GraphicsUi.ui:186 src/frontends/qt/GuiGraphics.cpp:479
 msgid "Set &width:"
 msgstr "&Ширина"
 
@@ -2481,10 +2445,11 @@ msgstr "Мащаб на екрана (%):"
 msgid ""
 "If LyX uses a dark theme, revert the colors of this graphics in the workarea"
 msgstr ""
+"Ако LyX използва тъмна тема, обръща цветовете при изобразяване на работната площ"
 
 #: src/frontends/qt/ui/GraphicsUi.ui:592
 msgid "Re&vert colors in dark mode"
-msgstr ""
+msgstr "Обръщане на цветовете в тъмен режим"
 
 # src/frontends/xforms/form_preferences.C:926
 #: src/frontends/qt/ui/GraphicsUi.ui:615 src/frontends/qt/ui/GraphicsUi.ui:634
@@ -2498,46 +2463,43 @@ msgstr "LaTeX &опции:"
 
 #: src/frontends/qt/ui/GraphicsUi.ui:641
 msgid "Assign the graphic to a group of graphics that share the same settings"
-msgstr ""
+msgstr "Присъединяване на изображение към група с еднакви настройки "
 
 # src/frontends/xforms/FormGraphics.C:36
 # src/frontends/xforms/FormGraphics.C:359
 #: src/frontends/qt/ui/GraphicsUi.ui:644
-#, fuzzy
 msgid "Graphics Group"
-msgstr "Графика"
+msgstr "Графична група"
 
 #: src/frontends/qt/ui/GraphicsUi.ui:677
 msgid "Assigned &to group:"
-msgstr ""
+msgstr "Присъединяване към група: "
 
 #: src/frontends/qt/ui/GraphicsUi.ui:700
 msgid "Click to define a new graphics group."
-msgstr ""
+msgstr "Щракнете за да дефинирате нова графична група."
 
 #: src/frontends/qt/ui/GraphicsUi.ui:703
 msgid "O&pen new group..."
-msgstr ""
+msgstr "Отваряне на нова група..."
 
 #: src/frontends/qt/ui/GraphicsUi.ui:710
 msgid "Select an existing group for the current graphics."
-msgstr ""
+msgstr "Избиране на съществуваща група за текущото изображение."
 
 # src/LyXAction.C:321
 #: src/frontends/qt/ui/GraphicsUi.ui:723
-#, fuzzy
 msgid "Draft mode"
-msgstr "Матем. режим"
+msgstr "Режим проектиране"
 
 # src/LyXAction.C:321
 #: src/frontends/qt/ui/GraphicsUi.ui:726
-#, fuzzy
 msgid "&Draft mode"
-msgstr "Матем. режим"
+msgstr "Режим &проектиране"
 
 #: src/frontends/qt/ui/HSpaceUi.ui:28
 msgid "Select a fill pattern style for HFills"
-msgstr ""
+msgstr "Избиране на стил за запълване на шаблон HFills"
 
 #: src/frontends/qt/ui/HSpaceUi.ui:37
 msgid "..............."
@@ -2581,23 +2543,21 @@ msgstr "&Стойност:"
 #: src/frontends/qt/ui/HSpaceUi.ui:100 src/frontends/qt/ui/VSpaceUi.ui:62
 msgid "Custom value. Needs spacing type \"Custom\"."
 msgstr ""
-"За да можете да зададете стойност отместването трябва да е „потребителско“"
+"За да можете да зададете стойност отместването трябва да е „от потребителя“"
 
 # src/frontends/kde/dlg/printdlgdata.C:246
 #: src/frontends/qt/ui/HSpaceUi.ui:110
-#, fuzzy
 msgid "&Fill Pattern:"
-msgstr "(&F)Файл"
+msgstr "Попълване на шаблон"
 
 #: src/frontends/qt/ui/HSpaceUi.ui:123 src/frontends/qt/ui/VSpaceUi.ui:46
 msgid "&Protect:"
-msgstr "Защити"
+msgstr "&Защити:"
 
 # src/LyXAction.C:197 src/lyx_cb.C:878
-#: src/frontends/qt/ui/HSpaceUi.ui:133 src/frontends/qt/GuiHSpace.cpp:212
-#, fuzzy
+#: src/frontends/qt/ui/HSpaceUi.ui:133 src/frontends/qt/GuiHSpace.cpp:217
 msgid "Insert the spacing even after a line break"
-msgstr "Вмъкни фигура"
+msgstr "Вмъкване на интервал дори след нов ред."
 
 # src/ext_l10n.h:406 src/frontends/gnome/FormUrl.C:117
 # src/frontends/kde/urldlg.C:62 src/frontends/kde/urldlg.C:63
@@ -2605,8 +2565,8 @@ msgstr "Вмъкни фигура"
 #: lib/layouts/acmart.layout:694 lib/layouts/acmart.layout:712
 #: lib/layouts/amsdefs.inc:190 lib/layouts/maa-monthly.layout:165
 #: lib/layouts/maa-monthly.layout:169 lib/layouts/minimalistic.module:27
-#: lib/layouts/scrlttr2.layout:271 lib/layouts/stdinsets.inc:578
-#: lib/layouts/stdinsets.inc:581
+#: lib/layouts/scrlttr2.layout:271 lib/layouts/stdinsets.inc:579
+#: lib/layouts/stdinsets.inc:582
 msgid "URL"
 msgstr "URL"
 
@@ -2618,7 +2578,7 @@ msgstr "&Цел:"
 # src/frontends/kde/urldlg.C:64 src/frontends/kde/urldlg.C:65
 #: src/frontends/qt/ui/HyperlinkUi.ui:37 src/frontends/qt/ui/HyperlinkUi.ui:68
 msgid "Name associated with the URL"
-msgstr "Име за URL-а"
+msgstr "Име свързано с URL-а"
 
 # src/frontends/gnome/FormRef.C:301
 #: src/frontends/qt/ui/HyperlinkUi.ui:40 src/frontends/qt/ui/LyXFilesUi.ui:55
@@ -2631,6 +2591,8 @@ msgid ""
 "Pass content of the `Name' field literally to LaTeX. Check this if you want "
 "to enter LaTeX code."
 msgstr ""
+"Подава съдържанието на полето „име“ дословно към LaTeX. Изберете това ако "
+"желаете да въвеждате код на LaTeX."
 
 # src/lyxrc.C:1838
 #: src/frontends/qt/ui/HyperlinkUi.ui:106
@@ -2703,8 +2665,8 @@ msgstr "Редактиране на файла"
 
 # src/MenuBackend.C:444 src/ext_l10n.h:2 src/ext_l10n.h:5
 #: src/frontends/qt/ui/IncludeUi.ui:72 src/frontends/qt/ui/LocalLayoutUi.ui:77
-#: src/frontends/qt/ui/PreambleUi.ui:48 src/frontends/qt/GuiDocument.cpp:579
-#: src/frontends/qt/GuiDocument.cpp:751
+#: src/frontends/qt/ui/PreambleUi.ui:48 src/frontends/qt/GuiDocument.cpp:578
+#: src/frontends/qt/GuiDocument.cpp:759
 msgid "&Edit"
 msgstr "&Редактиране"
 
@@ -2713,6 +2675,8 @@ msgid ""
 "File name to include. (You can create a new file by entering the name of one "
 "that does not yet exist.)"
 msgstr ""
+"Име на файл за включване. Може да създадете нов файл като въведете име на файл, "
+"който все още не съществува."
 
 #: src/frontends/qt/ui/IncludeUi.ui:124
 msgid "Underline spaces in generated output"
@@ -2730,7 +2694,7 @@ msgstr "Показване на предварителния изглед на L
 # src/frontends/kde/dlg/printdlgdata.C:246
 #: src/frontends/qt/ui/IncludeUi.ui:143
 msgid "&Show preview"
-msgstr "&Предварителен изглед"
+msgstr "Предварителен &изглед"
 
 # src/lyxfunc.C:1105 src/lyxfunc.C:2550
 #: src/frontends/qt/ui/IncludeUi.ui:171
@@ -2746,7 +2710,7 @@ msgstr "&Нодрис:"
 #: src/frontends/qt/ui/ListingsSettingsUi.ui:79
 #: src/frontends/qt/ui/ListingsUi.ui:507
 msgid "Check it to enter parameters that are not recognizable by LyX"
-msgstr ""
+msgstr "Отметка за въвеждане на параметри, които не се разпознават от LyX"
 
 #: src/frontends/qt/ui/IncludeUi.ui:282
 #: src/frontends/qt/ui/ListingsSettingsUi.ui:82
@@ -2789,8 +2753,8 @@ msgid "Index Generation"
 msgstr "Съставяне на указатели"
 
 # src/form1.C:129 src/sp_form.C:58
-#: src/frontends/qt/ui/IndicesUi.ui:54 src/frontends/qt/GuiPrefs.cpp:704
-#: src/frontends/qt/GuiPrefs.cpp:830
+#: src/frontends/qt/ui/IndicesUi.ui:54 src/frontends/qt/GuiPrefs.cpp:708
+#: src/frontends/qt/GuiPrefs.cpp:834
 msgid "&Options:"
 msgstr "&Опции:"
 
@@ -2878,19 +2842,17 @@ msgstr "Тук се въвежда точна дата в ISO формат: ГГ
 
 # src/ext_l10n.h:215
 #: src/frontends/qt/ui/InfoUi.ui:70
-#, fuzzy
 msgid "&Custom:"
 msgstr "&От потребителя:"
 
 # src/LyXAction.C:164
 #: src/frontends/qt/ui/InsetParamsUi.ui:17
-#, fuzzy
 msgid "Inset Parameter Configuration"
-msgstr "Вмъкни цитат"
+msgstr "Конфигурация на парамтри за добавки"
 
 #: src/frontends/qt/ui/InsetParamsUi.ui:47
 msgid "Update dialog when moving context"
-msgstr "Опресняване на диалога когато се сменя контекста"
+msgstr "Актуализиране на диалога когато се сменя контекста"
 
 #: src/frontends/qt/ui/InsetParamsUi.ui:50
 msgid "S&ynchronize Dialog"
@@ -2912,12 +2874,12 @@ msgstr "&Клас (жанр) документ"
 
 #: src/frontends/qt/ui/LaTeXUi.ui:48
 msgid "Click to select a local document class definition file"
-msgstr "Избиране на локална дефиниция на клас документ от файл"
+msgstr "Избиране на дефиниция на клас документ от локален файл"
 
 # src/insets/insettext.C:1036 src/lyxfunc.C:1260
 #: src/frontends/qt/ui/LaTeXUi.ui:51
-msgid "&Local Layout..."
-msgstr "&Разглеждане"
+msgid "&Local Class..."
+msgstr "&Локален клас..."
 
 # src/form1.C:129 src/sp_form.C:58
 #: src/frontends/qt/ui/LaTeXUi.ui:61
@@ -2951,7 +2913,7 @@ msgstr "&От потребителя:"
 # src/frontends/xforms/FormGraphics.C:359
 #: src/frontends/qt/ui/LaTeXUi.ui:106
 msgid "&Graphics driver:"
-msgstr "&Графичен драйвер"
+msgstr "&Графична представяне: "
 
 #: src/frontends/qt/ui/LaTeXUi.ui:136
 msgid "Select if the current document is included to a master file"
@@ -2987,9 +2949,8 @@ msgstr "Вид кавички"
 
 # src/frontends/xforms/FormDocument.C:1101
 #: src/frontends/qt/ui/LanguageUi.ui:49
-#, fuzzy
 msgid "Select the default quotation marks style"
-msgstr "Избиране на гарнитурата на шрифта по подразбиране за документа"
+msgstr "Избиране на кавички за цитиране по подразбиране"
 
 #: src/frontends/qt/ui/LanguageUi.ui:59
 msgid ""
@@ -3007,27 +2968,25 @@ msgstr "Динамичен знак за кавички"
 
 # src/frontends/xforms/form_preferences.C:132
 #: src/frontends/qt/ui/LanguageUi.ui:89
-#, fuzzy
 msgid "&Encoding:"
 msgstr "&Кодиране:"
 
 #: src/frontends/qt/ui/LanguageUi.ui:102
 msgid "Select encoding of the generated LaTeX source (LaTeX input encoding)."
-msgstr ""
+msgstr "Избиране на кодиране за генерирания изходен код на LaTex."
 
 #: src/frontends/qt/ui/LanguageUi.ui:115
 msgid "Select Unicode encoding variant."
-msgstr ""
+msgstr "Избиране на вариант на уникод кодиране."
 
 #: src/frontends/qt/ui/LanguageUi.ui:125
 msgid "Specify whether to load the 'inputenc' package."
-msgstr ""
+msgstr "Посочване дали да се зарежда пакета „inputenc“."
 
 # src/bufferlist.C:113 src/bufferlist.C:189
 #: src/frontends/qt/ui/LanguageUi.ui:135
-#, fuzzy
 msgid "Select custom encoding."
-msgstr "Запазване на документа?"
+msgstr "избиране на кодиране от потребителя."
 
 # src/layout_forms.C:64
 #: src/frontends/qt/ui/LanguageUi.ui:142
@@ -3089,10 +3048,10 @@ msgstr "Пакет за открояване на синтаксиса:"
 
 # src/ext_l10n.h:274
 #: src/frontends/qt/ui/ListingsUi.ui:14 lib/layouts/numreport.inc:37
-#: lib/layouts/stdcounters.inc:77 lib/layouts/stdinsets.inc:337
-#: lib/layouts/stdinsets.inc:343 lib/layouts/stdinsets.inc:392
-#: lib/layouts/stdinsets.inc:398 src/insets/InsetCaption.cpp:414
-#: src/insets/InsetListings.cpp:611 src/insets/InsetListings.cpp:612
+#: lib/layouts/stdcounters.inc:77 lib/layouts/stdinsets.inc:338
+#: lib/layouts/stdinsets.inc:344 lib/layouts/stdinsets.inc:393
+#: lib/layouts/stdinsets.inc:399 src/insets/InsetCaption.cpp:410
+#: src/insets/InsetListings.cpp:612 src/insets/InsetListings.cpp:613
 msgid "Listing"
 msgstr "Списък"
 
@@ -3245,33 +3204,30 @@ msgstr "&Диалект:"
 
 #: src/frontends/qt/ui/ListingsUi.ui:370
 msgid "Select the dialect of the programming language, if available"
-msgstr ""
+msgstr "Избор на диалект на език за програмиране ако е наличен"
 
 # src/bufferview_funcs.C:280
 #: src/frontends/qt/ui/ListingsUi.ui:380
-#, fuzzy
 msgid "Range"
-msgstr "Единично"
+msgstr "Обхват"
 
 # src/ext_l10n.h:242
 #: src/frontends/qt/ui/ListingsUi.ui:389
-#, fuzzy
 msgid "Fi&rst line:"
-msgstr "Малко име"
+msgstr "&Първи ред:"
 
 #: src/frontends/qt/ui/ListingsUi.ui:402
 msgid "The first line to be printed"
-msgstr ""
+msgstr "Първи ред за печатане"
 
 # src/LColor.C:84
 #: src/frontends/qt/ui/ListingsUi.ui:415
-#, fuzzy
 msgid "&Last line:"
-msgstr "ред на математика"
+msgstr "П&оследен ред:"
 
 #: src/frontends/qt/ui/ListingsUi.ui:428
 msgid "The last line to be printed"
-msgstr ""
+msgstr "Последен ред, които да се отпечта"
 
 # src/frontends/kde/FormCitation.C:166 src/frontends/kde/FormRef.C:203
 # src/frontends/kde/citationdlg.C:87 src/frontends/kde/dlg/indexdlgdata.C:85
@@ -3314,20 +3270,18 @@ msgstr "Грешките се показват в панела със съобщ
 
 #: src/frontends/qt/ui/LocalLayoutUi.ui:74 src/frontends/qt/ui/PreambleUi.ui:45
 msgid "Editor for Latex (plain) format will be used"
-msgstr ""
+msgstr "Ще се използва редактор за LaTeX в тектов режим"
 
 # src/frontends/xforms/FormPreferences.C:226
 # src/frontends/xforms/FormPreferences.C:255
 #: src/frontends/qt/ui/LocalLayoutUi.ui:84
-#, fuzzy
 msgid "Convert"
-msgstr "Конвертори"
+msgstr "Преобразуване"
 
 # src/frontends/xforms/form_toc.C:40
 #: src/frontends/qt/ui/LogUi.ui:25
-#, fuzzy
 msgid "Log &Type:"
-msgstr "Тип(T):|#T"
+msgstr "Тип &журнал:"
 
 #: src/frontends/qt/ui/LogUi.ui:71
 msgid "Jump to the next error message."
@@ -3354,7 +3308,7 @@ msgstr "&Търсене:"
 
 #: src/frontends/qt/ui/LogUi.ui:111
 msgid "Hit Enter or click 'Find Next' to search"
-msgstr ""
+msgstr "Натиснете клавиша „Нов ред“ или щракнете „Следващо търсене“ за да търсите."
 
 #: src/frontends/qt/ui/LogUi.ui:118
 msgid "Find &Next"
@@ -3374,7 +3328,7 @@ msgstr "Връщане в изходно положение"
 #: src/frontends/qt/ui/LogUi.ui:159 src/frontends/qt/ui/ViewSourceUi.ui:173
 #: src/frontends/qt/GuiRef.cpp:77
 msgid "&Update"
-msgstr "&Опресняване"
+msgstr "&Актуализиране"
 
 #: src/frontends/qt/ui/LyXFilesUi.ui:23
 msgid "Filter"
@@ -3403,6 +3357,12 @@ msgstr "При филтриране се раличават малки и гол
 msgid "Case Sensiti&ve"
 msgstr "Различава малки и големи"
 
+# диалогов прозорец
+# src/layout_forms.C:64
+#: src/frontends/qt/ui/LyXFilesUi.ui:94
+msgid "File &Language:"
+msgstr "&Език от файла:"
+
 #: src/frontends/qt/ui/LyXFilesUi.ui:110
 msgid "The available language(s) of the selected file will be displayed here"
 msgstr "Тук ще се показват наличните езици за избраните файлове."
@@ -3454,39 +3414,38 @@ msgstr "&Разделител на колони:"
 
 # src/bufferlist.C:113 src/bufferlist.C:189
 #: src/frontends/qt/ui/MasterChildUi.ui:20
-#, fuzzy
 msgid "Master Document Output"
-msgstr "Запазване на документа?"
+msgstr "Резултат от главния документ"
 
 #: src/frontends/qt/ui/MasterChildUi.ui:29
 msgid "Include all subdocuments in the output"
-msgstr ""
+msgstr "Включване на всички поддокументи в крайния резултат"
 
 # src/ext_l10n.h:92
 #: src/frontends/qt/ui/MasterChildUi.ui:32
-#, fuzzy
 msgid "&Include all children"
-msgstr "Включи файл(e)|e"
+msgstr "Включване на всички поддокументи"
 
 #: src/frontends/qt/ui/MasterChildUi.ui:39
 msgid "Include only the selected subdocuments in the output"
-msgstr ""
+msgstr "Включване само на избраните поддокументи в крайния резултат"
 
 #: src/frontends/qt/ui/MasterChildUi.ui:42
 msgid "Include only &selected children"
-msgstr ""
+msgstr "Включване само на избраните поддокументи"
 
 #: src/frontends/qt/ui/MasterChildUi.ui:58
 msgid ""
 "Here you can set up the handling of counters and references with regard to "
 "the excluded child documents."
 msgstr ""
+"Тук можете да настроите обработката на броячите и препратките по отношение "
+"на изключените поддокументи."
 
 # src/frontends/kde/refdlg.C:30
 #: src/frontends/qt/ui/MasterChildUi.ui:61
-#, fuzzy
 msgid "Global Counters && References"
-msgstr "всички нецитирани препратки"
+msgstr "Глобални броячи и препратки"
 
 #: src/frontends/qt/ui/MasterChildUi.ui:67
 msgid ""
@@ -3495,10 +3454,14 @@ msgid ""
 "document.<br>This is the fastest method. Use this if you do not need correct "
 "counter values and references."
 msgstr ""
+"Всички броячи и препратки от изключени поддокументи ще се пренебрегнат и така "
+"броячите в крайния документ ще се различават от броячите в пълния документ.<br> "
+"Това е най-бързия метод. Използва се само ако нямате нужда от коректни стойности "
+"на броячите и препратките."
 
 #: src/frontends/qt/ui/MasterChildUi.ui:70
 msgid "Do &not maintain (fast)"
-msgstr ""
+msgstr "Без спазване (бързо)"
 
 #: src/frontends/qt/ui/MasterChildUi.ui:77
 msgid ""
@@ -3509,10 +3472,16 @@ msgid ""
 "is significantly faster than \"Strictly maintain\". Use this if you need "
 "correct counters and more or less correct references."
 msgstr ""
+"Броячите и препратките на изключените поддокументи ще се настроят веднъж и "
+"ще се адаптират ако изключения документ бъде променен. Това работи правилно "
+"в повечето случай, но не коригира препатките към страници на невключените "
+"поддокументи, които се променят поради промяна във включените файлове. <br>"
+"Това много по-бързо от „Стриктно спазване“. Използвайте това ако имате нужда "
+"коректни броячи и повече или по-малко коректни препратки."
 
 #: src/frontends/qt/ui/MasterChildUi.ui:80
 msgid "Maintain mostl&y (medium)"
-msgstr ""
+msgstr "Спазване в &повечето случай (средно)"
 
 #: src/frontends/qt/ui/MasterChildUi.ui:87
 msgid ""
@@ -3520,16 +3489,19 @@ msgid ""
 "document. This can be much slower than the first two methods.<br>Use this if "
 "you absolutely need correct counters."
 msgstr ""
+"Гарантира, че всички броячи и препратки са идентични на цялостния документ. "
+"Това може да е много по-бьвно от първите два метода.<br>Използва се ако "
+"имате нужда от коректни броячи."
 
 #: src/frontends/qt/ui/MasterChildUi.ui:90
 msgid "Strictly &maintain (slow)"
-msgstr ""
+msgstr "Стриктно &спазване (бавно)"
 
 # src/mathed/math_forms.C:152
 #: src/frontends/qt/ui/MathMatrixUi.ui:53
 msgid "Horizontal alignment per column (l,c,r)"
 msgstr ""
-"Хоризонтално подравняване на колона - низ от „l“(ляво), „c“(центрирано) и "
+"Хоризонтално подравняване на колона - низ от „l“(ляво), „c“(център) и "
 "„r“(дясно)"
 
 # src/frontends/xforms/form_paragraph.C:153
@@ -3549,13 +3521,12 @@ msgstr "&Хоризонтално:"
 
 # src/ext_l10n.h:173
 #: src/frontends/qt/ui/MathMatrixUi.ui:100
-#, fuzzy
 msgid "Appearance"
-msgstr "Приложения"
+msgstr "Външен вид"
 
 #: src/frontends/qt/ui/MathMatrixUi.ui:122
 msgid "decoration type / matrix border"
-msgstr ""
+msgstr "тип декорация / матричен кант"
 
 # src/frontends/kde/printdlg.C:31
 #: src/frontends/qt/ui/MathMatrixUi.ui:149
@@ -3698,13 +3669,12 @@ msgstr ""
 # src/ext_l10n.h:291 src/insets/insetinfo.C:77 src/insets/insetinfo.C:102
 # src/insets/insetinfo.C:231
 #: src/frontends/qt/ui/NoteUi.ui:47
-#, fuzzy
 msgid "LyX &Note"
-msgstr "Бележка"
+msgstr "LyX Бележка"
 
 #: src/frontends/qt/ui/NoteUi.ui:54
 msgid "Export to LaTeX/Docbook but don't print"
-msgstr ""
+msgstr "Експортиране към LaTeX/Docbook, но без печат"
 
 # src/ext_l10n.h:202
 #: src/frontends/qt/ui/NoteUi.ui:57
@@ -3713,37 +3683,36 @@ msgstr "Коментар"
 
 # src/frontends/kde/printdlg.C:25
 #: src/frontends/qt/ui/NoteUi.ui:64
-#, fuzzy
 msgid "Print as grey text"
-msgstr "Печат на всяка страница"
+msgstr "Печат като сив текст"
 
 #: src/frontends/qt/ui/NoteUi.ui:67
 msgid "&Greyed out"
-msgstr ""
+msgstr "&Цветна бележка"
 
 # src/bufferlist.C:113 src/bufferlist.C:189
 #: src/frontends/qt/ui/NumberingUi.ui:37
-#, fuzzy
 msgid "Add line numbers to the document"
-msgstr "Показване на главния документ"
+msgstr "Добавяне номера на редовете в документа"
 
 # src/mathed/formula.C:929
 #: src/frontends/qt/ui/NumberingUi.ui:40
-#, fuzzy
 msgid "L&ine numbering"
 msgstr "Номериране на редовете"
 
 # src/form1.C:129 src/sp_form.C:58
 #: src/frontends/qt/ui/NumberingUi.ui:63
-#, fuzzy
 msgid "O&ptions:"
-msgstr "&Опции"
+msgstr "&Опции:"
 
 #: src/frontends/qt/ui/NumberingUi.ui:73
 msgid ""
 "Line numbering (lineno package) options (e.g. right, modulo, switch(*), "
 "pagewise). Please refer to the lineno package manual for details."
 msgstr ""
+"Опции за номериране на редовете (пакета lineno) (като right, module, "
+"switch(*), pagewise). Обърнете се към ръководството но пакета lineno "
+"за повече информация."
 
 # src/frontends/gnome/FormToc.C:100 src/frontends/gnome/FormToc.C:167
 # src/frontends/kde/FormToc.C:167 src/frontends/kde/FormToc.C:168
@@ -3760,36 +3729,59 @@ msgstr "&Номериране"
 
 # src/frontends/xforms/form_preferences.C:926
 #: src/frontends/qt/ui/OutputUi.ui:20
-#, fuzzy
 msgid "DocBook Output Options"
-msgstr "Опции за съставяне на XHTML"
+msgstr "Опции при извеждане на DocBook"
 
 # src/frontends/xforms/FormPreferences.C:232
 #: src/frontends/qt/ui/OutputUi.ui:35
-#, fuzzy
 msgid "&Table output:"
-msgstr "&Математически изходен резултат:"
+msgstr "Формат за &таблици:"
 
-#: src/frontends/qt/ui/OutputUi.ui:51 src/frontends/qt/ui/OutputUi.ui:203
+#: src/frontends/qt/ui/OutputUi.ui:51 src/frontends/qt/ui/OutputUi.ui:260
 msgid "Format to use for math output."
 msgstr ""
 "Избиране на изходен формат за резултата от обработката на математическите "
 "символи"
 
-#: src/frontends/qt/ui/OutputUi.ui:55 src/frontends/qt/ui/OutputUi.ui:212
+#: src/frontends/qt/ui/OutputUi.ui:55 src/frontends/qt/ui/OutputUi.ui:269
 msgid "HTML"
 msgstr "HTML"
 
 #: src/frontends/qt/ui/OutputUi.ui:60
 msgid "CALS"
+msgstr "CALS"
+
+#: src/frontends/qt/ui/OutputUi.ui:87
+msgid "&MathML namespace prefix:"
+msgstr "&Именовано пространство в MathML:"
+
+#: src/frontends/qt/ui/OutputUi.ui:103
+msgid ""
+"Namespace prefix to use for MathML formulae. For instance, with the <code>m</"
+"code> prefix, the MathML tags will be output like <code>m:math</code>."
 msgstr ""
+"Именовано пространство за използване във формулите на MathML. Например с "
+"префикс <code>m</code> елементите на MathML ще се изведат като <code>m:math</code>."
+
+#: src/frontends/qt/ui/OutputUi.ui:107
+msgid "No prefix (namespace defined inline for each tag)"
+msgstr "Без префикс - именното пространство се дефинира за всеки елемент"
+
+# src/ext_l10n.h:133
+#: src/frontends/qt/ui/OutputUi.ui:112
+msgid "m (default)"
+msgstr "m (по подразбиране)"
+
+#: src/frontends/qt/ui/OutputUi.ui:117
+msgid "mml"
+msgstr "mml"
 
 # src/frontends/xforms/FormPreferences.C:252
-#: src/frontends/qt/ui/OutputUi.ui:84
+#: src/frontends/qt/ui/OutputUi.ui:141
 msgid "LyX Format"
 msgstr "LyX формат"
 
-#: src/frontends/qt/ui/OutputUi.ui:96
+#: src/frontends/qt/ui/OutputUi.ui:153
 msgid ""
 "Save all parameters in the LyX file, including ones that are frequently "
 "switched or that are specific to the user (such as the output of the tracked "
@@ -3802,163 +3794,165 @@ msgstr ""
 "помага при съвместна работа върху един файл и при работа със ситема за "
 "управление на версиите."
 
-#: src/frontends/qt/ui/OutputUi.ui:99
+#: src/frontends/qt/ui/OutputUi.ui:156
 msgid "Save &transient properties"
 msgstr "Запазване на преходните настройки"
 
 # src/frontends/kde/tocdlg.C:57
-#: src/frontends/qt/ui/OutputUi.ui:109
+#: src/frontends/qt/ui/OutputUi.ui:166
 msgid "Output Format"
 msgstr "Изходен формат"
 
 # src/lyxrc.C:1838
-#: src/frontends/qt/ui/OutputUi.ui:150 src/frontends/qt/ui/OutputUi.ui:163
+#: src/frontends/qt/ui/OutputUi.ui:207 src/frontends/qt/ui/OutputUi.ui:220
 msgid "Specify the default output format (for view/update)"
 msgstr ""
 "Изберете изходния формат по подразбиране за предварителен преглед и "
-"опресняване."
+"актуализация."
 
 # src/frontends/xforms/form_preferences.C:221
-#: src/frontends/qt/ui/OutputUi.ui:153
+#: src/frontends/qt/ui/OutputUi.ui:210
 msgid "De&fault output format:"
 msgstr "&Изходен формат по подразбиране:"
 
 # src/frontends/xforms/form_preferences.C:926
-#: src/frontends/qt/ui/OutputUi.ui:188
+#: src/frontends/qt/ui/OutputUi.ui:245
 msgid "XHTML Output Options"
-msgstr "Опции за съставяне на XHTML"
+msgstr "Опции при извеждане на XHTML"
 
 # src/frontends/xforms/form_document.C:587
-#: src/frontends/qt/ui/OutputUi.ui:207
+#: src/frontends/qt/ui/OutputUi.ui:264
 msgid "MathML"
 msgstr "МаthML"
 
 # src/frontends/kde/dlg/printdlgdata.C:42
-#: src/frontends/qt/ui/OutputUi.ui:217
+#: src/frontends/qt/ui/OutputUi.ui:274
 msgid "Images"
 msgstr "Изображения"
 
 # src/ext_l10n.h:265
-#: src/frontends/qt/ui/OutputUi.ui:222 lib/layouts/aapaper.layout:63
+#: src/frontends/qt/ui/OutputUi.ui:279 lib/layouts/aapaper.layout:63
 #: lib/layouts/egs.layout:712 lib/languages:146
-#: src/frontends/qt/GuiDocument.cpp:1597 src/frontends/qt/GuiErrorList.cpp:50
-#: src/frontends/qt/GuiLog.cpp:235 src/frontends/qt/GuiPrefs.cpp:638
+#: src/frontends/qt/GuiDocument.cpp:1609 src/frontends/qt/GuiErrorList.cpp:50
+#: src/frontends/qt/GuiLog.cpp:282 src/frontends/qt/GuiPrefs.cpp:642
 msgid "LaTeX"
 msgstr "LaTeX"
 
 # src/frontends/kde/dlg/printdlgdata.C:88
 # src/frontends/xforms/form_print.C:138
-#: src/frontends/qt/ui/OutputUi.ui:230
+#: src/frontends/qt/ui/OutputUi.ui:287
 msgid "Write CSS to file"
 msgstr "Записване на CSS във файл"
 
 # src/frontends/xforms/FormPreferences.C:232
-#: src/frontends/qt/ui/OutputUi.ui:243
+#: src/frontends/qt/ui/OutputUi.ui:300
 msgid "&Math output:"
 msgstr "&Математически изходен резултат:"
 
 # src/mathed/math_panel.C:128
-#: src/frontends/qt/ui/OutputUi.ui:259
+#: src/frontends/qt/ui/OutputUi.ui:316
 msgid "Math &image scaling:"
-msgstr "Мащаб на мат. изображение:"
+msgstr "Мащаб на математ. изображение:"
 
-#: src/frontends/qt/ui/OutputUi.ui:269
+#: src/frontends/qt/ui/OutputUi.ui:326
 msgid "Whether to comply strictly with XHTML 1.1."
-msgstr "Дали да се спазва стриктно стандарта XHTML 1.1"
+msgstr "Спазвана стриктен XHTML 1.1 стандарт"
 
-#: src/frontends/qt/ui/OutputUi.ui:272
+#: src/frontends/qt/ui/OutputUi.ui:329
 msgid "&Strict XHTML 1.1"
 msgstr "&Стриктен XHTML 1.1"
 
-#: src/frontends/qt/ui/OutputUi.ui:285
+#: src/frontends/qt/ui/OutputUi.ui:342
 msgid "Scaling factor for images used for math output."
 msgstr ""
 "Коефицент за мащаба на изображението, в резултат от обработката на "
 "математическите символи"
 
-#: src/frontends/qt/ui/OutputUi.ui:320
+#: src/frontends/qt/ui/OutputUi.ui:377
 msgid ""
 "Runs the LaTeX backend with the -shell-escape option (Warning: use only when "
 "really necessary)"
 msgstr ""
+"Стартира програми от командния ред чрез -shell-escape опцията на LaTeX."
+"Внимание: използвайте само при необходимост поради риск за сигурността - "
+"изпълнение на произволни команди скрити в LaTeX скрипт."
 
-#: src/frontends/qt/ui/OutputUi.ui:323
+#: src/frontends/qt/ui/OutputUi.ui:380
 msgid "&Allow running external programs"
-msgstr ""
+msgstr "Рарешава се стартиране на &външни програми от LaTeX скрипт"
 
 # src/frontends/xforms/form_preferences.C:926
-#: src/frontends/qt/ui/OutputUi.ui:330
-#, fuzzy
+#: src/frontends/qt/ui/OutputUi.ui:387
 msgid "LaTeX Output Options"
-msgstr "Опции за съставяне на XHTML"
+msgstr "Опции на LaTeX за крайния файл"
 
-#: src/frontends/qt/ui/OutputUi.ui:338
+#: src/frontends/qt/ui/OutputUi.ui:395
 msgid "Enable forward/reverse search between editor and output (e.g., SyncTeX)"
 msgstr ""
 "Позволява търсене напред и назад между LyX-редактора и изходния резултат "
 "(напр. от SyncTeX)"
 
-#: src/frontends/qt/ui/OutputUi.ui:341
+#: src/frontends/qt/ui/OutputUi.ui:398
 msgid "S&ynchronize with output"
 msgstr "&Синхронизиране с изхода"
 
 # src/ext_l10n.h:215
-#: src/frontends/qt/ui/OutputUi.ui:366
+#: src/frontends/qt/ui/OutputUi.ui:423
 msgid "C&ustom macro:"
 msgstr "&Вмъкване на LaTeX команда:"
 
 # src/lyx_cb.C:675
-#: src/frontends/qt/ui/OutputUi.ui:376
+#: src/frontends/qt/ui/OutputUi.ui:433
 msgid "Custom LaTeX preamble macro"
 msgstr "Избиране на LaTeX команда за вмъкване в заглавната част"
 
-#: src/frontends/qt/ui/OutputUi.ui:403
+#: src/frontends/qt/ui/OutputUi.ui:460
 msgid ""
 "If this is checked, fragile items such as labels and index entries are moved "
 "out of moving arguments such as sections and captions. This prevents LaTeX "
 "errors that can happen in such cases. It is recommended to keep this on."
 msgstr ""
 
-#: src/frontends/qt/ui/OutputUi.ui:406
+#: src/frontends/qt/ui/OutputUi.ui:463
 msgid "Put fra&gile content out of moving arguments"
 msgstr ""
 
-#: src/frontends/qt/ui/PDFSupportUi.ui:38
+#: src/frontends/qt/ui/PDFSupportUi.ui:23
 msgid "&Use hyperref support"
-msgstr ""
+msgstr "Използване на хипервръзки"
 
 # src/frontends/xforms/FormParagraph.C:132
-#: src/frontends/qt/ui/PDFSupportUi.ui:72
+#: src/frontends/qt/ui/PDFSupportUi.ui:57
 msgid "&General"
 msgstr "&Общо"
 
 # src/ext_l10n.h:146
-#: src/frontends/qt/ui/PDFSupportUi.ui:119
+#: src/frontends/qt/ui/PDFSupportUi.ui:104
 msgid "Header Information"
 msgstr "Заглавна информация"
 
 # src/ext_l10n.h:395 src/frontends/gnome/FormCitation.C:529
-#: src/frontends/qt/ui/PDFSupportUi.ui:134
+#: src/frontends/qt/ui/PDFSupportUi.ui:119
 msgid "&Title:"
 msgstr "&Заглавие:"
 
 # src/ext_l10n.h:175
-#: src/frontends/qt/ui/PDFSupportUi.ui:147
+#: src/frontends/qt/ui/PDFSupportUi.ui:132
 msgid "&Author:"
 msgstr "&Автор:"
 
 # src/ext_l10n.h:367
-#: src/frontends/qt/ui/PDFSupportUi.ui:160
+#: src/frontends/qt/ui/PDFSupportUi.ui:145
 msgid "Sub&ject:"
 msgstr "&Тема:"
 
 # src/ext_l10n.h:262 src/frontends/gnome/FormIndex.C:89
 # src/frontends/xforms/form_index.C:28
-#: src/frontends/qt/ui/PDFSupportUi.ui:173
+#: src/frontends/qt/ui/PDFSupportUi.ui:158
 msgid "&Keywords:"
 msgstr "&Ключови думи:"
 
-#: src/frontends/qt/ui/PDFSupportUi.ui:206
+#: src/frontends/qt/ui/PDFSupportUi.ui:191
 msgid ""
 "If not stated explicitly, fill title and author from appropriate environments"
 msgstr ""
@@ -3966,82 +3960,99 @@ msgstr ""
 "контекст"
 
 # src/ext_l10n.h:175
-#: src/frontends/qt/ui/PDFSupportUi.ui:209
+#: src/frontends/qt/ui/PDFSupportUi.ui:194
 msgid "Automatically fi&ll header"
 msgstr "&Автоматично попълване на заглавната част"
 
-#: src/frontends/qt/ui/PDFSupportUi.ui:216
+#: src/frontends/qt/ui/PDFSupportUi.ui:201
 msgid "Enable fullscreen PDF presentation"
 msgstr "Разрешаване на PDF презентации на пълен екран"
 
-#: src/frontends/qt/ui/PDFSupportUi.ui:219
+#: src/frontends/qt/ui/PDFSupportUi.ui:204
 msgid "Load in &fullscreen mode"
 msgstr "&Зареждане в режим на пълен екран"
 
 # src/frontends/kde/urldlg.C:45
-#: src/frontends/qt/ui/PDFSupportUi.ui:229
+#: src/frontends/qt/ui/PDFSupportUi.ui:214
 msgid "H&yperlinks"
 msgstr "&Хипервръзки"
 
-#: src/frontends/qt/ui/PDFSupportUi.ui:280
+#: src/frontends/qt/ui/PDFSupportUi.ui:265
 msgid "Allows link text to break across lines."
 msgstr "Разрешаване хипервръзките да се пренасят на нов ред"
 
-#: src/frontends/qt/ui/PDFSupportUi.ui:283
+#: src/frontends/qt/ui/PDFSupportUi.ui:268
 msgid "B&reak links over lines"
 msgstr "&Пренасяне на връзките на нов ред"
 
-#: src/frontends/qt/ui/PDFSupportUi.ui:290
+#: src/frontends/qt/ui/PDFSupportUi.ui:275
 msgid "No &frames around links"
 msgstr "&Без рамки около връзките"
 
 # src/frontends/xforms/FormPreferences.C:244
-#: src/frontends/qt/ui/PDFSupportUi.ui:300
+#: src/frontends/qt/ui/PDFSupportUi.ui:285
 msgid "C&olor links"
 msgstr "&Цветни връзки"
 
-#: src/frontends/qt/ui/PDFSupportUi.ui:307
+#: src/frontends/qt/ui/PDFSupportUi.ui:292
 msgid "Bibliographical backreferences"
 msgstr "Поставяне на обратни указатели в литературния списък"
 
 # src/frontends/xforms/FormPreferences.C:68
-#: src/frontends/qt/ui/PDFSupportUi.ui:310
+#: src/frontends/qt/ui/PDFSupportUi.ui:295
 msgid "B&ackreferences:"
 msgstr "&Обратни указатели:"
 
 # src/frontends/xforms/form_paragraph.C:244
-#: src/frontends/qt/ui/PDFSupportUi.ui:339
+#: src/frontends/qt/ui/PDFSupportUi.ui:324
 msgid "&Bookmarks"
 msgstr "&Показалци"
 
 # src/frontends/xforms/form_paragraph.C:244
-#: src/frontends/qt/ui/PDFSupportUi.ui:360
+#: src/frontends/qt/ui/PDFSupportUi.ui:345
 msgid "G&enerate bookmarks (toc)"
 msgstr "&Създаване на показалци в съдържанието"
 
 # src/lyxfont.C:415
-#: src/frontends/qt/ui/PDFSupportUi.ui:390
+#: src/frontends/qt/ui/PDFSupportUi.ui:375
 msgid "&Numbered bookmarks"
 msgstr "&Номерирани показалци"
 
 # src/frontends/xforms/form_paragraph.C:244
-#: src/frontends/qt/ui/PDFSupportUi.ui:397
+#: src/frontends/qt/ui/PDFSupportUi.ui:382
 msgid "&Open bookmark tree"
 msgstr "&Отваряне на дървото с показалци"
 
 # src/frontends/kde/printdlg.C:31
-#: src/frontends/qt/ui/PDFSupportUi.ui:431
+#: src/frontends/qt/ui/PDFSupportUi.ui:416
 msgid "Number of levels"
 msgstr "Брой нива"
 
 # src/frontends/xforms/form_preferences.C:926
-#: src/frontends/qt/ui/PDFSupportUi.ui:473
+#: src/frontends/qt/ui/PDFSupportUi.ui:455
 msgid "Additional O&ptions"
 msgstr "&Допълнителни опции"
 
-#: src/frontends/qt/ui/PDFSupportUi.ui:509
-msgid "e.g.: pdfstartview=XYZ, plainpages=false, pdfpagelabels"
-msgstr "напр.: „pdfstartview=XYZ, plainpages=false, pdfpagelabels“"
+#: src/frontends/qt/ui/PDFSupportUi.ui:461
+msgid ""
+"Additional hyperref options (comma-separated) to be passed via \\hypersetup."
+msgstr ""
+"Допълнителни опции за хипервръзките, разделени със запетая и предавани чрез \\hypersetup."
+
+#: src/frontends/qt/ui/PDFSupportUi.ui:464
+msgid "Hyperse&tup"
+msgstr "Настройка на хипервръзките"
+
+#: src/frontends/qt/ui/PDFSupportUi.ui:487
+msgid ""
+"Document metadata and PDF settings (as specified in LaTeX 06/2022 and later)"
+msgstr ""
+"Метаданни за документа и PDF настройките, така както са в LaTeX 06/22 и следващи версии"
+
+# src/ext_l10n.h:130
+#: src/frontends/qt/ui/PDFSupportUi.ui:490
+msgid "Document &Metadata"
+msgstr "&Метаданни за документа"
 
 # src/frontends/xforms/form_preferences.C:354
 #: src/frontends/qt/ui/PageLayoutUi.ui:20
@@ -4078,9 +4089,9 @@ msgstr "Пей&заж"
 # src/frontends/xforms/FormParagraph.C:33
 #: src/frontends/qt/ui/PageLayoutUi.ui:162
 #: lib/layouts/customHeadersFooters.module:3 lib/layouts/landscape.module:3
-#: lib/layouts/multicol.module:3 src/frontends/qt/GuiDocument.cpp:1765
+#: lib/layouts/multicol.module:3 src/frontends/qt/GuiDocument.cpp:1779
 msgid "Page Layout"
-msgstr "Оформление на страниците"
+msgstr "Страници"
 
 # src/frontends/xforms/form_document.C:278
 #: src/frontends/qt/ui/PageLayoutUi.ui:171
@@ -4107,17 +4118,17 @@ msgstr "&Разстояние между редовете"
 
 # src/bufferview_funcs.C:280
 #: src/frontends/qt/ui/ParagraphUi.ui:60 src/Text.cpp:2118
-#: src/frontends/qt/GuiDocument.cpp:867
+#: src/frontends/qt/GuiDocument.cpp:875
 msgid "Single"
 msgstr "eдинично"
 
 #: src/frontends/qt/ui/ParagraphUi.ui:65
 msgid "1.5"
-msgstr ""
+msgstr "1.5"
 
 # src/bufferview_funcs.C:286
 #: src/frontends/qt/ui/ParagraphUi.ui:70 src/Text.cpp:2124
-#: src/frontends/qt/GuiDocument.cpp:871
+#: src/frontends/qt/GuiDocument.cpp:879
 msgid "Double"
 msgstr "двойно"
 
@@ -4128,19 +4139,19 @@ msgstr "двойно"
 #: src/frontends/qt/ui/TabularUi.ui:1210 src/frontends/qt/ui/TabularUi.ui:1229
 #: src/frontends/qt/ui/TabularUi.ui:1277 src/frontends/qt/ui/VSpaceUi.ui:118
 #: lib/layouts/stdcustom.inc:8 src/frontends/qt/FloatPlacement.cpp:185
-#: src/frontends/qt/GuiDocument.cpp:859 src/frontends/qt/GuiDocument.cpp:865
-#: src/frontends/qt/GuiDocument.cpp:873 src/frontends/qt/GuiDocument.cpp:987
-#: src/frontends/qt/GuiDocument.cpp:1054 src/frontends/qt/GuiDocument.cpp:1140
-#: src/frontends/qt/GuiDocument.cpp:1191 src/frontends/qt/GuiDocument.cpp:1537
-#: src/frontends/qt/GuiHSpace.cpp:57 src/frontends/qt/GuiPrefs.cpp:812
-#: src/frontends/qt/GuiPrefs.cpp:840 src/frontends/qt/GuiPrefs.cpp:867
-#: src/frontends/qt/GuiPrefs.cpp:2287 src/frontends/qt/GuiPrefs.cpp:2310
+#: src/frontends/qt/GuiDocument.cpp:867 src/frontends/qt/GuiDocument.cpp:873
+#: src/frontends/qt/GuiDocument.cpp:881 src/frontends/qt/GuiDocument.cpp:997
+#: src/frontends/qt/GuiDocument.cpp:1064 src/frontends/qt/GuiDocument.cpp:1150
+#: src/frontends/qt/GuiDocument.cpp:1201 src/frontends/qt/GuiDocument.cpp:1549
+#: src/frontends/qt/GuiHSpace.cpp:57 src/frontends/qt/GuiPrefs.cpp:816
+#: src/frontends/qt/GuiPrefs.cpp:844 src/frontends/qt/GuiPrefs.cpp:871
+#: src/frontends/qt/GuiPrefs.cpp:2329 src/frontends/qt/GuiPrefs.cpp:2352
 #: src/frontends/qt/GuiPrintNomencl.cpp:51 src/insets/InsetInfo.cpp:236
 #: src/insets/InsetInfo.cpp:246 src/insets/InsetInfo.cpp:250
-#: src/insets/InsetInfo.cpp:259 src/insets/InsetInfo.cpp:317
-#: src/insets/InsetInfo.cpp:335
+#: src/insets/InsetInfo.cpp:259 src/insets/InsetInfo.cpp:321
+#: src/insets/InsetInfo.cpp:343
 msgid "Custom"
-msgstr "потребителско"
+msgstr "задаване"
 
 #: src/frontends/qt/ui/ParagraphUi.ui:110
 msgid "&Justified"
@@ -4153,7 +4164,7 @@ msgstr "от&дясно"
 
 #: src/frontends/qt/ui/ParagraphUi.ui:138
 msgid "Use the default alignment for this paragraph, whatever it is."
-msgstr ""
+msgstr "Използване на подравняване по подразбиране за този параграф, каквото и да е то."
 
 # src/frontends/kde/FormParagraph.C:183
 # src/frontends/xforms/FormParagraph.C:148
@@ -4178,13 +4189,12 @@ msgstr "Най-дълъг етикет"
 
 # src/buffer.C:323
 #: src/frontends/qt/ui/ParagraphUi.ui:201
-#, fuzzy
 msgid "&Do not indent paragraph"
-msgstr "Абзац с отстъп"
+msgstr "Абзац без отстъп"
 
 #: src/frontends/qt/ui/PhantomUi.ui:47
 msgid "Horizontal and vertical space of the phantom content"
-msgstr ""
+msgstr "Хориз. и верт. разстояние от фантомното съдържание"
 
 # src/ext_l10n.h:438
 #: src/frontends/qt/ui/PhantomUi.ui:50
@@ -4213,24 +4223,22 @@ msgstr "Вертикален фантом"
 
 # src/form1.C:286
 #: src/frontends/qt/ui/PreambleUi.ui:38
-#, fuzzy
 msgid "&Find"
 msgstr "&Търсене:"
 
 # src/frontends/kde/citationdlg.C:96
 #: src/frontends/qt/ui/PrefColorsUi.ui:60
-#, fuzzy
 msgid "Change the selected color"
-msgstr "Променяне името на избраното разклонение."
+msgstr "Промяна на избрания цвят"
 
 # src/intl.C:349 src/intl.C:350
 #: src/frontends/qt/ui/PrefColorsUi.ui:63
 msgid "A&lter..."
-msgstr "&Променяне"
+msgstr "&Промяна"
 
 #: src/frontends/qt/ui/PrefColorsUi.ui:70
 msgid "Reset the selected color to its original value"
-msgstr ""
+msgstr "Връщане на избрания цвят до неговата първоначална стойност"
 
 #: src/frontends/qt/ui/PrefColorsUi.ui:73
 msgid "Restore &Default"
@@ -4241,13 +4249,12 @@ msgid "Reset all colors to their original value"
 msgstr "Възстановяване на всички цветове до първоначалната им стойност"
 
 #: src/frontends/qt/ui/PrefColorsUi.ui:83
-#, fuzzy
 msgid "Restore A&ll"
-msgstr "Възстановяване"
+msgstr "Възстановяване всички"
 
 #: src/frontends/qt/ui/PrefColorsUi.ui:105
 msgid "Use the color scheme of your Operating System/Desktop Environment"
-msgstr ""
+msgstr "Използване на цветовата схема от графичната среда на операционната система"
 
 # src/lyxfunc.C:1132
 #: src/frontends/qt/ui/PrefColorsUi.ui:108
@@ -4274,7 +4281,7 @@ msgstr "Автоматично дописване в реда"
 
 #: src/frontends/qt/ui/PrefCompletionUi.ui:51
 msgid "Show the popup in math mode after the delay."
-msgstr ""
+msgstr "Показване на изскачащ прозорец в матем. режим след закъснение"
 
 # src/ext_l10n.h:175
 #: src/frontends/qt/ui/PrefCompletionUi.ui:54
@@ -4327,9 +4334,9 @@ msgid "Cursor i&ndicator"
 msgstr "Индикатор на курсора"
 
 #: src/frontends/qt/ui/PrefCompletionUi.ui:119
-#: src/frontends/qt/GuiPrefs.cpp:317
+#: src/frontends/qt/GuiPrefs.cpp:321
 msgid "General[[settings]]"
-msgstr ""
+msgstr "Общи"
 
 #: src/frontends/qt/ui/PrefCompletionUi.ui:142
 msgid ""
@@ -4428,8 +4435,8 @@ msgstr "&Редактиране"
 
 # src/frontends/kde/dlg/paradlgdata.C:82
 #: src/frontends/qt/ui/PrefConvertersUi.ui:286
-#: src/frontends/qt/ui/PrefShortcutsUi.ui:61 src/frontends/qt/GuiPrefs.cpp:3101
-#: src/frontends/qt/GuiPrefs.cpp:3187
+#: src/frontends/qt/ui/PrefShortcutsUi.ui:61 src/frontends/qt/GuiPrefs.cpp:3150
+#: src/frontends/qt/GuiPrefs.cpp:3236
 msgid "Remo&ve"
 msgstr "&Премахване"
 
@@ -4524,11 +4531,12 @@ msgid ""
 "If this is checked, additions in change tracking are underlined in the "
 "workarea"
 msgstr ""
+"Ако е отметнато добавките в документа при проследяване на промените се "
+"подчертават в работната площ"
 
 #: src/frontends/qt/ui/PrefDisplayUi.ui:157
-#, fuzzy
 msgid "&Underline change tracking additions"
-msgstr "Активиране проследяване на промените в крайния документ"
+msgstr "&Подчертаване на промените в документа"
 
 # src/debug.C:42
 #: src/frontends/qt/ui/PrefDocHandlingUi.ui:26
@@ -4660,7 +4668,7 @@ msgid "Ask the user"
 msgstr "пита се птребителя"
 
 # src/ext_l10n.h:16 src/ext_l10n.h:29
-#: src/frontends/qt/ui/PrefEditUi.ui:26 src/frontends/qt/GuiPrefs.cpp:210
+#: src/frontends/qt/ui/PrefEditUi.ui:26 src/frontends/qt/GuiPrefs.cpp:214
 msgid "Editing"
 msgstr "Редактиране"
 
@@ -4690,10 +4698,13 @@ msgid ""
 "paste operations and when moving content from/to insets if change tracking "
 "is deactivated."
 msgstr ""
+"Ако е отметнато, открояването на текста при проследяване на промените няма да "
+"се възстанови при операциите копиране и поставяне, и при преместване на текст "
+"от/в добавка при неактивно проселдяване на промените."
 
 #: src/frontends/qt/ui/PrefEditUi.ui:93
 msgid "&Keep change tracking markup on copy and paste"
-msgstr ""
+msgstr "Проследяване на промените при копиране и поставяне"
 
 # src/frontends/kde/refdlg.C:99
 #: src/frontends/qt/ui/PrefEditUi.ui:100
@@ -4713,21 +4724,19 @@ msgstr ""
 
 # src/frontends/kde/printdlg.C:35
 #: src/frontends/qt/ui/PrefEditUi.ui:119
-#, fuzzy
 msgid "Search &drive for cited files"
-msgstr "Изборане на директория за примерни файлове"
+msgstr "Претърсване на диска за файлове с цитати"
 
 # src/frontends/kde/dlg/printdlgdata.C:246
 #: src/frontends/qt/ui/PrefEditUi.ui:144
-#, fuzzy
 msgid "Patte&rn:"
-msgstr "(&F)Файл"
+msgstr "Шаблан:"
 
 #: src/frontends/qt/ui/PrefEditUi.ui:154
 msgid "Define search pattern (see UserGuide for syntax)"
-msgstr ""
+msgstr "Дефиниране на шаблон за търсене (виж ръководството за синтаксис)"
 
-#: src/frontends/qt/ui/PrefEditUi.ui:167 src/LyXRC.cpp:3103
+#: src/frontends/qt/ui/PrefEditUi.ui:167 src/LyXRC.cpp:3175
 msgid ""
 "Configure the width of the text cursor. Automatic zoom-controlled cursor "
 "width used when set to 0."
@@ -4741,7 +4750,7 @@ msgstr "Ширина на курсора в пиксели (px):"
 
 #: src/frontends/qt/ui/PrefEditUi.ui:198
 msgid "Skip trailing non-word characters"
-msgstr ""
+msgstr "Премахване на крайните знаци, които не са букви"
 
 # src/ext_l10n.h:202
 #: src/frontends/qt/ui/PrefEditUi.ui:201
@@ -4769,7 +4778,6 @@ msgid "Hide sta&tusbar"
 msgstr "Скриване на лентата на състоянието"
 
 #: src/frontends/qt/ui/PrefEditUi.ui:267
-#, fuzzy
 msgid "H&ide tabbar"
 msgstr "Скриване на лентата с разделите"
 
@@ -4778,7 +4786,6 @@ msgid "&Limit text width"
 msgstr "Ограничаване ширината на реда"
 
 #: src/frontends/qt/ui/PrefEditUi.ui:328
-#, fuzzy
 msgid "Screen used (pi&xels):"
 msgstr "Изполван екран в пиксели (px):"
 
@@ -4858,7 +4865,7 @@ msgid ""
 "Specification of the default output formats when using specific LaTeX "
 "variants"
 msgstr ""
-"Показва форматите по подразбиране, когато се използва специфичен LaTeXi "
+"Показва форматите по подразбиране, когато се използва специфичен LaTeX "
 "вариант."
 
 # src/frontends/xforms/form_preferences.C:221
@@ -4907,13 +4914,12 @@ msgstr "Вашето име"
 
 # src/lyxfont.C:51
 #: src/frontends/qt/ui/PrefIdentityUi.ui:41
-#, fuzzy
 msgid "&Initials:"
-msgstr "Курсив"
+msgstr "&Инициали:"
 
 #: src/frontends/qt/ui/PrefIdentityUi.ui:63
 msgid "Initials of your name"
-msgstr ""
+msgstr "Инициали на вашето име"
 
 # src/layout_forms.C:23
 #: src/frontends/qt/ui/PrefIdentityUi.ui:72
@@ -5012,7 +5018,7 @@ msgid "Ctrl"
 msgstr "Ctrl"
 
 # src/lyxfont.C:56
-#: src/frontends/qt/ui/PrefInputUi.ui:249 src/insets/InsetInfo.cpp:855
+#: src/frontends/qt/ui/PrefInputUi.ui:249 src/insets/InsetInfo.cpp:863
 msgid "Shift"
 msgstr "Shift"
 
@@ -5032,9 +5038,8 @@ msgstr ""
 "Изберете езика за графичния потребителски интерфейс (менюта, диалози и т.н.)"
 
 #: src/frontends/qt/ui/PrefLanguageUi.ui:57
-#, fuzzy
 msgid "LaTeX Language Support"
-msgstr "Поддръжка за писане от дясно наляво"
+msgstr "Поддържани езици от LaTeX"
 
 # src/layout_forms.C:64
 #: src/frontends/qt/ui/PrefLanguageUi.ui:63
@@ -5042,38 +5047,36 @@ msgid "Language &package:"
 msgstr "&Езиков пакет:"
 
 #: src/frontends/qt/ui/PrefLanguageUi.ui:73
-#, fuzzy
 msgid "Select which (LaTeX) language package documents should use by default"
-msgstr "Изберете какъв езиков пакет да се използва от LyX"
+msgstr "Изберете какъв езиков пакет от LaTeX да се използва по подразбиране"
 
 # src/ext_l10n.h:175
 #: src/frontends/qt/ui/PrefLanguageUi.ui:77
-#: src/frontends/qt/GuiDocument.cpp:1050 src/frontends/qt/GuiDocument.cpp:2706
-#: src/frontends/qt/GuiPrefs.cpp:811 src/frontends/qt/GuiPrefs.cpp:839
+#: src/frontends/qt/GuiDocument.cpp:1060 src/frontends/qt/GuiDocument.cpp:2724
+#: src/frontends/qt/GuiPrefs.cpp:815 src/frontends/qt/GuiPrefs.cpp:843
 msgid "Automatic"
 msgstr "по подразбиране"
 
 # src/layout_forms.C:72
 #: src/frontends/qt/ui/PrefLanguageUi.ui:82
-#: src/frontends/qt/GuiDocument.cpp:1052
+#: src/frontends/qt/GuiDocument.cpp:1062
 msgid "Always Babel"
-msgstr "винаги Babel"
+msgstr "винаги Бабел (babel)"
 
 # src/layout_forms.C:64
 #: src/frontends/qt/ui/PrefLanguageUi.ui:92
-#: src/frontends/qt/GuiDocument.cpp:1056
+#: src/frontends/qt/GuiDocument.cpp:1066
 msgid "None[[language package]]"
 msgstr "няма"
 
 # src/lyxrc.C:1908
 #: src/frontends/qt/ui/PrefLanguageUi.ui:100
-#, fuzzy
 msgid ""
 "Enter the command to load a custom language package (default: "
 "\\usepackage{babel})"
 msgstr ""
-"Въведете командата за зареждане на езиков пакет (по подразбиране: "
-"\\usepackage{babel}"
+"Въведете команда за зареждане на езиков пакет от потребителя "
+"(по подразбиране: \\usepackage{babel}"
 
 # src/frontends/xforms/form_preferences.C:438
 #: src/frontends/qt/ui/PrefLanguageUi.ui:107
@@ -5082,11 +5085,11 @@ msgstr "Команда за начало:"
 
 # src/lyxrc.C:1936
 #: src/frontends/qt/ui/PrefLanguageUi.ui:117
-#, fuzzy
 msgid ""
 "The LaTeX command that starts a switch to a different language. The "
 "placeholder $$lang is replaced by the actual language name."
-msgstr "LaTeX командата за начало на локална смяна на езика."
+msgstr "LaTeX командата за начало на локална смяна на езика. "
+"Променливата $$lang се заменя с името на езика."
 
 # src/frontends/xforms/form_preferences.C:445
 #: src/frontends/qt/ui/PrefLanguageUi.ui:124
@@ -5095,97 +5098,91 @@ msgstr "Команда за край:"
 
 # src/lyxrc.C:1936
 #: src/frontends/qt/ui/PrefLanguageUi.ui:134
-#, fuzzy
 msgid ""
 "The LaTeX command that ends a switch to a different language.  The "
 "placeholder $$lang is replaced by the actual language name."
 msgstr "LaTeX командата за край на локалната смяна на езика."
+"Променливата $$lang се заменя с името на езика."
 
 #: src/frontends/qt/ui/PrefLanguageUi.ui:141
-#, fuzzy
 msgid ""
 "Check to pass the language globally (to the document class), not locally (to "
 "the language package), so that other packages are also informed about the "
 "used languages."
 msgstr ""
-"Активирай за настройка на езика глобално - за класа (жанра) на документа, а "
-"не локално - за езиковия пакет"
+"При активиране настройката на езика е глобална - за класа (жанра) на документа, а "
+"не локално - за езиковия пакет, така че, други пакети също разбират използваните "
+"езици."
 
 #: src/frontends/qt/ui/PrefLanguageUi.ui:144
 msgid "Set languages &globally"
 msgstr "Задаване на езика глобално"
 
 #: src/frontends/qt/ui/PrefLanguageUi.ui:151
-#, fuzzy
 msgid ""
 "If checked, the document language is explicitly set by a language switch "
 "command"
 msgstr ""
-"Отметнете за да не настройвате изришно езика за документа с команда за смяна "
+"Отметнете за да настройвате изрично езика за документа с команда за смяна "
 "на език"
 
 #: src/frontends/qt/ui/PrefLanguageUi.ui:154
-#, fuzzy
 msgid "Set document language e&xplicitly"
-msgstr "Задаване на езика глобално"
+msgstr "Езика се задава изрично"
 
 #: src/frontends/qt/ui/PrefLanguageUi.ui:161
-#, fuzzy
 msgid ""
 "If checked, the document language is explicitly closed by a language switch "
 "command"
 msgstr ""
-"Отметнете за да не затваряте изришно езика за документа с команда за смяна "
+"Отметнете за да затваряте изрично езика за документа с команда за смяна "
 "на език"
 
 #: src/frontends/qt/ui/PrefLanguageUi.ui:164
 msgid "&Unset document language explicitly"
-msgstr ""
+msgstr "Езика не се задава изрично"
 
 # заглавие на диалог
 # src/form1.C:129 src/sp_form.C:58
 #: src/frontends/qt/ui/PrefLanguageUi.ui:177
-#, fuzzy
 msgid "Editor Settings"
-msgstr "Настройки на рамка"
+msgstr "Настройки на редактора"
 
 #: src/frontends/qt/ui/PrefLanguageUi.ui:189
-#, fuzzy
 msgid ""
 "Check to highlight additional languages (to the document language) visually "
 "in the work area"
 msgstr ""
-"Отметнете за да откроите визуално текста на чужд език в работния документ"
+"Отметка за открояване визуално текста на чужди езици в работния документ"
 
 #: src/frontends/qt/ui/PrefLanguageUi.ui:192
-#, fuzzy
 msgid "&Mark additional languages"
-msgstr "Открояване на чужд език"
+msgstr "Открояване на чужди езици"
 
-#: src/frontends/qt/ui/PrefLanguageUi.ui:199 src/LyXRC.cpp:3231
+#: src/frontends/qt/ui/PrefLanguageUi.ui:199 src/LyXRC.cpp:3303
 msgid ""
 "Select to use the current keyboard language, as set from the operating "
 "system, as default input language."
 msgstr ""
+"Избиране на език на клавиатурата по подразбиране от настройките на операционната система"
 
 # src/frontends/xforms/FormPreferences.C:1798
 # src/frontends/xforms/FormPreferences.C:1806
 #: src/frontends/qt/ui/PrefLanguageUi.ui:202
-#, fuzzy
 msgid "Respect &OS keyboard language"
-msgstr "Клавишна подредба"
+msgstr "Съобразяване с езика на клавиатурата от ОС"
 
 #: src/frontends/qt/ui/PrefLanguageUi.ui:226
 msgid ""
 "Specify here how the arrow keys behave within scripts with right-to-left "
 "direction"
 msgstr ""
+"Посочете тук как се движи курсора с клавишите стрелка в текст от дясно наляво"
 
 # src/ext_l10n.h:202
 #: src/frontends/qt/ui/PrefLanguageUi.ui:229
-#, fuzzy
 msgid "Right-to-left cursor movement:"
-msgstr "Използване на Mac стил движение на кусора"
+msgstr "Движение на кусора от дясно на ляво:"
 
 #: src/frontends/qt/ui/PrefLanguageUi.ui:239
 msgid ""
@@ -5193,6 +5190,9 @@ msgid ""
 "to-left text in a left-to-right paragraph, the cursor starts at the right "
 "when coming from the left)"
 msgstr ""
+"Курсора следва логическата посока на текста (напр. в текст „от дясно наляво“ "
+"вложен в абзац с текст „от ляво надясно“, курсора започва вдясно, когато идва "
+"отляво)."
 
 # src/frontends/kde/dlg/paraextradlgdata.C:142
 #: src/frontends/qt/ui/PrefLanguageUi.ui:242
@@ -5205,6 +5205,8 @@ msgid ""
 "text in a left-to-right paragraph, the cursor starts at the left when coming "
 "from the left)"
 msgstr ""
+"Курсора следва визуалните посоки (напр. в текст „от дясно наляво“ вложен в "
+"абзац с текст „от ляво надясно“, курсора започва вляво, когато идва отляво)."
 
 #: src/frontends/qt/ui/PrefLanguageUi.ui:255
 msgid "&Visual"
@@ -5212,9 +5214,8 @@ msgstr "&Визуално"
 
 # src/frontends/kde/refdlg.C:30
 #: src/frontends/qt/ui/PrefLanguageUi.ui:280
-#, fuzzy
 msgid "Local Preferences"
-msgstr "всички препратки"
+msgstr "Локални предпочитания"
 
 #: src/frontends/qt/ui/PrefLanguageUi.ui:286
 #: src/frontends/qt/ui/PrefLanguageUi.ui:344
@@ -5223,6 +5224,9 @@ msgid ""
 "dialog by default. \"Language default\" selects the appropriate separator "
 "for the current language."
 msgstr ""
+"Тук се посочва десетичния разделител по подразбиране, който се използва в "
+"диалога с настройките на таблица. Избирайки „По подлазбиране за езика“ поставя "
+"подходящия разделител за текущия език."
 
 # src/frontends/xforms/form_preferences.C:221
 #: src/frontends/qt/ui/PrefLanguageUi.ui:289
@@ -5231,16 +5235,14 @@ msgstr "Разделител за десетични числа:"
 
 # src/frontends/xforms/form_preferences.C:221
 #: src/frontends/qt/ui/PrefLanguageUi.ui:318
-#, fuzzy
 msgid "Insert a custom decimal separator here"
-msgstr "Разделител за десетични числа:"
+msgstr "Вмъкване тук на разделител за десетични числа от потребителя"
 
 # src/frontends/xforms/FormDocument.C:1101
 #: src/frontends/qt/ui/PrefLanguageUi.ui:331
 #: src/frontends/qt/ui/PrefLanguageUi.ui:361
-#, fuzzy
 msgid "Select the default length unit for LyX dialogs"
-msgstr "Избиране на гарнитурата на шрифта по подразбиране за документа"
+msgstr "Избиране на мерна единица за дължина по подразбиране за LyX диалозите"
 
 # src/frontends/xforms/form_preferences.C:391
 #: src/frontends/qt/ui/PrefLanguageUi.ui:334
@@ -5249,10 +5251,9 @@ msgstr "Eдиница за дължина:"
 
 # src/ext_l10n.h:270
 #: src/frontends/qt/ui/PrefLanguageUi.ui:348
-#: src/frontends/qt/GuiDocument.cpp:1013
-#, fuzzy
+#: src/frontends/qt/GuiDocument.cpp:1023
 msgid "Language Default"
-msgstr "&По подразбиране за езика"
+msgstr "По подразбиране за езика"
 
 # src/frontends/xforms/form_preferences.C:926
 #: src/frontends/qt/ui/PrefLatexUi.ui:34
@@ -5388,7 +5389,7 @@ msgstr "Други опции"
 msgid "Output &line length:"
 msgstr "Дължина на реда на изходния документ:"
 
-#: src/frontends/qt/ui/PrefOutputUi.ui:186 src/LyXRC.cpp:3042
+#: src/frontends/qt/ui/PrefOutputUi.ui:186 src/LyXRC.cpp:3114
 msgid ""
 "The maximum line length of exported plain text/LaTeX/SGML files. If set to "
 "0, paragraphs are output in a single line; if the line length is > 0, "
@@ -5732,19 +5733,17 @@ msgstr "Настройки на означенията"
 #: src/frontends/qt/ui/PrintNomenclUi.ui:19
 #: src/frontends/qt/ui/PrintNomenclUi.ui:32
 msgid "Define hanging indentation/label length for the nomenclature list."
-msgstr ""
+msgstr "Определяне на отстъпа за запис или етикет от номенслатурен списък."
 
 # src/frontends/xforms/form_paragraph.C:48
 #: src/frontends/qt/ui/PrintNomenclUi.ui:22
-#, fuzzy
 msgid "&List Indentation:"
-msgstr "Отместване"
+msgstr "Отместване на списък:"
 
 # src/mathed/math_forms.C:140
 #: src/frontends/qt/ui/PrintNomenclUi.ui:39
-#, fuzzy
 msgid "Custom &Width:"
-msgstr "Колони "
+msgstr "Ширина от потребителя:"
 
 #: src/frontends/qt/ui/PrintNomenclUi.ui:52
 msgid "Custom value. \"List Indentation\" needs to be set to \"Custom\"."
@@ -5757,9 +5756,8 @@ msgstr "Набични указатели:"
 
 # src/frontends/xforms/FormDocument.C:1101
 #: src/frontends/qt/ui/PrintindexUi.ui:50
-#, fuzzy
 msgid "Select the index that shall be printed at this place of the document."
-msgstr "подразбиращи се за този документ клас?"
+msgstr "Избиране на индекс, които да се отпечата на това място от дакумента."
 
 #: src/frontends/qt/ui/PrintindexUi.ui:61
 msgid "Check if this index should be part (e.g., a section) of the former one."
@@ -5767,20 +5765,21 @@ msgstr ""
 
 # src/layout_forms.C:28
 #: src/frontends/qt/ui/PrintindexUi.ui:64
-#, fuzzy
 msgid "&Subindex"
-msgstr "Серия(S):|#S"
+msgstr "&Подиндекс"
 
 #: src/frontends/qt/ui/PrintindexUi.ui:71
 msgid ""
 "Pass index names literally to LaTeX. Check this if you want to use LaTeX "
 "code in index names."
 msgstr ""
+"Подаване на индексни имена дословно към LaTeX. Отметнете това ако искате "
+"да използвате код на LaTeX в имена на индекси."
 
 # src/frontends/xforms/FormPreferences.C:232
-#: src/frontends/qt/ui/ProgressViewUi.ui:93 src/frontends/qt/GuiPrefs.cpp:212
+#: src/frontends/qt/ui/ProgressViewUi.ui:93 src/frontends/qt/GuiPrefs.cpp:216
 msgid "Output"
-msgstr "Изходен документ"
+msgstr "Краен документ"
 
 # src/ext_l10n.h:344
 #: src/frontends/qt/ui/ProgressViewUi.ui:146
@@ -5932,21 +5931,18 @@ msgstr "<препратка> на стр. <страница>"
 
 # src/frontends/kde/refdlg.C:66
 #: src/frontends/qt/ui/RefUi.ui:262 src/frontends/qt/GuiRef.cpp:325
-#, fuzzy
 msgid "Formatted reference"
-msgstr "\"Хубава\" препратка"
+msgstr "Форматирана препратка"
 
 # src/frontends/kde/refdlg.C:30
 #: src/frontends/qt/ui/RefUi.ui:267 src/frontends/qt/GuiRef.cpp:324
-#, fuzzy
 msgid "Textual reference"
-msgstr "Достъпни препратки"
+msgstr "Текстова препратки"
 
 # src/frontends/xforms/FormPreferences.C:244
 #: src/frontends/qt/ui/RefUi.ui:272 src/frontends/qt/GuiRef.cpp:326
-#, fuzzy
 msgid "Label only"
-msgstr "Цветове"
+msgstr "Само етикет"
 
 #: src/frontends/qt/ui/RefUi.ui:310
 msgid ""
@@ -5979,140 +5975,124 @@ msgstr "Главни букви"
 msgid "Do not output part of label before \":\""
 msgstr "Не извежда частта от етикета преди „:“ (двоеточието)."
 
-#: src/frontends/qt/ui/RefUi.ui:333 lib/ui/stdcontext.inc:106
+#: src/frontends/qt/ui/RefUi.ui:333 lib/ui/stdcontext.inc:126
 msgid "No Prefix"
 msgstr "Без префикс"
 
-#: src/frontends/qt/ui/SearchUi.ui:34
-#, fuzzy
+#: src/frontends/qt/ui/SearchUi.ui:52
 msgid "Find previous occurrence (Shift+Enter)"
-msgstr "Търсене на следващото съвпадение - клавиша „Нов ред“"
+msgstr "Търсене на предишно съвпадение - клавиша „Изместване“ + „Нов ред“"
 
 # src/form1.C:286
-#: src/frontends/qt/ui/SearchUi.ui:37 src/frontends/qt/FindAndReplace.cpp:642
-#, fuzzy
+#: src/frontends/qt/ui/SearchUi.ui:55 src/frontends/qt/FindAndReplace.cpp:642
 msgid "&< Find"
-msgstr "&Търсене:"
+msgstr "< Търсене"
 
 # src/lyx_cb.C:230
-#: src/frontends/qt/ui/SearchUi.ui:47
+#: src/frontends/qt/ui/SearchUi.ui:65
 #, fuzzy
 msgid "Replace all occurrences"
 msgstr "Замяна на всички съвпадения наведнъж"
 
-#: src/frontends/qt/ui/SearchUi.ui:82 src/frontends/qt/GuiSearch.cpp:203
+#: src/frontends/qt/ui/SearchUi.ui:100 src/frontends/qt/GuiSearch.cpp:206
 msgid "Hide replace and option widgets"
 msgstr ""
 
 # src/frontends/xforms/FormPreferences.C:247
 # src/frontends/xforms/FormPreferences.C:264
 # src/frontends/xforms/FormPreferences.C:272 src/mathed/math_forms.C:46
-#: src/frontends/qt/ui/SearchUi.ui:85 src/frontends/qt/GuiSearch.cpp:202
-#, fuzzy
+#: src/frontends/qt/ui/SearchUi.ui:103 src/frontends/qt/GuiSearch.cpp:205
 msgid "&Minimize"
-msgstr "Различни"
+msgstr "Минимизиране"
 
 # src/form1.C:290
-#: src/frontends/qt/ui/SearchUi.ui:92
-#, fuzzy
+#: src/frontends/qt/ui/SearchUi.ui:110
 msgid "Rep&lace with:"
-msgstr "Замяна с:"
+msgstr "&Замяна с:"
 
 # src/frontends/gnome/FormCitation.C:453
-#: src/frontends/qt/ui/SearchUi.ui:102
-#, fuzzy
+#: src/frontends/qt/ui/SearchUi.ui:120
 msgid "&Search:"
-msgstr "Търсене"
+msgstr "Търсене:"
 
-#: src/frontends/qt/ui/SearchUi.ui:137
-#, fuzzy
+#: src/frontends/qt/ui/SearchUi.ui:155
 msgid "Replace and find next occurrence"
-msgstr "Търсене и замяна на следващото съвпадение - клавиша „Нов ред“"
+msgstr "Замяна и намиране на следващо съвпадение"
 
 # src/sp_form.C:86
-#: src/frontends/qt/ui/SearchUi.ui:143
-#, fuzzy
+#: src/frontends/qt/ui/SearchUi.ui:161
 msgid "&Replace >"
-msgstr "Замяна"
+msgstr "Замяна >"
 
-#: src/frontends/qt/ui/SearchUi.ui:153
-#, fuzzy
+#: src/frontends/qt/ui/SearchUi.ui:171
 msgid "Replace and find previous occurrence"
-msgstr "Търсене и замяна на следващото съвпадение - клавиша „Нов ред“"
+msgstr "Замяна и намиране на следващо съвпадение"
 
 # src/sp_form.C:86
-#: src/frontends/qt/ui/SearchUi.ui:156
-#, fuzzy
+#: src/frontends/qt/ui/SearchUi.ui:174
 msgid "< Re&place"
-msgstr "Замяна"
+msgstr "< Замяна"
 
-#: src/frontends/qt/ui/SearchUi.ui:166
-#, fuzzy
+#: src/frontends/qt/ui/SearchUi.ui:184
 msgid "Find next occurrence (Enter)"
-msgstr "Търсене на следващото съвпадение - клавиша „Нов ред“"
+msgstr "Намиране на следващо съвпадение - клавиша „Нов ред“"
 
-#: src/frontends/qt/ui/SearchUi.ui:204
+#: src/frontends/qt/ui/SearchUi.ui:228
 msgid "Treat uppercase/lowercase writing as distinct"
-msgstr ""
+msgstr "Различаване на малки и големи букви"
 
 # src/form1.C:310
-#: src/frontends/qt/ui/SearchUi.ui:207 src/frontends/qt/GuiSearch.cpp:99
-#, fuzzy
+#: src/frontends/qt/ui/SearchUi.ui:231 src/frontends/qt/GuiSearch.cpp:100
 msgid "&Case sensitive[[search]]"
 msgstr "Различаване на малки от големи букви"
 
-#: src/frontends/qt/ui/SearchUi.ui:214
-#, fuzzy
+#: src/frontends/qt/ui/SearchUi.ui:238
 msgid "Match whole words only"
-msgstr "&Съвпадение само на цели думи"
+msgstr "Съвпадение само на цели думи"
 
-#: src/frontends/qt/ui/SearchUi.ui:224
+#: src/frontends/qt/ui/SearchUi.ui:248
 msgid "Limit search and replace to selection"
-msgstr ""
+msgstr "Ограничаване на търсенето и замяна само до избрания текс"
 
 # src/LColor.C:64
-#: src/frontends/qt/ui/SearchUi.ui:227 src/frontends/qt/GuiSearch.cpp:103
-#, fuzzy
+#: src/frontends/qt/ui/SearchUi.ui:251 src/frontends/qt/GuiSearch.cpp:104
 msgid "Selection onl&y"
-msgstr "Избраните елементи|И"
+msgstr "Само избрания текст"
 
-#: src/frontends/qt/ui/SearchUi.ui:234
+#: src/frontends/qt/ui/SearchUi.ui:258
 msgid "If this is checked, LyX will search forward immediately"
 msgstr ""
 
-#: src/frontends/qt/ui/SearchUi.ui:237 src/frontends/qt/GuiSearch.cpp:105
-#, fuzzy
+#: src/frontends/qt/ui/SearchUi.ui:261 src/frontends/qt/GuiSearch.cpp:106
 msgid "Search as yo&u type"
 msgstr "&Търсене докато се пише"
 
-#: src/frontends/qt/ui/SearchUi.ui:244
+#: src/frontends/qt/ui/SearchUi.ui:268
 msgid "If the end/start of the document is reached, automatically wrap around"
 msgstr ""
 
-#: src/frontends/qt/ui/SearchUi.ui:247 src/frontends/qt/GuiSearch.cpp:107
+#: src/frontends/qt/ui/SearchUi.ui:271 src/frontends/qt/GuiSearch.cpp:108
 #, fuzzy
 msgid "&Wrap"
 msgstr "плаващ в текста: "
 
 #: src/frontends/qt/ui/SendtoUi.ui:50
 msgid "Process the converted file with this command ($$FName = file name)"
-msgstr ""
+msgstr "Обработване на конвертирания файл с тази команда ($$FName = име_на_файл)"
 
 # src/frontends/xforms/form_preferences.C:761
 #: src/frontends/qt/ui/SendtoUi.ui:95
-#, fuzzy
 msgid "Export for&mats:"
-msgstr "&Поддържани формати за експорт:"
+msgstr "&Формати за експорт:"
 
 # src/LyXSendto.C:40
 #: src/frontends/qt/ui/SendtoUi.ui:105
-#, fuzzy
 msgid "Send exported file to &command:"
-msgstr "Подаване на експортирания документ към следната команда:"
+msgstr "Подаване на експортирания файл към командаjd:"
 
 #: src/frontends/qt/ui/ShortcutUi.ui:14
 msgid "Edit shortcut"
-msgstr ""
+msgstr "Редактиране на препратка"
 
 # src/mathed/math_forms.C:22
 #: src/frontends/qt/ui/ShortcutUi.ui:23
@@ -6121,13 +6101,12 @@ msgstr "Функция:"
 
 #: src/frontends/qt/ui/ShortcutUi.ui:33
 msgid "Enter LyX function or command sequence"
-msgstr ""
+msgstr "Въвеждане на LyX функция или последователност от команди"
 
 # src/ext_l10n.h:375
 #: src/frontends/qt/ui/ShortcutUi.ui:43
-#, fuzzy
 msgid "Short&cut:"
-msgstr "Подзаглавие"
+msgstr "Препратка:"
 
 #: src/frontends/qt/ui/ShortcutUi.ui:56
 msgid ""
@@ -6142,13 +6121,12 @@ msgstr ""
 # src/frontends/xforms/form_preferences.C:600
 # src/frontends/xforms/form_preferences.C:687
 #: src/frontends/qt/ui/ShortcutUi.ui:69
-#, fuzzy
 msgid "&Delete Key"
-msgstr "Изтрий(D)|#D"
+msgstr "Изтриване на ключ"
 
 #: src/frontends/qt/ui/ShortcutUi.ui:76
 msgid "Clear current shortcut"
-msgstr ""
+msgstr "Изчистване на текущата препратка"
 
 # src/lyx_gui_misc.C:430
 #: src/frontends/qt/ui/ShortcutUi.ui:79 src/frontends/qt/ui/TabularUi.ui:1106
@@ -6159,95 +6137,107 @@ msgstr "Премахване"
 #: src/frontends/qt/ui/SpellcheckerUi.ui:20
 #: src/frontends/qt/GuiSpellchecker.cpp:273
 #: src/frontends/qt/GuiSpellchecker.cpp:280
-#: src/frontends/qt/GuiSpellchecker.cpp:559
+#: src/frontends/qt/GuiSpellchecker.cpp:587
 msgid "Spell Checker"
 msgstr "Проверка на правописа"
 
-# src/lyx_cb.C:230
-#: src/frontends/qt/ui/SpellcheckerUi.ui:29
-#, fuzzy
-msgid "Replace with selected word"
-msgstr "Да го заменя ли с текущия документ?"
-
-# src/lyx_cb.C:230
-#: src/frontends/qt/ui/SpellcheckerUi.ui:45
-#, fuzzy
-msgid "Replace word with current choice"
-msgstr "Да го заменя ли с текущия документ?"
-
-# src/sp_form.C:86
-#: src/frontends/qt/ui/SpellcheckerUi.ui:48
-#: src/frontends/qt/ui/ThesaurusUi.ui:86
-msgid "&Replace"
-msgstr "Замяна"
-
-#: src/frontends/qt/ui/SpellcheckerUi.ui:73
+#: src/frontends/qt/ui/SpellcheckerUi.ui:44
 msgid ""
 "The checked language. Switching this alters the language of the checked word."
 msgstr ""
 
 # src/support/getUserName.C:13
-#: src/frontends/qt/ui/SpellcheckerUi.ui:82
-#, fuzzy
+#: src/frontends/qt/ui/SpellcheckerUi.ui:60
 msgid "Unknown &word:"
 msgstr "Непозната дума:"
 
-#: src/frontends/qt/ui/SpellcheckerUi.ui:92
+#: src/frontends/qt/ui/SpellcheckerUi.ui:70
 msgid "Current word"
-msgstr ""
+msgstr "Текуща дума"
+
+#: src/frontends/qt/ui/SpellcheckerUi.ui:77
+msgid "Skip this match and go to next misspelling"
+msgstr "Пропускане на това съвпадение и отиване до следващата грешка"
+
+#: src/frontends/qt/ui/SpellcheckerUi.ui:80
+msgid "S&kip"
+msgstr "Пропускане"
 
 # src/sp_form.C:86
-#: src/frontends/qt/ui/SpellcheckerUi.ui:99
-#, fuzzy
+#: src/frontends/qt/ui/SpellcheckerUi.ui:87
 msgid "Repla&cement:"
 msgstr "Заместване:"
 
+#: src/frontends/qt/ui/SpellcheckerUi.ui:97
+msgid "Skips all occurrences of this word within the current session."
+msgstr ""
+
+#: src/frontends/qt/ui/SpellcheckerUi.ui:100
+msgid "Skip A&ll"
+msgstr "Пропускане на всичко"
+
+# src/lyx_cb.C:230
+#: src/frontends/qt/ui/SpellcheckerUi.ui:110
+msgid "Replace with selected word"
+msgstr "Замяна с избраната дума"
+
+# src/lyx_cb.C:230
+#: src/frontends/qt/ui/SpellcheckerUi.ui:126
+msgid "Replace word with current choice"
+msgstr "Замяна на дума с текущия избор"
+
+# src/sp_form.C:86
+#: src/frontends/qt/ui/SpellcheckerUi.ui:129
+#: src/frontends/qt/ui/ThesaurusUi.ui:86
+msgid "&Replace"
+msgstr "Замяна"
+
 # src/ext_l10n.h:323
-#: src/frontends/qt/ui/SpellcheckerUi.ui:115
-#, fuzzy
+#: src/frontends/qt/ui/SpellcheckerUi.ui:142
 msgid "S&uggestions:"
-msgstr "Въпрос"
+msgstr "Предложения:"
+
+# src/lyx_cb.C:230
+#: src/frontends/qt/ui/SpellcheckerUi.ui:152
+msgid "Replace all occurrences of the word in the document with current choice"
+msgstr "Замяна на всички съвпадения на думата в документа с текущия избор"
 
 # src/form1.C:314
-#: src/frontends/qt/ui/SpellcheckerUi.ui:128
-#, fuzzy
+#: src/frontends/qt/ui/SpellcheckerUi.ui:155
 msgid "Re&place All"
 msgstr "Замяна на &всички"
 
-# src/sp_form.C:95
-#: src/frontends/qt/ui/SpellcheckerUi.ui:145
-#, fuzzy
-msgid "Add the word to your personal dictionary"
-msgstr "Вмъкни в личния речник(I)|#I"
-
-# src/spellchecker.C:717
-#: src/frontends/qt/ui/SpellcheckerUi.ui:148
-#, fuzzy
-msgid "&Add[[Spellchecker]]"
-msgstr "Правопис"
-
-# src/sp_form.C:97
-#: src/frontends/qt/ui/SpellcheckerUi.ui:171
-#, fuzzy
-msgid "Ignore this word"
-msgstr "Игнорирай(g)|#g"
+#: src/frontends/qt/ui/SpellcheckerUi.ui:165
+msgid "Ignore this occurrence of the word permanently"
+msgstr "Пропускане на това съвпадение на думата постоянно"
 
-#: src/frontends/qt/ui/SpellcheckerUi.ui:174
+#: src/frontends/qt/ui/SpellcheckerUi.ui:168
 msgid "Ign&ore"
-msgstr ""
+msgstr "Пропускане"
 
-# src/sp_form.C:99
-#: src/frontends/qt/ui/SpellcheckerUi.ui:181
-#, fuzzy
-msgid "Ignore this word throughout this session"
-msgstr "Приеми думата за тази сесия(A)|#A"
+#: src/frontends/qt/ui/SpellcheckerUi.ui:175
+msgid ""
+"Ignore all occurrences of this word within this document. This persists "
+"beyond the current session."
+msgstr ""
+"Пропускане на всички съвпадения на тази дума в документа. Това продължава "
+"и след текущата сесия."
 
 # src/lyxfont.C:43 src/lyxfont.C:47 src/lyxfont.C:52 src/lyxfont.C:58
 # src/lyxfont.C:62
-#: src/frontends/qt/ui/SpellcheckerUi.ui:184
-#, fuzzy
+#: src/frontends/qt/ui/SpellcheckerUi.ui:178
 msgid "I&gnore All"
-msgstr "Игнорирай"
+msgstr "Пропускане на всички"
+
+# src/sp_form.C:95
+#: src/frontends/qt/ui/SpellcheckerUi.ui:185
+msgid "Add the word to your personal dictionary"
+msgstr "Добавяне на дума във вашия личен речник"
+
+# src/spellchecker.C:717
+#: src/frontends/qt/ui/SpellcheckerUi.ui:188
+msgid "&Add[[Spellchecker]]"
+msgstr "Добавяне"
 
 #: src/frontends/qt/ui/SymbolsUi.ui:40
 msgid ""
@@ -6264,7 +6254,7 @@ msgstr "&Категория:"
 
 #: src/frontends/qt/ui/SymbolsUi.ui:73
 msgid "Select this to display all available characters at once"
-msgstr ""
+msgstr "Избиране за показване на всички налични знаци наведнъж"
 
 # src/frontends/xforms/FormGraphics.C:36
 # src/frontends/xforms/FormGraphics.C:359
@@ -6274,9 +6264,8 @@ msgstr "&Показване на всички"
 
 # src/insets/insetbib.C:340
 #: src/frontends/qt/ui/TabularCreateUi.ui:121
-#, fuzzy
 msgid "&Style:"
-msgstr "Стил"
+msgstr "&Стил:"
 
 # src/LColor.C:78
 #: src/frontends/qt/ui/TabularUi.ui:33
@@ -6364,7 +6353,7 @@ msgstr "градуса"
 # src/lyxfunc.C:3156 src/lyxfunc.C:3212 src/lyxfunc.C:3288
 #: src/frontends/qt/ui/TabularUi.ui:302
 msgid "Column settings"
-msgstr "Настройки на колоната"
+msgstr "Настройки на колона"
 
 #: src/frontends/qt/ui/TabularUi.ui:313
 msgid ""
@@ -6372,41 +6361,41 @@ msgid ""
 "text width</p><p>* Variable: Adjust to match table width</p><p>* Custom: "
 "Fixed custom width</p></body></html>"
 msgstr ""
-"<html><head/><body><p>Начин на задаване на ширината:</p><p>* според "
-"дължината на текста: разпъване за да обхване текста</p><p>* променлива: "
-"нагласяване според ширината на таблицата</p><p>* потребителска: зададена "
-"фиксирана ширина</p></body></html>"
+"<html><head/><body><p>Начин на задаване на ширината:</p><p>* обхваща "
+"текста: разтягане докато се обхване текста</p><p>* разтягане: "
+"разтягане до запълване на свободното пространство</p><p>* фиксирана: "
+"зададена от потребиталя фиксирана ширина</p></body></html>"
 
 # src/ext_l10n.h:126
 #: src/frontends/qt/ui/TabularUi.ui:317
 msgid "Text length"
-msgstr "дължина на текста"
+msgstr "обхваща текста"
 
 # src/LColor.C:97
 #: src/frontends/qt/ui/TabularUi.ui:322
 msgid "Variable[[Width]]"
-msgstr "променлива"
+msgstr "разтягане"
 
 # src/mathed/math_forms.C:140
 #: src/frontends/qt/ui/TabularUi.ui:327
 msgid "Custom[[Width]]"
-msgstr "потребителска"
+msgstr "фиксирана"
 
 # src/mathed/math_forms.C:152
 #: src/frontends/qt/ui/TabularUi.ui:335
 msgid "Horizontal alignment in column"
-msgstr "Хоризонтално подравняване на съдържанието в клетката"
+msgstr "Хоризонтално подравняване на колоната"
 
 #: src/frontends/qt/ui/TabularUi.ui:339 src/frontends/qt/GuiParagraph.cpp:114
-#: src/frontends/qt/GuiTabular.cpp:1040
+#: src/frontends/qt/GuiTabular.cpp:1046
 msgid "Justified"
 msgstr "двустранно"
 
 # src/frontends/xforms/form_document.C:244
-#: src/frontends/qt/ui/TabularUi.ui:359 src/frontends/qt/GuiTabular.cpp:243
-#: src/frontends/qt/GuiTabular.cpp:1042
+#: src/frontends/qt/ui/TabularUi.ui:359 src/frontends/qt/GuiTabular.cpp:249
+#: src/frontends/qt/GuiTabular.cpp:1048
 msgid "At Decimal Separator"
-msgstr "при десетичния разделител"
+msgstr "при разделителя"
 
 # src/mathed/math_forms.C:152
 #: src/frontends/qt/ui/TabularUi.ui:390
@@ -6429,7 +6418,7 @@ msgstr "&Верт. подравняване в реда:"
 # src/ext_l10n.h:141
 #: src/frontends/qt/ui/TabularUi.ui:437
 msgid "Custom width of the column"
-msgstr "Зададена от потребителя ширина на колона"
+msgstr "От потребителя зададена ширина на колона"
 
 # src/frontends/xforms/form_preferences.C:221
 #: src/frontends/qt/ui/TabularUi.ui:457
@@ -6459,7 +6448,7 @@ msgstr "Конфигуриране формата на колоната с па
 # src/frontends/xforms/form_tabular.C:349
 #: src/frontends/qt/ui/TabularUi.ui:566
 msgid "&Borders"
-msgstr "&Рамки"
+msgstr "&Кантове"
 
 # src/frontends/xforms/form_tabular.C:99
 #: src/frontends/qt/ui/TabularUi.ui:572
@@ -6468,13 +6457,13 @@ msgstr "Видими кантове"
 
 #: src/frontends/qt/ui/TabularUi.ui:1071
 msgid "Set borders of the current (selected) cell(s)"
-msgstr "Задаване на кантовете на текущо избраните клетки"
+msgstr "Поставяне на кантове на избраните клетки"
 
 # src/frontends/xforms/form_tabular.C:223
 # src/frontends/xforms/form_tabular.C:349
 #: src/frontends/qt/ui/TabularUi.ui:1084
 msgid "All Borders"
-msgstr "Всички рамки"
+msgstr "Всички кантове"
 
 #: src/frontends/qt/ui/TabularUi.ui:1093
 msgid "Set all borders of the current (selected) cell(s)"
@@ -6503,22 +6492,22 @@ msgstr "По подразбиране"
 msgid ""
 "If this is checked, the table will be reset to the formal default style "
 "(only top and bottom row have horizontal lines)"
-msgstr "Ако е активирана тази отметка "
+msgstr "Ако е активирана тази отметка, таблицата ще се възстанови до "
+"формалния стил по подразбиране - само горния и долния ред имат хориз. линии"
 
 # src/frontends/xforms/form_preferences.C:221
 #: src/frontends/qt/ui/TabularUi.ui:1138
-#, fuzzy
 msgid "Use Default &Formal Style"
-msgstr "Стандартен размер на лист"
+msgstr "Използване на формален стил по подразбиране"
 
 #: src/frontends/qt/ui/TabularUi.ui:1145
 msgid "Use formal (a.k.a. booktabs) border style (no vertical borders)"
-msgstr "Използване на официален стил (без вертикални кантове)"
+msgstr "Използване на формален стил таблица (без вертикални кантове)"
 
 # src/frontends/kde/paraextradlg.C:25 src/lyxfont.C:56
 #: src/frontends/qt/ui/TabularUi.ui:1148
 msgid "Fo&rmal"
-msgstr "Официален"
+msgstr "Формален"
 
 # src/frontends/xforms/form_paragraph.C:153
 #: src/frontends/qt/ui/TabularUi.ui:1177
@@ -6527,12 +6516,12 @@ msgstr "Допълнително разстояние"
 
 #: src/frontends/qt/ui/TabularUi.ui:1183
 msgid "T&op of row:"
-msgstr "Отгоре на реда:"
+msgstr "Над реда:"
 
 # src/frontends/xforms/form_paragraph.C:244
 #: src/frontends/qt/ui/TabularUi.ui:1243
 msgid "Botto&m of row:"
-msgstr "Отдолу на реда:"
+msgstr "Под реда:"
 
 #: src/frontends/qt/ui/TabularUi.ui:1256
 msgid "Bet&ween rows:"
@@ -6555,7 +6544,7 @@ msgstr "Пренасяне на нова страница"
 # src/form1.C:129 src/sp_form.C:58
 #: src/frontends/qt/ui/TabularUi.ui:1324
 msgid "Row settings"
-msgstr "Настройки на реда"
+msgstr "Настройки на ред"
 
 # src/ext_l10n.h:362
 #: src/frontends/qt/ui/TabularUi.ui:1330
@@ -6593,7 +6582,7 @@ msgstr ""
 # src/ext_l10n.h:398
 #: src/frontends/qt/ui/TabularUi.ui:1368 src/frontends/qt/ui/TabularUi.ui:1405
 #: src/frontends/qt/ui/TabularUi.ui:1446 src/frontends/qt/ui/TabularUi.ui:1477
-#: src/frontends/qt/ui/TabularUi.ui:1515 src/frontends/qt/GuiToolbar.cpp:641
+#: src/frontends/qt/ui/TabularUi.ui:1515 src/frontends/qt/GuiToolbar.cpp:654
 #: src/insets/InsetBranch.cpp:79 src/insets/InsetBranch.cpp:82
 msgid "on"
 msgstr "вкл."
@@ -6681,7 +6670,7 @@ msgstr "Подравняване на таблицата"
 
 #: src/frontends/qt/ui/TabularUi.ui:1599
 msgid "Current cell:"
-msgstr "Текуща клетка:"
+msgstr "Избрана клетка:"
 
 # src/ext_l10n.h:320
 #: src/frontends/qt/ui/TabularUi.ui:1621
@@ -6901,7 +6890,7 @@ msgstr "Преместване на избрания елемент нагоре
 
 #: src/frontends/qt/ui/TocUi.ui:203
 msgid "Adjust the depth of the navigation tree"
-msgstr ""
+msgstr "Нагласяне дълбочината на навигационното дърво"
 
 # src/frontends/kde/refdlg.C:57
 #: src/frontends/qt/ui/TocUi.ui:257
@@ -6922,28 +6911,27 @@ msgid ""
 "Filter items that are not output (in notes, inactive branches, deleted in "
 "change tracking, etc.)"
 msgstr ""
+"Филтриране на елементи, които не са активни - в бележки, неактивни разклонения, "
+"изтрити промени и др."
 
 # src/exporter.C:91
-#: src/frontends/qt/ui/TocUi.ui:317
-#, fuzzy
+#: src/frontends/qt/ui/TocUi.ui:317 src/frontends/qt/TocWidget.cpp:88
 msgid "All items"
-msgstr "всички файлове"
+msgstr "всички елементи"
 
 # src/ext_l10n.h:75
 #: src/frontends/qt/ui/TocUi.ui:322
-#, fuzzy
 msgid "Only output items"
-msgstr "Изтрий колона(D)|D"
+msgstr "само активни елементи"
 
 # src/ext_l10n.h:75
 #: src/frontends/qt/ui/TocUi.ui:327
-#, fuzzy
 msgid "Only non-output items"
-msgstr "Изтрий колона(D)|D"
+msgstr "само неактивни елементи"
 
 #: src/frontends/qt/ui/TocUi.ui:335
 msgid "Sho&w:"
-msgstr ""
+msgstr "&Покажи:"
 
 #: src/frontends/qt/ui/TocUi.ui:358
 msgid ""
@@ -6954,14 +6942,13 @@ msgstr ""
 
 # src/frontends/kde/FormIndex.C:96
 #: src/frontends/qt/ui/ToggleWarningUi.ui:14
-#, fuzzy
 msgid "Enter text"
-msgstr "LyX: Въвеждане на текст"
+msgstr "Въвеждане на текст"
 
 #: src/frontends/qt/ui/ToggleWarningUi.ui:62
 #: src/frontends/qt/GuiProgress.cpp:194
 msgid "If you check this, LyX will not warn you again in the given case."
-msgstr ""
+msgstr "Ако отметнете това LyX няма да ви предупреждава повече за този случай."
 
 #: src/frontends/qt/ui/ToggleWarningUi.ui:65
 #: src/frontends/qt/GuiProgress.cpp:193
@@ -6979,33 +6966,31 @@ msgid "DefSkip"
 msgstr "разстояние по подразбиране"
 
 # src/frontends/kde/parageneraldlg.C:39 src/frontends/kde/parageneraldlg.C:46
-#: src/frontends/qt/ui/VSpaceUi.ui:88 src/frontends/qt/GuiDocument.cpp:862
+#: src/frontends/qt/ui/VSpaceUi.ui:88 src/frontends/qt/GuiDocument.cpp:870
 msgid "SmallSkip"
 msgstr "малко разстояние"
 
 # src/frontends/kde/parageneraldlg.C:40 src/frontends/kde/parageneraldlg.C:47
-#: src/frontends/qt/ui/VSpaceUi.ui:93 src/frontends/qt/GuiDocument.cpp:863
+#: src/frontends/qt/ui/VSpaceUi.ui:93 src/frontends/qt/GuiDocument.cpp:871
 msgid "MedSkip"
 msgstr "средно разстояние"
 
 # src/frontends/kde/parageneraldlg.C:41 src/frontends/kde/parageneraldlg.C:48
-#: src/frontends/qt/ui/VSpaceUi.ui:98 src/frontends/qt/GuiDocument.cpp:864
+#: src/frontends/qt/ui/VSpaceUi.ui:98 src/frontends/qt/GuiDocument.cpp:872
 msgid "BigSkip"
 msgstr "голямо разстояние"
 
 # src/ext_l10n.h:65
 #: src/frontends/qt/ui/VSpaceUi.ui:103 src/VSpace.cpp:201
-#: src/frontends/qt/GuiDocument.cpp:860
-#, fuzzy
+#: src/frontends/qt/GuiDocument.cpp:868
 msgid "Half line height"
-msgstr "основата вдясно"
+msgstr "половин ред височина"
 
 # src/form1.C:157 src/frontends/xforms/form_graphics.C:46
 #: src/frontends/qt/ui/VSpaceUi.ui:108 src/VSpace.cpp:204
-#: src/frontends/qt/GuiDocument.cpp:861
-#, fuzzy
+#: src/frontends/qt/GuiDocument.cpp:869
 msgid "Line height"
-msgstr "&Височина"
+msgstr "един ред височина"
 
 # src/frontends/kde/parageneraldlg.C:42 src/frontends/kde/parageneraldlg.C:49
 #: src/frontends/qt/ui/VSpaceUi.ui:113
@@ -7019,7 +7004,7 @@ msgstr "&Формат:"
 
 #: src/frontends/qt/ui/ViewSourceUi.ui:114
 msgid "Automatic update"
-msgstr "Автоматично опресняване"
+msgstr "Автоматична актуализация"
 
 #: src/frontends/qt/ui/ViewSourceUi.ui:130
 msgid "Show the source as the master document gets it"
@@ -7054,23 +7039,21 @@ msgid "Select the output format"
 msgstr "Избиране на изходния формат на документа"
 
 # src/sp_form.C:86
-#: src/frontends/qt/ui/WorkAreaUi.ui:82 src/frontends/qt/GuiView.cpp:3530
-#: src/frontends/qt/GuiView.cpp:4234
+#: src/frontends/qt/ui/WorkAreaUi.ui:82 src/frontends/qt/GuiView.cpp:3722
+#: src/frontends/qt/GuiView.cpp:4426
 msgid "&Reload"
 msgstr "&Презареждане"
 
 # src/lyxfont.C:43 src/lyxfont.C:47 src/lyxfont.C:52 src/lyxfont.C:58
 # src/lyxfont.C:62
 #: src/frontends/qt/ui/WorkAreaUi.ui:89
-#, fuzzy
 msgid "&Ignore"
-msgstr "Игнорирай"
+msgstr "Пропускане"
 
 # src/frontends/xforms/form_paragraph.C:153
 #: src/frontends/qt/ui/WrapUi.ui:33
-#, fuzzy
 msgid "Horizontal placement"
-msgstr "Интервал"
+msgstr "Хориз. поставяне"
 
 # src/ext_l10n.h:133
 #: src/frontends/qt/ui/WrapUi.ui:37
@@ -7084,7 +7067,7 @@ msgstr "вътрешно"
 
 #: src/frontends/qt/ui/WrapUi.ui:60
 msgid "Check this to allow flexible placement"
-msgstr ""
+msgstr "Отметка за позволяване на произволно поставяне"
 
 #: src/frontends/qt/ui/WrapUi.ui:63
 msgid "Allow &floating"
@@ -7092,15 +7075,14 @@ msgstr ""
 
 #: src/frontends/qt/ui/WrapUi.ui:70
 msgid "Wid&th:"
-msgstr ""
+msgstr "Ширина:"
 
 # src/form1.C:161 src/frontends/kde/dlg/paraextradlgdata.C:91
 # src/frontends/xforms/form_graphics.C:44
 # src/frontends/xforms/form_paragraph.C:219
 #: src/frontends/qt/ui/WrapUi.ui:108
-#, fuzzy
 msgid "Unit of width value"
-msgstr "Ширина"
+msgstr "Мерна единица за ширина"
 
 #: src/frontends/qt/ui/WrapUi.ui:115
 msgid "use overhang"
@@ -7124,9 +7106,8 @@ msgstr ""
 
 # src/frontends/kde/printdlg.C:31
 #: src/frontends/qt/ui/WrapUi.ui:169
-#, fuzzy
 msgid "use number of lines"
-msgstr "Брой копия за печат"
+msgstr "използване номера на редове"
 
 # src/mathed/math_panel.C:128
 #: src/frontends/qt/ui/WrapUi.ui:172
@@ -7136,20 +7117,20 @@ msgstr "Разстояние"
 
 # src/frontends/kde/printdlg.C:31
 #: src/frontends/qt/ui/WrapUi.ui:182
-#, fuzzy
 msgid "number of needed lines"
-msgstr "Брой копия за печат"
+msgstr "брой необходими редове"
 
 #: lib/citeengines/basic.citeengine:2
-#, fuzzy
 msgid "Basic (BibTeX)"
-msgstr "арабски (ArabTeX)"
+msgstr "Обикновена (BibTeX)"
 
 #: lib/citeengines/basic.citeengine:6
 msgid ""
 "The basic citation capabilities provided by BibTeX. Mainly simple numeric "
 "styles primarily suitable for science and maths."
 msgstr ""
+"Основни възможности зо цитиране осигурени от Бибтех (BibTeX). Главно прости "
+"числови стилове удобни за математика и др. науки."
 
 # src/ext_l10n.h:375
 #: lib/citeengines/basic.citeengine:52
@@ -7200,19 +7181,22 @@ msgid ""
 "than normal Biblatex. As with normal Biblatex, the use of 'biber' as "
 "Bibliography processor is advised."
 msgstr ""
+"Варианта BibLaTeX поддържа команди за Natbib цитати и така е най-удобен за "
+"преминаване от Natbib (или по-стари версии  от LyX 2.3) към Biblatex. "
+"Програмата Natbib поддържа малко по-различни и няколко допълнителни стила "
+"от нормалния Biblatex. Както и при обичайния Biblatex за билиографска програма "
+"се препоръчва използването на „biber“."
 
 # src/ext_l10n.h:82
 #: lib/citeengines/biblatex-natbib.citeengine:143
 #: lib/citeengines/biblatex.citeengine:133 lib/layouts/numreport.inc:42
 #: lib/layouts/stdcounters.inc:86
-#, fuzzy
 msgid "Footnote"
-msgstr "Бележки под черта"
+msgstr "Бележка под черта"
 
 # src/ext_l10n.h:246
 #: lib/citeengines/biblatex-natbib.citeengine:144
 #: lib/citeengines/biblatex.citeengine:134
-#, fuzzy
 msgid "Foot"
 msgstr "Бел. под черта"
 
@@ -7220,16 +7204,14 @@ msgstr "Бел. под черта"
 #: lib/citeengines/biblatex-natbib.citeengine:145
 #: lib/citeengines/biblatex.citeengine:135
 #: lib/citeengines/jurabib.citeengine:125
-#, fuzzy
 msgid "bibliography entry"
-msgstr "Библиография"
+msgstr "библиографски запис"
 
 # src/ext_l10n.h:186
 #: lib/citeengines/biblatex-natbib.citeengine:146
 #: lib/citeengines/biblatex.citeengine:136 lib/layouts/tufte-book.layout:30
-#, fuzzy
 msgid "Full bibliography entry."
-msgstr "Библиография"
+msgstr "Пълен библиографски запис."
 
 #: lib/citeengines/biblatex-natbib.citeengine:147
 #: lib/citeengines/biblatex.citeengine:137
@@ -7269,9 +7251,8 @@ msgstr "Горен индекс"
 
 # src/BufferView2.C:601 src/LyXAction.C:346 src/MenuBackend.C:433
 #: lib/citeengines/biblatex.citeengine:2 src/insets/InsetBibtex.cpp:148
-#, fuzzy
 msgid "Biblatex"
-msgstr "Залепи"
+msgstr "Библатех (BibLaTeX)"
 
 #: lib/citeengines/biblatex.citeengine:8
 msgid ""
@@ -7280,19 +7261,22 @@ msgid ""
 "many features that are not possible with BibTeX. The use of 'biber' as "
 "bibliography processor is advised."
 msgstr ""
+"Библатех поддържа много автор-година и числови стилове. Насочен е главно към "
+"хуманитарните науки. Поддържа много настройки, напълно локализиран е и осигурява "
+"много функции, които не са достъпни с Бибтех (BibTeX). Препоръчва се "
+"използването на „biber“ като библиографски компилатор."
 
 #: lib/citeengines/biblatex.citeengine:140
 msgid "S&horten author list[[Possible substitute to All aut&hors]]"
-msgstr ""
+msgstr "Кратък списък с автори"
 
 #: lib/citeengines/biblatex.citeengine:141
 msgid "Force a short author list (using et al.)"
-msgstr ""
+msgstr "Налагане на кратък списък с автори използвайки „и др.“."
 
 #: lib/citeengines/jurabib.citeengine:2
-#, fuzzy
 msgid "Jurabib (BibTeX)"
-msgstr "арабски (ArabTeX)"
+msgstr "Jurabib (BibTeX)"
 
 #: lib/citeengines/jurabib.citeengine:7
 msgid ""
@@ -7300,28 +7284,27 @@ msgid ""
 "studies and the Humanities. It includes localizations for English, German, "
 "French, Dutch, Spanish and Italian."
 msgstr ""
+"Jurabib поддържа набор от автор-година стилове за цитиране главно удобни за "
+"юридическа литература и хуманитарни науки. Включва адаптация за английски, "
+"немски, френски, холандски, испански и италиански."
 
 # src/ext_l10n.h:186
 #: lib/citeengines/jurabib.citeengine:126
-#, fuzzy
 msgid "Bibliography entry."
-msgstr "Библиография"
+msgstr "Библиографски запис."
 
 #: lib/citeengines/jurabib.citeengine:127
-#, fuzzy
 msgid "before"
-msgstr "Текст преди(T)|#T"
+msgstr "преди"
 
 # src/ext_l10n.h:375
 #: lib/citeengines/jurabib.citeengine:128
-#, fuzzy
 msgid "short title"
-msgstr "Подзаглавие"
+msgstr "кратко заглавие"
 
 #: lib/citeengines/natbib.citeengine:2
-#, fuzzy
 msgid "Natbib (BibTeX)"
-msgstr "арабски (ArabTeX)"
+msgstr "Natbib (BibTeX)"
 
 #: lib/citeengines/natbib.citeengine:8
 msgid ""
@@ -7333,7 +7316,7 @@ msgstr ""
 
 #: lib/layouts/AEA.layout:3 lib/examples/Articles:0
 msgid "American Economic Association (AEA)"
-msgstr ""
+msgstr "Американска икономическа асоциация (AEA)"
 
 # src/frontends/xforms/form_paragraph.C:153
 #: lib/layouts/AEA.layout:4 lib/layouts/IEEEtran-CompSoc.layout:4
@@ -7372,9 +7355,8 @@ msgstr "Статии"
 
 # src/ext_l10n.h:375
 #: lib/layouts/AEA.layout:50 lib/layouts/apa.layout:109 lib/layouts/apax.inc:54
-#, fuzzy
 msgid "ShortTitle"
-msgstr "Подзаглавие"
+msgstr "Кратко заглавие"
 
 # падащ списък на контекста
 #: lib/layouts/AEA.layout:51 lib/layouts/AEA.layout:130
@@ -7471,59 +7453,51 @@ msgstr "предни части"
 
 # src/frontends/xforms/form_document.C:244
 #: lib/layouts/AEA.layout:61
-#, fuzzy
 msgid "Publication Month"
-msgstr "Абзац разделяне"
+msgstr "Месец на публекация"
 
 # src/frontends/xforms/form_document.C:244
 #: lib/layouts/AEA.layout:67
-#, fuzzy
 msgid "Publication Month:"
-msgstr "Абзац разделяне"
+msgstr "Месец на публикация:"
 
 # src/frontends/xforms/form_document.C:244
 #: lib/layouts/AEA.layout:79
-#, fuzzy
 msgid "Publication Year"
-msgstr "Абзац разделяне"
+msgstr "Година на публикация"
 
 # src/frontends/xforms/form_document.C:244
 #: lib/layouts/AEA.layout:82
-#, fuzzy
 msgid "Publication Year:"
-msgstr "Абзац разделяне"
+msgstr "Година на публикация:"
 
 # src/frontends/xforms/form_document.C:244
 #: lib/layouts/AEA.layout:90
-#, fuzzy
 msgid "Publication Volume"
-msgstr "Абзац разделяне"
+msgstr "Том на публикация"
 
 # src/frontends/xforms/form_document.C:244
 #: lib/layouts/AEA.layout:93
-#, fuzzy
 msgid "Publication Volume:"
-msgstr "Абзац разделяне"
+msgstr "Том на публикация:"
 
 # src/frontends/xforms/form_document.C:244
 #: lib/layouts/AEA.layout:99
-#, fuzzy
 msgid "Publication Issue"
-msgstr "Абзац разделяне"
+msgstr "Издание на публикация"
 
 # src/frontends/xforms/form_document.C:244
 #: lib/layouts/AEA.layout:102
-#, fuzzy
 msgid "Publication Issue:"
-msgstr "Абзац разделяне"
+msgstr "Издание на публикация:"
 
 #: lib/layouts/AEA.layout:109
 msgid "JEL"
-msgstr ""
+msgstr "JEL"
 
 #: lib/layouts/AEA.layout:112
 msgid "JEL:"
-msgstr ""
+msgstr "JEL:"
 
 # src/ext_l10n.h:263
 #: lib/layouts/AEA.layout:115 lib/layouts/IEEEtran-CompSoc.layout:55
@@ -7624,20 +7598,19 @@ msgstr "Резюме"
 #: lib/layouts/theorems-ams-extended.module:348
 #: lib/layouts/theorems-counters-extended-bytype.inc:28
 msgid "Acknowledgement"
-msgstr "Признателност"
+msgstr "Благодарност"
 
 #: lib/layouts/AEA.layout:131 lib/layouts/egs.layout:627
 #: lib/layouts/theorems-ams-extended-bytype.module:349
 #: lib/layouts/theorems-ams-extended-chap-bytype.module:420
 #: lib/layouts/theorems-ams-extended.module:339
 msgid "Acknowledgement."
-msgstr "Признателност."
+msgstr "Благодарност."
 
 # src/ext_l10n.h:244
 #: lib/layouts/AEA.layout:140
-#, fuzzy
 msgid "Figure Notes"
-msgstr "Фигура"
+msgstr "Текст на изображение"
 
 # src/BufferView2.C:601 src/LyXAction.C:346 src/MenuBackend.C:433
 # падащ списък на контекста
@@ -7648,10 +7621,10 @@ msgstr "Фигура"
 #: lib/layouts/acmsiggraph-0-92.layout:44 lib/layouts/acmsiggraph.layout:36
 #: lib/layouts/agutex.layout:33 lib/layouts/amsart.layout:33
 #: lib/layouts/amsbook.layout:34 lib/layouts/apa.layout:26
-#: lib/layouts/apax.inc:22 lib/layouts/beamer.layout:65
-#: lib/layouts/beamer.layout:1209 lib/layouts/beamer.layout:1236
-#: lib/layouts/beamer.layout:1263 lib/layouts/beamer.layout:1388
-#: lib/layouts/beamer.layout:1425 lib/layouts/broadway.layout:179
+#: lib/layouts/apax.inc:22 lib/layouts/beamer.layout:67
+#: lib/layouts/beamer.layout:1211 lib/layouts/beamer.layout:1238
+#: lib/layouts/beamer.layout:1265 lib/layouts/beamer.layout:1390
+#: lib/layouts/beamer.layout:1427 lib/layouts/broadway.layout:179
 #: lib/layouts/cl2emult.layout:152 lib/layouts/db_stdclass.inc:17
 #: lib/layouts/dtk.layout:33 lib/layouts/egs.layout:20
 #: lib/layouts/elsart.layout:51 lib/layouts/elsarticle.layout:36
@@ -7679,49 +7652,45 @@ msgstr "Фигура"
 #: lib/layouts/stdlayouts.inc:38 lib/layouts/stdlayouts.inc:63
 #: lib/layouts/stdlayouts.inc:85 lib/layouts/stdletter.inc:13
 #: lib/layouts/svcommon.inc:27 lib/layouts/svcommon.inc:710
-#: lib/layouts/svcommon.inc:721 lib/layouts/tufte-book.layout:236
+#: lib/layouts/svcommon.inc:721 lib/layouts/tufte-book.layout:242
 msgid "MainText"
 msgstr "текст"
 
 # src/ext_l10n.h:244
 #: lib/layouts/AEA.layout:147
-#, fuzzy
 msgid "Figure Note"
-msgstr "Фигура"
+msgstr "Бележка на изображение"
 
 #: lib/layouts/AEA.layout:148 lib/layouts/AEA.layout:175
 msgid "Text of a note in a figure"
-msgstr ""
+msgstr "Текст на бележка в изображение"
 
 # src/ext_l10n.h:291 src/insets/insetinfo.C:77 src/insets/insetinfo.C:102
 # src/insets/insetinfo.C:231
 #: lib/layouts/AEA.layout:156 lib/layouts/apax.inc:240
-#: lib/layouts/beamer.layout:1437 lib/layouts/powerdot.layout:228
+#: lib/layouts/beamer.layout:1439 lib/layouts/powerdot.layout:228
 msgid "Note:"
 msgstr "Бележка:"
 
 # src/LColor.C:97
 #: lib/layouts/AEA.layout:169
-#, fuzzy
 msgid "Table Notes"
-msgstr "ред на таблица"
+msgstr "Бележки в таблица"
 
 # src/LColor.C:97
 #: lib/layouts/AEA.layout:173
-#, fuzzy
 msgid "Table Note"
-msgstr "ред на таблица"
+msgstr "Бележка в таблица"
 
 # src/buffer.C:3331
 #: lib/layouts/AEA.layout:174
-#, fuzzy
 msgid "Text of a note in a table"
-msgstr "Недъзможна е работата с файл: "
+msgstr "Текст на бележка в таблица"
 
 # src/ext_l10n.h:387
 #: lib/layouts/AEA.layout:180 lib/layouts/IEEEtran.layout:49
 #: lib/layouts/acmart.layout:548 lib/layouts/acmart.layout:552
-#: lib/layouts/beamer.layout:1376 lib/layouts/elsart.layout:306
+#: lib/layouts/beamer.layout:1378 lib/layouts/elsart.layout:306
 #: lib/layouts/elsart.layout:310 lib/layouts/foils.layout:248
 #: lib/layouts/heb-article.layout:28 lib/layouts/ijmpc.layout:421
 #: lib/layouts/ijmpd.layout:428 lib/layouts/ijmpd.layout:431
@@ -7914,7 +7883,7 @@ msgid "Conjecture"
 msgstr "Предположение"
 
 #: lib/layouts/AEA.layout:241 lib/layouts/acmart.layout:587
-#: lib/layouts/beamer.layout:1292 lib/layouts/elsart.layout:381
+#: lib/layouts/beamer.layout:1294 lib/layouts/elsart.layout:381
 #: lib/layouts/foils.layout:281 lib/layouts/heb-article.layout:66
 #: lib/layouts/ijmpc.layout:442 lib/layouts/ijmpd.layout:457
 #: lib/layouts/ijmpd.layout:460 lib/layouts/llncs.layout:353
@@ -7964,7 +7933,7 @@ msgstr "Признак"
 
 # src/ext_l10n.h:221
 #: lib/layouts/AEA.layout:256 lib/layouts/acmart.layout:615
-#: lib/layouts/beamer.layout:1330 lib/layouts/elsart.layout:417
+#: lib/layouts/beamer.layout:1332 lib/layouts/elsart.layout:417
 #: lib/layouts/foils.layout:295 lib/layouts/heb-article.layout:86
 #: lib/layouts/llncs.layout:367 lib/layouts/siamltex.layout:128
 #: lib/layouts/svmono.layout:34 lib/layouts/theorems-ams-bytype.inc:180
@@ -7991,7 +7960,7 @@ msgstr "Определение"
 
 # src/ext_l10n.h:232
 #: lib/layouts/AEA.layout:263 lib/layouts/acmart.layout:629
-#: lib/layouts/beamer.layout:1342 lib/layouts/elsart.layout:442
+#: lib/layouts/beamer.layout:1344 lib/layouts/elsart.layout:442
 #: lib/layouts/linguistics.module:18 lib/layouts/llncs.layout:374
 #: lib/layouts/svmono.layout:74 lib/layouts/theorems-ams-bytype.inc:207
 #: lib/layouts/theorems-ams-bytype.inc:217
@@ -8012,7 +7981,7 @@ msgstr "Определение"
 #: lib/layouts/theorems-without-preamble.inc:240
 #: lib/layouts/theorems-without-preamble.inc:243 lib/layouts/theorems.inc:204
 #: lib/layouts/theorems.inc:213 lib/layouts/theorems.inc:216
-#: src/frontends/qt/GuiDocument.cpp:1344
+#: src/frontends/qt/GuiDocument.cpp:1356
 msgid "Example"
 msgstr "Пример"
 
@@ -8044,7 +8013,7 @@ msgstr "Упражнение"
 
 # src/ext_l10n.h:271
 #: lib/layouts/AEA.layout:277 lib/layouts/acmart.layout:594
-#: lib/layouts/beamer.layout:1364 lib/layouts/elsart.layout:372
+#: lib/layouts/beamer.layout:1366 lib/layouts/elsart.layout:372
 #: lib/layouts/foils.layout:274 lib/layouts/heb-article.layout:56
 #: lib/layouts/ijmpc.layout:446 lib/layouts/ijmpd.layout:465
 #: lib/layouts/ijmpd.layout:468 lib/layouts/llncs.layout:388
@@ -8241,14 +8210,14 @@ msgid "Summary"
 msgstr "обобщение"
 
 # src/ext_l10n.h:191
-#: lib/layouts/AEA.layout:333 src/frontends/qt/Menus.cpp:1787
-#: src/frontends/qt/Menus.cpp:1802
+#: lib/layouts/AEA.layout:333 src/frontends/qt/Menus.cpp:1803
+#: src/frontends/qt/Menus.cpp:1818
 msgid "Caption"
 msgstr "надпис"
 
 # src/ext_l10n.h:318
 #: lib/layouts/AEA.layout:344 lib/layouts/IEEEtran.layout:448
-#: lib/layouts/beamer.layout:1370 lib/layouts/elsart.layout:342
+#: lib/layouts/beamer.layout:1372 lib/layouts/elsart.layout:342
 #: lib/layouts/foils.layout:309 lib/layouts/heb-article.layout:106
 #: lib/layouts/ijmpc.layout:399 lib/layouts/ijmpd.layout:405
 #: lib/layouts/llncs.layout:408 lib/layouts/siamltex.layout:157
@@ -8261,7 +8230,7 @@ msgstr "Доказателство"
 
 #: lib/layouts/IEEEtran-CompSoc.layout:3 lib/examples/Articles:0
 msgid "IEEE Transactions Computer Society"
-msgstr ""
+msgstr "IEEE Общество за компютърни трансакции"
 
 # src/ext_l10n.h:361
 #: lib/layouts/IEEEtran-CompSoc.layout:19
@@ -8295,13 +8264,12 @@ msgstr ""
 
 #: lib/layouts/IEEEtran-TransMag.layout:3 lib/examples/Articles:0
 msgid "IEEE Transactions on Magnetics"
-msgstr ""
+msgstr "IEEE Трансакции по магнетизъм"
 
 # src/ext_l10n.h:400
 #: lib/layouts/IEEEtran.layout:3
-#, fuzzy
 msgid "IEEE Transactions"
-msgstr "Преход"
+msgstr "IEEE трансакции"
 
 # src/ext_l10n.h:361
 #: lib/layouts/IEEEtran.layout:35 lib/layouts/aa.layout:36
@@ -8310,7 +8278,7 @@ msgstr "Преход"
 #: lib/layouts/acmsiggraph-0-92.layout:43 lib/layouts/acmsiggraph.layout:35
 #: lib/layouts/agutex.layout:32 lib/layouts/amsart.layout:32
 #: lib/layouts/amsbook.layout:33 lib/layouts/apa.layout:25
-#: lib/layouts/apax.inc:21 lib/layouts/beamer.layout:64
+#: lib/layouts/apax.inc:21 lib/layouts/beamer.layout:66
 #: lib/layouts/broadway.layout:178 lib/layouts/chess.layout:30
 #: lib/layouts/cl2emult.layout:151 lib/layouts/db_stdclass.inc:16
 #: lib/layouts/dtk.layout:32 lib/layouts/egs.layout:19
@@ -8330,9 +8298,9 @@ msgstr "Преход"
 #: lib/layouts/scrlttr2.layout:19 lib/layouts/siamltex.layout:37
 #: lib/layouts/sigplanconf.layout:41 lib/layouts/simplecv.layout:18
 #: lib/layouts/slides.layout:61 lib/layouts/stdclass.inc:28
-#: lib/layouts/stdinsets.inc:687 lib/layouts/stdletter.inc:12
+#: lib/layouts/stdinsets.inc:688 lib/layouts/stdletter.inc:12
 #: lib/layouts/svcommon.inc:26 lib/layouts/tufte-book.layout:35
-#: src/insets/InsetRef.cpp:595
+#: src/insets/InsetRef.cpp:597
 msgid "Standard"
 msgstr "По подразбиране"
 
@@ -8343,7 +8311,7 @@ msgstr "По подразбиране"
 #: lib/layouts/acmart.layout:145 lib/layouts/acmsiggraph-0-92.layout:165
 #: lib/layouts/acmsiggraph.layout:141 lib/layouts/agutex.layout:56
 #: lib/layouts/amsdefs.inc:27 lib/layouts/apa.layout:42 lib/layouts/apax.inc:38
-#: lib/layouts/beamer.layout:984 lib/layouts/beamerposter.layout:21
+#: lib/layouts/beamer.layout:986 lib/layouts/beamerposter.layout:21
 #: lib/layouts/broadway.layout:192 lib/layouts/cl2emult.layout:41
 #: lib/layouts/copernicus.layout:34 lib/layouts/docbook-book.layout:18
 #: lib/layouts/docbook-chapter.layout:14 lib/layouts/docbook-section.layout:14
@@ -8370,19 +8338,17 @@ msgstr "Заглавие"
 
 #: lib/layouts/IEEEtran.layout:91 lib/layouts/IEEEtran.layout:96
 msgid "IEEE membership"
-msgstr ""
+msgstr "IEEE членство"
 
 # src/lyxfunc.C:1125
 #: lib/layouts/IEEEtran.layout:112 lib/layouts/revtex4-x.inc:350
-#, fuzzy
 msgid "Lowercase"
-msgstr "overset"
+msgstr "Малки букви"
 
 # src/lyxfunc.C:1125
 #: lib/layouts/IEEEtran.layout:116
-#, fuzzy
 msgid "lowercase"
-msgstr "overset"
+msgstr "малки бекви"
 
 # src/ext_l10n.h:175
 #: lib/layouts/IEEEtran.layout:123 lib/layouts/aa.layout:237
@@ -8391,7 +8357,7 @@ msgstr "overset"
 #: lib/layouts/achemso.layout:84 lib/layouts/acmart.layout:81
 #: lib/layouts/acmsiggraph-0-92.layout:178 lib/layouts/acmsiggraph.layout:154
 #: lib/layouts/amsdefs.inc:57 lib/layouts/apa.layout:139
-#: lib/layouts/apax.inc:80 lib/layouts/beamer.layout:1048
+#: lib/layouts/apax.inc:80 lib/layouts/beamer.layout:1050
 #: lib/layouts/beamerposter.layout:31 lib/layouts/broadway.layout:210
 #: lib/layouts/cl2emult.layout:63 lib/layouts/copernicus.layout:61
 #: lib/layouts/ectaart.layout:131 lib/layouts/ectaart.layout:217
@@ -8414,45 +8380,40 @@ msgid "Author"
 msgstr "Автор"
 
 # src/ext_l10n.h:375
-#: lib/layouts/IEEEtran.layout:129 lib/layouts/beamer.layout:1061
+#: lib/layouts/IEEEtran.layout:129 lib/layouts/beamer.layout:1063
 #, fuzzy
 msgid "Short Author|S"
 msgstr "Подзаглавие"
 
 #: lib/layouts/IEEEtran.layout:130
 msgid "A short version of the author name"
-msgstr ""
+msgstr "Кратка версия на името на автора"
 
 # src/ext_l10n.h:175
 #: lib/layouts/IEEEtran.layout:152
-#, fuzzy
 msgid "Author Name"
-msgstr "Автор"
+msgstr "Име на автор"
 
 # src/ext_l10n.h:175
 #: lib/layouts/IEEEtran.layout:158
-#, fuzzy
 msgid "Author name"
-msgstr "Автор"
+msgstr "Име на автор"
 
 # src/ext_l10n.h:221
 #: lib/layouts/IEEEtran.layout:170
-#, fuzzy
 msgid "Author Affiliation"
-msgstr "Дефиниция"
+msgstr "Принадлежност на автор"
 
 # src/ext_l10n.h:221
 #: lib/layouts/IEEEtran.layout:173 lib/layouts/agutex.layout:122
 #: lib/layouts/copernicus.layout:67
-#, fuzzy
 msgid "Author affiliation"
-msgstr "Дефиниция"
+msgstr "Принадлежност на автор"
 
 # src/ext_l10n.h:175
 #: lib/layouts/IEEEtran.layout:184
-#, fuzzy
 msgid "Author Mark"
-msgstr "Автор"
+msgstr "Знак на автор"
 
 # src/ext_l10n.h:175
 #: lib/layouts/IEEEtran.layout:189 lib/layouts/elsarticle.layout:174
@@ -8511,9 +8472,8 @@ msgstr "Индекс запис"
 
 # src/insets/insetbib.C:219
 #: lib/layouts/IEEEtran.layout:316 lib/layouts/IEEEtran.layout:320
-#, fuzzy
 msgid "Paragraph Start"
-msgstr "Библ. перо"
+msgstr "Начало на абзац"
 
 # src/ext_l10n.h:337
 #: lib/layouts/IEEEtran.layout:324
@@ -8523,7 +8483,7 @@ msgstr "Заглавие"
 
 #: lib/layouts/IEEEtran.layout:325
 msgid "First character of first word"
-msgstr ""
+msgstr "Първа буква на първата дума"
 
 # src/ext_l10n.h:173
 #: lib/layouts/IEEEtran.layout:334 lib/layouts/IEEEtran.layout:344
@@ -8539,7 +8499,7 @@ msgstr "Приложения"
 #: lib/layouts/acmsiggraph.layout:305 lib/layouts/agutex.layout:167
 #: lib/layouts/agutex.layout:177 lib/layouts/agutex.layout:197
 #: lib/layouts/agutex.layout:223 lib/layouts/amsdefs.inc:266
-#: lib/layouts/apa.layout:244 lib/layouts/beamer.layout:1169
+#: lib/layouts/apa.layout:244 lib/layouts/beamer.layout:1171
 #: lib/layouts/copernicus.layout:437 lib/layouts/egs.layout:588
 #: lib/layouts/egs.layout:639 lib/layouts/elsarticle.layout:333
 #: lib/layouts/europasscv.layout:539 lib/layouts/europecv.layout:380
@@ -8583,7 +8543,7 @@ msgstr "Автозаписът пропадна!"
 #: lib/layouts/ijmpc.layout:496 lib/layouts/ijmpc.layout:498
 #: lib/layouts/ijmpd.layout:520 lib/layouts/ijmpd.layout:522
 #: lib/layouts/kluwer.layout:364 lib/layouts/kluwer.layout:377
-#: lib/examples/Articles:0 src/RowPainter.cpp:366
+#: lib/examples/Articles:0 src/RowPainter.cpp:374
 msgid "Appendix"
 msgstr "приложение"
 
@@ -8602,7 +8562,7 @@ msgstr "Кратко заглавие на приложението"
 #: lib/layouts/aapaper.layout:234 lib/layouts/aastex.layout:450
 #: lib/layouts/aguplus.inc:172 lib/layouts/aguplus.inc:174
 #: lib/layouts/agutex.layout:219 lib/layouts/amsbook.layout:121
-#: lib/layouts/amsdefs.inc:265 lib/layouts/beamer.layout:1168
+#: lib/layouts/amsdefs.inc:265 lib/layouts/beamer.layout:1170
 #: lib/layouts/book.layout:24 lib/layouts/book.layout:26
 #: lib/layouts/cl2emult.layout:115 lib/layouts/copernicus.layout:433
 #: lib/layouts/egs.layout:638 lib/layouts/elsarticle.layout:329
@@ -8620,16 +8580,16 @@ msgstr "Кратко заглавие на приложението"
 #: lib/layouts/scrreprt.layout:12 lib/layouts/scrreprt.layout:14
 #: lib/layouts/siamltex.layout:339 lib/layouts/simplecv.layout:196
 #: lib/layouts/stdstruct.inc:59 lib/layouts/svcommon.inc:657
-#: lib/layouts/tufte-book.layout:292 lib/layouts/tufte-book.layout:294
+#: lib/layouts/tufte-book.layout:298 lib/layouts/tufte-book.layout:300
 #: lib/layouts/tufte-handout.layout:77 lib/examples/Articles:0
-#: src/frontends/qt/GuiDocument.cpp:1771 src/insets/InsetBibtex.cpp:957
+#: src/frontends/qt/GuiDocument.cpp:1785 src/insets/InsetBibtex.cpp:957
 msgid "Bibliography"
 msgstr "Литература"
 
 # src/ext_l10n.h:329
 #: lib/layouts/IEEEtran.layout:389 lib/layouts/aastex.layout:464
 #: lib/layouts/aastex.layout:485 lib/layouts/agutex.layout:235
-#: lib/layouts/amsdefs.inc:281 lib/layouts/beamer.layout:1183
+#: lib/layouts/amsdefs.inc:281 lib/layouts/beamer.layout:1185
 #: lib/layouts/cl2emult.layout:130 lib/layouts/copernicus.layout:449
 #: lib/layouts/egs.layout:654 lib/layouts/elsarticle.layout:345
 #: lib/layouts/ijmpc.layout:540 lib/layouts/ijmpd.layout:564
@@ -8647,7 +8607,7 @@ msgstr "Препратки"
 # src/frontends/xforms/form_preferences.C:896
 #: lib/layouts/IEEEtran.layout:398 lib/layouts/aastex.layout:474
 #: lib/layouts/agutex.layout:244 lib/layouts/amsdefs.inc:293
-#: lib/layouts/beamer.layout:1192 lib/layouts/cl2emult.layout:139
+#: lib/layouts/beamer.layout:1194 lib/layouts/cl2emult.layout:139
 #: lib/layouts/copernicus.layout:457 lib/layouts/egs.layout:662
 #: lib/layouts/elsarticle.layout:354 lib/layouts/ijmpc.layout:549
 #: lib/layouts/ijmpd.layout:573 lib/layouts/iopart.layout:346
@@ -8662,7 +8622,7 @@ msgstr "заглавна част на лит. списък"
 # src/ext_l10n.h:186
 #: lib/layouts/IEEEtran.layout:399 lib/layouts/aastex.layout:475
 #: lib/layouts/agutex.layout:245 lib/layouts/amsdefs.inc:294
-#: lib/layouts/beamer.layout:1193 lib/layouts/cl2emult.layout:140
+#: lib/layouts/beamer.layout:1195 lib/layouts/cl2emult.layout:140
 #: lib/layouts/copernicus.layout:458 lib/layouts/egs.layout:663
 #: lib/layouts/elsarticle.layout:355 lib/layouts/ijmpc.layout:550
 #: lib/layouts/ijmpd.layout:574 lib/layouts/iopart.layout:347
@@ -8676,7 +8636,7 @@ msgstr "Заглавна част на лит. списък"
 
 #: lib/layouts/IEEEtran.layout:400 lib/layouts/aastex.layout:476
 #: lib/layouts/agutex.layout:246 lib/layouts/amsdefs.inc:295
-#: lib/layouts/beamer.layout:1194 lib/layouts/cl2emult.layout:141
+#: lib/layouts/beamer.layout:1196 lib/layouts/cl2emult.layout:141
 #: lib/layouts/copernicus.layout:459 lib/layouts/egs.layout:664
 #: lib/layouts/elsarticle.layout:356 lib/layouts/ijmpc.layout:551
 #: lib/layouts/ijmpd.layout:575 lib/layouts/iopart.layout:348
@@ -8696,11 +8656,11 @@ msgstr "Биография"
 
 #: lib/layouts/IEEEtran.layout:415 lib/layouts/moderncv.layout:275
 msgid "Photo"
-msgstr ""
+msgstr "Снимка"
 
 #: lib/layouts/IEEEtran.layout:416
 msgid "Optional photo for biography"
-msgstr ""
+msgstr "Незадължителна снимка за биография"
 
 # src/ext_l10n.h:288 src/frontends/gnome/FormUrl.C:119
 #: lib/layouts/IEEEtran.layout:421 lib/layouts/IEEEtran.layout:438
@@ -8721,25 +8681,22 @@ msgstr "Име"
 # src/lyxrc.C:1838
 #: lib/layouts/IEEEtran.layout:422 lib/layouts/IEEEtran.layout:439
 #: lib/layouts/sigplanconf.layout:165
-#, fuzzy
 msgid "Name of the author"
-msgstr "Укажете стандартния размер на хартията."
+msgstr "Име на автора"
 
 # src/ext_l10n.h:187
 #: lib/layouts/IEEEtran.layout:431
-#, fuzzy
 msgid "Biography without photo"
 msgstr "Биография без снимка"
 
 # src/ext_l10n.h:187
 #: lib/layouts/IEEEtran.layout:443
-#, fuzzy
 msgid "BiographyNoPhoto"
-msgstr "Биография"
+msgstr "Биография без снимка"
 
 # src/ext_l10n.h:298
 #: lib/layouts/IEEEtran.layout:449 lib/layouts/acmart.layout:553
-#: lib/layouts/beamer.layout:1293 lib/layouts/elsart.layout:311
+#: lib/layouts/beamer.layout:1295 lib/layouts/elsart.layout:311
 #: lib/layouts/elsart.layout:343 lib/layouts/foils.layout:249
 #: lib/layouts/heb-article.layout:29 lib/layouts/heb-article.layout:107
 #: lib/layouts/ijmpc.layout:402 lib/layouts/ijmpd.layout:408
@@ -8750,25 +8707,22 @@ msgstr "Биография"
 #: lib/layouts/theorems-named.module:13 lib/layouts/theorems-named.module:58
 #: lib/layouts/theorems-proof.inc:14 lib/layouts/theorems-starred.inc:27
 #: lib/layouts/theorems-without-preamble.inc:39 lib/layouts/theorems.inc:28
-#, fuzzy
 msgid "Reasoning"
-msgstr "Отваряне"
+msgstr "Разсъждаване"
 
 # src/frontends/xforms/form_preferences.C:278
 #: lib/layouts/IEEEtran.layout:455 lib/layouts/siamltex.layout:163
 #: lib/layouts/theorems-proof.inc:21
-#, fuzzy
 msgid "Alternative Proof String"
-msgstr "Използвай алтернативен език"
+msgstr "Текст на алтернативно доказателство"
 
 # src/frontends/xforms/form_preferences.C:278
 #: lib/layouts/IEEEtran.layout:456 lib/layouts/siamltex.layout:164
-#, fuzzy
 msgid "An alternative proof string"
-msgstr "Използвай алтернативен език"
+msgstr "Текст на алтернативно доказателство"
 
 # src/ext_l10n.h:318
-#: lib/layouts/IEEEtran.layout:468 lib/layouts/beamer.layout:1373
+#: lib/layouts/IEEEtran.layout:468 lib/layouts/beamer.layout:1375
 #: lib/layouts/foils.layout:312 lib/layouts/llncs.layout:411
 #: lib/layouts/siamltex.layout:176 lib/layouts/svcommon.inc:748
 #: lib/layouts/svmono.layout:103 lib/layouts/svmono.layout:107
@@ -8778,12 +8732,12 @@ msgstr "Доказателство."
 
 #: lib/layouts/InStar.module:2
 msgid "Title and Preamble Hacks"
-msgstr ""
+msgstr "Подобрения в заглавието и преамбюла"
 
 #: lib/layouts/InStar.module:3 lib/layouts/fix-cm.module:3
 #: lib/layouts/fixltx2e.module:3 lib/layouts/minimalistic.module:3
 msgid "Fixes & Hacks"
-msgstr ""
+msgstr "Поправки и подобрения"
 
 #: lib/layouts/InStar.module:13
 msgid ""
@@ -8795,24 +8749,29 @@ msgid ""
 "in title-related material. (If you put these in a Standard layout, this "
 "signals to LyX to output \\maketitle, which may then come too early.)"
 msgstr ""
+"Добавя два нови стила: 1. „В преамбюл“, където се добавя всичко за "
+"заглавната част на документа. Може да се използва ако някои желае да "
+"пише преамбюла в изложението на документа. 1. „В заглавие“, което се пише "
+"в изложението на документа, но съдържанието ще се включи преди да се "
+"изпълни \\maketitle. Това е полезно за правене на разклонения и бележки "
+"при материали свързани със заглавието. Ако паставите това в стандартно "
+"оформление се сигнализира на LyX да изпълни \\maketitle, което ще дойде "
+"твърде рано."
 
 # src/lyx_cb.C:675
 #: lib/layouts/InStar.module:17
-#, fuzzy
 msgid "In Preamble"
-msgstr "LaTeX увод"
+msgstr "В преамбюл"
 
 # src/ext_l10n.h:395 src/frontends/gnome/FormCitation.C:529
 #: lib/layouts/InStar.module:24
-#, fuzzy
 msgid "In Title"
-msgstr "Заглавие"
+msgstr "В заглавие"
 
 # src/frontends/kde/paraextradlg.C:25 src/lyxfont.C:56
 #: lib/layouts/RJournal.layout:3 lib/examples/Articles:0
-#, fuzzy
 msgid "R Journal"
-msgstr "Нормален"
+msgstr "Журнал R"
 
 #: lib/layouts/RJournal.layout:4 lib/layouts/bxjsreport.layout:4
 #: lib/layouts/ctex-report.layout:4 lib/layouts/extreport.layout:4
@@ -8872,7 +8831,7 @@ msgstr "Ел. поща"
 # src/frontends/xforms/FormPreferences.C:255
 #: lib/layouts/a0poster.layout:3 lib/examples/Articles:0
 msgid "A0 Poster"
-msgstr "A0 плакат"
+msgstr "Плакат A0"
 
 # src/frontends/xforms/FormPreferences.C:226
 # src/frontends/xforms/FormPreferences.C:255
@@ -8887,7 +8846,7 @@ msgstr "Плакати"
 #: lib/layouts/sciposter.layout:130 lib/layouts/sciposter.layout:133
 #: lib/layouts/sciposter.layout:160
 msgid "Giant"
-msgstr ""
+msgstr "Гигатски"
 
 #: lib/layouts/a0poster.layout:57 lib/layouts/a0poster.layout:60
 #: lib/layouts/a0poster.layout:86 lib/layouts/beamerposter.layout:69
@@ -8895,7 +8854,7 @@ msgstr ""
 #: lib/layouts/sciposter.layout:146 lib/layouts/sciposter.layout:149
 #: lib/layouts/sciposter.layout:175
 msgid "More Giant"
-msgstr ""
+msgstr "По-гигантски"
 
 #: lib/layouts/a0poster.layout:63 lib/layouts/a0poster.layout:66
 #: lib/layouts/a0poster.layout:92 lib/layouts/beamerposter.layout:75
@@ -8903,22 +8862,22 @@ msgstr ""
 #: lib/layouts/sciposter.layout:152 lib/layouts/sciposter.layout:155
 #: lib/layouts/sciposter.layout:181
 msgid "Most Giant"
-msgstr ""
+msgstr "Най-гигантски"
 
 #: lib/layouts/a0poster.layout:69 lib/layouts/beamerposter.layout:81
 #: lib/layouts/sciposter.layout:158
 msgid "Giant Snippet"
-msgstr ""
+msgstr "Гигантски фрагмент"
 
 #: lib/layouts/a0poster.layout:84 lib/layouts/beamerposter.layout:96
 #: lib/layouts/sciposter.layout:173
 msgid "More Giant Snippet"
-msgstr ""
+msgstr "По-гигантски фрагмент"
 
 #: lib/layouts/a0poster.layout:90 lib/layouts/beamerposter.layout:102
 #: lib/layouts/sciposter.layout:179
 msgid "Most Giant Snippet"
-msgstr ""
+msgstr "Най-гигантски фрагмент"
 
 #: lib/layouts/aa.layout:3 lib/examples/Articles:0
 msgid "Astronomy & Astrophysics"
@@ -8927,7 +8886,7 @@ msgstr "Астрономия и астрофизика"
 # src/ext_l10n.h:375
 #: lib/layouts/aa.layout:69 lib/layouts/aapaper.inc:9
 #: lib/layouts/aapaper.layout:81 lib/layouts/acm-sigs.inc:10
-#: lib/layouts/acmart.layout:160 lib/layouts/beamer.layout:1021
+#: lib/layouts/acmart.layout:160 lib/layouts/beamer.layout:1023
 #: lib/layouts/beamerposter.layout:26 lib/layouts/kluwer.layout:136
 #: lib/layouts/llncs.layout:135 lib/layouts/scrclass.inc:217
 #: lib/layouts/sigplanconf.layout:138 lib/layouts/svcommon.inc:356
@@ -8939,38 +8898,35 @@ msgstr "подзаглавие"
 # src/form1.C:129 src/sp_form.C:58
 #: lib/layouts/aa.layout:113 lib/layouts/aapaper.inc:65
 #: lib/layouts/aapaper.layout:93
-#, fuzzy
 msgid "Offprint"
-msgstr "Опции"
+msgstr "Отделно издание"
 
 # src/form1.C:129 src/sp_form.C:58
 #: lib/layouts/aa.layout:122 lib/layouts/aapaper.inc:73
-#, fuzzy
 msgid "Offprint Requests to:"
-msgstr "Опции"
+msgstr "Отделно издание по изискване на:"
 
 # src/layout_forms.C:23
 #: lib/layouts/aa.layout:142 lib/layouts/svglobal.layout:136
 #: lib/layouts/svjog.layout:140 lib/layouts/svprobth.layout:169
-#, fuzzy
 msgid "Mail"
-msgstr "Семейство(F):|#F"
+msgstr "Ел. поща"
 
 #: lib/layouts/aa.layout:151
 msgid "Correspondence to:"
-msgstr ""
+msgstr "Кореспонденция до:"
 
 #: lib/layouts/aa.layout:181 lib/layouts/copernicus.layout:427
 #: lib/layouts/egs.layout:602
 msgid "Acknowledgements."
-msgstr ""
+msgstr "Благодарности."
 
 # src/ext_l10n.h:344
 #: lib/layouts/aa.layout:196 lib/layouts/aapaper.layout:66
 #: lib/layouts/aapaper.layout:139 lib/layouts/aastex.layout:97
 #: lib/layouts/aguplus.inc:29 lib/layouts/amsart.layout:66
 #: lib/layouts/amsbook.layout:57 lib/layouts/apa.layout:339
-#: lib/layouts/apax.inc:438 lib/layouts/beamer.layout:288
+#: lib/layouts/apax.inc:438 lib/layouts/beamer.layout:290
 #: lib/layouts/egs.layout:33 lib/layouts/europasscv.layout:264
 #: lib/layouts/europecv.layout:193 lib/layouts/isprs.layout:160
 #: lib/layouts/iucr.layout:47 lib/layouts/jss.layout:25
@@ -8994,7 +8950,7 @@ msgstr "Раздел"
 #: lib/layouts/aapaper.layout:149 lib/layouts/aastex.layout:110
 #: lib/layouts/aguplus.inc:44 lib/layouts/amsart.layout:107
 #: lib/layouts/amsbook.layout:67 lib/layouts/apa.layout:350
-#: lib/layouts/apax.inc:449 lib/layouts/beamer.layout:350
+#: lib/layouts/apax.inc:449 lib/layouts/beamer.layout:352
 #: lib/layouts/egs.layout:56 lib/layouts/isprs.layout:172
 #: lib/layouts/iucr.layout:53 lib/layouts/jss.layout:29
 #: lib/layouts/kluwer.layout:72 lib/layouts/latex8.layout:59
@@ -9013,7 +8969,7 @@ msgstr "Подраздел"
 #: lib/layouts/aapaper.layout:161 lib/layouts/aastex.layout:123
 #: lib/layouts/amsart.layout:130 lib/layouts/amsbook.layout:76
 #: lib/layouts/apa.layout:360 lib/layouts/apax.inc:459
-#: lib/layouts/beamer.layout:412 lib/layouts/isprs.layout:182
+#: lib/layouts/beamer.layout:414 lib/layouts/isprs.layout:182
 #: lib/layouts/iucr.layout:61 lib/layouts/jss.layout:33
 #: lib/layouts/kluwer.layout:82 lib/layouts/llncs.layout:67
 #: lib/layouts/ltugboat.layout:90 lib/layouts/memoir.layout:129
@@ -9030,7 +8986,7 @@ msgstr "Подподраздел"
 #: lib/layouts/aa.layout:253 lib/layouts/aapaper.layout:99
 #: lib/layouts/aapaper.layout:202 lib/layouts/aastex.layout:265
 #: lib/layouts/acmart.layout:133 lib/layouts/amsdefs.inc:82
-#: lib/layouts/beamer.layout:1120 lib/layouts/beamerposter.layout:41
+#: lib/layouts/beamer.layout:1122 lib/layouts/beamerposter.layout:41
 #: lib/layouts/dinbrief.layout:218 lib/layouts/egs.layout:550
 #: lib/layouts/foils.layout:169 lib/layouts/frletter.layout:24
 #: lib/layouts/g-brief.layout:199 lib/layouts/g-brief2.layout:54
@@ -9052,7 +9008,7 @@ msgid "institutemark"
 msgstr "Знак на организацията"
 
 # src/LyXAction.C:354
-#: lib/layouts/aa.layout:273 lib/layouts/beamer.layout:1103
+#: lib/layouts/aa.layout:273 lib/layouts/beamer.layout:1105
 msgid "Institute Mark"
 msgstr "Знак на организацията"
 
@@ -9071,65 +9027,60 @@ msgstr "Резюме (структурирано)"
 # src/frontends/xforms/FormPreferences.C:226
 # src/frontends/xforms/FormPreferences.C:255
 #: lib/layouts/aa.layout:335
-#, fuzzy
 msgid "Context"
-msgstr "Конвертори"
+msgstr "Контекст"
 
 #: lib/layouts/aa.layout:336
 msgid "Context of your work (optional, can be left empty)"
-msgstr ""
+msgstr "Контекст на вашата работе (незадължително, може да не се попълва)"
 
 #: lib/layouts/aa.layout:340
 msgid "Aims"
-msgstr ""
+msgstr "Цели"
 
 #: lib/layouts/aa.layout:341
 msgid "Aims of your work"
-msgstr ""
+msgstr "Цели на вашата работа"
 
 #: lib/layouts/aa.layout:345
 msgid "Methods"
-msgstr ""
+msgstr "Методи"
 
 #: lib/layouts/aa.layout:346
 msgid "Methods used in your work"
-msgstr ""
+msgstr "Методи използвани във вашата работа"
 
 #: lib/layouts/aa.layout:350
 msgid "Results"
-msgstr ""
+msgstr "Резултати"
 
 #: lib/layouts/aa.layout:351
 msgid "Results of your work"
-msgstr ""
+msgstr "Резултати на вашата работа"
 
 # src/ext_l10n.h:263
 #: lib/layouts/aa.layout:377
-#, fuzzy
 msgid "Key words."
-msgstr "Ключови дума"
+msgstr "Ключови думи"
 
 # src/LyXAction.C:354
-#: lib/layouts/aa.layout:395 lib/layouts/beamer.layout:1076
+#: lib/layouts/aa.layout:395 lib/layouts/beamer.layout:1078
 #: lib/layouts/beamerposter.layout:36 lib/layouts/cl2emult.layout:81
 #: lib/layouts/llncs.layout:231 lib/layouts/sciposter.layout:24
 #: lib/layouts/svcommon.inc:384
-#, fuzzy
 msgid "Institute"
-msgstr "Вмъкни кавички"
+msgstr "Институция"
 
 # src/layout_forms.C:23
 #: lib/layouts/aa.layout:406 lib/layouts/sciposter.layout:29
 #: lib/layouts/scrlttr2.layout:257
-#, fuzzy
 msgid "E-Mail"
-msgstr "Семейство(F):|#F"
+msgstr "Ел. поща"
 
 # src/layout_forms.C:23
 #: lib/layouts/aapaper.inc:56
-#, fuzzy
 msgid "email:"
-msgstr "Семейство(F):|#F"
+msgstr "ел. поща:"
 
 #: lib/layouts/aapaper.inc:93 lib/layouts/aastex.layout:354
 #: lib/layouts/aastex62.layout:225 lib/layouts/apa.layout:243
@@ -9139,7 +9090,7 @@ msgstr "Семейство(F):|#F"
 #: lib/layouts/kluwer.layout:353 lib/layouts/svcommon.inc:639
 #: lib/layouts/svcommon.inc:652
 msgid "Acknowledgements"
-msgstr ""
+msgstr "Благодарности"
 
 # src/ext_l10n.h:390
 #: lib/layouts/aapaper.inc:107 lib/layouts/aapaper.layout:96
@@ -9149,11 +9100,11 @@ msgstr "Синонимен речник"
 
 #: lib/layouts/aapaper.inc:118
 msgid "Thesaurus not supported in recent A&A:"
-msgstr ""
+msgstr "Синонимен речник не се поддържа в последни A&A:"
 
 #: lib/layouts/aapaper.layout:3 lib/layouts/aapaper.layout:14
 msgid "Astronomy & Astrophysics (V. 4, Obsolete)"
-msgstr ""
+msgstr "Астрономия и астрофизика (вер. 4, остарял)"
 
 #: lib/layouts/aapaper.layout:4 lib/layouts/acm-sigs-alt.layout:4
 #: lib/layouts/acm-sigs.layout:4 lib/layouts/acmsiggraph-0-92.layout:4
@@ -9168,7 +9119,7 @@ msgstr "Излязли от употреба"
 
 # src/LyXAction.C:251
 #: lib/layouts/aapaper.layout:50 lib/layouts/apa.layout:391
-#: lib/layouts/apax.inc:490 lib/layouts/beamer.layout:82
+#: lib/layouts/apax.inc:490 lib/layouts/beamer.layout:84
 #: lib/layouts/egs.layout:203 lib/layouts/powerdot.layout:264
 #: lib/layouts/simplecv.layout:108 lib/layouts/stdlists.inc:13
 msgid "Itemize"
@@ -9176,14 +9127,14 @@ msgstr "Водещи знаци"
 
 # src/ext_l10n.h:231
 #: lib/layouts/aapaper.layout:53 lib/layouts/apa.layout:427
-#: lib/layouts/apax.inc:527 lib/layouts/beamer.layout:131
+#: lib/layouts/apax.inc:527 lib/layouts/beamer.layout:133
 #: lib/layouts/egs.layout:166 lib/layouts/powerdot.layout:326
 #: lib/layouts/stdlists.inc:52
 msgid "Enumerate"
 msgstr "Номериране"
 
 # src/ext_l10n.h:223
-#: lib/layouts/aapaper.layout:56 lib/layouts/beamer.layout:186
+#: lib/layouts/aapaper.layout:56 lib/layouts/beamer.layout:188
 #: lib/layouts/egs.layout:239 lib/layouts/hollywood.layout:130
 #: lib/layouts/paper.layout:110 lib/layouts/scrclass.inc:55
 #: lib/layouts/scrlettr.layout:21 lib/layouts/scrlttr2.layout:33
@@ -9196,8 +9147,8 @@ msgstr "Описание"
 #: lib/layouts/aapaper.layout:59 lib/layouts/algorithm2e.module:34
 #: lib/layouts/apa.layout:392 lib/layouts/apa.layout:428
 #: lib/layouts/apa.layout:466 lib/layouts/apax.inc:491 lib/layouts/apax.inc:528
-#: lib/layouts/apax.inc:566 lib/layouts/beamer.layout:83
-#: lib/layouts/beamer.layout:132 lib/layouts/beamer.layout:187
+#: lib/layouts/apax.inc:566 lib/layouts/beamer.layout:85
+#: lib/layouts/beamer.layout:134 lib/layouts/beamer.layout:189
 #: lib/layouts/egs.layout:139 lib/layouts/egs.layout:167
 #: lib/layouts/egs.layout:204 lib/layouts/enumitem.module:88
 #: lib/layouts/europasscv.layout:400 lib/layouts/foils.layout:87
@@ -9214,7 +9165,7 @@ msgstr "изброяване по списък"
 
 #: lib/layouts/aastex.layout:3
 msgid "American Astronomical Society (AASTeX v. 5)"
-msgstr ""
+msgstr "Американско астрономическо общество (AASTeX v. 5)"
 
 # src/ext_l10n.h:221
 #: lib/layouts/aastex.layout:169 lib/layouts/aastex62.layout:174
@@ -9225,32 +9176,28 @@ msgstr ""
 #: lib/layouts/maa-monthly.layout:124 lib/layouts/moderncv.layout:445
 #: lib/layouts/revtex4-x.inc:63 lib/layouts/revtex4.layout:141
 #: lib/layouts/sigplanconf.layout:172
-#, fuzzy
 msgid "Affiliation"
-msgstr "Дефиниция"
+msgstr "Принадлежност"
 
 # src/ext_l10n.h:221
 #: lib/layouts/aastex.layout:192 lib/layouts/aastex62.layout:219
-#, fuzzy
 msgid "Altaffilation"
-msgstr "Дефиниция"
+msgstr "Предишна принадлежност"
 
 # src/mathed/formula.C:929
 #: lib/layouts/aastex.layout:201 lib/layouts/agutex.layout:132
-#: src/mathed/InsetMathHull.cpp:1857 src/mathed/InsetMathHull.cpp:1866
-#, fuzzy
+#: src/mathed/InsetMathHull.cpp:1866 src/mathed/InsetMathHull.cpp:1875
 msgid "Number"
-msgstr "Номериране"
+msgstr "Номер"
 
 #: lib/layouts/aastex.layout:202
 msgid "Consecutive number for the alternative affiliations"
-msgstr ""
+msgstr "Пореден номер на алтернативна принадлежност"
 
 # src/frontends/xforms/form_preferences.C:278
 #: lib/layouts/aastex.layout:207
-#, fuzzy
 msgid "Alternative affiliation:"
-msgstr "Използвай алтернативен език"
+msgstr "Алтернативна принадлежност:"
 
 # src/ext_l10n.h:170
 #: lib/layouts/aastex.layout:245
@@ -9258,34 +9205,30 @@ msgid "And"
 msgstr "И"
 
 # src/ext_l10n.h:170
-#: lib/layouts/aastex.layout:256 src/frontends/qt/GuiDocument.cpp:3137
-#: src/frontends/qt/GuiDocument.cpp:3149 src/frontends/qt/GuiDocument.cpp:3275
-#: src/frontends/qt/GuiDocument.cpp:3294
-#, fuzzy
+#: lib/layouts/aastex.layout:256 src/frontends/qt/GuiDocument.cpp:3152
+#: src/frontends/qt/GuiDocument.cpp:3164 src/frontends/qt/GuiDocument.cpp:3290
+#: src/frontends/qt/GuiDocument.cpp:3309
 msgid "and"
-msgstr "И"
+msgstr "и"
 
 # src/ext_l10n.h:221
 #: lib/layouts/aastex.layout:301
-#, fuzzy
 msgid "altaffilmark"
-msgstr "Дефиниция"
+msgstr "знак за принадлежност"
 
 # src/ext_l10n.h:221
 #: lib/layouts/aastex.layout:305
-#, fuzzy
 msgid "altaffiliation mark"
-msgstr "Дефиниция"
+msgstr "знак за принадлежнаст"
 
 # src/buffer.C:329
 #: lib/layouts/aastex.layout:336
-#, fuzzy
 msgid "Subject headings:"
-msgstr "Грешка при ченете от "
+msgstr "Тема в заглавието:"
 
 #: lib/layouts/aastex.layout:365
 msgid "[Acknowledgements]"
-msgstr ""
+msgstr "[Благодарности]"
 
 # src/ext_l10n.h:310
 #: lib/layouts/aastex.layout:377
@@ -9294,9 +9237,8 @@ msgstr "Фигура"
 
 # src/ext_l10n.h:310
 #: lib/layouts/aastex.layout:388
-#, fuzzy
 msgid "Place Figure here:"
-msgstr "Фигура"
+msgstr "Поставяне на фигура тук:"
 
 # src/ext_l10n.h:311
 #: lib/layouts/aastex.layout:397
@@ -9305,15 +9247,13 @@ msgstr "Таблица"
 
 # src/ext_l10n.h:311
 #: lib/layouts/aastex.layout:408
-#, fuzzy
 msgid "Place Table here:"
-msgstr "Таблица"
+msgstr "Поставяне на таблица:"
 
 # src/ext_l10n.h:174
 #: lib/layouts/aastex.layout:427 lib/layouts/copernicus.layout:344
-#, fuzzy
 msgid "[Appendix]"
-msgstr "Приложение"
+msgstr "[Приложение]"
 
 # src/mathed/math_panel.C:116
 #: lib/layouts/aastex.layout:437
@@ -9323,15 +9263,13 @@ msgstr "Разделител"
 
 # src/text2.C:456
 #: lib/layouts/aastex.layout:492
-#, fuzzy
 msgid "NoteToEditor"
-msgstr "Няма нищо за правене"
+msgstr "Бел. към редактора"
 
 # src/text2.C:456
 #: lib/layouts/aastex.layout:504
-#, fuzzy
 msgid "Note to Editor:"
-msgstr "Няма нищо за правене"
+msgstr "Бел. към редактора:"
 
 # src/frontends/xforms/FormTabular.C:133
 #: lib/layouts/aastex.layout:516 lib/layouts/aastex6.layout:106
@@ -9342,9 +9280,8 @@ msgstr "Дълга таблица"
 
 # src/frontends/gnome/FormRef.C:311
 #: lib/layouts/aastex.layout:528
-#, fuzzy
 msgid "References. ---"
-msgstr " Препратка: "
+msgstr "Препратки. ---"
 
 # src/frontends/gnome/FormToc.C:100 src/frontends/gnome/FormToc.C:167
 # src/frontends/kde/FormToc.C:167 src/frontends/kde/FormToc.C:168
@@ -9352,9 +9289,8 @@ msgstr " Препратка: "
 # src/insets/insettoc.C:22
 #: lib/layouts/aastex.layout:539 lib/layouts/aastex6.layout:113
 #: lib/layouts/aastex62.layout:124
-#, fuzzy
 msgid "TableComments"
-msgstr "Съдържание"
+msgstr "Коментари на таблица"
 
 # src/ext_l10n.h:291 src/insets/insetinfo.C:77 src/insets/insetinfo.C:102
 # src/insets/insetinfo.C:231
@@ -9388,7 +9324,7 @@ msgstr ""
 # src/ext_l10n.h:240
 #: lib/layouts/aastex.layout:605
 msgid "FigCaption"
-msgstr "Фиг.заглавие"
+msgstr "Надпис на фигура"
 
 #: lib/layouts/aastex.layout:606
 msgid "fig."
@@ -9396,7 +9332,7 @@ msgstr "фиг."
 
 #: lib/layouts/aastex.layout:612
 msgid "Filename to identify the corresponding figure file"
-msgstr ""
+msgstr "Име на файл за зареждане на изображението"
 
 # src/ext_l10n.h:238
 #: lib/layouts/aastex.layout:627
@@ -9416,11 +9352,11 @@ msgstr ""
 
 #: lib/layouts/aastex.layout:665
 msgid "Obj:"
-msgstr ""
+msgstr "Обект:"
 
 #: lib/layouts/aastex.layout:667 lib/layouts/aastex.layout:697
 msgid "Recognized Name"
-msgstr ""
+msgstr "Разпознато име"
 
 #: lib/layouts/aastex.layout:668
 msgid "Separate the recognized name of an object from text"
@@ -9428,15 +9364,13 @@ msgstr ""
 
 # src/insets/insetbib.C:339
 #: lib/layouts/aastex.layout:683
-#, fuzzy
 msgid "Dataset"
-msgstr "База данни:"
+msgstr "Набор данни"
 
 # src/insets/insetbib.C:339
 #: lib/layouts/aastex.layout:695
-#, fuzzy
 msgid "Dataset:"
-msgstr "База данни:"
+msgstr "Набор данни:"
 
 #: lib/layouts/aastex.layout:698
 msgid "Separate the dataset ID from text"
@@ -9444,15 +9378,15 @@ msgstr ""
 
 #: lib/layouts/aastex6.layout:3 lib/examples/Articles:0
 msgid "American Astronomical Society (AASTeX v. 6)"
-msgstr ""
+msgstr "Американско астрономическо общество (AASTEX вер. 6)"
 
 #: lib/layouts/aastex6.layout:59 lib/layouts/aastex62.layout:70
 msgid "Software"
-msgstr ""
+msgstr "Софуер"
 
 #: lib/layouts/aastex6.layout:66 lib/layouts/aastex62.layout:77
 msgid "Software:"
-msgstr ""
+msgstr "Софтуер:"
 
 #: lib/layouts/aastex6.layout:103 lib/layouts/aastex62.layout:114
 msgid "APPENDIX"
@@ -9460,41 +9394,35 @@ msgstr ""
 
 # src/ext_l10n.h:329
 #: lib/layouts/aastex6.layout:107 lib/layouts/aastex62.layout:118
-#, fuzzy
 msgid "References-"
-msgstr "Препратки"
+msgstr "Препратки-"
 
 # src/ext_l10n.h:291 src/insets/insetinfo.C:77 src/insets/insetinfo.C:102
 # src/insets/insetinfo.C:231
 #: lib/layouts/aastex6.layout:114 lib/layouts/aastex62.layout:125
-#, fuzzy
 msgid "Note-"
-msgstr "Бележка"
+msgstr "Бележка-"
 
 #: lib/layouts/aastex62.layout:3 lib/examples/Articles:0
-#, fuzzy
 msgid "American Astronomical Society (AASTeX v. 6.2)"
-msgstr "Книга на Американско математическо общество (AMS)"
+msgstr "Американско астрономическо общество (AASTEX вер. 6.2)"
 
 # src/ext_l10n.h:175
 #: lib/layouts/aastex62.layout:130 lib/layouts/ectaart.layout:210
 #: lib/layouts/ectaart.layout:213
-#, fuzzy
 msgid "Corresponding Author"
-msgstr "Автор"
+msgstr "Кореспондиращ автор"
 
 # src/ext_l10n.h:175
 #: lib/layouts/aastex62.layout:136
-#, fuzzy
 msgid "Corresponding author:"
-msgstr "Автор"
+msgstr "Кореспондиращ автор:"
 
 # src/ext_l10n.h:175
 #: lib/layouts/aastex62.layout:155 lib/layouts/copernicus.layout:65
 #: lib/layouts/egs.layout:380 lib/layouts/svmult.layout:93
-#, fuzzy
 msgid "Author:"
-msgstr "Автор"
+msgstr "Автор:"
 
 #: lib/layouts/aastex62.layout:161 lib/layouts/acmart.layout:196
 #: lib/layouts/apax.inc:640 lib/layouts/apax.inc:667
@@ -9511,9 +9439,8 @@ msgstr ""
 #: lib/layouts/egs.layout:407 lib/layouts/iucr.layout:194
 #: lib/layouts/jss.layout:78 lib/layouts/revtex4-x.inc:77
 #: lib/layouts/revtex4.layout:152
-#, fuzzy
 msgid "Affiliation:"
-msgstr "Дефиниция"
+msgstr "Принадлежност:"
 
 # src/frontends/xforms/form_document.C:244
 #: lib/layouts/aastex62.layout:187 lib/layouts/revtex4-x.inc:164
@@ -9543,141 +9470,125 @@ msgstr "Абзац разделяне"
 
 # src/ext_l10n.h:174
 #: lib/layouts/aastex62.layout:241 lib/layouts/copernicus.layout:307
-#, fuzzy
 msgid "Section Appendix"
-msgstr "приложение"
+msgstr "Раадел приложение"
 
 # src/LColor.C:64
 #: lib/layouts/aastex62.layout:245
-#, fuzzy
 msgid "\\Alph{appendix}."
-msgstr "избор"
+msgstr "\\Alph{appendix}."
 
 # src/ext_l10n.h:174
 #: lib/layouts/aastex62.layout:253 lib/layouts/copernicus.layout:315
-#, fuzzy
 msgid "Subappendix"
-msgstr "приложение"
+msgstr "Подраздел приложение"
 
 # src/ext_l10n.h:371
 #: lib/layouts/aastex62.layout:257 lib/layouts/copernicus.layout:319
-#, fuzzy
 msgid "Subsection Appendix"
-msgstr "Подраздел"
+msgstr "Подраздел приложение"
 
 # src/LColor.C:64
 #: lib/layouts/aastex62.layout:261
-#, fuzzy
 msgid "\\Alph{appendix}\\arabic{subappendix}."
-msgstr "избор"
+msgstr "\\Alph{appendix}\\arabic{subappendix}."
 
 # src/ext_l10n.h:373
 #: lib/layouts/aastex62.layout:269 lib/layouts/copernicus.layout:327
-#, fuzzy
 msgid "Subsubappendix"
-msgstr "Под-подраздел"
+msgstr "Под-подприложиние"
 
 # src/ext_l10n.h:373
 #: lib/layouts/aastex62.layout:273 lib/layouts/copernicus.layout:331
-#, fuzzy
 msgid "Subsubsection Appendix"
-msgstr "Под-подраздел"
+msgstr "Под-подраздел Приложение"
 
 # src/ext_l10n.h:373
 #: lib/layouts/aastex62.layout:277
-#, fuzzy
 msgid "\\Alph{appendix}\\arabic{subappendix}.\\arabic{subsubappendix}."
-msgstr "Под-подраздел"
+msgstr "\\Alph{appendix}\\arabic{subappendix}.\\arabic{subsubappendix}."
 
 #: lib/layouts/achemso.layout:3 lib/examples/Articles:0
 msgid "American Chemical Society (ACS)"
-msgstr ""
+msgstr "Американско химическо общество (ACS)"
 
 # src/ext_l10n.h:375
 #: lib/layouts/achemso.layout:75 lib/layouts/amsdefs.inc:41
 #: lib/layouts/apa.layout:291 lib/layouts/apax.inc:390
-#: lib/layouts/beamer.layout:260 lib/layouts/beamer.layout:315
-#: lib/layouts/beamer.layout:377 lib/layouts/beamer.layout:439
-#: lib/layouts/beamer.layout:998 lib/layouts/europecv.layout:201
+#: lib/layouts/beamer.layout:262 lib/layouts/beamer.layout:317
+#: lib/layouts/beamer.layout:379 lib/layouts/beamer.layout:441
+#: lib/layouts/beamer.layout:1000 lib/layouts/europecv.layout:201
 #: lib/layouts/iopart.layout:67 lib/layouts/jasatex.layout:75
 #: lib/layouts/memoir.layout:68 lib/layouts/revtex4-x.inc:245
 #: lib/layouts/scrclass.inc:142 lib/layouts/scrclass.inc:155
 #: lib/layouts/scrclass.inc:168 lib/layouts/scrclass.inc:324
 #: lib/layouts/scrclass.inc:349 lib/layouts/siamltex.layout:206
-#: lib/layouts/simplecv.layout:52 lib/layouts/stdinsets.inc:694
+#: lib/layouts/simplecv.layout:52 lib/layouts/stdinsets.inc:695
 #: lib/layouts/stdsections.inc:32 lib/layouts/stdsections.inc:76
 #: lib/layouts/stdsections.inc:117 lib/layouts/tufte-book.layout:98
 #: lib/layouts/tufte-book.layout:129 lib/layouts/tufte-handout.layout:40
 msgid "Short Title|S"
-msgstr "Кратък надпис"
+msgstr "Кратки заглавия"
 
 #: lib/layouts/achemso.layout:76
 msgid "Short title which will appear in the running header"
-msgstr ""
+msgstr "Кратко име, което ще се появи в подвижно заглавие"
 
 # src/frontends/gnome/FormRef.C:301
 #: lib/layouts/achemso.layout:119 lib/layouts/acmart.layout:125
-#, fuzzy
 msgid "Short name"
-msgstr "Име:"
+msgstr "Кратко име"
 
 # src/lyxrc.C:1676
 #: lib/layouts/achemso.layout:120
-#, fuzzy
 msgid "Short name which appears in the footer of the title page"
-msgstr "Опция за обръщане на реда за печат на страниците."
+msgstr "Кратко име което се появява в долния колшнтштул на заглавната страница"
 
 # src/ext_l10n.h:221
 #: lib/layouts/achemso.layout:131
-#, fuzzy
 msgid "Alt Affiliation"
-msgstr "Дефиниция"
+msgstr "Алтернат. принадлежност"
 
 # src/ext_l10n.h:221
 #: lib/layouts/achemso.layout:144
-#, fuzzy
 msgid "Also Affiliation"
-msgstr "Дефиниция"
+msgstr "Също принадлежност"
 
 #: lib/layouts/achemso.layout:157 lib/layouts/europasscv.layout:141
 #: lib/layouts/europecv.layout:140 lib/layouts/lettre.layout:48
 #: lib/layouts/lettre.layout:381 lib/layouts/moderncv.layout:210
 #: lib/layouts/scrlttr2.layout:242 lib/configure.py:855
 msgid "Fax"
-msgstr ""
+msgstr "Факс"
 
 # src/LColor.C:63
 #: lib/layouts/achemso.layout:163 lib/layouts/europasscv.layout:144
 #: lib/layouts/europecv.layout:143 lib/layouts/lettre.layout:394
 #: lib/layouts/moderncv.layout:213
-#, fuzzy
 msgid "Fax:"
-msgstr "текст"
+msgstr "Факс:"
 
 # src/ext_l10n.h:308
 #: lib/layouts/achemso.layout:173 lib/layouts/dinbrief.layout:384
 #: lib/layouts/g-brief.layout:127 lib/layouts/moderncv.layout:184
 msgid "Phone"
-msgstr "Телефонен указател"
+msgstr "Телефон"
 
 # src/ext_l10n.h:308
 #: lib/layouts/achemso.layout:176 lib/layouts/g-brief.layout:130
 #: lib/layouts/moderncv.layout:187
-#, fuzzy
 msgid "Phone:"
-msgstr "Телефонен указател"
+msgstr "Телефон:"
 
 # src/frontends/xforms/form_document.C:244
 #: lib/layouts/achemso.layout:187
-#, fuzzy
 msgid "Abbreviations"
-msgstr "Абзац разделяне"
+msgstr "Съкращения"
 
 # src/frontends/xforms/form_document.C:244
 #: lib/layouts/achemso.layout:193
-#, fuzzy
 msgid "Abbreviations:"
-msgstr "Абзац разделяне"
+msgstr "Съкращения:"
 
 # src/ext_l10n.h:462
 #: lib/layouts/achemso.layout:206
@@ -9744,35 +9655,31 @@ msgstr ""
 
 # src/ext_l10n.h:175
 #: lib/layouts/achemso.layout:311
-#, fuzzy
 msgid "TOC entry"
-msgstr "Автор"
+msgstr "Точка от съдържание"
 
 #: lib/layouts/achemso.layout:315
 msgid "Graphical TOC Entry"
-msgstr ""
+msgstr "Графична точка от съдържание"
 
 # src/LColor.C:67
 #: lib/layouts/achemso.layout:321
-#, fuzzy
 msgid "Bibnote"
-msgstr "бележка"
+msgstr "Bibnote"
 
 # src/LColor.C:67
 #: lib/layouts/achemso.layout:325
-#, fuzzy
 msgid "bibnote"
-msgstr "бележка"
+msgstr "bibnote"
 
 # src/lyxfont.C:56
 #: lib/layouts/achemso.layout:344
-#, fuzzy
 msgid "Chemistry"
-msgstr "Дребен"
+msgstr "Химия"
 
 #: lib/layouts/achemso.layout:347
 msgid "chemistry"
-msgstr ""
+msgstr "химия"
 
 # src/ext_l10n.h:433
 #: lib/layouts/achemso.layout:359 lib/layouts/achemso.layout:362
@@ -9787,15 +9694,13 @@ msgstr ""
 # src/ext_l10n.h:387
 #: lib/layouts/acm-sigs.inc:33 lib/layouts/acmart.layout:398
 #: lib/layouts/sigplanconf.layout:188
-#, fuzzy
 msgid "Terms"
-msgstr "Теорема"
+msgstr "Условия"
 
 # src/frontends/xforms/FormParagraph.C:132
 #: lib/layouts/acm-sigs.inc:39
-#, fuzzy
 msgid "General terms:"
-msgstr "Общо"
+msgstr "Общи условия:"
 
 #: lib/layouts/acm-sigs.layout:3 lib/examples/Articles:0
 msgid "ACM SIG Proceedings (SP, Obsolete)"
@@ -9803,7 +9708,7 @@ msgstr ""
 
 #: lib/layouts/acmart.layout:3 lib/examples/Articles:0
 msgid "Association for Computing Machinery (ACM)"
-msgstr ""
+msgstr "Асоциация за изчислителна техника (ACM)"
 
 # src/ext_l10n.h:386
 #: lib/layouts/acmart.layout:86 lib/layouts/acmsiggraph-0-92.layout:335
@@ -9815,39 +9720,34 @@ msgstr "Благодарности"
 
 # src/ext_l10n.h:386
 #: lib/layouts/acmart.layout:100
-#, fuzzy
 msgid "Thanks: "
-msgstr "Благодарности:"
+msgstr "Благодарности: "
 
 # src/frontends/kde/paraextradlg.C:25 src/lyxfont.C:56
 #: lib/layouts/acmart.layout:106
-#, fuzzy
 msgid "ACM Journal"
-msgstr "Нормален"
+msgstr "Журнал ACM"
 
 # src/lyx_cb.C:675
 #: lib/layouts/acmart.layout:109 lib/layouts/apax.inc:341
 #: lib/layouts/apax.inc:349 lib/layouts/apax.inc:358 lib/layouts/apax.inc:366
-#, fuzzy
 msgid "Preamble"
-msgstr "LaTeX увод"
+msgstr "Преамбюл"
 
 #: lib/layouts/acmart.layout:111
 msgid "Journal's Short Name: "
-msgstr ""
+msgstr "Кратко име на журнала: "
 
 # src/ext_l10n.h:328 src/frontends/kde/refdlg.C:62
 # src/frontends/xforms/FormRef.C:36
 #: lib/layouts/acmart.layout:122
-#, fuzzy
 msgid "ACM Conference"
-msgstr "Препратка"
+msgstr "Конференсия ACM"
 
 # src/lyx.C:87
 #: lib/layouts/acmart.layout:129
-#, fuzzy
 msgid "Full name"
-msgstr "Параметри(p)|#p"
+msgstr "Пълно име"
 
 #: lib/layouts/acmart.layout:137
 msgid "Venue"
@@ -9856,21 +9756,18 @@ msgstr ""
 # src/ext_l10n.h:328 src/frontends/kde/refdlg.C:62
 # src/frontends/xforms/FormRef.C:36
 #: lib/layouts/acmart.layout:140
-#, fuzzy
 msgid "Conference Name: "
-msgstr "Препратка"
+msgstr "Име на конференция: "
 
 # src/ext_l10n.h:375
 #: lib/layouts/acmart.layout:147
-#, fuzzy
 msgid "Short title"
 msgstr "Подзаглавие"
 
 # src/ext_l10n.h:163
 #: lib/layouts/acmart.layout:184
-#, fuzzy
 msgid "Email address: "
-msgstr "Адреси"
+msgstr "Ел. адрес: "
 
 #: lib/layouts/acmart.layout:198
 msgid "ORCID: "
@@ -9878,61 +9775,52 @@ msgstr ""
 
 # src/ext_l10n.h:221
 #: lib/layouts/acmart.layout:218
-#, fuzzy
 msgid "Affiliation: "
-msgstr "Дефиниция"
+msgstr "Принадлежност: "
 
 # src/ext_l10n.h:221
 #: lib/layouts/acmart.layout:222
-#, fuzzy
 msgid "Additional Affiliation"
-msgstr "Дефиниция"
+msgstr "Допълнителна принадлежност"
 
 # src/ext_l10n.h:221
 #: lib/layouts/acmart.layout:224
-#, fuzzy
 msgid "Additional Affiliation: "
-msgstr "Дефиниция"
+msgstr "Допълнителна принадлежност: "
 
 # src/ext_l10n.h:320
 #: lib/layouts/acmart.layout:228 lib/layouts/acmart.layout:232
-#, fuzzy
 msgid "Position"
-msgstr "Допускане"
+msgstr "Позиция"
 
 # src/LyXAction.C:164
 #: lib/layouts/acmart.layout:237 lib/layouts/acmart.layout:239
 #: lib/layouts/paper.layout:181
-#, fuzzy
 msgid "Institution"
-msgstr "Вмъкни цитат"
+msgstr "Институция"
 
 # src/sp_form.C:86
 #: lib/layouts/acmart.layout:244 lib/layouts/acmart.layout:246
-#, fuzzy
 msgid "Department"
-msgstr "Замести"
+msgstr "Отдел"
 
 # src/ext_l10n.h:163
 #: lib/layouts/acmart.layout:252 lib/layouts/acmart.layout:254
-#, fuzzy
 msgid "Street Address"
-msgstr "Адреси"
+msgstr "Адрес на улица"
 
 # src/lyxfont.C:56
 #: lib/layouts/acmart.layout:260 lib/layouts/acmart.layout:262
 #: lib/layouts/iucr.layout:77 lib/layouts/iucr.layout:82
-#, fuzzy
 msgid "City"
-msgstr "Дребен"
+msgstr "Град"
 
 # src/frontends/xforms/FormDocument.C:279
 # src/frontends/xforms/FormParagraph.C:133
 #: lib/layouts/acmart.layout:268 lib/layouts/acmart.layout:270
 #: lib/layouts/iucr.layout:99 lib/layouts/iucr.layout:102
-#, fuzzy
 msgid "Country"
-msgstr "Екстри"
+msgstr "Област"
 
 # src/ext_l10n.h:362
 #: lib/layouts/acmart.layout:276 lib/layouts/acmart.layout:278
@@ -9942,9 +9830,8 @@ msgstr "Държава"
 
 # src/ext_l10n.h:202
 #: lib/layouts/acmart.layout:284 lib/layouts/acmart.layout:286
-#, fuzzy
 msgid "Postal Code"
-msgstr "Коментар"
+msgstr "Пощенски код"
 
 # src/ext_l10n.h:246
 #: lib/layouts/acmart.layout:292
@@ -9966,9 +9853,8 @@ msgstr "подзаглавие"
 
 # src/ext_l10n.h:375
 #: lib/layouts/acmart.layout:310
-#, fuzzy
 msgid "Subtitle Note: "
-msgstr "подзаглавие"
+msgstr "Бележка на подзаглавие: "
 
 # src/ext_l10n.h:175
 #: lib/layouts/acmart.layout:314 lib/layouts/apax.inc:304
@@ -9985,16 +9871,14 @@ msgstr "Бележка: "
 # src/frontends/kde/dlg/tabcreatedlgdata.C:107
 # src/frontends/xforms/form_tabular_create.C:45
 #: lib/layouts/acmart.layout:320
-#, fuzzy
 msgid "ACM Volume"
-msgstr "Колони"
+msgstr "Том ACM"
 
 # src/frontends/kde/dlg/tabcreatedlgdata.C:107
 # src/frontends/xforms/form_tabular_create.C:45
 #: lib/layouts/acmart.layout:322
-#, fuzzy
 msgid "Volume: "
-msgstr "Колони"
+msgstr "Том: "
 
 # src/mathed/formula.C:929
 #: lib/layouts/acmart.layout:326
@@ -10016,9 +9900,8 @@ msgstr "Вертикално разстояние"
 
 # src/frontends/xforms/form_paragraph.C:153
 #: lib/layouts/acmart.layout:334
-#, fuzzy
 msgid "Article: "
-msgstr "Вертикално разстояние"
+msgstr "Статия: "
 
 # src/lyx_gui_misc.C:430
 #: lib/layouts/acmart.layout:338
@@ -10028,21 +9911,18 @@ msgstr "годена"
 
 # src/lyx_gui_misc.C:430
 #: lib/layouts/acmart.layout:340
-#, fuzzy
 msgid "Year: "
-msgstr "годена"
+msgstr "Година: "
 
 # src/frontends/xforms/FormPreferences.C:261
 #: lib/layouts/acmart.layout:344
-#, fuzzy
 msgid "ACM Month"
-msgstr "месец"
+msgstr "Месец ACM"
 
 # src/frontends/xforms/FormPreferences.C:261
 #: lib/layouts/acmart.layout:346
-#, fuzzy
 msgid "Month: "
-msgstr "месец"
+msgstr "Месец: "
 
 #: lib/layouts/acmart.layout:350
 msgid "ACM Art Seq Num"
@@ -10050,9 +9930,8 @@ msgstr ""
 
 # src/mathed/formula.C:929
 #: lib/layouts/acmart.layout:352
-#, fuzzy
 msgid "Article Sequential Number: "
-msgstr "Номериране"
+msgstr "Пореден номер на статия: "
 
 #: lib/layouts/acmart.layout:356
 msgid "ACM Submission ID"
@@ -10070,7 +9949,7 @@ msgstr ""
 
 #: lib/layouts/acmart.layout:364
 msgid "Price: "
-msgstr ""
+msgstr "Цена: "
 
 #: lib/layouts/acmart.layout:368
 msgid "ACM ISBN"
@@ -10106,15 +9985,13 @@ msgstr ""
 
 # src/lyx_gui_misc.C:430
 #: lib/layouts/acmart.layout:392
-#, fuzzy
 msgid "Start Page"
-msgstr "Завършване на страница"
+msgstr "Начална страница"
 
 # src/frontends/xforms/form_print.C:112
 #: lib/layouts/acmart.layout:394
-#, fuzzy
 msgid "Start Page: "
-msgstr "Страници:"
+msgstr "Начална страница: "
 
 # src/ext_l10n.h:387
 #: lib/layouts/acmart.layout:400
@@ -10124,13 +10001,12 @@ msgstr "Теорема"
 
 # src/ext_l10n.h:263
 #: lib/layouts/acmart.layout:406
-#, fuzzy
 msgid "Keywords: "
-msgstr "Ключови думи:"
+msgstr "Ключови думи: "
 
 #: lib/layouts/acmart.layout:410
 msgid "CCSXML"
-msgstr ""
+msgstr "CCSXML"
 
 #: lib/layouts/acmart.layout:421
 msgid "Computing Classification Scheme (XML): "
@@ -10138,9 +10014,8 @@ msgstr ""
 
 # src/ext_l10n.h:223
 #: lib/layouts/acmart.layout:432
-#, fuzzy
 msgid "CCS Description"
-msgstr "Описание"
+msgstr "Описание CCS"
 
 #: lib/layouts/acmart.layout:435
 msgid "Significance"
@@ -10148,33 +10023,28 @@ msgstr ""
 
 # src/ext_l10n.h:367
 #: lib/layouts/acmart.layout:437
-#, fuzzy
 msgid "Computing Classification Scheme: "
-msgstr "Тема"
+msgstr "Изчислителна класификационна схема: "
 
 # src/ext_l10n.h:209
 #: lib/layouts/acmart.layout:450
-#, fuzzy
 msgid "Set Copyright"
 msgstr "Авторски права"
 
 # src/ext_l10n.h:209
 #: lib/layouts/acmart.layout:452
-#, fuzzy
 msgid "Set Copyright: "
-msgstr "Авторски права"
+msgstr "Авторски права: "
 
 # src/ext_l10n.h:209
 #: lib/layouts/acmart.layout:456
-#, fuzzy
 msgid "Copyright Year"
-msgstr "Авторски права"
+msgstr "Година на авторски права"
 
 # src/ext_l10n.h:209
 #: lib/layouts/acmart.layout:458
-#, fuzzy
 msgid "Copyright Year: "
-msgstr "Авторски права"
+msgstr "Година за авторски права: "
 
 # src/lyx_gui_misc.C:430
 #: lib/layouts/acmart.layout:462 lib/layouts/acmart.layout:465
@@ -10196,9 +10066,8 @@ msgstr ""
 
 # src/ext_l10n.h:327
 #: lib/layouts/acmart.layout:477
-#, fuzzy
 msgid "Received: "
-msgstr "Получен"
+msgstr "Получен: "
 
 # src/ext_l10n.h:375
 #: lib/layouts/acmart.layout:485
@@ -10228,9 +10097,9 @@ msgid "Margin figure (sigchi-a only)"
 msgstr "само главния файл"
 
 # src/ext_l10n.h:244
-#: lib/layouts/acmart.layout:526 lib/layouts/beamer.layout:1724
+#: lib/layouts/acmart.layout:526 lib/layouts/beamer.layout:1728
 #: lib/layouts/powerdot.layout:577 lib/layouts/sciposter.layout:109
-#: lib/layouts/stdfloats.inc:33 lib/layouts/tufte-book.layout:286
+#: lib/layouts/stdfloats.inc:33 lib/layouts/tufte-book.layout:292
 msgid "List of Figures"
 msgstr "Списък на изображенията"
 
@@ -10241,9 +10110,9 @@ msgstr ""
 # src/frontends/gnome/FormToc.C:108 src/frontends/gnome/FormToc.C:185
 # src/frontends/kde/FormToc.C:177 src/frontends/kde/FormToc.C:178
 # src/frontends/kde/tocdlg.C:30 src/insets/insettoc.C:28
-#: lib/layouts/acmart.layout:539 lib/layouts/beamer.layout:1711
+#: lib/layouts/acmart.layout:539 lib/layouts/beamer.layout:1715
 #: lib/layouts/powerdot.layout:560 lib/layouts/sciposter.layout:123
-#: lib/layouts/stdfloats.inc:18 lib/layouts/tufte-book.layout:270
+#: lib/layouts/stdfloats.inc:18 lib/layouts/tufte-book.layout:276
 msgid "List of Tables"
 msgstr "Списък на таблиците"
 
@@ -10256,7 +10125,7 @@ msgid "Definitions & Theorems"
 msgstr "Определения и теореми"
 
 # src/frontends/xforms/form_preferences.C:926
-#: lib/layouts/acmart.layout:562 lib/layouts/beamer.layout:1322
+#: lib/layouts/acmart.layout:562 lib/layouts/beamer.layout:1324
 #: lib/layouts/theorems-ams-bytype.inc:40
 #: lib/layouts/theorems-ams-chap-bytype.inc:82 lib/layouts/theorems-ams.inc:37
 #: lib/layouts/theorems-bytype.inc:35 lib/layouts/theorems-named.module:22
@@ -10264,7 +10133,7 @@ msgstr "Определения и теореми"
 msgid "Additional Theorem Text"
 msgstr "Допълнителен текст на теорема"
 
-#: lib/layouts/acmart.layout:563 lib/layouts/beamer.layout:1323
+#: lib/layouts/acmart.layout:563 lib/layouts/beamer.layout:1325
 #: lib/layouts/theorems-ams-bytype.inc:41
 #: lib/layouts/theorems-ams-chap-bytype.inc:83 lib/layouts/theorems-ams.inc:38
 #: lib/layouts/theorems-bytype.inc:36 lib/layouts/theorems-named.module:23
@@ -10279,43 +10148,43 @@ msgstr "Допълнителен текст добавен към заглавн
 #: lib/layouts/theorems-bytype.inc:49
 #: lib/layouts/theorems-without-preamble.inc:62 lib/layouts/theorems.inc:52
 msgid "Theorem \\thetheorem."
-msgstr "Теорема \\thetheorem."
+msgstr "Теорема „\\thetheorem“"
 
 # src/ext_l10n.h:320
 #: lib/layouts/acmart.layout:591 lib/layouts/theorems-ams.inc:81
 #: lib/layouts/theorems.inc:81
 msgid "Corollary \\thetheorem."
-msgstr "Следствие \\thetheorem."
+msgstr "Следствие „\\thetheorem“"
 
 #: lib/layouts/acmart.layout:598 lib/layouts/theorems-ams.inc:101
 #: lib/layouts/theorems.inc:101
 msgid "Lemma \\thetheorem."
-msgstr "Лема \\thetheorem."
+msgstr "Лема „\\thetheorem“"
 
 # src/ext_l10n.h:320
 #: lib/layouts/acmart.layout:605 lib/layouts/theorems-ams.inc:121
 #: lib/layouts/theorems.inc:121
 msgid "Proposition \\thetheorem."
-msgstr "Твърдение \\thetheorem."
+msgstr "Твърдение „\\thetheorem“"
 
 # src/ext_l10n.h:291 src/insets/insetinfo.C:77 src/insets/insetinfo.C:102
 # src/insets/insetinfo.C:231
 #: lib/layouts/acmart.layout:612 lib/layouts/theorems-ams.inc:141
 #: lib/layouts/theorems.inc:141
 msgid "Conjecture \\thetheorem."
-msgstr "Предположение \\thetheorem."
+msgstr "Предположение „\\thetheorem“"
 
 # src/ext_l10n.h:221
 #: lib/layouts/acmart.layout:619 lib/layouts/theorems-ams.inc:181
 #: lib/layouts/theorems.inc:181
 msgid "Definition \\thetheorem."
-msgstr "Определение \\thetheorem."
+msgstr "Определение „\\thetheorem“"
 
 # src/ext_l10n.h:232
 #: lib/layouts/acmart.layout:632 lib/layouts/theorems-ams.inc:207
 #: lib/layouts/theorems.inc:207
 msgid "Example \\thetheorem."
-msgstr "Пример \\thetheorem."
+msgstr "Пример „\\thetheorem“"
 
 #: lib/layouts/acmart.layout:635
 #, fuzzy
@@ -10361,21 +10230,20 @@ msgstr ""
 #: lib/layouts/sigplanconf.layout:242 lib/layouts/spie.layout:100
 #: lib/examples/Articles:0
 msgid "Acknowledgments"
-msgstr ""
+msgstr "Благодарности"
 
 #: lib/layouts/acmart.layout:675 lib/layouts/acmart.layout:679
 msgid "Grant Sponsor"
-msgstr ""
+msgstr "Спонсор на грант"
 
 #: lib/layouts/acmart.layout:683 lib/layouts/acmart.layout:719
 msgid "Sponsor ID"
-msgstr ""
+msgstr "Спонсор ИН"
 
 # src/frontends/kde/refdlg.C:63
 #: lib/layouts/acmart.layout:704 lib/layouts/acmart.layout:708
-#, fuzzy
 msgid "Grant Number"
-msgstr "Номер на страница"
+msgstr "Номер на грант"
 
 #: lib/layouts/acmsiggraph-0-92.layout:3 lib/examples/Articles:0
 msgid "ACM SIGGGRAPH 0.92 (obsolete)"
@@ -10411,73 +10279,63 @@ msgstr "Номериране"
 
 # src/mathed/formula.C:929
 #: lib/layouts/acmsiggraph-0-92.layout:103 lib/layouts/acmsiggraph.layout:95
-#, fuzzy
 msgid "Article number:"
-msgstr "Номериране"
+msgstr "Номер на статия: "
 
 # src/ext_l10n.h:209
 #: lib/layouts/acmsiggraph-0-92.layout:107
-#, fuzzy
 msgid "Set copyright"
 msgstr "Авторски права"
 
 # src/ext_l10n.h:209
 #: lib/layouts/acmsiggraph-0-92.layout:110
-#, fuzzy
 msgid "Copyright type:"
-msgstr "Авторски права"
+msgstr "Вид авторско право:"
 
 # src/ext_l10n.h:209
 #: lib/layouts/acmsiggraph-0-92.layout:114
-#, fuzzy
 msgid "Copyright year"
-msgstr "Авторски права"
+msgstr "Година на авторско право"
 
 # src/ext_l10n.h:209
 #: lib/layouts/acmsiggraph-0-92.layout:117
-#, fuzzy
 msgid "Year of copyright:"
-msgstr "Авторски права"
+msgstr "Година на авторско право:"
 
 # src/ext_l10n.h:328 src/frontends/kde/refdlg.C:62
 # src/frontends/xforms/FormRef.C:36
 #: lib/layouts/acmsiggraph-0-92.layout:125
-#, fuzzy
 msgid "Conference info"
-msgstr "Препратка"
+msgstr "Информация за конференсия"
 
 # src/frontends/kde/refdlg.C:51
 #: lib/layouts/acmsiggraph-0-92.layout:128
-#, fuzzy
 msgid "Conference info:"
-msgstr "Препратка :"
+msgstr "Информация за конференсия:"
 
 # src/ext_l10n.h:328 src/frontends/kde/refdlg.C:62
 # src/frontends/xforms/FormRef.C:36
 #: lib/layouts/acmsiggraph-0-92.layout:132
-#, fuzzy
 msgid "Conference name"
-msgstr "Препратка"
+msgstr "Име на конференсия"
 
 #: lib/layouts/acmsiggraph-0-92.layout:137
 msgid "ISBN"
-msgstr ""
+msgstr "ISBN"
 
 #: lib/layouts/acmsiggraph-0-92.layout:140
 msgid "ISBN:"
-msgstr ""
+msgstr "ISBN:"
 
 #: lib/layouts/acmsiggraph-0-92.layout:144 lib/layouts/sigplanconf.layout:127
-#, fuzzy
 msgid "DOI"
-msgstr "DIA"
+msgstr "DOI"
 
 # src/frontends/xforms/form_paragraph.C:153
 #: lib/layouts/acmsiggraph-0-92.layout:147
 #: lib/layouts/acmsiggraph-0-92.layout:154 lib/layouts/acmsiggraph.layout:102
-#, fuzzy
 msgid "Article DOI:"
-msgstr "Вертикално разстояние"
+msgstr "Статия DOI:"
 
 #: lib/layouts/acmsiggraph-0-92.layout:151 lib/layouts/acmsiggraph.layout:99
 msgid "TOG article DOI"
@@ -10496,9 +10354,8 @@ msgstr "PDF автор:"
 # src/ext_l10n.h:263
 #: lib/layouts/acmsiggraph-0-92.layout:198
 #: lib/layouts/acmsiggraph-0-92.layout:203
-#, fuzzy
 msgid "Keyword list"
-msgstr "Ключови дума"
+msgstr "Списък с ключови думи"
 
 # src/LColor.C:75
 #: lib/layouts/acmsiggraph-0-92.layout:207
@@ -10566,17 +10423,16 @@ msgstr "Брой копия за печат"
 #: lib/layouts/acmsiggraph-0-92.layout:313
 #: lib/layouts/acmsiggraph-0-92.layout:314 lib/layouts/acmsiggraph.layout:269
 #: lib/layouts/acmsiggraph.layout:270
-#, fuzzy
 msgid "Subcategory"
-msgstr "Заглавие"
+msgstr "Подкатегория"
 
 #: lib/layouts/acmsiggraph-0-92.layout:319 lib/layouts/acmsiggraph.layout:275
 msgid "Third-level"
-msgstr ""
+msgstr "Трето ниво"
 
 #: lib/layouts/acmsiggraph-0-92.layout:320 lib/layouts/acmsiggraph.layout:276
 msgid "Third-level of the category"
-msgstr ""
+msgstr "Трето ниво на категория"
 
 # src/ext_l10n.h:375
 #: lib/layouts/acmsiggraph-0-92.layout:326 lib/layouts/acmsiggraph.layout:282
@@ -10593,9 +10449,8 @@ msgstr "Подзаглавие"
 # src/layout_forms.C:23
 #: lib/layouts/acmsiggraph-0-92.layout:339 lib/layouts/acmsiggraph.layout:295
 #: lib/layouts/jss.layout:183 lib/layouts/jss.layout:185
-#, fuzzy
 msgid "E-mail"
-msgstr "Семейство(F):|#F"
+msgstr "Ел. поща"
 
 #: lib/layouts/acmsiggraph.layout:3
 msgid "ACM SIGGRAPH (older than 0.91, obsolete)"
@@ -10607,7 +10462,7 @@ msgstr ""
 
 #: lib/layouts/acmsiggraph.layout:110
 msgid "Project URL:"
-msgstr ""
+msgstr "URL на проекта:"
 
 #: lib/layouts/acmsiggraph.layout:114
 msgid "TOG video URL"
@@ -10615,9 +10470,8 @@ msgstr ""
 
 # src/LyXAction.C:261
 #: lib/layouts/acmsiggraph.layout:117
-#, fuzzy
 msgid "Video URL:"
-msgstr "Вмъкни етикет"
+msgstr "Видео URL:"
 
 #: lib/layouts/acmsiggraph.layout:121
 msgid "TOG data URL"
@@ -10642,11 +10496,11 @@ msgstr "Вмъкни етикет"
 
 #: lib/layouts/agums.layout:3
 msgid "American Geophysical Union (AGUPLUS Manuscript)"
-msgstr ""
+msgstr "Американски геофизичен съюз (ръкопис AGUPLUS)"
 
 # src/ext_l10n.h:345
 #: lib/layouts/aguplus.inc:37 lib/layouts/amsart.layout:77
-#: lib/layouts/amsbook.layout:86 lib/layouts/beamer.layout:332
+#: lib/layouts/amsbook.layout:86 lib/layouts/beamer.layout:334
 #: lib/layouts/egs.layout:676 lib/layouts/isprs.layout:192
 #: lib/layouts/spie.layout:32 lib/layouts/stdstarsections.inc:43
 #: lib/layouts/svcommon.inc:278
@@ -10655,7 +10509,7 @@ msgstr "Раздел*"
 
 # src/ext_l10n.h:372
 #: lib/layouts/aguplus.inc:52 lib/layouts/amsart.layout:119
-#: lib/layouts/amsbook.layout:95 lib/layouts/beamer.layout:394
+#: lib/layouts/amsbook.layout:95 lib/layouts/beamer.layout:396
 #: lib/layouts/egs.layout:696 lib/layouts/isprs.layout:203
 #: lib/layouts/stdstarsections.inc:58 lib/layouts/svcommon.inc:286
 msgid "Subsection*"
@@ -10684,30 +10538,26 @@ msgstr "Абзац*"
 # src/ext_l10n.h:270
 #: lib/layouts/aguplus.inc:80 lib/layouts/customHeadersFooters.module:12
 #: lib/layouts/foils.layout:215 lib/layouts/simplecv.layout:143
-#, fuzzy
 msgid "Left Header"
-msgstr "Заглавие"
+msgstr "Надпис горе вляво"
 
 # src/ext_l10n.h:270
 #: lib/layouts/aguplus.inc:93 lib/layouts/customHeadersFooters.module:19
 #: lib/layouts/foils.layout:219
-#, fuzzy
 msgid "Left Header:"
-msgstr "Заглавие"
+msgstr "Наспис горе вляво:"
 
 # src/ext_l10n.h:337
 #: lib/layouts/aguplus.inc:103 lib/layouts/customHeadersFooters.module:40
 #: lib/layouts/foils.layout:223 lib/layouts/simplecv.layout:162
-#, fuzzy
 msgid "Right Header"
-msgstr "Заглавие"
+msgstr "Надпис горе вдясно"
 
 # src/ext_l10n.h:337
 #: lib/layouts/aguplus.inc:107 lib/layouts/customHeadersFooters.module:43
 #: lib/layouts/foils.layout:227
-#, fuzzy
 msgid "Right Header:"
-msgstr "Заглавие"
+msgstr "Надпис горе вдясно:"
 
 # src/ext_l10n.h:327
 #: lib/layouts/aguplus.inc:115 lib/layouts/copernicus.layout:176
@@ -10815,7 +10665,7 @@ msgid "Planotable"
 msgstr "Таблица"
 
 # src/frontends/xforms/FormTabular.C:133
-#: lib/layouts/aguplus.inc:211 lib/layouts/beamer.layout:1706
+#: lib/layouts/aguplus.inc:211 lib/layouts/beamer.layout:1710
 #: lib/layouts/powerdot.layout:553 lib/layouts/powerdot.layout:631
 #: lib/layouts/sciposter.layout:118 lib/layouts/stdfloats.inc:13
 #: lib/ui/stdtoolbars.inc:153 src/insets/Inset.cpp:104
@@ -10835,7 +10685,7 @@ msgstr "Таблица"
 
 #: lib/layouts/agutex.layout:3 lib/examples/Articles:0
 msgid "American Geophysical Union (AGUTeX)"
-msgstr ""
+msgstr "Американски геофизичен съюз (AGUTeX)"
 
 # src/ext_l10n.h:175
 #: lib/layouts/agutex.layout:77
@@ -10845,9 +10695,8 @@ msgstr "Автори"
 # src/ext_l10n.h:221
 #: lib/layouts/agutex.layout:100 lib/layouts/agutex.layout:104
 #: lib/layouts/copernicus.layout:92
-#, fuzzy
 msgid "Affiliation Mark"
-msgstr "Дефиниция"
+msgstr "Знак за принадлежност"
 
 #: lib/layouts/agutex.layout:133
 msgid "Consecutive number for the author affiliations"
@@ -10855,29 +10704,25 @@ msgstr ""
 
 # src/ext_l10n.h:221
 #: lib/layouts/agutex.layout:138
-#, fuzzy
 msgid "Author affiliation:"
-msgstr "Дефиниция"
+msgstr "Принадлежност на автора:"
 
 # src/ext_l10n.h:202
 #: lib/layouts/agutex.layout:205
-#, fuzzy
 msgid "Acknowledgments."
-msgstr "complement"
+msgstr "Благодарности."
 
 # src/ext_l10n.h:169
 #: lib/layouts/algorithm2e.module:2
-#, fuzzy
 msgid "Algorithm2e Float"
-msgstr "Aлгоритъм"
+msgstr "Плаващ обект Алгоритъм2е"
 
 # src/form1.C:129 src/sp_form.C:58
 #: lib/layouts/algorithm2e.module:3 lib/layouts/bicaption.module:3
 #: lib/layouts/figs-within-sections.module:3
 #: lib/layouts/tabs-within-sections.module:3
-#, fuzzy
 msgid "Floats & Captions"
-msgstr "Опции на класа"
+msgstr "Плаващи обекти и надписи"
 
 #: lib/layouts/algorithm2e.module:8
 msgid ""
@@ -10894,27 +10739,24 @@ msgstr "Списък на алгоритмите"
 
 #: lib/layouts/amsart.layout:3 lib/layouts/amsbook.layout:3
 #: lib/examples/Articles:0
-#, fuzzy
 msgid "American Mathematical Society (AMS)"
-msgstr "Книга на Американско математическо общество (AMS)"
+msgstr "Американско математическо общество (AMS)"
 
 # src/LColor.C:64
 #: lib/layouts/amsart.layout:87
-#, fuzzy
 msgid "SpecialSection"
-msgstr "избор"
+msgstr "Специален раздел"
 
 # src/LColor.C:64
 #: lib/layouts/amsart.layout:96
-#, fuzzy
 msgid "SpecialSection*"
-msgstr "избор"
+msgstr "Специален раздел*"
 
 # src/mathed/formula.C:929
 # падащ списък на контекста
-#: lib/layouts/amsart.layout:98 lib/layouts/beamer.layout:334
-#: lib/layouts/beamer.layout:396 lib/layouts/beamer.layout:458
-#: lib/layouts/memoir.layout:248 lib/layouts/stdinsets.inc:712
+#: lib/layouts/amsart.layout:98 lib/layouts/beamer.layout:336
+#: lib/layouts/beamer.layout:398 lib/layouts/beamer.layout:460
+#: lib/layouts/memoir.layout:248 lib/layouts/stdinsets.inc:713
 #: lib/layouts/stdstarsections.inc:15 lib/layouts/stdstarsections.inc:30
 #: lib/layouts/stdstarsections.inc:45 lib/layouts/stdstarsections.inc:60
 #: lib/layouts/stdstarsections.inc:75 lib/layouts/stdstarsections.inc:90
@@ -10924,7 +10766,7 @@ msgstr "без номера"
 
 # src/ext_l10n.h:374
 #: lib/layouts/amsart.layout:140 lib/layouts/amsbook.layout:103
-#: lib/layouts/beamer.layout:456 lib/layouts/isprs.layout:212
+#: lib/layouts/beamer.layout:458 lib/layouts/isprs.layout:212
 #: lib/layouts/stdstarsections.inc:73 lib/layouts/svcommon.inc:294
 msgid "Subsubsection*"
 msgstr "Подподраздел*"
@@ -10952,8 +10794,8 @@ msgstr "Глава за примири"
 #: lib/layouts/amsbook.layout:166 lib/layouts/apa.layout:412
 #: lib/layouts/apa.layout:450 lib/layouts/apa.layout:486
 #: lib/layouts/apax.inc:512 lib/layouts/apax.inc:550 lib/layouts/apax.inc:586
-#: lib/layouts/beamer.layout:107 lib/layouts/beamer.layout:160
-#: lib/layouts/beamer.layout:203 lib/layouts/beamer.layout:788
+#: lib/layouts/beamer.layout:109 lib/layouts/beamer.layout:162
+#: lib/layouts/beamer.layout:205 lib/layouts/beamer.layout:790
 #: lib/layouts/egs.layout:154 lib/layouts/egs.layout:188
 #: lib/layouts/egs.layout:224 lib/layouts/egs.layout:259
 #: lib/layouts/europasscv.layout:405 lib/layouts/foils.layout:105
@@ -10972,8 +10814,8 @@ msgstr "заглавна част на списък"
 #: lib/layouts/amsbook.layout:167 lib/layouts/apa.layout:413
 #: lib/layouts/apa.layout:451 lib/layouts/apa.layout:487
 #: lib/layouts/apax.inc:513 lib/layouts/apax.inc:551 lib/layouts/apax.inc:587
-#: lib/layouts/beamer.layout:108 lib/layouts/beamer.layout:161
-#: lib/layouts/beamer.layout:204 lib/layouts/beamer.layout:789
+#: lib/layouts/beamer.layout:110 lib/layouts/beamer.layout:163
+#: lib/layouts/beamer.layout:206 lib/layouts/beamer.layout:791
 #: lib/layouts/egs.layout:155 lib/layouts/egs.layout:189
 #: lib/layouts/egs.layout:225 lib/layouts/egs.layout:260
 #: lib/layouts/europasscv.layout:406 lib/layouts/foils.layout:106
@@ -10991,8 +10833,8 @@ msgstr "Заглавна част на списък (LaTeX код)"
 #: lib/layouts/amsbook.layout:168 lib/layouts/apa.layout:414
 #: lib/layouts/apa.layout:452 lib/layouts/apa.layout:488
 #: lib/layouts/apax.inc:514 lib/layouts/apax.inc:552 lib/layouts/apax.inc:588
-#: lib/layouts/beamer.layout:109 lib/layouts/beamer.layout:162
-#: lib/layouts/beamer.layout:205 lib/layouts/beamer.layout:790
+#: lib/layouts/beamer.layout:111 lib/layouts/beamer.layout:164
+#: lib/layouts/beamer.layout:207 lib/layouts/beamer.layout:792
 #: lib/layouts/egs.layout:156 lib/layouts/egs.layout:190
 #: lib/layouts/egs.layout:226 lib/layouts/egs.layout:261
 #: lib/layouts/europasscv.layout:407 lib/layouts/foils.layout:107
@@ -11042,13 +10884,12 @@ msgstr "Текущ адрес"
 # src/ext_l10n.h:163
 #: lib/layouts/amsdefs.inc:169
 msgid "Current address:"
-msgstr "Текущ адреси:"
+msgstr "Текущ адрес:"
 
 # src/ext_l10n.h:163
 #: lib/layouts/amsdefs.inc:181
-#, fuzzy
 msgid "E-mail address:"
-msgstr "Адреси"
+msgstr "Адрес ел. поща:"
 
 # src/ext_l10n.h:406 src/frontends/gnome/FormUrl.C:117
 # src/frontends/kde/urldlg.C:62 src/frontends/kde/urldlg.C:63
@@ -11059,15 +10900,13 @@ msgstr "URL:"
 
 # src/ext_l10n.h:263
 #: lib/layouts/amsdefs.inc:206
-#, fuzzy
 msgid "Key words and phrases:"
-msgstr "Ключови дума"
+msgstr "Ключови думи и фрази:"
 
 # src/ext_l10n.h:386
 #: lib/layouts/amsdefs.inc:218 lib/layouts/revtex4.layout:216
-#, fuzzy
 msgid "Thanks:"
-msgstr "Благодаря"
+msgstr "Благодарности:"
 
 # src/ext_l10n.h:220
 #: lib/layouts/amsdefs.inc:227
@@ -11077,9 +10916,8 @@ msgstr "Речник"
 # src/ext_l10n.h:219
 #: lib/layouts/amsdefs.inc:230 lib/layouts/svglobal.layout:132
 #: lib/layouts/svjog.layout:136 lib/layouts/svprobth.layout:165
-#, fuzzy
 msgid "Dedication:"
-msgstr "Посвещение"
+msgstr "Посвещение:"
 
 # src/ext_l10n.h:403
 #: lib/layouts/amsdefs.inc:238
@@ -11088,9 +10926,8 @@ msgstr "Преводач"
 
 # src/ext_l10n.h:403
 #: lib/layouts/amsdefs.inc:241
-#, fuzzy
 msgid "Translator:"
-msgstr "Преводач"
+msgstr "Преводач:"
 
 # src/ext_l10n.h:367
 #: lib/layouts/amsdefs.inc:251 lib/layouts/siamltex.layout:332
@@ -11104,19 +10941,17 @@ msgstr ""
 
 #: lib/layouts/apa.layout:3 lib/examples/Articles:0
 msgid "American Psychological Association (APA)"
-msgstr ""
+msgstr "Американска психологическа асоциация (APA)"
 
 # src/ext_l10n.h:337
 #: lib/layouts/apa.layout:58
-#, fuzzy
 msgid "RightHeader"
-msgstr "Заглавие"
+msgstr "Заглавие вдясно"
 
 # src/ext_l10n.h:337
 #: lib/layouts/apa.layout:67
-#, fuzzy
 msgid "Right header:"
-msgstr "Заглавие"
+msgstr "Заглавие вдясно:"
 
 #: lib/layouts/apa.layout:95 lib/layouts/apax.inc:263
 #: lib/layouts/maa-monthly.layout:43
@@ -11125,82 +10960,73 @@ msgstr "Резюме:"
 
 # src/ext_l10n.h:375
 #: lib/layouts/apa.layout:118 lib/layouts/apax.inc:63
-#, fuzzy
 msgid "Short title:"
-msgstr "Подзаглавие"
+msgstr "Кратко заглавие:"
 
 # src/ext_l10n.h:175
 #: lib/layouts/apa.layout:160 lib/layouts/apax.inc:101
-#, fuzzy
 msgid "TwoAuthors"
-msgstr "Автор"
+msgstr "Двама автори"
 
 # src/ext_l10n.h:175
 #: lib/layouts/apa.layout:168 lib/layouts/apax.inc:109
-#, fuzzy
 msgid "ThreeAuthors"
-msgstr "Автор"
+msgstr "Трима автори"
 
 # src/ext_l10n.h:175
 #: lib/layouts/apa.layout:176 lib/layouts/apax.inc:117
-#, fuzzy
 msgid "FourAuthors"
-msgstr "Автор"
+msgstr "Четирима автори"
 
 # src/ext_l10n.h:221
 #: lib/layouts/apa.layout:212 lib/layouts/apax.inc:191
-#, fuzzy
 msgid "TwoAffiliations"
-msgstr "Дефиниция"
+msgstr "Две принадлежности"
 
 # src/ext_l10n.h:221
 #: lib/layouts/apa.layout:220 lib/layouts/apax.inc:198
-#, fuzzy
 msgid "ThreeAffiliations"
-msgstr "Дефиниция"
+msgstr "Три принадлежности"
 
 # src/ext_l10n.h:221
 #: lib/layouts/apa.layout:228 lib/layouts/apax.inc:205
-#, fuzzy
 msgid "FourAffiliations"
-msgstr "Дефиниция"
+msgstr "Четири принадлежности"
 
 #: lib/layouts/apa.layout:256 lib/layouts/iucr.layout:254
 msgid "Acknowledgements:"
-msgstr "Признателност:"
+msgstr "Благодарности:"
 
 #: lib/layouts/apa.layout:273 lib/layouts/apax.inc:372
 msgid "ThickLine"
-msgstr ""
+msgstr "Дебела линия"
 
 # src/frontends/kde/dlg/parageneraldlgdata.C:107
 #: lib/layouts/apa.layout:284 lib/layouts/apax.inc:383
-#, fuzzy
 msgid "Centered"
-msgstr "Центринан"
+msgstr "центринан"
 
 # src/ext_l10n.h:361
 #: lib/layouts/apa.layout:285 lib/layouts/apax.inc:384
-#: lib/layouts/stdinsets.inc:688 src/insets/InsetCaption.cpp:440
-#, fuzzy
+#: lib/layouts/stdinsets.inc:689 src/insets/InsetCaption.cpp:436
 msgid "standard"
-msgstr "Стандартен"
+msgstr "стандартен"
 
 # src/frontends/xforms/FormPreferences.C:1278
 #: lib/layouts/apa.layout:292 lib/layouts/apax.inc:391
 #: lib/layouts/scrclass.inc:325 lib/layouts/scrclass.inc:350
-#: lib/layouts/stdinsets.inc:695
+#: lib/layouts/stdinsets.inc:696
 msgid "The caption as it appears in the list of figures/tables"
 msgstr "Надписа който ще се появи в сисъка с изображения и/или таблици."
 
 # src/ext_l10n.h:244
 #: lib/layouts/apa.layout:307 lib/layouts/apax.inc:406
 msgid "FitFigure"
-msgstr "Фигура"
+msgstr "Напасване на фигура"
 
 #: lib/layouts/apa.layout:313 lib/layouts/apax.inc:412
 msgid "FitBitmap"
-msgstr ""
+msgstr "Напасване на растер"
 
 # src/ext_l10n.h:369
 #: lib/layouts/apa.layout:380 lib/layouts/apax.inc:479
@@ -11215,30 +11041,28 @@ msgstr "Подабзац"
 # src/ext_l10n.h:215
 #: lib/layouts/apa.layout:408 lib/layouts/apa.layout:446
 #: lib/layouts/apax.inc:508 lib/layouts/apax.inc:546
-#: lib/layouts/beamer.layout:95 lib/layouts/beamer.layout:148
+#: lib/layouts/beamer.layout:97 lib/layouts/beamer.layout:150
 #: lib/layouts/egs.layout:184 lib/layouts/egs.layout:220
 #: lib/layouts/europasscv.layout:428 lib/layouts/powerdot.layout:299
 #: lib/layouts/powerdot.layout:364 lib/layouts/stdlists.inc:33
 #: lib/layouts/stdlists.inc:75 lib/layouts/theorems-case.inc:66
-#, fuzzy
 msgid "Custom Item|s"
-msgstr "Клиент"
+msgstr "Елемент от потребителя|Е"
 
 #: lib/layouts/apa.layout:409 lib/layouts/apa.layout:447
 #: lib/layouts/apax.inc:509 lib/layouts/apax.inc:547
-#: lib/layouts/beamer.layout:96 lib/layouts/beamer.layout:149
+#: lib/layouts/beamer.layout:98 lib/layouts/beamer.layout:151
 #: lib/layouts/egs.layout:185 lib/layouts/egs.layout:221
 #: lib/layouts/europasscv.layout:429 lib/layouts/powerdot.layout:300
 #: lib/layouts/powerdot.layout:365 lib/layouts/stdlists.inc:34
 #: lib/layouts/stdlists.inc:76 lib/layouts/theorems-case.inc:67
 msgid "A customized item string"
-msgstr ""
+msgstr "Текстов елемент от потребитела"
 
 # src/ext_l10n.h:458
 #: lib/layouts/apa.layout:465 lib/layouts/apax.inc:565
-#, fuzzy
 msgid "Seriate"
-msgstr "Сръбски"
+msgstr "Нареждам"
 
 #: lib/layouts/apa.layout:482 lib/layouts/apa.layout:483
 #: lib/layouts/apax.inc:582 lib/layouts/apax.inc:583
@@ -11248,24 +11072,21 @@ msgstr "(\\alph{enumii})"
 
 #: lib/layouts/apa6.layout:3 lib/examples/Articles:0
 msgid "American Psychological Association (APA), v. 6"
-msgstr ""
+msgstr "Американска психологическа асоциация (APA), вер. 6"
 
 #: lib/layouts/apa7.layout:3 lib/examples/Articles:0
-#, fuzzy
 msgid "American Psychological Association (APA), v. 7"
-msgstr "Книга на Американско математическо общество (AMS)"
+msgstr "Американска психологическа асоциация (APA), вер. 7"
 
 # src/ext_l10n.h:175
 #: lib/layouts/apax.inc:124
-#, fuzzy
 msgid "FiveAuthors"
-msgstr "Автор"
+msgstr "Пет автори"
 
 # src/ext_l10n.h:175
 #: lib/layouts/apax.inc:131
-#, fuzzy
 msgid "SixAuthors"
-msgstr "Автор"
+msgstr "Шест автори"
 
 # src/ext_l10n.h:270
 #: lib/layouts/apax.inc:138
@@ -11293,7 +11114,7 @@ msgstr "Дефиниция"
 
 # src/ext_l10n.h:291 src/insets/insetinfo.C:77 src/insets/insetinfo.C:102
 # src/insets/insetinfo.C:231
-#: lib/layouts/apax.inc:227 lib/layouts/beamer.layout:1653
+#: lib/layouts/apax.inc:227 lib/layouts/beamer.layout:1657
 #: lib/layouts/elsart.layout:470 lib/layouts/fixme.module:108
 #: lib/layouts/iopart.layout:106 lib/layouts/llncs.layout:394
 #: lib/layouts/powerdot.layout:215 lib/layouts/slides.layout:170
@@ -11328,9 +11149,8 @@ msgstr "бележка на автора:"
 
 # src/frontends/kde/paraextradlg.C:25 src/lyxfont.C:56
 #: lib/layouts/apax.inc:340 lib/layouts/egs.layout:416
-#, fuzzy
 msgid "Journal"
-msgstr "Нормален"
+msgstr "Журнал"
 
 # src/frontends/kde/dlg/tabcreatedlgdata.C:107
 # src/frontends/xforms/form_tabular_create.C:45
@@ -11342,9 +11162,8 @@ msgstr "Колони"
 # src/frontends/kde/dlg/tabcreatedlgdata.C:107
 # src/frontends/xforms/form_tabular_create.C:45
 #: lib/layouts/apax.inc:365
-#, fuzzy
 msgid "Volume"
-msgstr "Колони"
+msgstr "Том"
 
 #: lib/layouts/apax.inc:506
 msgid "*"
@@ -11374,9 +11193,8 @@ msgstr ""
 
 # src/ext_l10n.h:175
 #: lib/layouts/apax.inc:639 lib/layouts/apax.inc:661
-#, fuzzy
 msgid "Author-name"
-msgstr "Автор"
+msgstr "Автор-име"
 
 # src/ext_l10n.h:424
 #: lib/layouts/arab-article.layout:3
@@ -11392,8 +11210,8 @@ msgid "Article (Standard Class)"
 msgstr "Статия (стандартен вид)"
 
 # src/BufferView2.C:601 src/LyXAction.C:346 src/MenuBackend.C:433
-#: lib/layouts/article.layout:21 lib/layouts/beamer.layout:246
-#: lib/layouts/beamer.layout:275 lib/layouts/memoir.layout:66
+#: lib/layouts/article.layout:21 lib/layouts/beamer.layout:248
+#: lib/layouts/beamer.layout:277 lib/layouts/memoir.layout:66
 #: lib/layouts/mwart.layout:25 lib/layouts/paper.layout:55
 #: lib/layouts/scrartcl.layout:22 lib/layouts/scrclass.inc:77
 #: lib/layouts/stdcounters.inc:9 lib/layouts/stdsections.inc:12
@@ -11421,69 +11239,68 @@ msgstr "Прожектор"
 msgid "Presentations"
 msgstr "Презентации"
 
-#: lib/layouts/beamer.layout:88 lib/layouts/beamer.layout:137
-#: lib/layouts/beamer.layout:192 lib/layouts/beamer.layout:503
-#: lib/layouts/beamer.layout:571 lib/layouts/beamer.layout:629
-#: lib/layouts/beamer.layout:659 lib/layouts/beamer.layout:875
-#: lib/layouts/beamer.layout:904 lib/layouts/beamer.layout:1227
-#: lib/layouts/beamer.layout:1252 lib/layouts/beamer.layout:1279
-#: lib/layouts/beamer.layout:1445
+#: lib/layouts/beamer.layout:90 lib/layouts/beamer.layout:139
+#: lib/layouts/beamer.layout:194 lib/layouts/beamer.layout:505
+#: lib/layouts/beamer.layout:573 lib/layouts/beamer.layout:631
+#: lib/layouts/beamer.layout:661 lib/layouts/beamer.layout:877
+#: lib/layouts/beamer.layout:906 lib/layouts/beamer.layout:1229
+#: lib/layouts/beamer.layout:1254 lib/layouts/beamer.layout:1281
+#: lib/layouts/beamer.layout:1447
 msgid "Overlay Specifications|v"
 msgstr ""
 
-#: lib/layouts/beamer.layout:89 lib/layouts/beamer.layout:138
-#: lib/layouts/beamer.layout:193
+#: lib/layouts/beamer.layout:91 lib/layouts/beamer.layout:140
+#: lib/layouts/beamer.layout:195
 msgid "Overlay specifications for this list"
 msgstr ""
 
-#: lib/layouts/beamer.layout:99 lib/layouts/beamer.layout:152
-#: lib/layouts/beamer.layout:213 lib/layouts/beamer.layout:798
+#: lib/layouts/beamer.layout:101 lib/layouts/beamer.layout:154
+#: lib/layouts/beamer.layout:215 lib/layouts/beamer.layout:800
 #: lib/layouts/powerdot.layout:303 lib/layouts/powerdot.layout:368
 msgid "Item Overlay Specifications"
 msgstr ""
 
 # src/layout_forms.C:28
-#: lib/layouts/beamer.layout:100 lib/layouts/beamer.layout:153
-#: lib/layouts/beamer.layout:214 lib/layouts/beamer.layout:628
-#: lib/layouts/beamer.layout:658 lib/layouts/beamer.layout:799
-#: lib/layouts/beamer.layout:874 lib/layouts/beamer.layout:903
-#: lib/layouts/beamer.layout:1226 lib/layouts/beamer.layout:1251
-#: lib/layouts/beamer.layout:1278 lib/layouts/beamer.layout:1444
+#: lib/layouts/beamer.layout:102 lib/layouts/beamer.layout:155
+#: lib/layouts/beamer.layout:216 lib/layouts/beamer.layout:630
+#: lib/layouts/beamer.layout:660 lib/layouts/beamer.layout:801
+#: lib/layouts/beamer.layout:876 lib/layouts/beamer.layout:905
+#: lib/layouts/beamer.layout:1228 lib/layouts/beamer.layout:1253
+#: lib/layouts/beamer.layout:1280 lib/layouts/beamer.layout:1446
 #: lib/layouts/powerdot.layout:304 lib/layouts/powerdot.layout:369
 #, fuzzy
 msgid "On Slide"
 msgstr "Серия(S):|#S"
 
-#: lib/layouts/beamer.layout:101 lib/layouts/beamer.layout:154
-#: lib/layouts/beamer.layout:215 lib/layouts/beamer.layout:800
+#: lib/layouts/beamer.layout:103 lib/layouts/beamer.layout:156
+#: lib/layouts/beamer.layout:217 lib/layouts/beamer.layout:802
 #: lib/layouts/powerdot.layout:305 lib/layouts/powerdot.layout:370
 msgid "Overlay specifications for this item"
 msgstr ""
 
 # src/lyx_cb.C:198 src/lyxfunc.C:3055
-#: lib/layouts/beamer.layout:144
+#: lib/layouts/beamer.layout:146
 #, fuzzy
 msgid "Mini Template"
 msgstr "Шаблони"
 
-#: lib/layouts/beamer.layout:145
+#: lib/layouts/beamer.layout:147
 msgid "Mini template for this list (see beamer manual for details)"
 msgstr ""
 
 # src/frontends/xforms/form_tabular.C:113
-#: lib/layouts/beamer.layout:199
-#, fuzzy
+#: lib/layouts/beamer.layout:201
 msgid "Longest label|s"
-msgstr " Дълга таблица(L)|#L"
+msgstr "Най-дълъг етикат"
 
-#: lib/layouts/beamer.layout:200
+#: lib/layouts/beamer.layout:202
 msgid "The longest label in this list (to determine the indendation width)"
-msgstr ""
+msgstr "Най-дългия етикат в този списък (за определяне ширината на интервалите)"
 
 # src/ext_l10n.h:344
 # падащ списък на контекста
-#: lib/layouts/beamer.layout:247 lib/layouts/beamer.layout:289
-#: lib/layouts/beamer.layout:351 lib/layouts/beamer.layout:413
+#: lib/layouts/beamer.layout:249 lib/layouts/beamer.layout:291
+#: lib/layouts/beamer.layout:353 lib/layouts/beamer.layout:415
 #: lib/layouts/egs.layout:34 lib/layouts/egs.layout:57
 #: lib/layouts/europasscv.layout:265 lib/layouts/europecv.layout:194
 #: lib/layouts/foils.layout:46 lib/layouts/ltugboat.layout:49
@@ -11499,592 +11316,577 @@ msgstr ""
 msgid "Sectioning"
 msgstr "раздели"
 
-#: lib/layouts/beamer.layout:252 lib/layouts/beamer.layout:307
-#: lib/layouts/beamer.layout:340 lib/layouts/beamer.layout:369
-#: lib/layouts/beamer.layout:402 lib/layouts/beamer.layout:431
-#: lib/layouts/beamer.layout:464
+#: lib/layouts/beamer.layout:254 lib/layouts/beamer.layout:309
+#: lib/layouts/beamer.layout:342 lib/layouts/beamer.layout:371
+#: lib/layouts/beamer.layout:404 lib/layouts/beamer.layout:433
+#: lib/layouts/beamer.layout:466
 msgid "Mode"
-msgstr ""
+msgstr "Жанр"
 
 # src/LColor.C:64
-#: lib/layouts/beamer.layout:253 lib/layouts/beamer.layout:308
-#: lib/layouts/beamer.layout:341 lib/layouts/beamer.layout:370
-#: lib/layouts/beamer.layout:403 lib/layouts/beamer.layout:432
-#: lib/layouts/beamer.layout:465
-#, fuzzy
+#: lib/layouts/beamer.layout:255 lib/layouts/beamer.layout:310
+#: lib/layouts/beamer.layout:343 lib/layouts/beamer.layout:372
+#: lib/layouts/beamer.layout:405 lib/layouts/beamer.layout:434
+#: lib/layouts/beamer.layout:467
 msgid "Mode Specification|S"
-msgstr "избор"
+msgstr "Настройки на жанра"
 
-#: lib/layouts/beamer.layout:254 lib/layouts/beamer.layout:309
-#: lib/layouts/beamer.layout:342 lib/layouts/beamer.layout:371
-#: lib/layouts/beamer.layout:404 lib/layouts/beamer.layout:433
-#: lib/layouts/beamer.layout:466
+#: lib/layouts/beamer.layout:256 lib/layouts/beamer.layout:311
+#: lib/layouts/beamer.layout:344 lib/layouts/beamer.layout:373
+#: lib/layouts/beamer.layout:406 lib/layouts/beamer.layout:435
+#: lib/layouts/beamer.layout:468
 msgid "Specify in which mode (article, presentation etc.) this header appears"
 msgstr ""
-"Посочване режима (статия, презентация и т.н.), в който това заглавие се "
+"Посочване на жанра (статия, презентация и т.н.), в който това заглавие ще се "
 "появява."
 
 # src/frontends/xforms/FormPreferences.C:1278
-#: lib/layouts/beamer.layout:261 lib/layouts/memoir.layout:69
+#: lib/layouts/beamer.layout:263 lib/layouts/memoir.layout:69
 #: lib/layouts/scrclass.inc:143 lib/layouts/stdsections.inc:33
 #: lib/layouts/tufte-handout.layout:41
-#, fuzzy
 msgid "The part as it appears in the table of contents/running headers"
-msgstr "Името на формата, както ще се вижда в менютата."
+msgstr "Името на главата, както ще се появи в съдържанието и горния колинтитул."
 
 # src/ext_l10n.h:373
-#: lib/layouts/beamer.layout:304
-#, fuzzy
+#: lib/layouts/beamer.layout:306
 msgid "Section \\arabic{section}"
-msgstr "Под-подраздел"
+msgstr "Подраздел \\arabic{section}"
 
 # src/frontends/xforms/FormPreferences.C:1278
-#: lib/layouts/beamer.layout:316 lib/layouts/scrclass.inc:169
+#: lib/layouts/beamer.layout:318 lib/layouts/scrclass.inc:169
 #: lib/layouts/simplecv.layout:53 lib/layouts/stdsections.inc:118
 #: lib/layouts/tufte-book.layout:130
-#, fuzzy
 msgid "The section as it appears in the table of contents/running headers"
-msgstr "Името на формата, както ще се вижда в менютата."
+msgstr "Името на раздела, както ще се появи в съдържанието и горния колинтитул."
 
 # src/LColor.C:64
-#: lib/layouts/beamer.layout:328 lib/layouts/numarticle.inc:11
+#: lib/layouts/beamer.layout:330 lib/layouts/numarticle.inc:11
 #: lib/layouts/powerdot.layout:254
 msgid "\\Alph{section}"
 msgstr "\\Alph{section}"
 
 # src/ext_l10n.h:373
-#: lib/layouts/beamer.layout:366
-#, fuzzy
+#: lib/layouts/beamer.layout:368
 msgid "Subsection \\arabic{section}.\\arabic{subsection}"
-msgstr "Под-подраздел"
+msgstr "Подраздел \\arabic{section}.\\arabic{subsection}"
 
 # src/frontends/xforms/FormPreferences.C:1278
-#: lib/layouts/beamer.layout:378
-#, fuzzy
+#: lib/layouts/beamer.layout:380
 msgid "The subsection as it appears in the table of contents/running headers"
-msgstr "Името на формата, както ще се вижда в менютата."
+msgstr "Името на подраздела, както ще се появи в съдържанието и горния колинтитул."
 
 # src/ext_l10n.h:373
-#: lib/layouts/beamer.layout:390
+#: lib/layouts/beamer.layout:392
 msgid "\\arabic{section}.\\arabic{subsection}"
 msgstr "\\arabic{section}.\\arabic{subsection}"
 
 # src/ext_l10n.h:373
-#: lib/layouts/beamer.layout:428
-#, fuzzy
+#: lib/layouts/beamer.layout:430
 msgid ""
 "Subsubsection \\arabic{section}.\\arabic{subsection}.\\arabic{subsubsection}"
-msgstr "Под-подраздел"
+msgstr "Под-подраздел \\arabic{section}.\\arabic{subsection}.\\arabic{subsubsection}"
 
-#: lib/layouts/beamer.layout:440
+#: lib/layouts/beamer.layout:442
 msgid ""
 "The subsubsection as it appears in the table of contents/running headers"
 msgstr ""
+"Под-подраздела, както ще се появи в съдържанието и горния колититул"
 
 # src/ext_l10n.h:373
-#: lib/layouts/beamer.layout:452
-#, fuzzy
+#: lib/layouts/beamer.layout:454
 msgid "\\arabic{section}.\\arabic{subsection}.\\arabic{subsubsection}"
-msgstr "Под-подраздел"
+msgstr "\\arabic{section}.\\arabic{subsection}.\\arabic{subsubsection}"
 
 # src/lyx.C:87
-#: lib/layouts/beamer.layout:479 lib/layouts/beamer.layout:485
-#, fuzzy
+#: lib/layouts/beamer.layout:481 lib/layouts/beamer.layout:487
 msgid "Frame"
-msgstr "Параметри(p)|#p"
+msgstr "Рамка"
 
 # src/lyx.C:87
-#: lib/layouts/beamer.layout:480 lib/layouts/beamer.layout:565
-#: lib/layouts/beamer.layout:612 lib/layouts/beamer.layout:643
-#, fuzzy
+#: lib/layouts/beamer.layout:482 lib/layouts/beamer.layout:567
+#: lib/layouts/beamer.layout:614 lib/layouts/beamer.layout:645
 msgid "Frames"
-msgstr "Параметри(p)|#p"
+msgstr "Рамки"
 
 # src/ext_l10n.h:344
-#: lib/layouts/beamer.layout:502 lib/layouts/beamer.layout:937
-#: lib/layouts/beamer.layout:1314 lib/layouts/beamer.layout:1471
-#: lib/layouts/beamer.layout:1491 lib/layouts/beamer.layout:1511
-#: lib/layouts/beamer.layout:1531 lib/layouts/beamer.layout:1551
-#: lib/layouts/beamer.layout:1572 lib/layouts/beamer.layout:1593
-#: lib/layouts/beamer.layout:1614 lib/layouts/beamer.layout:1635
-#: lib/layouts/beamer.layout:1661 lib/layouts/pdfform.module:124
+#: lib/layouts/beamer.layout:504 lib/layouts/beamer.layout:939
+#: lib/layouts/beamer.layout:1316 lib/layouts/beamer.layout:1473
+#: lib/layouts/beamer.layout:1493 lib/layouts/beamer.layout:1513
+#: lib/layouts/beamer.layout:1533 lib/layouts/beamer.layout:1553
+#: lib/layouts/beamer.layout:1574 lib/layouts/beamer.layout:1595
+#: lib/layouts/beamer.layout:1616 lib/layouts/beamer.layout:1637
+#: lib/layouts/beamer.layout:1665 lib/layouts/pdfform.module:124
 #, fuzzy
 msgid "Action"
 msgstr "Раздел"
 
-#: lib/layouts/beamer.layout:504 lib/layouts/beamer.layout:572
+#: lib/layouts/beamer.layout:506 lib/layouts/beamer.layout:574
 msgid "Overlay specifications for this frame"
 msgstr ""
 
-#: lib/layouts/beamer.layout:510 lib/layouts/beamer.layout:578
+#: lib/layouts/beamer.layout:512 lib/layouts/beamer.layout:580
 msgid "Default Overlay Specifications"
 msgstr ""
 
-#: lib/layouts/beamer.layout:511 lib/layouts/beamer.layout:579
+#: lib/layouts/beamer.layout:513 lib/layouts/beamer.layout:581
 msgid "Default overlay specifications within this frame"
 msgstr ""
 
 # src/frontends/xforms/form_preferences.C:926
-#: lib/layouts/beamer.layout:517 lib/layouts/beamer.layout:546
-#: lib/layouts/beamer.layout:557 lib/layouts/beamer.layout:585
+#: lib/layouts/beamer.layout:519 lib/layouts/beamer.layout:548
+#: lib/layouts/beamer.layout:559 lib/layouts/beamer.layout:587
 #, fuzzy
 msgid "Frame Options"
 msgstr "допълнителни опции"
 
-#: lib/layouts/beamer.layout:519 lib/layouts/beamer.layout:548
-#: lib/layouts/beamer.layout:559 lib/layouts/beamer.layout:587
+#: lib/layouts/beamer.layout:521 lib/layouts/beamer.layout:550
+#: lib/layouts/beamer.layout:561 lib/layouts/beamer.layout:589
 msgid "Frame options (see beamer manual)"
 msgstr ""
 
 # src/ext_l10n.h:375
-#: lib/layouts/beamer.layout:522
+#: lib/layouts/beamer.layout:524
 #, fuzzy
 msgid "Frame Title"
 msgstr "Подзаглавие"
 
-#: lib/layouts/beamer.layout:523
+#: lib/layouts/beamer.layout:525
 msgid "Enter the frame title here"
 msgstr ""
 
 # src/LColor.C:82
-#: lib/layouts/beamer.layout:542
+#: lib/layouts/beamer.layout:544
 #, fuzzy
 msgid "PlainFrame"
 msgstr "рамка на математика"
 
 # src/frontends/xforms/form_preferences.C:926
-#: lib/layouts/beamer.layout:544
+#: lib/layouts/beamer.layout:546
 #, fuzzy
 msgid "Frame (plain)"
 msgstr "допълнителни опции"
 
 # src/LColor.C:82
-#: lib/layouts/beamer.layout:553
+#: lib/layouts/beamer.layout:555
 #, fuzzy
 msgid "FragileFrame"
 msgstr "рамка на математика"
 
 # src/ext_l10n.h:377
-#: lib/layouts/beamer.layout:555
+#: lib/layouts/beamer.layout:557
 #, fuzzy
 msgid "Frame (fragile)"
 msgstr "Презиме"
 
 # src/LColor.C:82
-#: lib/layouts/beamer.layout:564
+#: lib/layouts/beamer.layout:566
 #, fuzzy
 msgid "AgainFrame"
 msgstr "рамка на математика"
 
 # src/layout_forms.C:28
-#: lib/layouts/beamer.layout:570 lib/layouts/powerdot.layout:135
+#: lib/layouts/beamer.layout:572 lib/layouts/powerdot.layout:135
 #: lib/layouts/seminar.layout:111 lib/layouts/slides.layout:92
 #: src/frontends/qt/GuiDocument.cpp:136
 msgid "Slide"
 msgstr "Кадър"
 
-#: lib/layouts/beamer.layout:599
+#: lib/layouts/beamer.layout:601
 msgid "Repeat frame with label"
 msgstr ""
 
 # src/ext_l10n.h:375
-#: lib/layouts/beamer.layout:611
+#: lib/layouts/beamer.layout:613
 #, fuzzy
 msgid "FrameTitle"
 msgstr "Подзаглавие"
 
-#: lib/layouts/beamer.layout:630 lib/layouts/beamer.layout:660
-#: lib/layouts/beamer.layout:876 lib/layouts/beamer.layout:905
-#: lib/layouts/beamer.layout:939 lib/layouts/beamer.layout:1228
-#: lib/layouts/beamer.layout:1253 lib/layouts/beamer.layout:1280
-#: lib/layouts/beamer.layout:1316 lib/layouts/beamer.layout:1446
-#: lib/layouts/beamer.layout:1473 lib/layouts/beamer.layout:1493
-#: lib/layouts/beamer.layout:1513 lib/layouts/beamer.layout:1533
-#: lib/layouts/beamer.layout:1553 lib/layouts/beamer.layout:1574
-#: lib/layouts/beamer.layout:1595 lib/layouts/beamer.layout:1616
-#: lib/layouts/beamer.layout:1637 lib/layouts/beamer.layout:1663
+#: lib/layouts/beamer.layout:632 lib/layouts/beamer.layout:662
+#: lib/layouts/beamer.layout:878 lib/layouts/beamer.layout:907
+#: lib/layouts/beamer.layout:941 lib/layouts/beamer.layout:1230
+#: lib/layouts/beamer.layout:1255 lib/layouts/beamer.layout:1282
+#: lib/layouts/beamer.layout:1318 lib/layouts/beamer.layout:1448
+#: lib/layouts/beamer.layout:1475 lib/layouts/beamer.layout:1495
+#: lib/layouts/beamer.layout:1515 lib/layouts/beamer.layout:1535
+#: lib/layouts/beamer.layout:1555 lib/layouts/beamer.layout:1576
+#: lib/layouts/beamer.layout:1597 lib/layouts/beamer.layout:1618
+#: lib/layouts/beamer.layout:1639 lib/layouts/beamer.layout:1667
 msgid "Specify the overlay settings (see beamer manual)"
 msgstr ""
 
 # src/ext_l10n.h:375
-#: lib/layouts/beamer.layout:636
+#: lib/layouts/beamer.layout:638
 #, fuzzy
 msgid "Short Frame Title|S"
 msgstr "Подзаглавие"
 
-#: lib/layouts/beamer.layout:637
+#: lib/layouts/beamer.layout:639
 msgid "A short form of the frame title used in some themes"
 msgstr ""
 
 # src/ext_l10n.h:375
-#: lib/layouts/beamer.layout:642
+#: lib/layouts/beamer.layout:644
 #, fuzzy
 msgid "FrameSubtitle"
 msgstr "Подзаглавие"
 
 # src/frontends/kde/dlg/tabcreatedlgdata.C:107
 # src/frontends/xforms/form_tabular_create.C:45
-#: lib/layouts/beamer.layout:672 lib/layouts/moderncv.layout:395
+#: lib/layouts/beamer.layout:674 lib/layouts/moderncv.layout:395
 #: lib/layouts/moderncv.layout:412
-#, fuzzy
 msgid "Column"
-msgstr "Колони"
+msgstr "Колона"
 
 # src/frontends/kde/dlg/tabcreatedlgdata.C:107
 # src/frontends/xforms/form_tabular_create.C:45
-#: lib/layouts/beamer.layout:673 lib/layouts/beamer.layout:698
-#: lib/layouts/beamer.layout:699 lib/layouts/beamer.layout:709
+#: lib/layouts/beamer.layout:675 lib/layouts/beamer.layout:700
+#: lib/layouts/beamer.layout:701 lib/layouts/beamer.layout:711
 #: lib/layouts/moderncv.layout:373 lib/layouts/multicol.module:15
 msgid "Columns"
 msgstr "колони"
 
-#: lib/layouts/beamer.layout:685
+#: lib/layouts/beamer.layout:687
 msgid "Start column (increase depth!), width:"
 msgstr ""
 
 # src/insets/insetinclude.C:117 src/lyx_cb.C:197 src/lyxfunc.C:3054
 # src/lyxfunc.C:3156 src/lyxfunc.C:3212 src/lyxfunc.C:3288
-#: lib/layouts/beamer.layout:688 lib/layouts/powerdot.layout:504
+#: lib/layouts/beamer.layout:690 lib/layouts/powerdot.layout:504
 #, fuzzy
 msgid "Column Options"
 msgstr "Документи"
 
-#: lib/layouts/beamer.layout:690
+#: lib/layouts/beamer.layout:692
 msgid "Column options (see beamer manual)"
 msgstr ""
 
 # src/frontends/xforms/form_paragraph.C:200
-#: lib/layouts/beamer.layout:711
+#: lib/layouts/beamer.layout:713
 msgid "Column Placement Options"
 msgstr "опции за разположение на колони"
 
-#: lib/layouts/beamer.layout:712
+#: lib/layouts/beamer.layout:714
 msgid "Column placement options (t, T, c, b)"
 msgstr ""
-"Опции за разположение на колони за подравняване - низ от „t“ (отгоре), "
-"„T“ (?), „c“ (центрирано), „b“ (отдолу)"
+"Опции за разположение на колони за подравняване - низ от „t“ (горе), "
+"„T“ (?), „c“ (център), „b“ (долу)"
 
-#: lib/layouts/beamer.layout:729
+#: lib/layouts/beamer.layout:731
 msgid "ColumnsCenterAligned"
 msgstr ""
 
-#: lib/layouts/beamer.layout:732
+#: lib/layouts/beamer.layout:734
 msgid "Columns (center aligned)"
 msgstr ""
 
-#: lib/layouts/beamer.layout:736
+#: lib/layouts/beamer.layout:738
 msgid "ColumnsTopAligned"
 msgstr ""
 
-#: lib/layouts/beamer.layout:739
+#: lib/layouts/beamer.layout:741
 msgid "Columns (top aligned)"
 msgstr ""
 
 # src/BufferView2.C:601 src/LyXAction.C:346 src/MenuBackend.C:433
-#: lib/layouts/beamer.layout:748 lib/layouts/powerdot.layout:518
+#: lib/layouts/beamer.layout:750 lib/layouts/powerdot.layout:518
 #, fuzzy
 msgid "Pause"
 msgstr "Залепи"
 
 # src/frontends/xforms/form_preferences.C:896
-#: lib/layouts/beamer.layout:749 lib/layouts/beamer.layout:777
-#: lib/layouts/beamer.layout:823 lib/layouts/beamer.layout:855
-#: lib/layouts/beamer.layout:884 lib/layouts/powerdot.layout:519
+#: lib/layouts/beamer.layout:751 lib/layouts/beamer.layout:779
+#: lib/layouts/beamer.layout:825 lib/layouts/beamer.layout:857
+#: lib/layouts/beamer.layout:886 lib/layouts/powerdot.layout:519
 #, fuzzy
 msgid "Overlays"
 msgstr "обърнато"
 
 # src/frontends/kde/refdlg.C:63
-#: lib/layouts/beamer.layout:755 lib/layouts/powerdot.layout:525
+#: lib/layouts/beamer.layout:757 lib/layouts/powerdot.layout:525
 #, fuzzy
 msgid "Pause number"
 msgstr "Номер на страница"
 
-#: lib/layouts/beamer.layout:756 lib/layouts/powerdot.layout:526
+#: lib/layouts/beamer.layout:758 lib/layouts/powerdot.layout:526
 msgid "Number of slide where the context below the pause gets visible"
 msgstr ""
 
-#: lib/layouts/beamer.layout:767 lib/layouts/powerdot.layout:537
+#: lib/layouts/beamer.layout:769 lib/layouts/powerdot.layout:537
 msgid "_ _ _ _ _ _ _ _ _ _ _ _ _ _"
 msgstr "_ _ _ _ _ _ _ _ _ _ _ _ _ _"
 
 # src/form1.C:129 src/sp_form.C:58
-#: lib/layouts/beamer.layout:776 lib/layouts/beamer.layout:815
-#, fuzzy
+#: lib/layouts/beamer.layout:778 lib/layouts/beamer.layout:817
 msgid "Overprint"
-msgstr "Опции"
+msgstr "Надпечатка"
 
 # src/form1.C:129 src/sp_form.C:58
-#: lib/layouts/beamer.layout:783
-#, fuzzy
+#: lib/layouts/beamer.layout:785
 msgid "Overprint Area Width"
-msgstr "Опции"
+msgstr "Ширина на надпечатка"
 
 # src/form1.C:161 src/frontends/kde/dlg/paraextradlgdata.C:91
 # src/frontends/xforms/form_graphics.C:44
 # src/frontends/xforms/form_paragraph.C:219
-#: lib/layouts/beamer.layout:784 lib/layouts/europasscv.layout:246
+#: lib/layouts/beamer.layout:786 lib/layouts/europasscv.layout:246
 #: lib/layouts/graphicboxes.module:49 lib/layouts/moderncv.layout:400
 #: lib/layouts/sectionbox.module:22 src/frontends/qt/GuiBox.cpp:71
-#, fuzzy
 msgid "Width"
-msgstr "Ширина"
+msgstr "ширина"
 
-#: lib/layouts/beamer.layout:785
+#: lib/layouts/beamer.layout:787
 msgid "The width of the overprint area (default: text width)"
-msgstr ""
+msgstr "Ширина на площа за надпечат (по подразбиране е ширината на текста)"
 
 # src/frontends/xforms/form_preferences.C:896
-#: lib/layouts/beamer.layout:822
+#: lib/layouts/beamer.layout:824
 #, fuzzy
 msgid "OverlayArea"
 msgstr "обърнато"
 
 # src/frontends/xforms/form_preferences.C:896
-#: lib/layouts/beamer.layout:832
+#: lib/layouts/beamer.layout:834
 #, fuzzy
 msgid "Overlayarea"
 msgstr "обърнато"
 
 # src/frontends/xforms/form_preferences.C:896
-#: lib/layouts/beamer.layout:842
+#: lib/layouts/beamer.layout:844
 #, fuzzy
 msgid "Overlay Area Width"
 msgstr "обърнато"
 
-#: lib/layouts/beamer.layout:843
+#: lib/layouts/beamer.layout:845
 msgid "The width of the overlay area"
 msgstr ""
 
 # src/frontends/xforms/form_preferences.C:896
-#: lib/layouts/beamer.layout:847
+#: lib/layouts/beamer.layout:849
 #, fuzzy
 msgid "Overlay Area Height"
 msgstr "обърнато"
 
 # src/form1.C:157 src/frontends/xforms/form_graphics.C:46
-#: lib/layouts/beamer.layout:848 lib/layouts/graphicboxes.module:56
+#: lib/layouts/beamer.layout:850 lib/layouts/graphicboxes.module:56
 #: lib/layouts/moderncv.layout:288 src/frontends/qt/GuiBox.cpp:70
-#, fuzzy
 msgid "Height"
-msgstr "Височина"
+msgstr "като височинaта"
 
-#: lib/layouts/beamer.layout:849
+#: lib/layouts/beamer.layout:851
 msgid "The height of the overlay area"
 msgstr ""
 
 # src/frontends/kde/dlg/paradlgdata.C:82
-#: lib/layouts/beamer.layout:854 lib/layouts/beamer.layout:1563
-#: lib/layouts/beamer.layout:1565 lib/layouts/powerdot.layout:660
+#: lib/layouts/beamer.layout:856 lib/layouts/beamer.layout:1565
+#: lib/layouts/beamer.layout:1567 lib/layouts/powerdot.layout:660
 #, fuzzy
 msgid "Uncover"
 msgstr "(&R)Въстанови"
 
 # src/ext_l10n.h:75
-#: lib/layouts/beamer.layout:864
+#: lib/layouts/beamer.layout:866
 #, fuzzy
 msgid "Uncovered on slides"
 msgstr "Изтрий колона(D)|D"
 
 # src/lyxfont.C:62
-#: lib/layouts/beamer.layout:883 lib/layouts/beamer.layout:1542
-#: lib/layouts/beamer.layout:1544 lib/layouts/powerdot.layout:666
+#: lib/layouts/beamer.layout:885 lib/layouts/beamer.layout:1544
+#: lib/layouts/beamer.layout:1546 lib/layouts/powerdot.layout:666
 #, fuzzy
 msgid "Only"
 msgstr "Вкл."
 
 # src/ext_l10n.h:75
-#: lib/layouts/beamer.layout:893
+#: lib/layouts/beamer.layout:895
 #, fuzzy
 msgid "Only on slides"
 msgstr "Изтрий колона(D)|D"
 
 # src/frontends/kde/dlg/parageneraldlgdata.C:94
-#: lib/layouts/beamer.layout:917
+#: lib/layouts/beamer.layout:919
 #, fuzzy
 msgid "Block"
 msgstr "Блок"
 
 # src/frontends/kde/dlg/parageneraldlgdata.C:94
-#: lib/layouts/beamer.layout:918
+#: lib/layouts/beamer.layout:920
 msgid "Blocks"
 msgstr "Блок"
 
 # src/frontends/kde/dlg/parageneraldlgdata.C:94
-#: lib/layouts/beamer.layout:927
+#: lib/layouts/beamer.layout:929
 msgid "Block:"
 msgstr "блок:"
 
 # src/LColor.C:64
-#: lib/layouts/beamer.layout:938
+#: lib/layouts/beamer.layout:940
 #, fuzzy
 msgid "Action Specification|S"
 msgstr "избор"
 
 # src/sp_form.C:86
-#: lib/layouts/beamer.layout:945
+#: lib/layouts/beamer.layout:947
 msgid "Block Title"
 msgstr "Заглавие на блок"
 
-#: lib/layouts/beamer.layout:946
+#: lib/layouts/beamer.layout:948
 msgid "Enter the block title here"
 msgstr "Въведете името на блока"
 
-#: lib/layouts/beamer.layout:961
+#: lib/layouts/beamer.layout:963
 #, fuzzy
 msgid "ExampleBlock"
 msgstr "Пример"
 
 # src/ext_l10n.h:232
-#: lib/layouts/beamer.layout:964
+#: lib/layouts/beamer.layout:966
 #, fuzzy
 msgid "Example Block:"
 msgstr "Пример"
 
 # src/frontends/kde/dlg/parageneraldlgdata.C:94
-#: lib/layouts/beamer.layout:970
+#: lib/layouts/beamer.layout:972
 #, fuzzy
 msgid "AlertBlock"
 msgstr "Блок"
 
 # src/frontends/kde/dlg/parageneraldlgdata.C:94
-#: lib/layouts/beamer.layout:973
+#: lib/layouts/beamer.layout:975
 #, fuzzy
 msgid "Alert Block:"
 msgstr "Блок"
 
 # src/ext_l10n.h:274
-#: lib/layouts/beamer.layout:985 lib/layouts/beamer.layout:1022
-#: lib/layouts/beamer.layout:1049 lib/layouts/beamer.layout:1077
-#: lib/layouts/beamer.layout:1121 lib/layouts/beamer.layout:1144
+#: lib/layouts/beamer.layout:987 lib/layouts/beamer.layout:1024
+#: lib/layouts/beamer.layout:1051 lib/layouts/beamer.layout:1079
+#: lib/layouts/beamer.layout:1123 lib/layouts/beamer.layout:1146
 #, fuzzy
 msgid "Titling"
 msgstr "Списък"
 
-#: lib/layouts/beamer.layout:999
+#: lib/layouts/beamer.layout:1001
 msgid "Short title which appears in the sidebar/header"
 msgstr ""
 
-#: lib/layouts/beamer.layout:1013
+#: lib/layouts/beamer.layout:1015
 msgid "Title (Plain Frame)"
 msgstr ""
 
 # src/ext_l10n.h:375
-#: lib/layouts/beamer.layout:1035
-#, fuzzy
+#: lib/layouts/beamer.layout:1037
 msgid "Short Subtitle|S"
-msgstr "Подзаглавие"
+msgstr "Кратко подзаглавие"
 
-#: lib/layouts/beamer.layout:1036
+#: lib/layouts/beamer.layout:1038
 msgid "Short subtitle which appears in the sidebar/header"
-msgstr ""
+msgstr "Кратко подзаглавие, което се показва в полето/колинтитуля"
 
-#: lib/layouts/beamer.layout:1062
+#: lib/layouts/beamer.layout:1064
 msgid "Short author which appears in the sidebar/header"
 msgstr ""
 
 # src/ext_l10n.h:375
-#: lib/layouts/beamer.layout:1089
+#: lib/layouts/beamer.layout:1091
 #, fuzzy
 msgid "Short Institute|S"
 msgstr "Подзаглавие"
 
-#: lib/layouts/beamer.layout:1090
+#: lib/layouts/beamer.layout:1092
 msgid "Short institute which appears in the sidebar/header"
 msgstr ""
 
 # src/LyXAction.C:354
-#: lib/layouts/beamer.layout:1099
+#: lib/layouts/beamer.layout:1101
 #, fuzzy
 msgid "InstituteMark"
 msgstr "Вмъкни кавички"
 
 # src/ext_l10n.h:375
-#: lib/layouts/beamer.layout:1133
+#: lib/layouts/beamer.layout:1135
 #, fuzzy
 msgid "Short Date|S"
 msgstr "Подзаглавие"
 
-#: lib/layouts/beamer.layout:1134
+#: lib/layouts/beamer.layout:1136
 msgid "Short date which appears in the sidebar/header"
 msgstr ""
 
 # src/frontends/xforms/FormGraphics.C:36
 # src/frontends/xforms/FormGraphics.C:359
-#: lib/layouts/beamer.layout:1143 lib/layouts/beamerposter.layout:46
+#: lib/layouts/beamer.layout:1145 lib/layouts/beamerposter.layout:46
 #, fuzzy
 msgid "TitleGraphic"
 msgstr "Графика"
 
 # src/form1.C:165
-#: lib/layouts/beamer.layout:1208 lib/layouts/egs.layout:103
+#: lib/layouts/beamer.layout:1210 lib/layouts/egs.layout:103
 #: lib/layouts/powerdot.layout:426 lib/layouts/stdlayouts.inc:12
 msgid "Quotation"
 msgstr "Цитиране"
 
 # src/ext_l10n.h:291 src/insets/insetinfo.C:77 src/insets/insetinfo.C:102
 # src/insets/insetinfo.C:231
-#: lib/layouts/beamer.layout:1235 lib/layouts/egs.layout:122
+#: lib/layouts/beamer.layout:1237 lib/layouts/egs.layout:122
 #: lib/layouts/moderncv.layout:305 lib/layouts/powerdot.layout:448
 #: lib/layouts/stdlayouts.inc:37
 msgid "Quote"
 msgstr "Цитат"
 
 # src/lyxfunc.C:1125
-#: lib/layouts/beamer.layout:1260 lib/layouts/egs.layout:277
+#: lib/layouts/beamer.layout:1262 lib/layouts/egs.layout:277
 #: lib/layouts/powerdot.layout:468 lib/layouts/stdlayouts.inc:60
 msgid "Verse"
 msgstr "Стих"
 
-#: lib/layouts/beamer.layout:1302 lib/layouts/foils.layout:340
+#: lib/layouts/beamer.layout:1304 lib/layouts/foils.layout:340
 #: lib/layouts/theorems-starred.inc:78
 msgid "Corollary."
 msgstr "Следствие."
 
 # src/LColor.C:64
-#: lib/layouts/beamer.layout:1315 lib/layouts/beamer.layout:1472
-#: lib/layouts/beamer.layout:1492 lib/layouts/beamer.layout:1512
-#: lib/layouts/beamer.layout:1532 lib/layouts/beamer.layout:1552
-#: lib/layouts/beamer.layout:1573 lib/layouts/beamer.layout:1594
-#: lib/layouts/beamer.layout:1615 lib/layouts/beamer.layout:1636
-#: lib/layouts/beamer.layout:1662
+#: lib/layouts/beamer.layout:1317 lib/layouts/beamer.layout:1474
+#: lib/layouts/beamer.layout:1494 lib/layouts/beamer.layout:1514
+#: lib/layouts/beamer.layout:1534 lib/layouts/beamer.layout:1554
+#: lib/layouts/beamer.layout:1575 lib/layouts/beamer.layout:1596
+#: lib/layouts/beamer.layout:1617 lib/layouts/beamer.layout:1638
+#: lib/layouts/beamer.layout:1666
 #, fuzzy
 msgid "Action Specifications|S"
 msgstr "избор"
 
 # src/ext_l10n.h:221
-#: lib/layouts/beamer.layout:1333 lib/layouts/foils.layout:354
+#: lib/layouts/beamer.layout:1335 lib/layouts/foils.layout:354
 #: lib/layouts/theorems-starred.inc:174
 msgid