]> git.lyx.org Git - lyx.git/blobdiff - lib/lyx2lyx/LyX.py
\textcyr -> \textcyrillic
[lyx.git] / lib / lyx2lyx / LyX.py
index b92469080dd56c21efcb7c11beb67199d11cb6e4..a410dfb77b55e485577d4fdae7d169a89b9063be 100644 (file)
@@ -1,6 +1,6 @@
 # This file is part of lyx2lyx
 # -*- coding: utf-8 -*-
-# Copyright (C) 2002-2015 The LyX Team
+# Copyright (C) 2002-2018 The LyX Team
 # Copyright (C) 2002-2004 Dekel Tsur <dekel@lyx.org>
 # Copyright (C) 2002-2006 José Matos <jamatos@lyx.org>
 #
@@ -35,7 +35,7 @@ try:
     import lyx2lyx_version
     version__ = lyx2lyx_version.version
 except: # we are running from build directory so assume the last version
-    version__ = '2.3'
+    version__ = '2.4'
 
 default_debug__ = 2
 
@@ -92,8 +92,9 @@ format_relation = [("0_06",    [200], minor_versions("0.6" , 4)),
                    ("1_6", list(range(277,346)), minor_versions("1.6" , 10)),
                    ("2_0", list(range(346,414)), minor_versions("2.0" , 8)),
                    ("2_1", list(range(414,475)), minor_versions("2.1" , 5)),
-                   ("2_2", list(range(475,509)), minor_versions("2.2" , 0)),
-                   ("2_3", (), minor_versions("2.3" , 0))
+                   ("2_2", list(range(475,509)), minor_versions("2.2" , 4)),
+                   ("2_3", list(range(509,545)), minor_versions("2.3" , 0)),
+                   ("2_4", (), minor_versions("2.4" , 0))
                   ]
 
 ####################################################################
@@ -393,6 +394,7 @@ class LyX_base:
             self.inputencoding = get_value(self.header, b"\\inputencoding", 0,
                                            default = b"auto").decode('ascii')
         self.format = self.read_format()
+        self.initial_format = self.format
         self.encoding = get_encoding(self.language,
                                      self.inputencoding, self.format,
                                      self.cjk_encoding)
@@ -532,7 +534,7 @@ class LyX_base:
         " Set the header with the version used."
 
         initial_comment = " ".join(["#LyX %s created this file." % version__,
-                                    "For more info see http://www.lyx.org/"])
+                                    "For more info see https://www.lyx.org/"])
 
         # Simple heuristic to determine the comment that always starts
         # a lyx file
@@ -698,7 +700,6 @@ class LyX_base:
         conversion are taken.  It returns a list of modules needed to
         convert the LyX file from self.format to self.end_format"""
 
-        self.start =  self.format
         format = self.format
         correct_version = 0
 
@@ -732,7 +733,7 @@ class LyX_base:
 
         # Convertion mode, back or forth
         steps = []
-        if (initial_step, self.start) < (final_step, self.end_format):
+        if (initial_step, self.initial_format) < (final_step, self.end_format):
             mode = "convert"
             full_steps = []
             for step in format_relation: