# This script will update a .layout file to current format
# The latest layout format is also defined in src/TextClass.cpp
-currentFormat = 84
+currentFormat = 87
# Incremented to format 4, 6 April 2007, lasgouttes
# 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.
+
+# Incremeted to format 87, 2 November 2020 by rkh
+
# Do not forget to document format change in Customization
# Manual (section "Declaring a new text class").
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: