[Kst] extragear/graphics/kst/kst
Barth Netterfield
netterfield at astro.utoronto.ca
Tue Nov 22 18:16:14 CET 2005
SVN commit 482336 by netterfield:
Compensate for the box border width when drawing the box.
The extents of the box are the outside edges of the border.
M +7 -1 kstviewbox.cpp
--- trunk/extragear/graphics/kst/kst/kstviewbox.cpp #482335:482336
@@ -75,7 +75,13 @@
} else {
p.setBrush(_foregroundColor);
}
- p.drawRoundRect(_geom, _xRound, _yRound);
+ QRect r;
+ r.setX(_geom.left() + borderWidth()/2);
+ r.setY(_geom.top() + borderWidth()/2);
+ r.setWidth(_geom.width() - borderWidth());
+ r.setHeight(_geom.height() - borderWidth());
+
+ p.drawRoundRect(r, _xRound, _yRound);
// do this last so the focus rectangle isn't covered up
KstViewObject::paint(type, p, bounds); // skip over the immediate parent
More information about the Kst
mailing list