Skip to content

armgit / krita

Public Imported from GitHub
0

Krita is a free and open source cross-platform application that offers an end-to-end solution for creating digital art files from scratch built on the KDE and Qt frameworks.

C++

Fix cleanup function in svg text a little.

Wolthera van Hövell tot Westerflier9c19848ef70a
diff --git a/libs/flake/text/KoSvgTextShape_p.h b/libs/flake/text/KoSvgTextShape_p.h
index 94488ebb51..4576adfb84 100644
--- a/libs/flake/text/KoSvgTextShape_p.h
+++ b/libs/flake/text/KoSvgTextShape_p.h
@@ -1285,7 +1285,8 @@ public:
&& (siblingPrev->textPathId.isEmpty() && it->textPathId.isEmpty())
&& (siblingPrev->textLength.isAuto && it->textLength.isAuto)
&& (siblingPrev->properties == it->properties)
- && (bidi != KoSvgText::BidiIsolate && bidi != KoSvgText::BidiIsolateOverride)) {
+ && (bidi != KoSvgText::BidiIsolate && bidi != KoSvgText::BidiIsolateOverride)
+ && childCount(siblingPrev) == 0) {
// TODO: handle localtransforms better; annoyingly, this requires whitespace handling
siblingPrev->text += it->text;
tree.erase(siblingCurrent(it));