diff --git a/Cargo.lock b/Cargo.lock index 0cfac1f..b98178b 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -548,7 +548,7 @@ dependencies = [ [[package]] name = "canvas-pilot" -version = "0.9.8" +version = "0.9.9" dependencies = [ "base64", "craft-dwg", diff --git a/Cargo.toml b/Cargo.toml index 66762ef..14221e5 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -4,7 +4,7 @@ default-members = ["crates/canvas-pilot"] resolver = "3" [workspace.package] -version = "0.9.8" +version = "0.9.9" edition = "2024" license = "MIT" repository = "https://proxy.dandaedre.com/gitea/idle-org/canvas-pilot" diff --git a/crates/canvas-pilot/src/gui.rs b/crates/canvas-pilot/src/gui.rs index 4bd2957..1f2dbb3 100644 --- a/crates/canvas-pilot/src/gui.rs +++ b/crates/canvas-pilot/src/gui.rs @@ -4482,7 +4482,11 @@ fn toolbar_menu( let widgets = &mut ui.style_mut().visuals.widgets; for (visuals, fill, border) in [ (&mut widgets.inactive, palette.field, palette.line), - (&mut widgets.hovered, palette.panel, palette.cyan), + ( + &mut widgets.hovered, + original.visuals.widgets.hovered.bg_fill, + palette.cyan, + ), (&mut widgets.active, palette.purple, palette.cyan), (&mut widgets.open, palette.panel, palette.cyan), ] { diff --git a/crates/canvas-pilot/src/theme.rs b/crates/canvas-pilot/src/theme.rs index ee681b4..4ea23dc 100644 --- a/crates/canvas-pilot/src/theme.rs +++ b/crates/canvas-pilot/src/theme.rs @@ -306,12 +306,14 @@ impl Theme { } else { Color32::LIGHT_RED }; + // A small contrast shift makes borderless menu hover visible too. + let hover_fill = p.panel.lerp_to_gamma(p.text, 0.08); v.selection.bg_fill = p.purple; v.selection.stroke = Stroke::new(1.0_f32, p.text); for (widget, fill, border) in [ (&mut v.widgets.noninteractive, p.panel, p.line), (&mut v.widgets.inactive, p.field, p.line), - (&mut v.widgets.hovered, p.panel, p.cyan), + (&mut v.widgets.hovered, hover_fill, p.cyan), (&mut v.widgets.active, p.purple, p.cyan), (&mut v.widgets.open, p.panel, p.cyan), ] { diff --git a/docs/canvas-pilot/changelog.md b/docs/canvas-pilot/changelog.md index b1e5abe..811200c 100644 --- a/docs/canvas-pilot/changelog.md +++ b/docs/canvas-pilot/changelog.md @@ -4,6 +4,13 @@ ## Unreleased +### v0.9.9 + +- Added a subtle background shift to shared hover styling, including borderless + menus and toolbar menus. The colour adapts to each theme without animation, + extra drawing passes or changes to control sizes. Native dark/light screenshots + confirmed stationary rows; required checks passed with 91.38% line coverage. + ### v0.9.8 - Fixed hover/focus outlines changing selectable-row widths and moving surrounding