summaryrefslogtreecommitdiff
path: root/svgio/source
diff options
context:
space:
mode:
authorXisco Fauli <xiscofauli@libreoffice.org>2022-07-18 13:21:35 +0200
committerXisco Fauli <xiscofauli@libreoffice.org>2022-07-18 21:59:57 +0200
commit47c428537154cd94b1d9a7547bde21ce711abd0d (patch)
tree347288edd76bc4753efb7e3dc25e30e3655ff10c /svgio/source
parent67c422585db43e30f0c9e4c9753fcd14f87a277f (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>
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 6b676cd952f7..6ad1b1d25cc2 100644
--- a/svgio/source/svgreader/svgstyleattributes.cxx
+++ b/svgio/source/svgreader/svgstyleattributes.cxx
@@ -1196,10 +1196,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