Mendy Krinsky

Added decimal options for circle chart

@@ -13,7 +13,9 @@ @@ -13,7 +13,9 @@
13 typedef NS_ENUM (NSUInteger, PNChartFormatType) { 13 typedef NS_ENUM (NSUInteger, PNChartFormatType) {
14 PNChartFormatTypePercent, 14 PNChartFormatTypePercent,
15 PNChartFormatTypeDollar, 15 PNChartFormatTypeDollar,
16 - PNChartFormatTypeNone 16 + PNChartFormatTypeNone,
  17 + PNChartFormatTypeDecimal,
  18 + PNChartFormatTypeDecimalTwoPlaces,
17 }; 19 };
18 20
19 #define DEGREES_TO_RADIANS(angle) ((angle) / 180.0 * M_PI) 21 #define DEGREES_TO_RADIANS(angle) ((angle) / 180.0 * M_PI)
@@ -131,6 +131,12 @@ displayCountingLabel:(BOOL)displayCountingLabel @@ -131,6 +131,12 @@ displayCountingLabel:(BOOL)displayCountingLabel
131 case PNChartFormatTypeDollar: 131 case PNChartFormatTypeDollar:
132 format = @"$%d"; 132 format = @"$%d";
133 break; 133 break;
  134 + case PNChartFormatTypeDecimal:
  135 + format = @"%.1f";
  136 + break;
  137 + case PNChartFormatTypeDecimalTwoPlaces:
  138 + format = @"%.2f";
  139 + break;
134 case PNChartFormatTypeNone: 140 case PNChartFormatTypeNone:
135 default: 141 default:
136 format = @"%d"; 142 format = @"%d";