Skip to content

RectangleMark

ClassChartGuruChartGuru
[Serializable]
public class RectangleMark : ChartMark, IChartMark

RectangleMark for heatmaps, range charts, and grid-based visualizations. Matches Swift Charts RectangleMark(xStart:xEnd:yStart:yEnd:) API.

public override ChartType MarkType { get; }

No description is available for this member.

Returns

ChartGuru.ChartType — No return description is available.

public bool NeedsCategoricalResolution { get; }

When true, this mark was created with categorical PlottableValue bounds and needs position resolution by ChartBuilder.

Returns

System.Boolean — No return description is available.

public bool IsCentered { get; }

True when authored with Swift Charts’ centered RectangleMark(x:y:width:height:) form instead of range bounds.

Returns

System.Boolean — No return description is available.

public float XStart { get; set; }

Left X coordinate of the rectangle.

Returns

System.Single — No return description is available.

public float XEnd { get; set; }

Right X coordinate of the rectangle.

Returns

System.Single — No return description is available.

public float YStart { get; set; }

Bottom Y coordinate of the rectangle.

Returns

System.Single — No return description is available.

public float YEnd { get; set; }

Top Y coordinate of the rectangle.

Returns

System.Single — No return description is available.

public float CornerRadiusValue { get; set; }

Corner radius for rounded rectangles.

Returns

System.Single — No return description is available.

public float CellPaddingPercent { get; set; }

Cell padding as a percentage (0–10) of cell screen size on each side. Applied by the renderer at draw time; does not modify the data-space coordinates. Matches the Designer’s _heatMapCellPadding semantics.

Returns

System.Single — No return description is available.

public Color StrokeColor { get; set; }

Stroke/border color.

Returns

UnityEngine.Color — No return description is available.

public float StrokeWidth { get; set; }

Stroke/border width.

Returns

System.Single — No return description is available.

public MarkDimension WidthDimension { get; set; }

Optional Swift Charts MarkDimension width override. This does not replace ChartGuru.RectangleMark.DataWidth, which remains the data-space rectangle extent.

Returns

ChartGuru.MarkDimension — No return description is available.

public MarkDimension HeightDimension { get; set; }

Optional Swift Charts MarkDimension height override. This does not replace ChartGuru.RectangleMark.DataHeight, which remains the data-space rectangle extent.

Returns

ChartGuru.MarkDimension — No return description is available.

public float DataWidth { get; }

Data-space width of the rectangle (XEnd - XStart).

Returns

System.Single — No return description is available.

public float DataHeight { get; }

Data-space height of the rectangle (YEnd - YStart).

Returns

System.Single — No return description is available.

public float CenterX { get; }

Center X coordinate.

Returns

System.Single — No return description is available.

public float CenterY { get; }

Center Y coordinate.

Returns

System.Single — No return description is available.

public RectangleMark()

No description is available for this member.

public RectangleMark(float x, float y)

Creates a RectangleMark centered at an XY point. Matches Swift Charts: RectangleMark(x:y:width:height:). Width/height are controlled through ChartGuru.RectangleMark.Width(ChartGuru.MarkDimension) and ChartGuru.RectangleMark.Height(ChartGuru.MarkDimension).

Parameters

Name Type Description
x System.Single
y System.Single

RectangleMark(PlottableValueRef, PlottableValueRef, int)

Section titled “RectangleMark(PlottableValueRef, PlottableValueRef, int)”
public RectangleMark(PlottableValueRef x, PlottableValueRef y, int index = 0)

Creates a centered RectangleMark from Swift-style plottable x/y bindings.

Parameters

Name Type Description
x ChartGuru.PlottableValueRef
y ChartGuru.PlottableValueRef
index System.Int32
public RectangleMark(float xStart, float xEnd, float yStart, float yEnd)

Creates a RectangleMark with explicit bounds. Matches Swift Charts: RectangleMark(xStart:xEnd:yStart:yEnd:)

Parameters

Name Type Description
xStart System.Single
xEnd System.Single
yStart System.Single
yEnd System.Single

RectangleMark(PlottableValueRef, PlottableValueRef, PlottableValueRef, PlottableValueRef)

Section titled “RectangleMark(PlottableValueRef, PlottableValueRef, PlottableValueRef, PlottableValueRef)”
public RectangleMark(PlottableValueRef xStart, PlottableValueRef xEnd, PlottableValueRef yStart, PlottableValueRef yEnd)

Creates a RectangleMark with categorical PlottableValue bounds. Matches Swift Charts: RectangleMark(xStart: .Value(…), xEnd: .Value(…), yStart: .Value(…), yEnd: .Value(…)) Positions are resolved automatically by ChartBuilder from unique category order.

Parameters

Name Type Description
xStart ChartGuru.PlottableValueRef
xEnd ChartGuru.PlottableValueRef
yStart ChartGuru.PlottableValueRef
yEnd ChartGuru.PlottableValueRef

public static RectangleMark FromRect(float x, float y, float width, float height)

Creates a RectangleMark from position and Size (convenience constructor).

Parameters

Name Type Description
x System.Single
y System.Single
width System.Single
height System.Single

Returns

ChartGuru.RectangleMark — No return description is available.

public static RectangleMark FromCenter(float centerX, float centerY, float width, float height)

Creates a RectangleMark centered at position with given size.

Parameters

Name Type Description
centerX System.Single
centerY System.Single
width System.Single
height System.Single

Returns

ChartGuru.RectangleMark — No return description is available.

public RectangleMark CornerRadius(float radius)

Sets the corner radius for this rectangle. Swift Charts equivalent: .ClipShape(.rect(cornerRadius:))

Parameters

Name Type Description
radius System.Single

Returns

ChartGuru.RectangleMark — No return description is available.

public RectangleMark CellPadding(float padding)

Sets the cell Padding (0–10 percent of cell size on each side) for this rectangle. Matches the designer’s Heat Map cell padding slider.

Parameters

Name Type Description
padding System.Single

Returns

ChartGuru.RectangleMark — No return description is available.

public RectangleMark Width(MarkDimension dimension)

Sets the rendered rectangle width with Swift Charts MarkDimension semantics. Equivalent to RectangleMark(…, width: .fixed/.ratio/.inset/.automatic).

Parameters

Name Type Description
dimension ChartGuru.MarkDimension

Returns

ChartGuru.RectangleMark — No return description is available.

public RectangleMark Height(MarkDimension dimension)

Sets the rendered rectangle height with Swift Charts MarkDimension semantics. Equivalent to RectangleMark(…, height: .fixed/.ratio/.inset/.automatic).

Parameters

Name Type Description
dimension ChartGuru.MarkDimension

Returns

ChartGuru.RectangleMark — No return description is available.

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

No description is available for this member.

Parameters

Name Type Description
targetType ChartGuru.ChartType
plotArea UnityEngine.Rect

Returns

System.ValueTuple{UnityEngine.Vector2,UnityEngine.Vector2} — No return description is available.

public override IChartMark Clone()

No description is available for this member.

Returns

ChartGuru.IChartMark — No return description is available.