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

List:       kde-commits
Subject:    KDE/kdebase/workspace/libs/plasma/widgets
From:       Marco Martin <notmart () gmail ! com>
Date:       2008-08-02 13:01:18
Message-ID: 1217682078.173784.24990.nullmailer () svn ! kde ! org
[Download RAW message or body]

SVN commit 841020 by mart:

Plasma::Label should be able to actually display svgs from the theme
now
cleaning some juck debug stuff in label


 M  +2 -2      frame.cpp  
 M  +2 -1      label.cpp  


--- trunk/KDE/kdebase/workspace/libs/plasma/widgets/frame.cpp #841019:841020
@@ -72,10 +72,10 @@
     qreal left, top, right, bottom;
 
     svg->getMargins(left, top, right, bottom);
-kWarning()<<top;
+
     if (!text.isNull()) {
         QFontMetricsF fm(QApplication::font());
-        top += fm.height();kWarning()<<top;
+        top += fm.height();
     }
 
     q->setContentsMargins(left, top, right, bottom);
--- trunk/KDE/kdebase/workspace/libs/plasma/widgets/label.cpp #841019:841020
@@ -54,8 +54,9 @@
         KMimeType::Ptr mime = KMimeType::findByPath(absImagePath);
         QPixmap pm(q->size().toSize());
 
-        if (mime->is("image/svg+xml")) {
+        if (mime->is("image/svg+xml") || mime->is("application/x-gzip")) {
             svg = new Svg();
+            svg->setImagePath(imagePath);
             QPainter p(&pm);
             svg->paint(&p, pm.rect());
         } else {
[prev in list] [next in list] [prev in thread] [next in thread] 

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