Bug 121166 - Labels with borders don't always have equal borders on all sizes
Summary: Labels with borders don't always have equal borders on all sizes
Status: RESOLVED FIXED
Alias: None
Product: kst
Classification: Applications
Component: general (show other bugs)
Version: 1.x
Platform: unspecified Solaris
: NOR normal
Target Milestone: ---
Assignee: kst
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-02-01 17:13 UTC by Nicolas Brisset
Modified: 2006-05-08 19:38 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Nicolas Brisset 2006-02-01 17:13:23 UTC
Version:           1.2.0_devel (using KDE 3.4.0, compiled sources)
Compiler:          gcc version 3.4.3
OS:                SunOS (sun4u) release 5.8

[I can't always reproduce this and it may be due to a local bug as the invisible ellipse outline...]
Sometimes, label borders don't have the same width on all sides. I'm sorry, the report as is may not be very useful, but that's the best I can do right now...
Comment 1 Andrew Walker 2006-02-28 21:08:14 UTC
STEPS TO REPRODUCE:
Create a label
Edit the label and set:
Transparent: on
Border width: 1

RESULTS:
Border is drawn only at the top and left of the label

EXPECTED RESULTS:
Border is drawn on all sides of the label

Comment 2 Andrew Walker 2006-03-17 21:45:04 UTC
SVN commit 519685 by arwalker:

BUG:121166 Correctly define the clip region.

 M  +1 -1      kstviewlabel.cpp  
 M  +2 -2      kstviewpicture.cpp  


--- trunk/extragear/graphics/kst/src/libkstapp/kstviewlabel.cpp #519684:519685
@@ -426,7 +426,7 @@
     _myClipMask = QRegion(bm);
     _myClipMask.translate(cr.topLeft().x(), cr.topLeft().y());
 
-    QBitmap bm1(_geom.bottomRight().x(), _geom.bottomRight().y(), true);
+    QBitmap bm1(_geom.bottomRight().x() + 1, _geom.bottomRight().y() + 1, true);
     if (!bm1.isNull()) {
       KstPainter p;
       p.setMakingMask(true);
--- trunk/extragear/graphics/kst/src/libkstapp/kstviewpicture.cpp #519684:519685
@@ -71,7 +71,7 @@
 QRegion KstViewPicture::clipRegion() {
   if (_clipMask.isNull()) {
     _myClipMask = QRegion();
-    QBitmap bm1(_geom.bottomRight().x(), _geom.bottomRight().y(), true);
+    QBitmap bm1(_geom.bottomRight().x() + 1, _geom.bottomRight().y() + 1, true);
     if (!bm1.isNull()) {
       KstPainter p;
       p.setMakingMask(true);
@@ -82,7 +82,7 @@
       p.end();
       _clipMask = QRegion(bm1);
     }
-    QBitmap bm2(_geom.bottomRight().x(), _geom.bottomRight().y(), true);
+    QBitmap bm2(_geom.bottomRight().x() + 1, _geom.bottomRight().y() + 1, true);
     if (!bm2.isNull()) {
       KstPainter p;
       p.setMakingMask(true);
Comment 3 Andrew Walker 2006-05-08 19:38:10 UTC
SVN commit 538727 by arwalker:

CCBUG:121166 Ensure border always drawn on all sides of the legend.

 M  +1 -1      kstviewlegend.cpp  


--- trunk/extragear/graphics/kst/src/libkstapp/kstviewlegend.cpp #538726:538727
@@ -391,7 +391,7 @@
     _myClipMask = QRegion(bm);
     _myClipMask.translate(cr.topLeft().x(), cr.topLeft().y());
 
-    QBitmap bm1(_geom.bottomRight().x(), _geom.bottomRight().y(), true);
+    QBitmap bm1(_geom.bottomRight().x() + 1, _geom.bottomRight().y() + 1, true);
     if (!bm1.isNull()) {
       KstPainter p;
       p.setMakingMask(true);