[Libreoffice-commits] .: oox/source
Muthu Subramanian
sumuthu at kemper.freedesktop.org
Tue Sep 13 01:26:23 PDT 2011
oox/source/drawingml/customshapegeometry.cxx | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
New commits:
commit e8acb5c43c99081b68ac3df7336f0985b2554a8e
Author: Muthu Subramanian <sumuthu at suse.com>
Date: Tue Sep 13 14:14:31 2011 +0530
n#657909: Fixed import of free drawn curves.
diff --git a/oox/source/drawingml/customshapegeometry.cxx b/oox/source/drawingml/customshapegeometry.cxx
index 9d58367..9c22186 100644
--- a/oox/source/drawingml/customshapegeometry.cxx
+++ b/oox/source/drawingml/customshapegeometry.cxx
@@ -231,7 +231,7 @@ rtl::OUString GetFormulaParameter( const EnhancedCustomShapeParameter& rParamete
// ---------------------------------------------------------------------
-static EnhancedCustomShapeParameter GetAdjCoordinate( CustomShapeProperties& rCustomShapeProperties, const::rtl::OUString& rValue, sal_Bool bNoSymbols )
+static EnhancedCustomShapeParameter GetAdjCoordinate( CustomShapeProperties& rCustomShapeProperties, const::rtl::OUString& rValue, sal_Bool bNoSymbols, bool bAbs = false )
{
com::sun::star::drawing::EnhancedCustomShapeParameter aRet;
if ( rValue.getLength() )
@@ -401,7 +401,7 @@ static EnhancedCustomShapeParameter GetAdjCoordinate( CustomShapeProperties& rCu
}
if ( ( n >= '0' ) && ( n <= '9' ) )
{ // seems to be a ST_Coordinate
- aRet.Value = Any( (sal_Int32)(rValue.toInt32() / 5) );
+ aRet.Value = Any( (sal_Int32)(rValue.toInt32() / ( bAbs ? 1 : 5 ) ) );
aRet.Type = EnhancedCustomShapeParameterType::NORMAL;
}
else
@@ -657,8 +657,8 @@ public:
AdjPoint2DContext::AdjPoint2DContext( ContextHandler& rParent, const Reference< XFastAttributeList >& xAttribs, CustomShapeProperties& rCustomShapeProperties, EnhancedCustomShapeParameterPair& rAdjPoint2D )
: ContextHandler( rParent )
{
- rAdjPoint2D.First = GetAdjCoordinate( rCustomShapeProperties, xAttribs->getOptionalValue( XML_x ), sal_True );
- rAdjPoint2D.Second = GetAdjCoordinate( rCustomShapeProperties, xAttribs->getOptionalValue( XML_y ), sal_True );
+ rAdjPoint2D.First = GetAdjCoordinate( rCustomShapeProperties, xAttribs->getOptionalValue( XML_x ), sal_True, true );
+ rAdjPoint2D.Second = GetAdjCoordinate( rCustomShapeProperties, xAttribs->getOptionalValue( XML_y ), sal_True, true );
}
// ---------------------------------------------------------------------
More information about the Libreoffice-commits
mailing list