diff options
author | Attila Bakos (NISZ) <bakos.attilakaroly@nisz.hu> | 2021-08-13 14:11:24 +0200 |
---|---|---|
committer | László Németh <nemeth@numbertext.org> | 2021-09-01 10:09:37 +0200 |
commit | 504d78acb866495fd954fcd6db22ea68f174a5ab (patch) | |
tree | 454c012ca959cf144c3380a7e7b58561fac3704e /sw/source/uibase/shells/drawsh.cxx | |
parent | 9c9ff9e89fd50223b28f327d3a7e416ab0ae831f (diff) |
tdf#143574 sw: textboxes in group shapes - part 1
Introduce SwTextBoxNode class to support grouped
textboxes, fixing the crash when entering a group
shape, trying to add a textbox to one of the shapes.
Test of crash fix: right click on a group shape.
Select the menu item "Enter group". Select one of
the shapes, and right click on it, and choose "Add
Text Box".
Note: textboxes in Writer are linked in SwFrameFormat
class. Each textbox consists of a text frame and a shape.
This object pair makes it possible to have complex
content inside any kind of shape (pictures, tables etc.
Group shapes have only one SwFrameFormat, but can have
many shapes so that means they can only have one textbox.
From now, each shape could have a textbox in a group.
Please note this is only a preparation for that. Filter
implementation and handlers are under development.
Change-Id: Iae35c118f0e67697b289c30d0fad4f5e16501c02
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/120452
Tested-by: László Németh <nemeth@numbertext.org>
Reviewed-by: László Németh <nemeth@numbertext.org>
Diffstat (limited to 'sw/source/uibase/shells/drawsh.cxx')
-rw-r--r-- | sw/source/uibase/shells/drawsh.cxx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sw/source/uibase/shells/drawsh.cxx b/sw/source/uibase/shells/drawsh.cxx index 89d8658597dc..beb197c87fa9 100644 --- a/sw/source/uibase/shells/drawsh.cxx +++ b/sw/source/uibase/shells/drawsh.cxx @@ -372,7 +372,7 @@ void SwDrawShell::Execute(SfxRequest &rReq) { SwFrameFormat* pFrameFormat = ::FindFrameFormat(pObj); if (pFrameFormat) - SwTextBoxHelper::create(pFrameFormat, pObj->HasText()); + SwTextBoxHelper::create(pFrameFormat, pObj, pObj->HasText()); } break; } @@ -382,7 +382,7 @@ void SwDrawShell::Execute(SfxRequest &rReq) { SwFrameFormat* pFrameFormat = ::FindFrameFormat(pObj); if (pFrameFormat) - SwTextBoxHelper::destroy(pFrameFormat); + SwTextBoxHelper::destroy(pFrameFormat, pObj); } break; } |