LightCraft: An open-source non-destructive photo editor written by scratch in pure Rust
Merge PR #786
Claude34b55101fe42
diff --cc crates/ui-egui/src/lib.rsindex 5d88b9024,6ee6e3f2e..e096af2cf--- a/crates/ui-egui/src/lib.rs+++ b/crates/ui-egui/src/lib.rs@@@ -57,8 -47,8 +57,10 @@@ mod tests_curve#[cfg(test)]mod tests_date_picker;#[cfg(test)]+mod tests_dialogs;+#[cfg(test)]+ mod tests_dialog_fit;+ #[cfg(test)]mod tests_filmstrip;#[cfg(test)]mod tests_grid;diff --cc crates/ui-egui/src/panels/dialogs.rsindex 594cc2967,c26c06863..6e9bdadf1--- a/crates/ui-egui/src/panels/dialogs.rs+++ b/crates/ui-egui/src/panels/dialogs.rs@@@ -153,7 -127,14 +153,14 @@@ pub fn show(app: &mut LightcraftApp, ct// own so the size it is given doesn't carry over to the other dialogs. Its content scrolls// rather than growing the window when the options below the grid get taller (e.g. Copy).let import = matches!(dlg, Dialog::Import { .. });- let window_id = egui::Id::new(if import { "lightcraft-import-dialog" } else { "lightcraft-dialog" });+ let window_id = window_id(&dlg);+ // Every other dialog fits the window (#781): its options scroll when they don't, and the title+ // bar and the button row stay outside the scroll area. The room they take is measured on the+ // previous frame (a guess on the first one).+ let chrome_id = window_id.with("chrome");+ let chrome = ctx.data(|d| d.get_temp::<f32>(chrome_id)).unwrap_or(DIALOG_CHROME_GUESS);+ let body_max = (screen.height() - 2.0 * DIALOG_SCREEN_MARGIN - chrome).max(DIALOG_MIN_BODY);+ let mut body_h = None;let shown = egui::Window::new(crate::i18n::tr(&title)).id(window_id).collapsible(false).resizable(import)@@@ -994,17 -952,12 +1001,17 @@@}}Dialog::Shortcuts => crate::panels::keymap::body(app, ui, &t),- }+ });ui.add_space(4.0);ui.horizontal(|ui| {- // a model file LightCraft cannot use has nothing to confirm+ // a model file LightCraft cannot use has nothing to confirm, nor has a dialog that+ // only shows something (one Close, no Cancel / OK)let unusable_model = matches!(&dlg, Dialog::DenoiseModel { info, .. } | Dialog::FaceModel { info, .. } if info["kind"] == "unsupported");- let informational = unusable_model || matches!(dlg, Dialog::About | Dialog::Shortcuts | Dialog::Settings { .. });+ let informational = unusable_model+ || matches!(+ dlg,+ Dialog::About | Dialog::Shortcuts | Dialog::Settings { .. } | Dialog::SystemInfo { .. } | Dialog::AllMetadata { .. } | Dialog::WhatsNew+ );let sam = &app.session.segmenter;let (sam_installed, sam_running, sam_failed) = (sam.installed(), sam.download_status().running, sam.download_status().error.is_some());// no download location in this build: nothing to offer but the manual install@@@ -1077,7 -1029,13 +1084,14 @@@}});if let Some(w) = shown {+ ctx.memory_mut(|m| m.set_modal_layer(w.response.layer_id));+ if let Some(body_h) = body_h {+ let measured = (w.response.rect.height() - body_h).max(0.0);+ if (measured - chrome).abs() > 0.5 {+ ctx.data_mut(|d| d.insert_temp(chrome_id, measured));+ ctx.request_repaint();+ }+ }ctx.move_to_top(w.response.layer_id);crate::widgets::register(ctx, "dialog:window", w.response.rect);}diff --cc docs/whats-new.mdindex 2de8c4961,561cf965f..e9a912152--- a/docs/whats-new.md+++ b/docs/whats-new.md@@@ -1,15 -1,13 +1,21 @@@# What's new in LightCraft+## 2026-10-11++### Open Library knows a Lightroom catalog+- Choosing a Lightroom Classic catalog folder in File → Open Library… (or one of its `Previews.lrdata` /+ `.lrcat-data` folders, or the `.lrcat`) no longer makes an empty LightCraft library inside it (issue #891). The+ library open now stays, and LightCraft says "This is a Lightroom catalog, not a LightCraft library" and offers+ **Import Lightroom Catalog…** with that catalog, or Cancel. `lightcraft-cli --library` refuses those folders too.+## 2026-10-10+ ### Dialogs fit the window+ - A dialog taller than the window no longer runs off it (issue #781): on a 1366×768 screen the Export dialog's title+ and its Cancel / OK buttons were off screen, so it couldn't be confirmed. Now its options scroll and the title and+ buttons stay visible. Long lists in dialogs (What's New, All Metadata, Keyboard Shortcuts) get shorter to fit.+ Dialogs that fit look as before.+### Activity stack- Long-running tasks show in one place, top left under the top bar, as in Lightroom Classic (issue #345): imports andfolder scans, exports (and the contact sheet PDF), Synchronize Folder, Build / Smart Previews, Lightroom catalog import, Photo Merge, model downloads, the face scan,