support axis text properties during OOXML export, tdf#90532
Change-Id: Ied2b21154e31754f8b8461c349fe0e52ce7455e8
This commit is contained in:
@@ -154,6 +154,7 @@ private:
|
|||||||
void exportSeriesValues(
|
void exportSeriesValues(
|
||||||
const css::uno::Reference< css::chart2::data::XDataSequence >& xValueSeq, sal_Int32 nValueType = XML_val );
|
const css::uno::Reference< css::chart2::data::XDataSequence >& xValueSeq, sal_Int32 nValueType = XML_val );
|
||||||
void exportShapeProps( css::uno::Reference< css::beans::XPropertySet > xPropSet );
|
void exportShapeProps( css::uno::Reference< css::beans::XPropertySet > xPropSet );
|
||||||
|
void exportTextProps(css::uno::Reference< css::beans::XPropertySet > xPropSet);
|
||||||
void exportDataPoints(
|
void exportDataPoints(
|
||||||
const css::uno::Reference< css::beans::XPropertySet >& xSeriesProperties,
|
const css::uno::Reference< css::beans::XPropertySet >& xSeriesProperties,
|
||||||
sal_Int32 nSeriesLength );
|
sal_Int32 nSeriesLength );
|
||||||
|
@@ -29,6 +29,7 @@
|
|||||||
#include <tools/poly.hxx>
|
#include <tools/poly.hxx>
|
||||||
#include <filter/msfilter/escherex.hxx>
|
#include <filter/msfilter/escherex.hxx>
|
||||||
#include "oox/drawingml/drawingmltypes.hxx"
|
#include "oox/drawingml/drawingmltypes.hxx"
|
||||||
|
#include <oox/token/tokens.hxx>
|
||||||
#ifndef OOX_DRAWINGML_EXPORT_ROTATE_CLOCKWISIFY
|
#ifndef OOX_DRAWINGML_EXPORT_ROTATE_CLOCKWISIFY
|
||||||
// Our rotation is counter-clockwise and is in 100ths of a degree.
|
// Our rotation is counter-clockwise and is in 100ths of a degree.
|
||||||
// drawingML rotation is clockwise and is in 60000ths of a degree.
|
// drawingML rotation is clockwise and is in 60000ths of a degree.
|
||||||
@@ -172,7 +173,7 @@ public:
|
|||||||
void WriteParagraphNumbering( ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > rXPropSet,
|
void WriteParagraphNumbering( ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > rXPropSet,
|
||||||
sal_Int16 nLevel );
|
sal_Int16 nLevel );
|
||||||
void WriteRun( ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextRange > rRun );
|
void WriteRun( ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextRange > rRun );
|
||||||
void WriteRunProperties( ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > rRun, bool bIsField );
|
void WriteRunProperties( ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > rRun, bool bIsField, sal_Int32 nElement = XML_rPr );
|
||||||
|
|
||||||
void WritePresetShape( const char* pShape );
|
void WritePresetShape( const char* pShape );
|
||||||
void WritePresetShape( const char* pShape, MSO_SPT eShapeType, bool bPredefinedHandlesUsed, sal_Int32 nAdjustmentsWhichNeedsToBeConverted, const ::com::sun::star::beans::PropertyValue& rProp );
|
void WritePresetShape( const char* pShape, MSO_SPT eShapeType, bool bPredefinedHandlesUsed, sal_Int32 nAdjustmentsWhichNeedsToBeConverted, const ::com::sun::star::beans::PropertyValue& rProp );
|
||||||
|
@@ -2306,6 +2306,25 @@ void ChartExport::exportShapeProps( Reference< XPropertySet > xPropSet )
|
|||||||
pFS->endElement( FSNS( XML_c, XML_spPr ) );
|
pFS->endElement( FSNS( XML_c, XML_spPr ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void ChartExport::exportTextProps(Reference<XPropertySet> xPropSet)
|
||||||
|
{
|
||||||
|
FSHelperPtr pFS = GetFS();
|
||||||
|
pFS->startElement(FSNS(XML_c, XML_txPr), FSEND);
|
||||||
|
|
||||||
|
pFS->startElement(FSNS(XML_c, XML_bodyPr), FSEND);
|
||||||
|
pFS->endElement(FSNS(XML_c, XML_bodyPr));
|
||||||
|
|
||||||
|
pFS->startElement(FSNS(XML_a, XML_p), FSEND);
|
||||||
|
pFS->startElement(FSNS(XML_a, XML_pPr), FSEND);
|
||||||
|
|
||||||
|
WriteRunProperties(xPropSet, false, XML_defRPr);
|
||||||
|
|
||||||
|
pFS->endElement(FSNS(XML_a, XML_pPr));
|
||||||
|
pFS->endElement(FSNS(XML_a, XML_p));
|
||||||
|
|
||||||
|
pFS->endElement(FSNS(XML_c, XML_txPr));
|
||||||
|
}
|
||||||
|
|
||||||
void ChartExport::InitPlotArea( )
|
void ChartExport::InitPlotArea( )
|
||||||
{
|
{
|
||||||
Reference< XPropertySet > xDiagramProperties (mxDiagram, uno::UNO_QUERY);
|
Reference< XPropertySet > xDiagramProperties (mxDiagram, uno::UNO_QUERY);
|
||||||
@@ -2680,6 +2699,8 @@ void ChartExport::_exportAxis(
|
|||||||
// shape properties
|
// shape properties
|
||||||
exportShapeProps( xAxisProp );
|
exportShapeProps( xAxisProp );
|
||||||
|
|
||||||
|
exportTextProps(xAxisProp);
|
||||||
|
|
||||||
pFS->singleElement( FSNS( XML_c, XML_crossAx ),
|
pFS->singleElement( FSNS( XML_c, XML_crossAx ),
|
||||||
XML_val, I32S( rAxisIdPair.nCrossAx ),
|
XML_val, I32S( rAxisIdPair.nCrossAx ),
|
||||||
FSEND );
|
FSEND );
|
||||||
|
@@ -1167,7 +1167,7 @@ void DrawingML::WriteShapeTransformation( Reference< XShape > rXShape, sal_Int32
|
|||||||
WriteTransformation( Rectangle( Point( aPos.X, aPos.Y ), Size( aSize.Width, aSize.Height ) ), nXmlNamespace, bFlipH, bFlipV, OOX_DRAWINGML_EXPORT_ROTATE_CLOCKWISIFY(nRotation) );
|
WriteTransformation( Rectangle( Point( aPos.X, aPos.Y ), Size( aSize.Width, aSize.Height ) ), nXmlNamespace, bFlipH, bFlipV, OOX_DRAWINGML_EXPORT_ROTATE_CLOCKWISIFY(nRotation) );
|
||||||
}
|
}
|
||||||
|
|
||||||
void DrawingML::WriteRunProperties( Reference< XPropertySet > rRun, bool bIsField )
|
void DrawingML::WriteRunProperties( Reference< XPropertySet > rRun, bool bIsField, sal_Int32 nElement /*= XML_rPr*/ )
|
||||||
{
|
{
|
||||||
Reference< XPropertySet > rXPropSet( rRun, UNO_QUERY );
|
Reference< XPropertySet > rXPropSet( rRun, UNO_QUERY );
|
||||||
Reference< XPropertyState > rXPropState( rRun, UNO_QUERY );
|
Reference< XPropertyState > rXPropState( rRun, UNO_QUERY );
|
||||||
@@ -1318,7 +1318,7 @@ void DrawingML::WriteRunProperties( Reference< XPropertySet > rRun, bool bIsFiel
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
mpFS->startElementNS( XML_a, XML_rPr,
|
mpFS->startElementNS( XML_a, nElement,
|
||||||
XML_b, bold,
|
XML_b, bold,
|
||||||
XML_i, italic,
|
XML_i, italic,
|
||||||
XML_lang, usLanguage.isEmpty() ? NULL : USS( usLanguage ),
|
XML_lang, usLanguage.isEmpty() ? NULL : USS( usLanguage ),
|
||||||
@@ -1405,7 +1405,7 @@ void DrawingML::WriteRunProperties( Reference< XPropertySet > rRun, bool bIsFiel
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
mpFS->endElementNS( XML_a, XML_rPr );
|
mpFS->endElementNS( XML_a, nElement );
|
||||||
}
|
}
|
||||||
|
|
||||||
const char* DrawingML::GetFieldType( ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextRange > rRun, bool& bIsField )
|
const char* DrawingML::GetFieldType( ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextRange > rRun, bool& bIsField )
|
||||||
|
Reference in New Issue
Block a user