[Libreoffice-commits] core.git: Branch 'libreoffice-4-2' - oox/source

Matúš Kukan matus.kukan at collabora.com
Tue Aug 12 03:24:48 PDT 2014


 oox/source/drawingml/textbodypropertiescontext.cxx |    6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

New commits:
commit ca51beb73336b3a19364df02aab82d56a2a63e74
Author: Matúš Kukan <matus.kukan at collabora.com>
Date:   Thu Jul 24 20:03:43 2014 +0200

    bnc#887227: Do not set TextAutoGrowHeight for vertical text.
    
    It's horribly broken and it would resize text box
    horizontally which is not supposed to happen.
    
    (cherry picked from commit d068f13596f6d1023a70d98ec2059d38ad6fd777)
    
    Change-Id: I201ec8dbcddca56d21bf46ea8ee838d01923c442
    Reviewed-on: https://gerrit.libreoffice.org/10585
    Reviewed-by: David Tardon <dtardon at redhat.com>
    Tested-by: David Tardon <dtardon at redhat.com>

diff --git a/oox/source/drawingml/textbodypropertiescontext.cxx b/oox/source/drawingml/textbodypropertiescontext.cxx
index b580be3..166ecd0 100644
--- a/oox/source/drawingml/textbodypropertiescontext.cxx
+++ b/oox/source/drawingml/textbodypropertiescontext.cxx
@@ -132,7 +132,11 @@ ContextHandlerRef TextBodyPropertiesContext::onCreateContext( sal_Int32 aElement
                 mrTextBodyProp.maPropertyMap[ PROP_TextAutoGrowHeight ] <<= false;
                 break;
             case A_TOKEN( spAutoFit ):
-                mrTextBodyProp.maPropertyMap[ PROP_TextAutoGrowHeight ] <<= true;
+                {
+                    const sal_Int32 tVert = mrTextBodyProp.moVert.get( XML_horz );
+                    if( tVert != XML_vert && tVert != XML_eaVert && tVert != XML_vert270 && tVert != XML_mongolianVert )
+                        mrTextBodyProp.maPropertyMap[ PROP_TextAutoGrowHeight ] <<= true;
+                }
                 break;
 
             case A_TOKEN( scene3d ):        // CT_Scene3D


More information about the Libreoffice-commits mailing list