• Pure: the device-pixel rectangle geometry of one candle. This is the single source of the snapping and parity rules, so a second backend rasterising candles with its own primitives lands on the same pixels as drawCandles.

    widthScale is the per-bar body scale a volume candle applies (1 = the full optimalBarWidth). It is clamped to 0.05..1: a zero-volume bar still has to show a sliver of body, and nothing may grow past the gap.

    Parameters

    • x: number
    • barSpacing: number
    • dpr: number
    • widthScale: number = 1

    Returns CandleGeometry