diff options
author | Tomaž Vajngerl <tomaz.vajngerl@collabora.co.uk> | 2024-06-27 21:11:50 +0900 |
---|---|---|
committer | Tomaž Vajngerl <quikee@gmail.com> | 2024-07-04 10:06:31 +0200 |
commit | 4e97c21ab32f3e6f28a842ad14bad41f00fefda5 (patch) | |
tree | 3ab7b5a4771721ab26f6761ebcb9a465e5fc34f6 /sd | |
parent | daca6c1e86c9db1ffe400178d13b8c90b6e7579d (diff) |
annot: AnnotationObject should be the size as the text content
This makes the AnnotationObject to resize the frame to the size of
the text content, or else the text that is too big will be shown
outside the object's frame (rectangle). For some reason we need to
set the object as a "text frame" (mbTextFrame = true) or else it
will not allow to automatically adjust the frame to the text
content.
Change-Id: Ib2b9a7c07626fe8b0a2286cfd67c3bf37cf9af03
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/169642
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Tested-by: Jenkins
Diffstat (limited to 'sd')
-rw-r--r-- | sd/source/ui/annotations/annotationmanager.cxx | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sd/source/ui/annotations/annotationmanager.cxx b/sd/source/ui/annotations/annotationmanager.cxx index b07a79932b5d..940c763f73cc 100644 --- a/sd/source/ui/annotations/annotationmanager.cxx +++ b/sd/source/ui/annotations/annotationmanager.cxx @@ -1108,7 +1108,7 @@ void AnnotationManagerImpl::SyncAnnotationObjects() applyAnnotationProperties(*pNewObject, rInfo); } - pNewObject->SetLogicRect(aRectangle); + pNewObject->SetRelativePos(aRectangle.TopLeft()); pView->InsertObjectAtView(pNewObject.get(), *pView->GetSdrPageView()); |