cui/source/options/optgdlg.cxx                |   12 +-----------
 include/svtools/optionsdrawinglayer.hxx       |    5 -----
 include/vcl/vclenum.hxx                       |    1 -
 svtools/source/config/optionsdrawinglayer.cxx |   16 +---------------
 svx/source/sdr/overlay/overlayselection.cxx   |    6 ------
 vcl/headless/CairoCommon.cxx                  |    1 -
 vcl/qt5/QtGraphics_GDI.cxx                    |   11 +----------
 vcl/quartz/AquaGraphicsBackend.cxx            |   12 +-----------
 vcl/skia/gdiimpl.cxx                          |   11 +----------
 vcl/win/gdi/gdiimpl.cxx                       |   14 ++------------
 10 files changed, 7 insertions(+), 82 deletions(-)

New commits:
commit 664ecbd8916478cdc28a9c793fbdb9359b3cac64
Author:     Noel Grandin <noelgran...@gmail.com>
AuthorDate: Wed Nov 20 16:08:14 2024 +0200
Commit:     Noel Grandin <noelgran...@gmail.com>
CommitDate: Thu Nov 21 08:15:37 2024 +0100

    remove OutDevSupportType::TransparentRect
    
    all our backends support transparency, and have some time, XRender
    support became mandatory a couple of years ago.
    
    Change-Id: Ie2db7e4665068fe88a926e9791d74a82c2e75834
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/176852
    Tested-by: Jenkins
    Reviewed-by: Caolán McNamara <caolan.mcnam...@collabora.com>
    Reviewed-by: Noel Grandin <noel.gran...@collabora.co.uk>

diff --git a/cui/source/options/optgdlg.cxx b/cui/source/options/optgdlg.cxx
index 6ca5847d22cf..65717c944956 100644
--- a/cui/source/options/optgdlg.cxx
+++ b/cui/source/options/optgdlg.cxx
@@ -1065,17 +1065,7 @@ void OfaViewTabPage::Reset( const SfxItemSet* )
     m_xUseHardwareAccell->save_state();
 
     { // #i95644# AntiAliasing
-        if(SvtOptionsDrawinglayer::IsAAPossibleOnThisSystem())
-        {
-            
m_xUseAntiAliase->set_active(SvtOptionsDrawinglayer::IsAntiAliasing());
-        }
-        else
-        {
-            m_xUseAntiAliase->set_active(false);
-            m_xUseAntiAliase->set_sensitive(false);
-            m_xUseAntiAliaseImg->set_visible(true);
-        }
-
+        m_xUseAntiAliase->set_active(SvtOptionsDrawinglayer::IsAntiAliasing());
         bEnable = 
!officecfg::Office::Common::Drawinglayer::AntiAliasing::isReadOnly();
         m_xUseAntiAliase->set_sensitive(bEnable);
         m_xUseAntiAliaseImg->set_visible(!bEnable);
diff --git a/include/svtools/optionsdrawinglayer.hxx 
b/include/svtools/optionsdrawinglayer.hxx
index 28767ce73fbe..e620c0c71e6d 100644
--- a/include/svtools/optionsdrawinglayer.hxx
+++ b/include/svtools/optionsdrawinglayer.hxx
@@ -42,11 +42,6 @@ namespace SvtOptionsDrawinglayer
 SVT_DLLPUBLIC Color       GetStripeColorA();
 SVT_DLLPUBLIC Color       GetStripeColorB();
 
-// #i95644# helper to check if AA is allowed on this system. Currently, for 
WIN it's disabled
-// and OutDevSupportType::TransparentRect is checked (this  hits 
XRenderExtension, e.g.
-// currently for SunRay as long as not supported there)
-SVT_DLLPUBLIC bool       IsAAPossibleOnThisSystem();
-
 // primitives
 SVT_DLLPUBLIC bool        IsAntiAliasing();
 SVT_DLLPUBLIC bool        IsSnapHorVerLinesToDiscrete();
diff --git a/include/vcl/vclenum.hxx b/include/vcl/vclenum.hxx
index 8d37156a3eec..e19648515d7d 100644
--- a/include/vcl/vclenum.hxx
+++ b/include/vcl/vclenum.hxx
@@ -164,7 +164,6 @@ typedef sal_uInt32 sal_UCS4;    // TODO: this should be 
moved to rtl
 
 enum class OutDevSupportType
 {
-    TransparentRect,
     TransparentText     // if alpha in TextColor can be honored
 };
 
diff --git a/svtools/source/config/optionsdrawinglayer.cxx 
b/svtools/source/config/optionsdrawinglayer.cxx
index 5c7ad7250472..277d716681f1 100644
--- a/svtools/source/config/optionsdrawinglayer.cxx
+++ b/svtools/source/config/optionsdrawinglayer.cxx
@@ -46,23 +46,9 @@ Color GetStripeColorB()
 static bool gbPixelSnapHairlineForwardInitial(false);
 static bool gbPixelSnapHairlineForwardLast(true);
 
-bool IsAAPossibleOnThisSystem()
-{
-    static const bool gbAllowAA
-        = 
Application::GetDefaultDevice()->SupportsOperation(OutDevSupportType::TransparentRect);
-    return gbAllowAA;
-}
-
-
 bool IsAntiAliasing()
 {
-    bool bAntiAliasing = 
drawinglayer::geometry::ViewInformation2D::getGlobalAntiAliasing();
-    if (bAntiAliasing && !IsAAPossibleOnThisSystem())
-    {
-        
drawinglayer::geometry::ViewInformation2D::setGlobalAntiAliasing(false, true);
-        bAntiAliasing = false;
-    }
-    return bAntiAliasing;
+    return drawinglayer::geometry::ViewInformation2D::getGlobalAntiAliasing();
 }
 
 /**
diff --git a/svx/source/sdr/overlay/overlayselection.cxx 
b/svx/source/sdr/overlay/overlayselection.cxx
index ff0b3a4a12f7..6f9284696d51 100644
--- a/svx/source/sdr/overlay/overlayselection.cxx
+++ b/svx/source/sdr/overlay/overlayselection.cxx
@@ -106,12 +106,6 @@ namespace sdr::overlay
                         // not possible when in high contrast mode
                         return  OverlayType::Invert;
                     }
-
-                    
if(!pOut->SupportsOperation(OutDevSupportType::TransparentRect))
-                    {
-                        // not possible when no fast transparence paint is 
supported on the system
-                        return OverlayType::Invert;
-                    }
                 }
             }
 
diff --git a/vcl/headless/CairoCommon.cxx b/vcl/headless/CairoCommon.cxx
index 0cb8ceefdedd..754fd9d1797b 100644
--- a/vcl/headless/CairoCommon.cxx
+++ b/vcl/headless/CairoCommon.cxx
@@ -1992,7 +1992,6 @@ bool CairoCommon::supportsOperation(OutDevSupportType 
eType)
 {
     switch (eType)
     {
-        case OutDevSupportType::TransparentRect:
         case OutDevSupportType::TransparentText:
             return true;
     }
diff --git a/vcl/qt5/QtGraphics_GDI.cxx b/vcl/qt5/QtGraphics_GDI.cxx
index fc039c685dc9..8e76741c5f30 100644
--- a/vcl/qt5/QtGraphics_GDI.cxx
+++ b/vcl/qt5/QtGraphics_GDI.cxx
@@ -674,15 +674,6 @@ void QtGraphicsBackend::SetROPLineColor(SalROPColor 
/*nROPColor*/) {}
 
 void QtGraphicsBackend::SetROPFillColor(SalROPColor /*nROPColor*/) {}
 
