$OpenBSD: patch-src_gvcore_documentimpl_cpp,v 1.1 2008/04/15 03:45:11 merdely Exp $
--- src/gvcore/documentimpl.cpp.orig	Mon Apr 14 21:26:16 2008
+++ src/gvcore/documentimpl.cpp	Mon Apr 14 21:26:50 2008
@@ -38,6 +38,11 @@ void DocumentImpl::switchToImpl(DocumentImpl* impl) {
 }
 
 void DocumentImpl::setImage(QImage img) {
+	if (img.depth() == 1) {
+		// 1 bit depth images are difficult to scale. Let's convert to 8 bit
+		// depth. See bug #155518.
+		img = img.convertDepth(8);
+	}
 	mDocument->setImage(img);
 }
 
