Kaydet (Commit) 3f135598 authored tarafından Markus Mohrhard's avatar Markus Mohrhard

add import of axis color for data bars from xlsx

Change-Id: I2a15f8787afceaea1cb8e1c2902c05367d3e5b15
üst 064bfb1a
...@@ -713,6 +713,7 @@ axId ...@@ -713,6 +713,7 @@ axId
axPos axPos
axis axis
axisCol axisCol
axisColor
axisPage axisPage
axisPosition axisPosition
axisRow axisRow
......
...@@ -43,6 +43,7 @@ public: ...@@ -43,6 +43,7 @@ public:
private: private:
void importDataBar( const AttributeList& rAttribs ); void importDataBar( const AttributeList& rAttribs );
void importNegativeFillColor( const AttributeList& rAttribs ); void importNegativeFillColor( const AttributeList& rAttribs );
void importAxisColor( const AttributeList& rAttribs );
void* mpTarget; void* mpTarget;
}; };
......
...@@ -58,6 +58,10 @@ void ExtCfRuleContext::onStartElement( const AttributeList& rAttribs ) ...@@ -58,6 +58,10 @@ void ExtCfRuleContext::onStartElement( const AttributeList& rAttribs )
break; break;
case XLS_EXT_TOKEN( negativeFillColor ): case XLS_EXT_TOKEN( negativeFillColor ):
importNegativeFillColor( rAttribs ); importNegativeFillColor( rAttribs );
break;
case XLS_EXT_TOKEN( axisColor ):
importAxisColor( rAttribs );
break;
default: default:
break; break;
...@@ -93,6 +97,15 @@ namespace { ...@@ -93,6 +97,15 @@ namespace {
} }
void ExtCfRuleContext::importAxisColor( const AttributeList& rAttribs )
{
ScDataBarFormatData* pDataBar = static_cast<ScDataBarFormatData*>(mpTarget);
sal_Int32 nColor = rAttribs.getIntegerHex( XML_rgb, API_RGB_TRANSPARENT );
::Color aColor = RgbToRgbComponents(nColor);
pDataBar->maAxisColor = aColor;
}
void ExtCfRuleContext::importNegativeFillColor( const AttributeList& rAttribs ) void ExtCfRuleContext::importNegativeFillColor( const AttributeList& rAttribs )
{ {
sal_Int32 nColor = rAttribs.getIntegerHex( XML_rgb, API_RGB_TRANSPARENT ); sal_Int32 nColor = rAttribs.getIntegerHex( XML_rgb, API_RGB_TRANSPARENT );
......
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