From 685ab7ccd43ae81f95eeeacff52dc0223971655d Mon Sep 17 00:00:00 2001 From: dotCooCoo Date: Mon, 16 Nov 2026 08:05:40 -0800 Subject: [PATCH 1/3] Ellipse: a click on the word Height in the click dialog copies Width into Height The Ellipse dialog's Height label is now a button. A click, or Space or Enter while it has the keyboard focus, copies the Width value into the Height field, so OK draws a circle. The Rectangle and Rounded Rectangle dialogs keep plain labels. With Constrain Width and Height Proportions on, the link stays on and keeps the circle when a side is typed next. A Width that is empty or not a distance, including one the field refuses as the click leaves it, leaves Height unchanged. Enter on the Height button or on the link button no longer also presses OK. Screen readers read the button as "Height:", which still names the Height field, with the description "Copy Width to Height" (translated in every catalog). --- crates/ui-egui/src/dialogs/shapes.rs | 282 ++++++++++++++++++++++++++- crates/ui-egui/src/i18n/bg.tsv | 1 + crates/ui-egui/src/i18n/bs.tsv | 1 + crates/ui-egui/src/i18n/ca.tsv | 1 + crates/ui-egui/src/i18n/cs.tsv | 1 + crates/ui-egui/src/i18n/da.tsv | 1 + crates/ui-egui/src/i18n/de.tsv | 1 + crates/ui-egui/src/i18n/el.tsv | 1 + crates/ui-egui/src/i18n/es.tsv | 1 + crates/ui-egui/src/i18n/fi.tsv | 1 + crates/ui-egui/src/i18n/fr.tsv | 1 + crates/ui-egui/src/i18n/gu.tsv | 1 + crates/ui-egui/src/i18n/hi.tsv | 1 + crates/ui-egui/src/i18n/hu.tsv | 1 + crates/ui-egui/src/i18n/id.tsv | 1 + crates/ui-egui/src/i18n/it.tsv | 1 + crates/ui-egui/src/i18n/ja.tsv | 1 + crates/ui-egui/src/i18n/ka.tsv | 1 + crates/ui-egui/src/i18n/ko.tsv | 1 + crates/ui-egui/src/i18n/nl.tsv | 1 + crates/ui-egui/src/i18n/pl.tsv | 1 + crates/ui-egui/src/i18n/pt-br.tsv | 1 + crates/ui-egui/src/i18n/ru.tsv | 1 + crates/ui-egui/src/i18n/sv.tsv | 1 + crates/ui-egui/src/i18n/tr.tsv | 1 + crates/ui-egui/src/i18n/uk.tsv | 1 + crates/ui-egui/src/i18n/vi.tsv | 1 + crates/ui-egui/src/i18n/zh-hans.tsv | 1 + crates/ui-egui/src/i18n/zh-hant.tsv | 1 + docs/target-app-parity.md | 1 + 30 files changed, 310 insertions(+), 1 deletion(-) diff --git a/crates/ui-egui/src/dialogs/shapes.rs b/crates/ui-egui/src/dialogs/shapes.rs index b761383752..651fa098ff 100644 --- a/crates/ui-egui/src/dialogs/shapes.rs +++ b/crates/ui-egui/src/dialogs/shapes.rs @@ -294,7 +294,15 @@ fn linked_size_form(ui: &mut egui::Ui, d: &mut Dialog, unit: Unit) { let mut rows: Option = None; egui::Grid::new("shape-size-dlg").num_columns(3).spacing([10.0, 8.0]).show(ui, |ui| { for (key, label) in [("width", "Width:"), ("height", "Height:")] { - let row = form::row_label(ui, label); + let row = if key == "height" && d.kind == "ellipse" { + let (row, pressed) = height_label_button(ui, label); + if pressed { + copy_width_to_height(d); + } + row + } else { + form::row_label(ui, label) + }; if ui.label_inputs_by(row.id, |ui| form::length(ui, d, key, unit, form::FIELD_W)) { follow_link(d, key); } @@ -316,6 +324,8 @@ fn linked_size_form(ui: &mut egui::Ui, d: &mut Dialog, unit: Unit) { let resp = ui.interact(rect, ui.scope_id().with("shape-size-link"), egui::Sense::click()); let icon = if on { "link" } else { "link-2-off" }; if widgets::paint_icon_button(ui, resp, icon, "Constrain Width and Height Proportions", on).clicked() { + // Enter on the focused button turns the link on or off; it does not also press OK. + ui.input_mut(|i| i.consume_key(egui::Modifiers::NONE, egui::Key::Enter)); d.fields.insert(LINK.into(), json!(!on)); sync_link(ui.ctx(), d); } @@ -361,6 +371,61 @@ fn follow_link(d: &mut Dialog, typed: &str) { } } +/// The Ellipse dialog's Height label: a button drawn as the other rows' labels are. Whether it was +/// pressed: a click, or Enter or Space while it has the keyboard focus; that Enter does not also +/// press OK. A click whose press took the focus from a field that then refused its text (Width +/// left empty or not a distance) does not count, as such a click on OK does not. Screen readers +/// read it as the button "Height:" (which also names the Height field) with the description "Copy +/// Width to Height". +fn height_label_button(ui: &mut egui::Ui, label: &str) -> (egui::Response, bool) { + let t = crate::theme::Tokens::get(ui.ctx()); + let text = egui::RichText::new(tl!(label)).color(t.text_dim); + let resp = ui.add(egui::Button::new(text).frame(false)).on_hover_cursor(egui::CursorIcon::PointingHand); + let resp = resp.on_hover_text(tl!("Copy Width to Height")); + let press = resp.id.with("press-pass"); + if resp.contains_pointer() && ui.input(|i| i.pointer.any_pressed()) { + let pass = ui.ctx().cumulative_pass_nr(); + ui.data_mut(|m| m.insert_temp(press, pass)); + } + if !resp.clicked() { + // A press let go without a click (dragged off the button) leaves no press behind. + if ui.input(|i| i.pointer.any_released()) { + ui.data_mut(|m| m.remove::(press)); + } + return (resp, false); + } + ui.input_mut(|i| i.consume_key(egui::Modifiers::NONE, egui::Key::Enter)); + let (pressed_at, refused_at, refused_now) = ui.data_mut(|m| { + let pressed_at = m.get_temp::(press); + m.remove::(press); + (pressed_at, m.get_temp::(widgets::dialog_reject_pass()), m.get_temp::(widgets::dialog_reject_commit_flag())) + }); + let refused = refused_now == Some(true) || matches!((refused_at, pressed_at), (Some(r), Some(p)) if r >= p); + (resp, !refused) +} + +/// Height takes the Width the dialog holds (help page "Draw ellipses", +/// ). +/// A Width that is missing, empty, not a distance or not finite leaves Height as it is. With the +/// link on, the link keeps the circle from then on (proportions 1 : 1), or keeps no proportions +/// when Width is 0; the link stays on. +fn copy_width_to_height(d: &mut Dialog) { + let width = match d.fields.get("width") { + Some(Value::Number(n)) => n.as_f64(), + Some(Value::String(s)) => Unit::Points.parse(s), + _ => None, + }; + let Some(width) = width.filter(|w| w.is_finite()) else { return }; + d.fields.insert("height".into(), json!(width)); + if d.bool(LINK) { + if width != 0.0 { + d.fields.insert(RATIO.into(), json!(1.0)); + } else { + d.fields.remove(RATIO); + } + } +} + /// The Ellipse dialog's Anchors: the nearest whole number from 2 to 1000 (4, a live ellipse, when /// left empty or not a number). fn ellipse_anchors(d: &Dialog) -> u64 { @@ -794,6 +859,221 @@ mod tests { assert_eq!(ellipse_anchors(h.state().ui.dialog.as_ref().unwrap()), 4); } + /// A harness drawing `app`'s dialog, with the app's fonts installed on its first frame. + fn dialog_harness(app: VectorcraftApp) -> egui_kittest::Harness<'static, VectorcraftApp> { + let mut fonts = false; + let mut h = egui_kittest::Harness::builder().with_size(egui::vec2(1100.0, 900.0)).build_ui_state( + move |ui, app: &mut VectorcraftApp| { + if !std::mem::replace(&mut fonts, true) { + crate::theme::install_fonts(ui.ctx()); + return; + } + super::super::show(app, ui.ctx()); + }, + app, + ); + h.run_steps(5); + h + } + + /// The dialog's Width and Height in points. + fn dialog_size(h: &egui_kittest::Harness<'_, VectorcraftApp>) -> (f64, f64) { + let d = h.state().ui.dialog.as_ref().expect("the dialog is open"); + (d.f64("width", -1.0), d.f64("height", -1.0)) + } + + /// Replaces the text of the field named `name` with `text` and leaves it with Tab. + fn retype(h: &mut egui_kittest::Harness<'_, VectorcraftApp>, name: &str, text: &str) { + use egui::accesskit::Role; + use egui_kittest::kittest::Queryable; + let all = egui::Modifiers { ctrl: true, command: true, ..Default::default() }; + h.get_by_role_and_label(Role::TextInput, name).focus(); + h.run_steps(2); + h.key_press_modifiers(all, egui::Key::A); + h.get_by_role_and_label(Role::TextInput, name).type_text(text); + h.run_steps(2); + h.key_press(egui::Key::Tab); + h.run_steps(2); + } + + /// In the Ellipse dialog, a click on the word Height copies Width into Height, also a Width + /// typed and not yet committed; the fields keep their names. Cancel discards it; OK draws the + /// circle as one undo step. + #[test] + fn clicking_height_in_the_ellipse_dialog_copies_width_into_height() { + use egui::accesskit::Role; + use egui_kittest::kittest::{NodeT, Queryable}; + let mut app = VectorcraftApp::new(Session::new(), Default::default()); + app.run("file.new", json!({"width": 300, "height": 300})).unwrap(); + super::super::open_tool_dialog(&mut app, "ellipse", json!({"x": 10.0, "y": 10.0})); + let d = app.ui.dialog.as_mut().unwrap(); + d.fields.insert("width".into(), json!(80.0)); + d.fields.insert("height".into(), json!(30.0)); + let mut h = dialog_harness(app); + h.check_accessibility(); + let button = h.get_by_role_and_label(Role::Button, "Height:"); + assert_eq!(button.accesskit_node().description().as_deref(), Some("Copy Width to Height")); + h.get_by_role_and_label(Role::Button, "Height:").click(); + h.run_steps(2); + assert_eq!(dialog_size(&h), (80.0, 80.0)); + let d = h.state().ui.dialog.as_ref().unwrap(); + assert!(!d.bool(LINK) && !d.fields.contains_key(RATIO), "the link stays off"); + // The value fields keep their names. + h.get_by_role_and_label(Role::TextInput, "Width:"); + h.get_by_role_and_label(Role::TextInput, "Height:"); + + // A Width typed and not committed with Enter or Tab is the one copied. + let all = egui::Modifiers { ctrl: true, command: true, ..Default::default() }; + h.get_by_role_and_label(Role::TextInput, "Width:").focus(); + h.run_steps(2); + h.key_press_modifiers(all, egui::Key::A); + h.get_by_role_and_label(Role::TextInput, "Width:").type_text("50 pt"); + h.run_steps(2); + h.get_by_role_and_label(Role::Button, "Height:").click(); + h.run_steps(3); + assert_eq!(dialog_size(&h), (50.0, 50.0)); + + // A Width the field refuses when the click takes its focus (not a distance, or empty) + // is not copied: Height keeps its value. + h.state_mut().ui.dialog.as_mut().unwrap().fields.insert("height".into(), json!(30.0)); + h.run_steps(2); + for typed in ["wide", ""] { + h.get_by_role_and_label(Role::TextInput, "Width:").focus(); + h.run_steps(2); + h.key_press_modifiers(all, egui::Key::A); + if typed.is_empty() { + h.key_press(egui::Key::Backspace); + } else { + h.get_by_role_and_label(Role::TextInput, "Width:").type_text(typed); + } + h.run_steps(2); + h.get_by_role_and_label(Role::Button, "Height:").click(); + h.run_steps(3); + assert_eq!(dialog_size(&h), (50.0, 30.0), "{typed:?}"); + } + // The field shows its value again, and the next click copies it. + h.get_by_role_and_label(Role::Button, "Height:").click(); + h.run_steps(3); + assert_eq!(dialog_size(&h), (50.0, 50.0)); + + // Cancel: nothing is drawn. + let undo = |h: &egui_kittest::Harness<'_, VectorcraftApp>| h.state().session.active().unwrap().history.undo.len(); + let before = undo(&h); + crate::dialogs::cancel(h.state_mut()); + h.run_steps(2); + assert!(h.state().session.doc().unwrap().doc.layers[0].children().unwrap().is_empty()); + assert_eq!(undo(&h), before); + + // OK: one circle, one undo step. + super::super::open_tool_dialog(h.state_mut(), "ellipse", json!({"x": 10.0, "y": 10.0})); + h.state_mut().ui.dialog.as_mut().unwrap().fields.insert("width".into(), json!(64.0)); + h.run_steps(2); + h.get_by_role_and_label(Role::Button, "Height:").click(); + h.run_steps(2); + super::super::confirm(h.state_mut()).unwrap(); + assert!(h.state().ui.dialog.is_none()); + assert_eq!(undo(&h), before + 1); + let doc = &h.state().session.doc().unwrap().doc; + let b = doc.layers[0].children().unwrap()[0].geometric_bounds().unwrap(); + assert!((b.width() - 64.0).abs() < 1e-6 && (b.height() - 64.0).abs() < 1e-6, "{b:?}"); + } + + /// The Height button works from the keyboard: Space and Enter copy Width into Height, and + /// that Enter does not press OK. With the link on, the link stays on and keeps the circle when + /// Width is typed next; a Width of 0 is copied and leaves the link no proportions to keep. + #[test] + fn the_ellipse_height_button_copies_width_from_the_keyboard_and_keeps_the_link_round() { + use egui::accesskit::Role; + use egui_kittest::kittest::Queryable; + let mut app = VectorcraftApp::new(Session::new(), Default::default()); + app.run("file.new", json!({"width": 300, "height": 300})).unwrap(); + super::super::open_tool_dialog(&mut app, "ellipse", json!({"x": 10.0, "y": 10.0})); + let d = app.ui.dialog.as_mut().unwrap(); + d.fields.insert("width".into(), json!(80.0)); + d.fields.insert("height".into(), json!(20.0)); + d.fields.insert(LINK.into(), json!(true)); + let mut h = dialog_harness(app); + assert_eq!(h.state().ui.dialog.as_ref().unwrap().f64(RATIO, 0.0), 0.25); + h.get_by_role_and_label(Role::Button, "Height:").focus(); + h.run_steps(2); + h.key_press(egui::Key::Space); + h.run_steps(2); + assert_eq!(dialog_size(&h), (80.0, 80.0)); + let d = h.state().ui.dialog.as_ref().unwrap(); + assert!(d.bool(LINK), "the link stays on"); + assert_eq!(d.f64(RATIO, 0.0), 1.0); + // The link now keeps the circle. + retype(&mut h, "Width:", "40 pt"); + assert_eq!(dialog_size(&h), (40.0, 40.0)); + + // Enter on the button copies, and the dialog stays open. + h.state_mut().ui.dialog.as_mut().unwrap().fields.insert("width".into(), json!(0.0)); + h.run_steps(2); + h.get_by_role_and_label(Role::Button, "Height:").focus(); + h.run_steps(2); + h.key_press(egui::Key::Enter); + h.run_steps(2); + assert!(h.state().ui.dialog.is_some(), "Enter on the Height button does not press OK"); + assert_eq!(dialog_size(&h), (0.0, 0.0)); + let d = h.state().ui.dialog.as_ref().unwrap(); + assert!(d.bool(LINK) && !d.fields.contains_key(RATIO), "no proportions to keep at 0"); + assert!(h.state().session.doc().unwrap().doc.layers[0].children().unwrap().is_empty()); + } + + /// Enter on the focused link button turns the link on and leaves the dialog open, as Space does. + #[test] + fn enter_on_the_link_button_turns_the_link_on_without_pressing_ok() { + use egui::accesskit::Role; + use egui_kittest::kittest::Queryable; + const LINK_NAME: &str = "Constrain Width and Height Proportions"; + let mut app = VectorcraftApp::new(Session::new(), Default::default()); + app.run("file.new", json!({"width": 300, "height": 300})).unwrap(); + super::super::open_tool_dialog(&mut app, "rectangle", json!({"x": 10.0, "y": 10.0})); + let mut h = dialog_harness(app); + assert!(!h.state().ui.dialog.as_ref().unwrap().bool(LINK)); + h.get_by_role_and_label(Role::Button, LINK_NAME).focus(); + h.run_steps(2); + h.key_press(egui::Key::Enter); + h.run_steps(2); + let d = h.state().ui.dialog.as_ref().expect("Enter on the link button does not press OK"); + assert!(d.bool(LINK)); + assert!(h.state().session.doc().unwrap().doc.layers[0].children().unwrap().is_empty()); + } + + /// Rectangle and Rounded Rectangle keep plain Width and Height labels. + #[test] + fn only_the_ellipse_dialog_has_the_height_button() { + use egui::accesskit::Role; + use egui_kittest::kittest::Queryable; + for kind in ["rectangle", "roundedRectangle"] { + let mut app = VectorcraftApp::new(Session::new(), Default::default()); + app.run("file.new", json!({"width": 300, "height": 300})).unwrap(); + super::super::open_tool_dialog(&mut app, kind, json!({"x": 10.0, "y": 10.0})); + let h = dialog_harness(app); + h.get_by_role_and_label(Role::TextInput, "Height:"); + assert!(h.query_by_role_and_label(Role::Button, "Height:").is_none(), "{kind}"); + } + } + + /// A Width that is missing, empty, not a distance or not finite leaves Height as it is; a + /// Width with a unit is copied in points, and 0 is copied. + #[test] + fn copying_width_takes_only_a_width_that_reads() { + for width in [None, Some(json!("")), Some(json!("wide")), Some(json!("inf")), Some(json!(null)), Some(json!(true))] { + let mut d = Dialog::new("ellipse", json!({"height": 30.0})); + if let Some(w) = width.clone() { + d.fields.insert("width".into(), w); + } + copy_width_to_height(&mut d); + assert_eq!(d.fields.get("height"), Some(&json!(30.0)), "{width:?}"); + } + for (width, want) in [(json!("1 in"), 72.0), (json!(0), 0.0), (json!(12.5), 12.5)] { + let mut d = Dialog::new("ellipse", json!({"width": width.clone(), "height": 30.0})); + copy_width_to_height(&mut d); + assert_eq!(d.f64("height", -1.0), want, "{width}"); + } + } + #[test] fn ellipse_anchors_take_the_nearest_whole_number_from_2_to_1000() { let d = |v: Value| Dialog::new("ellipse", json!({ "anchors": v })); diff --git a/crates/ui-egui/src/i18n/bg.tsv b/crates/ui-egui/src/i18n/bg.tsv index 613d5cd1e3..e4aa85e716 100644 --- a/crates/ui-egui/src/i18n/bg.tsv +++ b/crates/ui-egui/src/i18n/bg.tsv @@ -592,6 +592,7 @@ font-technology Variable Променливи Consolidate All Windows Обединяване на всички прозорци Constrain Angle Заключване на ъгъла Constrain Width and Height Proportions Запазване на пропорциите на ширина и височина + Copy Width to Height Копиране на ширината във височината Construction Guides Конструкционни водачи Contextual Alternates Контекстни алтернативи Contextual Task Bar Контекстна лента със задачи diff --git a/crates/ui-egui/src/i18n/bs.tsv b/crates/ui-egui/src/i18n/bs.tsv index fcc034cd0f..6b751766ef 100644 --- a/crates/ui-egui/src/i18n/bs.tsv +++ b/crates/ui-egui/src/i18n/bs.tsv @@ -3876,6 +3876,7 @@ theme Appearance Izgled Command Click to Select Objects Behind Command-klik za odabir objekata iza Constrain Angle Ograniči ugao Constrain Width and Height Proportions Zadrži proporcije širine i visine + Copy Width to Height Kopiraj širinu u visinu Construction Guides Konstrukcijske vodilice Curvature Tool Alat zakrivljenost Data Recovery Oporavak podataka diff --git a/crates/ui-egui/src/i18n/ca.tsv b/crates/ui-egui/src/i18n/ca.tsv index ac55a78ff4..2eac9f7e17 100644 --- a/crates/ui-egui/src/i18n/ca.tsv +++ b/crates/ui-egui/src/i18n/ca.tsv @@ -884,6 +884,7 @@ antiAlias Sharp Nítid Constrain Restringeix Constrain Angle Angle de restricció Constrain Width and Height Proportions Restringeix les proporcions d’amplada i alçada + Copy Width to Height Copia l’amplada a l’alçada Construction Guides Guies de construcció Contextual Alternates Alternatives contextuals Contextual Task Bar Barra de tasques contextual diff --git a/crates/ui-egui/src/i18n/cs.tsv b/crates/ui-egui/src/i18n/cs.tsv index 69dd46dc23..bc4e94fc22 100644 --- a/crates/ui-egui/src/i18n/cs.tsv +++ b/crates/ui-egui/src/i18n/cs.tsv @@ -3979,6 +3979,7 @@ theme Appearance Motiv Command Click to Select Objects Behind Kliknutím s Cmd vybírat objekty vzadu Constrain Angle Úhel omezení Constrain Width and Height Proportions Zachovat proporce šířky a výšky + Copy Width to Height Kopírovat šířku do výšky Construction Guides Konstrukční vodítka Curvature Tool Nástroj Zakřivení Data Recovery Obnovení dat diff --git a/crates/ui-egui/src/i18n/da.tsv b/crates/ui-egui/src/i18n/da.tsv index 7bc0ed6c94..c54e0c961b 100644 --- a/crates/ui-egui/src/i18n/da.tsv +++ b/crates/ui-egui/src/i18n/da.tsv @@ -6376,6 +6376,7 @@ theme Appearance Udseende Command Click to Select Objects Behind Command-klik for at markere objekter bagved Constrain Angle Fastlåsningsvinkel Constrain Width and Height Proportions Fasthold forholdet mellem bredde og højde + Copy Width to Height Kopiér bredde til højde Construction Guides Konstruktionshjælpelinjer Curvature Tool Krumningsværktøj Data Recovery Datgendannelse diff --git a/crates/ui-egui/src/i18n/de.tsv b/crates/ui-egui/src/i18n/de.tsv index 4b17261bfb..33dade7e4c 100644 --- a/crates/ui-egui/src/i18n/de.tsv +++ b/crates/ui-egui/src/i18n/de.tsv @@ -585,6 +585,7 @@ font-technology Variable Variabel Consolidate All Windows Alle Fenster zusammenführen Constrain Angle Winkelbeschränkung Constrain Width and Height Proportions Proportionen von Breite und Höhe beibehalten + Copy Width to Height Breite in Höhe kopieren Construction Guides Konstruktionslinien Contextual Alternates Kontextbedingte Varianten Contextual Task Bar Kontextbezogene Taskleiste diff --git a/crates/ui-egui/src/i18n/el.tsv b/crates/ui-egui/src/i18n/el.tsv index bba8d392ad..3bf2b655dd 100644 --- a/crates/ui-egui/src/i18n/el.tsv +++ b/crates/ui-egui/src/i18n/el.tsv @@ -566,6 +566,7 @@ font-technology Variable Μεταβλητές Consolidate All Windows Συγχώνευση όλων των παραθύρων Constrain Angle Περιορισμός γωνίας Constrain Width and Height Proportions Διατήρηση αναλογιών πλάτους και ύψους + Copy Width to Height Αντιγραφή πλάτους στο ύψος Construction Guides Οδηγοί κατασκευής Contextual Alternates Εναλλακτικοί χαρακτήρες βάσει συμφραζομένων Contextual Task Bar Γραμμή εργασιών βάσει περιβάλλοντος diff --git a/crates/ui-egui/src/i18n/es.tsv b/crates/ui-egui/src/i18n/es.tsv index 57e7f44e87..82b1a47478 100644 --- a/crates/ui-egui/src/i18n/es.tsv +++ b/crates/ui-egui/src/i18n/es.tsv @@ -607,6 +607,7 @@ font-technology Variable Variables Consolidate All Windows Consolidar todas las ventanas Constrain Angle Restringir ángulo Constrain Width and Height Proportions Restringir proporciones de anchura y altura + Copy Width to Height Copiar anchura en altura Construction Guides Guías de construcción Contextual Alternates Alternativas contextuales Contextual Task Bar Barra de tareas contextual diff --git a/crates/ui-egui/src/i18n/fi.tsv b/crates/ui-egui/src/i18n/fi.tsv index 0276e5b6ed..44165e80c4 100644 --- a/crates/ui-egui/src/i18n/fi.tsv +++ b/crates/ui-egui/src/i18n/fi.tsv @@ -3917,6 +3917,7 @@ theme Appearance Ulkoasu Command Click to Select Objects Behind Valitse takana olevat objektit Komento-napsautuksella Constrain Angle Rajoita kulmaa Constrain Width and Height Proportions Säilytä leveyden ja korkeuden suhde + Copy Width to Height Kopioi leveys korkeudeksi Construction Guides Rakenneapuviivat Curvature Tool Kaarevuustyökalu Data Recovery Tietojen palautus diff --git a/crates/ui-egui/src/i18n/fr.tsv b/crates/ui-egui/src/i18n/fr.tsv index 75f4f14c6f..c4edd359c5 100644 --- a/crates/ui-egui/src/i18n/fr.tsv +++ b/crates/ui-egui/src/i18n/fr.tsv @@ -608,6 +608,7 @@ font-technology Variable Variables Consolidate All Windows Regrouper toutes les fenêtres Constrain Angle Contraindre l’angle Constrain Width and Height Proportions Conserver les proportions de largeur et de hauteur + Copy Width to Height Copier la largeur dans la hauteur Construction Guides Repères de construction Contextual Alternates Variantes contextuelles Contextual Task Bar Barre des tâches contextuelle diff --git a/crates/ui-egui/src/i18n/gu.tsv b/crates/ui-egui/src/i18n/gu.tsv index 4eed343e3d..8b448dbf43 100644 --- a/crates/ui-egui/src/i18n/gu.tsv +++ b/crates/ui-egui/src/i18n/gu.tsv @@ -704,6 +704,7 @@ Constrain મર્યાદિત કરો Constrain Angle ખૂણો મર્યાદિત કરો Constrain Width and Height Proportions પહોળાઈ અને ઊંચાઈનો પ્રમાણ મર્યાદિત કરો + Copy Width to Height પહોળાઈને ઊંચાઈમાં નકલ કરો Construction Guides બાંધકામ ગાઇડ્સ Contextual Alternates સંદર્ભિત વૈકલ્પિક અક્ષરો Contextual Task Bar સંદર્ભિત ટાસ્ક બાર diff --git a/crates/ui-egui/src/i18n/hi.tsv b/crates/ui-egui/src/i18n/hi.tsv index 094d49ce52..6a11ade6a4 100644 --- a/crates/ui-egui/src/i18n/hi.tsv +++ b/crates/ui-egui/src/i18n/hi.tsv @@ -1019,6 +1019,7 @@ antiAlias Sharp शार्प Constrain सीमित करें Constrain Angle कंस्ट्रेन एंगल Constrain Width and Height Proportions चौड़ाई और ऊंचाई का अनुपात बनाए रखें + Copy Width to Height चौड़ाई को ऊंचाई में कॉपी करें Construction Guides निर्माण गाइड Conté Crayon कॉन्टे क्रेयॉन Conté Crayon… कॉन्टे क्रेयॉन… diff --git a/crates/ui-egui/src/i18n/hu.tsv b/crates/ui-egui/src/i18n/hu.tsv index d5f42ce788..72460bf22b 100644 --- a/crates/ui-egui/src/i18n/hu.tsv +++ b/crates/ui-egui/src/i18n/hu.tsv @@ -801,6 +801,7 @@ font-technology Variable Változó Constrain Korlátozás Constrain Angle Korlátozási szög Constrain Width and Height Proportions Szélesség és magasság arányának megtartása + Copy Width to Height Szélesség másolása a magasságba Construction Guides Szerkesztési segédvonalak Contextual Alternates Környezetfüggő változatok Contextual Task Bar Helyzetérzékeny műveletsáv diff --git a/crates/ui-egui/src/i18n/id.tsv b/crates/ui-egui/src/i18n/id.tsv index b349f589a5..63bba3c347 100644 --- a/crates/ui-egui/src/i18n/id.tsv +++ b/crates/ui-egui/src/i18n/id.tsv @@ -3653,6 +3653,7 @@ theme Appearance Tampilan Command Click to Select Objects Behind Command-klik untuk memilih objek di belakang Constrain Angle Sudut kendala Constrain Width and Height Proportions Kendalikan proporsi lebar dan tinggi + Copy Width to Height Salin lebar ke tinggi Construction Guides Panduan konstruksi Curvature Tool Alat kelengkungan Data Recovery Pemulihan data diff --git a/crates/ui-egui/src/i18n/it.tsv b/crates/ui-egui/src/i18n/it.tsv index 8bc9d44147..aebe1850ae 100644 --- a/crates/ui-egui/src/i18n/it.tsv +++ b/crates/ui-egui/src/i18n/it.tsv @@ -607,6 +607,7 @@ font-technology Variable Variabili Consolidate All Windows Consolida tutte le finestre Constrain Angle Vincola angolo Constrain Width and Height Proportions Vincola proporzioni di larghezza e altezza + Copy Width to Height Copia la larghezza nell’altezza Construction Guides Guide di costruzione Contextual Alternates Alternative contestuali Contextual Task Bar Barra attività contestuale diff --git a/crates/ui-egui/src/i18n/ja.tsv b/crates/ui-egui/src/i18n/ja.tsv index 57c9aee61e..b008d3bcb3 100644 --- a/crates/ui-egui/src/i18n/ja.tsv +++ b/crates/ui-egui/src/i18n/ja.tsv @@ -1368,6 +1368,7 @@ antiAlias Sharp シャープ Conflict {n} of {count} 競合 {n} / {count} Constrain Angle 角度を制限 Constrain Width and Height Proportions 幅と高さの縦横比を固定 + Copy Width to Height 幅を高さにコピー Construction Guides 作図ガイド Contextual Alternates 前後関係に依存する字形 Convert 変換 diff --git a/crates/ui-egui/src/i18n/ka.tsv b/crates/ui-egui/src/i18n/ka.tsv index a661bc0cbb..5e1e3b4983 100644 --- a/crates/ui-egui/src/i18n/ka.tsv +++ b/crates/ui-egui/src/i18n/ka.tsv @@ -5631,6 +5631,7 @@ theme Appearance იერსახე Command Click to Select Objects Behind Command-დაწკაპუნებით უკან მდებარე ობიექტების მონიშვნა Constrain Angle კუთხის შეზღუდვა Constrain Width and Height Proportions სიგანისა და სიმაღლის პროპორციების შენარჩუნება + Copy Width to Height სიგანის კოპირება სიმაღლეში Construction Guides სამშენებლო დამხმარე ხაზები Curvature Tool მრუდის ხელსაწყო Data Recovery მონაცემების აღდგენა diff --git a/crates/ui-egui/src/i18n/ko.tsv b/crates/ui-egui/src/i18n/ko.tsv index 632c2473f8..985a8104c3 100644 --- a/crates/ui-egui/src/i18n/ko.tsv +++ b/crates/ui-egui/src/i18n/ko.tsv @@ -1358,6 +1358,7 @@ antiAlias Sharp 날카롭게 Conflict {n} of {count} 충돌 {n}/{count} Constrain Angle 각도 제한 Constrain Width and Height Proportions 너비와 높이 비율 고정 + Copy Width to Height 너비를 높이로 복사 Construction Guides 작도 안내선 Contextual Alternates 문맥 대체 글자 Convert 변환 diff --git a/crates/ui-egui/src/i18n/nl.tsv b/crates/ui-egui/src/i18n/nl.tsv index 0137b7ac5b..d78e1f9f6a 100644 --- a/crates/ui-egui/src/i18n/nl.tsv +++ b/crates/ui-egui/src/i18n/nl.tsv @@ -4270,6 +4270,7 @@ theme Appearance Vormgeving Command Click to Select Objects Behind Command-klik om objecten erachter te selecteren Constrain Angle Vastleghoek Constrain Width and Height Proportions Breedte- en hoogteverhouding vastleggen + Copy Width to Height Breedte naar hoogte kopiëren Construction Guides Bouwhulplijnen Curvature Tool Krommingsgereedschap Data Recovery Gegevensherstel diff --git a/crates/ui-egui/src/i18n/pl.tsv b/crates/ui-egui/src/i18n/pl.tsv index a2909473c2..65c5d809dc 100644 --- a/crates/ui-egui/src/i18n/pl.tsv +++ b/crates/ui-egui/src/i18n/pl.tsv @@ -3856,6 +3856,7 @@ theme Appearance Wygląd Command Click to Select Objects Behind Kliknięcie z Command zaznacza obiekty pod spodem Constrain Angle Kąt ograniczenia Constrain Width and Height Proportions Zachowaj proporcje szerokości i wysokości + Copy Width to Height Kopiuj szerokość do wysokości Construction Guides Linie konstrukcyjne Curvature Tool Narzędzie Krzywizna Data Recovery Odzyskiwanie danych diff --git a/crates/ui-egui/src/i18n/pt-br.tsv b/crates/ui-egui/src/i18n/pt-br.tsv index 9c7e0fddd5..42d0bedbaf 100644 --- a/crates/ui-egui/src/i18n/pt-br.tsv +++ b/crates/ui-egui/src/i18n/pt-br.tsv @@ -552,6 +552,7 @@ antiAlias Sharp Nítido Consolidate All Windows Consolidar Todas as Janelas Constrain Angle Ângulo de Restrição Constrain Width and Height Proportions Restringir Proporções de Largura e Altura + Copy Width to Height Copiar Largura para Altura Construction Guides Guias de Construção Contextual Alternates Variantes Contextuais Contextual Task Bar Barra de Tarefas Contextual diff --git a/crates/ui-egui/src/i18n/ru.tsv b/crates/ui-egui/src/i18n/ru.tsv index 87424a1938..6d073b7b6a 100644 --- a/crates/ui-egui/src/i18n/ru.tsv +++ b/crates/ui-egui/src/i18n/ru.tsv @@ -605,6 +605,7 @@ font-technology Variable Вариативные Consolidate All Windows Объединить все окна Constrain Angle Ограничить угол Constrain Width and Height Proportions Сохранять пропорции ширины и высоты + Copy Width to Height Копировать ширину в высоту Construction Guides Направляющие построения Contextual Alternates Контекстные альтернативы Contextual Task Bar Контекстная панель задач diff --git a/crates/ui-egui/src/i18n/sv.tsv b/crates/ui-egui/src/i18n/sv.tsv index 62ac5b67a8..55954bc41d 100644 --- a/crates/ui-egui/src/i18n/sv.tsv +++ b/crates/ui-egui/src/i18n/sv.tsv @@ -594,6 +594,7 @@ font-technology Variable Variabla Consolidate All Windows Samla alla fönster Constrain Angle Begränsa vinkel Constrain Width and Height Proportions Behåll proportioner för bredd och höjd + Copy Width to Height Kopiera bredd till höjd Construction Guides Konstruktionsstödlinjer Contextual Alternates Kontextuella alternativ Contextual Task Bar Kontextuellt aktivitetsfält diff --git a/crates/ui-egui/src/i18n/tr.tsv b/crates/ui-egui/src/i18n/tr.tsv index 9076b8da7c..e8d0665fd2 100644 --- a/crates/ui-egui/src/i18n/tr.tsv +++ b/crates/ui-egui/src/i18n/tr.tsv @@ -587,6 +587,7 @@ font-technology Variable Değişken Consolidate All Windows Tüm Pencereleri Birleştir Constrain Angle Açıyı Sınırla Constrain Width and Height Proportions Genişlik ve Yükseklik Oranlarını Sınırla + Copy Width to Height Genişliği Yüksekliğe Kopyala Construction Guides İnşaat Kılavuzları Contextual Alternates Bağlamsal Alternatifler Contextual Task Bar Bağlamsal Görev Çubuğu diff --git a/crates/ui-egui/src/i18n/uk.tsv b/crates/ui-egui/src/i18n/uk.tsv index c701f1bd5d..7e48b16e08 100644 --- a/crates/ui-egui/src/i18n/uk.tsv +++ b/crates/ui-egui/src/i18n/uk.tsv @@ -601,6 +601,7 @@ font-technology Variable Варіативні Consolidate All Windows Об’єднати всі вікна Constrain Angle Обмежити кут Constrain Width and Height Proportions Зберігати пропорції ширини та висоти + Copy Width to Height Копіювати ширину у висоту Construction Guides Напрямні побудови Contextual Alternates Контекстні альтернативи Contextual Task Bar Контекстна панель завдань diff --git a/crates/ui-egui/src/i18n/vi.tsv b/crates/ui-egui/src/i18n/vi.tsv index 7ce09032d1..665ed7b880 100644 --- a/crates/ui-egui/src/i18n/vi.tsv +++ b/crates/ui-egui/src/i18n/vi.tsv @@ -705,6 +705,7 @@ font-technology Variable Biến thiên Constrain Giữ tỷ lệ Constrain Angle Ràng buộc góc Constrain Width and Height Proportions Ràng buộc tỷ lệ chiều rộng và chiều cao + Copy Width to Height Sao chép chiều rộng sang chiều cao Construction Guides Đường căn xây dựng Contextual Alternates Ký tự thay thế theo ngữ cảnh Contextual Task Bar Thanh tác vụ theo ngữ cảnh diff --git a/crates/ui-egui/src/i18n/zh-hans.tsv b/crates/ui-egui/src/i18n/zh-hans.tsv index 86f04f416e..39b52139a6 100644 --- a/crates/ui-egui/src/i18n/zh-hans.tsv +++ b/crates/ui-egui/src/i18n/zh-hans.tsv @@ -552,6 +552,7 @@ antiAlias Sharp 锐利 Consolidate All Windows 合并所有窗口 Constrain Angle 约束角度 Constrain Width and Height Proportions 约束宽高比例 + Copy Width to Height 将宽度复制到高度 Construction Guides 构造参考线 Contextual Alternates 上下文替代 Contextual Task Bar 上下文任务栏 diff --git a/crates/ui-egui/src/i18n/zh-hant.tsv b/crates/ui-egui/src/i18n/zh-hant.tsv index 65e5274812..2fc830e1cb 100644 --- a/crates/ui-egui/src/i18n/zh-hant.tsv +++ b/crates/ui-egui/src/i18n/zh-hant.tsv @@ -569,6 +569,7 @@ font-technology Variable 可變 Consolidate All Windows 合併所有視窗 Constrain Angle 強制角度 Constrain Width and Height Proportions 強制寬度與高度比例 + Copy Width to Height 將寬度複製到高度 Construction Guides 建構參考線 Contextual Alternates 前後關聯替代字 Contextual Task Bar 快捷工作列 diff --git a/docs/target-app-parity.md b/docs/target-app-parity.md index a81d1add49..f9015038e3 100644 --- a/docs/target-app-parity.md +++ b/docs/target-app-parity.md @@ -1206,6 +1206,7 @@ Moved from the ROADMAP's "Shipped so far" on 2026-10-10. Update it when a featur While a spiral is dragged out, Alt adds or removes whole winds of four segments and Ctrl/Cmd changes the decay. The spiral's inner end keeps the distance from the center it had on the first modified drag event, while the outer end follows the pointer. The [default keyboard shortcuts](https://web.archive.org/web/20260726060015/https://helpx.adobe.com/illustrator/using/default-keyboard-shortcuts.html) (archived copy) list Alt-drag to add or subtract winds and Ctrl-drag to change the decay rate; [Draw spirals](https://helpx.adobe.com/illustrator/desktop/draw-shapes-and-paths/draw-shapes/draw-spirals.html) defines four segments per full wind and Decay as the amount each wind decreases. An 80% spiral has 80% of its outer radius after four segments; newly drawn spirals with the same settings wind more broadly than in earlier VectorCraft builds. Rounding the fitted count to whole winds from the count on the first Alt-only drag event, the held inner radius, the ranges (2…1000 segments, 5…99.99 % decay), Ctrl/Cmd taking precedence when both are held, and the new values staying as Spiral tool options are our own rules. Switching back to Alt uses the current count as its new base while keeping the held inner end. Escape while an arc, spiral or grid is dragged out cancels it and puts back the options its keys, Alt and Ctrl/Cmd changed (slope, open or closed, base axis, segments, decay, dividers and skews), so the next drag and the tool's options start from the values before the canceled drag; a drag that is let go keeps them, and an option set with `tool.setOption` during the drag stays. This is VectorCraft's own rule. VectorCraft's own Anchors field in the Ellipse dialog (a click with the Ellipse tool; `shape.ellipse {anchors}`, part of #7840) sets how many smooth anchors the ellipse has, 4 by default; 4 draws a live ellipse, and any other count from 2 to 1000 draws a plain path with the anchors spaced evenly by angle, fitted to the typed width and height. The count last confirmed stays as the Ellipse tool's `anchors` option, and the next Ellipse dialog opens on it (`ellipse_with_four_anchors_is_the_live_ellipse`, `ellipse_anchors_draw_that_many_anchors_on_the_ellipse`, `ellipse_refuses_a_bad_anchor_count`, `the_ellipse_dialog_draws_and_keeps_its_anchor_count`). + In the Ellipse dialog, a click on the word Height copies the Width value into the Height field, so OK draws a circle of that width, as [the help page](https://web.archive.org/web/20210601162814/https://helpx.adobe.com/pdf/illustrator_reference.pdf#page=90) describes for drawing ellipses. The Rectangle and Rounded Rectangle dialogs keep plain labels. VectorCraft's own rules: the word Height is a button that Space or Enter also presses, and that Enter does not press OK (nor does Enter on the Constrain Width and Height Proportions button); with the link on, the link stays on and keeps the circle when a side is typed next; a Width that is empty or not a distance, including one the field refuses as the click leaves it, leaves Height as it is; Cancel discards the copy. Evidence: `dialogs::shapes::tests::{clicking_height_in_the_ellipse_dialog_copies_width_into_height, the_ellipse_height_button_copies_width_from_the_keyboard_and_keeps_the_link_round, enter_on_the_link_button_turns_the_link_on_without_pressing_ok, only_the_ellipse_dialog_has_the_height_button, copying_width_takes_only_a_width_that_reads}`. - **Cutting:** Eraser, Scissors, Knife, Mirror & Cut, Line Cut and Rectangle Cut (real geometry, compound paths keep their holes). A Scissors cut (`path.split`) leaves one of the two new end points selected and the rest of the path unselected, as [Cut paths](https://helpx.adobe.com/illustrator/desktop/draw-shapes-and-paths/modify-paths/split-paths.html) and the "Split a path" section of the [CS3 user guide](https://help.adobe.com/archive/en_US/illustrator/cs3/illustrator_cs3_help.pdf) describe: the two end points lie on top of each other, and a Direct Selection drag from them moves the selected one with its handles and no other anchor. A closed path cut once stays one open path. While Alt is held, the Scissors tool works as the Add Anchor Point tool ([Default keyboard shortcuts](https://web.archive.org/web/20260726060015/https://helpx.adobe.com/illustrator/using/default-keyboard-shortcuts.html)): a click on a segment adds an anchor point without cutting (`path.insertAnchor`), and the pointer shows the Add Anchor Point cursor. When Alt is let go, a click cuts again. From 9d93240055f34bcdb0b49c523c4cbbc9b6c8895d Mon Sep 17 00:00:00 2001 From: dotCooCoo Date: Mon, 16 Nov 2026 08:13:36 -0800 Subject: [PATCH 2/3] Ellipse: the Height button's help page link opens at Draw ellipses --- crates/ui-egui/src/dialogs/shapes.rs | 2 +- docs/target-app-parity.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/crates/ui-egui/src/dialogs/shapes.rs b/crates/ui-egui/src/dialogs/shapes.rs index 651fa098ff..cf78326cac 100644 --- a/crates/ui-egui/src/dialogs/shapes.rs +++ b/crates/ui-egui/src/dialogs/shapes.rs @@ -405,7 +405,7 @@ fn height_label_button(ui: &mut egui::Ui, label: &str) -> (egui::Response, bool) } /// Height takes the Width the dialog holds (help page "Draw ellipses", -/// ). +/// ). /// A Width that is missing, empty, not a distance or not finite leaves Height as it is. With the /// link on, the link keeps the circle from then on (proportions 1 : 1), or keeps no proportions /// when Width is 0; the link stays on. diff --git a/docs/target-app-parity.md b/docs/target-app-parity.md index f9015038e3..f682cc0a47 100644 --- a/docs/target-app-parity.md +++ b/docs/target-app-parity.md @@ -1206,7 +1206,7 @@ Moved from the ROADMAP's "Shipped so far" on 2026-10-10. Update it when a featur While a spiral is dragged out, Alt adds or removes whole winds of four segments and Ctrl/Cmd changes the decay. The spiral's inner end keeps the distance from the center it had on the first modified drag event, while the outer end follows the pointer. The [default keyboard shortcuts](https://web.archive.org/web/20260726060015/https://helpx.adobe.com/illustrator/using/default-keyboard-shortcuts.html) (archived copy) list Alt-drag to add or subtract winds and Ctrl-drag to change the decay rate; [Draw spirals](https://helpx.adobe.com/illustrator/desktop/draw-shapes-and-paths/draw-shapes/draw-spirals.html) defines four segments per full wind and Decay as the amount each wind decreases. An 80% spiral has 80% of its outer radius after four segments; newly drawn spirals with the same settings wind more broadly than in earlier VectorCraft builds. Rounding the fitted count to whole winds from the count on the first Alt-only drag event, the held inner radius, the ranges (2…1000 segments, 5…99.99 % decay), Ctrl/Cmd taking precedence when both are held, and the new values staying as Spiral tool options are our own rules. Switching back to Alt uses the current count as its new base while keeping the held inner end. Escape while an arc, spiral or grid is dragged out cancels it and puts back the options its keys, Alt and Ctrl/Cmd changed (slope, open or closed, base axis, segments, decay, dividers and skews), so the next drag and the tool's options start from the values before the canceled drag; a drag that is let go keeps them, and an option set with `tool.setOption` during the drag stays. This is VectorCraft's own rule. VectorCraft's own Anchors field in the Ellipse dialog (a click with the Ellipse tool; `shape.ellipse {anchors}`, part of #7840) sets how many smooth anchors the ellipse has, 4 by default; 4 draws a live ellipse, and any other count from 2 to 1000 draws a plain path with the anchors spaced evenly by angle, fitted to the typed width and height. The count last confirmed stays as the Ellipse tool's `anchors` option, and the next Ellipse dialog opens on it (`ellipse_with_four_anchors_is_the_live_ellipse`, `ellipse_anchors_draw_that_many_anchors_on_the_ellipse`, `ellipse_refuses_a_bad_anchor_count`, `the_ellipse_dialog_draws_and_keeps_its_anchor_count`). - In the Ellipse dialog, a click on the word Height copies the Width value into the Height field, so OK draws a circle of that width, as [the help page](https://web.archive.org/web/20210601162814/https://helpx.adobe.com/pdf/illustrator_reference.pdf#page=90) describes for drawing ellipses. The Rectangle and Rounded Rectangle dialogs keep plain labels. VectorCraft's own rules: the word Height is a button that Space or Enter also presses, and that Enter does not press OK (nor does Enter on the Constrain Width and Height Proportions button); with the link on, the link stays on and keeps the circle when a side is typed next; a Width that is empty or not a distance, including one the field refuses as the click leaves it, leaves Height as it is; Cancel discards the copy. Evidence: `dialogs::shapes::tests::{clicking_height_in_the_ellipse_dialog_copies_width_into_height, the_ellipse_height_button_copies_width_from_the_keyboard_and_keeps_the_link_round, enter_on_the_link_button_turns_the_link_on_without_pressing_ok, only_the_ellipse_dialog_has_the_height_button, copying_width_takes_only_a_width_that_reads}`. + In the Ellipse dialog, a click on the word Height copies the Width value into the Height field, so OK draws a circle of that width, as [the help page](https://web.archive.org/web/20210601162814/https://helpx.adobe.com/pdf/illustrator_reference.pdf#page=140) describes for drawing ellipses. The Rectangle and Rounded Rectangle dialogs keep plain labels. VectorCraft's own rules: the word Height is a button that Space or Enter also presses, and that Enter does not press OK (nor does Enter on the Constrain Width and Height Proportions button); with the link on, the link stays on and keeps the circle when a side is typed next; a Width that is empty or not a distance, including one the field refuses as the click leaves it, leaves Height as it is; Cancel discards the copy. Evidence: `dialogs::shapes::tests::{clicking_height_in_the_ellipse_dialog_copies_width_into_height, the_ellipse_height_button_copies_width_from_the_keyboard_and_keeps_the_link_round, enter_on_the_link_button_turns_the_link_on_without_pressing_ok, only_the_ellipse_dialog_has_the_height_button, copying_width_takes_only_a_width_that_reads}`. - **Cutting:** Eraser, Scissors, Knife, Mirror & Cut, Line Cut and Rectangle Cut (real geometry, compound paths keep their holes). A Scissors cut (`path.split`) leaves one of the two new end points selected and the rest of the path unselected, as [Cut paths](https://helpx.adobe.com/illustrator/desktop/draw-shapes-and-paths/modify-paths/split-paths.html) and the "Split a path" section of the [CS3 user guide](https://help.adobe.com/archive/en_US/illustrator/cs3/illustrator_cs3_help.pdf) describe: the two end points lie on top of each other, and a Direct Selection drag from them moves the selected one with its handles and no other anchor. A closed path cut once stays one open path. While Alt is held, the Scissors tool works as the Add Anchor Point tool ([Default keyboard shortcuts](https://web.archive.org/web/20260726060015/https://helpx.adobe.com/illustrator/using/default-keyboard-shortcuts.html)): a click on a segment adds an anchor point without cutting (`path.insertAnchor`), and the pointer shows the Add Anchor Point cursor. When Alt is let go, a click cuts again. From c6924c2954708ed3918631eaafe191129c5f1dc5 Mon Sep 17 00:00:00 2001 From: dotCooCoo Date: Mon, 16 Nov 2026 08:43:14 -0800 Subject: [PATCH 3/3] Ellipse: test that a Height typed and not committed does not outlast the copy --- crates/ui-egui/src/dialogs/shapes.rs | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/crates/ui-egui/src/dialogs/shapes.rs b/crates/ui-egui/src/dialogs/shapes.rs index cf78326cac..4d967c83db 100644 --- a/crates/ui-egui/src/dialogs/shapes.rs +++ b/crates/ui-egui/src/dialogs/shapes.rs @@ -956,6 +956,22 @@ mod tests { h.run_steps(3); assert_eq!(dialog_size(&h), (50.0, 50.0)); + // A Height typed and not committed does not outlast the copy: a distance is replaced by + // Width, and a Height the field refuses keeps the copy from happening, as it keeps OK from + // confirming. + for (typed, after) in [("70 pt", (50.0, 50.0)), ("tall", (50.0, 30.0))] { + h.state_mut().ui.dialog.as_mut().unwrap().fields.insert("height".into(), json!(30.0)); + h.run_steps(2); + h.get_by_role_and_label(Role::TextInput, "Height:").focus(); + h.run_steps(2); + h.key_press_modifiers(all, egui::Key::A); + h.get_by_role_and_label(Role::TextInput, "Height:").type_text(typed); + h.run_steps(2); + h.get_by_role_and_label(Role::Button, "Height:").click(); + h.run_steps(3); + assert_eq!(dialog_size(&h), after, "{typed:?}"); + } + // Cancel: nothing is drawn. let undo = |h: &egui_kittest::Harness<'_, VectorcraftApp>| h.state().session.active().unwrap().history.undo.len(); let before = undo(&h);