Fixed value working out issue

This commit is contained in:
Curtis Hard
2017-01-17 09:22:19 +00:00
parent 0cc22cad44
commit a3bde2f710
+6 -1
View File
@@ -58,7 +58,7 @@
- (CGFloat)computeValue:(CGFloat)anotherValue
{
if(self.type == IJSVGUnitLengthTypePercentage) {
return ((anotherValue/100)*self.value);
return ((anotherValue/100.f)*(self.value*100.f));
}
return self.value;
}
@@ -76,4 +76,9 @@
return [NSString stringWithFormat:@"%g",self.value];
}
- (NSString *)description
{
return [NSString stringWithFormat:@"%f%@",self.value,(self.type == IJSVGUnitLengthTypePercentage ? @"%" : @"")];
}
@end