DesignCraft: An open-source page and layout design editor written by scratch in pure Rust
Merge remote-tracking branch 'origin/main' into paragraph-shading-indesign
moppeeerdfd7091f6456
diff --cc ROADMAP.mdindex f1c7be6dd,5c739f11e..7491d6350--- a/ROADMAP.md+++ b/ROADMAP.md@@@ -358,8 -358,10 +358,11 @@@ list) · [roadmap.md](docs/roadmap.md)Newest first.+- **2026-10-22** · Paragraph Style Options › Paragraph Shading and Paragraph Border are laid out as InDesign's: headed with the page's name; Tint is a spinner with InDesign's presets and has Overprint beside it (shading, border and gap; a new attribute each, kept through IDML; PDF export warns it doesn't overprint yet); Corner Size and Shape is InDesign's two-by-two grid of corner icons, sizes and shape menus showing each shape's glyph, with the link in the middle; offsets and weights have spinners. Found in the Learn Skills Daily course, chapter 41. No readiness percentage change.+ - **2026-10-24** · New documents start with Hyphenate Capitalized Words, Hyphenate Last Word and Hyphenate Across Column off in [Basic Paragraph], as in InDesign. Opened and imported files keep the values they carry. No readiness percentage change.+ - **2026-10-24** · The baseline grid's Relative To setting applies: with Top Margin, the grid starts at each page's own top margin in text composition, on the canvas and for snapping. It started at the page top, so grid-aligned text sat on the wrong lines and a page could fit one line fewer. No readiness percentage change.- **2026-10-24** · Custom-positioned anchored objects honour Relative to Spine (`anchored.options {spineRelative}`, IDML `SpineRelative`): the settings describe a left-hand page and mirror on a right-hand page, so marginal notes stay in the outside margin on both pages of a spread. On right-hand pages they took the left-hand placement and landed in the inside margin, across the spine or over the body text. No readiness percentage change.+ - **2026-10-24** · Text frames: a custom baseline grid (Text Frame Options › Baseline Options) from an IDML file sets lines from its start by its increment. The composer read the two values in the other order, so lines landed on the wrong grid. No readiness percentage change.- **2026-10-23** · Save and export dialogs (Save As, Save a Copy, Export PDF and the other exports, Package, libraries and books) start in the active document's folder once it has been saved, and for a document never saved in the folder of the last file saved or exported, remembered across sessions (#1653). A folder deleted since falls back to the system's choice. No readiness percentage change.- **2026-10-22** · Autoflow (Shift-click with the loaded text cursor, autoflow on Place, `text.thread {autoflow}`) fills the pages that follow before it adds any, as InDesign does: one frame per column on each following page, whatever else the page holds, then new pages at the end of the document. It inserted pages right after the story's last frame, in front of the document's own pages. Frames it set past the end of the text go again; a page the document had stays, and a page autoflow added only for such a frame goes with it. Smart Text Reflow of the primary text frame is unchanged. No readiness percentage change.- **2026-10-16** · Edit › Keyboard Shortcuts imports a set saved by InDesign's Show Set (.txt, Windows or Mac key names, UTF-8 or UTF-16): matched commands take its Default shortcuts or lose theirs, other commands give up keys it takes, and a report lists what it changed and the items it could not match (`window.importShortcuts`, #1180). Tool keys stay fixed. No readiness percentage change.@@@ -381,8 -386,11 +387,13 @@@- **2026-10-16** · Lock Guides and Lock Column Guides are commands in View ▸ Grids & Guides (`view.lockGuides`, ⌥⌘;, and `view.lockColumnGuides`), so the control channel and MCP reach them. Lock Column Guides is an undo step, is saved with the document, on in new ones, and read from and written to IDML's `ColumnGuideLocked`, which export always wrote as locked (#1096). No readiness percentage change.- **2026-10-16** · IDML: a page keeps column guides that were dragged off centre (InDesign's Custom columns). They were divided evenly on import, so the gutter sprang back to the middle; the imported positions now place the columns, with the canvas guides, snapping and text placement following them, and they are written back on export. Layout › Margins and Columns re-divides them evenly when the count or gutter changes, as InDesign's does. No readiness percentage change.- **2026-10-16** · IDML: custom column positions are checked before they are used (#1096). A set must give two edges per column, ascending from the left margin to the right one; any other (a wrong count, unsorted or non-numeric values, a list longer than 216 columns allow, or positions left behind by a margin or page-size change) is the even split, in the canvas, on import and on export, instead of columns drawn outside the margins. No readiness percentage change.+- **2026-10-20** · Properties › Appearance: the corner shape list shows each shape's glyph beside its name, drawn as InDesign draws them (Fancy has its own glyph now), and the stroke type list shows each type's line; both dropdowns are named for screen readers. No readiness percentage change.+- **2026-10-21** · Paragraph Border and Paragraph Shading link their four sides as InDesign's: the stroke weights, offsets and corners have the "Make all settings the same" link, on when the four are the same, so a side typed in sets all four; with the link off a side is set alone (a border with only a thick left side). Found in the Learn Skills Daily course, chapter 40. No readiness percentage change.+ - **2026-10-21** · Properties › Character and Paragraph: ••• (More Options) expands the section in place, as InDesign's: Character adds vertical and horizontal scale, baseline shift, skew, language and OpenType, and All Caps, Small Caps, Superscript, Subscript, Underline and Strikethrough; Paragraph adds the left, right, first line and last line indents, space before and after, the drop cap's lines and characters, Align to Baseline Grid and Hyphenate. It used to open the Character or Paragraph panel; the language field moved under ••• as in InDesign. Found in the Learn Skills Daily course, chapter 16. No readiness percentage change.+ - **2026-10-21** · The text Control panel has InDesign's two modes: A (Character Formatting Controls: font and style, size and leading, All Caps/Superscript/Underline and Small Caps/Subscript/Strikethrough, kerning and tracking, vertical and horizontal scale, baseline shift and skew, character style and language) and ¶ (Paragraph Formatting Controls: the nine alignments, left/first line and right/last line indents, space before and after, the drop cap's lines and characters, paragraph style, Hyphenate and Align to Baseline Grid). It used to show a fixed mix of both. Found in the Learn Skills Daily course, chapter 16. No readiness percentage change.+ - **2026-10-20** · With the Type tool, the Control panel's font size, leading and tracking fields have a spinner and a list of common values, as in InDesign (auto leading in parentheses). No readiness percentage change.+ - **2026-10-21** · The ¶ (Paragraph Formatting Controls) mode of the text Control panel has InDesign's Bulleted List and Numbered List buttons (with the default hanging indent) and Shading and Border: a checkbox, a button opening Paragraph Borders and Shading on that tab, and the colour. Found in the Learn Skills Daily course, chapter 21. No readiness percentage change.+ - **2026-10-21** · The Bulleted and Numbered List buttons (Properties, and Type › Bulleted & Numbered Lists › Apply Bullets / Apply Numbers) work as InDesign's: a paragraph with no indents gets the default hanging indent (0.25 in, −0.25 in), so the text lines up after the bullet instead of at the next default tab stop, and pressing the button again removes the list and that indent (`list.bullets`, `list.numbers`). Found in the Learn Skills Daily course, chapter 21. 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 --cc crates/ui-egui/src/i18n.rsindex f57921383,e74cc0f73..3d87253e8--- a/crates/ui-egui/src/i18n.rs+++ b/crates/ui-egui/src/i18n.rs@@@ -1012,11 -1075,102 +1077,107 @@@ const TABLE: &[(&str, [&str; 5])] = &],),("Load Styles", ["Formate laden", "Charger les styles", "Cargar estilos", "スタイルを読み込み", "加载样式"]),+ ("Overprint", ["Überdrucken", "Surimpression", "Sobreimprimir", "オーバープリント", "叠印"]),+ ("Top Left Corner", ["Ecke oben links", "Angle supérieur gauche", "Esquina superior izquierda", "左上角", "左上角"]),+ ("Top Right Corner", ["Ecke oben rechts", "Angle supérieur droit", "Esquina superior derecha", "右上角", "右上角"]),+ ("Bottom Left Corner", ["Ecke unten links", "Angle inférieur gauche", "Esquina inferior izquierda", "左下角", "左下角"]),+ ("Bottom Right Corner", ["Ecke unten rechts", "Angle inférieur droit", "Esquina inferior derecha", "右下角", "右下角"]),+ ("Restart Numbering", ["Nummerierung neu beginnen", "Recommencer la numérotation", "Reiniciar numeración", "番号の振り直し", "重新开始编号"]),+ ("Continue Numbering", ["Nummerierung fortführen", "Poursuivre la numérotation", "Continuar numeración", "番号の継続", "继续编号"]),+ ("Keep Options…", ["Umbruchoptionen …", "Options d'enchaînement…", "Opciones de separación…", "段落分離禁止オプション…", "保持选项…"]),+ (+ "Space Between Paragraphs Using Same Style",+ [+ "Abstand zwischen Absätzen mit gleichem Format",+ "Espace entre les paragraphes de même style",+ "Espacio entre párrafos con el mismo estilo",+ "同じスタイルの段落間のスペース",+ "使用相同样式的段落间距",+ ],+ ),+ ("Ignore", ["Ignorieren", "Ignorer", "Ignorar", "無視", "忽略"]),+ (+ "Do Not Align to Baseline Grid",+ [+ "Nicht am Grundlinienraster ausrichten",+ "Ne pas aligner sur la grille de ligne de base",+ "No alinear con cuadrícula base",+ "ベースライングリッドに揃えない",+ "不对齐基线网格",+ ],+ ),+ (+ "Only Align First Line to Grid",+ [+ "Nur erste Zeile am Raster ausrichten",+ "Aligner uniquement la première ligne sur la grille",+ "Alinear solo primera línea con cuadrícula",+ "最初の行のみグリッドに揃える",+ "仅首行对齐网格",+ ],+ ),+ (+ "Balance Ragged Lines",+ ["Unausgeglichene Zeilen ausgleichen", "Équilibrer les lignes irrégulières", "Equilibrar líneas desiguales", "行末を調整", "平衡未对齐的行"],+ ),+ (+ "Drop Caps and Nested Styles…",+ [+ "Initialen und verschachtelte Formate …",+ "Lettrines et styles imbriqués…",+ "Capitulares y estilos anidados…",+ "ドロップキャップと先頭文字スタイル…",+ "首字下沉和嵌套样式…",+ ],+ ),+ ("GREP Styles…", ["GREP-Stile …", "Styles GREP…", "Estilos GREP…", "正規表現スタイル…", "GREP 样式…"]),+ (+ "Restart/Continue Numbering",+ [+ "Nummerierung neu beginnen/fortführen",+ "Recommencer/Poursuivre la numérotation",+ "Reiniciar/Continuar numeración",+ "番号の振り直し/継続",+ "重新开始/继续编号",+ ],+ ),+ (+ "Convert Bullets and Numbering to Text",+ [+ "Aufzählungszeichen und Nummerierung in Text konvertieren",+ "Convertir les puces et la numérotation en texte",+ "Convertir viñetas y numeración en texto",+ "箇条書きと段落番号をテキストに変換",+ "将项目符号和编号转换为文本",+ ],+ ),+ ("Hyphenation…", ["Silbentrennung …", "Césure…", "Separación por sílabas…", "ハイフネーション…", "连字…"]),+ (+ "Hyphenation Settings",+ ["Silbentrennungseinstellungen", "Paramètres de césure", "Configuración de separación por sílabas", "ハイフネーション設定", "连字设置"],+ ),+ ("hyphens", ["Trennstriche", "tirets", "guiones", "ハイフン", "连字符"]),+ ("Hyphenation Zone:", ["Silbentrennungsbereich:", "Zone de césure :", "Zona de separación:", "ハイフネーション領域 :", "连字区:"]),+ ("Better Spacing", ["Bessere Abstände", "Meilleur espacement", "Mejor espaciado", "スペースを優先", "更好的间距"]),+ ("Fewer Hyphens", ["Weniger Trennstriche", "Moins de tirets", "Menos guiones", "ハイフンを減らす", "更少的连字符"]),+ (+ "Hyphenate Capitalized Words",+ [+ "Großgeschriebene Wörter trennen",+ "Césure des mots en capitales",+ "Separar palabras en mayúscula",+ "大文字で始まる単語をハイフネーション",+ "连字大写的单词",+ ],+ ),+ (+ "Hyphenate Last Word",+ ["Letztes Wort trennen", "Césure du dernier mot", "Separar última palabra", "最後の単語をハイフネーション", "连字最后一个单词"],+ ),+ (+ "Hyphenate Across Column",+ ["Über Spalten trennen", "Césure entre colonnes", "Separar entre columnas", "段をまたいでハイフネーション", "跨栏连字"],+ ),("Differs from this document",["Weicht von diesem Dokument ab", "Diffère de ce document", "Difiere de este documento", "このドキュメントと異なります", "与此文档不同"],diff --cc crates/ui-egui/src/i18n/ar.rsindex afcd8dfa3,49fd3046e..0693de788--- a/crates/ui-egui/src/i18n/ar.rs+++ b/crates/ui-egui/src/i18n/ar.rs@@@ -30,13 -30,43 +30,50 @@@ pub(super) const TABLE: &[(&str, &str)("Cut", "قص"),("Copy", "نسخ"),("Paste", "لصق"),+ ("Overprint", "طباعة فوقية"),+ ("Top Left Corner", "الزاوية العلوية اليسرى"),+ ("Top Right Corner", "الزاوية العلوية اليمنى"),+ ("Bottom Left Corner", "الزاوية السفلية اليسرى"),+ ("Bottom Right Corner", "الزاوية السفلية اليمنى"),+ ("Stroke Type", "نوع الحد"),+ ("Corner Shape", "شكل الزاوية"),+ ("Restart Numbering", "إعادة الترقيم"),+ ("Continue Numbering", "متابعة الترقيم"),+ ("Keep Options…", "خيارات الإبقاء…"),+ ("Space Between Paragraphs Using Same Style", "المسافة بين الفقرات ذات النمط نفسه"),+ ("Ignore", "تجاهل"),+ ("Do Not Align to Baseline Grid", "عدم المحاذاة إلى شبكة خط الأساس"),+ ("Only Align First Line to Grid", "محاذاة السطر الأول فقط إلى الشبكة"),+ ("Balance Ragged Lines", "موازنة الأسطر غير المتساوية"),+ ("Drop Caps and Nested Styles…", "الأحرف الاستهلالية والأنماط المتداخلة…"),+ ("GREP Styles…", "أنماط GREP…"),+ ("Restart/Continue Numbering", "إعادة/متابعة الترقيم"),+ ("Convert Bullets and Numbering to Text", "تحويل التعداد النقطي والترقيم إلى نص"),+ ("Hyphenation…", "الواصلة…"),+ ("Hyphenation Settings", "إعدادات الواصلة"),+ ("hyphens", "واصلات"),+ ("Hyphenation Zone:", "منطقة الواصلة:"),+ ("Better Spacing", "تباعد أفضل"),+ ("Fewer Hyphens", "واصلات أقل"),+ ("Hyphenate Capitalized Words", "وصل الكلمات ذات الأحرف الكبيرة"),+ ("Hyphenate Last Word", "وصل الكلمة الأخيرة"),+ ("Hyphenate Across Column", "الوصل عبر الأعمدة"),+ ("Character Formatting Controls", "عناصر تحكم تنسيق الأحرف"),+ ("Paragraph Formatting Controls", "عناصر تحكم تنسيق الفقرات"),+ ("Font Size", "حجم الخط"),+ ("Vertical Scale", "المقياس الرأسي"),+ ("Horizontal Scale", "المقياس الأفقي"),+ ("Baseline Shift", "إزاحة خط الأساس"),+ ("Skew (False Italic)", "إمالة (مائل زائف)"),+ ("Left Indent", "مسافة بادئة يسرى"),+ ("Right Indent", "مسافة بادئة يمنى"),+ ("First Line Left Indent", "مسافة بادئة يسرى للسطر الأول"),+ ("Last Line Right Indent", "مسافة بادئة يمنى للسطر الأخير"),+ ("Drop Cap Number of Lines", "عدد أسطر الحرف الاستهلالي"),+ ("Drop Cap One or More Characters", "حرف استهلالي واحد أو أكثر"),+ ("Align to Baseline Grid", "محاذاة إلى شبكة خط الأساس"),+ ("Apply Bullets", "تطبيق التعداد النقطي"),+ ("Apply Numbers", "تطبيق الترقيم"),("Paste Vector Art", "لصق رسم متجه"),("Baseline Options", "خيارات خط الأساس"),("Fixed Number", "عدد ثابت"),diff --cc crates/ui-egui/src/i18n/cs.rsindex 261ee3af6,6f47fdaff..fcbd5ae00--- a/crates/ui-egui/src/i18n/cs.rs+++ b/crates/ui-egui/src/i18n/cs.rs@@@ -31,13 -31,43 +31,50 @@@ pub(super) const TABLE: &[(&str, &str)("Cut", "Vyjmout"),("Copy", "Kopírovat"),("Paste", "Vložit"),+ ("Overprint", "Přetisk"),+ ("Top Left Corner", "Levý horní roh"),+ ("Top Right Corner", "Pravý horní roh"),+ ("Bottom Left Corner", "Levý dolní roh"),+ ("Bottom Right Corner", "Pravý dolní roh"),+ ("Stroke Type", "Typ tahu"),+ ("Corner Shape", "Tvar rohu"),+ ("Restart Numbering", "Začít číslování znovu"),+ ("Continue Numbering", "Pokračovat v číslování"),+ ("Keep Options…", "Volby zachování…"),+ ("Space Between Paragraphs Using Same Style", "Mezera mezi odstavci se stejným stylem"),+ ("Ignore", "Ignorovat"),+ ("Do Not Align to Baseline Grid", "Nezarovnávat na mřížku účaří"),+ ("Only Align First Line to Grid", "Zarovnat na mřížku jen první řádek"),+ ("Balance Ragged Lines", "Vyrovnat nezarovnané řádky"),+ ("Drop Caps and Nested Styles…", "Iniciály a vnořené styly…"),+ ("GREP Styles…", "Styly GREP…"),+ ("Restart/Continue Numbering", "Začít znovu/pokračovat v číslování"),+ ("Convert Bullets and Numbering to Text", "Převést odrážky a číslování na text"),+ ("Hyphenation…", "Dělení slov…"),+ ("Hyphenation Settings", "Nastavení dělení slov"),+ ("hyphens", "spojovníky"),+ ("Hyphenation Zone:", "Zóna dělení:"),+ ("Better Spacing", "Lepší mezery"),+ ("Fewer Hyphens", "Méně spojovníků"),+ ("Hyphenate Capitalized Words", "Dělit slova s velkým počátečním písmenem"),+ ("Hyphenate Last Word", "Dělit poslední slovo"),+ ("Hyphenate Across Column", "Dělit přes sloupce"),+ ("Character Formatting Controls", "Ovládací prvky formátování znaků"),+ ("Paragraph Formatting Controls", "Ovládací prvky formátování odstavců"),+ ("Font Size", "Velikost písma"),+ ("Vertical Scale", "Svislá změna velikosti"),+ ("Horizontal Scale", "Vodorovná změna velikosti"),+ ("Baseline Shift", "Posun účaří"),+ ("Skew (False Italic)", "Zkosení (nepravá kurzíva)"),+ ("Left Indent", "Odsazení zleva"),+ ("Right Indent", "Odsazení zprava"),+ ("First Line Left Indent", "Odsazení prvního řádku zleva"),+ ("Last Line Right Indent", "Odsazení posledního řádku zprava"),+ ("Drop Cap Number of Lines", "Počet řádků iniciály"),+ ("Drop Cap One or More Characters", "Iniciála: jeden nebo více znaků"),+ ("Align to Baseline Grid", "Zarovnat na mřížku účaří"),+ ("Apply Bullets", "Použít odrážky"),+ ("Apply Numbers", "Použít číslování"),("Reverse Path", "Obrátit cestu"),("Set Anchor", "Nastavit kotvu"),("Clear", "Vymazat"),diff --cc crates/ui-egui/src/i18n/de.rsindex 81cb4fa44,97b48316b..6979dd5f7--- a/crates/ui-egui/src/i18n/de.rs+++ b/crates/ui-egui/src/i18n/de.rs@@@ -31,13 -31,29 +31,36 @@@ pub(super) const TABLE: &[(&str, &str)("Cut", "Ausschneiden"),("Copy", "Kopieren"),("Paste", "Einfügen"),+ ("Overprint", "Überdrucken"),+ ("Top Left Corner", "Ecke oben links"),+ ("Top Right Corner", "Ecke oben rechts"),+ ("Bottom Left Corner", "Ecke unten links"),+ ("Bottom Right Corner", "Ecke unten rechts"),+ ("Stroke Type", "Konturtyp"),+ ("Corner Shape", "Eckenform"),+ ("Restart Numbering", "Nummerierung neu beginnen"),+ ("Continue Numbering", "Nummerierung fortführen"),+ ("Keep Options…", "Umbruchoptionen …"),+ ("Space Between Paragraphs Using Same Style", "Abstand zwischen Absätzen mit gleichem Format"),+ ("Ignore", "Ignorieren"),+ ("Do Not Align to Baseline Grid", "Nicht am Grundlinienraster ausrichten"),+ ("Only Align First Line to Grid", "Nur erste Zeile am Raster ausrichten"),+ ("Balance Ragged Lines", "Unausgeglichene Zeilen ausgleichen"),+ ("Drop Caps and Nested Styles…", "Initialen und verschachtelte Formate …"),+ ("GREP Styles…", "GREP-Stile …"),+ ("Restart/Continue Numbering", "Nummerierung neu beginnen/fortführen"),+ ("Convert Bullets and Numbering to Text", "Aufzählungszeichen und Nummerierung in Text konvertieren"),+ ("Hyphenation…", "Silbentrennung …"),+ ("Hyphenation Settings", "Silbentrennungseinstellungen"),+ ("hyphens", "Trennstriche"),+ ("Hyphenation Zone:", "Silbentrennungsbereich:"),+ ("Better Spacing", "Bessere Abstände"),+ ("Fewer Hyphens", "Weniger Trennstriche"),+ ("Hyphenate Capitalized Words", "Großgeschriebene Wörter trennen"),+ ("Hyphenate Last Word", "Letztes Wort trennen"),+ ("Hyphenate Across Column", "Über Spalten trennen"),+ ("Apply Bullets", "Aufzählungszeichen anwenden"),+ ("Apply Numbers", "Nummerierung anwenden"),("Inches Decimal", "Zoll dezimal"),("Back", "Zurück"),("Warning", "Warnung"),diff --cc crates/ui-egui/src/i18n/it.rsindex 274127a76,4a3656699..0f9489fa0--- a/crates/ui-egui/src/i18n/it.rs+++ b/crates/ui-egui/src/i18n/it.rs@@@ -28,13 -28,43 +28,50 @@@ pub(super) const TABLE: &[(&str, &str)("Cut", "Taglia"),("Copy", "Copia"),("Paste", "Incolla"),+ ("Overprint", "Sovrastampa"),+ ("Top Left Corner", "Angolo superiore sinistro"),+ ("Top Right Corner", "Angolo superiore destro"),+ ("Bottom Left Corner", "Angolo inferiore sinistro"),+ ("Bottom Right Corner", "Angolo inferiore destro"),+ ("Stroke Type", "Tipo traccia"),+ ("Corner Shape", "Forma angolo"),+ ("Restart Numbering", "Riavvia numerazione"),+ ("Continue Numbering", "Continua numerazione"),+ ("Keep Options…", "Opzioni di separazione…"),+ ("Space Between Paragraphs Using Same Style", "Spazio tra paragrafi con lo stesso stile"),+ ("Ignore", "Ignora"),+ ("Do Not Align to Baseline Grid", "Non allineare alla griglia linee di base"),+ ("Only Align First Line to Grid", "Allinea solo la prima riga alla griglia"),+ ("Balance Ragged Lines", "Bilancia righe irregolari"),+ ("Drop Caps and Nested Styles…", "Capilettera e stili nidificati…"),+ ("GREP Styles…", "Stili GREP…"),+ ("Restart/Continue Numbering", "Riavvia/continua numerazione"),+ ("Convert Bullets and Numbering to Text", "Converti elenchi puntati e numerati in testo"),+ ("Hyphenation…", "Sillabazione…"),+ ("Hyphenation Settings", "Impostazioni sillabazione"),+ ("hyphens", "trattini"),+ ("Hyphenation Zone:", "Area di sillabazione:"),+ ("Better Spacing", "Spaziatura migliore"),+ ("Fewer Hyphens", "Meno trattini"),+ ("Hyphenate Capitalized Words", "Sillaba parole con iniziale maiuscola"),+ ("Hyphenate Last Word", "Sillaba ultima parola"),+ ("Hyphenate Across Column", "Sillaba tra colonne"),+ ("Character Formatting Controls", "Controlli di formattazione carattere"),+ ("Paragraph Formatting Controls", "Controlli di formattazione paragrafo"),+ ("Font Size", "Dimensione font"),+ ("Vertical Scale", "Scala verticale"),+ ("Horizontal Scale", "Scala orizzontale"),+ ("Baseline Shift", "Spostamento linea di base"),+ ("Skew (False Italic)", "Inclinazione (falso corsivo)"),+ ("Left Indent", "Rientro sinistro"),+ ("Right Indent", "Rientro destro"),+ ("First Line Left Indent", "Rientro sinistro prima riga"),+ ("Last Line Right Indent", "Rientro destro ultima riga"),+ ("Drop Cap Number of Lines", "Capolettera: numero di righe"),+ ("Drop Cap One or More Characters", "Capolettera: uno o più caratteri"),+ ("Align to Baseline Grid", "Allinea alla griglia di base"),+ ("Apply Bullets", "Applica punti elenco"),+ ("Apply Numbers", "Applica numeri"),("Paste Vector Art", "Incolla grafica vettoriale"),("Baseline Options", "Opzioni linea di base"),("Fixed Number", "Numero fisso"),diff --cc crates/ui-egui/src/i18n/ja.rsindex 16ba7af47,6180858af..9ea59084f--- a/crates/ui-egui/src/i18n/ja.rs+++ b/crates/ui-egui/src/i18n/ja.rs@@@ -30,13 -30,29 +30,36 @@@ pub(super) const TABLE: &[(&str, &str)("Cut", "カット"),("Copy", "コピー"),("Paste", "ペースト"),+ ("Overprint", "オーバープリント"),+ ("Top Left Corner", "左上角"),+ ("Top Right Corner", "右上角"),+ ("Bottom Left Corner", "左下角"),+ ("Bottom Right Corner", "右下角"),+ ("Stroke Type", "線の種類"),+ ("Corner Shape", "角のシェイプ"),+ ("Restart Numbering", "番号の振り直し"),+ ("Continue Numbering", "番号の継続"),+ ("Keep Options…", "段落分離禁止オプション…"),+ ("Space Between Paragraphs Using Same Style", "同じスタイルの段落間のスペース"),+ ("Ignore", "無視"),+ ("Do Not Align to Baseline Grid", "ベースライングリッドに揃えない"),+ ("Only Align First Line to Grid", "最初の行のみグリッドに揃える"),+ ("Balance Ragged Lines", "行末を調整"),+ ("Drop Caps and Nested Styles…", "ドロップキャップと先頭文字スタイル…"),+ ("GREP Styles…", "正規表現スタイル…"),+ ("Restart/Continue Numbering", "番号の振り直し/継続"),+ ("Convert Bullets and Numbering to Text", "箇条書きと段落番号をテキストに変換"),+ ("Hyphenation…", "ハイフネーション…"),+ ("Hyphenation Settings", "ハイフネーション設定"),+ ("hyphens", "ハイフン"),+ ("Hyphenation Zone:", "ハイフネーション領域 :"),+ ("Better Spacing", "スペースを優先"),+ ("Fewer Hyphens", "ハイフンを減らす"),+ ("Hyphenate Capitalized Words", "大文字で始まる単語をハイフネーション"),+ ("Hyphenate Last Word", "最後の単語をハイフネーション"),+ ("Hyphenate Across Column", "段をまたいでハイフネーション"),+ ("Apply Bullets", "箇条書きを適用"),+ ("Apply Numbers", "段落番号を適用"),("Paste Vector Art", "ベクトルアートをペースト"),("Baseline Options", "ベースラインオプション"),("Column Rules", "段落境界線"),diff --cc crates/ui-egui/src/i18n/ka.rsindex c77354343,4767b6c30..5794bb9f6--- a/crates/ui-egui/src/i18n/ka.rs+++ b/crates/ui-egui/src/i18n/ka.rs@@@ -31,13 -31,43 +31,50 @@@ pub(super) const TABLE: &[(&str, &str)("Cut", "ამოჭრა"),("Copy", "კოპირება"),("Paste", "ჩასმა"),+ ("Overprint", "ზედაბეჭდვა"),+ ("Top Left Corner", "ზედა მარცხენა კუთხე"),+ ("Top Right Corner", "ზედა მარჯვენა კუთხე"),+ ("Bottom Left Corner", "ქვედა მარცხენა კუთხე"),+ ("Bottom Right Corner", "ქვედა მარჯვენა კუთხე"),+ ("Stroke Type", "კონტურის ტიპი"),+ ("Corner Shape", "კუთხის ფორმა"),+ ("Restart Numbering", "ნუმერაციის თავიდან დაწყება"),+ ("Continue Numbering", "ნუმერაციის გაგრძელება"),+ ("Keep Options…", "შენარჩუნების პარამეტრები…"),+ ("Space Between Paragraphs Using Same Style", "დაშორება ერთი სტილის აბზაცებს შორის"),+ ("Ignore", "უგულებელყოფა"),+ ("Do Not Align to Baseline Grid", "საბაზისო ბადეზე არ გასწორდეს"),+ ("Only Align First Line to Grid", "ბადეზე მხოლოდ პირველი ხაზის გასწორება"),+ ("Balance Ragged Lines", "უსწორმასწორო ხაზების დაბალანსება"),+ ("Drop Caps and Nested Styles…", "საწყისი ასოები და ჩადგმული სტილები…"),+ ("GREP Styles…", "GREP სტილები…"),+ ("Restart/Continue Numbering", "ნუმერაციის თავიდან დაწყება/გაგრძელება"),+ ("Convert Bullets and Numbering to Text", "მარკერებისა და ნუმერაციის ტექსტად გარდაქმნა"),+ ("Hyphenation…", "დამარცვლა…"),+ ("Hyphenation Settings", "დამარცვლის პარამეტრები"),+ ("hyphens", "დეფისი"),+ ("Hyphenation Zone:", "დამარცვლის ზონა:"),+ ("Better Spacing", "უკეთესი დაშორება"),+ ("Fewer Hyphens", "ნაკლები დეფისი"),+ ("Hyphenate Capitalized Words", "მთავრული სიტყვების დამარცვლა"),+ ("Hyphenate Last Word", "ბოლო სიტყვის დამარცვლა"),+ ("Hyphenate Across Column", "სვეტებს შორის დამარცვლა"),+ ("Character Formatting Controls", "სიმბოლოების ფორმატირების მართვა"),+ ("Paragraph Formatting Controls", "აბზაცების ფორმატირების მართვა"),+ ("Font Size", "შრიფტის ზომა"),+ ("Vertical Scale", "ვერტიკალური მასშტაბი"),+ ("Horizontal Scale", "ჰორიზონტალური მასშტაბი"),+ ("Baseline Shift", "საბაზო ხაზის წანაცვლება"),+ ("Skew (False Italic)", "დახრა (ცრუ კურსივი)"),+ ("Left Indent", "მარცხენა შეწევა"),+ ("Right Indent", "მარჯვენა შეწევა"),+ ("First Line Left Indent", "პირველი სტრიქონის მარცხენა შეწევა"),+ ("Last Line Right Indent", "ბოლო სტრიქონის მარჯვენა შეწევა"),+ ("Drop Cap Number of Lines", "ინიციალის სტრიქონების რაოდენობა"),+ ("Drop Cap One or More Characters", "ინიციალი: ერთი ან მეტი სიმბოლო"),+ ("Align to Baseline Grid", "საბაზო ბადეზე სწორება"),+ ("Apply Bullets", "მარკერების გამოყენება"),+ ("Apply Numbers", "ნუმერაციის გამოყენება"),("Inches Decimal", "ინჩები (ათობითი)"),("Back", "უკან"),("Warning", "გაფრთხილება"),diff --cc crates/ui-egui/src/i18n/pl.rsindex b60abd7d4,bf0c7600b..315c7a318--- a/crates/ui-egui/src/i18n/pl.rs+++ b/crates/ui-egui/src/i18n/pl.rs@@@ -29,13 -29,43 +29,50 @@@ pub(super) const TABLE: &[(&str, &str)("Cut", "Wytnij"),("Copy", "Kopiuj"),("Paste", "Wklej"),+ ("Overprint", "Nadruk"),+ ("Top Left Corner", "Lewy górny narożnik"),+ ("Top Right Corner", "Prawy górny narożnik"),+ ("Bottom Left Corner", "Lewy dolny narożnik"),+ ("Bottom Right Corner", "Prawy dolny narożnik"),+ ("Stroke Type", "Rodzaj obrysu"),+ ("Corner Shape", "Kształt narożnika"),+ ("Restart Numbering", "Zacznij numerowanie od nowa"),+ ("Continue Numbering", "Kontynuuj numerowanie"),+ ("Keep Options…", "Opcje utrzymywania…"),+ ("Space Between Paragraphs Using Same Style", "Odstęp między akapitami o tym samym stylu"),+ ("Ignore", "Ignoruj"),+ ("Do Not Align to Baseline Grid", "Nie wyrównuj do siatki linii bazowych"),+ ("Only Align First Line to Grid", "Wyrównaj do siatki tylko pierwszy wiersz"),+ ("Balance Ragged Lines", "Wyrównaj nierówne wiersze"),+ ("Drop Caps and Nested Styles…", "Inicjały i style zagnieżdżone…"),+ ("GREP Styles…", "Style GREP…"),+ ("Restart/Continue Numbering", "Zacznij od nowa/kontynuuj numerowanie"),+ ("Convert Bullets and Numbering to Text", "Konwertuj wypunktowanie i numerowanie na tekst"),+ ("Hyphenation…", "Dzielenie wyrazów…"),+ ("Hyphenation Settings", "Ustawienia dzielenia wyrazów"),+ ("hyphens", "dywizy"),+ ("Hyphenation Zone:", "Strefa dzielenia:"),+ ("Better Spacing", "Lepsze odstępy"),+ ("Fewer Hyphens", "Mniej dywizów"),+ ("Hyphenate Capitalized Words", "Dziel wyrazy pisane wielką literą"),+ ("Hyphenate Last Word", "Dziel ostatni wyraz"),+ ("Hyphenate Across Column", "Dziel między łamami"),+ ("Character Formatting Controls", "Elementy formatowania znaków"),+ ("Paragraph Formatting Controls", "Elementy formatowania akapitów"),+ ("Font Size", "Rozmiar czcionki"),+ ("Vertical Scale", "Skala pionowa"),+ ("Horizontal Scale", "Skala pozioma"),+ ("Baseline Shift", "Przesunięcie linii bazowej"),+ ("Skew (False Italic)", "Pochylenie (fałszywa kursywa)"),+ ("Left Indent", "Wcięcie z lewej"),+ ("Right Indent", "Wcięcie z prawej"),+ ("First Line Left Indent", "Wcięcie pierwszego wiersza z lewej"),+ ("Last Line Right Indent", "Wcięcie ostatniego wiersza z prawej"),+ ("Drop Cap Number of Lines", "Inicjał: liczba wierszy"),+ ("Drop Cap One or More Characters", "Inicjał: jeden lub więcej znaków"),+ ("Align to Baseline Grid", "Wyrównaj do siatki linii bazowych"),+ ("Apply Bullets", "Zastosuj wypunktowanie"),+ ("Apply Numbers", "Zastosuj numerowanie"),("Clear", "Wyczyść"),("Duplicate", "Powiel"),("Select All", "Zaznacz wszystko"),diff --cc crates/ui-egui/src/i18n/pt_br.rsindex 6205265f2,59c4f2e23..1498e4d61--- a/crates/ui-egui/src/i18n/pt_br.rs+++ b/crates/ui-egui/src/i18n/pt_br.rs@@@ -31,13 -31,43 +31,50 @@@ pub(super) const TABLE: &[(&str, &str)("Cut", "Recortar"),("Copy", "Copiar"),("Paste", "Colar"),+ ("Overprint", "Superimprimir"),+ ("Top Left Corner", "Canto superior esquerdo"),+ ("Top Right Corner", "Canto superior direito"),+ ("Bottom Left Corner", "Canto inferior esquerdo"),+ ("Bottom Right Corner", "Canto inferior direito"),+ ("Stroke Type", "Tipo de traçado"),+ ("Corner Shape", "Forma do canto"),+ ("Restart Numbering", "Reiniciar numeração"),+ ("Continue Numbering", "Continuar numeração"),+ ("Keep Options…", "Opções de manutenção…"),+ ("Space Between Paragraphs Using Same Style", "Espaço entre parágrafos com o mesmo estilo"),+ ("Ignore", "Ignorar"),+ ("Do Not Align to Baseline Grid", "Não alinhar à grade de linha de base"),+ ("Only Align First Line to Grid", "Alinhar somente a primeira linha à grade"),+ ("Balance Ragged Lines", "Equilibrar linhas irregulares"),+ ("Drop Caps and Nested Styles…", "Capitulares e estilos aninhados…"),+ ("GREP Styles…", "Estilos GREP…"),+ ("Restart/Continue Numbering", "Reiniciar/continuar numeração"),+ ("Convert Bullets and Numbering to Text", "Converter marcadores e numeração em texto"),+ ("Hyphenation…", "Hifenização…"),+ ("Hyphenation Settings", "Configurações de hifenização"),+ ("hyphens", "hifens"),+ ("Hyphenation Zone:", "Zona de hifenização:"),+ ("Better Spacing", "Melhor espaçamento"),+ ("Fewer Hyphens", "Menos hifens"),+ ("Hyphenate Capitalized Words", "Hifenizar palavras iniciadas por maiúscula"),+ ("Hyphenate Last Word", "Hifenizar última palavra"),+ ("Hyphenate Across Column", "Hifenizar entre colunas"),+ ("Character Formatting Controls", "Controles de formatação de caracteres"),+ ("Paragraph Formatting Controls", "Controles de formatação de parágrafos"),+ ("Font Size", "Tamanho da fonte"),+ ("Vertical Scale", "Escala vertical"),+ ("Horizontal Scale", "Escala horizontal"),+ ("Baseline Shift", "Deslocamento da linha de base"),+ ("Skew (False Italic)", "Inclinação (falso itálico)"),+ ("Left Indent", "Recuo à esquerda"),+ ("Right Indent", "Recuo à direita"),+ ("First Line Left Indent", "Recuo à esquerda da primeira linha"),+ ("Last Line Right Indent", "Recuo à direita da última linha"),+ ("Drop Cap Number of Lines", "Capitular: número de linhas"),+ ("Drop Cap One or More Characters", "Capitular: um ou mais caracteres"),+ ("Align to Baseline Grid", "Alinhar à grade de linha de base"),+ ("Apply Bullets", "Aplicar marcadores"),+ ("Apply Numbers", "Aplicar números"),("Paste Vector Art", "Colar arte vetorial"),("Baseline Options", "Opções de linha de base"),("Fixed Number", "Número fixo"),diff --cc crates/ui-egui/src/i18n/ru.rsindex e859c1448,412faea7e..9f2a568cd--- a/crates/ui-egui/src/i18n/ru.rs+++ b/crates/ui-egui/src/i18n/ru.rs@@@ -33,13 -33,43 +33,50 @@@ pub(super) const TABLE: &[(&str, &str)("Cut", "Вырезать"),("Copy", "Копировать"),("Paste", "Вставить"),+ ("Overprint", "Наложение"),+ ("Top Left Corner", "Левый верхний угол"),+ ("Top Right Corner", "Правый верхний угол"),+ ("Bottom Left Corner", "Левый нижний угол"),+ ("Bottom Right Corner", "Правый нижний угол"),+ ("Stroke Type", "Тип обводки"),+ ("Corner Shape", "Форма угла"),+ ("Restart Numbering", "Начать нумерацию заново"),+ ("Continue Numbering", "Продолжить нумерацию"),+ ("Keep Options…", "Параметры удержания…"),+ ("Space Between Paragraphs Using Same Style", "Интервал между абзацами одного стиля"),+ ("Ignore", "Игнорировать"),+ ("Do Not Align to Baseline Grid", "Не выравнивать по базовой сетке"),+ ("Only Align First Line to Grid", "Выравнивать по сетке только первую строку"),+ ("Balance Ragged Lines", "Сбалансировать рваные строки"),+ ("Drop Caps and Nested Styles…", "Буквицы и вложенные стили…"),+ ("GREP Styles…", "Стили GREP…"),+ ("Restart/Continue Numbering", "Начать заново/продолжить нумерацию"),+ ("Convert Bullets and Numbering to Text", "Преобразовать маркеры и нумерацию в текст"),+ ("Hyphenation…", "Расстановка переносов…"),+ ("Hyphenation Settings", "Параметры расстановки переносов"),+ ("hyphens", "дефисов"),+ ("Hyphenation Zone:", "Зона переносов:"),+ ("Better Spacing", "Лучшие интервалы"),+ ("Fewer Hyphens", "Меньше переносов"),+ ("Hyphenate Capitalized Words", "Переносить слова с прописной буквы"),+ ("Hyphenate Last Word", "Переносить последнее слово"),+ ("Hyphenate Across Column", "Переносить между колонками"),+ ("Character Formatting Controls", "Элементы управления форматированием символов"),+ ("Paragraph Formatting Controls", "Элементы управления форматированием абзацев"),+ ("Font Size", "Кегль"),+ ("Vertical Scale", "Масштаб по вертикали"),+ ("Horizontal Scale", "Масштаб по горизонтали"),+ ("Baseline Shift", "Смещение базовой линии"),+ ("Skew (False Italic)", "Наклон (ложный курсив)"),+ ("Left Indent", "Отступ слева"),+ ("Right Indent", "Отступ справа"),+ ("First Line Left Indent", "Отступ первой строки слева"),+ ("Last Line Right Indent", "Отступ последней строки справа"),+ ("Drop Cap Number of Lines", "Буквица: число строк"),+ ("Drop Cap One or More Characters", "Буквица: один или несколько символов"),+ ("Align to Baseline Grid", "Выровнять по сетке базовых линий"),+ ("Apply Bullets", "Применить маркеры"),+ ("Apply Numbers", "Применить нумерацию"),("Clear", "Очистить"),("Duplicate", "Дублировать"),("Select All", "Выделить все"),diff --cc crates/ui-egui/src/i18n/uk.rsindex ea3546a65,62c594fd1..c736884fa--- a/crates/ui-egui/src/i18n/uk.rs+++ b/crates/ui-egui/src/i18n/uk.rs@@@ -29,13 -29,43 +29,50 @@@ pub(super) const TABLE: &[(&str, &str)("Cut", "Вирізати"),("Copy", "Копіювати"),("Paste", "Вставити"),+ ("Overprint", "Накладання"),+ ("Top Left Corner", "Лівий верхній кут"),+ ("Top Right Corner", "Правий верхній кут"),+ ("Bottom Left Corner", "Лівий нижній кут"),+ ("Bottom Right Corner", "Правий нижній кут"),+ ("Stroke Type", "Тип обведення"),+ ("Corner Shape", "Форма кута"),+ ("Restart Numbering", "Почати нумерацію знову"),+ ("Continue Numbering", "Продовжити нумерацію"),+ ("Keep Options…", "Параметри утримання…"),+ ("Space Between Paragraphs Using Same Style", "Інтервал між абзацами одного стилю"),+ ("Ignore", "Ігнорувати"),+ ("Do Not Align to Baseline Grid", "Не вирівнювати за базовою сіткою"),+ ("Only Align First Line to Grid", "Вирівнювати за сіткою лише перший рядок"),+ ("Balance Ragged Lines", "Збалансувати нерівні рядки"),+ ("Drop Caps and Nested Styles…", "Буквиці та вкладені стилі…"),+ ("GREP Styles…", "Стилі GREP…"),+ ("Restart/Continue Numbering", "Почати знову/продовжити нумерацію"),+ ("Convert Bullets and Numbering to Text", "Перетворити маркери й нумерацію на текст"),+ ("Hyphenation…", "Перенесення…"),+ ("Hyphenation Settings", "Параметри перенесення"),+ ("hyphens", "дефісів"),+ ("Hyphenation Zone:", "Зона перенесення:"),+ ("Better Spacing", "Кращі інтервали"),+ ("Fewer Hyphens", "Менше перенесень"),+ ("Hyphenate Capitalized Words", "Переносити слова з великої літери"),+ ("Hyphenate Last Word", "Переносити останнє слово"),+ ("Hyphenate Across Column", "Переносити між колонками"),+ ("Character Formatting Controls", "Елементи керування форматуванням символів"),+ ("Paragraph Formatting Controls", "Елементи керування форматуванням абзаців"),+ ("Font Size", "Кегль"),+ ("Vertical Scale", "Масштаб по вертикалі"),+ ("Horizontal Scale", "Масштаб по горизонталі"),+ ("Baseline Shift", "Зсув базової лінії"),+ ("Skew (False Italic)", "Нахил (несправжній курсив)"),+ ("Left Indent", "Відступ ліворуч"),+ ("Right Indent", "Відступ праворуч"),+ ("First Line Left Indent", "Відступ першого рядка ліворуч"),+ ("Last Line Right Indent", "Відступ останнього рядка праворуч"),+ ("Drop Cap Number of Lines", "Буквиця: кількість рядків"),+ ("Drop Cap One or More Characters", "Буквиця: один або кілька символів"),+ ("Align to Baseline Grid", "Вирівняти за сіткою базових ліній"),+ ("Apply Bullets", "Застосувати маркери"),+ ("Apply Numbers", "Застосувати нумерацію"),("Paste Vector Art", "Вставити векторну графіку"),("Baseline Options", "Параметри базової лінії"),("Fixed Number", "Фіксована кількість"),diff --cc crates/ui-egui/src/icons.rsindex 544eca689,72c37fc83..36f9b4ec4--- a/crates/ui-egui/src/icons.rs+++ b/crates/ui-egui/src/icons.rs@@@ -938,18 -944,86 +944,98 @@@ pub fn paint(p: &Painter, r: Rect, namepen.line(&[(15.0, 13.5), (17.0, 15.5), (15.0, 17.5)]);}}+ // A box with one corner marked (Top Left, Top Right, Bottom Left, Bottom Right Corner).+ "corner-tl" | "corner-tr" | "corner-bl" | "corner-br" => {+ pen.w = 1.0;+ pen.rect(4.0, 4.0, 16.0, 16.0);+ let (x, y) = match name {+ "corner-tl" => (2.5, 2.5),+ "corner-tr" => (13.5, 2.5),+ "corner-bl" => (2.5, 13.5),+ _ => (13.5, 13.5),+ };+ pen.frect(x, y, x + 4.0, y + 4.0);+ }+ "vscale" => {+ pen.text(13.0, 10.5, "T", 15.0);+ pen.line(&[(4.0, 3.0), (4.0, 17.0)]);+ pen.line(&[(2.5, 5.0), (4.0, 3.0), (5.5, 5.0)]);+ pen.line(&[(2.5, 15.0), (4.0, 17.0), (5.5, 15.0)]);+ }+ "hscale" => {+ pen.text(10.0, 8.0, "T", 13.0);+ pen.line(&[(3.0, 16.5), (17.0, 16.5)]);+ pen.line(&[(5.0, 14.5), (3.0, 16.5), (5.0, 18.5)]);+ pen.line(&[(15.0, 14.5), (17.0, 16.5), (15.0, 18.5)]);+ }+ "baseline-shift" => {+ pen.text(7.0, 11.0, "A", 13.0);+ pen.text(15.5, 5.5, "a", 8.0);+ pen.line(&[(15.5, 17.5), (15.5, 10.0)]);+ pen.line(&[(13.5, 12.0), (15.5, 10.0), (17.5, 12.0)]);+ }+ "skew" => {+ pen.w = 1.8;+ pen.line(&[(7.0, 4.0), (17.0, 4.0)]);+ pen.line(&[(12.0, 4.0), (8.0, 17.0)]);+ }+ "indent-left" | "indent-right" | "indent-first" | "indent-last" => {+ // Text lines, and an arrow at the side (or line) indented.+ let (x0, x1) = match name {+ "indent-left" => (9.0, 18.0),+ "indent-right" => (2.0, 11.0),+ _ => (2.0, 18.0),+ };+ for (k, y) in [4.0, 8.0, 12.0, 16.0].into_iter().enumerate() {+ let (a, z) = match (name, k) {+ ("indent-first", 0) => (9.0, x1),+ ("indent-last", 3) => (x0, 11.0),+ _ => (x0, x1),+ };+ pen.line(&[(a, y), (z, y)]);+ }+ let (y, from, to) = match name {+ "indent-left" => (10.0, 2.0, 7.0),+ "indent-right" => (10.0, 18.0, 13.0),+ "indent-first" => (4.0, 2.0, 7.0),+ _ => (16.0, 18.0, 13.0),+ };+ pen.line(&[(from, y), (to, y)]);+ let d = if to > from { -2.0 } else { 2.0 };+ pen.line(&[(to + d, y - 2.0), (to, y), (to + d, y + 2.0)]);+ }+ "space-before" | "space-after" => {+ let before = name == "space-before";+ let (bar, lines) = if before { (3.0, [11.0, 14.5, 18.0]) } else { (17.0, [2.0, 5.5, 9.0]) };+ pen.line(&[(2.0, bar), (18.0, bar)]);+ for y in lines {+ pen.line(&[(8.0, y), (18.0, y)]);+ }+ let (a, z) = if before { (5.0, 10.0) } else { (10.0, 15.0) };+ pen.line(&[(4.0, a), (4.0, z)]);+ pen.line(&[(2.5, a + 1.5), (4.0, a), (5.5, a + 1.5)]);+ pen.line(&[(2.5, z - 1.5), (4.0, z), (5.5, z - 1.5)]);+ }+ // Space Between Paragraphs Using Same Style: two paragraphs and the space between them.+ "space-same" => {+ for y in [2.0, 5.0, 15.0, 18.0] {+ pen.line(&[(8.0, y), (18.0, y)]);+ }+ pen.line(&[(4.0, 6.5), (4.0, 13.5)]);+ pen.line(&[(2.5, 8.0), (4.0, 6.5), (5.5, 8.0)]);+ pen.line(&[(2.5, 12.0), (4.0, 13.5), (5.5, 12.0)]);+ }+ "drop-lines" | "drop-chars" => {+ pen.text(5.5, 8.0, "A", 14.0);+ if name == "drop-chars" {+ pen.text(13.5, 4.5, "a", 8.0);+ }+ for (y, x) in [(if name == "drop-chars" { 8.5 } else { 3.5 }, 11.0), (8.5, 11.0), (13.5, 11.0), (17.5, 2.0)] {+ if name == "drop-lines" || y > 5.0 {+ pen.line(&[(x, y), (18.0, y)]);+ }+ }+ }"corner" => {pen.w = 1.0;for (x, y) in [(3.0, 3.0), (14.0, 3.0), (3.0, 14.0), (14.0, 14.0)] {