sd/source/ui/unoidl/unomodel.cxx |   15 +++++++++++++++
 1 file changed, 15 insertions(+)

New commits:
commit 9ae19d8367baacfb284e19802d4fc1964e4593ac
Author:     Henry Castro <hcas...@collabora.com>
AuthorDate: Wed Aug 20 11:44:25 2025 -0400
Commit:     Caolán McNamara <caolan.mcnam...@collabora.com>
CommitDate: Wed Sep 3 13:05:29 2025 +0200

    sd: Fix custom text shape retrieval on notes page
    
    Adding a custom text drawing on the notes page requires explicitly
    searching for the text rectangle.
    
    Change-Id: Ib7cc0a0c67bf1ab83848ffd1d8396cddc364e375
    Signed-off-by: Henry Castro <hcas...@collabora.com>
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/189971
    Reviewed-by: Caolán McNamara <caolan.mcnam...@collabora.com>
    Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoff...@gmail.com>
    Tested-by: Caolán McNamara <caolan.mcnam...@collabora.com>

diff --git a/sd/source/ui/unoidl/unomodel.cxx b/sd/source/ui/unoidl/unomodel.cxx
index d89f6b39797c..98e4df25cc2b 100644
--- a/sd/source/ui/unoidl/unomodel.cxx
+++ b/sd/source/ui/unoidl/unomodel.cxx
@@ -4679,7 +4679,22 @@ OString SdXImpressDocument::getPresentationInfo() const
                 SdPage* pNotesPage = pPage ? 
mpDoc->GetSdPage((pPage->GetPageNum() - 1) >> 1, PageKind::Notes) : nullptr;
                 if (pNotesPage)
                 {
+                    SdrObject* pItObj = nullptr;
                     SdrObject* pNotes = 
pNotesPage->GetPresObj(PresObjKind::Notes);
+
+                    if (!pNotes)
+                    {
+                        for (size_t nNote = 0; nNote < 
pNotesPage->GetObjCount(); nNote++)
+                        {
+                            pItObj = pNotesPage->GetObj(nNote);
+                            if (pItObj && pItObj->GetObjIdentifier() == 
SdrObjKind::Text)
+                            {
+                                pNotes = pItObj;
+                                break;
+                            }
+                        }
+                    }
+
                     if (pNotes)
                     {
                         OUStringBuffer strNotes;

Reply via email to