[Kst] extragear/graphics/kst/kst
George Staikos
staikos at kde.org
Mon Dec 19 19:02:33 CET 2005
SVN commit 489766 by staikos:
When transparency is turned on, set the border width to 0. use the appropriate
base class for painting. Settings the border temporarily to zero around the
painting is no good since it breaks the separation of variables.
M +2 -6 kstviewlabel.cpp
M +5 -3 kstviewlegend.cpp
--- trunk/extragear/graphics/kst/kst/kstviewlabel.cpp #489765:489766
@@ -364,11 +364,7 @@
}
}
p.restore();
- if (_transparent) {
- KstViewObject::paint(p, bounds);
- } else {
- KstBorderedViewObject::paint(p, bounds);
- }
+ KstBorderedViewObject::paint(p, bounds);
}
@@ -620,7 +616,7 @@
setTransparent(widget->_transparent->isChecked());
setAutoResize(widget->_autoResize->isChecked());
- setBorderWidth(widget->_border->value());
+ setBorderWidth(transparent() ? 0 : widget->_border->value());
setBorderColor(widget->_boxColors->foreground());
setBackgroundColor(widget->_boxColors->background());
setPadding(widget->_margin->value());
--- trunk/extragear/graphics/kst/kst/kstviewlegend.cpp #489765:489766
@@ -406,8 +406,10 @@
void KstViewLegend::clear() {
- _curves.clear();
- setDirty();
+ if (!_curves.isEmpty()) {
+ _curves.clear();
+ setDirty();
+ }
}
@@ -482,7 +484,7 @@
setFontName(widget->_font->currentFont());
setTransparent(widget->_transparent->isChecked());
- setBorderWidth(widget->_border->value());
+ setBorderWidth(transparent() ? 0 : widget->_border->value());
setBorderColor(widget->_boxColors->foreground());
setBackgroundColor(widget->_boxColors->background());
setPadding(widget->_margin->value());
More information about the Kst
mailing list