no longer need this svtools/drawinglayer hack
after
commit 664ecbd891
Author: Noel Grandin <noelgrandin@gmail.com>
Date: Wed Nov 20 16:08:14 2024 +0200
remove OutDevSupportType::TransparentRect
Change-Id: I57804ec9e9967c7082a1f657165d967d75b1dedf
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/176910
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Tested-by: Jenkins
This commit is contained in:
@@ -48,12 +48,6 @@ constexpr OUStringLiteral g_PropertyName_UseAntiAliasing = u"UseAntiAliasing";
|
||||
constexpr OUStringLiteral g_PropertyName_PixelSnapHairline = u"PixelSnapHairline";
|
||||
}
|
||||
|
||||
namespace
|
||||
{
|
||||
bool bForwardsAreInitialized(false);
|
||||
bool bForwardPixelSnapHairline(true);
|
||||
}
|
||||
|
||||
class ImpViewInformation2D
|
||||
{
|
||||
private:
|
||||
@@ -123,8 +117,13 @@ public:
|
||||
, mbEditViewActive(false)
|
||||
, mbReducedDisplayQuality(false)
|
||||
, mbUseAntiAliasing(ViewInformation2D::getGlobalAntiAliasing())
|
||||
, mbPixelSnapHairline(mbUseAntiAliasing && bForwardPixelSnapHairline)
|
||||
{
|
||||
if (comphelper::IsFuzzing())
|
||||
mbPixelSnapHairline = false;
|
||||
else
|
||||
mbPixelSnapHairline
|
||||
= mbUseAntiAliasing
|
||||
&& officecfg::Office::Common::Drawinglayer::SnapHorVerLinesToDiscrete::get();
|
||||
}
|
||||
|
||||
const basegfx::B2DHomMatrix& getObjectTransformation() const { return maObjectTransformation; }
|
||||
@@ -250,18 +249,11 @@ ViewInformation2D::ImplType& theGlobalDefault()
|
||||
ViewInformation2D::ViewInformation2D()
|
||||
: mpViewInformation2D(theGlobalDefault())
|
||||
{
|
||||
if (!bForwardsAreInitialized)
|
||||
{
|
||||
bForwardsAreInitialized = true;
|
||||
if (!comphelper::IsFuzzing())
|
||||
{
|
||||
bForwardPixelSnapHairline
|
||||
= officecfg::Office::Common::Drawinglayer::SnapHorVerLinesToDiscrete::get();
|
||||
}
|
||||
}
|
||||
|
||||
setUseAntiAliasing(ViewInformation2D::getGlobalAntiAliasing());
|
||||
setPixelSnapHairline(bForwardPixelSnapHairline);
|
||||
if (!comphelper::IsFuzzing())
|
||||
setPixelSnapHairline(
|
||||
getUseAntiAliasing()
|
||||
&& officecfg::Office::Common::Drawinglayer::SnapHorVerLinesToDiscrete::get());
|
||||
}
|
||||
|
||||
ViewInformation2D::ViewInformation2D(const ViewInformation2D&) = default;
|
||||
@@ -427,11 +419,6 @@ void ViewInformation2D::setGlobalAntiAliasing(bool bAntiAliasing, bool bTemporar
|
||||
}
|
||||
bool ViewInformation2D::getGlobalAntiAliasing() { return globalAntiAliasing(); }
|
||||
|
||||
void ViewInformation2D::forwardPixelSnapHairline(bool bPixelSnapHairline)
|
||||
{
|
||||
bForwardPixelSnapHairline = bPixelSnapHairline;
|
||||
}
|
||||
|
||||
ViewInformation2D
|
||||
createViewInformation2D(const css::uno::Sequence<css::beans::PropertyValue>& rViewParameters)
|
||||
{
|
||||
|
@@ -173,7 +173,6 @@ public:
|
||||
|
||||
static void setGlobalAntiAliasing(bool bAntiAliasing, bool bTemporary);
|
||||
static bool getGlobalAntiAliasing();
|
||||
static void forwardPixelSnapHairline(bool bPixelSnapHairline);
|
||||
};
|
||||
|
||||
DRAWINGLAYERCORE_DLLPUBLIC ViewInformation2D
|
||||
|
@@ -43,9 +43,6 @@ Color GetStripeColorB()
|
||||
return Color(ColorTransparency, officecfg::Office::Common::Drawinglayer::StripeColorB::get());
|
||||
}
|
||||
|
||||
static bool gbPixelSnapHairlineForwardInitial(false);
|
||||
static bool gbPixelSnapHairlineForwardLast(true);
|
||||
|
||||
bool IsAntiAliasing()
|
||||
{
|
||||
return drawinglayer::geometry::ViewInformation2D::getGlobalAntiAliasing();
|
||||
@@ -64,16 +61,7 @@ void SetAntiAliasing( bool bOn, bool bTemporary )
|
||||
|
||||
bool IsSnapHorVerLinesToDiscrete()
|
||||
{
|
||||
const bool bRetval(IsAntiAliasing() && officecfg::Office::Common::Drawinglayer::SnapHorVerLinesToDiscrete::get());
|
||||
|
||||
if (!gbPixelSnapHairlineForwardInitial || gbPixelSnapHairlineForwardLast != bRetval)
|
||||
{
|
||||
gbPixelSnapHairlineForwardInitial = true;
|
||||
gbPixelSnapHairlineForwardLast = bRetval;
|
||||
drawinglayer::geometry::ViewInformation2D::forwardPixelSnapHairline(bRetval);
|
||||
}
|
||||
|
||||
return bRetval;
|
||||
return IsAntiAliasing() && officecfg::Office::Common::Drawinglayer::SnapHorVerLinesToDiscrete::get();
|
||||
}
|
||||
|
||||
sal_uInt16 GetTransparentSelectionPercent()
|
||||
|
Reference in New Issue
Block a user