[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    koffice/kexi/plugins/reportspgz/backend/renderer
From:       Adam Pigg <adam () piggz ! co ! uk>
Date:       2009-06-05 19:58:01
Message-ID: 1244231881.970538.22249.nullmailer () svn ! kde ! org
[Download RAW message or body]

SVN commit 978009 by piggz:

fix text area rendering

 M  +4 -6      orprerender.cpp  


--- trunk/koffice/kexi/plugins/reportspgz/backend/renderer/orprerender.cpp #978008:978009
@@ -463,9 +463,7 @@
             dataThis.setField(t->m_controlSource->value().toString());
             QPointF pos = t->m_pos.toScene();
             QSizeF size = t->m_size.toScene();
-            pos /= 100.0;
             pos += QPointF(_leftMargin, _yOffset);
-            size /= 100.0;
 
             QRectF trf(pos, size);
 
@@ -484,7 +482,7 @@
                 QPrinter prnt(QPrinter::HighResolution);
                 QFontMetrics fm(f, &prnt);
 
-                int   intRectWidth    = (int)(trf.width() * prnt.resolution()) - 10;
+                int   intRectWidth    = (int)((t->m_size.toPoint().width() / 72) * prnt.resolution());
 
                 while (qstrValue.length()) {
                     idx = re.indexIn(qstrValue, pos);
@@ -642,7 +640,7 @@
             QPointF pos = t->m_pos.toScene();
             QSizeF size = t->m_size.toScene();
             pos += QPointF(_leftMargin, _yOffset);
-
+	    
             QRectF trf(pos, size);
 
             int     intLineCounter  = 0;
@@ -665,8 +663,8 @@
                 QFontMetrics fm(f, &prnt);
 
 //                int   intRectWidth    = (int)(trf.width() * prnt.resolution()) - 10;
-		int   intRectWidth    = (int)(trf.width());
-		
+		int   intRectWidth    = (int)((t->m_size.toPoint().width() / 72) * prnt.resolution());
+		 
                 while (qstrValue.length()) {
                     idx = re.indexIn(qstrValue, pos);
                     if (idx == -1) {
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic