Kaydet (Commit) 0549f250 authored tarafından Miklos Vajna's avatar Miklos Vajna

Add SwView::EnterShapeDrawTextMode()

Change-Id: Ic19519ee727bd4b6c18d14dc3eb21b2eeb4395c9
üst 1349491d
...@@ -556,6 +556,8 @@ public: ...@@ -556,6 +556,8 @@ public:
inline void FlipDrawSelMode() { m_bDrawSelMode = !m_bDrawSelMode; } inline void FlipDrawSelMode() { m_bDrawSelMode = !m_bDrawSelMode; }
void NoRotate(); // turn off rotate mode void NoRotate(); // turn off rotate mode
bool EnterDrawTextMode(const Point& aDocPos); bool EnterDrawTextMode(const Point& aDocPos);
/// Same as EnterDrawTextMode(), but takes an SdrObject instead of guessing it by document position.
bool EnterShapeDrawTextMode(SdrObject* pObject);
void LeaveDrawCreate() { m_nDrawSfxId = m_nFormSfxId = USHRT_MAX; m_sDrawCustom.clear();} void LeaveDrawCreate() { m_nDrawSfxId = m_nFormSfxId = USHRT_MAX; m_sDrawCustom.clear();}
bool IsDrawMode() { return (m_nDrawSfxId != USHRT_MAX || m_nFormSfxId != USHRT_MAX); } bool IsDrawMode() { return (m_nDrawSfxId != USHRT_MAX || m_nFormSfxId != USHRT_MAX); }
bool IsFormMode() const; bool IsFormMode() const;
......
...@@ -504,6 +504,13 @@ bool SwView::EnterDrawTextMode(const Point& aDocPos) ...@@ -504,6 +504,13 @@ bool SwView::EnterDrawTextMode(const Point& aDocPos)
return bReturn; return bReturn;
} }
bool SwView::EnterShapeDrawTextMode(SdrObject* pObject)
{
SdrView* pSdrView = GetWrtShell().GetDrawView();
SdrPageView* pPageView = pSdrView->GetSdrPageView();
return BeginTextEdit(pObject, pPageView, m_pEditWin);
}
// Enable DrawTextEditMode // Enable DrawTextEditMode
bool SwView::BeginTextEdit(SdrObject* pObj, SdrPageView* pPV, vcl::Window* pWin, bool SwView::BeginTextEdit(SdrObject* pObj, SdrPageView* pPV, vcl::Window* pWin,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment