PhotoCraft: An open-source, photo editor written by scratch in pure Rust
Merge main into feat/zoom-animation-566
Gustavo Zigere14dda9dc8a2
diff --cc crates/ui-egui/src/canvas.rsindex f8034eb19,db11fc730..6c47c8989--- a/crates/ui-egui/src/canvas.rs+++ b/crates/ui-egui/src/canvas.rs@@@ -3090,30 -3027,6 +3083,32 @@@ pub fn canvas_view(app: &mut Photocraft// Every document view has its rulers, the tiles of Window › Arrange and floating windows// too, as in Photoshop (#6017).let rect = crate::rulers::content_rect(app, rect);+ // Both wheel reads share one owner so snap-zoom input is accumulated only once per frame.+ let wheel_owner = ui.id().with(("canvas-wheel", idx));+ // Direct navigation starts from the authoritative camera. This also means a click or drag+ // never maps through a camera that is still moving under the pointer.+ let (pointer_here, hover_here) = ctx.input(|i| {+ (+ (i.pointer.any_pressed() || i.pointer.any_down()) && i.pointer.press_origin().is_some_and(|p| rect.contains(p)),+ i.pointer.hover_pos().is_some_and(|p| rect.contains(p)),+ )+ });+ let direct_input = pointer_here+ || (hover_here- && crate::wheel_nav::read(++ && crate::wheel_nav::read_with(+ &ctx,+ app.session.prefs().general.zoom_with_scroll_wheel,+ app.session.prefs().enhanced_controls.zoom_with_trackpad_pinch,+ wheel_owner,+ hover_here,++ app.session.prefs().interface.enable_animations,++ app.session.prefs().enhanced_controls.touch_gestures,+ )+ .is_some());+ if direct_input {+ view.zoom_animating = false;+ view.zoom_anchor = None;+ }let doc = app.session.documents()[idx].doc.clone();let size = [doc.size.width, doc.size.height];if view.doc_size != size {@@@ -3429,9 -3334,10 +3427,10 @@@&ctx,app.session.prefs().general.zoom_with_scroll_wheel,app.session.prefs().enhanced_controls.zoom_with_trackpad_pinch,- response.id.with("wheel"),+ wheel_owner,nav_hovered,app.session.prefs().interface.enable_animations,+ touch_gestures,);if nav_hovered {let pointer = ui.input(|i| i.pointer.hover_pos());@@@ -3464,9 -3370,7 +3463,9 @@@_ => {}}let rotate_trackpad = app.session.prefs().enhanced_controls.rotate_view_with_trackpad;- if let Some(delta) = crate::rotate_view::trackpad_delta(&ctx, rotate_trackpad) {+ if let Some(delta) = crate::rotate_view::trackpad_delta(&ctx, rotate_trackpad, touch_gestures) {+ view.zoom_animating = false;+ view.zoom_anchor = None;let next = view.rotation + crate::rotate_view::screen_delta(delta, xf.flip);if next.is_finite() {view.rotation = crate::rotate_view::wrap_deg(next);diff --cc docs/scorecard.mdindex e7954a5b4,b32002893..1ef76a45b--- a/docs/scorecard.md+++ b/docs/scorecard.md@@@ -9,7 -9,7 +9,7 @@@ Generated by `cargo xtask scorecard` fr| [Performance](#performance) | 3 | 22 | 24 | 58 scenarios: 3 within budget, 22 over budget or failing, 9 tracked only, 19 not run, 5 not measurable yet (baseline 2026-10-05) || [File compatibility](#file-compatibility) | 7 | 14 | 6 | io corpus: oracle ≥ 148/170, round trip ≥ 169/170; psd-tools corpus: oracle ≥ 249/309, round trip ≥ 308/309; photoshop oracles: oracle ≥ 188/256, round trip ≥ 258/256 || [Tools](#tools) | 33 | 11 | 0 | |--| [Workspace and UI](#workspace-and-ui) | 13 | 6 | 4 | settings that do nothing: 25 of 168 (target 0) |++| [Workspace and UI](#workspace-and-ui) | 13 | 6 | 4 | settings that do nothing: 24 of 168 (target 0) || [Type](#type) | 4 | 3 | 2 | || [Automation](#automation) | 5 | 2 | 4 | 631 of 631 menu items live (100.0%) || [Reliability](#reliability) | 5 | 2 | 0 | never-crash lints on 30 of 30 crates; panic_hunt present |@@@ -179,9 -179,9 +179,9 @@@ Corpus floors (`crates/io/tests/corpus.## Workspace and UI--**Settings that do nothing: 25 of 168** (target 0, #204). Counted by the prefs audit (`xtask/src/scorecard.rs`): a `Preferences` field counts as read when code outside the prefs model (`prefs.rs` except its `impl Session` blocks; tests excluded; the schema-driven dialog never names a field) accesses `section.field`, or `.section` and `.field` in the same file, or calls a section method that reads `self.field`. It is a heuristic lower bound: a generic name can look read when it isn't.++**Settings that do nothing: 24 of 168** (target 0, #204). Counted by the prefs audit (`xtask/src/scorecard.rs`): a `Preferences` field counts as read when code outside the prefs model (`prefs.rs` except its `impl Session` blocks; tests excluded; the schema-driven dialog never names a field) accesses `section.field`, or `.section` and `.field` in the same file, or calls a section method that reads `self.field`. It is a heuristic lower bound: a generic name can look read when it isn't.- Unread: `general.color_picker`, `general.zoom_resizes_windows`, `workspace.auto_show_hidden_panels`, `workspace.enable_floating_document_window_docking`, `file_handling.save_in_background`, `performance.cache_levels`, `performance.legacy_compositing`, `scratch_disks.disks`, `units_and_rulers.column_width`, `units_and_rulers.gutter`, `plug_ins.show_extension_panels`, `plug_ins.allow_scripts_to_connect`, `plug_ins.generator_enabled`, `type_.text_engine`, `type_.recent_fonts`, `enhanced_controls.scrubby_slider_acceleration`, `enhanced_controls.touch_gestures`, `raw_defaults.color_space`, `raw_defaults.bit_depth`, `raw_defaults.resolution`, `raw_defaults.sharpen_for`, `raw_defaults.open_as_smart_object`, `raw_defaults.apply_auto_tone`, `integrations.allow_agent_control`, `integrations.control_port`.-Unread: `general.color_picker`, `general.animated_zoom`, `general.zoom_resizes_windows`, `workspace.auto_show_hidden_panels`, `workspace.enable_floating_document_window_docking`, `file_handling.save_in_background`, `performance.cache_levels`, `performance.legacy_compositing`, `scratch_disks.disks`, `units_and_rulers.column_width`, `units_and_rulers.gutter`, `plug_ins.show_extension_panels`, `plug_ins.allow_scripts_to_connect`, `plug_ins.generator_enabled`, `type_.text_engine`, `type_.recent_fonts`, `enhanced_controls.scrubby_slider_acceleration`, `raw_defaults.color_space`, `raw_defaults.bit_depth`, `raw_defaults.resolution`, `raw_defaults.sharpen_for`, `raw_defaults.open_as_smart_object`, `raw_defaults.apply_auto_tone`, `integrations.allow_agent_control`, `integrations.control_port`.++Unread: `general.color_picker`, `general.zoom_resizes_windows`, `workspace.auto_show_hidden_panels`, `workspace.enable_floating_document_window_docking`, `file_handling.save_in_background`, `performance.cache_levels`, `performance.legacy_compositing`, `scratch_disks.disks`, `units_and_rulers.column_width`, `units_and_rulers.gutter`, `plug_ins.show_extension_panels`, `plug_ins.allow_scripts_to_connect`, `plug_ins.generator_enabled`, `type_.text_engine`, `type_.recent_fonts`, `enhanced_controls.scrubby_slider_acceleration`, `raw_defaults.color_space`, `raw_defaults.bit_depth`, `raw_defaults.resolution`, `raw_defaults.sharpen_for`, `raw_defaults.open_as_smart_object`, `raw_defaults.apply_auto_tone`, `integrations.allow_agent_control`, `integrations.control_port`.| Id | Target | Status | Issue | Note ||---|---|---|---|---|