diff options
author | Sébastien Le Ray <sebastien-libreoffice@orniz.org> | 2011-03-01 22:29:50 +0100 |
---|---|---|
committer | Michael Meeks <michael.meeks@novell.com> | 2011-03-03 10:41:28 +0000 |
commit | f218e8401c4c1d07a967dbbcf112b13fb67bf72c (patch) | |
tree | b25a970f74481cdeff6df86324bbc1c342112a25 /sw | |
parent | af5e4ac2024060fbaaf498ee4a174ff21b87d7a2 (diff) |
Correct some minor graphical glitches.
SwRect::_Intersection() returns rectangles with negative
height/width when there is no intersection which cause artifacts
when drawing them... This bug has been present for a long time but
wasn't so evident since margins were only 2 opaque black pixels.
Diffstat (limited to 'sw')
-rw-r--r-- | sw/source/core/layout/paintfrm.cxx | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/sw/source/core/layout/paintfrm.cxx b/sw/source/core/layout/paintfrm.cxx index dcefe3a08c57..4da42e002363 100644 --- a/sw/source/core/layout/paintfrm.cxx +++ b/sw/source/core/layout/paintfrm.cxx @@ -5192,6 +5192,8 @@ void SwPageFrm::PaintMarginArea( const SwRect& _rOutputRect, { SwRect aPgRect = Frm(); aPgRect._Intersection( _rOutputRect ); + if(aPgRect.Height() < 0 || aPgRect.Width() <= 0) // No intersection + return; SwRegionRects aPgRegion( aPgRect ); aPgRegion -= aPgPrtRect; const SwPageFrm* pPage = static_cast<const SwPageFrm*>(this); |