sc/source/ui/view/tabview3.cxx | 23 +++++++++-------------- 1 file changed, 9 insertions(+), 14 deletions(-)
New commits: commit a07a0f429c3a1a6709ec42907d00b29b84c75447 Author: Armin Le Grand (Collabora) <armin.le.gr...@me.com> AuthorDate: Wed May 28 15:29:41 2025 +0200 Commit: Armin Le Grand <armin.le.gr...@me.com> CommitDate: Wed May 28 18:32:14 2025 +0200 tdf#166525 CEOO: Back to overpaint everything Change-Id: Ia39331001a6759d27e938602b1fc5d8da2e90ada Reviewed-on: https://gerrit.libreoffice.org/c/core/+/185971 Reviewed-by: Armin Le Grand <armin.le.gr...@me.com> Tested-by: Jenkins diff --git a/sc/source/ui/view/tabview3.cxx b/sc/source/ui/view/tabview3.cxx index 51b13f8945c5..15d7a85e6f8a 100644 --- a/sc/source/ui/view/tabview3.cxx +++ b/sc/source/ui/view/tabview3.cxx @@ -35,9 +35,7 @@ #include <osl/diagnose.h> #include <basegfx/polygon/b2dpolygontools.hxx> -#include <drawinglayer/primitive2d/PolyPolygonRGBAPrimitive2D.hxx> -#include <drawinglayer/primitive2d/unifiedtransparenceprimitive2d.hxx> -#include <drawinglayer/primitive2d/modifiedcolorprimitive2d.hxx> +#include <drawinglayer/primitive2d/PolyPolygonColorPrimitive2D.hxx> #include <drawinglayer/primitive2d/transformprimitive2d.hxx> #include <svx/sdr/overlay/overlayselection.hxx> #include <svtools/optionsdrawinglayer.hxx> @@ -2467,28 +2465,25 @@ drawinglayer::primitive2d::Primitive2DContainer ScTextEditOverlayObject::getOver if (aStart != aEnd) { + // create outline polygon. Shrink by 1px due to working + // with pixel positions one cell right and below. We are + // in discrete (pixel) coordinates with start/end here, + // so just substract '1' from x and y to do that basegfx::B2DPolyPolygon aOutline(basegfx::utils::createPolygonFromRect( basegfx::B2DRange( aStart.X(), aStart.Y(), - aEnd.X(), aEnd.Y()))); + aEnd.X() - 1, aEnd.Y() - 1))); // transform from Pixels to LogicDrawCoordinates ScGridWindow* pActiveWin(static_cast<ScGridWindow*>(mrScTabView.GetWindowByPos(maScSplitPos))); rOutDev.SetMapMode(pActiveWin->GetDrawMapMode()); aOutline.transform(rOutDev.GetInverseViewTransformation()); - // on overlay we can now design the look more freely, it - // uses the CellBackgroundColor combined with 50% transparence - // to not completely hide what may be behind. - // Also currently no need to shrink by 2px (?) right/bottom - // to not kill cell separation lines - may have to be re-added - // when transparency is not wanted aRetval.push_back( - rtl::Reference<drawinglayer::primitive2d::PolyPolygonRGBAPrimitive2D>( - new drawinglayer::primitive2d::PolyPolygonRGBAPrimitive2D( + rtl::Reference<drawinglayer::primitive2d::PolyPolygonColorPrimitive2D>( + new drawinglayer::primitive2d::PolyPolygonColorPrimitive2D( aOutline, - pEditView->GetBackgroundColor().getBColor(), - 0.5))); + pEditView->GetBackgroundColor().getBColor()))); } }