From 4de7a36e2900fef8b63be01725db3cf8e18381c6 Mon Sep 17 00:00:00 2001 From: Riccardo Iaconelli Date: Sun, 20 May 2007 21:01:30 +0000 Subject: [PATCH] The clock now shows (and moves) SVG hands. I had to do an hack on Plasma::Svg to make it work, it was doing strange things with the plasmoid painter, and especially its coordinate system, check the differences in lib/svg.cpp to see what changed. Still have a couple of problems with hands other than second, and for the black thingy in the middle. Too tired right now, will check (and hopefully fix) them again tomorrow. Let's party though! The first (mostly) working plasmoid goes public! Yay! CCMAIL:panel-devel@kde.org svn path=/trunk/KDE/kdebase/workspace/plasma/lib/; revision=666767 --- svg.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/svg.cpp b/svg.cpp index 405aa1847..47aad0d4e 100644 --- a/svg.cpp +++ b/svg.cpp @@ -146,8 +146,10 @@ void Svg::paint( QPainter* painter, int x, int y, const QString& elementID ) void Svg::paint( QPainter* painter, const QRectF& rect, const QString& elementID ) { +// QPixmap pix(rect.width(), rect.height()); QPixmap pix; - d->findInCache( painter, pix, elementID ); + QPainter *pain = new QPainter(); + d->findInCache( pain, pix, elementID ); /* QMatrix matrix = painter->worldMatrix(); painter->setWorldMatrix( QMatrix() );*/