drawinglayer/source/processor2d/vclmetafileprocessor2d.cxx |    5 +++++
 1 file changed, 5 insertions(+)

New commits:
commit 9f1c3ed96423ef6ffb6f6910c5ef497026129c5b
Author:     Michael Stahl <michael.st...@allotropia.de>
AuthorDate: Mon Jul 10 20:42:07 2023 +0200
Commit:     Caolán McNamara <caolan.mcnam...@collabora.com>
CommitDate: Wed Jul 26 14:49:05 2023 +0200

    (related tdf#154777) drawinglayer: add BBox to Figure fallback of forms
    
    PAC3 complains if the BBox is missing.
    
    Change-Id: I2cd61b2d01b64ffe77f28c661a3bd6f713df134f
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/154283
    Tested-by: Jenkins
    Reviewed-by: Michael Stahl <michael.st...@allotropia.de>
    (cherry picked from commit 41d8bb928231372f3ef08ce4ba3ea91b17e3ae29)
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/154267
    Reviewed-by: Caolán McNamara <caolan.mcnam...@collabora.com>

diff --git a/drawinglayer/source/processor2d/vclmetafileprocessor2d.cxx 
b/drawinglayer/source/processor2d/vclmetafileprocessor2d.cxx
index 7f25b44e1761..6e1f07efefbb 100644
--- a/drawinglayer/source/processor2d/vclmetafileprocessor2d.cxx
+++ b/drawinglayer/source/processor2d/vclmetafileprocessor2d.cxx
@@ -1175,6 +1175,11 @@ void VclMetafileProcessor2D::processControlPrimitive2D(
     { // no corresponding PDF Form, use Figure instead
         mpPDFExtOutDevData->WrapBeginStructureElement(vcl::PDFWriter::Figure);
         mpPDFExtOutDevData->SetStructureAttribute(vcl::PDFWriter::Placement, 
vcl::PDFWriter::Block);
+        auto const 
range(rControlPrimitive.getB2DRange(getViewInformation2D()));
+        tools::Rectangle const aLogicRect(
+            basegfx::fround(range.getMinX()), basegfx::fround(range.getMinY()),
+            basegfx::fround(range.getMaxX()), 
basegfx::fround(range.getMaxY()));
+        mpPDFExtOutDevData->SetStructureBoundingBox(aLogicRect);
         OUString const& rAltText(rControlPrimitive.GetAltText());
         if (!rAltText.isEmpty())
         {

Reply via email to