diff options
| author | Gabriel Schneider <[email protected]> | 2026-09-28 18:24:18 -0300 |
|---|---|---|
| committer | Gabriel Schneider <[email protected]> | 2026-10-01 00:12:15 -0300 |
| commit | 5dbd21795f6c68bd3c10d409135970e3033364f3 (patch) | |
| tree | 7dcea4712daa0dcd46e8b8438ca00b2001a4aed4 /src/detached/wire.zig | |
| parent | f41d0209f65237568c9f7d527d5989ac8921b74c (diff) | |
| download | pardes-5dbd21795f6c68bd3c10d409135970e3033364f3.tar.gz pardes-5dbd21795f6c68bd3c10d409135970e3033364f3.zip | |
Motion flavours, and Lift is shadow, rim or auto: auto on a dark page recedes the other panes (InactiveDim)
Motion off|crisp|smooth|bouncy|playful is one parameter set (animation.Motion)
every fx animation reads. One focus spring per pane drives both the lift and
the dim, at the flavour's pace; a grid snaps.
Lift drops glow and surface. A shadow falls on pane bodies and rails only,
capped so text and the selection keep min(contrast, 4.5); rim is a hairline
along the focused tag's top. auto is a shadow on a light page; on a dark page
the core recedes the unfocused panes' text (InactiveDim, ported from 2e4d97f,
default 30 under auto) with the same floor. Tests: focused text contrast is
never below unfocused in any style, dim or theme; the focused pane's cells and
tag are untouched by a dim.
Shared files: src/config.zig, src/builtins.zig, src/ninep/ctl.zig,
src/surface.zig, src/detached/wire.zig, docs/config.md,
test/snapshots/builtins.snap (one more wheel for the longer help).
Diffstat (limited to 'src/detached/wire.zig')
| -rw-r--r-- | src/detached/wire.zig | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/detached/wire.zig b/src/detached/wire.zig index 0a066410..2a2ccc6b 100644 --- a/src/detached/wire.zig +++ b/src/detached/wire.zig @@ -254,7 +254,8 @@ pub const Frame = struct { region.notice = try r.getByte(); region.clip = try r.getU16(); region.lift = @bitCast(try r.getU32()); - if (!(region.lift >= 0 and region.lift <= 1)) return error.BadValue; + // A springy flavour overshoots, and a wind-up dips below. + if (!(region.lift >= -1 and region.lift <= 2)) return error.BadValue; if (region.rect.x > f.cols or region.rect.w > f.cols - region.rect.x or region.rect.y > f.rows or region.rect.h > f.rows - region.rect.y or region.clip > region.rect.w or region.thumb_y > region.rect.h or region.thumb_h > region.rect.h - region.thumb_y) return error.BadValue; |
