mirror of
https://github.com/storytold/vectorcraft.git
synced 2026-11-24 18:32:23 +00:00
Text styles panel: add item right-click context menu (Options, Duplicate, Delete, Redefine) (#8745)
* Text styles panel: add item right-click context menu (Options, Duplicate, Delete, Redefine) * fix(text-styles): require text target for clear overrides and update parity docs
This commit is contained in:
@@ -98,7 +98,7 @@ fn highlight_made(ctx: &egui::Context, kind: Kind, names: Vec<String>) {
|
||||
|
||||
/// Duplicates the styles `names` (`charStyle.duplicate`, `paraStyle.duplicate`) in one undo step
|
||||
/// and highlights the copies.
|
||||
fn duplicate(app: &mut VectorcraftApp, ctx: &egui::Context, kind: Kind, names: &[String]) {
|
||||
fn duplicate(app: &mut VectorcraftApp, ctx: &egui::Context, kind: Kind, names: &[String]) -> Vec<String> {
|
||||
let p = kind.prefix();
|
||||
let made = if let [name] = names {
|
||||
app.run(&format!("{p}.duplicate"), json!({ "name": name })).map(|r| vec![r])
|
||||
@@ -108,7 +108,11 @@ fn duplicate(app: &mut VectorcraftApp, ctx: &egui::Context, kind: Kind, names: &
|
||||
app.run("command.batch", json!({ "label": label, "commands": commands })).map(|r| r["results"].as_array().cloned().unwrap_or_default())
|
||||
};
|
||||
if let Ok(made) = made {
|
||||
highlight_made(ctx, kind, made.iter().filter_map(|r| r["name"].as_str().map(str::to_string)).collect());
|
||||
let names: Vec<String> = made.iter().filter_map(|r| r["name"].as_str().map(str::to_string)).collect();
|
||||
highlight_made(ctx, kind, names.clone());
|
||||
names
|
||||
} else {
|
||||
vec![]
|
||||
}
|
||||
}
|
||||
|
||||
@@ -254,6 +258,48 @@ fn open_style_options(app: &mut VectorcraftApp, kind: Kind, name: &str) {
|
||||
app.run(command, json!({ "name": name })).ok();
|
||||
}
|
||||
|
||||
/// An item's right-click context menu in the Character Styles / Paragraph Styles panel.
|
||||
fn item_context_menu(app: &mut VectorcraftApp, ui: &mut Ui, kind: Kind, name: &str, normal: &str, sel: &mut Vec<String>, listed: &[&str]) {
|
||||
let p = kind.prefix();
|
||||
let is_normal = name == normal;
|
||||
let targets = dragged(sel, listed, name);
|
||||
let doomed: Vec<String> = targets.iter().filter(|s| *s != normal).cloned().collect();
|
||||
let has_text_target = text_style(app).is_some();
|
||||
|
||||
let options_label = crate::i18n::fmt(tl!("{kind} Style Options…"), &[("kind", kind.what_label())]);
|
||||
if menu_item(ui, &options_label, !is_normal, false) {
|
||||
open_style_options(app, kind, name);
|
||||
ui.close();
|
||||
}
|
||||
let duplicate_label = crate::i18n::fmt(tl!("Duplicate {kind} Style"), &[("kind", kind.what_label())]);
|
||||
if menu_item(ui, &duplicate_label, true, false) {
|
||||
let made = duplicate(app, ui.ctx(), kind, &targets);
|
||||
if !made.is_empty() {
|
||||
*sel = made;
|
||||
}
|
||||
ui.close();
|
||||
}
|
||||
let delete_label = crate::i18n::fmt(tl!("Delete {kind} Style"), &[("kind", kind.what_label())]);
|
||||
if menu_item(ui, &delete_label, !is_normal && !doomed.is_empty(), false) {
|
||||
if app.run(&format!("{p}.delete"), json!({ "names": doomed })).is_ok() {
|
||||
*sel = vec![];
|
||||
set_highlighted(ui.ctx(), kind, vec![]);
|
||||
}
|
||||
ui.close();
|
||||
}
|
||||
ui.separator();
|
||||
let redefine_label = crate::i18n::fmt(tl!("Redefine {kind} Style"), &[("kind", kind.what_label())]);
|
||||
if menu_item(ui, &redefine_label, has_text_target, false) {
|
||||
end_typing(app);
|
||||
app.run(&format!("{p}.redefine"), target(app, kind, json!({ "name": name }))).ok();
|
||||
ui.close();
|
||||
}
|
||||
if menu_item(ui, tl!("Clear Overrides"), has_text_target, false) {
|
||||
app.run(&format!("{p}.apply"), apply_target(app, kind, json!({ "name": name, "clearOverrides": true }))).ok();
|
||||
ui.close();
|
||||
}
|
||||
}
|
||||
|
||||
/// The style list and its New and Delete buttons. Shift-click highlights every style from the
|
||||
/// last one clicked without Shift through this one, and Cmd/Ctrl-click adds or removes one; both
|
||||
/// leave the text as it is. Delete deletes every highlighted style but the Normal style.
|
||||
@@ -296,6 +342,11 @@ pub fn show(app: &mut VectorcraftApp, ui: &mut Ui, kind: Kind) {
|
||||
if scroll_to.as_deref() == Some(name.as_str()) {
|
||||
ui.scroll_to_rect(r, None);
|
||||
}
|
||||
if resp.secondary_clicked() && !sel.contains(name) {
|
||||
sel = vec![name.clone()];
|
||||
set_pstate(ui.ctx(), kind.anchor_key(), name.clone());
|
||||
set_highlighted(ui.ctx(), kind, sel.clone());
|
||||
}
|
||||
let (fill, outline) = row_look(is_cur, sel.contains(name), resp.hovered(), &t);
|
||||
if let Some(fill) = fill {
|
||||
ui.painter().rect_filled(r, 0.0, fill);
|
||||
@@ -308,6 +359,10 @@ pub fn show(app: &mut VectorcraftApp, ui: &mut Ui, kind: Kind) {
|
||||
let shown = super::label_or_name(name, *name == normal);
|
||||
let label = if overridden { format!("{shown}+") } else { shown.to_string() };
|
||||
ui.painter().text(r.left_center() + vec2(8.0, 0.0), egui::Align2::LEFT_CENTER, label, egui::FontId::proportional(12.5), t.text);
|
||||
resp.widget_info(|| egui::WidgetInfo::selected(egui::Role::ListItem, ui.is_enabled(), sel.contains(name), shown.to_string()));
|
||||
resp.context_menu(|ui| {
|
||||
item_context_menu(app, ui, kind, name, &normal, &mut sel, &listed);
|
||||
});
|
||||
if resp.clicked() {
|
||||
clicked = Some((name.clone(), ui.input(|i| i.modifiers)));
|
||||
}
|
||||
|
||||
@@ -1478,3 +1478,249 @@ fn character_style_unicode_boundary_capture_controls() {
|
||||
capture_from_ui(Some((2, 5)), redefine, footer, true);
|
||||
}
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn right_click_context_menu_in_character_styles_panel() {
|
||||
use egui::vec2;
|
||||
use egui_kittest::Harness;
|
||||
use egui_kittest::kittest::{NodeT, Queryable};
|
||||
|
||||
let mut app = VectorcraftApp::new(vectorcraft_engine::Session::new(), Default::default());
|
||||
app.run("file.new", json!({"width": 300, "height": 200})).unwrap();
|
||||
let id = app.run("text.create", json!({"x": 20, "y": 50, "text": "Hello world", "size": 18})).unwrap()["id"].as_u64().unwrap();
|
||||
app.run("select.set", json!({"ids": [id]})).unwrap();
|
||||
app.run("charStyle.new", json!({"name": "Body", "attrs": {"size": 18.0}})).unwrap();
|
||||
|
||||
let mut h = Harness::builder().with_size(vec2(280.0, 500.0)).with_accessibility_check(false).build_ui_state(
|
||||
|ui, app: &mut VectorcraftApp| {
|
||||
show(app, ui, Kind::Char);
|
||||
},
|
||||
app,
|
||||
);
|
||||
h.run_steps(2);
|
||||
|
||||
// Initial state: Body is unselected in panel
|
||||
assert_eq!(pstate::<Option<String>>(&h.ctx, Kind::Char.key()), None, "Body is initially unselected");
|
||||
|
||||
// Right-click unselected row "Body"
|
||||
let node = h.get_by_label("Body");
|
||||
let pos = node.rect().center();
|
||||
h.event(egui::Event::PointerMoved(pos));
|
||||
h.event(egui::Event::PointerButton { pos, button: egui::PointerButton::Secondary, pressed: true, modifiers: Default::default() });
|
||||
h.event(egui::Event::PointerButton { pos, button: egui::PointerButton::Secondary, pressed: false, modifiers: Default::default() });
|
||||
h.run_steps(2);
|
||||
|
||||
// Right-clicking highlights it and opens context menu
|
||||
assert_eq!(pstate::<Option<String>>(&h.ctx, Kind::Char.key()).as_deref(), Some("Body"));
|
||||
|
||||
let opt = h.get_by_label(" Character Style Options…");
|
||||
let dup = h.get_by_label(" Duplicate Character Style");
|
||||
let del = h.get_by_label(" Delete Character Style");
|
||||
let redefine = h.get_by_label(" Redefine Character Style");
|
||||
let clear = h.get_by_label(" Clear Overrides");
|
||||
|
||||
assert!(!opt.accesskit_node().is_disabled());
|
||||
assert!(!dup.accesskit_node().is_disabled());
|
||||
assert!(!del.accesskit_node().is_disabled());
|
||||
assert!(!redefine.accesskit_node().is_disabled());
|
||||
assert!(!clear.accesskit_node().is_disabled());
|
||||
|
||||
// Clicking "Duplicate Character Style" creates a copy (e.g. "Body copy")
|
||||
dup.click();
|
||||
h.run_steps(2);
|
||||
|
||||
let all_styles = styles(h.state_mut(), Kind::Char);
|
||||
assert!(all_styles.iter().any(|s| s.0 == "Body copy"), "Body copy was created: {all_styles:?}");
|
||||
assert_eq!(pstate::<Option<String>>(&h.ctx, Kind::Char.key()).as_deref(), Some("Body copy"), "copy is highlighted");
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn right_click_context_menu_in_paragraph_styles_panel() {
|
||||
use egui::vec2;
|
||||
use egui_kittest::Harness;
|
||||
use egui_kittest::kittest::{NodeT, Queryable};
|
||||
|
||||
let mut app = VectorcraftApp::new(vectorcraft_engine::Session::new(), Default::default());
|
||||
app.run("file.new", json!({"width": 300, "height": 200})).unwrap();
|
||||
let id = app.run("text.create", json!({"x": 20, "y": 50, "text": "Paragraph text", "size": 14})).unwrap()["id"].as_u64().unwrap();
|
||||
app.run("select.set", json!({"ids": [id]})).unwrap();
|
||||
app.run("paraStyle.new", json!({"name": "Headline"})).unwrap();
|
||||
|
||||
let undo_len = app.session.doc().unwrap().history.undo.len();
|
||||
|
||||
let mut h = Harness::builder().with_size(vec2(280.0, 500.0)).with_accessibility_check(false).build_ui_state(
|
||||
|ui, app: &mut VectorcraftApp| {
|
||||
show(app, ui, Kind::Para);
|
||||
},
|
||||
app,
|
||||
);
|
||||
h.run_steps(2);
|
||||
|
||||
// Initial state: Headline is unselected
|
||||
assert_eq!(pstate::<Option<String>>(&h.ctx, Kind::Para.key()), None, "Headline is initially unselected");
|
||||
|
||||
// Right-click unselected row "Headline"
|
||||
let node = h.get_by_label("Headline");
|
||||
let pos = node.rect().center();
|
||||
h.event(egui::Event::PointerMoved(pos));
|
||||
h.event(egui::Event::PointerButton { pos, button: egui::PointerButton::Secondary, pressed: true, modifiers: Default::default() });
|
||||
h.event(egui::Event::PointerButton { pos, button: egui::PointerButton::Secondary, pressed: false, modifiers: Default::default() });
|
||||
h.run_steps(2);
|
||||
|
||||
// Highlights it and opens context menu
|
||||
assert_eq!(pstate::<Option<String>>(&h.ctx, Kind::Para.key()).as_deref(), Some("Headline"));
|
||||
|
||||
let opt = h.get_by_label(" Paragraph Style Options…");
|
||||
let dup = h.get_by_label(" Duplicate Paragraph Style");
|
||||
let del = h.get_by_label(" Delete Paragraph Style");
|
||||
let redefine = h.get_by_label(" Redefine Paragraph Style");
|
||||
let clear = h.get_by_label(" Clear Overrides");
|
||||
|
||||
assert!(!opt.accesskit_node().is_disabled());
|
||||
assert!(!dup.accesskit_node().is_disabled());
|
||||
assert!(!del.accesskit_node().is_disabled());
|
||||
assert!(!redefine.accesskit_node().is_disabled());
|
||||
assert!(!clear.accesskit_node().is_disabled());
|
||||
|
||||
// Clicking "Delete Paragraph Style" deletes the style with undo support
|
||||
del.click();
|
||||
h.run_steps(2);
|
||||
|
||||
let all_styles = styles(h.state_mut(), Kind::Para);
|
||||
assert!(!all_styles.iter().any(|s| s.0 == "Headline"), "Headline deleted: {all_styles:?}");
|
||||
assert_eq!(pstate::<Option<String>>(&h.ctx, Kind::Para.key()), None, "selection cleared after delete");
|
||||
assert_eq!(h.state().session.doc().unwrap().history.undo.len(), undo_len + 1, "delete recorded one undo step");
|
||||
|
||||
// Test undo
|
||||
h.state_mut().run("edit.undo", json!({})).unwrap();
|
||||
let restored = styles(h.state_mut(), Kind::Para);
|
||||
assert!(restored.iter().any(|s| s.0 == "Headline"), "Headline restored by undo: {restored:?}");
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn right_click_context_menu_normal_style_disables_options_and_delete() {
|
||||
use egui::vec2;
|
||||
use egui_kittest::Harness;
|
||||
use egui_kittest::kittest::{NodeT, Queryable};
|
||||
|
||||
let mut app = VectorcraftApp::new(vectorcraft_engine::Session::new(), Default::default());
|
||||
app.run("file.new", json!({"width": 300, "height": 200})).unwrap();
|
||||
|
||||
let mut h = Harness::builder().with_size(vec2(280.0, 500.0)).with_accessibility_check(false).build_ui_state(
|
||||
|ui, app: &mut VectorcraftApp| {
|
||||
show(app, ui, Kind::Char);
|
||||
},
|
||||
app,
|
||||
);
|
||||
h.run_steps(2);
|
||||
|
||||
// Right-click Normal Character Style row
|
||||
let node = h.get_by_label("[Normal Character Style]");
|
||||
let pos = node.rect().center();
|
||||
h.event(egui::Event::PointerMoved(pos));
|
||||
h.event(egui::Event::PointerButton { pos, button: egui::PointerButton::Secondary, pressed: true, modifiers: Default::default() });
|
||||
h.event(egui::Event::PointerButton { pos, button: egui::PointerButton::Secondary, pressed: false, modifiers: Default::default() });
|
||||
h.run_steps(2);
|
||||
|
||||
let opt = h.get_by_label(" Character Style Options…");
|
||||
let dup = h.get_by_label(" Duplicate Character Style");
|
||||
let del = h.get_by_label(" Delete Character Style");
|
||||
|
||||
assert!(opt.accesskit_node().is_disabled(), "Options disabled for Normal style");
|
||||
assert!(!dup.accesskit_node().is_disabled(), "Duplicate enabled for Normal style");
|
||||
assert!(del.accesskit_node().is_disabled(), "Delete disabled for Normal style");
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn right_click_context_menu_preserves_multiselection() {
|
||||
use egui::vec2;
|
||||
use egui_kittest::Harness;
|
||||
use egui_kittest::kittest::Queryable;
|
||||
|
||||
let mut app = VectorcraftApp::new(vectorcraft_engine::Session::new(), Default::default());
|
||||
app.run("file.new", json!({"width": 300, "height": 200})).unwrap();
|
||||
app.run("charStyle.new", json!({"name": "Style A"})).unwrap();
|
||||
app.run("charStyle.new", json!({"name": "Style B"})).unwrap();
|
||||
|
||||
let mut h = Harness::builder().with_size(vec2(280.0, 500.0)).with_accessibility_check(false).build_ui_state(
|
||||
|ui, app: &mut VectorcraftApp| {
|
||||
show(app, ui, Kind::Char);
|
||||
},
|
||||
app,
|
||||
);
|
||||
h.run_steps(2);
|
||||
|
||||
// Highlight both styles in pstate
|
||||
set_highlighted(&h.ctx, Kind::Char, vec!["Style A".into(), "Style B".into()]);
|
||||
h.run_steps(2);
|
||||
|
||||
// Right-click Style B (which is part of the multi-selection)
|
||||
let node = h.get_by_label("Style B");
|
||||
let pos = node.rect().center();
|
||||
h.event(egui::Event::PointerMoved(pos));
|
||||
h.event(egui::Event::PointerButton { pos, button: egui::PointerButton::Secondary, pressed: true, modifiers: Default::default() });
|
||||
h.event(egui::Event::PointerButton { pos, button: egui::PointerButton::Secondary, pressed: false, modifiers: Default::default() });
|
||||
h.run_steps(2);
|
||||
|
||||
// Multiselection is preserved
|
||||
let sel = highlighted(h.state(), &h.ctx, Kind::Char, &["[Normal Character Style]", "Style A", "Style B"]);
|
||||
assert_eq!(sel, vec!["Style A".to_string(), "Style B".to_string()], "multi-selection preserved on right-click");
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn right_click_context_menu_clear_overrides_requires_text_target() {
|
||||
use egui::vec2;
|
||||
use egui_kittest::Harness;
|
||||
use egui_kittest::kittest::{NodeT, Queryable};
|
||||
|
||||
let mut app = VectorcraftApp::new(vectorcraft_engine::Session::new(), Default::default());
|
||||
app.run("file.new", json!({"width": 300, "height": 200})).unwrap();
|
||||
app.run("charStyle.new", json!({"name": "Style 1"})).unwrap();
|
||||
|
||||
// Select a non-text shape: rectangle
|
||||
let rect_id = app.run("shape.rectangle", json!({"x": 20, "y": 20, "width": 60, "height": 60})).unwrap()["id"].as_u64().unwrap();
|
||||
app.run("select.set", json!({"ids": [rect_id]})).unwrap();
|
||||
|
||||
let mut h = Harness::builder().with_size(vec2(280.0, 500.0)).with_accessibility_check(false).build_ui_state(
|
||||
|ui, app: &mut VectorcraftApp| {
|
||||
show(app, ui, Kind::Char);
|
||||
},
|
||||
app,
|
||||
);
|
||||
h.run_steps(2);
|
||||
|
||||
// Right-click Style 1
|
||||
let node = h.get_by_label("Style 1");
|
||||
let pos = node.rect().center();
|
||||
h.event(egui::Event::PointerMoved(pos));
|
||||
h.event(egui::Event::PointerButton { pos, button: egui::PointerButton::Secondary, pressed: true, modifiers: Default::default() });
|
||||
h.event(egui::Event::PointerButton { pos, button: egui::PointerButton::Secondary, pressed: false, modifiers: Default::default() });
|
||||
h.run_steps(2);
|
||||
|
||||
let clear_overrides = h.get_by_label(" Clear Overrides");
|
||||
let redefine = h.get_by_label(" Redefine Character Style");
|
||||
assert!(clear_overrides.accesskit_node().is_disabled(), "Clear Overrides disabled when only a rectangle is selected");
|
||||
assert!(redefine.accesskit_node().is_disabled(), "Redefine disabled when only a rectangle is selected");
|
||||
|
||||
// Close menu
|
||||
h.event(egui::Event::Key { key: egui::Key::Escape, physical_key: None, pressed: true, repeat: false, modifiers: Default::default() });
|
||||
h.run_steps(2);
|
||||
|
||||
// Now select a text object
|
||||
let text_id = h.state_mut().run("text.create", json!({"x": 10, "y": 10, "text": "Hello"})).unwrap()["id"].as_u64().unwrap();
|
||||
h.state_mut().run("select.set", json!({"ids": [text_id]})).unwrap();
|
||||
h.run_steps(2);
|
||||
|
||||
// Right-click Style 1 again
|
||||
let node = h.get_by_label("Style 1");
|
||||
let pos = node.rect().center();
|
||||
h.event(egui::Event::PointerMoved(pos));
|
||||
h.event(egui::Event::PointerButton { pos, button: egui::PointerButton::Secondary, pressed: true, modifiers: Default::default() });
|
||||
h.event(egui::Event::PointerButton { pos, button: egui::PointerButton::Secondary, pressed: false, modifiers: Default::default() });
|
||||
h.run_steps(2);
|
||||
|
||||
let clear_overrides = h.get_by_label(" Clear Overrides");
|
||||
let redefine = h.get_by_label(" Redefine Character Style");
|
||||
assert!(!clear_overrides.accesskit_node().is_disabled(), "Clear Overrides enabled when text is selected");
|
||||
assert!(!redefine.accesskit_node().is_disabled(), "Redefine enabled when text is selected");
|
||||
}
|
||||
|
||||
@@ -59,6 +59,7 @@ Artboard Options forwards the active Artboard tool's Scale Artwork with Artboard
|
||||
| 2026-11-20 | minor | G12: Properties panel Quick Actions include contextual text actions (Create Outlines, Retype, Find and Replace…); headless tests in crates/ui-egui/src/panels/properties/tests.rs; scores and estimates unchanged. |
|
||||
| 2026-11-20 | minor | G12: Actions panel item context menus for action sets (New Action…, New Set…, Duplicate Set, Delete Set, Set Options…) and actions (Play, Record, Duplicate, Delete, Action Options…, Batch…) with selection handling; clicking Duplicate on an action duplicates that action; headless tests in `crates/ui-egui/src/panels/actions.rs`; scores and estimates unchanged. |
|
||||
| 2026-11-19 | minor | G12: Graphic Styles panel item context menus (Options…, Duplicate, Delete, Redefine, Break Link); regression tests in crates/ui-egui/src/panels/graphic_styles.rs; scores and estimates unchanged. |
|
||||
| 2026-11-19 | minor | G12: Character Styles and Paragraph Styles panels item context menus (Options…, Duplicate, Delete, Redefine, Clear Overrides); regression tests in crates/ui-egui/src/panels/text_styles/tests.rs; scores and estimates unchanged. |
|
||||
| 2026-11-19 | minor | G12: Place: show progress window with Cancel for slow placed files exceeding 0.4 s (part of #5930, `file.cancelPlace`); indeterminate moving bar, Cancel (Esc) leaves the document unmodified without undo steps; scores and estimates unchanged. |
|
||||
| 2026-11-18 | minor | G11: SVG export writes physical unit suffixes on the root <svg width="..." height="..."> for documents with physical units (mm, cm, in, pc), preventing drawings from scaling to 75% in external tools and preserving units across round-trips (#864; general unit preference on restart remains open under #864). Estimate 8–15 → 6–13 h. |
|
||||
| 2026-11-18 | minor | G5: Media Controls joins Basic Shapes, UI Frames, Map Markers, Inventory Icons, Skill Icons and Weather Icons as a seventh built-in symbol library (Play, Pause, Stop, Skip Next, Shuffle, Repeat; original procedural vector symbols generated in code, no default 9-slice); estimate decremented (3–13 → 2–12 h). |
|
||||
@@ -522,6 +523,8 @@ macOS cursor delivery (#2292) is narrowed to a native host adapter using the exi
|
||||
|
||||
- **Implemented and tested (2026-11-19):** Graphic Styles panel thumbnail and list views have item context menus with Graphic Style Options…, Duplicate Graphic Style, Delete Graphic Style, Redefine Graphic Style, and Break Link to Graphic Style. Right-click on an unselected style selects it first; existing multi-selections are preserved and offer plural commands ("Duplicate Graphic Styles", "Delete Graphic Styles"). Default Graphic Style disables Options and Delete; large preview remains accessible when holding the secondary button. Regression tests in `crates/ui-egui/src/panels/graphic_styles.rs` verify right-click selection, command dispatch, and one-step undo. Scores and estimates unchanged.
|
||||
|
||||
- **Implemented and tested (2026-11-19):** Character Styles and Paragraph Styles panel rows have item context menus with {Kind} Style Options…, Duplicate {Kind} Style, Delete {Kind} Style, Redefine {Kind} Style, and Clear Overrides. Right-clicking an unselected row highlights it before displaying the menu; right-clicking an item in an existing multi-selection preserves the selection. Style Options and Delete are disabled for the Normal style; Redefine is enabled when active text has styling; Clear Overrides is enabled when text is selected. Duplicate creates `<name> copy` and highlights it; Delete removes non-Normal styles in one undo step. Tests in crates/ui-egui/src/panels/text_styles/tests.rs. Scores and estimates unchanged.
|
||||
|
||||
- **Production workflow addition (2026-11-18):** Window > Production Preflight brings existing output-aware font/overflow checks, linked-file probes and effective image resolution into one panel. Findings select and zoom to affected art, and results recheck after edits, Undo/Redo and external link changes. Resource-art resolution is explicitly not checked. This does not close the remaining G12 gaps or change estimates.
|
||||
|
||||
- **Implemented and tested (2026-11-15):** Swatches list rows and thumbnail cells have item context menus with Swatch Options…, Duplicate Swatch and Delete Swatch. Right-click selects the target without painting art; actions use that item's name and are disabled for reserved or missing swatches. All 39 Swatches tests pass, covering all five views, command dispatch, selection and Undo; the regression fails with the menu hooks removed. Rendered list and thumbnail menus were inspected. Full workspace CI passed on Linux/WSL on the merged branch (all 13 gates), including the test-helper correction for the upstream compile error tracked in #7727; native Windows full CI has two unchanged engine-test failures. Other panels without context menus remain in G12; estimate unchanged.
|
||||
|
||||
+5
-1
@@ -74,6 +74,7 @@ M7 type: Touch Type moves a right-to-left character along its line and up from i
|
||||
| Date | Change | Summary |
|
||||
|---|---|---|
|
||||
| 2026-11-19 | minor | M14/G12: Graphic Styles panel item context menus in thumbnail and list views (Options…, Duplicate, Delete, Redefine, Break Link); regression tests in crates/ui-egui/src/panels/graphic_styles.rs; scores and estimates unchanged. |
|
||||
| 2026-11-19 | minor | M14/G12: Character Styles and Paragraph Styles panels item context menus (Options…, Duplicate, Delete, Redefine, Clear Overrides); regression tests in crates/ui-egui/src/panels/text_styles/tests.rs; scores and estimates unchanged. |
|
||||
| 2026-11-18 | minor | M10/G5: Media Controls joins Basic Shapes, UI Frames, Map Markers, Inventory Icons, Skill Icons and Weather Icons as a seventh built-in symbol library (Play, Pause, Stop, Skip Next, Shuffle, Repeat; original procedural vector symbols generated in code, no default 9-slice); G5 estimate decremented to 2–12 h, milestone estimates unchanged |
|
||||
| 2026-11-18 | minor | M14: PDF export writes the document language (Document Setup) as the catalog's `/Lang` (#3644). Scores and estimates unchanged. |
|
||||
| 2026-11-13 | minor | Layers: selected guide rows stay highlighted after the pointer leaves (#7344); scores and estimates unchanged. |
|
||||
@@ -193,7 +194,7 @@ Gujarati interface follow-up (2026-11-14): the catalog and zero/one plural rule
|
||||
| M11 | Artboards & views (selected-set deletion shared by Artboards menu, trash and Properties, retaining artboard 1 when all are selected; Artboard deletion keys keep the first of an all-selected set and protect artwork; history prunes invalid indices while preserving valid multiselection (history tests and full workspace CI pass); click-to-fit objects with the Artboard tool (#1227), artboard escape routing and document setup modal handoff done; artboard panel/tool with Move Artwork for X/Y fields and Artboard Options, Trim View (hiding the guides and the grid while it is on, #8363), middle-button pan, print tiling and the status bar's artboard navigator with synchronized Artboard tool selection done; Window › Arrange › Tile and Consolidate All Windows done; multiple windows, presentation polish) (cached canvas reprojection preserves scale during resize, rotation and DPI changes; regression-tested and contributor-confirmed 2026-10-19; estimates unchanged) (cached canvas dimensions match the renderer limit before cache-key creation, view construction and worker submission; regression-tested; estimates unchanged); status-bar pointer coordinates follow the active ruler origin and General units | 🟡; Artboard Options shares existing presets and orientation controls and can fit artwork without moving it; artwork fitting includes all drawn document art across artboards and off-board; artwork bounds are cached by active document and revision, and selection uses the shared bounds cache across artboards | 15–25 |
|
||||
| M12 | Advanced color & art (CMYK/ICC, separations, Gradient Mesh, Live Paint, Image Trace, Graphs) | 🟡 Gradient Mesh, Live Paint, Image Trace (junction-returning pieces retain their positioned boundaries; a simpler contour walk with identical output; an edge's sub-pixel shift is the same from either side; notches read only their own piece; collapsed loops keep few segments; large images trace with a warning; Auto Color keeps rare distinct colours; quick presets trace at once and the Image Trace button opens the adjustment controls; Properties reopens them; tiny fitted contours retain islands and holes; Create Strokes: exact crop EDT, Guo–Hall thinning and maximal-disc graph simplification; 15 presets, the 14 documented ones each with an enhanced version; Ignore Color (manual picker and canvas eyedropper from original pixels, no canvas View change, missed pixels keep the pick armed, Preview/Undo retained; #8068), Shapes, Auto Grouping and Gradients options; measured in `image-trace-quality.md`; closed outlines retain their interior after straightening; the Flat Logo mode places edges to a fraction of a pixel, restores sharp corners, snaps lines and circles, and refuses gradients; live trace result bounds and selection highlights exclude the retained bitmap except in source-image views), Recolor Artwork, colour management (ICC, soft proofing, separations preview), Graphs (all 9 tools, Graph Data/Type, group-selected series colours persist through regenerate/save/open) done; Graph Design and Marker designs, Transpose and Switch x/y, `\|` label line breaks, the pie options, drop shadows, the legend across the top, overlapping widths, First Row/Column in Front, filled lines, kept label formatting and the Graph Data worksheet done; graph Column designs pending; Vector Halftone Preview keeps the selection box without drawing dot selection marks (#6369); Live Paint Bucket fills faces crossed in one drag (#6373) | 6–10 |
|
||||
| M13 | Automation (Actions ✅ record/playback, persisted; variables, scripting, batch) | 🟡 MCP `add_text` exposes existing vertical point, area and path type; `script.run` and File › Scripts › Other Script… run JavaScript files, and Window › Script Console shows their output; the script document model and batch work remain | 18–27 |
|
||||
| M14 | 1.0 polish (preferences, shortcut editor, workspaces, accessibility, packaging for all OSes) (status messages and readouts use stable responsive allocations sized for localized labels and ordinary coordinates; sample widths cached by language/unit/DPI; regression-tested and contributor-confirmed 2026-10-19; estimates unchanged) | 🟡 Icon-strip flyouts resize on their free edges and retain sizes (#5713); interim macOS cursor delivery (#2292) uses existing artwork and host-owned AppKit cursors; headless coverage only, native menu/focus/handback and display validation pending. Dock groups collapse to their tabs by a double-click on a tab (UI.8); Preferences › General › Constrain Angle acts for the arrow keys, Shift drags and new objects (#394, 2026-10-21); numeric-field pointer selection and focus regression-tested (#1326; a release more than 1 pt from the press keeps the caret, a tap within 1 pt selects all, #6659); RPM runtime capabilities and glibc floor checked (#1275; real-distro install/start-up pending), Eyedropper cursor with precise-setting checks (#1269), Preferences, shortcut editor (chords with Shift and a punctuation key fire as typed; other apps' text shortcut sets imported), workspaces (each keeps its layout changes until Reset <name>, UI.7), Window › Help Bar shown or hidden apart from the status bar and kept in saved workspaces, panels docked by dragging into any dock group (as tabs or a top/bottom split) or into the icon column, and closed from a dock tab's context menu (UI.6), a custom title bar on Windows/Linux with a Home button, content-sized dialogs, menus that scroll when longer than the window and macOS native menu dismissal done (M14.8), and native macOS save sheets with a Format menu (#866); titled PDF exports set `DisplayDocTitle` for viewers and accessibility checkers (#3646) and give the document language as the catalog's `/Lang` (#3644); accessibility and broader Windows/Linux packaging/QA pending; floating tab groups collapse into the side icon rail and opened rail panels fold back into it (#5925, in part), with pointer and native-window regression coverage; estimates unchanged; numeric spinner arrows keep repeating while held with the mouse (#6307); Swatches item context menus tested in all five views and rendered layouts inspected; Linux full CI passed, Windows engine baseline limitations documented (G12); Graphic Styles item context menus in thumbnail and list views with Options, Duplicate, Delete, Redefine, Break Link (#8755); Window > Toolbars > Compact Tools offers optional denser main Tools spacing in one or two columns, with the existing layout still the default (#7234) | 18–28 |
|
||||
| M14 | 1.0 polish (preferences, shortcut editor, workspaces, accessibility, packaging for all OSes) (status messages and readouts use stable responsive allocations sized for localized labels and ordinary coordinates; sample widths cached by language/unit/DPI; regression-tested and contributor-confirmed 2026-10-19; estimates unchanged) | 🟡 Icon-strip flyouts resize on their free edges and retain sizes (#5713); interim macOS cursor delivery (#2292) uses existing artwork and host-owned AppKit cursors; headless coverage only, native menu/focus/handback and display validation pending. Dock groups collapse to their tabs by a double-click on a tab (UI.8); Preferences › General › Constrain Angle acts for the arrow keys, Shift drags and new objects (#394, 2026-10-21); numeric-field pointer selection and focus regression-tested (#1326; a release more than 1 pt from the press keeps the caret, a tap within 1 pt selects all, #6659); RPM runtime capabilities and glibc floor checked (#1275; real-distro install/start-up pending), Eyedropper cursor with precise-setting checks (#1269), Preferences, shortcut editor (chords with Shift and a punctuation key fire as typed; other apps' text shortcut sets imported), workspaces (each keeps its layout changes until Reset <name>, UI.7), Window › Help Bar shown or hidden apart from the status bar and kept in saved workspaces, panels docked by dragging into any dock group (as tabs or a top/bottom split) or into the icon column, and closed from a dock tab's context menu (UI.6), a custom title bar on Windows/Linux with a Home button, content-sized dialogs, menus that scroll when longer than the window and macOS native menu dismissal done (M14.8), and native macOS save sheets with a Format menu (#866); titled PDF exports set `DisplayDocTitle` for viewers and accessibility checkers (#3646) and give the document language as the catalog's `/Lang` (#3644); accessibility and broader Windows/Linux packaging/QA pending; floating tab groups collapse into the side icon rail and opened rail panels fold back into it (#5925, in part), with pointer and native-window regression coverage; estimates unchanged; numeric spinner arrows keep repeating while held with the mouse (#6307); Swatches item context menus tested in all five views and rendered layouts inspected; Linux full CI passed, Windows engine baseline limitations documented (G12); Graphic Styles item context menus in thumbnail and list views with Options, Duplicate, Delete, Redefine, Break Link (#8755); Character Styles and Paragraph Styles item context menus (panels::text_styles::tests::right_click_context_menu_*); Window > Toolbars > Compact Tools offers optional denser main Tools spacing in one or two columns, with the existing layout still the default (#7234) | 18–28 |
|
||||
| — | Interaction fidelity pass (every tool's modifiers, Properties panel per context, isolation, nuance; width-point creation and adjoining adjustment regression-tested; dialog layout reviewed) | ⬜ (new ruler-guide Alt orientation implemented; existing-guide Escape cancellation regression-tested; broader pass remains) | 60–90 |
|
||||
| — | Hardening at scale (big-file corpus, fuzzing, cross-platform + browser QA) | 🟡 PngSuite integrity and bounded fetching verified (#1729); real-world corpus/manual QA remain | 50–80 |
|
||||
| M14 follow-up | Color Picker layout (#2008) | ✅ Compact controls, centered header, stacked actions, aligned fields and screen sampling; narrow windows scroll vertically | Included above |
|
||||
@@ -239,6 +240,7 @@ not take the artwork yet. Overflow-menu drag remains separate. Scores and hours
|
||||
| 2026-11-19 | minor | M11: View › Trim View hides the ruler guides, guide paths and the grid while it is on and greys out Show/Hide Guides and Show/Hide Grid; a ruler drag or double-click makes no guide meanwhile (#8363). Scores and estimates unchanged |
|
||||
| 2026-11-19 | minor | Scissors previews its actual anchor or curve cut point with a native point marker while hovering, retaining existing snapping, Alt Add Anchor and cut behavior (#8655). Scores and estimates unchanged. |
|
||||
| 2026-11-19 | minor | M5: In the web build, an edit while the view of a heavy document moves (a tool drag held at an edge of the canvas, #8551, or a wheel scroll during a drag) draws only the part it changed into the last frame, which stays drawn moved with the view, instead of rendering the whole canvas each frame (an edit that changes more than half of the frame, or a change of more than the view and the document, still renders it whole at once), and edits that go on once the view is still don't put off its render (#8688). Scores and estimates unchanged. |
|
||||
| 2026-11-19 | minor | M14/G12: Character Styles and Paragraph Styles panels item context menus (Options…, Duplicate, Delete, Redefine, Clear Overrides); regression tests in crates/ui-egui/src/panels/text_styles/tests.rs; scores and estimates unchanged. |
|
||||
| 2026-11-18 | minor | M10/G5: Media Controls joins Basic Shapes, UI Frames, Map Markers, Inventory Icons, Skill Icons and Weather Icons as a seventh built-in symbol library (Play, Pause, Stop, Skip Next, Shuffle, Repeat; original procedural vector symbols generated in code, no default 9-slice); G5 estimate decremented to 2–12 h, milestone estimates unchanged |
|
||||
| 2026-11-18 | minor | M7/G4: Retype phase 1 (#4934): `type.retype` turns outlined text that exactly matches an available font back into point text. Scores and estimates unchanged |
|
||||
| 2026-11-18 | minor | M1: Lock Guides: a selection marquee (Selection, Direct Selection, Group Selection, Enclosing Lasso) leaves out paths made into guides inside groups and compound paths too, as clicks do (#3074), so a group is no longer selected by a locked guide in it; an enclosing marquee measures a group without its locked or hidden guides, and Direct Selection takes no anchor or segment of a guide that can't be picked; a guide in a group still moves with its group (#8538). Scores and estimates unchanged. |
|
||||
@@ -474,3 +476,5 @@ not take the artwork yet. Overflow-menu drag remains separate. Scores and hours
|
||||
Ordinary Save and Save As keep EPS as EPS, with the chosen page frame, transparent margins and the complete editable VectorCraft document. Existing import-loss confirmation and transparency warnings remain; the Save TIFF preview is capped at 1024 pixels, while Export retains 2048. See [file-format-parity.md](file-format-parity.md#eps-save-and-source-protection) for limits and regression evidence. This narrows G9 save-back workflow coverage; native Illustrator editing-data fidelity, parity scores and hour estimates are unchanged. Since 2026-11-12 the EPS Options of Save As show Use Artboards, unchecked by default: unchecked, the bounding box fits the visible art; checked, Save keeps the chosen page frame and margins described here.
|
||||
|
||||
> **Swatches status (2026-11-15):** Item context menus are implemented and covered by headless tests; full CI passed on the latest-main integration (all 13 gates), including the updated panel-view harness; parity scores and estimates are unchanged.
|
||||
|
||||
> **Text styles status (2026-11-19):** Character Styles and Paragraph Styles panels item context menus (Options…, Duplicate, Delete, Redefine, Clear Overrides) are implemented and covered by headless tests; parity scores and estimates are unchanged.
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -70,6 +70,7 @@ Artboard Options forwards the active Artboard tool's Scale Artwork with Artboard
|
||||
|
||||
| Date | Change | Summary |
|
||||
|---|---|---|
|
||||
| 2026-11-19 | minor | G12: Character Styles and Paragraph Styles panels item context menus (Options…, Duplicate, Delete, Redefine, Clear Overrides); regression tests in crates/ui-egui/src/panels/text_styles/tests.rs; scores and estimates unchanged. |
|
||||
| 2026-11-19 | minor | G12: Place: show progress window with Cancel for slow placed files exceeding 0.4 s (part of #5930, `file.cancelPlace`); indeterminate moving bar, Cancel (Esc) leaves the document unmodified without undo steps; scores and estimates unchanged. |
|
||||
| 2026-11-18 | minor | Layers panel: right-clicking a ruler guide row or a blend spine row shows its context menu (#8592): Hide/Show, Lock/Unlock, Release Guides, Delete and Locate Object on guide rows; Select, Blend Options…, Reverse Spine, Reverse Front to Back, Expand, Release and Locate Object on blend spine rows. Scores unchanged. |
|
||||
| 2026-11-17 | minor | All Tools drawer: a tool the toolbar holds is dimmed in the dim text colour — name, shortcut and icon, one step dimmer than a tool not in it — instead of the disabled colour, which at the drawer's 12.5 px was unreadable against the panel (about 2.6:1); the dim colour reaches 4.5:1 or better against the panel in every brightness of the Modern scheme and in the Classic scheme's lightest and darkest settings (5.4:1 in the default Charcoal theme), and a hovered dimmed row keeps it by taking the panel's darker fill rather than the lighter hover fill, which left it at 4.3:1 in the default theme; the Classic scheme's own dim text is 3.55:1 against its panel at its middle-dark brightness, which the drawer draws as that palette does (#8294; `tools_in_the_toolbar_are_dimmed_in_the_drawer` and `a_hovered_dimmed_row_stays_readable` in `crates/ui-egui/src/edit_toolbar/tests.rs`, both over every scheme and brightness). The dimming itself is VectorCraft's own (#1018) and is unchanged. Scores and estimates unchanged. |
|
||||
@@ -899,3 +900,5 @@ before release (#6373). [Paint faces and edges](https://helpx.adobe.com/illustra
|
||||
| 2026-10-22 | minor | Artwork dragged with Selection switches visible document tabs after a 400 ms hover, then copies editable artwork on canvas release; source and clipboard stay intact; scores and hours unchanged |
|
||||
|
||||
> **Swatches status (2026-11-15):** Item context menus are implemented and covered by headless tests; full CI passed on the latest-main integration (all 13 gates), including the updated panel-view harness; parity scores and estimates are unchanged.
|
||||
|
||||
> **Text styles status (2026-11-19):** Character Styles and Paragraph Styles panels item context menus (Options…, Duplicate, Delete, Redefine, Clear Overrides) are implemented and covered by headless tests; parity scores and estimates are unchanged.
|
||||
|
||||
Reference in New Issue
Block a user