]> git.lyx.org Git - lyx.git/blobdiff - lib/scripts/layout2layout.py
GuiSearch: make search options visible/accessible in minimal mode
[lyx.git] / lib / scripts / layout2layout.py
index 2bb62e37c96f7868e216d266ef489d58fd73ffd3..eb04f45a482cb53055b9a0d3289770e3f87245c3 100644 (file)
@@ -11,7 +11,7 @@
 # This script will update a .layout file to current format
 
 # The latest layout format is also defined in src/TextClass.cpp
-currentFormat = 83
+currentFormat = 93
 
 
 # Incremented to format 4, 6 April 2007, lasgouttes
@@ -271,7 +271,7 @@ currentFormat = 83
 # Incremented to format 81, 12 August 2019 by rikiheck
 # New tag GuiName for counters
 
-# Incremented to format 82, 4 June 2017 by dourouc05
+# Incremented to format 82, 4 June 2017 by tcuvelier
 # - Add new tags for Layout:
 #   DocBookTag, DocBookAttr, DocBookInInfo,
 #   DocBookWrapperTag, DocBookWrapperAttr,
@@ -281,9 +281,41 @@ currentFormat = 83
 # - Removed tag Header from ClassOptionsClassOptions
 # - Removed tag Element for flex insets
 
-# Incremented to format 83, 2 August 2020 by dourouc05
+# Incremented to format 83, 2 August 2020 by tcuvelier
 # New tags DocBookWrapperMergeWithPrevious and DocBookAbstract
 
+# Incremented to format 84, 17 August 2020 by tcuvelier
+# New tags DocBookTagType, DocBookWrapperTagTagType,
+# DocBookItemWrapperTagTagType, DocBookItemTagTagType,
+# DocBookLabelTag
+
+# Incremented to format 85, 7 October 2020 by tcuvelier
+# New tags DocBookInnerTag, DocBookInnerAttr,
+# DocBookInnerTagType
+
+# Incremented to format 86, 20 October 2020 by tcuvelier
+# New tag DocBookSection.
+
+# Incremented to format 87, 2 November 2020 by rkh
+
+# Incremented to format 88, 28 November 2020 by tcuvelier
+# New tag DocBookNotInPara.
+
+# Incremented to format 89, 5 December 2020 by rkh
+# New tag LaTeXName for counters
+
+# Incremented to format 90, 11 December 2020 by spitz
+# Use semantic label colors
+
+# Incremented to format 91, 25 January 2021 by spitz
+# InputGlobal tag
+
+# Incremented to format 92, 30 January 2021 by spitz
+# Add ProvideInsetLayout and ModifyInsetLayout
+
+# Incremented to format 93, 13 February 2021 by spitz
+# Add DocBookNoFontInside
+
 # Do not forget to document format change in Customization
 # Manual (section "Declaring a new text class").
 
@@ -344,6 +376,7 @@ def concatenate_label(old, new):
     else:
         return b'"' + old + new + b'"'
 
+
 # appends a string to a list unless it's already there
 def addstring(s, l):
     if l.count(s) > 0:
@@ -533,6 +566,23 @@ def convert(lines, end_format):
                 i += 1
             continue
 
+        if 87 <= format <= 93:
+            # nothing to do.
+            i += 1
+            continue
+
+        if format == 86:
+            if lines[i].lstrip().lower().startswith(b"stepmastercounter"):
+                pattern = re.compile(b"stepmastercounter", re.IGNORECASE)
+                lines[i] = pattern.sub(b"StepParentCounter", lines[i])
+            i += 1
+            continue
+
+        if 82 <= format <= 85:
+            # nothing to do.
+            i += 1
+            continue
+
         if format == 81:
             match = re.compile(b'^(\\s*Header\\s+)("?\\w+"?)', re.IGNORECASE).match(lines[i])
             if match: