git.lucas.co / cce-calendar
calendar
git clone https://git.lucas.co/cce-calendar.git

commitaca828fdc912287b34942aec9baf259a7a8884d4
parente775400c2f
authorLucas Galante <[email protected]>
date2026-09-24 12:49
Root plate: the toolkit's standard spec, not a flat fill

The window base was a full-window `pc.quad(…, BG)` at the top of
`display_list`; it is now `pc.root_plate(w, h)` (cce-ui
`PlateSpec::window`: DE root material, four window corners, `bevel_width`
roll) as the first prim of the frame. `BG` stays: it is still the
in-month cell fill and the clear colour. `PAD` is flagged with a
`TODO(style): root_plate_inset()` for a later spacing pass.

Co-Authored-By: Claude Fable 5.1 <[email protected]>

 src/main.rs | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/src/main.rs b/src/main.rs
index 39466b3..c03aec5 100644
--- a/src/main.rs
+++ b/src/main.rs
@@ -39,7 +39,7 @@ const WATCH_EVERY: std::time::Duration = std::time::Duration::from_secs(1);
 const HEADER_H: f32 = 46.0;
 const WEEKDAY_H: f32 = 24.0;
 const SIDEBAR_W: f32 = 300.0;
-const PAD: f32 = 12.0;
+const PAD: f32 = 12.0; // TODO(style): root_plate_inset()
 const ROW_H: f32 = 36.0;
 const INPUT_H: f32 = 40.0;
 /// Trackpad travel per month step over the grid (a wheel notch is one step).
@@ -811,7 +811,8 @@ impl Application for CalendarApp {
         self.win = (size.width, size.height);
         let g = self.geom();
         let mut pc = PaintCtx::new();
-        pc.quad(Rect { x: 0.0, y: 0.0, width: size.width, height: size.height }, BG);
+        // The standard root plate (cce-ui PlateSpec::window).
+        pc.root_plate(size.width, size.height);
         self.paint_header(&mut pc, &g);
         self.paint_grid(&mut pc, &g);
         self.paint_sidebar(&mut pc, &g);