diff options
Diffstat (limited to 'oox')
-rw-r--r-- | oox/source/drawingml/shapegroupcontext.cxx | 5 | ||||
-rw-r--r-- | oox/source/drawingml/textcharacterpropertiescontext.cxx | 3 |
2 files changed, 7 insertions, 1 deletions
diff --git a/oox/source/drawingml/shapegroupcontext.cxx b/oox/source/drawingml/shapegroupcontext.cxx index d795c39f63a9..f4e045437206 100644 --- a/oox/source/drawingml/shapegroupcontext.cxx +++ b/oox/source/drawingml/shapegroupcontext.cxx @@ -93,7 +93,10 @@ ContextHandlerRef ShapeGroupContext::onCreateContext( sal_Int32 aElementToken, c return new ShapeGroupContext( *this, mpGroupShapePtr, ShapePtr( new Shape( "com.sun.star.drawing.GroupShape" ) ) ); case XML_sp: // shape case XML_wsp: - return new ShapeContext( *this, mpGroupShapePtr, ShapePtr( new Shape( "com.sun.star.drawing.CustomShape" ) ) ); + // Don't set default character height for WPS shapes, Writer has its + // own way to set the default, and if we don't set it here, editing + // properly inherits it. + return new ShapeContext( *this, mpGroupShapePtr, ShapePtr( new Shape( "com.sun.star.drawing.CustomShape", getBaseToken(aElementToken) == XML_sp ) ) ); case XML_pic: // CT_Picture return new GraphicShapeContext( *this, mpGroupShapePtr, ShapePtr( new Shape( "com.sun.star.drawing.GraphicObjectShape" ) ) ); case XML_graphicFrame: // CT_GraphicalObjectFrame diff --git a/oox/source/drawingml/textcharacterpropertiescontext.cxx b/oox/source/drawingml/textcharacterpropertiescontext.cxx index 7bedd8e2f7a1..600f4727c582 100644 --- a/oox/source/drawingml/textcharacterpropertiescontext.cxx +++ b/oox/source/drawingml/textcharacterpropertiescontext.cxx @@ -165,6 +165,9 @@ ContextHandlerRef TextCharacterPropertiesContext::onCreateContext( sal_Int32 aEl case OOX_TOKEN( doc, b ): mrTextCharacterProperties.moBold = rAttribs.getBool(OOX_TOKEN( doc, val ), true); break; + case OOX_TOKEN( doc, i ): + mrTextCharacterProperties.moItalic = rAttribs.getBool(OOX_TOKEN( doc, val ), true); + break; case OOX_TOKEN( doc, bCs ): break; case OOX_TOKEN( doc, color ): |