Skip to content

SectorPlot<T>

ClassChartGuruChartGuru
public class SectorPlot<T> : ChartMark, IChartMark

Vectorized sector plot for rendering pie/donut sectors from collection data. Swift Charts equivalent: SectorPlot(data, angle:, innerRadius:, outerRadius:)

public SectorPlot(IEnumerable<T> data, Func<T, float> angle)

Creates a SectorPlot from collection data with angle selector. Swift Charts equivalent: SectorPlot(data, angle: .value)

Parameters

Name Type
data System.Collections.Generic.IEnumerable{{T}}
angle System.Func{{T},System.Single}

public IEnumerable<SectorMark> GetMarks()

Generates individual SectorMarks from the data.

Returns

System.Collections.Generic.IEnumerable{ChartGuru.SectorMark}

public SectorPlot<T> InnerRadius(float value)

Sets the sector inner-radius ratio, where zero produces a pie slice and positive values produce a ring.

Parameters

Name Type
value System.Single

Returns

ChartGuru.SectorPlot`1

public SectorPlot<T> InnerRadius(Func<T, float> selector)

Sets the sector inner-radius ratio, where zero produces a pie slice and positive values produce a ring.

Parameters

Name Type
selector System.Func{{T},System.Single}

Returns

ChartGuru.SectorPlot`1

public SectorPlot<T> OuterRadius(float value)

Sets the sector outer-radius ratio relative to the available plot radius.

Parameters

Name Type
value System.Single

Returns

ChartGuru.SectorPlot`1

public SectorPlot<T> OuterRadius(Func<T, float> selector)

Sets the sector outer-radius ratio relative to the available plot radius.

Parameters

Name Type
selector System.Func{{T},System.Single}

Returns

ChartGuru.SectorPlot`1

public SectorPlot<T> AngularInset(float value)

Sets the angular gap between adjacent sectors in degrees.

Parameters

Name Type
value System.Single

Returns

ChartGuru.SectorPlot`1

public SectorPlot<T> AngularInset(Func<T, float> selector)

Sets the angular gap between adjacent sectors in degrees.

Parameters

Name Type
selector System.Func{{T},System.Single}

Returns

ChartGuru.SectorPlot`1

public SectorPlot<T> CornerRadius(float radius)

Sets corner rounding for supported bar, rectangle, or sector geometry.

Parameters

Name Type
radius System.Single

Returns

ChartGuru.SectorPlot`1

public SectorPlot<T> ForegroundStyle(Color color)

Configures the fill or stroke color used by generated marks; selector overloads resolve the style separately for each datum.

Parameters

Name Type
color UnityEngine.Color

Returns

ChartGuru.SectorPlot`1

public SectorPlot<T> ForegroundStyle(Func<T, object> seriesSelector)

Configures the fill or stroke color used by generated marks; selector overloads resolve the style separately for each datum.

Parameters

Name Type
seriesSelector System.Func{{T},System.Object}

Returns

ChartGuru.SectorPlot`1

public SectorPlot<T> ForegroundStyle(Func<T, Color> colorSelector)

Configures the fill or stroke color used by generated marks; selector overloads resolve the style separately for each datum.

Parameters

Name Type
colorSelector System.Func{{T},UnityEngine.Color}

Returns

ChartGuru.SectorPlot`1

public SectorPlot<T> AccessibilityLabel(Func<T, string> selector)

Provides the spoken label for each generated mark when assistive chart navigation is used.

Parameters

Name Type
selector System.Func{{T},System.String}

Returns

ChartGuru.SectorPlot`1

public SectorPlot<T> AccessibilityValue(Func<T, string> selector)

Provides the spoken value for each generated mark when assistive chart navigation is used.

Parameters

Name Type
selector System.Func{{T},System.String}

Returns

ChartGuru.SectorPlot`1

public SectorPlot<T> Opacity(float value)

Configures the alpha multiplier for generated marks; selector overloads evaluate it separately for each datum.

Parameters

Name Type
value System.Single

Returns

ChartGuru.SectorPlot`1

public SectorPlot<T> Opacity(Func<T, float> selector)

Configures the alpha multiplier for generated marks; selector overloads evaluate it separately for each datum.

Parameters

Name Type
selector System.Func{{T},System.Single}

Returns

ChartGuru.SectorPlot`1

public override (Vector2 source, Vector2 target) GetMorphTargets(ChartType targetType, Rect plotArea)

Projects this mark into plot-space geometry that the morph renderer can interpolate toward the requested chart type.

Parameters

Name Type
targetType ChartGuru.ChartType
plotArea UnityEngine.Rect

Returns

System.ValueTuple{UnityEngine.Vector2,UnityEngine.Vector2}

public override IChartMark Clone()

Creates an independent copy of this Sector Plot; later configuration changes do not affect the original instance.

Returns

ChartGuru.IChartMark

public override ChartType MarkType { get; }

Returns

ChartGuru.ChartType

public IEnumerable<T> Data { get; }

Returns

System.Collections.Generic.IEnumerable{{T}}