Blob Blame History Raw
From 6c76b4b478428d2326ea672d1bd87d1fa9654797 Mon Sep 17 00:00:00 2001
From: Miklos Vajna <vmiklos@collabora.co.uk>
Date: Fri, 6 Nov 2015 17:12:46 +0100
Subject: [PATCH 285/398] sc lok annotations: paint range and anchor overlay

Change-Id: I16e51e074704026a45471e7a08c3b96846d44053
(cherry picked from commit 5f68759810496ff3fadf5a883203449772c7392f)
---
 sw/source/uibase/docvw/SidebarWin.cxx | 15 +++++++++++++++
 1 file changed, 15 insertions(+)

diff --git a/sw/source/uibase/docvw/SidebarWin.cxx b/sw/source/uibase/docvw/SidebarWin.cxx
index 038bdb243e65..e3e238715365 100644
--- a/sw/source/uibase/docvw/SidebarWin.cxx
+++ b/sw/source/uibase/docvw/SidebarWin.cxx
@@ -263,6 +263,21 @@ void SwSidebarWin::PaintTile(vcl::RenderContext& rRenderContext, const Rectangle
 
         rRenderContext.Pop();
     }
+
+    const drawinglayer::geometry::ViewInformation2D aViewInformation;
+    std::unique_ptr<drawinglayer::processor2d::BaseProcessor2D> pProcessor(drawinglayer::processor2d::createBaseProcessor2DFromOutputDevice(rRenderContext, aViewInformation));
+
+    // drawinglayer sets the map mode to pixels, not needed here.
+    rRenderContext.Pop();
+    // Work in document-global twips.
+    rRenderContext.Pop();
+    if (mpAnchor)
+        pProcessor->process(mpAnchor->getOverlayObjectPrimitive2DSequence());
+    if (mpTextRangeOverlay)
+        pProcessor->process(mpTextRangeOverlay->getOverlayObjectPrimitive2DSequence());
+    rRenderContext.Push(PushFlags::NONE);
+    pProcessor.reset();
+    rRenderContext.Push(PushFlags::NONE);
 }
 
 void SwSidebarWin::Draw(OutputDevice* pDev, const Point& rPt, const Size& rSz, sal_uLong nInFlags)
-- 
2.12.0