]> git.lyx.org Git - features.git/commitdiff
Fix bug #7214 as best we can. The point here is that we only
authorRichard Heck <rgheck@comcast.net>
Thu, 20 Jan 2011 16:38:41 +0000 (16:38 +0000)
committerRichard Heck <rgheck@comcast.net>
Thu, 20 Jan 2011 16:38:41 +0000 (16:38 +0000)
want to add the \clearpage if the class has chapters.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37266 a592a061-630c-0410-9148-cb99ea01b6c8

lib/lyx2lyx/lyx_2_0.py

index 1771e185f45cde2dfb555aacb9dbf18ef4a58694..49e08d24ce3826f6edb5db52e58704b7d23c0635 100644 (file)
@@ -1978,10 +1978,17 @@ def revert_diagram(document):
     # only need to do it once!
     return
 
+chapters = ("amsbook", "book", "docbook-book", "elsart", "extbook", "extreport", 
+    "jbook", "jreport", "jsbook", "literate-book", "literate-report", "memoir", 
+    "mwbk", "mwrep", "recipebook", "report", "scrbook", "scrreprt", "svmono", 
+    "svmult", "tbook", "treport", "tufte-book")
 
 def convert_bibtex_clearpage(document):
   " insert a clear(double)page bibliographystyle if bibtotoc option is used "
 
+  if document.textclass not in chapters:
+    return
+
   i = find_token(document.header, '\\papersides', 0)
   sides = 0
   if i == -1: