git.lucas.co / cce-designer
graphic design tool
git clone https://git.lucas.co/cce-designer.git

commit8a69cfb2a27c4774bc8dbe182fd2a179d9853d1c
parent6a22b6e8d3
authorLucas Galante <lsgalante12@gmail.com>
date2026-09-29 17:40
refactor: the network lattice reads graph.grid_color, and has no cell fill

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>

 CLAUDE.md  | 14 +++++++++-----
 src/app.rs | 28 ++++++++++------------------
 2 files changed, 19 insertions(+), 23 deletions(-)

diff --git a/CLAUDE.md b/CLAUDE.md
index 9b0a282..d99ce47 100644
--- a/CLAUDE.md
+++ b/CLAUDE.md
@@ -1800,10 +1800,14 @@ Two keys look like they apply and do not: `style.surface.plate.color`
 feeds `plate_color`, whose one consumer is the info box, and the finish's
 spec / shininess / curvature live as `relief.spec` / `.shininess` /
 `.curvature`, not under `plate`. The network pane is two layers: the
-`PassivePlate` above and the Graph on top with its own `style.surface.graph`
-fill (`cell_color`, `gap_color`, `opacity`, `blur`, `uniform_background`),
-nearly transparent by default so the lattice you see is the pane plate
-showing through — the next section is about dropping that plate entirely.
+`PassivePlate` above and the Graph on top, which has NO fill of its own
+(since 2026-09-29): its cells are whatever it is painted on — the pane
+plate, or the scene with the plate off — and `style.surface.graph` sets
+only the lines (`grid_color`, `line_width`), their `opacity`, and `blur`.
+Until then the graph filled itself with `cell_color` (this app hard-codes
+`uniform_background` true, which chose it) and drew its lines in
+`gap_color`; both keys are retired, reported by path at load and not read.
+The next section is about dropping the pane plate entirely.
 The params widget alone also reads `style.surface.param.backdrop_compression`.
 The rules live in cce-ui's CLAUDE.md ("There is one roll width", "The
 relief is two shapes", "Frost is one block"); this is the designer's view of
@@ -2014,7 +2018,7 @@ baseline Reset Zoom returns to and Frame All scales down from (never past
 100%); `MIN_PITCH_*` / `MAX_PITCH_*` are the old node-body zoom limits
 expressed on the pitch.
 
-The widget paints the lattice as lines (`paint_grid`: gap colour, network
+The widget paints the lattice as lines (`paint_grid`: `grid_color`, network
 opacity, `style.surface.graph.line_width` px, each line centred on its
 coordinate so the width changes nothing about where anything sits) with the
 two lines through the (0, 0) crossing heavier as the origin axes. Its
diff --git a/src/app.rs b/src/app.rs
index c18bf75..13393e9 100644
--- a/src/app.rs
+++ b/src/app.rs
@@ -1995,8 +1995,9 @@ pub struct State {
     pub vertex_count_spheres: u32,
     pub node_color: [f32; 4],
     pub grid_color: [f32; 3],
-    pub cell_color: [f32; 3],
-    pub gap_color: [f32; 3],
+    /// The network lattice's line colour (`style.surface.graph.grid_color`);
+    /// `grid_color` above is the viewport's ground grid.
+    pub graph_grid_color: [f32; 3],
     pub origin_size: f32,
     pub camera_pivot_size: f32,
 
@@ -6510,8 +6511,7 @@ pub(crate) fn geometry_to_spreadsheet_data(geom: &Detail) -> (Vec<String>, Vec<V
             vertex_count_spheres: 0,
             node_color: cce_ui::color::graph_node_color(),
             grid_color: settings.viewport.grid_color,
-            cell_color: cce_ui::color::graph_cell_color(),
-            gap_color: cce_ui::color::graph_gap_color(),
+            graph_grid_color: cce_ui::color::graph_grid_color(),
             origin_size: settings.viewport.origin_size,
             camera_pivot_size: settings.viewport.camera_pivot_size,
             fs_root: fs_root.clone(),
@@ -6982,8 +6982,7 @@ pub(crate) fn geometry_to_spreadsheet_data(geom: &Detail) -> (Vec<String>, Vec<V
             graph.set_uniform_background(self.uniform_background);
             graph.set_network_opacity(self.network_opacity);
             graph.set_node_opacity(self.node_opacity);
-            graph.set_cell_color(self.cell_color);
-            graph.set_gap_color(self.gap_color);
+            graph.set_grid_color(self.graph_grid_color);
         }
         if let Some(menubar) = self.slots.left_menubar.as_any_mut().downcast_mut::<cce_ui::widget::MenuBar>() {
             menubar.set_network_opacity(self.network_opacity);
@@ -7008,8 +7007,7 @@ pub(crate) fn geometry_to_spreadsheet_data(geom: &Detail) -> (Vec<String>, Vec<V
             g2.set_uniform_background(self.uniform_background);
             g2.set_network_opacity(self.network_opacity);
             g2.set_node_opacity(self.node_opacity);
-            g2.set_cell_color(self.cell_color);
-            g2.set_gap_color(self.gap_color);
+            g2.set_grid_color(self.graph_grid_color);
         }
         if let Some(bc2) = self.slots.breadcrumb2.as_any_mut().downcast_mut::<cce_ui::widget::Breadcrumb>() {
             bc2.set_network_opacity(self.network_opacity);
@@ -7059,8 +7057,7 @@ pub(crate) fn geometry_to_spreadsheet_data(geom: &Detail) -> (Vec<String>, Vec<V
         
         let opacity = cce_ui::color::graph_opacity();
         let node_opacity = cce_ui::color::graph_node_opacity();
-        let cell_color = cce_ui::color::graph_cell_color();
-        let gap_color = cce_ui::color::graph_gap_color();
+        let graph_grid_color = cce_ui::color::graph_grid_color();
         let snap_enabled = cce_ui::layout::graph_grid_snap();
         let node_color = cce_ui::color::graph_node_color();
         let node_compression = cce_ui::config::cached_config()
@@ -7082,12 +7079,8 @@ pub(crate) fn geometry_to_spreadsheet_data(geom: &Detail) -> (Vec<String>, Vec<V
             self.node_opacity = node_opacity;
             changed = true;
         }
-        if self.cell_color != cell_color {
-            self.cell_color = cell_color;
-            changed = true;
-        }
-        if self.gap_color != gap_color {
-            self.gap_color = gap_color;
+        if self.graph_grid_color != graph_grid_color {
+            self.graph_grid_color = graph_grid_color;
             changed = true;
         }
         if self.node_color != node_color {
@@ -10390,8 +10383,7 @@ pub(crate) fn geometry_to_spreadsheet_data(geom: &Detail) -> (Vec<String>, Vec<V
                          self.viewport_mut().grid_color = settings.viewport.grid_color;
                          self.origin_size = settings.viewport.origin_size;
                          self.camera_pivot_size = settings.viewport.camera_pivot_size;
-                         self.cell_color = cce_ui::color::graph_cell_color();
-                         self.gap_color = cce_ui::color::graph_gap_color();
+                         self.graph_grid_color = cce_ui::color::graph_grid_color();
 
                         colors::set_node_color(self.node_color);