[Libreoffice-commits] core.git: vcl/headless vcl/win

Caolán McNamara (via logerrit) logerrit at kemper.freedesktop.org
Wed Aug 14 19:28:39 UTC 2019


 vcl/headless/svpgdi.cxx |   16 ++++++++++------
 vcl/win/gdi/gdiimpl.cxx |   14 +++++++++-----
 2 files changed, 19 insertions(+), 11 deletions(-)

New commits:
commit bd513456710b69ac2f73e983ee1b823d71b3b47b
Author:     Caolán McNamara <caolanm at redhat.com>
AuthorDate: Wed Aug 14 13:09:36 2019 +0100
Commit:     Caolán McNamara <caolanm at redhat.com>
CommitDate: Wed Aug 14 21:27:35 2019 +0200

    tdf#124700 don't pull from or insert into cache for PixelSnapHairline
    
    Change-Id: I7ca0f556164b6bc462cee3c5532733dbd6b68a2b
    Reviewed-on: https://gerrit.libreoffice.org/77455
    Tested-by: Jenkins
    Reviewed-by: Caolán McNamara <caolanm at redhat.com>
    Tested-by: Caolán McNamara <caolanm at redhat.com>

diff --git a/vcl/headless/svpgdi.cxx b/vcl/headless/svpgdi.cxx
index f107b9936833..7488a77b635d 100644
--- a/vcl/headless/svpgdi.cxx
+++ b/vcl/headless/svpgdi.cxx
@@ -1285,7 +1285,8 @@ bool SvpSalGraphics::drawPolyLine(
         // check data validity
         if(nullptr == pSystemDependentData_CairoPath->getCairoPath()
             || pSystemDependentData_CairoPath->getNoJoin() != bNoJoin
-            || pSystemDependentData_CairoPath->getAntiAliasB2DDraw() != bAntiAliasB2DDraw)
+            || pSystemDependentData_CairoPath->getAntiAliasB2DDraw() != bAntiAliasB2DDraw
+            || bPixelSnapHairline /*tdf#124700*/ )
         {
             // data invalid, forget
             pSystemDependentData_CairoPath.reset();
@@ -1340,11 +1341,14 @@ bool SvpSalGraphics::drawPolyLine(
         }
 
         // copy and add to buffering mechanism
-        pSystemDependentData_CairoPath = rPolyLine.addOrReplaceSystemDependentData<SystemDependentData_CairoPath>(
-            ImplGetSystemDependentDataManager(),
-            cairo_copy_path(cr),
-            bNoJoin,
-            bAntiAliasB2DDraw);
+        if (!bPixelSnapHairline /*tdf#124700*/)
+        {
+            pSystemDependentData_CairoPath = rPolyLine.addOrReplaceSystemDependentData<SystemDependentData_CairoPath>(
+                ImplGetSystemDependentDataManager(),
+                cairo_copy_path(cr),
+                bNoJoin,
+                bAntiAliasB2DDraw);
+        }
     }
 
     // extract extents
diff --git a/vcl/win/gdi/gdiimpl.cxx b/vcl/win/gdi/gdiimpl.cxx
index 008f3a460f25..c3d891cd681e 100644
--- a/vcl/win/gdi/gdiimpl.cxx
+++ b/vcl/win/gdi/gdiimpl.cxx
@@ -2288,7 +2288,8 @@ bool WinSalGraphicsImpl::drawPolyLine(
     if(pSystemDependentData_GraphicsPath)
     {
         // check data validity
-        if(pSystemDependentData_GraphicsPath->getNoLineJoin() != bNoLineJoin)
+        if (pSystemDependentData_GraphicsPath->getNoLineJoin() != bNoLineJoin
+            || bPixelSnapHairline /*tdf#124700*/)
         {
             // data invalid, forget
             pSystemDependentData_GraphicsPath.reset();
@@ -2319,10 +2320,13 @@ bool WinSalGraphicsImpl::drawPolyLine(
         }
 
         // add to buffering mechanism
-        rPolygon.addOrReplaceSystemDependentData<SystemDependentData_GraphicsPath>(
-            ImplGetSystemDependentDataManager(),
-            pGraphicsPath,
-            bNoLineJoin);
+        if (!bPixelSnapHairline /*tdf#124700*/)
+        {
+            rPolygon.addOrReplaceSystemDependentData<SystemDependentData_GraphicsPath>(
+                ImplGetSystemDependentDataManager(),
+                pGraphicsPath,
+                bNoLineJoin);
+        }
     }
 
     if(mrParent.getAntiAliasB2DDraw())


More information about the Libreoffice-commits mailing list