Commit d66b7b00 authored by C. Boemann's avatar C. Boemann
Browse files

The new textshape graphic style loading code missed a save/restore

So we basically missed the inheritance info and loaded every thing (with all
the bugs it brings) when loading the para and text part of the graphic style
parent be08ea98
......@@ -297,8 +297,9 @@ void KoTextShapeData::loadStyle(const KoXmlElement &element, KoShapeLoadingConte
if (style) {
context.odfLoadingContext().addStyles(style, style->attributeNS(KoXmlNS::style, "family", "graphic").toLocal8Bit().constData()); // Load all parents
KoStyleStack &styleStack = context.odfLoadingContext().styleStack();
styleStack.save();
context.odfLoadingContext().addStyles(style, style->attributeNS(KoXmlNS::style, "family", "graphic").toLocal8Bit().constData()); // Load all parents
styleStack.setTypeProperties("graphic");
// Spacing (padding)
const QString paddingLeft(styleStack.property(KoXmlNS::fo, "padding-left" ));
......@@ -321,6 +322,7 @@ void KoTextShapeData::loadStyle(const KoXmlElement &element, KoShapeLoadingConte
if (!padding.isEmpty()) {
setPadding(KoUnit::parseValue(padding));
}
styleStack.restore();
// graphic styles don't support inheritance yet therefor some additional work is needed here.
QList<KoParagraphStyle *> paragraphStyles;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment