From bdcd01c39324f5c74e0f696f2afc3449243e6c4b Mon Sep 17 00:00:00 2001 From: Armin Le Grand Date: Thu, 2 May 2013 16:29:07 +0000 Subject: i122142 do use simple text hilight frame when captions are in TextEdit mode --- svx/source/svdraw/svdmrkv.cxx | 7 +++++++ svx/source/svdraw/svdorect.cxx | 1 + 2 files changed, 8 insertions(+) diff --git a/svx/source/svdraw/svdmrkv.cxx b/svx/source/svdraw/svdmrkv.cxx index b8c1d8ceab9e..5132140bcf99 100644 --- a/svx/source/svdraw/svdmrkv.cxx +++ b/svx/source/svdraw/svdmrkv.cxx @@ -54,6 +54,7 @@ #include #include #include +#include //////////////////////////////////////////////////////////////////////////////////////////////////// // predefines @@ -716,6 +717,12 @@ void SdrMarkView::SetMarkHandles() } } + // #122142# for captions in TextEdit, force to FrameHdls to get the special text selection + if(!bFrmHdl && pMarkedObj && bSingleTextObjMark && dynamic_cast< SdrCaptionObj* >(pMarkedObj)) + { + bFrmHdl = true; + } + if (bFrmHdl) { Rectangle aRect(GetMarkedObjRect()); diff --git a/svx/source/svdraw/svdorect.cxx b/svx/source/svdraw/svdorect.cxx index 8d21289d593c..7e1c21343e78 100644 --- a/svx/source/svdraw/svdorect.cxx +++ b/svx/source/svdraw/svdorect.cxx @@ -330,6 +330,7 @@ SdrHdl* SdrRectObj::GetHdl(sal_uInt32 nHdlNum) const { case 0: { + OSL_ENSURE(!IsTextEditActive(), "Do not use a ImpTextframeHdl for hilighting text in active text edit, this will collide with EditEngine paints (!)"); pH = new ImpTextframeHdl(aRect); pH->SetObj((SdrObject*)this); pH->SetDrehWink(aGeo.nDrehWink); -- cgit