[Libreoffice-commits] core.git: vcl/source
Michael Meeks (via logerrit)
logerrit at kemper.freedesktop.org
Sun Dec 22 21:21:20 UTC 2019
vcl/source/outdev/rect.cxx | 5 +++++
1 file changed, 5 insertions(+)
New commits:
commit 24e7208306fa1c60eb0a0cee5c49b6454cad9df3
Author: Michael Meeks <michael.meeks at collabora.com>
AuthorDate: Thu Nov 7 14:11:35 2019 +0000
Commit: Ashod Nakashian <ashnakash at gmail.com>
CommitDate: Sun Dec 22 22:20:30 2019 +0100
Drawing calc grid misses pixels on bottom and right; fix.
Don't attempt to offset empty rectangles causing serious problems.
Change-Id: I6fcac11f5f5e03f7edc0662cf4e06e7f8a109f00
Reviewed-on: https://gerrit.libreoffice.org/82220
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice at gmail.com>
Reviewed-by: Michael Meeks <michael.meeks at collabora.com>
(cherry picked from commit fb974bc968b3a1a95f8e621776076522ec719dc6)
Reviewed-on: https://gerrit.libreoffice.org/84993
Tested-by: Jenkins
Reviewed-by: Ashod Nakashian <ashnakash at gmail.com>
diff --git a/vcl/source/outdev/rect.cxx b/vcl/source/outdev/rect.cxx
index ecbeb12fbfee..4cced0f9b7e9 100644
--- a/vcl/source/outdev/rect.cxx
+++ b/vcl/source/outdev/rect.cxx
@@ -232,6 +232,11 @@ void OutputDevice::DrawGrid( const tools::Rectangle& rRect, const Size& rDist, D
if( mbOutputClipped )
return;
+ // FIXME: seems we have an off-by-one around the border
+ // here with the cairo / svp backend at least.
+ aDstRect.AdjustRight(1);
+ aDstRect.AdjustBottom(1);
+
const long nDistX = std::max( rDist.Width(), 1L );
const long nDistY = std::max( rDist.Height(), 1L );
long nX = ( rRect.Left() >= aDstRect.Left() ) ? rRect.Left() : ( rRect.Left() + ( ( aDstRect.Left() - rRect.Left() ) / nDistX ) * nDistX );
More information about the Libreoffice-commits
mailing list