-bool QtGraphicsBackend::supportsOperation(OutDevSupportType eType) const
-{
-    switch (eType)
-    {
-        case OutDevSupportType::TransparentRect:
-            return true;
-        default:
-            return false;
-    }
-}
+bool QtGraphicsBackend::supportsOperation(OutDevSupportType /*eType*/) const { 
return false; }
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s 
cinkeys+=0=break: */
diff --git a/vcl/quartz/AquaGraphicsBackend.cxx 
b/vcl/quartz/AquaGraphicsBackend.cxx
index 958ea7fcc6f1..1a3b45949801 100644
--- a/vcl/quartz/AquaGraphicsBackend.cxx
+++ b/vcl/quartz/AquaGraphicsBackend.cxx
@@ -1326,16 +1326,6 @@ bool 
AquaGraphicsBackend::implDrawGradient(basegfx::B2DPolyPolygon const& /*rPol
     return false;
 }
 
-bool AquaGraphicsBackend::supportsOperation(OutDevSupportType eType) const
-{
-    switch (eType)
-    {
-        case OutDevSupportType::TransparentRect:
-            return true;
-        default:
-            break;
-    }
-    return false;
-}
+bool AquaGraphicsBackend::supportsOperation(OutDevSupportType /*eType*/) const 
{ return false; }
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/vcl/skia/gdiimpl.cxx b/vcl/skia/gdiimpl.cxx
index 938c640ca34a..aa5a49ba602b 100644
--- a/vcl/skia/gdiimpl.cxx
+++ b/vcl/skia/gdiimpl.cxx
@@ -2267,16 +2267,7 @@ void SkiaSalGraphicsImpl::drawGenericLayout(const 
GenericSalLayout& layout, Colo
     postDraw();
 }
 
-bool SkiaSalGraphicsImpl::supportsOperation(OutDevSupportType eType) const
-{
-    switch (eType)
-    {
-        case OutDevSupportType::TransparentRect:
-            return true;
-        default:
-            return false;
-    }
-}
+bool SkiaSalGraphicsImpl::supportsOperation(OutDevSupportType /*eType*/) const 
{ return false; }
 
 static int getScaling()
 {
diff --git a/vcl/win/gdi/gdiimpl.cxx b/vcl/win/gdi/gdiimpl.cxx
index 7438f6a4ded7..dbd3b15b2916 100644
--- a/vcl/win/gdi/gdiimpl.cxx
+++ b/vcl/win/gdi/gdiimpl.cxx
@@ -2707,19 +2707,9 @@ bool 
WinSalGraphicsImpl::implDrawGradient(basegfx::B2DPolyPolygon const & /*rPol
     return false;
 }
 
-bool WinSalGraphicsImpl::supportsOperation(OutDevSupportType eType) const
+bool WinSalGraphicsImpl::supportsOperation(OutDevSupportType /*eType*/) const
 {
-    bool bRet = false;
-
-    switch (eType)
-    {
-        case OutDevSupportType::TransparentRect:
-            bRet = mrParent.mbVirDev || mrParent.mbWindow;
-            break;
-        default:
-            break;
-    }
-    return bRet;
+    return false;
 }
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Reply via email to