From 2f82bf1949299a3c27423db36f4a1c679e5492ce Mon Sep 17 00:00:00 2001 From: Luboš Luňák Date: Thu, 7 Jun 2012 18:10:20 +0200 Subject: handle f suffix (1/65536ths) when reading VML percentages Not all percentage attributes actually use this, but better be safe and no point in checking only the allowed ones use them. Change-Id: I851f9b19ea85201d70d5e6b2e219bbcd88ae3dea --- oox/source/vml/vmlformatting.cxx | 3 +++ 1 file changed, 3 insertions(+) (limited to 'oox/source/vml') diff --git a/oox/source/vml/vmlformatting.cxx b/oox/source/vml/vmlformatting.cxx index 4bc582d777be..6d202767fb2b 100644 --- a/oox/source/vml/vmlformatting.cxx +++ b/oox/source/vml/vmlformatting.cxx @@ -107,6 +107,9 @@ bool lclExtractDouble( double& orfValue, sal_Int32& ornEndPos, const OUString& r if( (nEndPos + 1 == rValue.getLength()) && (rValue[ nEndPos ] == '%') ) return fValue / 100.0; + if( (nEndPos + 1 == rValue.getLength()) && (rValue[ nEndPos ] == 'f') ) + return fValue / 65536.0; + OSL_FAIL( "ConversionHelper::decodePercent - unknown measure unit" ); return fDefValue; } -- cgit