diff options
author | Michael Stahl <michael.stahl@allotropia.de> | 2023-05-26 16:20:47 +0200 |
---|---|---|
committer | Michael Stahl <michael.stahl@allotropia.de> | 2023-05-26 19:19:20 +0200 |
commit | 370533da3f07169791c0a17013ca55c57df2f3c9 (patch) | |
tree | e61a654563517962ab16f2cc4d836857067d861d /svx | |
parent | ef2d064c403738660e9ba6bee6de736d0575dade (diff) |
tdf#155190 svx,sw: PDF export: don't tag SwNoTextFrame as Artifact
The problem is that inside of the Figure tag, in
SwNoTextFrame::ImplPaintPictureGraphic(), ViewContactOfSwNoTextFrame
and ViewObjectContactOfSwNoTextFrame are used to create and process
another primitive sequence.
ViewObjectContactOfSwNoTextFrame does not have access to a SdrObject,
because that was already processed by the outer layer of code that
called the SwFlyFrame painting code.
Avoid running the code that assumes anything without an SdrObject is an
artifact by disabling PDF tags altogether in
ViewObjectContactOfSwNoTextFrame.
(regression from commit 81ef84648515965bf67afaced946227d0f63a71e)
Change-Id: I9fabe7f7e5296f8d850448ac44865f87cd164591
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/152335
Tested-by: Jenkins
Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
Diffstat (limited to 'svx')
-rw-r--r-- | svx/source/sdr/contact/viewobjectcontact.cxx | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/svx/source/sdr/contact/viewobjectcontact.cxx b/svx/source/sdr/contact/viewobjectcontact.cxx index fb6f0fc73ff1..82b21d137ef1 100644 --- a/svx/source/sdr/contact/viewobjectcontact.cxx +++ b/svx/source/sdr/contact/viewobjectcontact.cxx @@ -341,6 +341,11 @@ void ViewObjectContact::createPrimitive2DSequence(const DisplayInfo& rDisplayInf rVisitor.visit(xRetval); } +bool ViewObjectContact::isExportPDFTags() const +{ + return GetObjectContact().isExportTaggedPDF(); +} + drawinglayer::primitive2d::Primitive2DContainer const & ViewObjectContact::getPrimitive2DSequence(const DisplayInfo& rDisplayInfo) const { // only some of the top-level apps are any good at reliably invalidating us (e.g. writer is not) @@ -387,7 +392,7 @@ drawinglayer::primitive2d::Primitive2DContainer const & ViewObjectContact::getPr // Check if we need to embed to a StructureTagPrimitive2D, too. This // was done at ImplRenderPaintProc::createRedirectedPrimitive2DSequence before - if (!xNewPrimitiveSequence.empty() && GetObjectContact().isExportTaggedPDF()) + if (!xNewPrimitiveSequence.empty() && isExportPDFTags()) { if (nullptr != pSdrObj) { |