Hide Comments
Hide Comments

Comments (0)

The Values property contains all the donut slices in the donut chart. Each donut slice (TRSDonutChartExValue) may have its own Color and Caption. The size of the donut slice is specified by the StartAngle and SweepAngle properties. The width of the slice is controlled by the InnerRadius and OuterRadius properties.

Use the Values collection to add, delete, and modify donut slices in the chart.
 
 
 

Namespace: RSDonutCharts

expandingSyntax

Delphi

published
  property Values: TRSDonutChartExValues read GetValues write SetValues stored IsValuesStored;
 

Property Value

Type: TRSDonutChartExValues

expandingExamples

The following code adds 3 donut slices to the chart:

Delphi

var
   Value: TRSDonutChartExValue;  // note, this type should be the same that the chart uses (e.g., TRS2DChartValue, TRSArrowChartValue, etc)
 begin
   // Add first point as a full circle outer ring
   Value := RSDonutChart1.Values.Add;
   Value.Color := clRed;
   Value.StartAngle := 0.0;
   Value.SweepAngle := 360;
   // Add second point, inside the first
   Value := RSDonutChart1.Values.Add;
   Value.Color := clGreen;
   Value.StartAngle := 10.0; // 10-40 degrees
   Value.SweepAngle := 30;
   Value.InnerRadius := 0.50
   Value.OuterRadius := 0.75
   // Add third point, twice as large as second
   Value := RSDonutChart1.Values.Add;
   Value.Color := clNavy;
   Value.StartAngle := 90.0; // 90-270
   Value.SweepAngle := 180;
   Value.InnerRadius := 0.50
   Value.OuterRadius := 0.75
 
   // Draw the donut slices starting at 12:00 and go counter-clockwise
   RSDonutChart1.Offset := 90;
 end;
 

expandingSee Also

Comments (0)

RiverSoftAVG Charting Component Suite (RCCS) © 2005-2015, Thomas G. Grubb