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

New commits:
commit 1e31b4f8cbc67c0119680a565417aa10fd9b4679
Author:     Henry Castro <[email protected]>
AuthorDate: Wed Aug 20 11:44:25 2025 -0400
Commit:     Henry Castro <[email protected]>
CommitDate: Fri Sep 26 14:30:10 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 <[email protected]>
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/189971
    Reviewed-by: Caolán McNamara <[email protected]>
    Tested-by: Jenkins CollaboraOffice <[email protected]>
    Tested-by: Caolán McNamara <[email protected]>
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/191539
    Tested-by: Jenkins

diff --git a/sd/source/ui/unoidl/unomodel.cxx b/sd/source/ui/unoidl/unomodel.cxx
index 59316ca26bdf..59e8da020e54 100644
--- a/sd/source/ui/unoidl/unomodel.cxx
+++ b/sd/source/ui/unoidl/unomodel.cxx
@@ -4661,7 +4661,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