Kaydet (Commit) 9c7dbd9e authored tarafından Miklos Vajna's avatar Miklos Vajna

fdo#60722 RTF import: fix line color default

Change-Id: Ic100837dd69498e97d940e5dfb4053c02fc7daa0
üst e4f492ac
......@@ -100,6 +100,8 @@ void RTFSdrImport::resolve(RTFShape& rShape)
beans::PropertyValue aPropertyValue;
awt::Rectangle aViewBox;
std::vector<beans::PropertyValue> aPathPropVec;
// Default line color is black in Word, blue in Writer.
uno::Any aLineColor = uno::makeAny(COL_BLACK);
for (std::vector< std::pair<rtl::OUString, rtl::OUString> >::iterator i = rShape.aProperties.begin();
i != rShape.aProperties.end(); ++i)
......@@ -138,11 +140,8 @@ void RTFSdrImport::resolve(RTFShape& rShape)
}
else if ( i->first == "fillBackColor" )
; // Ignore: complementer of fillColor
else if (i->first == "lineColor" && xPropertySet.is())
{
aAny <<= msfilter::util::BGRToRGB(i->second.toInt32());
xPropertySet->setPropertyValue("LineColor", aAny);
}
else if (i->first == "lineColor")
aLineColor <<= msfilter::util::BGRToRGB(i->second.toInt32());
else if ( i->first == "lineBackColor" )
; // Ignore: complementer of lineColor
else if (i->first == "txflTextFlow" && xPropertySet.is())
......@@ -297,6 +296,9 @@ void RTFSdrImport::resolve(RTFShape& rShape)
OUStringToOString( i->second, RTL_TEXTENCODING_UTF8 ).getStr() << "'");
}
if (xPropertySet.is())
xPropertySet->setPropertyValue("LineColor", aLineColor);
if (nType == ESCHER_ShpInst_PictureFrame) // picture frame
{
if (bPib)
......
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