Kaydet (Commit) c6238797 authored tarafından Jürgen Schmidt's avatar Jürgen Schmidt Kaydeden (comit) Caolán McNamara

Resolves: #i119889# .pptx table vertical text direction

Set property to cell object if the cell has vertical property. And fix in svx
module by setting cell's vertical property.

Patch By: companycy
Found By: Shan Zu
Review By: jsc

(cherry picked from commit bb8bf7bd)

Conflicts:
	oox/source/drawingml/table/tablecell.cxx

Change-Id: I58bb1548617c4c1e231280a405d6071ea8813039
üst 16e6841f
...@@ -32,6 +32,7 @@ ...@@ -32,6 +32,7 @@
#include <com/sun/star/drawing/TextVerticalAdjust.hpp> #include <com/sun/star/drawing/TextVerticalAdjust.hpp>
#include <com/sun/star/drawing/TextHorizontalAdjust.hpp> #include <com/sun/star/drawing/TextHorizontalAdjust.hpp>
#include <com/sun/star/text/XText.hpp> #include <com/sun/star/text/XText.hpp>
#include <com/sun/star/text/WritingMode.hpp>
using namespace ::oox::core; using namespace ::oox::core;
using namespace ::com::sun::star; using namespace ::com::sun::star;
...@@ -351,6 +352,11 @@ void TableCell::pushToXCell( const ::oox::core::XmlFilterBase& rFilterBase, ::oo ...@@ -351,6 +352,11 @@ void TableCell::pushToXCell( const ::oox::core::XmlFilterBase& rFilterBase, ::oo
aFillProperties.pushToPropMap( aPropMap, rFilterBase.getGraphicHelper() ); aFillProperties.pushToPropMap( aPropMap, rFilterBase.getGraphicHelper() );
PropertySet( xPropSet ).setProperties( aPropMap ); PropertySet( xPropSet ).setProperties( aPropMap );
if ( getVertToken() == XML_eaVert )
{
xPropSet->setPropertyValue("TextWritingMode", Any(com::sun::star::text::WritingMode_TB_RL));
}
getTextBody()->insertAt( rFilterBase, xText, xAt, aTextStyleProps, pMasterTextListStyle ); getTextBody()->insertAt( rFilterBase, xText, xAt, aTextStyleProps, pMasterTextListStyle );
} }
......
...@@ -305,6 +305,16 @@ namespace sdr ...@@ -305,6 +305,16 @@ namespace sdr
sdr::table::SdrTableObj& rObj = (sdr::table::SdrTableObj&)GetSdrObject(); sdr::table::SdrTableObj& rObj = (sdr::table::SdrTableObj&)GetSdrObject();
if( rObj.IsVerticalWriting() != bVertical ) if( rObj.IsVerticalWriting() != bVertical )
rObj.SetVerticalWriting(bVertical); rObj.SetVerticalWriting(bVertical);
// Set a cell vertical property
OutlinerParaObject* pParaObj = mxCell->GetEditOutlinerParaObject();
if( pParaObj == 0 )
pParaObj = mxCell->GetOutlinerParaObject();
if(pParaObj)
{
pParaObj->SetVertical(bVertical);
}
} }
// call parent // call parent
......
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