summaryrefslogtreecommitdiff
path: root/sc/source/ui
diff options
context:
space:
mode:
Diffstat (limited to 'sc/source/ui')
-rw-r--r--sc/source/ui/inc/gridwin.hxx3
-rw-r--r--sc/source/ui/view/gridwin.cxx39
2 files changed, 10 insertions, 32 deletions
diff --git a/sc/source/ui/inc/gridwin.hxx b/sc/source/ui/inc/gridwin.hxx
index c111ee23a7e1..9b31289d13d0 100644
--- a/sc/source/ui/inc/gridwin.hxx
+++ b/sc/source/ui/inc/gridwin.hxx
@@ -99,8 +99,7 @@ public:
// predefines
class ScGridWindow;
-enum ScOverlayType { SC_OVERLAY_INVERT, SC_OVERLAY_HATCH, SC_OVERLAY_SOLID,
- SC_OVERLAY_TRANSPARENT, SC_OVERLAY_LIGHT_TRANSPARENT, SC_OVERLAY_BORDER_TRANSPARENT };
+enum ScOverlayType { SC_OVERLAY_INVERT, SC_OVERLAY_SOLID, SC_OVERLAY_BORDER_TRANSPARENT };
// #114409#
namespace sdr
diff --git a/sc/source/ui/view/gridwin.cxx b/sc/source/ui/view/gridwin.cxx
index b6cd29a7d714..36566677a858 100644
--- a/sc/source/ui/view/gridwin.cxx
+++ b/sc/source/ui/view/gridwin.cxx
@@ -5477,9 +5477,6 @@ void ScGridWindow::UpdateDragRectOverlay()
if(pOverlayManager)
{
ScOverlayType eType = SC_OVERLAY_INVERT;
-// ScOverlayType eType = SC_OVERLAY_HATCH;
-// ScOverlayType eType = SC_OVERLAY_TRANSPARENT;
-
Color aHighlight = GetSettings().GetStyleSettings().GetHighlightColor();
sdr::overlay::OverlayObjectCell* pOverlay =
new sdr::overlay::OverlayObjectCell( eType, aHighlight, aRanges );
@@ -5531,9 +5528,6 @@ void ScGridWindow::UpdateHeaderOverlay()
if(pOverlayManager)
{
ScOverlayType eType = SC_OVERLAY_INVERT;
-// ScOverlayType eType = SC_OVERLAY_HATCH;
-// ScOverlayType eType = SC_OVERLAY_TRANSPARENT;
-
Color aHighlight = GetSettings().GetStyleSettings().GetHighlightColor();
sdr::overlay::OverlayObjectCell* pOverlay =
new sdr::overlay::OverlayObjectCell( eType, aHighlight, aRanges );
@@ -5608,9 +5602,6 @@ void ScGridWindow::UpdateShrinkOverlay()
if(pOverlayManager)
{
ScOverlayType eType = SC_OVERLAY_INVERT;
-// ScOverlayType eType = SC_OVERLAY_HATCH;
-// ScOverlayType eType = SC_OVERLAY_TRANSPARENT;
-
Color aHighlight = GetSettings().GetStyleSettings().GetHighlightColor();
sdr::overlay::OverlayObjectCell* pOverlay =
new sdr::overlay::OverlayObjectCell( eType, aHighlight, aRanges );
@@ -5674,6 +5665,10 @@ namespace sdr
void OverlayObjectCell::drawGeometry(OutputDevice& rOutputDevice)
{
+ // safe original AA and switch off for selection
+ const sal_uInt16 nOriginalAA(rOutputDevice.GetAntialiasing());
+ rOutputDevice.SetAntialiasing(0);
+
// set colors
rOutputDevice.SetLineColor();
rOutputDevice.SetFillColor(getBaseColor());
@@ -5726,17 +5721,6 @@ namespace sdr
case SC_OVERLAY_INVERT :
{
rOutputDevice.DrawRect( aRectangle );
-
- // if(OUTDEV_WINDOW == rOutputDevice.GetOutDevType())
- // {
- // ((Window&)rOutputDevice).Invert(aRectangle, INVERT_HIGHLIGHT);
- // }
-
- break;
- }
- case SC_OVERLAY_HATCH :
- {
- rOutputDevice.DrawHatch(PolyPolygon(Polygon(aRectangle)), Hatch(HATCH_SINGLE, getBaseColor(), 2, 450));
break;
}
case SC_OVERLAY_SOLID :
@@ -5744,16 +5728,6 @@ namespace sdr
rOutputDevice.DrawRect(aRectangle);
break;
}
- case SC_OVERLAY_TRANSPARENT :
- {
- rOutputDevice.DrawTransparent(PolyPolygon(Polygon(aRectangle)), 50);
- break;
- }
- case SC_OVERLAY_LIGHT_TRANSPARENT :
- {
- rOutputDevice.DrawTransparent(PolyPolygon(Polygon(aRectangle)), 75);
- break;
- }
default:
{
// SC_OVERLAY_BORDER_TRANSPARENT is handled separately
@@ -5762,8 +5736,13 @@ namespace sdr
}
if ( mePaintType == SC_OVERLAY_INVERT )
+ {
rOutputDevice.Pop();
+ }
}
+
+ // restore original AA
+ rOutputDevice.SetAntialiasing(nOriginalAA);
}
void OverlayObjectCell::createBaseRange(OutputDevice& /* rOutputDevice */)