From b7241253bbc709423a98598c8dcc1a0268cca88c Mon Sep 17 00:00:00 2001 From: ruchirguitar <113586074+ruchirguitar@users.noreply.github.com> Date: Mon, 9 Nov 2026 14:35:13 +0530 Subject: [PATCH] 5804: select a raster editor through the native picker --- apps/vectorcraft/src/host_services.rs | 34 ++- crates/ui-egui/src/app.rs | 1 + crates/ui-egui/src/dialogs.rs | 3 + crates/ui-egui/src/i18n/bg.tsv | 4 + crates/ui-egui/src/i18n/bs.tsv | 4 + crates/ui-egui/src/i18n/ca.tsv | 4 + crates/ui-egui/src/i18n/cs.tsv | 4 + crates/ui-egui/src/i18n/da.tsv | 4 + crates/ui-egui/src/i18n/de.tsv | 4 + crates/ui-egui/src/i18n/el.tsv | 4 + crates/ui-egui/src/i18n/es.tsv | 4 + crates/ui-egui/src/i18n/fi.tsv | 4 + crates/ui-egui/src/i18n/fr.tsv | 4 + crates/ui-egui/src/i18n/hi.tsv | 4 + crates/ui-egui/src/i18n/hu.tsv | 4 + crates/ui-egui/src/i18n/id.tsv | 4 + crates/ui-egui/src/i18n/it.tsv | 4 + crates/ui-egui/src/i18n/ja.tsv | 4 + crates/ui-egui/src/i18n/ka.tsv | 4 + crates/ui-egui/src/i18n/ko.tsv | 4 + crates/ui-egui/src/i18n/nl.tsv | 4 + crates/ui-egui/src/i18n/pl.tsv | 4 + crates/ui-egui/src/i18n/pt-br.tsv | 4 + crates/ui-egui/src/i18n/ru.tsv | 4 + crates/ui-egui/src/i18n/sv.tsv | 4 + crates/ui-egui/src/i18n/tr.tsv | 4 + crates/ui-egui/src/i18n/uk.tsv | 4 + crates/ui-egui/src/i18n/vi.tsv | 4 + crates/ui-egui/src/i18n/zh-hans.tsv | 4 + crates/ui-egui/src/i18n/zh-hant.tsv | 4 + crates/ui-egui/src/io/export.rs | 7 +- crates/ui-egui/src/lib.rs | 4 + crates/ui-egui/src/original_editor.rs | 254 +++++++++++++++++++++++ crates/ui-egui/src/panels/tests_links.rs | 14 ++ crates/ui-egui/src/prefs_dialog.rs | 8 + crates/ui-egui/src/services.rs | 7 + crates/ui-egui/src/state.rs | 4 + docs/control-protocol.md | 4 +- docs/gaps.md | 6 +- docs/mcp.md | 2 + docs/roadmap.md | 8 +- docs/target-app-parity.md | 8 +- docs/ui-parity.md | 6 +- 43 files changed, 467 insertions(+), 11 deletions(-) create mode 100644 crates/ui-egui/src/original_editor.rs diff --git a/apps/vectorcraft/src/host_services.rs b/apps/vectorcraft/src/host_services.rs index 187c42cde7..bdf28f9cd2 100644 --- a/apps/vectorcraft/src/host_services.rs +++ b/apps/vectorcraft/src/host_services.rs @@ -378,6 +378,8 @@ pub(crate) fn services(parent: Parent, ui: egui::Context) -> Services { open_file: Some(Box::new(open_file)), // Edit Original of a raster image with Use System Defaults for Edit Original off (#5236). open_in_photocraft: Some(Box::new(open_in_photocraft)), + check_application: Some(Box::new(|p| check_app(std::path::Path::new(p)))), + open_in_application: Some(Box::new(open_in_application)), pick_folder: Some(Box::new(move || pick_now(PickRequest::Folder, &p4).into_iter().next())), // Sample Color from Screen: the system's color sampler. #[cfg(target_os = "macos")] @@ -421,15 +423,32 @@ fn open_in_photocraft(path: &str) -> Result { explorer_safe(path)?; let home = std::env::var_os(if cfg!(windows) { "USERPROFILE" } else { "HOME" }).map(std::path::PathBuf::from); let Some(app) = find_photocraft(home.as_deref(), std::env::var_os("PATH").as_deref()) else { return Ok(false) }; + launch_application(&app, path) +} + +/// A missing chosen editor falls back; invalid applications and failed launches remain errors. +fn open_in_application(app: &str, path: &str) -> Result { + explorer_safe(path)?; + let app = std::path::Path::new(app); + match std::fs::metadata(app) { + Err(e) if e.kind() == std::io::ErrorKind::NotFound => return Ok(false), + Err(e) => return Err(format!("cannot inspect {}: {e}", app.display())), + Ok(_) => {} + } + check_app(app)?; + launch_application(app, path) +} + +fn launch_application(app: &std::path::Path, path: &str) -> Result { #[cfg(target_os = "macos")] let mut c = { let mut c = std::process::Command::new("open"); - c.arg("-a").arg(&app).arg(path); + c.arg("-a").arg(app).arg(path); c }; #[cfg(not(target_os = "macos"))] let mut c = { - let mut c = std::process::Command::new(&app); + let mut c = std::process::Command::new(app); c.arg(path); c }; @@ -602,6 +621,17 @@ mod open_with_tests { tempfile::Builder::new().prefix(&format!("vc-open-with-{name}-")).tempdir().unwrap() } + #[test] + fn chosen_editor_only_falls_back_when_missing() { + let dir = scratch("chosen"); + let missing = dir.path().join("Missing.exe"); + assert!(!super::open_in_application(&missing.to_string_lossy(), "image with spaces.png").unwrap()); + let doc = dir.path().join("notes.txt"); + std::fs::write(&doc, "not an application").unwrap(); + assert!(super::open_in_application(&doc.to_string_lossy(), "image.png").is_err()); + assert!(super::open_in_application(&dir.path().to_string_lossy(), "image.png").is_err()); + } + /// #5236: only an application counts as PhotoCraft, never a document, a folder or a missing /// path. #[test] diff --git a/crates/ui-egui/src/app.rs b/crates/ui-egui/src/app.rs index d02c59728d..ff380dd982 100644 --- a/crates/ui-egui/src/app.rs +++ b/crates/ui-egui/src/app.rs @@ -136,6 +136,7 @@ impl VectorcraftApp { system_paste_at: f64::NEG_INFINITY, clipboard_probe: None, picks: picks::Picks::default(), + original_editor: Default::default(), screen_sampler: None, font_check: None, #[cfg(not(target_arch = "wasm32"))] diff --git a/crates/ui-egui/src/dialogs.rs b/crates/ui-egui/src/dialogs.rs index 1f59647c13..7571a4dbd7 100644 --- a/crates/ui-egui/src/dialogs.rs +++ b/crates/ui-egui/src/dialogs.rs @@ -561,6 +561,9 @@ pub(crate) fn field_set(app: &mut VectorcraftApp, field: &str, old: Option<&Valu pub fn cancel(app: &mut VectorcraftApp) { missing_fonts::requeue_replaced(app); if let Some(d) = app.ui.dialog.take() { + if d.kind == "preferences" { + crate::original_editor::cancel(app); + } if d.kind == swatch_conflict::KIND { crate::placing::cancel_swatch_paste(app); } diff --git a/crates/ui-egui/src/i18n/bg.tsv b/crates/ui-egui/src/i18n/bg.tsv index ceb10bb4d2..ab6d95d79a 100644 --- a/crates/ui-egui/src/i18n/bg.tsv +++ b/crates/ui-egui/src/i18n/bg.tsv @@ -6427,3 +6427,7 @@ breakText Glyphs Глифи # Align to Pixel Grid Align to Pixel Grid Подравняване към пикселната мрежа @msg side is left or right, not `{s}` side е left или right, а не `{s}` + +# #5804 native-picked raster editor (draft translations; native review welcome). + Edit Original with: Редактиране на оригинала с: +file-filter Applications Приложения diff --git a/crates/ui-egui/src/i18n/bs.tsv b/crates/ui-egui/src/i18n/bs.tsv index d70d67c909..3bb02a3c56 100644 --- a/crates/ui-egui/src/i18n/bs.tsv +++ b/crates/ui-egui/src/i18n/bs.tsv @@ -6478,3 +6478,7 @@ shape Open Otvoren # Align to Pixel Grid Align to Pixel Grid Poravnaj s mrežom piksela @msg side is left or right, not `{s}` side je left ili right, a ne `{s}` + +# #5804 native-picked raster editor (draft translations; native review welcome). + Edit Original with: Uredi original pomoću: +file-filter Applications Aplikacije diff --git a/crates/ui-egui/src/i18n/ca.tsv b/crates/ui-egui/src/i18n/ca.tsv index 2fec000ece..7b90b5e7d2 100644 --- a/crates/ui-egui/src/i18n/ca.tsv +++ b/crates/ui-egui/src/i18n/ca.tsv @@ -6640,3 +6640,7 @@ breakText Glyphs Glifs Align to Pixel Grid Alinea a la quadrícula de píxels @msg only paths and compound paths can be aligned to the pixel grid només els traçats i els traçats compostos es poden alinear a la quadrícula de píxels @msg side is left or right, not `{s}` side ha de ser left o right, no `{s}` + +# #5804 native-picked raster editor (draft translations; native review welcome). + Edit Original with: Edita l’original amb: +file-filter Applications Aplicacions diff --git a/crates/ui-egui/src/i18n/cs.tsv b/crates/ui-egui/src/i18n/cs.tsv index 204e73da92..14efa3c2ad 100644 --- a/crates/ui-egui/src/i18n/cs.tsv +++ b/crates/ui-egui/src/i18n/cs.tsv @@ -6659,3 +6659,7 @@ breakText Glyphs Glyfy Align to Pixel Grid Zarovnat na mřížku obrazových bodů @msg only paths and compound paths can be aligned to the pixel grid na mřížku obrazových bodů lze zarovnat jen cesty a složené cesty @msg side is left or right, not `{s}` side je left nebo right, ne `{s}` + +# #5804 native-picked raster editor (draft translations; native review welcome). + Edit Original with: Upravit originál v: +file-filter Applications Aplikace diff --git a/crates/ui-egui/src/i18n/da.tsv b/crates/ui-egui/src/i18n/da.tsv index 395176d3d7..a389867cc5 100644 --- a/crates/ui-egui/src/i18n/da.tsv +++ b/crates/ui-egui/src/i18n/da.tsv @@ -6441,3 +6441,7 @@ breakText Glyphs Glyffer # Align to Pixel Grid Align to Pixel Grid Juster efter pixelgitter @msg side is left or right, not `{s}` side er left eller right, ikke `{s}` + +# #5804 native-picked raster editor (draft translations; native review welcome). + Edit Original with: Redigér original med: +file-filter Applications Programmer diff --git a/crates/ui-egui/src/i18n/de.tsv b/crates/ui-egui/src/i18n/de.tsv index db16fec6a7..1dc7399cc5 100644 --- a/crates/ui-egui/src/i18n/de.tsv +++ b/crates/ui-egui/src/i18n/de.tsv @@ -6246,3 +6246,7 @@ breakText Glyphs Glyphen Align to Pixel Grid Am Pixelraster ausrichten @msg only paths and compound paths can be aligned to the pixel grid nur Pfade und zusammengesetzte Pfade können am Pixelraster ausgerichtet werden @msg side is left or right, not `{s}` side ist left oder right, nicht `{s}` + +# #5804 native-picked raster editor (draft translations; native review welcome). + Edit Original with: Original bearbeiten mit: +file-filter Applications Anwendungen diff --git a/crates/ui-egui/src/i18n/el.tsv b/crates/ui-egui/src/i18n/el.tsv index cbd4093872..62068a7f32 100644 --- a/crates/ui-egui/src/i18n/el.tsv +++ b/crates/ui-egui/src/i18n/el.tsv @@ -6611,3 +6611,7 @@ breakText Glyphs Γλύφοι Align to Pixel Grid Στοίχιση στο πλέγμα εικονοστοιχείων @msg only paths and compound paths can be aligned to the pixel grid μόνο διαδρομές και σύνθετες διαδρομές μπορούν να στοιχιστούν στο πλέγμα εικονοστοιχείων @msg side is left or right, not `{s}` το side είναι left ή right, όχι `{s}` + +# #5804 native-picked raster editor (draft translations; native review welcome). + Edit Original with: Επεξεργασία πρωτοτύπου με: +file-filter Applications Εφαρμογές diff --git a/crates/ui-egui/src/i18n/es.tsv b/crates/ui-egui/src/i18n/es.tsv index 1d923ccbbb..82141d2cb5 100644 --- a/crates/ui-egui/src/i18n/es.tsv +++ b/crates/ui-egui/src/i18n/es.tsv @@ -6602,3 +6602,7 @@ breakText Glyphs Glifos Align to Pixel Grid Alinear con cuadrícula de píxeles @msg only paths and compound paths can be aligned to the pixel grid solo los trazados y los trazados compuestos se pueden alinear con la cuadrícula de píxeles @msg side is left or right, not `{s}` side es left o right, no `{s}` + +# #5804 native-picked raster editor (draft translations; native review welcome). + Edit Original with: Editar original con: +file-filter Applications Aplicaciones diff --git a/crates/ui-egui/src/i18n/fi.tsv b/crates/ui-egui/src/i18n/fi.tsv index 110b30ea92..4ca39a9444 100644 --- a/crates/ui-egui/src/i18n/fi.tsv +++ b/crates/ui-egui/src/i18n/fi.tsv @@ -6694,3 +6694,7 @@ breakText Glyphs Merkit Align to Pixel Grid Tasaa pikseliruudukkoon @msg only paths and compound paths can be aligned to the pixel grid vain polut ja yhdistelmäpolut voi tasata pikseliruudukkoon @msg side is left or right, not `{s}` side on left tai right, ei `{s}` + +# #5804 native-picked raster editor (draft translations; native review welcome). + Edit Original with: Muokkaa alkuperäistä sovelluksella: +file-filter Applications Sovellukset diff --git a/crates/ui-egui/src/i18n/fr.tsv b/crates/ui-egui/src/i18n/fr.tsv index 0e1632b04f..7f4535943b 100644 --- a/crates/ui-egui/src/i18n/fr.tsv +++ b/crates/ui-egui/src/i18n/fr.tsv @@ -6654,3 +6654,7 @@ breakText Glyphs Glyphes Align to Pixel Grid Aligner sur la grille de pixels @msg only paths and compound paths can be aligned to the pixel grid seuls les tracés et les tracés transparents peuvent être alignés sur la grille de pixels @msg side is left or right, not `{s}` side vaut left ou right, pas `{s}` + +# #5804 native-picked raster editor (draft translations; native review welcome). + Edit Original with: Modifier l’original avec : +file-filter Applications Applications diff --git a/crates/ui-egui/src/i18n/hi.tsv b/crates/ui-egui/src/i18n/hi.tsv index fb15934f1e..bf90840c36 100644 --- a/crates/ui-egui/src/i18n/hi.tsv +++ b/crates/ui-egui/src/i18n/hi.tsv @@ -8101,3 +8101,7 @@ theme Appearance अपीयरेंस @msg an importer declares 1 to {MAX_EXTENSIONS} `extensions` इंपोर्टर 1 से {MAX_EXTENSIONS} `extensions` घोषित करता है @msg an importer always gets an import's budget: leave `budget` out इंपोर्टर को हमेशा इंपोर्ट का बजट मिलता है: `budget` छोड़ दें @msg side is left or right, not `{s}` side left या right होना चाहिए, `{s}` नहीं + +# #5804 native-picked raster editor (draft translations; native review welcome). + Edit Original with: मूल फ़ाइल इसमें एडिट करें: +file-filter Applications ऐप्स diff --git a/crates/ui-egui/src/i18n/hu.tsv b/crates/ui-egui/src/i18n/hu.tsv index 1430073e17..1b40c41122 100644 --- a/crates/ui-egui/src/i18n/hu.tsv +++ b/crates/ui-egui/src/i18n/hu.tsv @@ -6643,3 +6643,7 @@ breakText Glyphs Glifák Align to Pixel Grid Igazítás a pixelrácshoz @msg only paths and compound paths can be aligned to the pixel grid csak útvonalak és összetett útvonalak igazíthatók a pixelrácshoz @msg side is left or right, not `{s}` a side értéke left vagy right lehet, nem `{s}` + +# #5804 native-picked raster editor (draft translations; native review welcome). + Edit Original with: Eredeti szerkesztése ezzel: +file-filter Applications Alkalmazások diff --git a/crates/ui-egui/src/i18n/id.tsv b/crates/ui-egui/src/i18n/id.tsv index d7a17ce502..58acbe559c 100644 --- a/crates/ui-egui/src/i18n/id.tsv +++ b/crates/ui-egui/src/i18n/id.tsv @@ -6441,3 +6441,7 @@ breakText Glyphs Glif # Align to Pixel Grid Align to Pixel Grid Sejajarkan ke grid piksel @msg side is left or right, not `{s}` side adalah left atau right, bukan `{s}` + +# #5804 native-picked raster editor (draft translations; native review welcome). + Edit Original with: Edit asli dengan: +file-filter Applications Aplikasi diff --git a/crates/ui-egui/src/i18n/it.tsv b/crates/ui-egui/src/i18n/it.tsv index 2e197ede67..74ff7365cb 100644 --- a/crates/ui-egui/src/i18n/it.tsv +++ b/crates/ui-egui/src/i18n/it.tsv @@ -6280,3 +6280,7 @@ breakText Glyphs Glifi Align to Pixel Grid Allinea alla griglia pixel @msg only paths and compound paths can be aligned to the pixel grid solo i tracciati e i tracciati composti possono essere allineati alla griglia pixel @msg side is left or right, not `{s}` side è left o right, non `{s}` + +# #5804 native-picked raster editor (draft translations; native review welcome). + Edit Original with: Modifica originale con: +file-filter Applications Applicazioni diff --git a/crates/ui-egui/src/i18n/ja.tsv b/crates/ui-egui/src/i18n/ja.tsv index 98c1383c2b..041824149a 100644 --- a/crates/ui-egui/src/i18n/ja.tsv +++ b/crates/ui-egui/src/i18n/ja.tsv @@ -6345,3 +6345,7 @@ breakText Glyphs 字形 Align to Pixel Grid ピクセルグリッドに整合 @msg only paths and compound paths can be aligned to the pixel grid ピクセルグリッドに整合できるのはパスと複合パスのみです @msg side is left or right, not `{s}` side は left または right です(`{s}` ではありません) + +# #5804 native-picked raster editor (draft translations; native review welcome). + Edit Original with: 元のファイルを編集するアプリ: +file-filter Applications アプリケーション diff --git a/crates/ui-egui/src/i18n/ka.tsv b/crates/ui-egui/src/i18n/ka.tsv index 4c331b354a..cb0429782c 100644 --- a/crates/ui-egui/src/i18n/ka.tsv +++ b/crates/ui-egui/src/i18n/ka.tsv @@ -6720,3 +6720,7 @@ font-script Japanese იაპონური Align to Pixel Grid პიქსელურ ბადეზე გასწორება @msg only paths and compound paths can be aligned to the pixel grid პიქსელურ ბადეზე მხოლოდ ტრაექტორიების და შედგენილი ტრაექტორიების გასწორებაა შესაძლებელი @msg side is left or right, not `{s}` side არის left ან right და არა `{s}` + +# #5804 native-picked raster editor (draft translations; native review welcome). + Edit Original with: ორიგინალის რედაქტირება პროგრამით: +file-filter Applications აპლიკაციები diff --git a/crates/ui-egui/src/i18n/ko.tsv b/crates/ui-egui/src/i18n/ko.tsv index 615b1159ed..c66c964383 100644 --- a/crates/ui-egui/src/i18n/ko.tsv +++ b/crates/ui-egui/src/i18n/ko.tsv @@ -6241,3 +6241,7 @@ breakText Glyphs 글리프 Align to Pixel Grid 픽셀 격자에 정렬 @msg only paths and compound paths can be aligned to the pixel grid 패스와 컴파운드 패스만 픽셀 격자에 정렬할 수 있습니다 @msg side is left or right, not `{s}` side는 left 또는 right입니다(`{s}` 아님) + +# #5804 native-picked raster editor (draft translations; native review welcome). + Edit Original with: 원본 편집 앱: +file-filter Applications 응용 프로그램 diff --git a/crates/ui-egui/src/i18n/nl.tsv b/crates/ui-egui/src/i18n/nl.tsv index ddc5d2186d..f2b563a543 100644 --- a/crates/ui-egui/src/i18n/nl.tsv +++ b/crates/ui-egui/src/i18n/nl.tsv @@ -6492,3 +6492,7 @@ breakText Glyphs Glyphs # Align to Pixel Grid Align to Pixel Grid Uitlijnen op pixelraster @msg side is left or right, not `{s}` side is left of right, niet `{s}` + +# #5804 native-picked raster editor (draft translations; native review welcome). + Edit Original with: Origineel bewerken met: +file-filter Applications Programma’s diff --git a/crates/ui-egui/src/i18n/pl.tsv b/crates/ui-egui/src/i18n/pl.tsv index 259cab122a..95c535574c 100644 --- a/crates/ui-egui/src/i18n/pl.tsv +++ b/crates/ui-egui/src/i18n/pl.tsv @@ -6515,3 +6515,7 @@ breakText Glyphs Glify Align to Pixel Grid Wyrównaj do siatki pikseli @msg only paths and compound paths can be aligned to the pixel grid do siatki pikseli można wyrównać tylko ścieżki i ścieżki złożone @msg side is left or right, not `{s}` side to left lub right, a nie `{s}` + +# #5804 native-picked raster editor (draft translations; native review welcome). + Edit Original with: Edytuj oryginał w: +file-filter Applications Aplikacje diff --git a/crates/ui-egui/src/i18n/pt-br.tsv b/crates/ui-egui/src/i18n/pt-br.tsv index b5371fd5b4..5967070583 100644 --- a/crates/ui-egui/src/i18n/pt-br.tsv +++ b/crates/ui-egui/src/i18n/pt-br.tsv @@ -6732,3 +6732,7 @@ swatch Yellow Green Verde-amarelado Align to Pixel Grid Alinhar à Grade de Pixels @msg only paths and compound paths can be aligned to the pixel grid somente caminhos e caminhos compostos podem ser alinhados à grade de pixels @msg side is left or right, not `{s}` side é left ou right, não `{s}` + +# #5804 native-picked raster editor (draft translations; native review welcome). + Edit Original with: Editar original com: +file-filter Applications Aplicativos diff --git a/crates/ui-egui/src/i18n/ru.tsv b/crates/ui-egui/src/i18n/ru.tsv index 5ada469cc3..396537022d 100644 --- a/crates/ui-egui/src/i18n/ru.tsv +++ b/crates/ui-egui/src/i18n/ru.tsv @@ -6748,3 +6748,7 @@ shape Open Открытый Align to Pixel Grid Выровнять по пиксельной сетке @msg only paths and compound paths can be aligned to the pixel grid по пиксельной сетке можно выровнять только контуры и составные контуры @msg side is left or right, not `{s}` side — это left или right, а не `{s}` + +# #5804 native-picked raster editor (draft translations; native review welcome). + Edit Original with: Редактировать оригинал в: +file-filter Applications Приложения diff --git a/crates/ui-egui/src/i18n/sv.tsv b/crates/ui-egui/src/i18n/sv.tsv index b857c0bd29..10c8d7ac70 100644 --- a/crates/ui-egui/src/i18n/sv.tsv +++ b/crates/ui-egui/src/i18n/sv.tsv @@ -8144,3 +8144,7 @@ digits Hindi Hindi Align to Pixel Grid Justera mot pixelrutnät @msg only paths and compound paths can be aligned to the pixel grid bara banor och sammansatta banor kan justeras mot pixelrutnätet @msg side is left or right, not `{s}` side är left eller right, inte `{s}` + +# #5804 native-picked raster editor (draft translations; native review welcome). + Edit Original with: Redigera original med: +file-filter Applications Program diff --git a/crates/ui-egui/src/i18n/tr.tsv b/crates/ui-egui/src/i18n/tr.tsv index 14238fd476..14f5305dfd 100644 --- a/crates/ui-egui/src/i18n/tr.tsv +++ b/crates/ui-egui/src/i18n/tr.tsv @@ -6615,3 +6615,7 @@ breakText Glyphs Glifler Align to Pixel Grid Piksel Izgarasına Hizala @msg only paths and compound paths can be aligned to the pixel grid piksel ızgarasına yalnızca yollar ve bileşik yollar hizalanabilir @msg side is left or right, not `{s}` side left veya right olmalıdır, `{s}` değil + +# #5804 native-picked raster editor (draft translations; native review welcome). + Edit Original with: Orijinali şununla düzenle: +file-filter Applications Uygulamalar diff --git a/crates/ui-egui/src/i18n/uk.tsv b/crates/ui-egui/src/i18n/uk.tsv index f9dfd2d30f..50eda30cea 100644 --- a/crates/ui-egui/src/i18n/uk.tsv +++ b/crates/ui-egui/src/i18n/uk.tsv @@ -6260,3 +6260,7 @@ breakText Glyphs Гліфи Align to Pixel Grid Вирівняти за піксельною сіткою @msg only paths and compound paths can be aligned to the pixel grid за піксельною сіткою можна вирівняти лише контури і складені контури @msg side is left or right, not `{s}` side — це left або right, а не `{s}` + +# #5804 native-picked raster editor (draft translations; native review welcome). + Edit Original with: Редагувати оригінал у: +file-filter Applications Програми diff --git a/crates/ui-egui/src/i18n/vi.tsv b/crates/ui-egui/src/i18n/vi.tsv index 31a0d99ffd..092ebff011 100644 --- a/crates/ui-egui/src/i18n/vi.tsv +++ b/crates/ui-egui/src/i18n/vi.tsv @@ -6261,3 +6261,7 @@ breakText Glyphs Glyph Align to Pixel Grid Căn theo lưới pixel @msg only paths and compound paths can be aligned to the pixel grid chỉ đường dẫn và đường dẫn phức mới căn theo lưới pixel được @msg side is left or right, not `{s}` side là left hoặc right, không phải `{s}` + +# #5804 native-picked raster editor (draft translations; native review welcome). + Edit Original with: Chỉnh sửa bản gốc bằng: +file-filter Applications Ứng dụng diff --git a/crates/ui-egui/src/i18n/zh-hans.tsv b/crates/ui-egui/src/i18n/zh-hans.tsv index 82e3ed58a4..fb4440bd06 100644 --- a/crates/ui-egui/src/i18n/zh-hans.tsv +++ b/crates/ui-egui/src/i18n/zh-hans.tsv @@ -6500,3 +6500,7 @@ breakText Glyphs 字形 Align to Pixel Grid 对齐像素网格 @msg only paths and compound paths can be aligned to the pixel grid 只有路径和复合路径可以对齐像素网格 @msg side is left or right, not `{s}` side 应为 left 或 right,而不是 `{s}` + +# #5804 native-picked raster editor (draft translations; native review welcome). + Edit Original with: 编辑原稿所用应用: +file-filter Applications 应用程序 diff --git a/crates/ui-egui/src/i18n/zh-hant.tsv b/crates/ui-egui/src/i18n/zh-hant.tsv index e65d4a84f3..c5a615f85d 100644 --- a/crates/ui-egui/src/i18n/zh-hant.tsv +++ b/crates/ui-egui/src/i18n/zh-hant.tsv @@ -6298,3 +6298,7 @@ breakText Glyphs 字符 Align to Pixel Grid 對齊像素格點 @msg only paths and compound paths can be aligned to the pixel grid 只有路徑和複合路徑可以對齊像素格點 @msg side is left or right, not `{s}` side 應為 left 或 right,而不是 `{s}` + +# #5804 native-picked raster editor (draft translations; native review welcome). + Edit Original with: 編輯原稿所用應用程式: +file-filter Applications 應用程式 diff --git a/crates/ui-egui/src/io/export.rs b/crates/ui-egui/src/io/export.rs index 562dc0e00a..349f0ebddb 100644 --- a/crates/ui-egui/src/io/export.rs +++ b/crates/ui-egui/src/io/export.rs @@ -223,11 +223,14 @@ pub(crate) fn open_in_app(app: &mut VectorcraftApp, path: &str) -> Result<(), St } /// Edit Original: open `path` in the system's default app for it, or with Preferences › File -/// Handling › Use System Defaults for Edit Original off, in the app that made it (#5236): PhotoCraft -/// for a raster image where it is installed. Any other file, or no PhotoCraft, uses the system's app. +/// Handling › Use System Defaults for Edit Original off, in a native-picked raster editor (#5804), +/// then PhotoCraft where installed (#5236). Other files, or no installed editor, use the system's app. pub(crate) fn open_original(app: &mut VectorcraftApp, path: &str) -> Result<(), String> { let ext = std::path::Path::new(path).extension().map(|e| e.to_string_lossy().into_owned()).unwrap_or_default(); let raster = vectorcraft_engine::cmd::fileio::readable_format(&ext).is_some_and(|f| f.raster); + if !app.session.prefs.edit_original_system_defaults && raster && crate::original_editor::try_open(app, path)? { + return Ok(()); + } if !app.session.prefs.edit_original_system_defaults && raster && let Some(open) = app.services.open_in_photocraft.as_mut() diff --git a/crates/ui-egui/src/lib.rs b/crates/ui-egui/src/lib.rs index 03acb7597e..ac7c20f0ca 100644 --- a/crates/ui-egui/src/lib.rs +++ b/crates/ui-egui/src/lib.rs @@ -53,6 +53,9 @@ pub mod layout_migration; pub mod menus; pub mod native_menu; pub mod opening; +mod original_editor; +#[doc(hidden)] +pub use original_editor::Choice as OriginalEditorChoice; pub mod palette; mod panel_docking; pub mod panels; @@ -235,6 +238,7 @@ pub struct VectorcraftApp { clipboard_probe: Option, /// File dialogs shown off the UI thread and what runs again with their answers. pub(crate) picks: picks::Picks, + pub(crate) original_editor: original_editor::Draft, /// The screen color sampler shown and not answered yet, and where its color goes. pub(crate) screen_sampler: Option, /// The look for fonts installed or removed meanwhile, running diff --git a/crates/ui-egui/src/original_editor.rs b/crates/ui-egui/src/original_editor.rs new file mode 100644 index 0000000000..b5fe1a6b2b --- /dev/null +++ b/crates/ui-egui/src/original_editor.rs @@ -0,0 +1,254 @@ +//! The raster editor is selected by a person in a native picker, never by a preference command +//! or a generic dialog field. Keep both the saved choice and the dialog's draft opaque. + +use serde::{Deserialize, Serialize}; + +use crate::{FilePick, VectorcraftApp, state::Dialog}; + +/// Opaque saved choice. Public so hosts can construct `UiState` with a struct update; its path +/// has no public setter and is never read from the generic preference or dialog-field maps. +#[derive(Clone, Debug, Default, Serialize, Deserialize)] +pub struct Choice { + path: Option, +} + +#[derive(Default)] +pub(crate) struct Draft { + choice: Choice, + generation: u64, +} + +pub(crate) fn open(app: &mut VectorcraftApp) { + app.original_editor.generation = app.original_editor.generation.wrapping_add(1); + app.original_editor.choice = app.ui.original_editor.clone(); +} + +pub(crate) fn commit(app: &mut VectorcraftApp) { + app.ui.original_editor = app.original_editor.choice.clone(); +} + +pub(crate) fn reset(app: &mut VectorcraftApp) { + app.original_editor.choice = Choice::default(); + // Discard an outstanding pick when Reset was pressed while its dialog was open. + app.original_editor.generation = app.original_editor.generation.wrapping_add(1); +} + +pub(crate) fn cancel(app: &mut VectorcraftApp) { + open(app); +} + +/// A chosen app may have been removed since Preferences saved it. Only absence falls through; +/// validation and launch failures are errors, as they are for PhotoCraft. +pub(crate) fn try_open(app: &mut VectorcraftApp, path: &str) -> Result { + let Some(editor) = app.ui.original_editor.path.as_deref() else { return Ok(false) }; + let Some(open) = app.services.open_in_application.as_mut() else { return Ok(false) }; + open(editor, path) +} + +fn pick(app: &mut VectorcraftApp, d: &mut Dialog) -> Result<(), String> { + app.refuse_automation("preferences.chooseOriginalEditor")?; + let generation = app.original_editor.generation; + crate::picks::in_app_dialog(app, d, move |app, _| { + if generation != app.original_editor.generation { + return Ok(()); + } + let filters = if cfg!(target_os = "macos") { + vec![FilePick::filter("Applications", &["app"])] + } else if cfg!(windows) { + vec![FilePick::filter("Applications", &["exe"])] + } else { + Vec::new() + }; + let Some(path) = crate::picks::open(app, &FilePick { filters, ..Default::default() }) else { return Ok(()) }; + app.services.check_application.as_ref().ok_or("no application chooser here")?(&path)?; + app.original_editor.choice.path = Some(path); + Ok(()) + }) +} + +pub(crate) fn show(ui: &mut egui::Ui, app: &mut VectorcraftApp, d: &mut Dialog) { + if app.services.check_application.is_none() || app.services.open_in_application.is_none() { + return; + } + ui.add_enabled_ui(!d.bool("editOriginalSystemDefaults"), |ui| { + ui.horizontal_wrapped(|ui| { + ui.label(tl!("Edit Original with:")); + let name = app.original_editor.choice.path.as_deref().and_then(|p| std::path::Path::new(p).file_name()); + ui.label(name.map(|n| n.to_string_lossy().into_owned()).unwrap_or_else(|| "PhotoCraft".into())); + if ui.button(tl!("Choose…")).clicked() + && let Err(e) = pick(app, d) + { + app.status(e); + } + if app.original_editor.choice.path.is_some() && ui.button("PhotoCraft").clicked() { + reset(app); + } + }); + }); +} + +#[cfg(test)] +mod tests { + use super::*; + use crate::{ + Services, + control::{ControlRequest, Outcome}, + prefs_dialog, + }; + use serde_json::{Value, json}; + use std::{cell::RefCell, rc::Rc}; + + fn app() -> VectorcraftApp { + let services = Services { + check_application: Some(Box::new(|p| if p == "/Apps/Bad" { Err("not an application".into()) } else { Ok(()) })), + open_in_application: Some(Box::new(|_, _| Ok(true))), + ..Default::default() + }; + let mut app = VectorcraftApp::new(vectorcraft_engine::Session::new(), services); + prefs_dialog::open(&mut app, Some("File Handling")); + app + } + + fn choose(app: &mut VectorcraftApp, path: Option<&str>) -> Result<(), String> { + let path = path.map(str::to_owned); + app.services.pick_open = Some(Box::new(move |_| path.clone())); + let mut d = app.ui.dialog.take().unwrap(); + let r = pick(app, &mut d); + app.ui.dialog = Some(d); + r + } + + fn request(app: &mut VectorcraftApp, method: &str, params: Value) -> Value { + let (req, _) = ControlRequest::new(method, params); + let Outcome::Done(r) = crate::control::handle(app, &egui::Context::default(), &req) else { panic!("deferred") }; + r + } + + #[test] + fn native_choice_commits_persists_cancels_and_resets() { + let mut app = app(); + choose(&mut app, Some("/Apps/My Editor.app")).unwrap(); + assert!(app.ui.original_editor.path.is_none(), "a draft until OK"); + prefs_dialog::confirm(&mut app).unwrap(); + let saved = serde_json::to_vec(&app.ui).unwrap(); + let restored: crate::UiState = serde_json::from_slice(&saved).unwrap(); + assert_eq!(restored.original_editor.path.as_deref(), Some("/Apps/My Editor.app")); + assert!(app.session.prefs.to_json().get("original_editor").is_none()); + assert!(app.take_prefs_changed(), "OK asks the host to persist the choice"); + prefs_dialog::open(&mut app, Some("File Handling")); + choose(&mut app, None).unwrap(); + assert_eq!(app.original_editor.choice.path, restored.original_editor.path); + choose(&mut app, Some("/Apps/Other Editor.app")).unwrap(); + crate::dialogs::cancel(&mut app); + prefs_dialog::open(&mut app, Some("File Handling")); + assert_eq!(app.original_editor.choice.path, restored.original_editor.path); + assert!(choose(&mut app, Some("/Apps/Bad")).is_err()); + assert_eq!(app.original_editor.choice.path, restored.original_editor.path); + reset(&mut app); + prefs_dialog::confirm(&mut app).unwrap(); + assert!(app.ui.original_editor.path.is_none()); + let legacy: crate::UiState = serde_json::from_str("{}").unwrap(); + assert!(legacy.original_editor.path.is_none()); + } + + #[test] + fn original_editor_routing_and_errors() { + let mut app = app(); + choose(&mut app, Some("/Apps/My Editor.app")).unwrap(); + prefs_dialog::confirm(&mut app).unwrap(); + let calls = Rc::new(RefCell::new(Vec::new())); + let c = calls.clone(); + app.services.open_file = Some(Box::new(move |_| { + c.borrow_mut().push("system"); + Ok(()) + })); + let c = calls.clone(); + app.services.open_in_photocraft = Some(Box::new(move |_| { + c.borrow_mut().push("photocraft"); + Ok(true) + })); + let c = calls.clone(); + app.services.open_in_application = Some(Box::new(move |editor, path| { + assert_eq!(editor, "/Apps/My Editor.app"); + assert_eq!(path, "/Art/a b.png"); + c.borrow_mut().push("chosen"); + Ok(true) + })); + crate::io::open_original(&mut app, "/Art/a b.png").unwrap(); + app.session.prefs.edit_original_system_defaults = false; + crate::io::open_original(&mut app, "/Art/a b.png").unwrap(); + crate::io::open_original(&mut app, "/Art/plan.emf").unwrap(); + app.services.open_in_application = Some(Box::new(|_, _| Ok(false))); + crate::io::open_original(&mut app, "/Art/a b.png").unwrap(); + app.services.open_in_photocraft = Some(Box::new(|_| Ok(false))); + crate::io::open_original(&mut app, "/Art/a b.png").unwrap(); + app.services.open_in_application = Some(Box::new(|_, _| Err("launch failed".into()))); + assert_eq!(crate::io::open_original(&mut app, "/Art/a b.png").unwrap_err(), "launch failed"); + assert_eq!(*calls.borrow(), ["system", "chosen", "system", "photocraft", "system"]); + } + + #[test] + fn automation_cannot_inject_an_original_editor() { + let mut app = app(); + for key in ["editOriginalApp", "original_editor", "__originalEditor", "__chosenApp"] { + let r = request(&mut app, "engine.execute", json!({"command": "prefs.set", "params": {"key": key, "value": "/Apps/Bad"}})); + assert_eq!(r["ok"], false, "{r}"); + let r = request(&mut app, "engine.execute", json!({"command": "prefs.set", "params": {"values": {key: "/Apps/Bad"}}})); + assert_eq!(r["ok"], false, "{r}"); + // __ fields are accepted by generic dialogs, but they cannot become a trusted choice. + let _ = request(&mut app, "ui.dialog.set", json!({"field": key, "value": "/Apps/Bad"})); + } + let r = request(&mut app, "engine.execute", json!({"command": "prefs.setValues", "params": {"values": {"editOriginalApp": "/Apps/Bad"}}})); + assert_eq!(r["ok"], false, "{r}"); + let _ = request(&mut app, "ui.set", json!({"original_editor": {"path": "/Apps/Bad"}})); + let r = request(&mut app, "ui.dialog.confirm", json!({})); + assert_eq!(r["ok"], true, "{r}"); + assert!(app.ui.original_editor.path.is_none()); + prefs_dialog::open(&mut app, Some("File Handling")); + app.ui.answering_control = true; + assert!(choose(&mut app, Some("/Apps/Bad")).is_err()); + app.ui.answering_control = false; + app.synthetic_frame = true; + assert!(choose(&mut app, Some("/Apps/Bad")).is_err()); + assert!(app.original_editor.choice.path.is_none()); + } + + #[test] + fn original_editor_async_picker_validates_and_commits_only_on_ok() { + let mut app = app(); + let (tx, rx) = std::sync::mpsc::channel(); + let mut rx = Some(rx); + app.services.start_pick = Some(Box::new(move |_| rx.take())); + choose(&mut app, None).unwrap(); + tx.send(vec!["/Apps/Async Editor.app".into()]).unwrap(); + crate::picks::poll(&mut app, &egui::Context::default()); + assert_eq!(app.original_editor.choice.path.as_deref(), Some("/Apps/Async Editor.app")); + assert!(app.ui.original_editor.path.is_none()); + prefs_dialog::confirm(&mut app).unwrap(); + assert_eq!(app.ui.original_editor.path.as_deref(), Some("/Apps/Async Editor.app")); + } + + #[test] + fn original_editor_picker_answer_does_not_survive_reopening_preferences() { + let mut app = app(); + let (tx, rx) = std::sync::mpsc::channel(); + let mut rx = Some(rx); + app.services.start_pick = Some(Box::new(move |_| rx.take())); + choose(&mut app, None).unwrap(); + crate::dialogs::cancel(&mut app); + prefs_dialog::open(&mut app, Some("File Handling")); + tx.send(vec!["/Apps/Stale.app".into()]).unwrap(); + crate::picks::poll(&mut app, &egui::Context::default()); + assert!(app.original_editor.choice.path.is_none()); + } + + #[test] + fn original_editor_controls_are_desktop_only_and_draw_the_choice() { + let mut app = app(); + let text = crate::tests_labels::painted_text(&mut app, |a, ui| prefs_dialog::show(a, ui.ctx())); + assert!(text.contains("Edit Original with:") && text.contains("PhotoCraft"), "{text}"); + app.services.check_application = None; + let text = crate::tests_labels::painted_text(&mut app, |a, ui| prefs_dialog::show(a, ui.ctx())); + assert!(!text.contains("Edit Original with:"), "{text}"); + } +} diff --git a/crates/ui-egui/src/panels/tests_links.rs b/crates/ui-egui/src/panels/tests_links.rs index 215cf7148a..fa514fef35 100644 --- a/crates/ui-egui/src/panels/tests_links.rs +++ b/crates/ui-egui/src/panels/tests_links.rs @@ -206,6 +206,20 @@ fn edit_original_opens_raster_images_in_photocraft_without_system_defaults() { assert_eq!(opened.borrow().len(), 4); } +#[test] +fn edit_original_with_chosen_editor_still_refuses_automation() { + let dir = Folder::new("chosen-automation"); + let (mut app, linked, _) = app(&dir); + app.ui.original_editor = serde_json::from_value(json!({"path": "/Apps/Editor.exe"})).unwrap(); + app.session.prefs.edit_original_system_defaults = false; + app.services.open_in_application = Some(Box::new(|_, _| panic!("automation must not launch an editor"))); + app.ui.answering_control = true; + assert!(app.run("links.editOriginal", json!({"id": linked})).unwrap_err().contains("only the person")); + app.ui.answering_control = false; + app.synthetic_frame = true; + assert!(app.run("links.editOriginal", json!({"id": linked})).unwrap_err().contains("only the person")); +} + /// Edit Original hands only regular image and document files to the system's default app. #[test] fn edit_original_opens_image_and_document_files_only() { diff --git a/crates/ui-egui/src/prefs_dialog.rs b/crates/ui-egui/src/prefs_dialog.rs index fad2d45e7a..89239f63a5 100644 --- a/crates/ui-egui/src/prefs_dialog.rs +++ b/crates/ui-egui/src/prefs_dialog.rs @@ -24,6 +24,7 @@ pub const UI_FIELDS: &[(&str, &str, &str)] = &[ const APP_TITLE_BAR_SHOWN: bool = cfg!(not(any(target_arch = "wasm32", target_os = "macos", target_os = "windows"))); pub fn open(app: &mut VectorcraftApp, category: Option<&str>) { + crate::original_editor::open(app); // One field per preference key or group (the flattener presets have commands of their own). let mut fields: Map = app.session.prefs.to_json().as_object().cloned().unwrap_or_default(); fields.retain(|k, _| vectorcraft_engine::cmd::prefscmds::spec(k).is_some() || PREF_GROUPS.contains(&k.as_str())); @@ -206,6 +207,7 @@ pub fn confirm(app: &mut VectorcraftApp) -> Result { app.ui.view.smart_guides = d.fields.get("__smartGuides").and_then(Value::as_bool).unwrap_or(app.ui.view.smart_guides); app.ui.view.snap_to_grid = d.fields.get("__snapToGrid").and_then(Value::as_bool).unwrap_or(app.ui.view.snap_to_grid); app.ui.task_bar = d.fields.get("__taskBar").and_then(Value::as_bool).unwrap_or(app.ui.task_bar); + crate::original_editor::commit(app); app.ui.dialog = None; app.ui.engine_prefs = app.session.prefs.to_json(); app.prefs_changed = true; @@ -415,6 +417,7 @@ pub fn show(app: &mut VectorcraftApp, ctx: &egui::Context) { }); }); if reset { + crate::original_editor::reset(app); for (k, v) in Prefs::default().to_json().as_object().cloned().unwrap_or_default() { d.fields.insert(k, v); } @@ -427,6 +430,7 @@ pub fn show(app: &mut VectorcraftApp, ctx: &egui::Context) { } app.ui.dialog = Some(d); if cancel { + crate::original_editor::cancel(app); app.ui.dialog = None; } else if ok && let Err(e) = confirm(app) { app.status(e); @@ -513,6 +517,10 @@ fn category_fields(ui: &mut egui::Ui, app: &mut VectorcraftApp, d: &mut Dialog, ui.label(egui::RichText::new(note).color(t.text_dim).size(11.0)); } } + PrefKind::Bool if sp.key == "editOriginalSystemDefaults" => { + bool_row(ui, d, sp.key, sp.label); + crate::original_editor::show(ui, app, d); + } PrefKind::Bool => bool_row(ui, d, sp.key, sp.label), PrefKind::Num { min, max, unit } => { labeled(ui, sp.label, |ui, label_id| { diff --git a/crates/ui-egui/src/services.rs b/crates/ui-egui/src/services.rs index 47374c7e69..0ca8da47ae 100644 --- a/crates/ui-egui/src/services.rs +++ b/crates/ui-egui/src/services.rs @@ -31,6 +31,9 @@ impl FilePick { } } +pub type CheckApplicationFn = Box Result<(), String>>; +pub type OpenApplicationFn = Box Result>; + pub type PickOpen = Box Option>; pub type PickSave = Box Option>; @@ -131,6 +134,10 @@ pub struct Services { /// with Preferences › File Handling › Use System Defaults for Edit Original off); `Ok(false)` /// when it isn't. Without it Edit Original uses `open_file`. pub open_in_photocraft: Option, + /// Validate a native-picked application before keeping it as the raster editor. + pub check_application: Option, + /// Launch a native-picked application with one file argument; false only when absent. + pub open_in_application: Option, /// Show a folder picker; returns its path (desktop: Relink to Folder, Package). pub pick_folder: Option Option>>, /// Show the system's color sampler, which picks a color anywhere on the screen (macOS, and diff --git a/crates/ui-egui/src/state.rs b/crates/ui-egui/src/state.rs index 95ffcd9cd6..6c5ef52b98 100644 --- a/crates/ui-egui/src/state.rs +++ b/crates/ui-egui/src/state.rs @@ -585,6 +585,9 @@ pub struct UiState { /// Engine preferences (Edit → Preferences), persisted alongside the UI state. #[serde(default)] pub engine_prefs: Value, + /// Native-picker-only raster editor; never exposed as an engine preference or dialog field. + #[serde(default)] + pub original_editor: crate::OriginalEditorChoice, /// Color Guide panel: variation kind, steps and amount (Color Guide Options). #[serde(default)] pub color_guide: vectorcraft_color::harmony::GuideOptions, @@ -1053,6 +1056,7 @@ impl Default for UiState { recent_fonts: vec![], favorite_fonts: vec![], engine_prefs: Value::Null, + original_editor: Default::default(), color_guide: Default::default(), library_panels: vec![], flattener_preview: Default::default(), diff --git a/docs/control-protocol.md b/docs/control-protocol.md index 2cb542c6b2..01d79105ea 100644 --- a/docs/control-protocol.md +++ b/docs/control-protocol.md @@ -1,6 +1,6 @@ # Control protocol -> **Last updated:** 2026-10-31 · **Change:** Confining file access refuses a `:` in a name after the drive on Windows, an NTFS alternate data stream such as `x.svg:evil` (#3604); previously: Object → Expand… dimmed while the selection has an appearance Expand Appearance expands (`object.expand.info`'s `appearance`, #3089); previously: brush library panels (`window.brushLibrary`, `window.brushLibrary.other`, `ui.saveBrushLibrary`); previously: Transform Each opens on the values it was last confirmed with; its Copy button confirms with `copy: true` (#1732); previously: panel docking on craft-ui's layout: `ui.docking`, the parameters of `window.panel.float` and `window.panel.dock`; previously: `ui.screenshot`'s 64 MiB inline-PNG cap and its path-plus-data downgrade; symbol library panels (`window.symbolLibrary`, `window.symbolLibrary.other`, `ui.saveSymbolLibrary`); synthetic input budgets (#1709); bounded transport waits (#1726). +> **Last updated:** 2026-11-09 · **Change:** #5804 draft private raster-editor selection; previously: Confining file access refuses a `:` in a name after the drive on Windows, an NTFS alternate data stream such as `x.svg:evil` (#3604); previously: Object → Expand… dimmed while the selection has an appearance Expand Appearance expands (`object.expand.info`'s `appearance`, #3089); previously: brush library panels (`window.brushLibrary`, `window.brushLibrary.other`, `ui.saveBrushLibrary`); previously: Transform Each opens on the values it was last confirmed with; its Copy button confirms with `copy: true` (#1732); previously: panel docking on craft-ui's layout: `ui.docking`, the parameters of `window.panel.float` and `window.panel.dock`; previously: `ui.screenshot`'s 64 MiB inline-PNG cap and its path-plus-data downgrade; symbol library panels (`window.symbolLibrary`, `window.symbolLibrary.other`, `ui.saveSymbolLibrary`); synthetic input budgets (#1709); bounded transport waits (#1726). `vectorcraft --control ` listens on `127.0.0.1:` (loopback only). The port must be a number from 1 to 65535 (`--control=` works too), given once; otherwise the app prints an error and exits @@ -728,6 +728,8 @@ PhotoCraft, looked for only where it installs (the Applications folders on macOS registers under App Paths, then `ArtCraft\PhotoCraft` in the per-user and per-machine program folders, then the `PATH`; the `PATH` elsewhere), and any other file, or a raster image without PhotoCraft installed, in the system's default app. +Draft #5804 adds a local, native-picker-only raster editor override when Use System Defaults is off. Its saved choice and Preferences draft are outside engine preferences and `Dialog::fields`: `prefs.set` (including bulk values), `ui.dialog.set` and `ui.set` cannot assign it. The chooser refuses control requests and synthetic input. If the chosen application is missing, Edit Original tries PhotoCraft and then the system default; validation or launch errors are reported. The existing refusal of automated external Edit Original remains. No executable arguments or shell command are accepted. + Package: File → Package… (`ui.packageDialog`) opens the `package` dialog for a saved document (a document never saved gets a `confirm` dialog whose OK runs `file.saveAs`). Fields: `folder` (the location), `name` (the package folder), `copyLinks`, `linksFolder`, `relink`, `copyFonts`, `report`. `ui.dialog.confirm` saves unsaved changes, runs diff --git a/docs/gaps.md b/docs/gaps.md index 37d4c1c28f..36720df5dc 100644 --- a/docs/gaps.md +++ b/docs/gaps.md @@ -1,9 +1,13 @@ # Gaps -> **Last reviewed:** 2026-10-10 · **Last updated:** 2026-11-09 · **Change:** minor (spell check engine: `text.spelling.check` and `text.spelling.suggest` on craft-proof, #4936; previously minor: floating tab groups collapse into the side icon rail and opened rail panels fold back into it, #5925 in part; G9: EPS gradients drawn as abutting strips import as one gradient, without seams; Tools stays beside the canvas with left-side panels; new gradients follow document color mode; Selection QoL: marquee modes and visible feedback, #5313; #3380 deletion-only review follow-up: independent survivors keep gradient placement, owned subpaths avoid discarded copies, and contracts/status/evidence are clarified; endpoint highlighting remains open; scores and estimates unchanged; Indian-language hyphenation review and license allowlist, #4947; opening a slow file shows a progress window, part of #5930; Hindi catalog and contributor loanword preferences; agent wording pass complete; wider native proofreading welcome; an image zoomed in on is separated, colorized or proofed only where it shows (#4155); scores and estimates unchanged; a document's first frame renders on the render worker, so opening a heavy file no longer freezes the window; scores and estimates unchanged; large images in CMYK documents are shrunk before they are separated into ink planes (#4155); scores and estimates unchanged; `.ai` paths with a Calligraphic brush open brushed, with the 6D Art Pen's channels, and Windows reads the pen's tilt and barrel rotation, #372; scores and estimates unchanged; Compound Shapes add-on, beyond Illustrator; scores and estimates unchanged; Contour add-on, beyond Illustrator; scores and estimates unchanged; a slow first frame is waited for instead of restarting without the graphics adapter, and the menu bar no longer waits for the installed fonts' scan; scores and estimates unchanged) · **Target:** Adobe Illustrator 2026 (30.x) +> **Last reviewed:** 2026-10-10 · **Last updated:** 2026-11-09 · **Change:** minor (#5804 draft native-picked raster editor; scores and estimates unchanged; spell check engine: `text.spelling.check` and `text.spelling.suggest` on craft-proof, #4936; previously minor: floating tab groups collapse into the side icon rail and opened rail panels fold back into it, #5925 in part; G9: EPS gradients drawn as abutting strips import as one gradient, without seams; Tools stays beside the canvas with left-side panels; new gradients follow document color mode; Selection QoL: marquee modes and visible feedback, #5313; #3380 deletion-only review follow-up: independent survivors keep gradient placement, owned subpaths avoid discarded copies, and contracts/status/evidence are clarified; endpoint highlighting remains open; scores and estimates unchanged; Indian-language hyphenation review and license allowlist, #4947; opening a slow file shows a progress window, part of #5930; Hindi catalog and contributor loanword preferences; agent wording pass complete; wider native proofreading welcome; an image zoomed in on is separated, colorized or proofed only where it shows (#4155); scores and estimates unchanged; a document's first frame renders on the render worker, so opening a heavy file no longer freezes the window; scores and estimates unchanged; large images in CMYK documents are shrunk before they are separated into ink planes (#4155); scores and estimates unchanged; `.ai` paths with a Calligraphic brush open brushed, with the 6D Art Pen's channels, and Windows reads the pen's tilt and barrel rotation, #372; scores and estimates unchanged; Compound Shapes add-on, beyond Illustrator; scores and estimates unchanged; Contour add-on, beyond Illustrator; scores and estimates unchanged; a slow first frame is waited for instead of restarting without the graphics adapter, and the menu bar no longer waits for the installed fonts' scan; scores and estimates unchanged) · **Target:** Adobe Illustrator 2026 (30.x) ## Feature submission evidence +Draft enhancement #5804: Preferences › File Handling can select a raster editor through the native picker, with a private draft outside engine preferences and generic dialog fields. OK saves it, Cancel discards it, and Reset restores PhotoCraft. With Use System Defaults off, a missing chosen editor falls back to PhotoCraft, then the system default; validation and launch failures are reported. Control/MCP and synthetic input cannot choose an application or run external Edit Original. Web behavior, parity scores and estimates are unchanged; maintainer acceptance and macOS/Linux smoke tests remain pending. + +**2026-11-09 revision:** draft implementation and regression coverage for #5804; no parity rescore. + **Feature evidence last updated:** 2026-11-02. | 2026-11-06 | minor | Opening a file that takes longer than 0.4 s shows a progress window: the file name, a moving bar (reading reports no steps), how many more files wait, Cancel (Esc; the file doesn't open) and Continue in Background (`file.cancelOpen`, `file.openInBackground`); it never opens over another dialog or progress window (part of #5930); scores and estimates unchanged | Raster rendering fits and preflattens curved stroke outlines more tightly only below four times the raster tolerance, retaining thin-band coverage without changing stroke weight or vector export geometry. Current cached character/object outlines, cropped long strokes, gradient clips and effect rasters share the helper; cropped-region reuse and guarded flattening remain. The unchanged `fractional_curved_strokes_retain_coverage_between_notches` regression covers fractional weights, rotation, phase, opacity and f32-rounded endpoints. This is a quality/cost tradeoff, not a speed claim. Scores and estimates unchanged. diff --git a/docs/mcp.md b/docs/mcp.md index 45ddabf8f4..ff696d15b1 100644 --- a/docs/mcp.md +++ b/docs/mcp.md @@ -5011,6 +5011,8 @@ except for a placed document, which opens in a tab. With the preference `editOri File Handling › Use System Defaults for Edit Original, on by default) off, Edit Original opens a raster image in the app that made it, PhotoCraft, where it is installed, and anything else in the system's default app (#5236). +Draft #5804 adds a local, native-picker-only raster editor override when Use System Defaults is off. Its saved choice and Preferences draft are outside engine preferences and `Dialog::fields`: `prefs.set` (including bulk values), `ui.dialog.set` and `ui.set` cannot assign it. The chooser refuses control requests and synthetic input. If the chosen application is missing, Edit Original tries PhotoCraft and then the system default; validation or launch errors are reported. The existing refusal of automated external Edit Original remains. No executable arguments or shell command are accepted. + ```json {"name":"run_command","arguments":{"command":"links.list","params":{"show":"missing"}}} {"name":"run_command","arguments":{"command":"links.placementOptions","params":{"ids":[12],"preserve":"fit","align":"top"}}} diff --git a/docs/roadmap.md b/docs/roadmap.md index 9763fc230c..f6d1ea87f8 100644 --- a/docs/roadmap.md +++ b/docs/roadmap.md @@ -1,9 +1,13 @@ # Roadmap: milestones and what's next -> **Last reviewed:** 2026-10-10 · **Last updated:** 2026-11-09 · **Change:** minor (spell check engine: `text.spelling.check` and `text.spelling.suggest` on craft-proof, #4936; previously minor: floating tab groups collapse into the side icon rail and opened rail panels fold back into it, #5925 in part; M4/M7: `.ai`/EPS type keeps its tab stops, and right-aligned lines with tabs lay out as the file's page, #6147; M4/M7: `.ai`/EPS type from the text document lays its lines out closer to the file's page, within limits, #6137; numeric fields step on wheel hover without taking keyboard focus, #5949; Character Styles panel: a double-click on a style's row opens its Character Style Options; the dialog keeps a fixed width and scrolls its sections, so its buttons stay on screen; Selection QoL: marquee modes and visible feedback, #5313; SVG CSS classes survive export and repeated import in all four styling modes (#2480); current-main integration retains event attributes and scripts; #3380 deletion-only review follow-up: independent survivors keep gradient placement, owned subpaths avoid discarded copies, and contracts/status/evidence are clarified; endpoint highlighting remains open; scores and estimates unchanged; Indian-language hyphenation review and license allowlist, #4947; Hindi catalog and contributor loanword preferences; full wording review in progress; Effect dialogs: a colour swatch beside a hex colour opens the Color Picker, #5365; shape tools move the selection from its centre point and turn it from the zone outside a box corner, #5477; scores and estimates unchanged) · **Target:** Adobe Illustrator 2026 (30.x) +> **Last reviewed:** 2026-10-10 · **Last updated:** 2026-11-09 · **Change:** minor (#5804 draft native-picked raster editor; scores and estimates unchanged; spell check engine: `text.spelling.check` and `text.spelling.suggest` on craft-proof, #4936; previously minor: floating tab groups collapse into the side icon rail and opened rail panels fold back into it, #5925 in part; M4/M7: `.ai`/EPS type keeps its tab stops, and right-aligned lines with tabs lay out as the file's page, #6147; M4/M7: `.ai`/EPS type from the text document lays its lines out closer to the file's page, within limits, #6137; numeric fields step on wheel hover without taking keyboard focus, #5949; Character Styles panel: a double-click on a style's row opens its Character Style Options; the dialog keeps a fixed width and scrolls its sections, so its buttons stay on screen; Selection QoL: marquee modes and visible feedback, #5313; SVG CSS classes survive export and repeated import in all four styling modes (#2480); current-main integration retains event attributes and scripts; #3380 deletion-only review follow-up: independent survivors keep gradient placement, owned subpaths avoid discarded copies, and contracts/status/evidence are clarified; endpoint highlighting remains open; scores and estimates unchanged; Indian-language hyphenation review and license allowlist, #4947; Hindi catalog and contributor loanword preferences; full wording review in progress; Effect dialogs: a colour swatch beside a hex colour opens the Color Picker, #5365; shape tools move the selection from its centre point and turn it from the zone outside a box corner, #5477; scores and estimates unchanged) · **Target:** Adobe Illustrator 2026 (30.x) ## Feature submission evidence +Draft enhancement #5804: Preferences › File Handling can select a raster editor through the native picker, with a private draft outside engine preferences and generic dialog fields. OK saves it, Cancel discards it, and Reset restores PhotoCraft. With Use System Defaults off, a missing chosen editor falls back to PhotoCraft, then the system default; validation and launch failures are reported. Control/MCP and synthetic input cannot choose an application or run external Edit Original. Web behavior, parity scores and estimates are unchanged; maintainer acceptance and macOS/Linux smoke tests remain pending. + +**2026-11-09 revision:** draft implementation and regression coverage for #5804; no parity rescore. + Numeric fields step on wheel hover without taking keyboard focus (#5949). Arrow keys still require focus; modifiers, units, limits, mixed values and existing rounding stay in the shared stepping path. Headless regressions in `tests/numfields.rs` cover hovered unfocused fields, focused fields, trackpad accumulation and panel scroll exclusion. Scores and estimates unchanged. Raster rendering fits and preflattens curved stroke outlines more tightly only below four times the raster tolerance, retaining thin-band coverage without changing stroke weight or vector export geometry. Current cached character/object outlines, cropped long strokes, gradient clips and effect rasters share the helper; cropped-region reuse and guarded flattening remain. The unchanged `fractional_curved_strokes_retain_coverage_between_notches` regression covers fractional weights, rotation, phase, opacity and f32-rounded endpoints. This is a quality/cost tradeoff, not a speed claim. Scores and estimates unchanged. @@ -133,7 +137,7 @@ native wording review, layout checks and a web Devanagari font remain. [Notes](l | M1 | Selection, transform, layers, MCP (common command tools, strict keys, session resources and version-aware result hints) | ✅ mostly done (document-tab artwork drag with lossless resource transfer and one target Undo; malformed MCP app replies discard the connection without replay, #1761; bounded control socket waits and connection-slot recovery, #1726; bounded synthetic control input, #1709; no-op anchor Align keeps Undo, Redo and saved state (#1180 follow-up); transform reference point snaps to anchors/centres; rotated objects keep a rotated bounding box and their angle; Free Transform, Scale and Reflect along a rotated box pending; the Transform fields take one Tab each, the W/H link after them) | 4–6 | | M2 | Drawing tools + smart guides | ✅ mostly done (#3380 deletion creates independent selected path pieces and keeps bounds-fitted gradients in place; endpoint highlighting remains open; Polygon/Star exact-size count persistence, with repeated-drag, tool-switch and Cancel regression coverage; Curvature point markers without direction handles (#1236, in part); Direct Selection segment click/Delete preserves neighboring edges, #1278; Flare, Reshape, Live Corners widget dragging and per-corner radii and kinds landed, on any path's corners; Shaper rough-shape recognition and orientation steps, the remaining Pen modifier nuances; Shaper Groups with editable sources and separate fill/stroke edits landed; custom ruler origin with drag preview, active-artboard reset, relative X/Y fields and native round-trip (#1212); construction widget/refinements pending); a shape just drawn moves by its centre point and turns from the zone outside a corner with its tool still active (#5477); Tangent and straight-segment perpendicular snapping use saved Smart Guides Geometric Guides preferences and Control bar quick access (#2537); no View submenu; Copy and Cut with the Pen or Curvature tool take the anchors a Cmd/Ctrl-lent Direct Selection picked (#6123) | 12–18 | | M3 | Paint & appearance (swatches, color, gradient, stroke, appearance, transparency, styles) | ✅ done (M3.7–M3.98): swatches, groups, libraries, tints, Lab spots and Registration; Eyedropper styles highlighted text only (atomic transparency rejection); Eyedropper reads visible locked and outside-isolation sources (#1251); Color Picker, Color panel, Color Guide, Color Themes, Edit Colors and Recolor Artwork (screen-bounded Edit chip list, #3416); gradients that follow every transform, the annotator, linked stops, freeform gradients, focal points, gradients on strokes and Expand; visible strokes when paint is added to inherited None/zero-width art (#1253); stroke geometry, arrowheads, dashes fitted to corners, stroke on type, width profiles and the Width tool (Shift-double-click enables adjoining adjustment in Width Point Edit; finite-arithmetic follow-up regressions and full CI passed ([Validation evidence](target-app-parity.md#evidence-what-ships-today-by-area))), Scale Strokes and preview bounds; Appearance targeting, container appearance, target circles, Expand Appearance; knockout, isolation, blend accuracy, CMYK blending, overprint, Attributes, masks and clipping, Flatten Transparency; graphic styles, links and libraries; CSS library export preserves fractional linear and radial gradient stop positions. Left: freeform gradients in SVG/PDF, mixed spot/process gradients in SVG and PDF gradients mixing a spot color with RGB or Lab stops export as stops or process colors; PDF export writes dithered gradient fills with spot stops, and Perceptual spot gradients with RGB or Lab stops other than white or more than 4,096 stops on their curve, as images in process colors; confirm the Scale Strokes & Effects default; Recolor model selection is available through the engine and MCP only (#2520); the dialog retains its existing controls | 4–8 | -| M4 | Files (native, SVG, PDF, raster, Export for Screens, clipboard interop) | `.ai`/EPS type from the text document keeps its paragraphs' tab stops (#6147); `.ai`/EPS type from the text document keeps auto leading per line, its hyphenation options, and may show more of the last lines the file sets in an area frame of its own, when growing the frame by its lines' deepest descent plus 0.05 pt shows them (#6137); ✅ done (M4.14–M4.98 on 2026-10-05): Save As/Save a Copy/Revert/templates, Data Recovery and background save, SVG import and export fidelity (units, text, symbols, filters, SVGZ, Preserve Editing, SVG Options), shared guarded PDF writer and windowed reader ([pdf-backend.md](pdf-backend.md)), PDF import (colours, layers, masks, editable text, security) and export (presets, marks, bleed, ICC and output intent, raster effects, subset fonts, PDF/X-1a, X-3 and X-4, PDF layers, overprint, page thumbnails, fast web view, PDF 1.3), Place and Links, Package, EPS and DXF in and out (EPS legacy mesh corners, vector opacity masks and raster page comparison verified; closed SPLINE flags round-trip and circular paths export as native CIRCLE/ARC, #1299), EMF/WMF, TIFF/BMP/Targa/PSD/GIF/PNG-8 export, Print and print presets, slices, Save for Web, TIFF in Export for Screens and Asset Export, clipboard flavours, File Info; AF.1–AF.4 add Affinity import (native layers, artboards, vectors, text and images from Affinity 1–3 files; the embedded preview only as a warned fallback; AF.4 expands current `.af` fixtures and every-board round-trip validation); EPS Save and Save As keep an opened EPS as EPS with its page frame and complete editable VectorCraft document (2026-10-26; G9 import fidelity unchanged). Left: DWG (use DXF), PSD placement as layers, overprint read back from PDF, Affinity export, polish; SVG CSS classes survive export and repeated import in all four styling modes (#2480); current-main integration retains event attributes and scripts; SVG CSS classes survive export and repeated import in all four styling modes (#2480); current-main integration retains event attributes and scripts | 3–6 (existing scope; Affinity export unestimated) | +| M4 | Files (native, SVG, PDF, raster, Export for Screens, clipboard interop) | Draft #5804 adds a private native-picked raster editor for Edit Original; `.ai`/EPS type from the text document keeps its paragraphs' tab stops (#6147); `.ai`/EPS type from the text document keeps auto leading per line, its hyphenation options, and may show more of the last lines the file sets in an area frame of its own, when growing the frame by its lines' deepest descent plus 0.05 pt shows them (#6137); ✅ done (M4.14–M4.98 on 2026-10-05): Save As/Save a Copy/Revert/templates, Data Recovery and background save, SVG import and export fidelity (units, text, symbols, filters, SVGZ, Preserve Editing, SVG Options), shared guarded PDF writer and windowed reader ([pdf-backend.md](pdf-backend.md)), PDF import (colours, layers, masks, editable text, security) and export (presets, marks, bleed, ICC and output intent, raster effects, subset fonts, PDF/X-1a, X-3 and X-4, PDF layers, overprint, page thumbnails, fast web view, PDF 1.3), Place and Links, Package, EPS and DXF in and out (EPS legacy mesh corners, vector opacity masks and raster page comparison verified; closed SPLINE flags round-trip and circular paths export as native CIRCLE/ARC, #1299), EMF/WMF, TIFF/BMP/Targa/PSD/GIF/PNG-8 export, Print and print presets, slices, Save for Web, TIFF in Export for Screens and Asset Export, clipboard flavours, File Info; AF.1–AF.4 add Affinity import (native layers, artboards, vectors, text and images from Affinity 1–3 files; the embedded preview only as a warned fallback; AF.4 expands current `.af` fixtures and every-board round-trip validation); EPS Save and Save As keep an opened EPS as EPS with its page frame and complete editable VectorCraft document (2026-10-26; G9 import fidelity unchanged). Left: DWG (use DXF), PSD placement as layers, overprint read back from PDF, Affinity export, polish; SVG CSS classes survive export and repeated import in all four styling modes (#2480); current-main integration retains event attributes and scripts; SVG CSS classes survive export and repeated import in all four styling modes (#2480); current-main integration retains event attributes and scripts | 3–6 (existing scope; Affinity export unestimated) | | M3 | Paint & appearance (swatches, color, gradient, stroke, appearance, transparency, styles) | ✅ done (M3.7–M3.98): swatches, groups, libraries, tints, Lab spots and Registration; Eyedropper styles highlighted text only (atomic transparency rejection); Eyedropper reads visible locked and outside-isolation sources (#1251); Color Picker, Color panel, Color Guide, Color Themes, Edit Colors and Recolor Artwork (screen-bounded Edit chip list, #3416); gradients that follow every transform, the annotator, linked stops, freeform gradients, focal points, gradients on strokes and Expand; visible strokes when paint is added to inherited None/zero-width art (#1253); stroke geometry, arrowheads, dashes fitted to corners, stroke on type, width profiles and the Width tool (Shift-double-click enables adjoining adjustment in Width Point Edit), Scale Strokes and preview bounds; Appearance targeting, container appearance, target circles, Expand Appearance; knockout, isolation, blend accuracy, CMYK blending, overprint, Attributes, masks and clipping, Flatten Transparency; graphic styles, links and libraries; CSS library export preserves fractional linear and radial gradient stop positions. Left: freeform gradients in SVG/PDF, mixed spot/process gradients in SVG and PDF gradients mixing a spot color with RGB or Lab stops export as stops or process colors; PDF export writes dithered gradient fills with spot stops, and Perceptual spot gradients with RGB or Lab stops other than white or more than 4,096 stops on their curve, as images in process colors; confirm the Scale Strokes & Effects default | 4–8 | | M5 | Performance | 🟡 background render + caches + MT done; `vectorcraft-cli bench` and `vectorcraft-cli perf` (budget suite); opaque solid-fill knockout paths draw once in hard-edge/supersampled raster export, with analytical-AA compositing unchanged; file format v2 opens 3× faster (50k paths: 722 → 244 ms); raster effects (glows, shadows, blur, feather) no longer force the whole frame single-threaded (filtered offscreen per effect, verified equal to the single-threaded reference); Craquelure/Mosaic Tiles/Stained Glass distance searches optimized with pixel-invariance checks and the `texture_drag_perf` probe (#1257); effect-heavy demos need a clean-machine benchmark; dirty-region rendering, GPU backend spike pending | 15–25 | | M6 | Path operations (Pathfinder, Shape Builder, offset…) | ✅ mostly done (live compound shapes: Make, Alt-click a Shape Mode, member modes, Release, Expand (#4522); single-result Pathfinder names and SVG IDs retained (#1293); Divide open-cutting-path geometry, appearance and history verified (#1307; existing segment cap remains); Simplify preview/counts and rewritten-path component selection verified (#1272; the slider opens at the Auto-Simplify level; a Direct Selection part of a path simplifies on its own); Compound appearance and member fill-rule edits verified (#1197); Boolean precision on almost-horizontal edges fixed and the property tests made deterministic; Shape Builder gap detection, large-offset bug open); Shape Builder Gap Detection shares Live Paint’s spatial gap finder and temporary merge bridges (#2526); Custom is capped at 72 pt in the existing options dialog | 3–6 | diff --git a/docs/target-app-parity.md b/docs/target-app-parity.md index 29c5bfc666..c709c4685c 100644 --- a/docs/target-app-parity.md +++ b/docs/target-app-parity.md @@ -1,9 +1,13 @@ # Parity with Adobe Illustrator -> **Last reviewed:** 2026-10-10 · **Last updated:** 2026-11-09 · **Change:** minor (spell check engine: `text.spelling.check` and `text.spelling.suggest` on craft-proof, #4936; previously minor: floating tab groups collapse into the side icon rail and opened rail panels fold back into it, #5925 in part; `.ai`/EPS type keeps its tab stops, and right-aligned lines with tabs lay out as the file's page, #6147; `.ai`/EPS type from the text document lays its lines out closer to the file's page, within limits, #6137; `.ai` and EPS import: older Art brush objects read; numeric fields step on wheel hover without taking keyboard focus, and a panel wheel turn cannot seed a canvas zoom glide, #5949; Character Styles panel: a double-click on a style's row opens its Character Style Options; the dialog keeps a fixed width and scrolls its sections, so its buttons stay on screen; Tools stays beside the canvas with left-side panels; new gradients follow document color mode; Selection QoL: marquee modes and visible feedback, #5313; SVG CSS classes survive export and repeated import in all four styling modes (#2480); current-main integration retains event attributes and scripts; #3380 deletion-only review follow-up: independent survivors keep gradient placement, owned subpaths avoid discarded copies, and contracts/status/evidence are clarified; endpoint highlighting remains open; scores and estimates unchanged; the canvas keeps selection outlines and anchors between frames; Indian-language hyphenation review and license allowlist, #4947; Stroke gradients: an arrowhead aligned to the tip is painted to the corners of its base, #5964; Drop Shadow and glow dialogs: spinner arrows, #5367, #5368; Stroke Weight Up and Down shortcuts, #5797; Hindi catalog and contributor loanword preferences; full wording review in progress; Properties in Edit Artboards: a Transform section with the reference point above the Artboards section, #5219; the Control bar's Stroke: and Opacity: links scrub their fields, #4088; an image zoomed in on is separated, colorized or proofed only where it shows (#4155); a document's first frame renders on the render worker, so opening a heavy file no longer freezes the window, #4155; Control bar Paragraph section with type selected, #5372; translating unchanged type reuses its glyph and character-stroke outlines; scores and estimates unchanged) · **Target:** Adobe Illustrator 2026 (30.x; public release notes through 30.7, August 2026; Units › East Asian Type acts, with Q and Ha units; scores unchanged) +> **Last reviewed:** 2026-10-10 · **Last updated:** 2026-11-09 · **Change:** minor (#5804 draft native-picked raster editor; scores and estimates unchanged; spell check engine: `text.spelling.check` and `text.spelling.suggest` on craft-proof, #4936; previously minor: floating tab groups collapse into the side icon rail and opened rail panels fold back into it, #5925 in part; `.ai`/EPS type keeps its tab stops, and right-aligned lines with tabs lay out as the file's page, #6147; `.ai`/EPS type from the text document lays its lines out closer to the file's page, within limits, #6137; `.ai` and EPS import: older Art brush objects read; numeric fields step on wheel hover without taking keyboard focus, and a panel wheel turn cannot seed a canvas zoom glide, #5949; Character Styles panel: a double-click on a style's row opens its Character Style Options; the dialog keeps a fixed width and scrolls its sections, so its buttons stay on screen; Tools stays beside the canvas with left-side panels; new gradients follow document color mode; Selection QoL: marquee modes and visible feedback, #5313; SVG CSS classes survive export and repeated import in all four styling modes (#2480); current-main integration retains event attributes and scripts; #3380 deletion-only review follow-up: independent survivors keep gradient placement, owned subpaths avoid discarded copies, and contracts/status/evidence are clarified; endpoint highlighting remains open; scores and estimates unchanged; the canvas keeps selection outlines and anchors between frames; Indian-language hyphenation review and license allowlist, #4947; Stroke gradients: an arrowhead aligned to the tip is painted to the corners of its base, #5964; Drop Shadow and glow dialogs: spinner arrows, #5367, #5368; Stroke Weight Up and Down shortcuts, #5797; Hindi catalog and contributor loanword preferences; full wording review in progress; Properties in Edit Artboards: a Transform section with the reference point above the Artboards section, #5219; the Control bar's Stroke: and Opacity: links scrub their fields, #4088; an image zoomed in on is separated, colorized or proofed only where it shows (#4155); a document's first frame renders on the render worker, so opening a heavy file no longer freezes the window, #4155; Control bar Paragraph section with type selected, #5372; translating unchanged type reuses its glyph and character-stroke outlines; scores and estimates unchanged) · **Target:** Adobe Illustrator 2026 (30.x; public release notes through 30.7, August 2026; Units › East Asian Type acts, with Q and Ha units; scores unchanged) ## Feature submission evidence +Draft enhancement #5804: Preferences › File Handling can select a raster editor through the native picker, with a private draft outside engine preferences and generic dialog fields. OK saves it, Cancel discards it, and Reset restores PhotoCraft. With Use System Defaults off, a missing chosen editor falls back to PhotoCraft, then the system default; validation and launch failures are reported. Control/MCP and synthetic input cannot choose an application or run external Edit Original. Web behavior, parity scores and estimates are unchanged; maintainer acceptance and macOS/Linux smoke tests remain pending. + +**2026-11-09 revision:** draft implementation and regression coverage for #5804; no parity rescore. + Numeric fields step on wheel hover without taking keyboard focus (#5949). Arrow keys still require focus; modifiers, units, limits, mixed values and existing rounding stay in the shared stepping path. Headless regressions in `tests/numfields.rs` cover hovered unfocused fields, focused fields, trackpad accumulation and panel scroll exclusion. A canvas-first/panel-second regression also checks that a field turn cannot start a canvas zoom glide when the pointer enters the canvas on the next frame. Scores and estimates unchanged. Raster rendering fits and preflattens curved stroke outlines more tightly only below four times the raster tolerance, retaining thin-band coverage without changing stroke weight or vector export geometry. Current cached character/object outlines, cropped long strokes, gradient clips and effect rasters share the helper; cropped-region reuse and guarded flattening remain. The unchanged `fractional_curved_strokes_retain_coverage_between_notches` regression covers fractional weights, rotation, phase, opacity and f32-rounded endpoints. This is a quality/cost tradeoff, not a speed claim. Scores and estimates unchanged. @@ -236,7 +240,7 @@ dominate; 3D, graphs and automation are specialist). They sum to 105. Feature de | Print, colour management, separations, flattener | 3 | 80% | print preview fidelity | 2–4 | estimated | | Automation (Actions, Variables, scripting, batch) | 3 | 60% | a scripting surface (Illustrator: JavaScript/ExtendScript), Batch, image and graph variables, dataset import/export | 8–14 | estimated; MCP `add_text` exposes existing vertical type; score and hours unchanged | | UI chrome (panels, Properties, workspaces, preferences) | 6 | 80% | Properties per context, 3 Preferences options stored but unused (#394, audited 2026-10-30: Open Documents As Tabs, Scratch Disks, legacy vector clipboard), SVG Interactivity, context menus beyond the canvas, accessibility | 13–20 | estimated; floating panels in OS windows of their own on the desktop (#4135), score and hours unchanged; macOS save Format menu implemented (#866), score and hours unchanged; Eyedropper cursor and precise setting checked (#1269), OS visual QA unverified; numeric-field focus and normal text drags regression-tested (#1326, in part); movements below the click threshold still select all; artboard navigation synchronizes the tool selection before destructive actions; status messages and readouts use stable responsive allocations sized for localized labels and ordinary coordinates (sample widths cached by language/unit/DPI; regression and contributor original-file evidence below; scores/hours unchanged); effect dialogs' colour fields show a swatch that opens the Color Picker (#5365), score and hours unchanged; floating tab groups collapse into the side icon rail and opened rail panels fold back into it (#5925, in part), scores and hours unchanged | -| Libraries, Links, Package | 2 | 82% | shared libraries, linked graphics, gradients and patterns as library items (no cloud by design) | 2–3 | estimated | +| Libraries, Links, Package | 2 | 82% | shared libraries, linked graphics, gradients and patterns as library items (no cloud by design) | 2–3 | estimated; draft #5804: private native-picked raster editor (scores unchanged) | | Generative AI (Text to Vector, Generative Recolor, Shape Fill, Concept to Vector, Prompt to Edit, Rewrite Text) | 2 | 0% | a pluggable provider and the panels; needs an owner decision on models | 30–60 | measured (absent) | | **Feature depth** | **105** | **~75%** | | **~250–420** | | | Interaction-fidelity pass (every tool's modifiers, cursors, Properties per context) | | | [ui-parity.md](ui-parity.md) | 60–90 | estimated | diff --git a/docs/ui-parity.md b/docs/ui-parity.md index b96caf13cf..b4c7d1e128 100644 --- a/docs/ui-parity.md +++ b/docs/ui-parity.md @@ -1,9 +1,13 @@ # UI and interaction parity -> **Last reviewed:** 2026-10-10 · **Last updated:** 2026-11-09 · **Change:** minor (floating tab groups collapse into the side icon rail and opened rail panels fold back into it, #5925 in part; numeric fields step on wheel hover without taking keyboard focus, #5949; Character Styles panel: a double-click on a style's row opens its Character Style Options; the dialog keeps a fixed width and scrolls its sections, so its buttons stay on screen; Selection QoL: marquee modes and visible feedback, #5313; #3380 deletion-only review follow-up: independent survivors keep gradient placement, owned subpaths avoid discarded copies, and contracts/status/evidence are clarified; endpoint highlighting remains open; scores and estimates unchanged; Drop Shadow and glow dialogs: spinner arrows, #5367, #5368; Stroke Weight Up and Down shortcuts, #5797; Layers: Rename (`ui.rename`) opens the name field of the selected layer, group or object, #5324; Properties in Edit Artboards: Transform section above the Artboards section, #5219; scrubby labels: the Control bar's Stroke: and Opacity: links and the Properties panel's Stroke link scrub their fields, #4088; Properties: Quick Actions has Repeat Options for one selected repeat, #5181; Direct Selection: Shift-click picks several blend spine points, which drag together, #5285; Direct Selection: Cmd/Ctrl held lends the Selection tool and shows its bounding box, #3901; Join tool trims two crossing open paths and joins them at the crossing, #5844; Control bar: Paragraph: link and Align left/center/right while type is selected, #5372; shape tools: a press on the selection's centre point moves it and one in the rotate zone outside a box corner turns it, #5477; scores and estimates unchanged) · **Target:** Adobe Illustrator 2026 (30.x; Units › East Asian Type acts, with Q and Ha units; scores unchanged) +> **Last reviewed:** 2026-10-10 · **Last updated:** 2026-11-09 · **Change:** minor (#5804 draft native-picked raster editor; scores and estimates unchanged; floating tab groups collapse into the side icon rail and opened rail panels fold back into it, #5925 in part; numeric fields step on wheel hover without taking keyboard focus, #5949; Character Styles panel: a double-click on a style's row opens its Character Style Options; the dialog keeps a fixed width and scrolls its sections, so its buttons stay on screen; Selection QoL: marquee modes and visible feedback, #5313; #3380 deletion-only review follow-up: independent survivors keep gradient placement, owned subpaths avoid discarded copies, and contracts/status/evidence are clarified; endpoint highlighting remains open; scores and estimates unchanged; Drop Shadow and glow dialogs: spinner arrows, #5367, #5368; Stroke Weight Up and Down shortcuts, #5797; Layers: Rename (`ui.rename`) opens the name field of the selected layer, group or object, #5324; Properties in Edit Artboards: Transform section above the Artboards section, #5219; scrubby labels: the Control bar's Stroke: and Opacity: links and the Properties panel's Stroke link scrub their fields, #4088; Properties: Quick Actions has Repeat Options for one selected repeat, #5181; Direct Selection: Shift-click picks several blend spine points, which drag together, #5285; Direct Selection: Cmd/Ctrl held lends the Selection tool and shows its bounding box, #3901; Join tool trims two crossing open paths and joins them at the crossing, #5844; Control bar: Paragraph: link and Align left/center/right while type is selected, #5372; shape tools: a press on the selection's centre point moves it and one in the rotate zone outside a box corner turns it, #5477; scores and estimates unchanged) · **Target:** Adobe Illustrator 2026 (30.x; Units › East Asian Type acts, with Q and Ha units; scores unchanged) ## Feature submission evidence +Draft enhancement #5804: Preferences › File Handling can select a raster editor through the native picker, with a private draft outside engine preferences and generic dialog fields. OK saves it, Cancel discards it, and Reset restores PhotoCraft. With Use System Defaults off, a missing chosen editor falls back to PhotoCraft, then the system default; validation and launch failures are reported. Control/MCP and synthetic input cannot choose an application or run external Edit Original. Web behavior, parity scores and estimates are unchanged; maintainer acceptance and macOS/Linux smoke tests remain pending. + +**2026-11-09 revision:** draft implementation and regression coverage for #5804; no parity rescore. + Numeric fields step on wheel hover without taking keyboard focus (#5949). Arrow keys still require focus; modifiers, units, limits, mixed values and existing rounding stay in the shared stepping path. Headless regressions in `tests/numfields.rs` cover hovered unfocused fields, focused fields, trackpad accumulation and panel scroll exclusion. Scores and estimates unchanged. | 2026-11-06 | minor | Opening a file that takes longer than 0.4 s shows a progress window: the file name, a moving bar (reading reports no steps), how many more files wait, Cancel (Esc; the file doesn't open) and Continue in Background (`file.cancelOpen`, `file.openInBackground`); it never opens over another dialog or progress window (part of #5930); scores and estimates unchanged |