ChartDrawable
MAUI drawable that renders a candlestick chart.
Implements: IDrawable
Properties
public List<ChartAxis> AdditionalYAxes { get; }
value = chartDrawable.AdditionalYAxes
Gets the additional Y axes.
public List<IAnnotation> Annotations { get; }
value = chartDrawable.Annotations
Gets the annotations collection.
public List<ChartArea> Areas { get; }
value = chartDrawable.Areas
Gets the chart areas collection for multi-area rendering.
public ChartColor BackgroundColor { get; set; }
value = chartDrawable.BackgroundColor
chartDrawable.BackgroundColor = value
Background color.
public List<BoxVolumeProfile> BoxVolumeProfiles { get; }
value = chartDrawable.BoxVolumeProfiles
Gets or sets the box volume profiles.
public CandleDataSeries Candles { get; set; }
value = chartDrawable.Candles
chartDrawable.Candles = value
The candle data to display.
public List<ClusterProfile> ClusterProfiles { get; }
value = chartDrawable.ClusterProfiles
Gets or sets the cluster profiles.
public ChartPoint? CrosshairPosition { get; set; }
value = chartDrawable.CrosshairPosition
chartDrawable.CrosshairPosition = value
Crosshair position (null if not shown).
public ChartDrawStyle DrawStyle { get; set; }
value = chartDrawable.DrawStyle
chartDrawable.DrawStyle = value
The chart draw style.
public List<ValueTuple<IReadOnlyList<decimal?>, ChartColor, string>> Indicators { get; }
value = chartDrawable.Indicators
Indicator data series (nullable values).
public ChartLegend Legend { get; }
value = chartDrawable.Legend
Gets the legend configuration.
public ModifierGroup Modifiers { get; set; }
value = chartDrawable.Modifiers
chartDrawable.Modifiers = value
Gets or sets the modifier group for drawing modifier visuals.
public List<OscillatorPane> OscillatorPanes { get; }
value = chartDrawable.OscillatorPanes
Oscillator sub-panes (RSI, MACD, …) stacked below the price chart, each with its own vertical scale. Empty by default — when empty the chart renders exactly as before, using the full height for the price (and optional volume) area.
public double Padding { get; set; }
value = chartDrawable.Padding
chartDrawable.Padding = value
Padding around the chart area.
public PnFChartData PnFData { get; set; }
value = chartDrawable.PnFData
chartDrawable.PnFData = value
Gets or sets the Point and Figure data.
public bool ShowCrosshair { get; set; }
value = chartDrawable.ShowCrosshair
chartDrawable.ShowCrosshair = value
Whether to show the crosshair.
public bool ShowLegend { get; set; }
value = chartDrawable.ShowLegend
chartDrawable.ShowLegend = value
Whether to show the legend.
public bool ShowVolume { get; set; }
value = chartDrawable.ShowVolume
chartDrawable.ShowVolume = value
Whether to show the volume subplot.
public int StartIndex { get; set; }
value = chartDrawable.StartIndex
chartDrawable.StartIndex = value
The starting index of visible candles.
public ChartTheme Theme { get; set; }
value = chartDrawable.Theme
chartDrawable.Theme = value
Gets or sets the chart theme.
public int VisibleCandleCount { get; set; }
value = chartDrawable.VisibleCandleCount
chartDrawable.VisibleCandleCount = value
The number of candles visible in the viewport.
public double VolumeHeightRatio { get; set; }
value = chartDrawable.VolumeHeightRatio
chartDrawable.VolumeHeightRatio = value
Height ratio of volume subplot (0.0 - 1.0).
public double XAxisHeight { get; set; }
value = chartDrawable.XAxisHeight
chartDrawable.XAxisHeight = value
Height of the X axis area in pixels.
public double YAxisWidth { get; set; }
value = chartDrawable.YAxisWidth
chartDrawable.YAxisWidth = value
Width of the Y axis area in pixels.
Methods
public ValueTuple<double, decimal> ScreenToData(ChartPoint screenPoint)
result = chartDrawable.ScreenToData(screenPoint)
Converts a screen pixel point (in chart-local coordinates) to data coordinates: a fractional candle index and a price. Returns (NaN, 0) when the point is outside the price area or no frame has been drawn yet. Uses the actual candle area, so the mapping stays correct when oscillator sub-panes shrink it.