SCIDonutRenderableSeries

@interface SCIDonutRenderableSeries : SCIPieDonutRenderableSeriesBase

Provides Donut series rendering.

  • Method that draws segment.

    Declaration

    Objective-C

    - (void)drawSegment:(SCIPieSegment *)segment
                 offset:(double)offset
                arcSize:(double)arcSize
                 center:(CGPoint)center
            innerRadius:(double)innerRadius
            outerRadius:(double)outerRadius;

    Swift

    func draw(_ segment: SCIPieSegment!, offset: Double, arcSize: Double, center: CGPoint, innerRadius: Double, outerRadius: Double)

    Parameters

    segment

    SCIPieSegment to be drawn

    offset

    is starting angle in radians

    arcSize

    arc size of segment in radians

    center

    CGPoint center from which segment is drawn

    innerRadius

    distance in point to inner arc of segment

    outerRadius

    distance in point to outer arc of segment

  • Entry point for drawing label for segment

    Declaration

    Objective-C

    - (void)drawSegmentLabel:(SCIPieSegment *)segment
                      offset:(double)offset
                     arcSize:(double)arcSize
                      center:(CGPoint)center
                 innerRadius:(double)innerRadius
                 outerRadius:(double)outerRadius;

    Swift

    func drawSegmentLabel(_ segment: SCIPieSegment!, offset: Double, arcSize: Double, center: CGPoint, innerRadius: Double, outerRadius: Double)

    Parameters

    segment

    SCIPieSegment for which label is placed

    offset

    starting angle of segment in radians

    arcSize

    size of segment arc in radians

    center

    CGPoint center from which segment is drawn

    innerRadius

    distance in point to inner arc of segment

    outerRadius

    distance in point to outer arc of segment

  • Draw text on segment

    Declaration

    Objective-C

    - (void)placeLabelForSegment:(SCIPieSegment *)segment
                            text:(NSString *)text
                          centre:(CGPoint)centre
                     innerRadius:(double)innerRadius
                     outerRadius:(double)outerRadius
                      startAngle:(double)startAngle
                        endAngle:(double)endAngle
                 placementOption:(int)placementOption;

    Swift

    func placeLabel(for segment: SCIPieSegment!, text: String!, centre: CGPoint, innerRadius: Double, outerRadius: Double, startAngle: Double, endAngle: Double, placementOption: Int32)

    Parameters

    segment

    SCIPieSegment on which text is placed

    text

    string to be written

    centre

    CGPoint center of series

    innerRadius

    distance in point to inner arc of segment

    outerRadius

    distance in point to outer arc of segment

    startAngle

    angle in radians that define start of segment area

    endAngle

    angle in radians that define end of segment area

    placementOption

    not used currently

  • Returns path for segment stroke and fill drawing

    Declaration

    Objective-C

    - (CGMutablePathRef)getSegmentPath:(SCIPieSegment *)segment
                                centre:(CGPoint)centre
                           innerRadius:(double)innerRadius
                           outerRadius:(double)outerRadius
                            startAngle:(double)startAngle
                              endAngle:(double)endAngle
                        segmentSpacing:(double)segmentSpacing;

    Swift

    func getSegmentPath(_ segment: SCIPieSegment!, centre: CGPoint, innerRadius: Double, outerRadius: Double, startAngle: Double, endAngle: Double, segmentSpacing: Double) -> Unmanaged<CGMutablePath>!

    Parameters

    segment

    SCIPieSegment for which path is calculated

    centre

    CGPoint centre from which arcs are calculated

    innerRadius

    distance in point to inner arc of segment

    outerRadius

    distance in point to outer arc of segment

    startAngle

    angle in radians that defines start of segment area

    endAngle

    angle in radians that defines end of segment area

    segmentSpacing

    offset in points for segment from center and other segments

  • Returns path for segment outline drawing

    Declaration

    Objective-C

    - (CGMutablePathRef)getOutlinePath:(SCIPieSegment *)segment
                                centre:(CGPoint)centre
                           innerRadius:(double)innerRadius
                           outerRadius:(double)outerRadius
                            startAngle:(double)startAngle
                              endAngle:(double)endAngle
                        segmentSpacing:(double)segmentSpacing;

    Swift

    func getOutlinePath(_ segment: SCIPieSegment!, centre: CGPoint, innerRadius: Double, outerRadius: Double, startAngle: Double, endAngle: Double, segmentSpacing: Double) -> Unmanaged<CGMutablePath>!

    Parameters

    segment

    SCIPieSegment for which path is calculated

    centre

    CGPoint centre from which arcs are calculated

    innerRadius

    distance in point to inner arc of segment

    outerRadius

    distance in point to outer arc of segment

    startAngle

    angle in radians that defines start of segment area

    endAngle

    angle in radians that defines end of segment area

    segmentSpacing

    offset in points for segment from center and other segments