commit 5ab19af7820fba58876ac86efd8cc4aa1e75b44f
Author: Georg Baum <[email protected]>
Date: Sun Jun 19 17:05:13 2016 +0200
Skip paragraph parameters for dash conversion
Some of them are directly passed to LaTeX, but for all of them a token
\twohyphens or \threehyphens is not valid. This fixes bug #10243.
diff --git a/lib/lyx2lyx/lyx_2_2.py b/lib/lyx2lyx/lyx_2_2.py
index 34490d8..25c4ba0 100644
--- a/lib/lyx2lyx/lyx_2_2.py
+++ b/lib/lyx2lyx/lyx_2_2.py
@@ -632,6 +632,10 @@ def convert_dashes(document):
else:
i = j
continue
+ if len(words) > 0 and words[0] in ["\\leftindent",
"\\paragraph_spacing", "\\align", "\\labelwidthstring"]:
+ # skip paragraph parameters (bug 10243)
+ i += 1
+ continue
while True:
j = document.body[i].find("--")
if j == -1: