graphic design tool
git clone https://git.lucas.co/cce-designer.git
fix(viewport): the viewer-state line goes back up a row
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
CLAUDE.md | 4 ++--
src/render.rs | 12 ++++++------
2 files changed, 8 insertions(+), 8 deletions(-)
diff --git a/CLAUDE.md b/CLAUDE.md
index 21d0ebd..83477c2 100644
--- a/CLAUDE.md
+++ b/CLAUDE.md
@@ -382,8 +382,8 @@ gone from cce-ui with the wgpu path).
are joined in order. Handle labels draw on a dark tab, since a handle
can stand over a white image.
- The HUD draws at the viewport's bottom left — not
- at the top, because the viewport is full-bleed and the pane plates float over
+ The HUD draws one line up from the viewport's bottom left (the row it had
+ above the scale readout, which is gone) — not at the top, because the viewport is full-bleed and the pane plates float over
its top edge, so a mode line there lands under the collapsed stubs. It exists
because a viewer state changes what every click does and snapping silently
changes what a drag does.
diff --git a/src/render.rs b/src/render.rs
index 9feac71..47a1d1a 100644
--- a/src/render.rs
+++ b/src/render.rs
@@ -1256,11 +1256,11 @@ impl State {
}
});
- // The HUD sits at the viewport's bottom left. Not at the top: the
- // viewport is full-bleed and the pane plates float over its top edge,
- // so a mode line there lands under the collapsed stubs and their
- // titles read through it. (It stood a line above the scale readout
- // until that was removed on 2026-10-06.)
+ // The HUD sits one line up from the viewport's bottom left, the row
+ // it had above the scale readout, kept when the readout went
+ // (2026-10-06). Not at the top: the viewport is full-bleed and the
+ // pane plates float over its top edge, so a mode line there lands
+ // under the collapsed stubs and their titles read through it.
//
// It exists because a viewer state changes what every click does and
// snapping silently changes what a drag does. A mode you cannot see is
@@ -1269,7 +1269,7 @@ impl State {
let hud = tool.hud();
let size = 11.0;
let pad = 5.0;
- let y = self.scene_text_floor(vy + vh) - (size + pad * 2.0) - 8.0;
+ let y = self.scene_text_floor(vy + vh) - 16.0 - (size + pad * 2.0) - 4.0;
let width = (hud.chars().count() as f32 * size * 0.52 + pad * 2.0).min(vw - 16.0);
pc.clip(rect(vx, vy, vw, vh), |pc| {
pc.quad(rect(vx + 8.0 - pad, y, width, size + pad * 2.0), [0.0, 0.0, 0.0, 0.55]);