- if file.format < 223:
- insert_tracking_changes(file.header)
- add_end_header(file.header)
- remove_color_default(file.body)
- convert_spaces(file.body)
- convert_bibtex(file.body)
- remove_insetparent(file.body)
- file.format = 223
- if file.end_format == file.format: return
-
- if file.format < 224:
- convert_external(file.body)
- convert_comment(file.body)
- file.format = 224
- if file.end_format == file.format: return
-
- if file.format < 225:
- add_end_layout(file.body)
- layout2begin_layout(file.body)
- convert_end_document(file.body)
- convert_table_valignment_middle(file.body)
- convert_breaks(file.body)
- file.format = 225
- if file.end_format == file.format: return
-
- if file.format < 226:
- convert_note(file.body)
- file.format = 226
- if file.end_format == file.format: return
-
- if file.format < 227:
- convert_box(file.body)
- file.format = 227
- if file.end_format == file.format: return
-
- if file.format < 228:
- convert_collapsable(file.body, file)
- convert_ert(file.body, file)
- file.format = 228
- if file.end_format == file.format: return
-
- if file.format < 229:
- convert_minipage(file.body)
- file.format = 229
- if file.end_format == file.format: return
-
- if file.format < 230:
- convert_jurabib(file.header, file)
- file.format = 230
- if file.end_format == file.format: return
-
- if file.format < 231:
- convert_float(file.body, file)
- file.format = 231
- if file.end_format == file.format: return
-
- if file.format < 232:
- convert_bibtopic(file.header, file)
- file.format = 232
- if file.end_format == file.format: return
-
- if file.format < 233:
- convert_graphics(file.body, file)
- convert_names(file.body, file)
- file.format = 233
- if file.end_format == file.format: return
-
- if file.format < 234:
- convert_cite_engine(file.header, file)
- file.format = 234
- if file.end_format == file.format: return
-
- if file.format < 235:
- convert_paperpackage(file.header, file)
- file.format = 235
- if file.end_format == file.format: return
-
- if file.format < 236:
- convert_bullets(file.header, file)
- add_begin_header(file.header, file)
- add_begin_body(file.body, file)
- normalize_papersize(file.header)
- strip_end_space(file.body)
- file.format = 236
+ table = { 223 : [insert_tracking_changes, add_end_header, remove_color_default,
+ convert_spaces, convert_bibtex, remove_insetparent],
+ 224 : [convert_external, convert_comment],
+ 225 : [add_end_layout, layout2begin_layout, convert_end_document,
+ convert_table_valignment_middle, convert_breaks],
+ 226 : [convert_note],
+ 227 : [convert_box],
+ 228 : [convert_collapsable, convert_ert],
+ 229 : [convert_minipage],
+ 230 : [convert_jurabib],
+ 231 : [convert_float],
+ 232 : [convert_bibtopic],
+ 233 : [convert_graphics, convert_names],
+ 234 : [convert_cite_engine],
+ 235 : [convert_paperpackage],
+ 236 : [convert_bullets, add_begin_header, add_begin_body,
+ normalize_papersize, strip_end_space],
+ 237 : [use_x_boolean]}
+
+ chain = table.keys()
+ chain.sort()
+
+ for version in chain:
+ if file.format >= version:
+ continue
+ for convert in table[version]:
+ convert(file)
+ file.format = version
+ if file.end_format == file.format:
+ return