]> git.lyx.org Git - lyx.git/commitdiff
Minor structural improvement.
authorRichard Heck <rgheck@comcast.net>
Thu, 4 Nov 2010 21:42:24 +0000 (21:42 +0000)
committerRichard Heck <rgheck@comcast.net>
Thu, 4 Nov 2010 21:42:24 +0000 (21:42 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@36093 a592a061-630c-0410-9148-cb99ea01b6c8

lib/lyx2lyx/lyx_2_0.py

index a2f5ec2d42b85309bf2b50d280851dab7fc94bd0..45c8c57d4fabb9a47732e84b5c75e4e1ac51d1e5 100644 (file)
@@ -1769,7 +1769,6 @@ def revert_mathdots(document):
     " Load mathdots if used in the document "
 
     mathdots = find_token(document.header, "\\use_mathdots" , 0)
-    usedots = 1
     if mathdots == -1:
       document.warning("No \\usemathdots line. Assuming auto.")
     else:
@@ -1778,18 +1777,17 @@ def revert_mathdots(document):
       try:
         usedots = int(val)
       except:
-        document.warning("Invalid \\use_mathdots value: " + val)
+        document.warning("Invalid \\use_mathdots value: " + val + ". Assuming auto.")
         # probably usedots has not been changed, but be safe.
         usedots = 1
 
-    if usedots == 0:
-      # do not load case
-      return
-  
-    if usedots == 2:
-      # force load case
-      add_to_preamble(["% lyx2lyx mathdots addition", "\\usepackage{mathdots}"])
-      return
+      if usedots == 0:
+        # do not load case
+        return
+      if usedots == 2:
+        # force load case
+        add_to_preamble(["% lyx2lyx mathdots addition", "\\usepackage{mathdots}"])
+        return
     
     # so we are in the auto case. we want to load mathdots if \iddots is used.
     i = 0