diff options
author | Miklos Vajna <vmiklos@collabora.co.uk> | 2014-05-29 11:54:39 +0200 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.co.uk> | 2014-05-29 14:43:44 +0200 |
commit | ad8aeb6e02444aa007ef38a59bbd84d67d60ffad (patch) | |
tree | 959a110df5c84ee588869b6e7598a1f80ebf82d1 /sw/source | |
parent | cd0ff1b3c2f388d37c3c9239148a3b302ae19ce4 (diff) |
SwTextBoxHelper::create(): initialize size
On import, syncProperty() takes care of this, but in case the user
interactively adds a textbox, when we need to handle the size in
create() as well.
Change-Id: I9428a682dbf70550bdfd081900e8098aeb64d38f
Diffstat (limited to 'sw/source')
-rw-r--r-- | sw/source/core/doc/textboxhelper.cxx | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/sw/source/core/doc/textboxhelper.cxx b/sw/source/core/doc/textboxhelper.cxx index 7735de51a36d..1e92c67ce9de 100644 --- a/sw/source/core/doc/textboxhelper.cxx +++ b/sw/source/core/doc/textboxhelper.cxx @@ -66,6 +66,10 @@ void SwTextBoxHelper::create(SwFrmFmt* pShape) aSet.Put(aCntnt); pShape->SetFmtAttr(aSet); } + + // Also initialize the properties, which are not constant, but inherited from the shape's ones. + uno::Reference<drawing::XShape> xShape(pShape->FindRealSdrObject()->getUnoShape(), uno::UNO_QUERY); + syncProperty(pShape, RES_FRM_SIZE, MID_FRMSIZE_SIZE, "Size", uno::makeAny(xShape->getSize())); } } |