SectorMark
public class SectorMark : ChartMark, IChartMarkEncodes an angular value as a pie or donut sector, with configurable radii, padding, corner treatment, and category grouping.
Constructors
Section titled “Constructors”
SectorMark()
Section titled “SectorMark()”public SectorMark()
SectorMark(float)
Section titled “SectorMark(float)”public SectorMark(float value)Creates a SectorMark with the given Value (angle proportion). Swift Charts equivalent: SectorMark(angle: .Value(“Value”, value))
Parameters
| Name | Type |
|---|---|
value |
System.Single |
SectorMark(float, float, float)
Section titled “SectorMark(float, float, float)”public SectorMark(float value, float innerRadius = 0, float angularInset = 0.01)Creates a SectorMark with the given value and optional inner radius (for donut charts). Swift Charts equivalent: SectorMark(angle: .Value(…), innerRadius: .ratio(0.5))
Parameters
| Name | Type | Description |
|---|---|---|
value |
System.Single | The angle Value (proportion) |
innerRadius |
System.Single | Inner radius ratio (0 = pie, >0 = donut) |
angularInset |
System.Single | Gap between slices in radians |
SectorMark(PlottableValueRef, PlottableValueRef)
Section titled “SectorMark(PlottableValueRef, PlottableValueRef)”public SectorMark(PlottableValueRef angle, PlottableValueRef category = null)Creates a sector whose angular weight comes from a semantic value and whose optional category controls grouping and labels.
Parameters
| Name | Type |
|---|---|
angle |
ChartGuru.PlottableValueRef |
category |
ChartGuru.PlottableValueRef |
SectorMark(PlottableValueRef, float, float, PlottableValueRef)
Section titled “SectorMark(PlottableValueRef, float, float, PlottableValueRef)”public SectorMark(PlottableValueRef angle, float innerRadius, float angularInset = 0.01, PlottableValueRef category = null)Creates a pie or donut sector from a semantic angular value, clamped inner-radius ratio, non-negative gap, and optional category.
Parameters
| Name | Type |
|---|---|
angle |
ChartGuru.PlottableValueRef |
innerRadius |
System.Single |
angularInset |
System.Single |
category |
ChartGuru.PlottableValueRef |
SectorMark(DataPoint)
Section titled “SectorMark(DataPoint)”public SectorMark(DataPoint point)Creates a sector from an existing point, using its Y value as angular weight and preserving grouping metadata.
Parameters
| Name | Type |
|---|---|
point |
ChartGuru.DataPoint |
SectorMark(float, float)
Section titled “SectorMark(float, float)”public SectorMark(float startAngle, float endAngle)Creates a SectorMark with explicit start and end angles. Used by vectorized SectorPlot to specify angular bounds directly.
Parameters
| Name | Type | Description |
|---|---|---|
startAngle |
System.Single | Start angle in degrees |
endAngle |
System.Single | End angle in degrees |
Methods
Section titled “Methods”
CornerRadius(float)
Section titled “CornerRadius(float)”public SectorMark CornerRadius(float radius)Sets the corner radius for this sector. Swift Charts equivalent: .CornerRadius(value) Note: In Swift Charts, this is typically a constructor parameter.
Parameters
| Name | Type |
|---|---|
radius |
System.Single |
Returns
ChartGuru.SectorMark
InnerRadius(float)
Section titled “InnerRadius(float)”public SectorMark InnerRadius(float ratio)Sets the inner radius ratio for this sector. Swift Charts equivalent: SectorMark(… innerRadius: .ratio(value))
Parameters
| Name | Type | Description |
|---|---|---|
ratio |
System.Single | Inner radius as a ratio (0.0 = pie, 0.5+ = donut) |
Returns
ChartGuru.SectorMark
OuterRadius(float)
Section titled “OuterRadius(float)”public SectorMark OuterRadius(float ratio)Sets the outer radius ratio for this sector. Swift Charts equivalent: SectorMark(… outerRadius: .ratio(value))
Parameters
| Name | Type | Description |
|---|---|---|
ratio |
System.Single | Outer radius as a ratio (0.0 to 1.0) |
Returns
ChartGuru.SectorMark
AngularInset(float)
Section titled “AngularInset(float)”public SectorMark AngularInset(float inset)Sets the angular inset (gap between slices) for this sector. Swift Charts equivalent: SectorMark(… angularInset: value)
Parameters
| Name | Type | Description |
|---|---|---|
inset |
System.Single | Angular inset in degrees |
Returns
ChartGuru.SectorMark
GetMorphTargets(ChartType, Rect)
Section titled “GetMorphTargets(ChartType, Rect)”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}
Clone()
Section titled “Clone()”public override IChartMark Clone()Creates an independent copy of this Sector Mark; later configuration changes do not affect the original instance.
Returns
ChartGuru.IChartMark
Properties
Section titled “Properties”
MarkType
Section titled “MarkType”public override ChartType MarkType { get; }Returns
ChartGuru.ChartType
InnerRadiusRatio
Section titled “InnerRadiusRatio”public float InnerRadiusRatio { get; set; }Returns
System.Single
OuterRadiusRatio
Section titled “OuterRadiusRatio”public float OuterRadiusRatio { get; set; }Returns
System.Single
StartAngle
Section titled “StartAngle”public float StartAngle { get; set; }Returns
System.Single
EndAngle
Section titled “EndAngle”public float EndAngle { get; set; }Returns
System.Single
PadAngle
Section titled “PadAngle”public float PadAngle { get; set; }Returns
System.Single
CornerRadiusValue
Section titled “CornerRadiusValue”public float CornerRadiusValue { get; set; }Returns
System.Single
StrokeColor
Section titled “StrokeColor”public Color StrokeColor { get; set; }Returns
UnityEngine.Color
StrokeWidth
Section titled “StrokeWidth”public float StrokeWidth { get; set; }Returns
System.Single
ExplodeOffset
Section titled “ExplodeOffset”public float ExplodeOffset { get; set; }Returns
System.Single
AngleSpan
Section titled “AngleSpan”public float AngleSpan { get; }Returns
System.Single
MidAngle
Section titled “MidAngle”public float MidAngle { get; }Returns
System.Single