vcl/source/gdi/pdfwriter_impl.cxx |    5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

New commits:
commit 4b83cd1e9479fd3292d2630593a2fb051016482a
Author:     Juraj Šarinay <ju...@sarinay.com>
AuthorDate: Fri Jan 31 18:04:34 2025 +0100
Commit:     Tomaž Vajngerl <qui...@gmail.com>
CommitDate: Fri May 2 08:43:26 2025 +0200

    tdf#121133 Emit /DR within AcroForm as a direct object
    
    An indirect /DR within AcroForm causes Acrobat Reader to warn
    of modification of documents signed on export. Emit /DR as a direct
    object referring to the \Font directory.
    
    Change-Id: I82aedf439c8edfceb938c86ba16a7ab4cda90bb1
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/181364
    Tested-by: Jenkins
    Reviewed-by: Tomaž Vajngerl <qui...@gmail.com>

diff --git a/vcl/source/gdi/pdfwriter_impl.cxx 
b/vcl/source/gdi/pdfwriter_impl.cxx
index a167743618a2..88722e9bcfd4 100644
--- a/vcl/source/gdi/pdfwriter_impl.cxx
+++ b/vcl/source/gdi/pdfwriter_impl.cxx
@@ -5510,8 +5510,9 @@ bool PDFWriterImpl::emitCatalog()
             bSigned = true;
         }
 #endif
-        aLine.append("/DR ");
-        appendObjectReference(getResourceDictObj(), aLine);
+        aLine.append("/DR<</Font ");
+        appendObjectReference(getFontDictObject(), aLine);
+        aLine.append(">>");
 
         // NeedAppearances must not be used if PDF is signed, PDF/A is used or
         // we have copied widgets (can't guarantee we have appearance streams 
in this case)

Reply via email to