sd/source/filter/html/htmlex.cxx |   16 ++++++++++++++++
 sd/source/filter/html/htmlex.hxx |    3 +++
 2 files changed, 19 insertions(+)

New commits:
commit e3351559be3783d73d19e37fd57b3067d14d51b5
Author:     Henry Castro <[email protected]>
AuthorDate: Tue Sep 9 07:47:40 2025 -0400
Commit:     Henry Castro <[email protected]>
CommitDate: Mon Oct 13 19:15:32 2025 +0200

    sd: add function to export HTML content to a single-page format
    
    Accessibility text must be sent to the client-side
    
    Change-Id: I220b1a051c0c247e0883f566f494e0a17885cbfc
    Signed-off-by: Henry Castro <[email protected]>
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/190702
    Tested-by: Caolán McNamara <[email protected]>
    Reviewed-by: Caolán McNamara <[email protected]>
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/192281
    Tested-by: Jenkins

diff --git a/sd/source/filter/html/htmlex.cxx b/sd/source/filter/html/htmlex.cxx
index d104cfd30a73..55c68bb88b0e 100644
--- a/sd/source/filter/html/htmlex.cxx
+++ b/sd/source/filter/html/htmlex.cxx
@@ -720,6 +720,22 @@ void HtmlExport::ExportSingleDocument()
     ResetProgress();
 }
 
+void HtmlExport::ExportPage(SdrOutliner* pOutliner, SdPage* pPage, 
OUStringBuffer& rHtml)
+{
+    if (!pPage || !pOutliner)
+    {
+        return;
+    }
+
+    // page title
+    OUString sTitleText(CreateTextForTitle(pOutliner, pPage));
+
+    rHtml.append("<h1>" + sTitleText + "</h1>
");
+
+    // write outline text
+    rHtml.append(CreateTextForPage(pOutliner, pPage, true));
+}
+
 void HtmlExport::InitProgress( sal_uInt16 nProgrCount )
 {
     mpProgress.reset(new SfxProgress( mpDocSh, SdResId(STR_CREATE_PAGES), 
nProgrCount ));
diff --git a/sd/source/filter/html/htmlex.hxx b/sd/source/filter/html/htmlex.hxx
index b2251a1449eb..37d8135fb77f 100644
--- a/sd/source/filter/html/htmlex.hxx
+++ b/sd/source/filter/html/htmlex.hxx
@@ -34,6 +34,7 @@ namespace sd { class DrawDocShell; }
 
 class SfxProgress;
 class SdPage;
+class SdrOutliner;
 class HtmlState;
 class SdDrawDocument;
 
@@ -71,6 +72,8 @@ class HtmlExport final
                SdDrawDocument& rExpDoc,
                sd::DrawDocShell* pDocShell);
 
+    static void ExportPage(SdrOutliner* pOutliner, SdPage* pPage, 
OUStringBuffer& rHtml);
+
     ~HtmlExport();
 };
 

Reply via email to