+##
+# Convert SGML paragraphs
+#
+def convert_sgml_paragraphs(file):
+ if file.backend != "docbook":
+ return
+
+ i = 0
+ while 1:
+ i = find_token(file.body, "\\begin_layout SGML", i)
+
+ if i == -1:
+ return
+
+ file.body[i] = "\\begin_layout Standard"
+ j = find_token(file.body, "\\end_layout", i)
+
+ file.body[j+1:j+1] = ['','\\end_inset','','','\\end_layout']
+ file.body[i+1:i+1] = ['\\begin_inset ERT','status inlined','','\\begin_layout Standard','']
+
+ i = i + 10