diff options
author | Miklos Vajna <vmiklos@collabora.co.uk> | 2014-03-19 09:59:32 +0100 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.co.uk> | 2014-03-19 10:06:38 +0100 |
commit | 81f9fe3a14f0fc99afbfa7ce3a26a9c7855d0919 (patch) | |
tree | 4dea4df2056ea35e66aecc1dd3537882cac88c5d /oox | |
parent | 75122338eba5515786198b734d43577d727e3c67 (diff) |
fdo#74401 VML groupshape import: only handle v:rect as TextShape
Regression from commit 75934fc178ed90b56d77eb1efebed5bdac8427b6 (VML
import: handle shape with text inside groupshape as TextShape,
2014-01-17), the problem was that TextShape is also a kind of rectangle,
so that shouldn't be used for all shape with text in groupshapes, just
for v:rect elements.
This fix gives the required text wrapping for the referenced bugdoc
without turning the rest of the shapes into rectangles.
Change-Id: I6e343c65a869e335b641728adbc7984ee85377b5
Diffstat (limited to 'oox')
-rw-r--r-- | oox/source/vml/vmlshapecontext.cxx | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/oox/source/vml/vmlshapecontext.cxx b/oox/source/vml/vmlshapecontext.cxx index d213815dd8f1..fe7e8ec7e3fe 100644 --- a/oox/source/vml/vmlshapecontext.cxx +++ b/oox/source/vml/vmlshapecontext.cxx @@ -459,7 +459,8 @@ ContextHandlerRef ShapeContext::onCreateContext( sal_Int32 nElement, const Attri dynamic_cast<SimpleShape&>( mrShape ).setService( "com.sun.star.text.TextFrame"); } - else + else if (getCurrentElement() == VML_TOKEN(rect)) + // Transform only rectangles into a TextShape inside a groupshape. dynamic_cast<SimpleShape&>(mrShape).setService("com.sun.star.drawing.TextShape"); return new TextBoxContext( *this, mrShapeModel.createTextBox(mrShape.getTypeModel()), rAttribs, mrShape.getDrawing().getFilter().getGraphicHelper()); |