Skip to content

DesignCraft: An open-source page and layout design editor written by scratch in pure Rust

Object menu: InDesign's order and groups, Join/Open/Close Path under Paths, Convert Point

moppeeerd7d9c4230ac2
diff --git a/ROADMAP.md b/ROADMAP.md
index 0128924c0..57285e793 100644
--- a/ROADMAP.md
+++ b/ROADMAP.md
@@ -348,6 +348,7 @@ list) · [roadmap.md](docs/roadmap.md) (milestones, plan) · [parity-checklist.m
Newest first.
+- **2026-10-20** · The Object menu is in InDesign's order and groups; Paths has Join, Open Path and Close Path (Convert Shape lists only shapes, as InDesign's does) and a Convert Point submenu (Plain, Corner, Smooth, Symmetrical) is added. No readiness percentage change.
- **2026-10-16** · Type › Reload Fonts (`font.reload`): fonts installed, edited or removed while DesignCraft runs are read again without a restart, and the open documents recompose with them (#328, #547). An edited font file is noticed by its length and modification time; bundled, added and document fonts stay as they are. InDesign does this by itself, so noticing changes automatically is still open (gap 6). No readiness percentage change.
- **2026-10-16** · Parents can be deleted from their Pages-panel context menu or `layout.parents.delete {id}`. Applied-page and based-on references are cleared, local override copies survive, and Undo restores the parent. Addresses the deletion portion of #956; no readiness percentage change.
- **2026-10-17** · File › Package writes the document's and the IDML's links relative to the package (`Links/logo.png`, `file:Links/logo.png`), so a package holds no path from the machine that made it; opening a document resolves them to the files beside it. Links › Copy Link(s) To still links by full path. (#340). No readiness percentage change.
diff --git a/crates/ui-egui/src/i18n.rs b/crates/ui-egui/src/i18n.rs
index efe089ef9..22e8a0a87 100644
--- a/crates/ui-egui/src/i18n.rs
+++ b/crates/ui-egui/src/i18n.rs
@@ -89,6 +89,8 @@ const TABLE: &[(&str, [&str; 5])] = &[
("Cut", ["Ausschneiden", "Couper", "Cortar", "カット", "剪切"]),
("Copy", ["Kopieren", "Copier", "Copiar", "コピー", "复制"]),
("Paste", ["Einfügen", "Coller", "Pegar", "ペースト", "粘贴"]),
+ ("Join", ["Join", "Joindre", "Join", "Join", "连接"]),
+ ("Convert Point", ["Convert Point", "Convertir le point", "Convert Point", "Convert Point", "转换点"]),
("Hide Rulers", ["Lineale ausblenden", "Masquer les règles", "Ocultar reglas", "定規を隠す", "隐藏标尺"]),
("Inches Decimal", ["Zoll dezimal", "Pouces décimaux", "Pulgadas decimales", "インチ(10 進)", "十进制英寸"]),
(
diff --git a/crates/ui-egui/src/i18n/ar.rs b/crates/ui-egui/src/i18n/ar.rs
index b050de38b..c9e6f463e 100644
--- a/crates/ui-egui/src/i18n/ar.rs
+++ b/crates/ui-egui/src/i18n/ar.rs
@@ -30,6 +30,8 @@ pub(super) const TABLE: &[(&str, &str)] = &[
("Cut", "قص"),
("Copy", "نسخ"),
("Paste", "لصق"),
+ ("Join", "وصل"),
+ ("Convert Point", "تحويل النقطة"),
("Paste Vector Art", "لصق رسم متجه"),
("Baseline Options", "خيارات خط الأساس"),
("Fixed Number", "عدد ثابت"),
diff --git a/crates/ui-egui/src/i18n/cs.rs b/crates/ui-egui/src/i18n/cs.rs
index e77e72a1c..dcebc1180 100644
--- a/crates/ui-egui/src/i18n/cs.rs
+++ b/crates/ui-egui/src/i18n/cs.rs
@@ -31,6 +31,10 @@ pub(super) const TABLE: &[(&str, &str)] = &[
("Cut", "Vyjmout"),
("Copy", "Kopírovat"),
("Paste", "Vložit"),
+ ("Join", "Spojit"),
+ ("Convert Point", "Převést bod"),
+ ("Plain", "Obyčejný"),
+ ("Symmetrical", "Symetrický"),
("Reverse Path", "Obrátit cestu"),
("Set Anchor", "Nastavit kotvu"),
("Clear", "Vymazat"),
diff --git a/crates/ui-egui/src/i18n/de.rs b/crates/ui-egui/src/i18n/de.rs
index efc128858..778f028ae 100644
--- a/crates/ui-egui/src/i18n/de.rs
+++ b/crates/ui-egui/src/i18n/de.rs
@@ -31,6 +31,10 @@ pub(super) const TABLE: &[(&str, &str)] = &[
("Cut", "Ausschneiden"),
("Copy", "Kopieren"),
("Paste", "Einfügen"),
+ ("Join", "Verbinden"),
+ ("Convert Point", "Punkt konvertieren"),
+ ("Plain", "Einfach"),
+ ("Symmetrical", "Symmetrisch"),
("Inches Decimal", "Zoll dezimal"),
("Back", "Zurück"),
("Warning", "Warnung"),
diff --git a/crates/ui-egui/src/i18n/it.rs b/crates/ui-egui/src/i18n/it.rs
index a918a9829..818eafcf3 100644
--- a/crates/ui-egui/src/i18n/it.rs
+++ b/crates/ui-egui/src/i18n/it.rs
@@ -28,6 +28,8 @@ pub(super) const TABLE: &[(&str, &str)] = &[
("Cut", "Taglia"),
("Copy", "Copia"),
("Paste", "Incolla"),
+ ("Join", "Unisci"),
+ ("Convert Point", "Converti punto"),
("Paste Vector Art", "Incolla grafica vettoriale"),
("Baseline Options", "Opzioni linea di base"),
("Fixed Number", "Numero fisso"),
diff --git a/crates/ui-egui/src/i18n/ja.rs b/crates/ui-egui/src/i18n/ja.rs
index 5647ca940..9f98222dd 100644
--- a/crates/ui-egui/src/i18n/ja.rs
+++ b/crates/ui-egui/src/i18n/ja.rs
@@ -30,6 +30,8 @@ pub(super) const TABLE: &[(&str, &str)] = &[
("Cut", "カット"),
("Copy", "コピー"),
("Paste", "ペースト"),
+ ("Join", "連結"),
+ ("Convert Point", "ポイントを切り換え"),
("Paste Vector Art", "ベクトルアートをペースト"),
("Baseline Options", "ベースラインオプション"),
("Column Rules", "段落境界線"),
diff --git a/crates/ui-egui/src/i18n/ka.rs b/crates/ui-egui/src/i18n/ka.rs
index d938c2dc7..d0c67ae3c 100644
--- a/crates/ui-egui/src/i18n/ka.rs
+++ b/crates/ui-egui/src/i18n/ka.rs
@@ -31,6 +31,10 @@ pub(super) const TABLE: &[(&str, &str)] = &[
("Cut", "ამოჭრა"),
("Copy", "კოპირება"),
("Paste", "ჩასმა"),
+ ("Join", "შეერთება"),
+ ("Convert Point", "წერტილის გარდაქმნა"),
+ ("Plain", "მარტივი"),
+ ("Symmetrical", "სიმეტრიული"),
("Inches Decimal", "ინჩები (ათობითი)"),
("Back", "უკან"),
("Warning", "გაფრთხილება"),
diff --git a/crates/ui-egui/src/i18n/pl.rs b/crates/ui-egui/src/i18n/pl.rs
index 68d685d99..4b5763383 100644
--- a/crates/ui-egui/src/i18n/pl.rs
+++ b/crates/ui-egui/src/i18n/pl.rs
@@ -29,6 +29,10 @@ pub(super) const TABLE: &[(&str, &str)] = &[
("Cut", "Wytnij"),
("Copy", "Kopiuj"),
("Paste", "Wklej"),
+ ("Join", "Połącz"),
+ ("Convert Point", "Konwertuj punkt"),
+ ("Plain", "Zwykły"),
+ ("Symmetrical", "Symetryczny"),
("Clear", "Wyczyść"),
("Duplicate", "Powiel"),
("Select All", "Zaznacz wszystko"),
diff --git a/crates/ui-egui/src/i18n/pt_br.rs b/crates/ui-egui/src/i18n/pt_br.rs
index 8521de594..4042fe559 100644
--- a/crates/ui-egui/src/i18n/pt_br.rs
+++ b/crates/ui-egui/src/i18n/pt_br.rs
@@ -31,6 +31,8 @@ pub(super) const TABLE: &[(&str, &str)] = &[
("Cut", "Recortar"),
("Copy", "Copiar"),
("Paste", "Colar"),
+ ("Join", "Unir"),
+ ("Convert Point", "Converter ponto"),
("Paste Vector Art", "Colar arte vetorial"),
("Baseline Options", "Opções de linha de base"),
("Fixed Number", "Número fixo"),
diff --git a/crates/ui-egui/src/i18n/ru.rs b/crates/ui-egui/src/i18n/ru.rs
index 251555ca5..0503aa350 100644
--- a/crates/ui-egui/src/i18n/ru.rs
+++ b/crates/ui-egui/src/i18n/ru.rs
@@ -33,6 +33,10 @@ pub(super) const TABLE: &[(&str, &str)] = &[
("Cut", "Вырезать"),
("Copy", "Копировать"),
("Paste", "Вставить"),
+ ("Join", "Соединить"),
+ ("Convert Point", "Преобразовать точку"),
+ ("Plain", "Простая"),
+ ("Symmetrical", "Симметричная"),
("Clear", "Очистить"),
("Duplicate", "Дублировать"),
("Select All", "Выделить все"),
diff --git a/crates/ui-egui/src/i18n/uk.rs b/crates/ui-egui/src/i18n/uk.rs
index dd4a1434d..e21385496 100644
--- a/crates/ui-egui/src/i18n/uk.rs
+++ b/crates/ui-egui/src/i18n/uk.rs
@@ -29,6 +29,8 @@ pub(super) const TABLE: &[(&str, &str)] = &[
("Cut", "Вирізати"),
("Copy", "Копіювати"),
("Paste", "Вставити"),
+ ("Join", "Зʼєднати"),
+ ("Convert Point", "Перетворити точку"),
("Paste Vector Art", "Вставити векторну графіку"),
("Baseline Options", "Параметри базової лінії"),
("Fixed Number", "Фіксована кількість"),
diff --git a/crates/ui-egui/src/menus.rs b/crates/ui-egui/src/menus.rs
index 79b8b2c4e..667593746 100644
--- a/crates/ui-egui/src/menus.rs
+++ b/crates/ui-egui/src/menus.rs
@@ -597,32 +597,24 @@ pub const MENUS: &[(&str, &[&str])] = &[
"cmd:transform.again|Transform Sequence Again|{\"sequence\": true}",
"cmd:transform.again|Transform Sequence Again Individually|{\"sequence\": true, \"individually\": true}",
"<",
- ">Flex Layout",
- "cmd:flex.add",
- "cmd:flex.convert",
- "cmd:flex.remove",
- "-",
- "ui:window.panel|Show Flex Controls|{\"panel\": \"flexLayout\"}",
- "<",
- ">Paths",
- "cmd:object.makeCompoundPath",
- "cmd:object.releaseCompoundPath",
- "-",
- "cmd:path.reverse",
- "<",
- ">Pathfinder",
- "cmd:object.pathfinder|Add|{\"op\": \"add\"}",
- "cmd:object.pathfinder|Subtract|{\"op\": \"subtract\"}",
- "cmd:object.pathfinder|Intersect|{\"op\": \"intersect\"}",
- "cmd:object.pathfinder|Exclude Overlap|{\"op\": \"exclude\"}",
- "cmd:object.pathfinder|Minus Back|{\"op\": \"minusBack\"}",
- "<",
">Arrange",
"cmd:object.bringToFront",
"cmd:object.bringForward",
"cmd:object.sendBackward",
"cmd:object.sendToBack",
"<",
+ ">Select",
+ "cmd:select.firstAbove",
+ "cmd:select.nextAbove",
+ "cmd:select.nextBelow",
+ "cmd:select.lastBelow",
+ "-",
+ "cmd:select.container",
+ "cmd:select.content",
+ "-",
+ "cmd:select.previousInGroup",
+ "cmd:select.nextInGroup",
+ "<",
"-",
"cmd:object.group",
"cmd:object.ungroup",
@@ -631,11 +623,29 @@ pub const MENUS: &[(&str, &[&str])] = &[
"cmd:object.hide",
"cmd:object.showAll",
"-",
+ "ui:app.qrCode",
+ "-",
"cmd:object.textFrameOptions",
- "ui:app.layerOptions",
- "cmd:object.exportOptions",
"cmd:object.primaryTextFrame",
- "cmd:object.cornerOptions",
+ ">Anchored Object",
+ "cmd:anchored.options",
+ "cmd:anchored.release",
+ "<",
+ "-",
+ ">Fitting",
+ "ui:fit.fillFrameProportionally",
+ "ui:fit.contentProportionally",
+ "ui:fit.frameToContent",
+ "ui:fit.contentToFrame",
+ "ui:fit.centerContent",
+ "-",
+ "ui:app.fittingOptions",
+ "<",
+ ">Content",
+ "cmd:object.content|Graphic|{\"type\":\"graphic\"}",
+ "cmd:object.content|Text|{\"type\":\"text\"}",
+ "cmd:object.content|Unassigned|{\"type\":\"unassigned\"}",
+ "<",
"-",
">Effects",
"ui:effects.dialog|Transparency…|{\"page\": \"transparency\"}",
@@ -648,17 +658,43 @@ pub const MENUS: &[(&str, &[&str])] = &[
"cmd:object.feather",
"cmd:object.directionalFeather",
"<",
- ">Select",
- "cmd:select.firstAbove",
- "cmd:select.nextAbove",
- "cmd:select.nextBelow",
- "cmd:select.lastBelow",
+ "cmd:object.cornerOptions",
"-",
- "cmd:select.container",
- "cmd:select.content",
+ "ui:app.layerOptions",
+ "cmd:object.exportOptions",
+ ">Captions",
+ "cmd:object.caption",
+ "cmd:object.caption|Generate Live Caption|{\"live\": true}",
+ "<",
+ ">Clipping Path",
+ "cmd:object.clippingPathOptions|None|{\"type\": \"none\"}",
+ "cmd:object.clippingPath|Alpha Channel|{\"type\": \"alpha\"}",
+ "cmd:object.clippingPath|Detect Edges|{\"type\": \"edges\"}",
+ "<",
"-",
- "cmd:select.previousInGroup",
- "cmd:select.nextInGroup",
+ ">Flex Layout",
+ "cmd:flex.add",
+ "cmd:flex.convert",
+ "cmd:flex.remove",
+ "-",
+ "ui:window.panel|Show Flex Controls|{\"panel\": \"flexLayout\"}",
+ "<",
+ "-",
+ ">Paths",
+ "cmd:path.join",
+ "cmd:object.convertShape|Open Path|{\"to\": \"openPath\"}",
+ "cmd:object.convertShape|Close Path|{\"to\": \"closedPath\"}",
+ "cmd:path.reverse",
+ "-",
+ "cmd:object.makeCompoundPath",
+ "cmd:object.releaseCompoundPath",
+ "<",
+ ">Pathfinder",
+ "cmd:object.pathfinder|Add|{\"op\": \"add\"}",
+ "cmd:object.pathfinder|Subtract|{\"op\": \"subtract\"}",
+ "cmd:object.pathfinder|Intersect|{\"op\": \"intersect\"}",
+ "cmd:object.pathfinder|Exclude Overlap|{\"op\": \"exclude\"}",
+ "cmd:object.pathfinder|Minus Back|{\"op\": \"minusBack\"}",
"<",
">Convert Shape",
"cmd:object.convertShape|Rectangle|{\"to\": \"rectangle\"}",
@@ -670,37 +706,12 @@ pub const MENUS: &[(&str, &[&str])] = &[
"cmd:object.convertShape|Polygon|{\"to\": \"polygon\"}",
"cmd:object.convertShape|Line|{\"to\": \"line\"}",
"cmd:object.convertShape|Orthogonal Line|{\"to\": \"orthogonalLine\"}",
- "-",
- "cmd:object.convertShape|Open Path|{\"to\": \"openPath\"}",
- "cmd:object.convertShape|Closed Path|{\"to\": \"closedPath\"}",
- "<",
- "ui:app.qrCode",
- ">Clipping Path",
- "cmd:object.clippingPathOptions|None|{\"type\": \"none\"}",
- "cmd:object.clippingPath|Alpha Channel|{\"type\": \"alpha\"}",
- "cmd:object.clippingPath|Detect Edges|{\"type\": \"edges\"}",
- "<",
- ">Captions",
- "cmd:object.caption",
- "cmd:object.caption|Generate Live Caption|{\"live\": true}",
- "<",
- ">Anchored Object",
- "cmd:anchored.options",
- "cmd:anchored.release",
- "<",
- ">Fitting",
- "ui:fit.fillFrameProportionally",
- "ui:fit.contentProportionally",
- "ui:fit.frameToContent",
- "ui:fit.contentToFrame",
- "ui:fit.centerContent",
- "-",
- "ui:app.fittingOptions",
"<",
- ">Content",
- "cmd:object.content|Graphic|{\"type\":\"graphic\"}",
- "cmd:object.content|Text|{\"type\":\"text\"}",
- "cmd:object.content|Unassigned|{\"type\":\"unassigned\"}",
+ ">Convert Point",
+ "cmd:path.convertPoints|Plain|{\"kind\": \"plain\"}",
+ "cmd:path.convertPoints|Corner|{\"kind\": \"corner\"}",
+ "cmd:path.convertPoints|Smooth|{\"kind\": \"smooth\"}",
+ "cmd:path.convertPoints|Symmetrical|{\"kind\": \"symmetrical\"}",
"<",
],
),
@@ -3254,6 +3265,81 @@ mod tests {
items.iter().filter_map(|e| e.split_once(':').map(|(_, rest)| rest.split('|').next().unwrap_or(rest))).collect()
}
+ /// The Object menu's top level in InDesign's order and groups (as InDesign 2023 shows it in
+ /// Learn Skills Daily's course), with Paths holding Join, Open and Close Path, Convert Shape
+ /// only shapes, and a Convert Point submenu.
+ #[test]
+ fn the_object_menu_is_in_indesigns_order() {
+ let items = MENUS.iter().find(|(t, _)| *t == "Object").map(|(_, items)| *items).unwrap();
+ // The top-level entries: submenus by name, separators as "-", items by command id.
+ let mut top = Vec::new();
+ let mut depth = 0;
+ for e in items {
+ match *e {
+ "<" => depth -= 1,
+ e if e.starts_with('>') => {
+ if depth == 0 {
+ top.push(e.trim_start_matches('>'));
+ }
+ depth += 1;
+ }
+ e if depth == 0 => top.push(e.split_once(':').map_or(e, |(_, r)| r.split('|').next().unwrap_or(r))),
+ _ => {}
+ }
+ }
+ assert_eq!(
+ top,
+ [
+ "Transform",
+ "Transform Again",
+ "Arrange",
+ "Select",
+ "-",
+ "object.group",
+ "object.ungroup",
+ "object.lock",
+ "object.unlockAll",
+ "object.hide",
+ "object.showAll",
+ "-",
+ "app.qrCode",
+ "-",
+ "object.textFrameOptions",
+ "object.primaryTextFrame",
+ "Anchored Object",
+ "-",
+ "Fitting",
+ "Content",
+ "-",
+ "Effects",
+ "object.cornerOptions",
+ "-",
+ "app.layerOptions",
+ "object.exportOptions",
+ "Captions",
+ "Clipping Path",
+ "-",
+ "Flex Layout",
+ "-",
+ "Paths",
+ "Pathfinder",
+ "Convert Shape",
+ "Convert Point",
+ ]
+ );
+ let ids = menu_ids("Object");
+ for id in ["path.join", "path.reverse", "path.convertPoints"] {
+ assert!(ids.contains(&id), "{id}");
+ }
+ let sub = |name: &str| {
+ let i = items.iter().position(|e| *e == format!(">{name}")).unwrap();
+ items[i + 1..].iter().take_while(|e| **e != "<").copied().collect::<Vec<_>>()
+ };
+ assert!(sub("Paths").iter().any(|e| e.contains("|Open Path|")) && sub("Paths").iter().any(|e| e.contains("|Close Path|")));
+ assert!(!sub("Convert Shape").iter().any(|e| e.contains("openPath") || e.contains("closedPath")), "shapes only");
+ assert_eq!(sub("Convert Point").len(), 4);
+ }
+
#[test]
fn view_items_are_in_the_view_menu_as_in_indesign() {
let (view, typ) = (menu_ids("View"), menu_ids("Type"));