summaryrefslogtreecommitdiff
path: root/svgio/source
diff options
context:
space:
mode:
authorXisco Fauli <xiscofauli@libreoffice.org>2022-07-18 13:21:35 +0200
committerAndras Timar <andras.timar@collabora.com>2022-08-01 08:46:35 +0200
commitaae4920e88d4cadae44b4cc12e72dc848599c8dd (patch)
tree4afaba68e117bc79bfa6f6399b97968c64ee068d /svgio/source
parent66862a4800051c9c8623661535fc2c3adafa748d (diff)
related: tdf#97539: SVGIO: iterate over parent's clippaths
This commit reintroduces fb33451a27d8668bc14f5bcfd6ea742fc4c5b84c "tdf#97539: SVGIO: iterate over parent's clippaths" which I reverted it in 82c0a363abbceac6464b62c3571aa3225415c7db "tdf#97539; if parent is css style, look one level up" because I thought it was no longer necessary, but I was wrong. Also add a unittest Change-Id: Ib66ca0afd63e8e52be6677b6965179e092a61aa8 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/137195 Tested-by: Jenkins Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org> Signed-off-by: Xisco Fauli <xiscofauli@libreoffice.org> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/137208 Reviewed-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com> Signed-off-by: Xisco Fauli <xiscofauli@libreoffice.org> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/137218 Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
Diffstat (limited to 'svgio/source')
-rw-r--r--svgio/source/svgreader/svgstyleattributes.cxx3
1 files changed, 2 insertions, 1 deletions
diff --git a/svgio/source/svgreader/svgstyleattributes.cxx b/svgio/source/svgreader/svgstyleattributes.cxx
index 891c5ff76c7e..8084ed5f0239 100644
--- a/svgio/source/svgreader/svgstyleattributes.cxx
+++ b/svgio/source/svgreader/svgstyleattributes.cxx
@@ -1188,10 +1188,11 @@ namespace svgio::svgreader
}
const SvgClipPathNode* pClip = accessClipPathXLink();
- if(pClip)
+ while(pClip)
{
// #i124852# transform may be needed when SvgUnits::userSpaceOnUse
pClip->apply(aSource, pTransform);
+ pClip = pClip->getSvgStyleAttributes()->accessClipPathXLink();
}
if(!aSource.empty()) // test again, applied clipPath may have lead to empty geometry