From 47c5e3b8160b72eb4fcd44aa7d44c10027ff41d0 Mon Sep 17 00:00:00 2001 From: AnhNgoo <110978888+AnhNgoo@users.noreply.github.com> Date: Thu, 29 Oct 2026 13:54:59 +0700 Subject: [PATCH] docs(chart): document Cartesian chart rendering --- crates/chart/src/render/cartesian.rs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/crates/chart/src/render/cartesian.rs b/crates/chart/src/render/cartesian.rs index 28f8bf791..6e6f70286 100644 --- a/crates/chart/src/render/cartesian.rs +++ b/crates/chart/src/render/cartesian.rs @@ -179,6 +179,12 @@ fn column_slots(fams: &[Fam], sec: &[bool]) -> (Vec, f32) { (slot_of, slot_keys.len().max(1) as f32) } +/// Renders Cartesian column, bar, line, area, and combination charts. +/// +/// Resolves series families and their axes, calculates stacking and +/// category positions, and draws the corresponding primitives. +/// Explicit chart style 9 adds white outlines to column and bar +/// rectangles, including stacked and 100%-stacked variants. pub(super) fn cartesian(ctx: &mut Ctx, chart: &Chart, data: &ChartData, area: Bx, horizontal: bool) { let ncat = data.categories.len().max(data.series.iter().map(|s| s.values.len()).max().unwrap_or(0)).min(MAX_CATS); if ncat == 0 {