File calibre-cssutils.diff of Package calibre

--- src/calibre/ebooks/oeb/stylizer.py	2011-01-12 10:26:25.108920983 +0100
+++ src/calibre/ebooks/oeb/stylizer.py_new	2011-01-12 10:40:56.797983394 +0100
@@ -17,7 +17,14 @@
 from xml.dom import SyntaxErr as CSSSyntaxError
 import cssutils
 from cssutils.css import CSSStyleRule, CSSPageRule, CSSStyleDeclaration, \
-    CSSValueList, CSSFontFaceRule, cssproperties
+    CSSFontFaceRule, cssproperties
+#
+# In python-cssutils >= 0.9.8 no CSSValueList is replaced with PropertyValue
+# 
+try:
+  from cssutils.css import CSSValueList
+except ImportError:
+  from cssutils.css import PropertyValue as CSSValueList
 from cssutils import profile as cssprofiles
 from lxml import etree
 from lxml.cssselect import css_to_xpath, ExpressionError, SelectorSyntaxError
openSUSE Build Service is sponsored by