Merge main into fix/save-metadata-only-change

This commit is contained in:
dotCooCoo committed 2026-12-05 11:00:16 -08:00
commit 4c020bfb08
40 files changed
+2395 -229

No files matched your search

Generated
+93 -93
View File
@@ -1256,7 +1256,7 @@ dependencies = [
[[package]]
name = "craft"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"craft-automation",
"craft-behavior",
@@ -1298,7 +1298,7 @@ dependencies = [
[[package]]
name = "craft-affinity"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"crc32fast",
"flate2",
@@ -1319,7 +1319,7 @@ dependencies = [
[[package]]
name = "craft-appkit"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"block2 0.6.2",
"objc2 0.6.5",
@@ -1331,7 +1331,7 @@ dependencies = [
[[package]]
name = "craft-atomic"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"rustix 1.1.6",
]
@@ -1339,7 +1339,7 @@ dependencies = [
[[package]]
name = "craft-automation"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"base64 0.23.1",
"craft-behavior",
@@ -1364,7 +1364,7 @@ dependencies = [
[[package]]
name = "craft-behavior"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"accesskit",
"bitflags 2.13.2",
@@ -1383,7 +1383,7 @@ dependencies = [
[[package]]
name = "craft-browse"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"craft-behavior",
"craft-docpath",
@@ -1401,7 +1401,7 @@ dependencies = [
[[package]]
name = "craft-cdr"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"crc32fast",
"flate2",
@@ -1410,7 +1410,7 @@ dependencies = [
[[package]]
name = "craft-cloud-ui"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"egui",
]
@@ -1418,7 +1418,7 @@ dependencies = [
[[package]]
name = "craft-cms"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"md-5",
"rayon",
@@ -1427,12 +1427,12 @@ dependencies = [
[[package]]
name = "craft-codepage"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
[[package]]
name = "craft-color-ui"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"craft-behavior",
"craft-cms",
@@ -1452,7 +1452,7 @@ dependencies = [
[[package]]
name = "craft-control"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"craft-ai-agents",
"craft-atomic",
@@ -1468,7 +1468,7 @@ dependencies = [
[[package]]
name = "craft-control-protocol"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"getrandom 0.3.4",
"serde_json",
@@ -1478,7 +1478,7 @@ dependencies = [
[[package]]
name = "craft-dds"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"rayon",
]
@@ -1486,7 +1486,7 @@ dependencies = [
[[package]]
name = "craft-dialogs"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"block2 0.6.2",
"craft-appkit",
@@ -1512,7 +1512,7 @@ dependencies = [
[[package]]
name = "craft-doc"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"blake3",
"craft-ecproj-format",
@@ -1528,7 +1528,7 @@ dependencies = [
[[package]]
name = "craft-docpath"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"serde",
]
@@ -1536,7 +1536,7 @@ dependencies = [
[[package]]
name = "craft-draw"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"craft-behavior",
"craft-color-ui",
@@ -1555,7 +1555,7 @@ dependencies = [
[[package]]
name = "craft-dwg"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"acadrust",
"craft-dxf",
@@ -1565,7 +1565,7 @@ dependencies = [
[[package]]
name = "craft-dxf"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"craft-codepage",
"encoding_rs",
@@ -1577,7 +1577,7 @@ dependencies = [
[[package]]
name = "craft-ecproj-format"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"serde",
"serde_json",
@@ -1587,12 +1587,12 @@ dependencies = [
[[package]]
name = "craft-eps"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
[[package]]
name = "craft-flags"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"craft-atomic",
"dirs",
@@ -1602,7 +1602,7 @@ dependencies = [
[[package]]
name = "craft-font-catalog"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"fontique",
"harfrust 0.13.3",
@@ -1617,7 +1617,7 @@ dependencies = [
[[package]]
name = "craft-font-manager"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"craft-behavior",
"craft-font-catalog",
@@ -1636,7 +1636,7 @@ dependencies = [
[[package]]
name = "craft-font-os-windows"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"windows-registry",
"windows-sys 0.61.2",
@@ -1645,7 +1645,7 @@ dependencies = [
[[package]]
name = "craft-font-store"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"cap-primitives",
"craft-atomic",
@@ -1668,12 +1668,12 @@ dependencies = [
[[package]]
name = "craft-fonts-build"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
[[package]]
name = "craft-gif"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"gif",
]
@@ -1681,7 +1681,7 @@ dependencies = [
[[package]]
name = "craft-gzip"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"flate2",
]
@@ -1689,7 +1689,7 @@ dependencies = [
[[package]]
name = "craft-host"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"bitflags 2.13.2",
"craft-i18n",
@@ -1702,7 +1702,7 @@ dependencies = [
[[package]]
name = "craft-i18n"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"brotli 9.1.3",
"brotli-decompressor 6.3.2",
@@ -1732,7 +1732,7 @@ dependencies = [
[[package]]
name = "craft-image-codecs"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"craft-dds",
"craft-jpeg",
@@ -1759,7 +1759,7 @@ dependencies = [
[[package]]
name = "craft-imaging"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"craft-behavior",
"craft-color-ui",
@@ -1777,7 +1777,7 @@ dependencies = [
[[package]]
name = "craft-jpeg"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"thiserror 2.0.21",
]
@@ -1785,7 +1785,7 @@ dependencies = [
[[package]]
name = "craft-jxl"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"brotli-decompressor 5.0.3",
"jixel",
@@ -1796,7 +1796,7 @@ dependencies = [
[[package]]
name = "craft-keymap"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"craft-host",
"craft-i18n",
@@ -1811,7 +1811,7 @@ dependencies = [
[[package]]
name = "craft-layers"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"craft-behavior",
"craft-i18n",
@@ -1825,7 +1825,7 @@ dependencies = [
[[package]]
name = "craft-menu"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"craft-behavior",
"craft-host",
@@ -1843,7 +1843,7 @@ dependencies = [
[[package]]
name = "craft-metadata"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"brotli-decompressor 6.3.2",
"chrono",
@@ -1855,7 +1855,7 @@ dependencies = [
[[package]]
name = "craft-metafile"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"encoding_rs",
"image",
@@ -1866,7 +1866,7 @@ dependencies = [
[[package]]
name = "craft-mime"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"chrono",
"craft-codepage",
@@ -1876,7 +1876,7 @@ dependencies = [
[[package]]
name = "craft-nightly"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"uds_windows",
"winsafe",
@@ -1885,7 +1885,7 @@ dependencies = [
[[package]]
name = "craft-pages"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"craft-behavior",
"craft-keymap",
@@ -1901,7 +1901,7 @@ dependencies = [
[[package]]
name = "craft-pbr"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"craft-texture",
"thiserror 2.0.21",
@@ -1910,7 +1910,7 @@ dependencies = [
[[package]]
name = "craft-pcraft-format"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"flate2",
"serde",
@@ -1921,7 +1921,7 @@ dependencies = [
[[package]]
name = "craft-pdf"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"hayro-interpret",
"hayro-syntax",
@@ -1933,7 +1933,7 @@ dependencies = [
[[package]]
name = "craft-platform"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"async-channel",
"async-io",
@@ -1966,7 +1966,7 @@ dependencies = [
[[package]]
name = "craft-plotter"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"kurbo 0.13.1",
"thiserror 2.0.21",
@@ -1975,7 +1975,7 @@ dependencies = [
[[package]]
name = "craft-print"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"craft-behavior",
"craft-host",
@@ -1999,7 +1999,7 @@ dependencies = [
[[package]]
name = "craft-proof"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"log",
"miniz_oxide 0.9.1",
@@ -2010,7 +2010,7 @@ dependencies = [
[[package]]
name = "craft-ps"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"craft-eps",
"flate2",
@@ -2024,7 +2024,7 @@ dependencies = [
[[package]]
name = "craft-psd"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"encoding_rs",
"flate2",
@@ -2035,7 +2035,7 @@ dependencies = [
[[package]]
name = "craft-quit"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"dispatch2",
"egui",
@@ -2048,7 +2048,7 @@ dependencies = [
[[package]]
name = "craft-raster3d"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"rayon",
"thiserror 2.0.21",
@@ -2057,7 +2057,7 @@ dependencies = [
[[package]]
name = "craft-review"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"base64 0.23.1",
"craft-behavior",
@@ -2076,7 +2076,7 @@ dependencies = [
[[package]]
name = "craft-settings"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"craft-atomic",
"craft-host",
@@ -2093,7 +2093,7 @@ dependencies = [
[[package]]
name = "craft-stream-codecs"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"fax",
"hayro-ccitt",
@@ -2104,7 +2104,7 @@ dependencies = [
[[package]]
name = "craft-svg"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"craft-image-codecs",
"craft-xml",
@@ -2125,7 +2125,7 @@ dependencies = [
[[package]]
name = "craft-table"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"craft-behavior",
"craft-keymap",
@@ -2137,7 +2137,7 @@ dependencies = [
[[package]]
name = "craft-text"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"craft-behavior",
"craft-font-manager",
@@ -2162,7 +2162,7 @@ dependencies = [
[[package]]
name = "craft-texture"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"thiserror 2.0.21",
]
@@ -2170,7 +2170,7 @@ dependencies = [
[[package]]
name = "craft-theme"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"bitflags 2.13.2",
"craft-tracked",
@@ -2185,7 +2185,7 @@ dependencies = [
[[package]]
name = "craft-theme-store"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"craft-atomic",
"craft-behavior",
@@ -2200,7 +2200,7 @@ dependencies = [
[[package]]
name = "craft-tiff"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"serde",
"thiserror 2.0.21",
@@ -2210,7 +2210,7 @@ dependencies = [
[[package]]
name = "craft-time"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"serde",
"thiserror 2.0.21",
@@ -2219,7 +2219,7 @@ dependencies = [
[[package]]
name = "craft-timeline"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"craft-behavior",
"craft-keymap",
@@ -2234,12 +2234,12 @@ dependencies = [
[[package]]
name = "craft-tracked"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
[[package]]
name = "craft-ui"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"craft-cloud-ui",
"craft-ui-canvas",
@@ -2253,7 +2253,7 @@ dependencies = [
[[package]]
name = "craft-ui-canvas"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"craft-behavior",
"craft-font-catalog",
@@ -2270,7 +2270,7 @@ dependencies = [
[[package]]
name = "craft-ui-contract"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"accesskit",
"craft-behavior",
@@ -2308,7 +2308,7 @@ dependencies = [
[[package]]
name = "craft-ui-macros"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"proc-macro-crate",
"proc-macro2",
@@ -2319,7 +2319,7 @@ dependencies = [
[[package]]
name = "craft-ui-panels"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"craft-behavior",
"craft-host",
@@ -2337,7 +2337,7 @@ dependencies = [
[[package]]
name = "craft-ui-patterns"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"craft-behavior",
"craft-host",
@@ -2358,7 +2358,7 @@ dependencies = [
[[package]]
name = "craft-ui-shell"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"craft-behavior",
"craft-host",
@@ -2379,7 +2379,7 @@ dependencies = [
[[package]]
name = "craft-ui-widgets"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"craft-behavior",
"craft-host",
@@ -2398,7 +2398,7 @@ dependencies = [
[[package]]
name = "craft-update"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"base64 0.22.1",
"chrono",
@@ -2430,7 +2430,7 @@ dependencies = [
[[package]]
name = "craft-vectorcraft-format"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"flate2",
"serde",
@@ -2441,7 +2441,7 @@ dependencies = [
[[package]]
name = "craft-wayland"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"raw-window-handle",
"wayland-backend",
@@ -2451,7 +2451,7 @@ dependencies = [
[[package]]
name = "craft-web-api"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"js-sys",
"serde_json",
@@ -2462,7 +2462,7 @@ dependencies = [
[[package]]
name = "craft-win32"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"winsafe",
]
@@ -2470,7 +2470,7 @@ dependencies = [
[[package]]
name = "craft-window"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"craft-appkit",
"craft-atomic",
@@ -2502,7 +2502,7 @@ dependencies = [
[[package]]
name = "craft-xml"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"quick-xml 0.41.0",
"serde",
@@ -3862,7 +3862,7 @@ checksum = "9f4d0e94ddd48749f06bbe4e5389fb9799a0c45bcaf00495042076ef05e3241a"
[[package]]
name = "hayro-cmap"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"brotli 8.0.4",
"hayro-postscript",
@@ -3871,7 +3871,7 @@ dependencies = [
[[package]]
name = "hayro-interpret"
version = "0.7.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"bitflags 2.13.2",
"hayro-cmap",
@@ -3889,7 +3889,7 @@ dependencies = [
[[package]]
name = "hayro-jbig2"
version = "0.3.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"fearless_simd",
"hayro-ccitt",
@@ -3907,12 +3907,12 @@ dependencies = [
[[package]]
name = "hayro-postscript"
version = "0.1.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
[[package]]
name = "hayro-syntax"
version = "0.7.2"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"flate2",
"hayro-ccitt",
@@ -4895,7 +4895,7 @@ dependencies = [
[[package]]
name = "krilla"
version = "0.8.2"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"base64 0.22.1",
"bumpalo",
@@ -5052,7 +5052,7 @@ checksum = "d4a5ff6bcca6c4867b1c4fd4ef63e4db7436ef363e0ad7531d1558856bae64f4"
[[package]]
name = "linesweeper"
version = "0.5.0"
source = "git+https://github.com/storytold/craft-libs?rev=4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da#4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da"
source = "git+https://github.com/storytold/craft-libs?rev=bd7c9e342a33796c9b36b33763c5b63883a22b79#bd7c9e342a33796c9b36b33763c5b63883a22b79"
dependencies = [
"arrayvec",
"kurbo 0.13.1",
@@ -9889,9 +9889,9 @@ dependencies = [
[[package]]
name = "wgpu-hal"
version = "30.0.1"
version = "30.0.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "b6b7fb58561a792bc237628ba0792e332de418fefe145f13b5ed8201e6d52f58"
checksum = "a57452fe453658e141aafdb09de1028afa498805fab518238ddf372a518813ff"
dependencies = [
"android_system_properties",
"arrayvec",
+41 -41
View File
@@ -10,60 +10,60 @@ license = "MIT OR Apache-2.0"
rust-version = "1.95"
[workspace.dependencies]
craft-cms = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da" }
craft-pdf = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da", default-features = false, features = ["interpret", "write"] }
craft-docpath = { version = "0.1.0", git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da" }
craft-proof = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da" }
craft-cms = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79" }
craft-pdf = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79", default-features = false, features = ["interpret", "write"] }
craft-docpath = { version = "0.1.0", git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79" }
craft-proof = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79" }
# Language packs: the Craft apps' shared font store installs them (#4936).
craft-font-store = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da" }
craft-font-catalog = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da" }
craft-font-store = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79" }
craft-font-catalog = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79" }
# The `.vectorcraft` envelope: its members, version, embedded images and the data after the JSON.
craft-vectorcraft-format = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da" }
craft-gzip = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da" }
craft-vectorcraft-format = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79" }
craft-gzip = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79" }
# `.pcraft` documents: their manifest, full-size composite, preview, layer pixels and ICC profile.
craft-doc = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da", features = ["pcraft-pixels"] }
craft-doc = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79", features = ["pcraft-pixels"] }
# Native Affinity documents (craft-libs#914).
craft-affinity = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da" }
craft-affinity = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79" }
# Bounded CDR (v1-v27) and CMX (32-bit) reader (craft-libs#778).
craft-cdr = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da" }
craft-cdr = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79" }
# SVG parsing, limits, SVGZ and writer (craft-libs#778).
craft-svg = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da", features = ["tree"] }
craft-mime = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da" }
craft-svg = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79", features = ["tree"] }
craft-mime = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79" }
# EPS container, previews, ASCII85 and DSC comments (craft-libs#778).
craft-eps = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da" }
craft-eps = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79" }
# DXF tags, reader and writer (craft-libs#778, #926, #927).
craft-plotter = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da" }
craft-dxf = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da" }
craft-plotter = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79" }
craft-dxf = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79" }
# DWG to DXF bytes, in a child process on desktop builds (acadrust 0.6.6, MPL-2.0, unmodified).
craft-dwg = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da" }
craft-dwg = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79" }
# The DWG reader and writer craft-dwg uses, at the rev craft-libs pins (its Cargo.toml). Tests only: it writes the
# R12, R13 and R14 DWG files that craft-dwg's writer, 2000 and later, does not.
acadrust = { git = "https://github.com/storytold/acadrust.git", rev = "468b9d8e317755209020d5d3f2f1c8a76210c47f" }
# WMF, EMF and EMF+ reader (craft-libs#778).
craft-metafile = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da" }
craft-xml = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da" }
craft-image-codecs = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da" }
craft-gif = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da" }
craft-tiff = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da" }
craft-ps = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da", default-features = false, features = ["read", "write"] }
craft-psd = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da" }
craft-stream-codecs = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da" }
craft-jxl = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da" }
craft-codepage = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da" }
craft-metafile = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79" }
craft-xml = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79" }
craft-image-codecs = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79" }
craft-gif = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79" }
craft-tiff = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79" }
craft-ps = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79", default-features = false, features = ["read", "write"] }
craft-psd = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79" }
craft-stream-codecs = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79" }
craft-jxl = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79" }
craft-codepage = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79" }
# The metallic-roughness BRDF and environment light the 3D effects' Roughness and Metallic shade with.
craft-pbr = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da" }
craft-pbr = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79" }
# The CPU rasterizer that draws a 3D effect's Render Settings › Rendered image: depth-buffered triangles, shadow maps.
craft-raster3d = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da" }
craft-raster3d = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79" }
# The framework facade (`craft::ui`, `craft::settings`, `craft::platform`, ...). No default features: each crate names
# the members it imports.
craft = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da" }
craft = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79" }
# Below the egui layer, so not through the facade: the colour harmony rules and their settings (craft-color-ui
# without its `ui` feature), the colour type they work in, and the craft-fonts tables the text crate's build writes.
craft-color-ui = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da" }
craft-theme = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da" }
craft-fonts-build = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da" }
craft-color-ui = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79" }
craft-theme = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79" }
craft-fonts-build = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79" }
# Nightly profile isolation, launch protocol, and security fence.
craft-nightly = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da" }
craft-nightly = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79" }
# internal
vectorcraft-geom = { path = "crates/geom" }
vectorcraft-color = { path = "crates/color" }
@@ -203,13 +203,13 @@ lto = "thin"
codegen-units = 1
[patch.crates-io]
hayro-syntax = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da" }
hayro-interpret = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da" }
hayro-jbig2 = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da" }
hayro-cmap = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da" }
hayro-postscript = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da" }
krilla = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da" }
linesweeper = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da" }
hayro-syntax = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79" }
hayro-interpret = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79" }
hayro-jbig2 = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79" }
hayro-cmap = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79" }
hayro-postscript = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79" }
krilla = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79" }
linesweeper = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79" }
# skrifa 0.44 (epaint, glifo, usvg) with the automatic hinter's long blue-zone exit (craft-libs vendor/skrifa).
# It stays at this rev until craft-libs#5222 merges.
skrifa = { git = "https://github.com/storytold/craft-libs", rev = "37d0532f42eb3421769c8a454e3e25a20fbcff97" }
+1 -1
View File
@@ -28,7 +28,7 @@ egui_extras = { workspace = true }
# `wgpu` pulls egui-wgpu's defaults: WebGPU plus the WebGL2 fallback.
eframe = { workspace = true, features = ["default_fonts", "wgpu", "accesskit"] }
# The page command API (storytold/craft-libs#413): the request plumbing behind window.vectorcraft.
craft-web-api = { git = "https://github.com/storytold/craft-libs", rev = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da", version = "0.1.0" }
craft-web-api = { git = "https://github.com/storytold/craft-libs", rev = "bd7c9e342a33796c9b36b33763c5b63883a22b79", version = "0.1.0" }
wasm-bindgen = "0.2"
serde_json = { workspace = true }
+13 -15
View File
@@ -287,29 +287,27 @@ fn insert_look_turned(
Ok(json!({ "id": id.0 }))
}
/// Draw Inside's clip group for `target`, the object new art goes inside: the clip group
/// [mask copy, target, …] `target` already is the clipped object of, else one made where `target`
/// was, holding an unpainted clipping copy of it and then `target`. New art and pastes go on top
/// of its children.
/// Draw Inside's clip group for `target`, the object new art goes inside: the clip group `target`
/// already is the clipping path of, else one made where `target` was, with `target` as its
/// clipping path. `target` keeps its appearance, so its fills paint behind the art drawn inside it
/// and its strokes over that art, unclipped ([`Node::clip_paint`], #8753). New art and pastes go
/// on top of the group's children.
pub(crate) fn draw_inside_group(d: &mut vectorcraft_doc::Document, target: NodeId) -> Result<NodeId> {
if let Some(p) = d.parent_of(target)
&& d.node(p).is_some_and(|pn| matches!(&pn.kind, NodeKind::Group { clip: true, children } if children.get(1).is_some_and(|c| c.id == target)))
&& d.node(p)
.is_some_and(|pn| matches!(&pn.kind, NodeKind::Group { clip: true, children } if children.first().is_some_and(|c| c.id == target)))
{
return Ok(p);
}
let (par, idx, _) = d.position(target).ok_or(crate::EngineError::NoNode(target))?;
// The mask is a copy with ids of its own, its subpaths' too (a compound path's).
let original = d.node(target).cloned().ok_or(crate::EngineError::NoNode(target))?;
let mut mask = d.reid(&original);
mask.appearance = Appearance::basic(vectorcraft_color::Paint::None, vectorcraft_color::Paint::None, 0.0).into();
if let NodeKind::Path { clipping, .. } = &mut mask.kind {
let gid = d.alloc_id();
d.insert(par, idx + 1, Node::new(gid, NodeKind::Group { children: vec![], clip: true }))?;
d.move_node(target, Some(gid), 0)?;
// A compound path or type is the clipping path by being the group's first child; a path is
// marked as well, as Make Clipping Mask marks it.
if let Some(NodeKind::Path { clipping, .. }) = d.node_mut(target).map(|n| &mut n.kind) {
*clipping = true;
}
let gid = d.alloc_id();
d.insert(par, idx + 1, Node::new(gid, NodeKind::Group { children: vec![std::sync::Arc::new(mask)], clip: true }))?;
d.move_node(target, Some(gid), usize::MAX)?;
// Copied type whose layout caches `reid` dropped has them again.
super::typecmd::refresh_bounds_of(d, &[gid]);
Ok(gid)
}
+18 -1
View File
@@ -5,6 +5,9 @@
use serde_json::{Value, json};
use vectorcraft_doc::NodeKind;
use super::typemenu::all_texts;
use super::{CommandSpec, EngineError, Result, Session, always, bad, cmd, text_param};
use crate::packs::{self, Outcome};
@@ -16,7 +19,7 @@ pub fn specs() -> Vec<CommandSpec> {
"Language Packs",
[],
None,
"{refresh?: bool (fetch the pinned pack index again; needs downloading on; refused under automation roots; in the desktop app it runs in the background: see refreshing)} the Language packs that spell-check and hyphenate languages other than English, shared by the Craft apps → {packs: [{locale, name, size: bytes, licence: SPDX, class, spelling: bool, hyphenation: bool, installed: bool}…] (the index fetched last; empty before the first fetch), installed: [{locale, name, licence}…] (the packs spelling and hyphenation use), installing: [{locale, done, total}…] (bytes), refreshing: bool, errors: {locale: message} (the last failure of each install or removal; \"\": of the index fetch), downloads: bool (the person allowed downloading), indexOverride: string|null (a test index used instead of the pinned one), available: bool (there is a font store folder to install into)}",
"{refresh?: bool (fetch the pinned pack index again; needs downloading on; refused under automation roots; in the desktop app it runs in the background: see refreshing)} the Language packs that spell-check and hyphenate languages other than English, shared by the Craft apps → {packs: [{locale, name, size: bytes, licence: SPDX, class, spelling: bool, hyphenation: bool, installed: bool}…] (the index fetched last; empty before the first fetch), installed: [{locale, name, licence}…] (the packs spelling and hyphenation use), installing: [{locale, done, total}…] (bytes), refreshing: bool, errors: {locale: message} (the last failure of each install or removal; \"\": of the index fetch), downloads: bool (the person allowed downloading), indexOverride: string|null (a test index used instead of the pinned one), available: bool (there is a font store folder to install into), missing: [{lang, locale: string|null}…] (the languages of the front document's visible, unlocked type that have no dictionary: each with its pack's locale, null before the index is first fetched; a language the fetched index has no pack for is left out)}",
always,
list
),
@@ -82,9 +85,23 @@ fn list(s: &mut Session, p: &Value) -> Result<Value> {
"downloads": backend.as_ref().is_some_and(|b| b.downloads_on()),
"indexOverride": backend.as_ref().and_then(|b| b.index_override()),
"available": backend.is_some(),
"missing": missing(s).iter().map(|m| json!({"lang": m.tag, "locale": m.pack.as_ref().map(|p| &p.locale)})).collect::<Vec<_>>(),
}))
}
/// The languages of the front document's type (the type spell check reads: visible, unlocked) that
/// have no dictionary yet, with the pack for each ([`packs::missing_of`]): what the missing-pack
/// bar offers, and `proof.packs`'s `missing`.
pub fn missing(s: &Session) -> Vec<packs::Missing> {
let Ok(st) = s.doc() else { return Vec::new() };
let texts = all_texts(&st.doc);
let runs = texts.iter().filter_map(|id| match st.doc.node(*id).map(|n| &n.kind) {
Some(NodeKind::Text(t)) => Some(t.runs.iter()),
_ => None,
});
packs::missing_of(runs.flatten().filter_map(|r| r.style.language.as_deref()))
}
/// Refuses `command` for a caller confined to automation roots: the packs are written into the font
/// store the Craft apps share, which is outside them.
fn not_confined(command: &str) -> Result<()> {
+9 -1
View File
@@ -608,13 +608,21 @@ impl Transaction {
for st in &mut s.docs {
// Past the newest revision the document reached, so the restored one redraws. A
// document the transaction left as it was keeps its revision, so a run made
// away from the session on it still applies.
// away from the session on it still applies. Putting back an older snapshot, or
// reopening a document the calls closed, counts as a rollback: an object the calls
// made can lose its node ID to a new one. The count never goes below the highest
// one the document reached.
let reached: Vec<_> = open.iter().filter(|d| d.uid == st.uid).collect();
let unchanged = !reached.is_empty() && reached.iter().all(|d| d.revision == st.revision && d.selection == st.selection);
if !unchanged {
let newest = reached.iter().map(|d| d.revision).max().unwrap_or(st.revision);
st.revision = newest.max(st.revision).saturating_add(1);
}
let rollbacks = reached.iter().map(|d| d.rollbacks).max().unwrap_or(st.rollbacks);
st.rollbacks = rollbacks.max(st.rollbacks);
if reached.is_empty() || reached.iter().any(|d| !Arc::ptr_eq(&d.doc, &st.doc)) {
st.rollbacks = st.rollbacks.saturating_add(1);
}
crate::deselect_hidden(&s.menu, &st.doc, &mut st.selection);
}
s.active = active;
+1
View File
@@ -231,6 +231,7 @@ pub(crate) fn leave(s: &mut Session, _: &Value) -> Result<Value> {
st.selection.prune(&st.doc);
st.history.redo = Arc::unwrap_or_clone(redo);
st.revision += 1;
st.rollbacks += 1;
} else {
s.edit("Exit Symbol Editing Mode", |d, sel| {
finish(d, sel);
+1
View File
@@ -2249,6 +2249,7 @@ fn discard_empty(s: &mut Session, p: &Value) -> Result<Value> {
st.selection.prune(&st.doc);
super::globaledit::follow_history(st);
st.revision += 1;
st.rollbacks += 1;
return Ok(json!({"removed": true}));
}
}
+16 -2
View File
@@ -2,6 +2,8 @@
//! Options, Dynamic Text, Fill with Placeholder Text, Insert Special/Whitespace/Break characters)
//! and the text commands of the Edit menu (Find and Replace, Find Next, Paste without Formatting).
use std::ops::ControlFlow;
use serde_json::{Value, json};
use vectorcraft_doc::{AreaFit, CharStyle, Document, Justify, LockedArtboards, Node, NodeId, NodeKind, Quotes, TextKind, TextObject, TextRun};
use vectorcraft_geom::{Affine, Rect, shapes};
@@ -40,7 +42,7 @@ pub fn specs() -> Vec<CommandSpec> {
["Type"],
None,
"{ids?|id?} point type → area type framed by its current layout bounds → {ids}",
has_selection,
|s| has_selected_text_kind(s, |kind| matches!(kind, TextKind::Point), "select point type"),
to_area
),
cmd!(
@@ -49,7 +51,7 @@ pub fn specs() -> Vec<CommandSpec> {
["Type"],
None,
"{ids?|id?} area type → point type; soft line wraps become line breaks, a frame of threaded text leaves its thread with the text it holds, and Dynamic Text (Block) is turned off, keeping the sizes it set → {ids}",
has_selection,
|s| has_selected_text_kind(s, |kind| matches!(kind, TextKind::Area { .. }), "select area type"),
to_point
),
cmd!(
@@ -154,6 +156,18 @@ pub fn specs() -> Vec<CommandSpec> {
]
}
/// A selected object or one of its descendants has the source kind a conversion needs.
fn has_selected_text_kind(s: &Session, matches_kind: fn(&TextKind) -> bool, reason: &str) -> std::result::Result<(), String> {
let st = s.active().ok_or("no document open")?;
let found = st.selection.objects.iter().filter_map(|id| st.doc.node(*id)).any(|node| {
node.try_walk(&mut |child| {
if matches!(&child.kind, NodeKind::Text(text) if matches_kind(&text.kind)) { ControlFlow::Break(()) } else { ControlFlow::Continue(()) }
})
.is_break()
});
found.then_some(()).ok_or_else(|| reason.into())
}
/// Text objects among `ids` and their descendants.
pub(crate) fn text_ids(d: &Document, ids: &[NodeId]) -> Vec<NodeId> {
let paths = d.index_paths(ids.iter().copied());
+13
View File
@@ -121,6 +121,15 @@ pub struct DocState {
/// Advances when Undo, Redo or a canceled undo group restores an older document snapshot. The same node ID can name different objects
/// across that boundary.
pub history_restores: u64,
/// Advances when a canceled interaction, Exit Symbol Editing Mode taking
/// back the entering step, Discard Empty Type taking back the step that made the text, or a command
/// that panicked puts back an older document snapshot. A canceled plug-in run advances it
/// when its calls changed the document. A preview advances it when it discards an earlier preview
/// that allocated node IDs, or fails after discarding an earlier preview's document change.
/// A command run during a tool interaction advances it when it sets aside a preview that allocated
/// node IDs.
/// The same node ID can name different objects across that boundary.
pub rollbacks: u64,
/// Preferences › User Interface › Open Documents As Tabs when the document opened: cleared,
/// the UI opens it in a floating window of its own.
pub opened_as_tab: bool,
@@ -556,6 +565,7 @@ impl DocState {
activated: 0,
reverts: 0,
history_restores: 0,
rollbacks: 0,
opened_as_tab: true,
mask_view: None,
spelling_ignored: Default::default(),
@@ -812,6 +822,9 @@ impl DocState {
/// End the interaction in progress, undoing what it changed.
pub(crate) fn undo_interaction(&mut self) {
if let Some(it) = self.interaction.take() {
if !Arc::ptr_eq(&self.doc, &it.doc) {
self.rollbacks += 1;
}
self.doc = it.doc;
self.selection = Arc::unwrap_or_clone(it.selection);
self.sync_new_art();
+141 -1
View File
@@ -59,6 +59,11 @@ pub trait Backend: Send + Sync {
fn index_override(&self) -> Option<String> {
None
}
/// Turns downloading on. Only from the person's own click in the app (an Install or Refresh
/// button, [`enable_downloads`]): no command calls it.
fn enable_downloads(&self) -> Result<(), String> {
Err(not_allowed())
}
}
/// An install running.
@@ -82,6 +87,8 @@ static JOBS: Mutex<Jobs> = Mutex::new(Jobs { installing: BTreeMap::new(), refres
static BACKGROUND: AtomicBool = AtomicBool::new(false);
/// Goes up each time the installed packs change.
static GENERATION: AtomicU64 = AtomicU64::new(0);
/// Goes up each time a fetch of the index ends, done or failed ([`index_generation`]).
static INDEX_GENERATION: AtomicU64 = AtomicU64::new(0);
fn jobs() -> MutexGuard<'static, Jobs> {
JOBS.lock().unwrap_or_else(PoisonError::into_inner)
@@ -119,6 +126,18 @@ pub fn generation() -> u64 {
GENERATION.load(Ordering::Relaxed)
}
/// Goes up each time a fetch of the index ends, done or failed: what [`available`] lists may have changed (a window
/// that keeps the list keys it on this).
pub fn index_generation() -> u64 {
INDEX_GENERATION.load(Ordering::Relaxed)
}
/// `r`, a fetch of the index that ended, counted in [`index_generation`].
fn fetched<T>(r: T) -> T {
INDEX_GENERATION.fetch_add(1, Ordering::Relaxed);
r
}
/// Read the packs folder again: spelling and hyphenation in its languages change.
fn changed() {
craft_proof::packs::reload();
@@ -149,6 +168,33 @@ fn downloads_off() -> String {
"downloading is turned off; only the person using a Craft app can turn it on, by installing a Language pack there".into()
}
fn not_allowed() -> String {
"only the person using the app can turn on downloading, with their own click".into()
}
/// Turns the font store's downloading on, for every Craft app. The app calls it only for the
/// person's own click on Install or Refresh (never for input the control channel injected), and no
/// command calls it (RFC-0011): an agent can install once the person has turned it on.
pub fn enable_downloads() -> Result<(), String> {
backend().ok_or_else(no_backend)?.enable_downloads()
}
/// An installed pack, as spelling and hyphenation read it.
#[derive(Clone, Debug, PartialEq, Eq)]
pub struct Installed {
/// The pack's locale (`nl`).
pub locale: String,
/// The language's own name, from the pack.
pub name: String,
/// SPDX licence expression of the pack's data.
pub licence: String,
}
/// The packs installed in the store (by this app or another), the ones spelling and hyphenation use.
pub fn installed() -> Vec<Installed> {
craft_proof::packs::installed().into_iter().map(|i| Installed { locale: i.locale, name: i.name, licence: i.licence }).collect()
}
/// The packs the index fetched last lists.
pub fn available() -> Vec<Pack> {
backend().map(|b| b.cached_index()).unwrap_or_default()
@@ -221,6 +267,7 @@ pub fn refresh() -> Result<Outcome, String> {
run(
move || {
let r = b.fetch_index(&cancel).map(|_| ());
INDEX_GENERATION.fetch_add(1, Ordering::Relaxed);
let mut j = jobs();
j.refreshing = None;
if let Err(e) = &r {
@@ -274,7 +321,7 @@ pub fn install(locale: &str) -> Result<Outcome, String> {
fn install_now(b: &dyn Backend, locale: &str, cancel: &Cancel) -> Result<(), String> {
let listed = |packs: &[Pack]| packs.iter().any(|p| p.locale == locale);
if !listed(&b.cached_index()) && !listed(&b.fetch_index(cancel)?) {
if !listed(&b.cached_index()) && !listed(&fetched(b.fetch_index(cancel))?) {
return Err(format!("there is no Language pack for {locale}"));
}
b.install(locale, cancel, &mut |done, total| {
@@ -309,6 +356,93 @@ pub fn remove(locale: &str) -> Result<(), String> {
r
}
/// Most languages [`missing`] reports for one document.
const MAX_MISSING: usize = 16;
/// A language the document's type is in that spelling (and hyphenation) can't check yet: what
/// the missing-pack bar offers.
#[derive(Clone, Debug, PartialEq, Eq)]
pub struct Missing {
/// The type's language tag (`hi`, `sr-Latn`).
pub tag: String,
/// The pack the index lists for it; `None` before the index is first fetched, when whether
/// there is one isn't known yet.
pub pack: Option<Pack>,
}
/// Of the language tags `tags` (a document's type's, in order, repeats allowed), those with no
/// dictionary: each with the pack the index lists for it, or, before the index is first fetched,
/// with none. A language the fetched index has no pack for is left out, and so is any language
/// while there is no store to install into ([`crate::cmd::packs::missing`] reads the tags).
pub fn missing_of<'a>(tags: impl IntoIterator<Item = &'a str>) -> Vec<Missing> {
if backend().is_none() {
return Vec::new();
}
let index = available();
let mut out: Vec<Missing> = Vec::new();
let mut seen: Vec<&str> = Vec::new();
for tag in tags {
if seen.contains(&tag) {
continue;
}
seen.push(tag);
// English spells from built-in data; a tag that is no language (`und`, `zxx`) has none.
let lang = craft_proof::ProofLang::from_tag(Some(tag));
if lang == craft_proof::ProofLang::Other || lang.is_english() || craft_proof::missing_dictionary(Some(tag)).is_none() {
continue;
}
let pack = pack_for_tag(tag, &index).cloned();
if pack.is_none() && !index.is_empty() {
continue;
}
// Two tags of one pack (`nl`, `nl-BE`) offer it once.
if pack.is_some() && out.iter().any(|m| m.pack == pack) {
continue;
}
out.push(Missing { tag: tag.to_string(), pack });
if out.len() >= MAX_MISSING {
break;
}
}
out
}
/// The pack for a language tag: the whole tag's (`pt-pt`), else each shorter prefix's
/// (`sr-latn` for `sr-Latn-RS`, `nl` for `nl-NL`), the first `packs` lists. A variant after the
/// region is tried without the region before the region alone (`ca-ES-valencia` is the
/// `ca-valencia` pack's). `None` for English and for a tag no pack is for.
pub fn pack_for_tag<'a>(tag: &str, packs: &'a [Pack]) -> Option<&'a Pack> {
pack_candidates(tag).iter().find_map(|c| packs.iter().find(|p| &p.locale == c))
}
/// Whether `subtag`, after a tag's language (and script), is a region: two letters or three digits.
fn is_region(subtag: &str) -> bool {
(subtag.len() == 2 && subtag.bytes().all(|b| b.is_ascii_alphabetic())) || (subtag.len() == 3 && subtag.bytes().all(|b| b.is_ascii_digit()))
}
/// The pack locales [`pack_for_tag`] tries for `tag`, best first.
fn pack_candidates(tag: &str) -> Vec<String> {
// A tag is a handful of short subtags; anything longer is junk and only its start is read.
let tag: String = tag.trim().chars().take(64).collect::<String>().replace('_', "-").to_ascii_lowercase();
let parts: Vec<&str> = tag.split('-').collect();
let base = parts.first().copied().unwrap_or("");
if base.is_empty() || base == "en" {
return Vec::new();
}
let mut out: Vec<String> = Vec::new();
for n in (1..=parts.len()).rev() {
let prefix = parts.get(..n).unwrap_or_default();
// The prefix, then without its regions: the variant's pack before the region alone.
let stripped: Vec<&str> = prefix.iter().enumerate().filter(|(i, p)| *i == 0 || !is_region(p)).map(|(_, p)| *p).collect();
for c in [prefix.join("-"), stripped.join("-")] {
if !out.contains(&c) {
out.push(c);
}
}
}
out
}
/// The pack index this build trusts: craft-i18n's Language pack release `language-packs-2` (75
/// packs), pinned by the sha256 of its `index.json`. The font store reads
/// `CRAFT_LANGUAGE_PACK_INDEX` itself, to try packs from a test index (testing only).
@@ -380,6 +514,12 @@ impl Backend for FontStoreBackend {
fn index_override(&self) -> Option<String> {
craft_font_store::language_pack_index_overridden()
}
fn enable_downloads(&self) -> Result<(), String> {
// The store is opened as an agent's, which can't turn downloading on: the same folder,
// opened as the person's, does (the setting is a file in it, read on each use).
craft_font_store::FontStore::new(self.store.dir().to_path_buf(), craft_font_store::Caller::User).enable_network().map_err(|e| e.to_string())
}
}
/// The font store backend in `dir`, for tests that need the real store without a request.
+55 -3
View File
@@ -869,7 +869,9 @@ fn items_remove_all(h: &super::Host, a: &[Data]) -> Answer {
/// Whether a subpath of `outline` encloses an area. Each subpath's area is measured from its first
/// point, so its position does not change the result, and an area within roundoff of its own
/// bounding box's is counted as none.
/// bounding box's is counted as none. A subpath that crosses itself, such as a figure eight whose
/// loops turn opposite ways and cancel in its signed area, is measured by the area it fills under
/// nonzero, which every loop counts toward.
fn encloses(outline: &kurbo::BezPath) -> bool {
let mut subpaths: Vec<kurbo::BezPath> = Vec::new();
for el in outline.elements() {
@@ -883,11 +885,35 @@ fn encloses(outline: &kurbo::BezPath) -> bool {
subpaths.into_iter().any(|mut sub| {
let Some(start) = sub.elements().iter().find_map(|e| e.end_point()) else { return false };
sub.apply_affine(kurbo::Affine::translate(-start.to_vec2()));
let area = kurbo::Shape::area(&sub).abs();
area > 0.0 && area > 64.0 * f64::EPSILON * kurbo::Shape::bounding_box(&sub).area()
let floor = 64.0 * f64::EPSILON * kurbo::Shape::bounding_box(&sub).area();
let counts = |area: f64| area > 0.0 && area > floor;
counts(kurbo::Shape::area(&sub).abs())
|| (!collinear(&sub)
&& vectorcraft_pathops::try_area(&vectorcraft_geom::PathData::from_bezpath(&sub), vectorcraft_geom::FillRule::NonZero)
.is_ok_and(counts))
})
}
/// Whether every point and control point of `sub` lies within roundoff of one straight line, as
/// in a frame collapsed to a line, which encloses no area however the path operations snap it.
fn collinear(sub: &kurbo::BezPath) -> bool {
let points: Vec<kurbo::Point> = sub
.elements()
.iter()
.flat_map(|e| match *e {
kurbo::PathEl::MoveTo(p) | kurbo::PathEl::LineTo(p) => vec![p],
kurbo::PathEl::QuadTo(a, p) => vec![a, p],
kurbo::PathEl::CurveTo(a, b, p) => vec![a, b, p],
kurbo::PathEl::ClosePath => vec![],
})
.collect();
let Some(&first) = points.first() else { return true };
let Some(&far) = points.iter().max_by(|a, b| a.distance(first).total_cmp(&b.distance(first))) else { return true };
let axis = far - first;
let length = axis.hypot();
length == 0.0 || points.iter().all(|p| axis.cross(*p - first).abs() <= 64.0 * f64::EPSILON * length * length)
}
/// Whether `outline` fills an area under `rule`: a subpath encloses an area ([`encloses`]) and the
/// outline with its overlaps resolved, thin strips included, has an area. An outline the path
/// operations refuse is judged by [`encloses`] alone.
@@ -2536,6 +2562,32 @@ mod tests {
assert_eq!(anchors, vec![(0, 1), (0, 3)], "the undo puts back the selection the write changed");
}
#[test]
fn a_figure_eight_clip_outline_fills_its_loops() {
let mut eight = kurbo::BezPath::new();
eight.move_to((0.0, 0.0));
eight.line_to((10.0, 10.0));
eight.line_to((10.0, 0.0));
eight.line_to((0.0, 10.0));
eight.close_path();
assert!(kurbo::Shape::area(&eight).abs() < 1e-9, "the loops cancel in the signed area");
assert!(encloses(&eight), "each loop of the figure eight encloses an area");
assert!(fills(&eight, vectorcraft_geom::FillRule::NonZero));
assert!(fills(&eight, vectorcraft_geom::FillRule::EvenOdd));
let mut line = kurbo::BezPath::new();
line.move_to((0.0, 0.0));
line.line_to((10.0, 10.0));
line.close_path();
assert!(!encloses(&line), "a closed line still encloses nothing");
let mut flat = kurbo::BezPath::new();
flat.move_to((0.0, 0.0));
flat.line_to((1000.0, 0.001));
flat.line_to((2000.0, 0.002));
flat.line_to((1000.0, 0.001));
flat.close_path();
assert!(!encloses(&flat), "a frame collapsed onto a shallow diagonal encloses nothing");
}
#[test]
fn a_made_id_above_two_to_the_53_stays_exact() {
let made = |v: Value| made_id(&(Data::Undefined, v));
+15 -2
View File
@@ -373,6 +373,9 @@ impl Session {
let previewed = !Arc::ptr_eq(&st.doc, &interaction.doc) || st.selection != *interaction.selection;
let shown = previewed.then(|| (st.doc.clone(), st.selection.clone()));
if previewed {
if st.doc.peek_next_id() > interaction.doc.peek_next_id() {
st.rollbacks += 1;
}
st.doc = interaction.doc.clone();
if let Some((shown_doc, _)) = shown.as_ref().filter(|_| interaction.dialog) {
shown_base_selection(&mut st.selection, shown_doc, &st.doc);
@@ -667,7 +670,7 @@ impl Session {
// `defaultsOnly: true`, and one after it.
let tool_paints = self.tool_paints(false) || self.tool_paints(true);
let new_art_basic = self.prefs.new_art_basic;
let (paint, restore_paint, inherited, last_preview_paint) = {
let (paint, restore_paint, inherited, last_preview_paint, discarded_uid, freed_ids, discarded) = {
let menu = self.menu.clone();
let st = self.doc_mut()?;
let Some(it) = &mut st.interaction else { return Err(EngineError::Other("no interaction in progress".into())) };
@@ -678,6 +681,8 @@ impl Session {
st.revision += 1;
}
let undone = std::mem::replace(&mut st.doc, it.doc.clone());
let freed_ids = undone.peek_next_id() > it.doc.peek_next_id();
let discarded = !Arc::ptr_eq(&undone, &it.doc);
let isolation = it.isolation;
// A batch, or a preview that changed the new-art paints (a pattern rename), started from
// the paints the interaction began with.
@@ -711,7 +716,7 @@ impl Session {
// undone with it.
st.restore_isolation(isolation, &undone);
cmd::globaledit::follow_history(st);
(paint, restore_paint, inherited, last_preview_paint)
(paint, restore_paint, inherited, last_preview_paint, st.uid, freed_ids, discarded)
};
// The paints before the previews that build on each other: a preview that starts from the
// interaction's paints (or from the inherited ones) starts a new run of them. A field that
@@ -757,6 +762,14 @@ impl Session {
}
let after_paint = r.is_ok().then(|| (base, self.paint.clone()));
let after_item = self.active_appearance_item.clone();
// A preview advances rollbacks when it discards an earlier preview that allocated node IDs, or
// fails after discarding an earlier preview's document change, even when the command activates
// another document.
if let Some(st) = self.docs.iter_mut().find(|d| d.uid == discarded_uid)
&& (freed_ids || (r.is_err() && discarded))
{
st.rollbacks += 1;
}
let st = self.doc_mut()?;
if let Some(it) = &mut st.interaction {
it.active_appearance_item =
+3
View File
@@ -473,6 +473,9 @@ impl Session {
for (uid, doc, selection, interaction, history) in snapshot {
// A document the command closed stays closed.
let Some(st) = self.docs.iter_mut().find(|d| d.uid == uid) else { continue };
if !std::sync::Arc::ptr_eq(&st.doc, &doc) {
st.rollbacks += 1;
}
st.doc = doc;
st.selection = selection;
st.interaction = interaction;
+70 -7
View File
@@ -134,11 +134,60 @@ fn draw_behind_and_inside() {
assert_eq!(d.parent_of(NodeId(a)), Some(g));
// A second shape goes into the same clip group.
s.execute("shape.ellipse", &json!({"x": 0, "y": 0, "width": 10, "height": 10})).unwrap();
assert_eq!(s.doc().unwrap().doc.node(g).unwrap().children().unwrap().len(), 4);
assert_eq!(s.doc().unwrap().doc.node(g).unwrap().children().unwrap().len(), 3);
s.execute("view.drawMode", &json!({"mode": "normal"})).unwrap();
assert!(s.draw_inside.is_none());
}
/// #8753: Draw Inside makes the object drawn into the clipping path, keeping its fill and stroke,
/// so its centred stroke stays whole and paints over the art drawn inside it. It used to clip by an
/// unpainted copy of the object, the object itself becoming clipped art under the new art: the
/// outer half of the stroke was cut off and the new art covered the inner half.
#[test]
fn draw_inside_keeps_the_objects_stroke_whole_and_over_the_new_art() {
use vectorcraft_geom::Affine;
use vectorcraft_render::{RenderOptions, Renderer};
let mut s = Session::new();
s.execute("file.new", &json!({"width": 240, "height": 240})).unwrap();
s.execute("paint.setFill", &json!({"color": "#ebb471"})).unwrap();
s.execute("paint.setStroke", &json!({"color": "#a8622a"})).unwrap();
s.execute("stroke.set", &json!({"weight": 12})).unwrap();
let a = s.execute("shape.rectangle", &json!({"x": 50, "y": 50, "width": 140, "height": 140})).unwrap()["id"].as_u64().unwrap();
let look = s.doc().unwrap().doc.node(NodeId(a)).unwrap().appearance.clone();
s.execute("select.set", &json!({"ids": [a]})).unwrap();
s.execute("view.drawMode", &json!({"mode": "inside"})).unwrap();
s.execute("select.none", &json!({})).unwrap();
s.execute("paint.setFill", &json!({"color": "#c89a60"})).unwrap();
s.execute("paint.setStroke", &json!({"none": true})).unwrap();
let b = s.execute("shape.rectangle", &json!({"x": 20, "y": 110, "width": 220, "height": 110})).unwrap()["id"].as_u64().unwrap();
let d = &s.doc().unwrap().doc;
// The clip group holds the object, its clipping path with its appearance, then the new art.
let g = d.parent_of(NodeId(a)).unwrap();
let children: Vec<u64> = d.node(g).unwrap().children().unwrap().iter().map(|n| n.id.0).collect();
assert_eq!(children, [a, b], "no unpainted copy of the object");
let target = d.node(NodeId(a)).unwrap();
assert!(matches!(target.kind, NodeKind::Path { clipping: true, .. }));
assert_eq!(target.appearance, look, "the object keeps its fill and stroke");
let opts = RenderOptions { background: Some([255, 255, 255, 255]), ..Default::default() };
let img = Renderer::new().render(d, 240, 240, Affine::IDENTITY, &opts);
let rgb = |x: u32, y: u32| {
let p = img.pixel(x, y);
[p[0], p[1], p[2]]
};
let (stroke, fill, new) = ([0xa8, 0x62, 0x2a], [0xeb, 0xb4, 0x71], [0xc8, 0x9a, 0x60]);
// The stroke runs 6 pt either side of the edge: its outer half is not clipped away.
assert_eq!(rgb(120, 46), stroke, "outer half of the top stroke");
assert_eq!(rgb(120, 53), stroke, "inner half of the top stroke");
assert_eq!(rgb(120, 80), fill);
// Where the new art crosses the edge, the stroke paints over it, both halves.
for (x, y) in [(46, 150), (53, 150), (120, 186), (120, 193), (186, 150), (193, 150)] {
assert_eq!(rgb(x, y), stroke, "stroke at ({x}, {y})");
}
// The new art shows inside the object only.
assert_eq!(rgb(120, 150), new);
assert_eq!(rgb(30, 150), [255, 255, 255]);
}
/// In Draw Inside, a double-click with a selection tool outside the object being drawn into sets
/// the drawing mode to Draw Normal, and the tool still takes the double-click. Inside the object's
/// bounds, grown by the selection tolerance, and with other tools, Draw Inside stays on.
@@ -181,11 +230,11 @@ fn double_clicking_outside_the_draw_inside_object_returns_to_draw_normal() {
/// the object drawn into, as drawn art goes, each paste one undo step; the first one makes the
/// clip group and the next ones add to it, with Paste Remembers Layers on and with the object
/// isolated by a double-click too. Paste in Front and Paste in Back keep their places.
/// Draw Inside a compound path: the clip group's mask is a copy whose subpaths have ids of their
/// own, so no two objects share an id. An artboard copied without art, pasted on all artboards in
/// Draw Inside a compound path: it becomes the clip group's clipping path, its first child, and no
/// two objects share an id. An artboard copied without art, pasted on all artboards in
/// Draw Inside, makes no clip group.
#[test]
fn draw_inside_a_compound_path_gives_its_mask_ids_of_its_own() {
fn draw_inside_a_compound_path_makes_it_the_clipping_path() {
let mut s = Session::new();
s.execute("file.new", &json!({"width": 400, "height": 300, "artboards": 2})).unwrap();
let a = s.execute("shape.rectangle", &json!({"x": 100, "y": 100, "width": 100, "height": 100})).unwrap()["id"].as_u64().unwrap();
@@ -202,7 +251,22 @@ fn draw_inside_a_compound_path_gives_its_mask_ids_of_its_own() {
ids.sort_unstable();
ids.dedup();
assert_eq!(ids.len(), all, "an id is used twice");
assert_eq!(d.node(d.parent_of(NodeId(c)).unwrap()).unwrap().kind_label(), "Clip Group");
let g = d.node(d.parent_of(NodeId(c)).unwrap()).unwrap();
assert_eq!(g.kind_label(), "Clip Group");
assert_eq!(g.children().unwrap().first().map(|n| n.id.0), Some(c), "the compound path is the clipping path");
// Type too: it is the clipping path, keeping its paint, and drawing inside it again adds to
// the same clip group.
s.execute("view.drawMode", &json!({"mode": "normal"})).unwrap();
let t = s.execute("text.create", &json!({"x": 100, "y": 250, "text": "Type", "size": 40})).unwrap()["id"].as_u64().unwrap();
let look = s.doc().unwrap().doc.node(NodeId(t)).unwrap().clone();
s.execute("select.set", &json!({"ids": [t]})).unwrap();
s.execute("view.drawMode", &json!({"mode": "inside"})).unwrap();
s.execute("shape.ellipse", &json!({"x": 100, "y": 220, "width": 30, "height": 30})).unwrap();
s.execute("shape.ellipse", &json!({"x": 110, "y": 220, "width": 30, "height": 30})).unwrap();
let d = &s.doc().unwrap().doc;
let g = d.node(d.parent_of(NodeId(t)).unwrap()).unwrap();
assert_eq!((g.kind_label(), g.children().unwrap().len()), ("Clip Group", 3));
assert_eq!(**g.children().unwrap().first().unwrap(), look, "the type is the clipping path, as it was");
// An artboard alone on the clipboard: Paste on All Artboards adds nothing inside the object.
let mut s = Session::new();
s.execute("file.new", &json!({"width": 400, "height": 300, "artboards": 2})).unwrap();
@@ -242,8 +306,7 @@ fn pasting_in_draw_inside_puts_the_copies_inside_the_object() {
let all = pasted(s.execute("edit.pasteOnAllArtboards", &json!({})).unwrap());
assert_eq!(all.len(), 2);
let children: Vec<u64> = s.doc().unwrap().doc.node(g).unwrap().children().unwrap().iter().map(|n| n.id.0).collect();
assert_eq!(children.len(), 6, "{children:?}");
assert_eq!(children[1..], [a, ids[0], in_place[0], all[0], all[1]]);
assert_eq!(children, [a, ids[0], in_place[0], all[0], all[1]]);
// Paste Remembers Layers doesn't take the copy out of the object.
s.execute("layer.pasteRemembersLayers", &json!({"on": true})).unwrap();
let remembered = pasted(s.execute("edit.paste", &json!({})).unwrap());
+184
View File
@@ -829,6 +829,190 @@ fn canceling_undo_groups_in_two_documents_drops_the_edits_of_both_from_the_journ
assert_eq!(ids.last(), Some(&"edit.undoGroup.end"));
}
/// Exit Symbol Editing Mode with nothing changed takes back the entering step, which puts back an older snapshot, so
/// it advances `rollbacks`; leaving after an edit adds a step and leaves it as it is.
#[test]
fn leaving_symbol_editing_advances_rollbacks_only_when_taking_back_the_entering_step() {
let mut s = Session::new();
s.execute("file.new", &json!({"width": 400, "height": 300})).unwrap();
s.execute("shape.rectangle", &rect_step(10)["params"]).unwrap();
s.execute("symbol.new", &json!({"name": "Box"})).unwrap();
for edited in [false, true] {
let rollbacks = s.doc().unwrap().rollbacks;
s.execute("symbol.edit", &json!({})).unwrap();
if edited {
s.execute("object.move", &json!({"dx": 5, "dy": 0})).unwrap();
}
s.execute("symbol.exitEditing", &json!({})).unwrap();
if edited {
assert_eq!(s.doc().unwrap().rollbacks, rollbacks, "leaving after an edit keeps the rollback count");
} else {
assert!(s.doc().unwrap().rollbacks > rollbacks, "taking back the entering step advances the rollback count");
}
}
}
/// Discard Empty Type advances `rollbacks` when it takes back the step that made the empty text, which frees the
/// text's node ID; when it removes the text as a new step instead, it leaves the count as it is.
#[test]
fn discard_empty_type_advances_rollbacks_only_when_taking_back_the_step_that_made_the_text() {
let mut s = Session::new();
s.execute("file.new", &json!({"width": 400, "height": 300})).unwrap();
let made = s.execute("text.create", &json!({"x": 10, "y": 40, "text": ""})).unwrap();
let rollbacks = s.doc().unwrap().rollbacks;
s.execute("text.discardEmpty", &json!({"id": made["id"]})).unwrap();
assert!(s.doc().unwrap().rollbacks > rollbacks, "taking back the step that made the text advances the rollback count");
let kept = s.execute("text.create", &json!({"x": 10, "y": 80, "text": ""})).unwrap();
s.execute("shape.rectangle", &rect_step(10)["params"]).unwrap();
let rollbacks = s.doc().unwrap().rollbacks;
s.execute("text.discardEmpty", &json!({"id": kept["id"]})).unwrap();
assert!(s.doc().unwrap().doc.node(NodeId(kept["id"].as_u64().unwrap())).is_none(), "the empty text is removed");
assert_eq!(s.doc().unwrap().rollbacks, rollbacks, "removing the text as a new step keeps the rollback count");
}
/// A command that panics after changing a document advances that document's `rollbacks` when the document is put
/// back; one that panics before changing it leaves the count as it is.
#[test]
fn a_panicking_command_advances_rollbacks_only_when_it_changed_the_document() {
let mut s = Session::new();
s.execute("file.new", &json!({"width": 400, "height": 300})).unwrap();
let a = NodeId(s.execute("shape.rectangle", &rect_step(10)["params"]).unwrap()["id"].as_u64().unwrap());
for changed in [false, true] {
let rollbacks = s.doc().unwrap().rollbacks;
let r = s.run_guarded("test.panic", |s| {
if changed {
let st = s.doc_mut()?;
std::sync::Arc::make_mut(&mut st.doc).remove(a)?;
}
s.run_nested(|_| panic!("boom"))
});
assert!(matches!(r, Err(EngineError::Internal { .. })), "the panic is returned as an internal error");
if changed {
assert!(s.doc().unwrap().rollbacks > rollbacks, "putting back the changed document advances the rollback count");
} else {
assert_eq!(s.doc().unwrap().rollbacks, rollbacks, "a panic before any change keeps the rollback count");
}
}
}
/// Canceling an interaction whose preview changed the document advances `rollbacks`; canceling one that changed
/// nothing leaves it as it is.
#[test]
fn interaction_cancellation_advances_rollbacks_only_when_restoring() {
let mut s = Session::new();
s.execute("file.new", &json!({"width": 400, "height": 300})).unwrap();
for previewed in [true, false] {
let rollbacks = s.doc().unwrap().rollbacks;
s.begin_interaction("Rectangle").unwrap();
if previewed {
s.preview("shape.rectangle", &rect_step(10)["params"]).unwrap();
}
s.cancel_interaction().unwrap();
if previewed {
assert!(s.doc().unwrap().rollbacks > rollbacks, "a canceled preview advances the rollback count");
} else {
assert_eq!(s.doc().unwrap().rollbacks, rollbacks, "a cancel with no preview keeps the rollback count");
}
}
}
/// A preview advances `rollbacks` when it discards earlier art and frees its node IDs, whether it
/// succeeds or fails. A failed preview also advances it when it discards an earlier document change
/// without freeing IDs. A successful preview that draws the earlier art again also advances the count.
#[test]
fn a_preview_that_discards_earlier_art_and_frees_its_ids_advances_rollbacks() {
let mut s = Session::new();
s.execute("file.new", &json!({"width": 400, "height": 300})).unwrap();
let rollbacks = s.doc().unwrap().rollbacks;
s.begin_interaction("Rectangle").unwrap();
s.preview("shape.rectangle", &rect_step(10)["params"]).unwrap();
assert!(s.preview("unknown.command", &json!({})).is_err(), "an unknown preview command returns an error");
assert!(s.doc().unwrap().rollbacks > rollbacks, "a failed preview after a drawn preview advances the rollback count");
s.cancel_interaction().unwrap();
let rollbacks = s.doc().unwrap().rollbacks;
s.begin_interaction("Rectangle").unwrap();
assert!(s.preview("unknown.command", &json!({})).is_err(), "an unknown preview command returns an error");
assert_eq!(s.doc().unwrap().rollbacks, rollbacks, "a failed preview with nothing previewed keeps the rollback count");
s.cancel_interaction().unwrap();
let rollbacks = s.doc().unwrap().rollbacks;
s.begin_interaction("Rectangle").unwrap();
s.preview("shape.rectangle", &rect_step(10)["params"]).unwrap();
s.preview("shape.rectangle", &rect_step(30)["params"]).unwrap();
assert_eq!(s.doc().unwrap().rollbacks, rollbacks + 1, "a preview that replaces earlier drawn art advances the rollback count");
s.cancel_interaction().unwrap();
let rollbacks = s.doc().unwrap().rollbacks;
let starting_doc = s.doc().unwrap().doc.clone();
s.begin_interaction("Rectangle").unwrap();
s.preview("shape.rectangle", &rect_step(10)["params"]).unwrap();
s.preview("select.set", &json!({"ids": []})).unwrap();
assert!(std::sync::Arc::ptr_eq(&s.doc().unwrap().doc, &starting_doc), "a selection-only preview leaves the starting document Arc");
assert_eq!(
s.doc().unwrap().rollbacks,
rollbacks + 1,
"a preview that leaves the starting document after a drawn preview advances the rollback count"
);
s.cancel_interaction().unwrap();
let kept = s.execute("shape.rectangle", &rect_step(5)["params"]).unwrap()["id"].clone();
let rollbacks = s.doc().unwrap().rollbacks;
let starting_doc = s.doc().unwrap().doc.clone();
s.begin_interaction("Rectangle").unwrap();
s.preview("shape.rectangle", &rect_step(10)["params"]).unwrap();
let steps = json!({"commands": [
{"command": "select.set", "params": {"ids": [kept]}},
{"command": "object.move", "params": {"dx": 5, "dy": 0}}
]});
s.preview("command.batch", &steps).unwrap();
assert!(!std::sync::Arc::ptr_eq(&s.doc().unwrap().doc, &starting_doc), "the move changes the document");
assert_eq!(s.doc().unwrap().rollbacks, rollbacks + 1, "a preview that moves art instead of drawing it advances the rollback count");
s.cancel_interaction().unwrap();
}
/// A command run during a tool interaction sets the preview aside and can reuse the node IDs the
/// preview allocated, so it advances `rollbacks`; with no IDs allocated by the preview it does not.
#[test]
fn a_command_outside_a_tool_interaction_advances_rollbacks_only_when_the_preview_allocated_ids() {
let mut s = Session::new();
s.execute("file.new", &json!({"width": 400, "height": 300})).unwrap();
s.begin_interaction("Rectangle").unwrap();
// A tool interaction routes the command through outside_interaction.
s.active_mut().unwrap().interaction.as_mut().unwrap().tool = true;
let preview_id = s.preview("shape.rectangle", &rect_step(10)["params"]).unwrap()["id"].clone();
let rollbacks = s.doc().unwrap().rollbacks;
let command_id = s.execute("shape.rectangle", &rect_step(30)["params"]).unwrap()["id"].clone();
assert_eq!(command_id, preview_id, "a command outside a tool interaction reuses the rectangle preview's node ID");
assert_eq!(s.doc().unwrap().rollbacks, rollbacks + 1, "setting aside a preview that allocated IDs advances the rollback count");
s.cancel_interaction().unwrap();
for previewed in [true, false] {
s.begin_interaction("Rectangle").unwrap();
s.active_mut().unwrap().interaction.as_mut().unwrap().tool = true;
if previewed {
s.preview("select.none", &json!({})).unwrap();
}
let rollbacks = s.doc().unwrap().rollbacks;
s.execute("shape.rectangle", &rect_step(50)["params"]).unwrap();
assert_eq!(s.doc().unwrap().rollbacks, rollbacks, "a command with no preview IDs keeps the rollback count, previewed: {previewed}");
s.cancel_interaction().unwrap();
}
}
/// A preview that activates another document advances rollbacks in the document whose art it discards.
#[test]
fn a_preview_that_activates_another_document_advances_only_the_source_rollbacks() {
let mut s = Session::new();
s.execute("file.new", &json!({"width": 400, "height": 300})).unwrap();
s.execute("file.new", &json!({"width": 400, "height": 300})).unwrap();
s.execute("document.activate", &json!({"index": 0})).unwrap();
let source_rollbacks = s.documents()[0].rollbacks;
let destination_rollbacks = s.documents()[1].rollbacks;
s.begin_interaction("Rectangle").unwrap();
s.preview("shape.rectangle", &rect_step(10)["params"]).unwrap();
s.preview("document.activate", &json!({"index": 1})).unwrap();
assert_eq!(s.active_index(), Some(1), "the activation preview makes the destination document active");
assert!(s.documents()[0].rollbacks > source_rollbacks, "discarding the rectangle preview advances the source document's rollback count");
assert_eq!(s.documents()[1].rollbacks, destination_rollbacks, "the activation preview keeps the destination document's rollback count unchanged");
}
/// A cancel drops only the canceled groups' own entries from the journal: an edit made in another
/// document while a group was open stays in that document and in the journal.
#[test]
+31 -6
View File
@@ -4275,19 +4275,44 @@ fn convert_point_area_roundtrip() {
assert_eq!(tt.plain_text(), "Some words");
}
/// Convert To Area Type with no point type selected, and Convert To Point Type with no area type
/// selected, record no undo step and reply with the objects. With point type and area type
/// selected, Convert To Area Type converts the point type in one undo step, and Convert To Point
/// Type then converts both in another.
#[test]
fn converting_type_to_the_kind_it_is_records_no_undo_step() {
fn type_conversion_availability_requires_its_source_kind() {
let mut s = session();
let point = text(&mut s, "Point");
let area = id_of(&s.execute("text.create", &json!({"x": 0, "y": 100, "text": "Area", "area": {"width": 100, "height": 50}})).unwrap());
let rectangle = rect(&mut s, 200.0, 50.0, 20.0, 20.0);
let to_area = find_command("type.convertToAreaType").unwrap();
let to_point = find_command("type.convertToPointType").unwrap();
for (selection, can_convert_to_area, can_convert_to_point) in
[(&[point][..], true, false), (&[area][..], false, true), (&[rectangle][..], false, false), (&[area, point][..], true, true)]
{
sel(&mut s, selection);
for (spec, can_convert) in [(to_area, can_convert_to_area), (to_point, can_convert_to_point)] {
let info = spec.info(&s);
assert_eq!(info.enabled, can_convert, "{} on {selection:?}", info.id);
assert_eq!(info.disabled_reason.is_some(), !can_convert, "{} on {selection:?}", info.id);
}
}
sel(&mut s, &[rectangle, point]);
let group = id_of(&s.execute("object.group", &json!({})).unwrap());
sel(&mut s, &[group]);
assert!(to_area.info(&s).enabled);
assert!(!to_point.info(&s).enabled);
}
/// An inapplicable conversion is disabled and leaves undo history intact. With point type and
/// area type selected, Convert To Area Type converts the point type in one undo step, and
/// Convert To Point Type then converts both in another.
#[test]
fn inapplicable_type_conversions_record_no_undo_step() {
let mut s = session();
let p = text(&mut s, "Point");
let a = id_of(&s.execute("text.create", &json!({"x": 0, "y": 100, "text": "Area", "area": {"width": 100, "height": 50}})).unwrap());
for (c, id) in [("type.convertToAreaType", a), ("type.convertToPointType", p)] {
select_with_a_step_to_redo(&mut s, &[id]);
let before = history(&s);
assert_eq!(s.execute(c, &json!({})).unwrap(), json!({"ids": [id.0]}), "{c}");
assert!(matches!(s.execute(c, &json!({})), Err(EngineError::Disabled(..))), "{c}");
assert_eq!(history(&s), before, "{c}");
}
for c in ["type.convertToAreaType", "type.convertToPointType"] {
+97
View File
@@ -265,3 +265,100 @@ fn a_script_cannot_install_a_pack() {
assert!(installed_locales(&mut s).is_empty(), "nothing installed");
assert_eq!(s.execute("proof.installPack", &json!({"locale": "nl"})).unwrap()["installed"], true, "outside a script it installs");
}
/// A backend that only lists `packs` (the index fetched last), for what the missing-pack bar offers.
struct Listing {
dir: PathBuf,
packs: Vec<Pack>,
}
impl Backend for Listing {
fn packs_dir(&self) -> PathBuf {
self.dir.clone()
}
fn downloads_on(&self) -> bool {
false
}
fn cached_index(&self) -> Vec<Pack> {
self.packs.clone()
}
fn fetch_index(&self, _: &Cancel) -> std::result::Result<Vec<Pack>, String> {
Err("downloading is off".into())
}
fn install(&self, _: &str, _: &Cancel, _: &mut dyn FnMut(u64, u64)) -> std::result::Result<(), String> {
Err("downloading is off".into())
}
fn remove(&self, _: &str) -> std::result::Result<(), String> {
Ok(())
}
}
fn pack(locale: &str) -> Pack {
Pack { locale: locale.into(), name: locale.into(), size: 1, licence: "MIT".into(), class: "Embeddable".into(), spelling: true, hyphenation: true }
}
/// `proof.packs`'s `missing`, as (lang, locale).
fn missing(s: &mut Session) -> Vec<(String, Value)> {
let r = s.execute("proof.packs", &json!({})).unwrap();
r["missing"].as_array().unwrap().iter().map(|m| (m["lang"].as_str().unwrap().to_string(), m["locale"].clone())).collect()
}
/// The missing-pack bar offers the languages of the document's type that have no dictionary: a
/// pack the index lists, or, before the index was ever fetched, the language alone; never one the
/// fetched index has no pack for, nor English.
#[test]
fn the_languages_with_no_dictionary_are_offered_their_pack() {
let _turn = packs_lock();
let root = folder("missing");
let _reset = Reset(root.clone());
let mut s = Session::new();
s.execute("file.new", &json!({"width": 400, "height": 400})).unwrap();
s.execute("text.create", &json!({"x": 10, "y": 50, "text": "The house"})).unwrap();
// Konkani: no system has a Hunspell dictionary for it, so the check can't depend on the machine.
let id = s.execute("text.create", &json!({"x": 10, "y": 90, "text": "घर"})).unwrap()["id"].clone();
s.execute("text.setFormat", &json!({"ids": [id], "language": "Konkani"})).unwrap();
assert!(missing(&mut s).is_empty(), "no store, nothing to offer");
let listing = |packs: Vec<Pack>| Some(Arc::new(Listing { dir: root.clone(), packs }) as Arc<dyn Backend>);
packs::set_backend(listing(vec![]));
assert_eq!(missing(&mut s), [("kok".to_string(), Value::Null)], "before the first fetch, the language alone");
packs::set_backend(listing(vec![pack("nl"), pack("kok")]));
assert_eq!(missing(&mut s), [("kok".to_string(), json!("kok"))], "the pack the index lists");
packs::set_backend(listing(vec![pack("nl")]));
assert!(missing(&mut s).is_empty(), "the index has no pack for it");
}
/// A pack is found for a tag's region and variant forms (`sr-Latn-RS` is `sr-latn`'s, `nl-BE`
/// is `nl`'s), not for English.
#[test]
fn a_tag_finds_its_pack_without_its_region() {
let index = [pack("nl"), pack("sr-latn"), pack("ca-valencia"), pack("pt-pt")];
let found = |tag: &str| packs::pack_for_tag(tag, &index).map(|p| p.locale.clone());
assert_eq!(found("nl-BE").as_deref(), Some("nl"));
assert_eq!(found("sr-Latn-RS").as_deref(), Some("sr-latn"));
assert_eq!(found("ca-ES-valencia").as_deref(), Some("ca-valencia"));
assert_eq!(found("pt_PT").as_deref(), Some("pt-pt"));
assert_eq!(found("en-NL"), None);
assert_eq!(found("fy"), None);
}
/// Downloading is turned on in the shared store only by the app for the person's click
/// (`packs::enable_downloads`); a backend that can't (a stand-in) refuses.
#[test]
fn the_persons_click_turns_downloading_on_in_the_shared_store() {
let _turn = packs_lock();
let root = folder("consent");
let _reset = Reset(root.clone());
let mut s = dutch_session();
assert!(packs::enable_downloads().is_err(), "no store");
packs::set_backend(Some(Arc::new(Listing { dir: root.clone(), packs: vec![] })));
assert!(packs::enable_downloads().is_err(), "a backend that can't turn it on");
packs::set_backend(Some(packs::font_store_in(root.clone())));
assert_eq!(s.execute("proof.packs", &json!({})).unwrap()["downloads"], false);
packs::enable_downloads().unwrap();
assert_eq!(s.execute("proof.packs", &json!({})).unwrap()["downloads"], true, "the store the agent opened sees it on");
}
+47
View File
@@ -8131,6 +8131,19 @@ fn install_select_all_then_remove(s: &mut Session, id: &str) {
run(s, "plugin.install", json!({"dataBase64": vectorcraft_format::base64_encode(&wasm), "grant": grant, "replace": true}));
}
/// Installs a filter `id` that calls `shape.rectangle` and then returns no objects.
fn install_draw_rectangle_then_remove(s: &mut Session, id: &str) {
let grant = json!(["doc.read", "doc.write", "commands"]);
let manifest =
format!(r#"{{"id":"{id}","name":"Test {id}","kind":"filter","api":2,"permissions":{grant},"commandAllowlist":["shape.rectangle"]}}"#);
let imports = r#"(import "env" "vc_call" (func $vc_call (param i32 i32 i32 i32) (result i32)))
(data (i32.const 0x2000) "shape.rectangle")
(data (i32.const 0x2100) "{\22x\22:0,\22y\22:0,\22width\22:5,\22height\22:5}")"#;
let first = "(drop (call $vc_call (i32.const 0x2000) (i32.const 15) (i32.const 0x2100) (i32.const 34)))";
let wasm = wat::parse_str(tpl::with_imports(&manifest, imports, first, r#"{"objects":[]}"#)).unwrap();
run(s, "plugin.install", json!({"dataBase64": vectorcraft_format::base64_encode(&wasm), "grant": grant, "replace": true}));
}
/// Runs the job of a run that [`FilterRun::begin_calls`] started as the web build's plug-in worker
/// does, making each command call in `s` → its output.
fn run_job_away(s: &mut Session, job: &cmd::plugin::FilterJob) -> Vec<u8> {
@@ -8201,6 +8214,40 @@ fn a_calling_run_made_away_from_the_session_that_ends_changes_nothing() {
run(&mut s, "plugin.remove", json!({"id": id}));
}
/// A run made away from the session that ends after its calls changed the document advances `rollbacks`.
/// A run whose calls only changed the selection or that ends before any call keeps the rollback count.
#[test]
fn an_ended_calling_run_advances_rollbacks_only_when_its_calls_changed_the_document() {
use cmd::plugin::FilterRun;
let id = "test.engine.callsawayrollback";
let draw_id = "test.engine.callsawayrollbackdraw";
let mut s = session();
install_select_all_then_remove(&mut s, id);
install_draw_rectangle_then_remove(&mut s, draw_id);
let (a, _) = (rect(&mut s, 10.0, "#ff0000"), rect(&mut s, 40.0, "#00ff00"));
for (plugin_id, called, changed_document) in [(draw_id, true, true), (id, true, false), (id, false, false)] {
run(&mut s, "select.set", json!({"ids": [a.0]}));
let rollbacks = s.doc().unwrap().rollbacks;
let job = FilterRun::begin_calls(&mut s, "plugin.run", &json!({"id": plugin_id})).unwrap();
let doc = s.doc().unwrap().doc.clone();
if called {
run_job_away(&mut s, &job);
assert_eq!(!std::sync::Arc::ptr_eq(&doc, &s.doc().unwrap().doc), changed_document, "the calls change only the intended state");
assert_ne!(s.doc().unwrap().selection.objects, vec![a], "the calls change the selection");
}
s.end_plugin_calls();
if changed_document {
assert!(s.doc().unwrap().rollbacks > rollbacks, "an ended run whose calls changed the document advances the rollback count");
} else if called {
assert_eq!(s.doc().unwrap().rollbacks, rollbacks, "an ended run whose calls only changed the selection keeps the rollback count");
} else {
assert_eq!(s.doc().unwrap().rollbacks, rollbacks, "an ended run with no calls keeps the rollback count");
}
}
run(&mut s, "plugin.remove", json!({"id": draw_id}));
run(&mut s, "plugin.remove", json!({"id": id}));
}
/// An output handed in for a run that holds the documents is dropped when that run ends: a later
/// run with the same input and params is not given it, and `plugin.run` without its own output is
/// refused.
+5
View File
@@ -181,6 +181,7 @@ impl VectorcraftApp {
multi_color: None,
global_edit_count: None,
shape_angle: None,
shape_edit_target: None,
radius_corners: None,
selected_rectangles: None,
trace_presets: None,
@@ -253,6 +254,8 @@ impl VectorcraftApp {
trace_runs: Default::default(),
concept_runs: Default::default(),
retype_runs: Default::default(),
#[cfg(not(target_arch = "wasm32"))]
language_packs: Default::default(),
recovery: Default::default(),
closing: None,
prefs: None,
@@ -697,6 +700,7 @@ impl VectorcraftApp {
if self.session.poll_language_packs() {
ctx.request_repaint_after(std::time::Duration::from_millis(250));
}
crate::language_packs::tick(self, ctx);
if self.session.plugins_loading() {
if self.session.poll_plugin_loads() {
ctx.request_repaint_after(std::time::Duration::from_millis(50));
@@ -769,6 +773,7 @@ impl VectorcraftApp {
&& let Some(view) = app.canvas_view()
{
chrome::isolation_bar(app, ui, view.rect);
crate::language_packs::bar(app, ui, view.rect);
}
});
}
+2
View File
@@ -160,6 +160,8 @@ pub struct CanvasCache {
pub(crate) global_edit_count: Option<(crate::panels::properties::GlobalEditKey, usize)>,
/// The selected live shape's angle, for (document uid, revision, kind of shape).
pub shape_angle: Option<ShapeAngleCache>,
/// The shape-wide edit target, for (document uid, revision).
pub(crate) shape_edit_target: Option<((u64, u64), egui::IdSalt)>,
/// The corners a live shape's Corner Radius field sets, as one hash, for (document uid,
/// File › Revert count, revision).
pub(crate) radius_corners: Option<((u64, u64, u64), u64)>,
+57
View File
@@ -0,0 +1,57 @@
//! Language packs in the window (#4936): Preferences › Language Packs lists the packs that spell-check and
//! hyphenate languages other than English, with Install and Remove, and the missing-pack bar over the canvas offers
//! the pack for a language the document's type is in. The engine does the work ([`vectorcraft_engine::packs`]):
//! installs run on its thread, and the buttons go through `proof.installPack`, `proof.removePack` and
//! `proof.packs {refresh}`, as an agent's would.
//!
//! The one step no command takes is turning on the font store's downloading (RFC-0011): the person's own click on
//! Install, Get Language Pack or Refresh List is their consent, and it turns downloading on for every Craft app. A
//! click the control channel injected never does; an agent can install once the person has turned it on.
//!
//! The web build has no font store yet (storytold/craft-libs#745): the page says so and the bar never shows.
#[cfg(target_arch = "wasm32")]
use craft::theme::variant::Tone;
use craft::ui::contract::{Show as _, ShowContainer as _};
use craft::ui::display::Text;
use craft::ui::layout_components::Stack;
#[cfg(target_arch = "wasm32")]
use craft::ui::notices::Notice;
use egui::Ui;
use crate::VectorcraftApp;
#[cfg(not(target_arch = "wasm32"))]
mod desktop;
#[cfg(not(target_arch = "wasm32"))]
pub use desktop::Runtime;
#[cfg(not(target_arch = "wasm32"))]
pub(crate) use desktop::{bar, tick};
/// The Preferences page's id (its English title), beside the categories of the engine's preference table.
pub const PAGE: &str = "Language Packs";
/// Once a frame: nothing on the web.
#[cfg(target_arch = "wasm32")]
pub(crate) fn tick(_app: &mut VectorcraftApp, _ctx: &egui::Context) {}
/// The missing-pack bar: never on the web, which can't install packs.
#[cfg(target_arch = "wasm32")]
pub(crate) fn bar(_app: &mut VectorcraftApp, _ui: &mut Ui, _area: egui::Rect) {}
/// Preferences › Language Packs: what packs are, then (on the desktop) whether downloading is on, the installed packs
/// with Remove, and the packs of the list with Install, each with its progress or its last failure.
pub(crate) fn page(app: &mut VectorcraftApp, ui: &mut Ui) {
Stack::new().show(ui, |ui, _| {
Text::new(tl!("Language packs add spelling and hyphenation for languages other than English. They are shared with the other Craft apps."))
.show(ui);
#[cfg(target_arch = "wasm32")]
{
let _ = &app;
Notice::new(Tone::Info, tl!("Language packs can't be installed in the browser yet: only English is spell-checked here.")).show(ui);
}
#[cfg(not(target_arch = "wasm32"))]
desktop::page(app, ui);
});
}
@@ -0,0 +1,425 @@
//! The desktop's Language packs: the Preferences page's list and the missing-pack bar, over the engine's packs
//! ([`vectorcraft_engine::packs`]), which the web build doesn't have.
use std::collections::{BTreeMap, BTreeSet};
use craft::theme::variant::Tone;
use craft::ui::buttons::Button;
use craft::ui::contract::{Politeness, Props as _, Show as _, ShowContainer as _};
use craft::ui::display::{Progress, Text};
use craft::ui::layout_components::Row;
use craft::ui::notices::Notice;
use craft::ui::patterns::language_packs::{
self, BarOffer, BarState, Consent, LanguagePackWords, MissingPackBar, injected, shown, shown_error, size_text,
};
use craft::ui::runtime::env::Env;
use egui::Ui;
use serde_json::json;
use vectorcraft_engine::packs::{self, Missing, Pack};
use crate::VectorcraftApp;
/// Most characters of a language's name shown (an index may name it at any length).
const MAX_NAME: usize = 40;
/// How long the bar keeps what it worked out while the document is being edited.
const MISSING_REFRESH_SECS: f64 = 1.0;
/// The window's pack state.
#[derive(Default)]
pub struct Runtime {
/// Failures of the window's own (turning downloading on, a command it ran), by locale or language tag (`""`:
/// the list), shown until the next try. The engine keeps the installs' own.
errors: BTreeMap<String, String>,
/// The keys of `errors` that say only the person can turn downloading on: dropped once it is on.
refused: BTreeSet<String>,
/// (document, pack locale or language tag) pairs whose bar was closed.
dismissed: BTreeSet<(u64, String)>,
/// The language tag whose bar asked for the list: its pack installs once the list arrives.
wanted: Option<String>,
/// The installs running when last looked at, to announce each one's end.
running: BTreeSet<String>,
/// What the bar offers for the front document, what it was worked out from, and when.
missing: Option<(MissingKey, f64, Vec<Missing>)>,
/// The index fetched last, and what it was read for (the list is read from disk, so not every frame).
index: Option<(IndexKey, Vec<Pack>)>,
}
impl Runtime {
/// Keeps `message` as the failure for `key`, in place of a refusal it had: downloading coming on drops only
/// refusals, so this one stays.
fn fail(&mut self, key: impl Into<String>, message: String) {
let key = key.into();
self.refused.remove(&key);
self.errors.insert(key, message);
}
/// Forgets the failure (or refusal) for `key`: a new try is starting.
fn clear(&mut self, key: &str) {
self.refused.remove(key);
self.errors.remove(key);
}
}
#[derive(Clone, Copy, PartialEq, Eq)]
struct MissingKey {
document: u64,
revision: u64,
/// The installed packs changed.
generation: u64,
/// A fetch of the list started or ended.
refreshing: bool,
/// A fetch of the list ended (one can start and end between two frames).
index: u64,
}
/// Whether a fetch of the list was running, the fetches that ended, and the installed packs' generation.
type IndexKey = (bool, u64, u64);
/// A language as the window names it: the interface's name for a document language (`Hindi`), with the pack's own
/// name after it when that differs (`Hindi (हिन्दी)`); the pack's own name alone for a language the documents'
/// list doesn't have; the tag when there is neither.
pub(crate) fn language_name(tag: &str, own: Option<&str>) -> String {
let own = own.map(|o| shown(o, MAX_NAME)).filter(|o| !o.is_empty());
let primary = |t: &str| t.split(['-', '_']).next().unwrap_or_default().to_ascii_lowercase();
let languages = vectorcraft_doc::setup::LANGUAGES;
let known = languages
.iter()
.find(|(_, t, _)| t.eq_ignore_ascii_case(tag))
.or_else(|| languages.iter().find(|(_, t, _)| primary(t) == primary(tag)))
.map(|(name, _, _)| tl!(name).to_string());
match (known, own) {
(Some(k), Some(o)) if k != o => format!("{k} ({o})"),
(Some(k), _) => k,
(None, Some(o)) => o,
(None, None) => shown(tag, MAX_NAME),
}
}
/// What a pack provides, as the list says it.
fn provides(p: &Pack) -> String {
match (p.spelling, p.hyphenation) {
(true, true) => tl!("Spelling and hyphenation").to_string(),
(true, false) => tl!("Spelling").to_string(),
(false, true) => tl!("Hyphenation").to_string(),
(false, false) => String::new(),
}
}
/// Once a frame: announces the installs that ended, and installs the pack the bar asked the list for once it
/// arrives.
pub(crate) fn tick(app: &mut VectorcraftApp, ctx: &egui::Context) {
if !app.language_packs.refused.is_empty() && packs::backend().is_some_and(|b| b.downloads_on()) {
// Downloading came on (Refresh List, the bar, another Craft app): the refusals no longer hold.
let refused = std::mem::take(&mut app.language_packs.refused);
app.language_packs.errors.retain(|key, _| !refused.contains(key));
}
let status = packs::status();
let now: BTreeSet<String> = status.installing.iter().map(|(l, _, _)| l.clone()).collect();
let ended: Vec<String> = app.language_packs.running.difference(&now).cloned().collect();
// The installs running now, an agent's too, and the ones the window started that haven't ended.
app.language_packs.running = now;
if !ended.is_empty() {
for locale in ended {
// The status bar is a live region: the end is announced wherever focus is.
announce_end(app, &locale, status.errors.get(&locale).map(String::as_str));
}
app.language_packs.missing = None;
}
if status.refreshing {
return;
}
let Some(tag) = app.language_packs.wanted.take() else { return };
app.language_packs.index = None;
app.language_packs.missing = None;
if let Some(e) = status.errors.get("") {
let message = crate::i18n::fmt(tl!("Couldn't get the list of Language packs: {error}"), &[("error", &shown_error(e))]);
app.language_packs.fail(tag, message.clone());
app.status(message);
} else if let Some(pack) = packs::pack_for_tag(&tag, &packs::available()).cloned() {
// The person's click asked for it, and turned downloading on.
install(app, &pack.locale);
// The session already checked for work this frame. Wake it even if the install ends before the next check.
ctx.request_repaint();
} else {
let name = language_name(&tag, None);
app.status(crate::i18n::fmt(tl!("There is no Language pack for {language} yet."), &[("language", &name)]));
}
}
/// Handles the shared consent decision and remembers which messages are only temporary refusals.
fn consent(app: &mut VectorcraftApp, ui: &Ui, injected: bool, key: &str) -> bool {
app.language_packs.clear(key);
let Some(backend) = packs::backend() else { return false };
let decision = language_packs::consent(backend.downloads_on(), injected, packs::enable_downloads);
if let Some(message) = decision.message(&Env::of(ui).words::<LanguagePackWords>()) {
app.language_packs.fail(key, message);
if decision == Consent::Refused {
app.language_packs.refused.insert(key.to_string());
}
}
decision.is_on()
}
/// `proof.installPack` for `locale`; a refusal is kept for its row. An install that started is watched from now on,
/// so its end is announced even when it ends before the next frame looks; one that is done already is announced now.
fn install(app: &mut VectorcraftApp, locale: &str) {
app.language_packs.clear(locale);
match app.run("proof.installPack", json!({ "locale": locale })) {
Ok(r) if r["installed"] == true => announce_end(app, locale, None),
Ok(_) => {
app.language_packs.running.insert(locale.to_string());
}
Err(e) => {
app.language_packs.fail(locale.to_string(), shown_error(&e));
announce_end(app, locale, Some(&e));
}
}
app.language_packs.missing = None;
}
/// Says in the status bar, a live region, that the install of `locale` ended: installed, or its `error`.
fn announce_end(app: &mut VectorcraftApp, locale: &str, error: Option<&str>) {
let own = packs::installed().into_iter().find(|i| i.locale == locale).map(|i| i.name);
let name = language_name(locale, own.as_deref());
let message = match error {
Some(e) => {
crate::i18n::fmt(tl!("Couldn't install the {language} Language pack: {error}"), &[("language", &name), ("error", &shown_error(e))])
}
None => crate::i18n::fmt(tl!("The {language} Language pack is installed."), &[("language", &name)]),
};
app.status(message);
}
/// Removes through `proof.removePack`; a failure is kept for its row and announced.
fn remove(app: &mut VectorcraftApp, locale: &str) {
app.language_packs.clear(locale);
let own = packs::installed().into_iter().find(|p| p.locale == locale).map(|p| p.name);
let name = language_name(locale, own.as_deref());
let message = match app.run("proof.removePack", json!({ "locale": locale })) {
Ok(_) => crate::i18n::fmt(tl!("The {language} Language pack is removed."), &[("language", &name)]),
Err(e) => {
let error = shown_error(&e);
app.language_packs.fail(locale.to_string(), error.clone());
crate::i18n::fmt(tl!("Couldn't remove the {language} Language pack: {error}"), &[("language", &name), ("error", &error)])
}
};
app.status(message);
app.language_packs.missing = None;
}
/// `proof.packs {refresh: true}` (fetching runs on the engine's thread); a refusal is kept under `key` → whether
/// the fetch started.
fn refresh(app: &mut VectorcraftApp, key: &str) -> bool {
app.language_packs.index = None;
match app.run("proof.packs", json!({ "refresh": true })) {
Ok(_) => true,
Err(e) => {
app.language_packs.fail(key.to_string(), shown_error(&e));
false
}
}
}
/// The index fetched last, read again only when a fetch starts or ends or the installed packs change.
fn index(app: &mut VectorcraftApp) -> Vec<Pack> {
let key = (packs::status().refreshing, packs::index_generation(), packs::generation());
if let Some((k, list)) = &app.language_packs.index
&& *k == key
{
return list.clone();
}
let list = packs::available();
app.language_packs.index = Some((key, list.clone()));
list
}
/// The failure to show for `locale` (`""`: the list): the window's own, else the engine's last.
fn error_of(app: &VectorcraftApp, errors: &BTreeMap<String, String>, locale: &str) -> Option<String> {
app.language_packs.errors.get(locale).cloned().or_else(|| errors.get(locale).map(|e| shown_error(e)))
}
/// The share of an install done, from its bytes (`total` 0: not known yet).
fn fraction(done: u64, total: u64) -> f32 {
if total == 0 { 0.0 } else { (done.min(total) as f64 / total as f64) as f32 }
}
/// "Installing… 40%" for an install's bytes.
fn installing_text(done: u64, total: u64) -> String {
let percent = (fraction(done, total) * 100.0).round().to_string();
crate::i18n::fmt(tl!("Installing… {percent}%"), &[("percent", &percent)])
}
/// The desktop part of Preferences › Language Packs ([`super::page`]).
pub(super) fn page(app: &mut VectorcraftApp, ui: &mut Ui) {
let Some(backend) = packs::backend() else {
Notice::new(Tone::Warn, tl!("Language packs aren't available: there is no font store folder for this user.")).show(ui);
return;
};
let injected = injected(ui.ctx());
let status = packs::status();
let list = index(app);
let installed = packs::installed();
if !backend.downloads_on() {
Text::new(tl!("Downloading is off. Install or Refresh List turns it on, for every Craft app.")).show(ui);
}
if let Some(test) = backend.index_override() {
Notice::new(Tone::Warn, crate::i18n::fmt(tl!("Packs come from a test list: {source}"), &[("source", &shown_error(&test))])).show(ui);
}
let mut refresh_clicked = false;
Row::new().wrap(true).show(ui, |ui, _| {
refresh_clicked |= Button::new(tl!("Refresh List")).enabled(!status.refreshing).show(ui).clicked();
if status.refreshing {
Text::new(tl!("Getting the list of languages…")).show(ui);
}
});
if let Some(e) = error_of(app, &status.errors, "") {
let message = crate::i18n::fmt(tl!("Couldn't get the list of Language packs: {error}"), &[("error", &e)]);
Notice::new(Tone::Bad, message).announce(Politeness::Assertive).show(ui);
}
// The installed packs, whether or not the list has them (another app may have installed one from a newer list).
Text::new(tl!("Installed")).show(ui);
if installed.is_empty() {
Text::new(tl!("No Language packs are installed.")).show(ui);
}
let mut remove_clicked: Option<String> = None;
for pack in &installed {
let name = language_name(&pack.locale, Some(&pack.name));
Row::new().wrap(true).show(ui, |ui, _| {
Text::new(name.clone()).show(ui);
Text::new(shown(&pack.licence, MAX_NAME)).show(ui);
if Button::new(tl!("Remove")).show(ui).clicked() {
remove_clicked = Some(pack.locale.clone());
}
});
if let Some(e) = error_of(app, &status.errors, &pack.locale) {
Notice::new(Tone::Bad, e).announce(Politeness::Assertive).show(ui);
}
}
Text::new(tl!("Available")).show(ui);
if list.is_empty() && !status.refreshing {
Text::new(tl!("The list of Language packs hasn't been fetched yet: Refresh List gets it.")).show(ui);
}
let mut install_clicked: Option<String> = None;
for pack in list.iter().filter(|p| !installed.iter().any(|i| i.locale == p.locale)) {
let name = language_name(&pack.locale, Some(&pack.name));
let running = status.installing.iter().find(|(l, _, _)| *l == pack.locale).map(|(_, d, t)| (*d, *t));
let details: Vec<String> =
[size_text(ui, pack.size), provides(pack), shown(&pack.licence, MAX_NAME)].into_iter().filter(|s| !s.is_empty()).collect();
Row::new().wrap(true).show(ui, |ui, _| {
Text::new(name.clone()).show(ui);
Text::new(details.join(" · ")).show(ui);
match running {
Some((done, total)) => {
Progress::new(fraction(done, total)).show(ui);
Text::new(installing_text(done, total)).show(ui);
}
None => {
if Button::new(tl!("Install")).show(ui).clicked() {
install_clicked = Some(pack.locale.clone());
}
}
}
});
if let Some(e) = error_of(app, &status.errors, &pack.locale) {
Notice::new(Tone::Bad, e).announce(Politeness::Assertive).show(ui);
}
}
if refresh_clicked && consent(app, ui, injected, "") {
refresh(app, "");
}
if let Some(locale) = remove_clicked {
remove(app, &locale);
}
if let Some(locale) = install_clicked
&& consent(app, ui, injected, &locale)
{
install(app, &locale);
}
}
/// What the bar offers for the front document, worked out again when the document, the installed packs or the
/// list change (at most once a [`MISSING_REFRESH_SECS`] while the document is being edited).
fn missing(app: &mut VectorcraftApp, ctx: &egui::Context) -> Vec<Missing> {
let now = ctx.input(|i| i.time);
let Some(st) = app.session.active() else { return Vec::new() };
let key = MissingKey {
document: st.uid,
revision: st.revision,
generation: packs::generation(),
refreshing: packs::status().refreshing,
index: packs::index_generation(),
};
if let Some((k, at, m)) = &app.language_packs.missing {
let only_edited = k.document == key.document && k.generation == key.generation && k.refreshing == key.refreshing && k.index == key.index;
if *k == key {
return m.clone();
}
let age = now - *at;
if only_edited && age < MISSING_REFRESH_SECS {
// Stale for an edit: a frame comes once it may be worked out again, even with no input by then.
ctx.request_repaint_after(std::time::Duration::from_secs_f64((MISSING_REFRESH_SECS - age).max(0.0)));
return m.clone();
}
}
let m = vectorcraft_engine::cmd::packs::missing(&app.session);
app.language_packs.missing = Some((key, now, m.clone()));
m
}
/// The key a bar is closed under: its pack's locale, else (before the list) its language tag.
fn offer_key(m: &Missing) -> String {
m.pack.as_ref().map_or_else(|| m.tag.clone(), |p| p.locale.clone())
}
/// The offer the bar shows for the front document: the first language missing a pack whose bar wasn't closed.
fn shown_offer(app: &mut VectorcraftApp, ctx: &egui::Context) -> Option<Missing> {
packs::backend()?;
let document = app.session.active()?.uid;
missing(app, ctx).into_iter().find(|m| {
let closed = |key: String| app.language_packs.dismissed.contains(&(document, key));
!closed(offer_key(m)) && !closed(m.tag.clone())
})
}
/// The missing-pack bar at the foot of the canvas `area`: "<Language> spelling and hyphenation need a Language
/// pack.", with Install (and the size) when the list has the pack, else Get Language Pack, which fetches the list
/// and then installs it. Closing it hides it for that language in this document.
pub(crate) fn bar(app: &mut VectorcraftApp, ui: &mut Ui, area: egui::Rect) {
let Some(offer) = shown_offer(app, &ui.ctx().clone()) else { return };
let Some(document) = app.session.active().map(|st| st.uid) else { return };
let status = packs::status();
let name = language_name(&offer.tag, offer.pack.as_ref().map(|p| p.name.as_str()));
let message = crate::i18n::fmt(tl!("{language} spelling and hyphenation need a Language pack."), &[("language", &name)]);
let key = offer_key(&offer);
let running = status.installing.iter().find(|(l, _, _)| *l == key).map(|(_, d, t)| (*d, *t));
let fetching = offer.pack.is_none() && (status.refreshing || app.language_packs.wanted.is_some());
let error = error_of(app, &status.errors, &key);
let bar_offer = offer.pack.as_ref().map_or(BarOffer::Get, |pack| BarOffer::install(pack.size));
let state = match running {
Some((done, total)) => BarState::installing(done, total),
None if fetching => BarState::Fetching,
None => BarState::Idle,
};
// A child that allocates nothing in the canvas, at its foot and clear of the isolation bar.
let mut bar_ui = ui.new_child(egui::UiBuilder::new().max_rect(area.shrink(8.0)).layout(egui::Layout::bottom_up(egui::Align::Center)));
let response = MissingPackBar::new(message, bar_offer).state(state).error(error).show(&mut bar_ui);
if response.dismissed {
app.language_packs.dismissed.insert((document, key.clone()));
}
if response.clicked && consent(app, &bar_ui, response.injected, &key) {
match &offer.pack {
Some(p) => install(app, &p.locale),
None => {
if refresh(app, &key) {
app.language_packs.wanted = Some(offer.tag.clone());
}
}
}
}
}
#[cfg(test)]
mod tests;
@@ -0,0 +1,406 @@
//! Preferences › Language Packs and the missing-pack bar, over a stand-in for the font store. The packs backend is
//! the whole process's, and with one set the bar shows over any document in a language without a dictionary, so
//! each test that sets it runs in a process of its own ([`crate::testing::in_own_process`]).
use std::path::{Path, PathBuf};
use std::sync::atomic::{AtomicBool, Ordering};
use std::sync::{Arc, Mutex, mpsc};
use std::time::{Duration, Instant};
use egui::accesskit::TreeUpdate;
use egui::{Event, Modifiers, PointerButton, Pos2, RawInput, Rect};
use serde_json::json;
use vectorcraft_engine::Session;
use vectorcraft_engine::packs::{self, Backend, Cancel, Pack};
use super::*;
use crate::Services;
/// A stand-in for the font store: it lists a Konkani pack once the list was fetched (or from the start), and installs
/// it by writing its files. Konkani: no system has a Hunspell dictionary for it, so what the bar offers doesn't
/// depend on the machine.
struct Fake {
dir: PathBuf,
network: AtomicBool,
fetched: AtomicBool,
install_gate: Mutex<Option<mpsc::Receiver<()>>>,
}
impl Fake {
fn new(name: &str, fetched: bool) -> Arc<Fake> {
let dir = std::env::temp_dir().join(format!("vc-ui-packs-{name}-{}", std::process::id()));
let _ = std::fs::remove_dir_all(&dir);
std::fs::create_dir_all(&dir).unwrap();
let fake = Arc::new(Fake { dir, network: AtomicBool::new(false), fetched: AtomicBool::new(fetched), install_gate: Mutex::default() });
packs::set_backend(Some(fake.clone()));
fake
}
fn downloads(&self) -> bool {
self.network.load(Ordering::Relaxed)
}
}
impl Drop for Fake {
fn drop(&mut self) {
let _ = std::fs::remove_dir_all(&self.dir);
}
}
fn konkani() -> Pack {
Pack {
locale: "kok".into(),
name: "कोंकणी".into(),
size: 2_400_000,
licence: "MIT".into(),
class: "Embeddable".into(),
spelling: true,
hyphenation: true,
}
}
/// Writes a small Konkani pack into `packs/kok`, laid out as the font store unpacks one.
fn write_konkani_pack(packs: &Path) {
let dir = packs.join("kok");
std::fs::create_dir_all(dir.join("LICENCES")).unwrap();
std::fs::write(dir.join("pack.toml"), "locale = \"kok\"\nname = \"कोंकणी\"\nlicence = \"MIT\"\n").unwrap();
std::fs::write(dir.join("LICENCES").join("COPYING"), "Test licence text.").unwrap();
std::fs::write(dir.join("spelling.aff"), "SET UTF-8\n").unwrap();
std::fs::write(dir.join("spelling.dic"), "1\nघर\n").unwrap();
}
impl Backend for Fake {
fn packs_dir(&self) -> PathBuf {
self.dir.clone()
}
fn downloads_on(&self) -> bool {
self.downloads()
}
fn cached_index(&self) -> Vec<Pack> {
if self.fetched.load(Ordering::Relaxed) { vec![konkani()] } else { Vec::new() }
}
fn fetch_index(&self, _: &Cancel) -> Result<Vec<Pack>, String> {
assert!(self.downloads(), "a fetch only once downloading is on");
self.fetched.store(true, Ordering::Relaxed);
Ok(self.cached_index())
}
fn install(&self, locale: &str, _: &Cancel, progress: &mut dyn FnMut(u64, u64)) -> Result<(), String> {
assert!(self.downloads(), "an install only once downloading is on");
assert_eq!(locale, "kok");
let gate = self.install_gate.lock().unwrap().take();
if let Some(gate) = gate {
gate.recv_timeout(Duration::from_secs(10)).map_err(|e| e.to_string())?;
}
progress(1, 1);
write_konkani_pack(&self.dir);
Ok(())
}
fn remove(&self, locale: &str) -> Result<(), String> {
std::fs::remove_dir_all(self.dir.join(locale)).map_err(|e| e.to_string())
}
fn enable_downloads(&self) -> Result<(), String> {
self.network.store(true, Ordering::Relaxed);
Ok(())
}
}
/// Takes the backend away when the test ends, also when it failed.
struct NoBackend;
impl Drop for NoBackend {
fn drop(&mut self) {
packs::run_in_background(false);
packs::set_backend(None);
}
}
fn app() -> VectorcraftApp {
crate::testing::windowed(VectorcraftApp::new(Session::new(), Services::default()))
}
/// One frame of the whole app, as the hosts run it → its accessibility tree.
fn frame(a: &mut VectorcraftApp, events: Vec<Event>) -> TreeUpdate {
let ctx = a.ui_ctx.clone().expect("a window context");
let time = ctx.input(|i| i.time) + 0.1;
let raw = RawInput {
events,
time: Some(time),
screen_rect: Some(Rect::from_min_size(Pos2::ZERO, egui::vec2(1400.0, 900.0))),
focused: true,
..Default::default()
};
crate::testing::app_frame(a, &ctx, raw).platform_output.accesskit_update.expect("an accessibility tree")
}
/// Frames until no install or fetch of the list runs and none waits to start (the bar's wanted pack), then one more,
/// whose tick announces what ended.
fn idle(a: &mut VectorcraftApp) {
let start = std::time::Instant::now();
loop {
frame(a, vec![]);
let status = packs::status();
if status.installing.is_empty() && !status.refreshing && a.language_packs.wanted.is_none() {
break;
}
assert!(start.elapsed() < std::time::Duration::from_secs(10), "the pack work never ended");
std::thread::sleep(std::time::Duration::from_millis(5));
}
frame(a, vec![]);
}
/// [`idle`], then frames until the layout holds still → the last one's tree.
fn settled(a: &mut VectorcraftApp) -> TreeUpdate {
idle(a);
for _ in 0..5 {
frame(a, vec![]);
}
frame(a, vec![])
}
fn labels(tree: &TreeUpdate) -> Vec<String> {
tree.nodes.iter().filter_map(|(_, n)| n.label().map(str::to_string)).collect()
}
fn has(tree: &TreeUpdate, part: &str) -> bool {
labels(tree).iter().any(|l| l.contains(part))
}
/// The centre of the control named `label` exactly (Install, not the Installed heading).
fn spot(tree: &TreeUpdate, label: &str) -> Option<Pos2> {
spot_where(tree, |l| l == label)
}
/// The centre of the control whose name starts with `start` (`Install (` and the size).
fn spot_starting(tree: &TreeUpdate, start: &str) -> Option<Pos2> {
spot_where(tree, |l| l.starts_with(start))
}
fn spot_where(tree: &TreeUpdate, named: impl Fn(&str) -> bool) -> Option<Pos2> {
let (_, node) = tree.nodes.iter().find(|(_, n)| n.label().is_some_and(|l| named(l.trim())) && n.bounds().is_some())?;
let b = node.bounds()?;
Some(Pos2::new((b.x0 + b.x1) as f32 * 0.5, (b.y0 + b.y1) as f32 * 0.5))
}
/// The person's own click at `at` (not the control channel's).
fn click(a: &mut VectorcraftApp, at: Pos2) {
frame(a, vec![Event::PointerMoved(at)]);
for pressed in [true, false] {
frame(a, vec![Event::PointerButton { pos: at, button: PointerButton::Primary, pressed, modifiers: Modifiers::NONE }]);
}
idle(a);
}
/// An agent's click on the control named `name`, through the control channel.
fn agent_click(a: &mut VectorcraftApp, name: &str) {
let ctx = a.ui_ctx.clone().expect("a window context");
let (request, _reply) = craft::automation::ControlRequest::new("ui.click", json!({"control": {"name": name}}));
let _ = crate::control::handle(a, &ctx, &request);
for _ in 0..3 {
frame(a, vec![]);
}
idle(a);
}
fn installed() -> Vec<String> {
packs::installed().into_iter().map(|p| p.locale).collect()
}
/// A document with type in Konkani.
fn konkani_document(a: &mut VectorcraftApp) {
a.run("file.new", json!({"width": 400, "height": 400})).unwrap();
let id = a.run("text.create", json!({"x": 10, "y": 50, "text": "घर"})).unwrap()["id"].clone();
a.run("text.setFormat", json!({"ids": [id], "language": "Konkani"})).unwrap();
}
#[test]
fn the_page_installs_and_removes_a_pack_on_the_persons_click() {
if !crate::testing::in_own_process("language_packs::desktop::tests::the_page_installs_and_removes_a_pack_on_the_persons_click") {
return;
}
let _none = NoBackend;
let fake = Fake::new("page", true);
let mut a = app();
crate::prefs_dialog::open(&mut a, Some("language packs"));
let tree = settled(&mut a);
assert!(has(&tree, "Konkani (कोंकणी)"), "the pack is listed by name: {:?}", labels(&tree));
assert!(has(&tree, "Spelling and hyphenation"), "with what it provides");
assert!(has(&tree, "Downloading is off"), "and says downloading is off");
let install = spot(&tree, "Install").expect("an Install button");
click(&mut a, install);
assert!(fake.downloads(), "the person's click turned downloading on");
assert_eq!(installed(), ["kok"]);
assert!(a.ui.status.contains("installed"), "the end is announced: {}", a.ui.status);
let tree = settled(&mut a);
assert!(!has(&tree, "Downloading is off"));
let remove = spot(&tree, "Remove").expect("a Remove button for the installed pack");
click(&mut a, remove);
assert!(installed().is_empty(), "removed");
assert!(spot(&settled(&mut a), "Install").is_some(), "the pack can be installed again");
}
#[test]
fn a_faked_click_never_turns_on_downloading() {
if !crate::testing::in_own_process("language_packs::desktop::tests::a_faked_click_never_turns_on_downloading") {
return;
}
let _none = NoBackend;
let fake = Fake::new("agent", true);
let mut a = app();
crate::prefs_dialog::open(&mut a, Some("Language Packs"));
settled(&mut a);
agent_click(&mut a, "Install");
assert!(!fake.downloads(), "an injected click is no consent");
assert!(installed().is_empty(), "nothing installed");
assert!(has(&settled(&mut a), "Only you can turn on downloading"), "the row says why");
// Once the person turned it on, the refusal goes, and an agent installs.
fake.enable_downloads().unwrap();
assert!(!has(&settled(&mut a), "Only you can turn on downloading"), "the refusal no longer holds");
agent_click(&mut a, "Install");
assert_eq!(installed(), ["kok"]);
}
/// A failure that took a refusal's place is a failure: downloading coming on drops refusals only.
#[test]
fn a_failure_after_a_refusal_outlasts_downloading_coming_on() {
if !crate::testing::in_own_process("language_packs::desktop::tests::a_failure_after_a_refusal_outlasts_downloading_coming_on") {
return;
}
let _none = NoBackend;
let fake = Fake::new("refused-then-failed", true);
let mut a = app();
crate::prefs_dialog::open(&mut a, Some("Language Packs"));
settled(&mut a);
agent_click(&mut a, "Install");
assert!(has(&settled(&mut a), "Only you can turn on downloading"), "refused first");
// Removing a pack that isn't installed fails under the same locale.
remove(&mut a, "kok");
let failure = a.language_packs.errors.get("kok").cloned().expect("the removal's failure");
assert!(!failure.contains("Only you can turn on downloading"), "{failure}");
fake.enable_downloads().unwrap();
settled(&mut a);
assert_eq!(a.language_packs.errors.get("kok"), Some(&failure), "the failure stays once downloading is on");
}
#[test]
fn immediate_pack_errors_reach_the_status_bar() {
if !crate::testing::in_own_process("language_packs::desktop::tests::immediate_pack_errors_reach_the_status_bar") {
return;
}
let _none = NoBackend;
let _fake = Fake::new("immediate-errors", true);
let mut a = app();
// The engine rejects the install before starting a worker because downloading is off.
install(&mut a, "kok");
let install_error = &a.language_packs.errors["kok"];
assert!(a.ui.status.contains("Couldn't install") && a.ui.status.contains(install_error), "{}", a.ui.status);
assert!(packs::status().installing.is_empty());
// The backend rejects removal synchronously because the pack does not exist.
remove(&mut a, "kok");
let remove_error = &a.language_packs.errors["kok"];
assert!(a.ui.status.contains("Couldn't remove") && a.ui.status.contains(remove_error), "{}", a.ui.status);
}
#[test]
fn a_deferred_install_schedules_its_completion_frame() {
if !crate::testing::in_own_process("language_packs::desktop::tests::a_deferred_install_schedules_its_completion_frame") {
return;
}
let _none = NoBackend;
let fake = Fake::new("deferred-repaint", false);
fake.enable_downloads().unwrap();
packs::run_in_background(true);
let (finish, gate) = mpsc::channel();
*fake.install_gate.lock().unwrap() = Some(gate);
let mut a = app();
let ctx = a.ui_ctx.clone().expect("a window context");
// Tick the host without drawing widgets, which can independently ask for repaints.
let tick = |app: &mut VectorcraftApp| {
let mut out = ctx.run_ui(egui::RawInput::default(), |ui| app.tick(ui.ctx()));
out.textures_delta.clear();
out.viewport_output[&egui::ViewportId::ROOT].repaint_delay
};
for _ in 0..3 {
tick(&mut a);
}
assert_eq!(tick(&mut a), Duration::MAX, "the idle host does not request a frame");
// The bar's request is pending when the fetch finishes and the host next ticks.
assert!(refresh(&mut a, "kok"));
a.language_packs.wanted = Some("kok".into());
wait_for_pack_worker(|| !packs::status().refreshing);
let repaint_delay = tick(&mut a);
assert!(!packs::status().installing.is_empty(), "the deferred install started during the tick");
assert!(repaint_delay < Duration::MAX, "the host must wake with no further input");
finish.send(()).unwrap();
wait_for_pack_worker(|| packs::status().installing.is_empty());
frame(&mut a, vec![]);
assert_eq!(installed(), ["kok"]);
assert!(a.ui.status.contains("is installed"), "the scheduled frame announces completion: {}", a.ui.status);
}
fn wait_for_pack_worker(done: impl Fn() -> bool) {
let start = Instant::now();
while !done() {
assert!(start.elapsed() < Duration::from_secs(10), "the pack worker did not finish");
std::thread::sleep(Duration::from_millis(5));
}
}
#[test]
fn the_bar_gets_the_pack_for_the_documents_language() {
if !crate::testing::in_own_process("language_packs::desktop::tests::the_bar_gets_the_pack_for_the_documents_language") {
return;
}
let _none = NoBackend;
// No list yet: the bar offers the language alone, and its button gets the list, then the pack.
let fake = Fake::new("bar", false);
let mut a = app();
konkani_document(&mut a);
let tree = settled(&mut a);
assert!(has(&tree, "Konkani spelling and hyphenation need a Language pack."), "{:?}", labels(&tree));
let get = spot(&tree, "Get Language Pack").expect("the bar's button");
click(&mut a, get);
let tree = settled(&mut a);
assert!(fake.downloads(), "the person's click turned downloading on");
assert_eq!(installed(), ["kok"], "the list came, then the pack");
assert!(!has(&tree, "need a Language pack"), "the bar is gone once the language spells: {:?}", labels(&tree));
}
#[test]
fn closing_the_bar_hides_it_for_that_document() {
if !crate::testing::in_own_process("language_packs::desktop::tests::closing_the_bar_hides_it_for_that_document") {
return;
}
let _none = NoBackend;
let _fake = Fake::new("close", true);
let mut a = app();
konkani_document(&mut a);
let tree = settled(&mut a);
assert!(spot_starting(&tree, "Install (").is_some(), "the bar offers the pack with its size: {:?}", labels(&tree));
let close = ["Dismiss", "Close"].iter().find_map(|l| spot(&tree, l)).unwrap_or_else(|| panic!("the bar's close button: {:?}", labels(&tree)));
click(&mut a, close);
assert!(!has(&settled(&mut a), "need a Language pack"), "closed for this document");
konkani_document(&mut a);
assert!(has(&settled(&mut a), "need a Language pack"), "another document in the language offers it again");
assert!(installed().is_empty(), "nothing installed without a click");
}
/// Text from the index isn't ours to trust: control, bidi and tag characters are taken out and it is cut short.
#[test]
fn index_text_is_shown_without_hidden_characters() {
let hostile = "Nederlands\u{202E}lmth.exe\u{E0041}\u{200B}\n";
let shown = language_name("zz", Some(hostile));
assert!(!shown.chars().any(|c| c.is_control() || ('\u{202A}'..='\u{202E}').contains(&c) || ('\u{E0000}'..='\u{E007F}').contains(&c)));
assert!(shown.starts_with("Nederlands"));
assert!(language_name("zz", Some(&"x".repeat(100))).chars().count() <= 40, "cut short");
}
+4
View File
@@ -56,6 +56,7 @@ pub mod icon_data;
pub mod icons;
pub mod io;
pub mod keymap;
pub mod language_packs;
pub mod layout_migration;
pub mod menus;
pub mod opening;
@@ -270,6 +271,9 @@ pub struct VectorcraftApp {
pub concept_runs: panels::concept_vector::ConceptRuns,
/// Retype's search of the installed fonts, off the UI thread ([`retype_runs`]).
pub retype_runs: retype_runs::RetypeRuns,
/// Language packs: the Preferences page's and the missing-pack bar's state ([`language_packs`]). The web has none.
#[cfg(not(target_arch = "wasm32"))]
pub(crate) language_packs: language_packs::Runtime,
/// Data Recovery's timer and startup question ([`recovery`]).
pub recovery: recovery::Timer,
/// The Close, Close All or Quit in progress, which asks about each unsaved document in turn.
+4 -2
View File
@@ -172,7 +172,7 @@ fn east_asian_hidden(app: &VectorcraftApp, id: &str) -> bool {
/// How the menus show item `id` (params `p`) now: (enabled, checked: `Some` for an item that is on
/// or off), or `None` while they leave it out: an empty slot ([`hidden_when_disabled`]), an item
/// another stands in for ([`swapped_out`]) or an East Asian item with those options hidden
/// ([`east_asian_hidden`]).
/// ([`east_asian_hidden`]), or a disabled type conversion.
pub fn shown_state(app: &VectorcraftApp, id: &str, p: &Value) -> Option<(bool, Option<bool>)> {
shown_state_with(app, id, p, &mut |id| why_off(app, id))
}
@@ -194,7 +194,9 @@ pub(crate) fn shown_state_with(
})
&& (id != crate::addons::select::link_status::COMMAND || crate::addons::select::link_status::enabled(app, p))
&& (!vectorcraft_engine::cmd::plugin::is_command_id(id) || crate::dialogs::plugin::canvas_item_enabled(app, id, p));
if (!en && hidden_when_disabled(id)) || swapped_out(id, why_off) || east_asian_hidden(app, id) {
// Keep conversion labels in the catalog while leaving unavailable rows out of the Type menu.
let hide_disabled = hidden_when_disabled(id) || matches!(id, "type.convertToAreaType" | "type.convertToPointType");
if (!en && hide_disabled) || swapped_out(id, why_off) || east_asian_hidden(app, id) {
return None;
}
Some((en, checked(app, id, p)))
+60
View File
@@ -164,6 +164,66 @@ fn snapping_menu_clicks_toggle_view_state_and_painted_checkmarks() {
assert_eq!(menu.toggled("Pixel Snapping Options…"), None);
}
#[test]
fn type_menu_offers_only_conversions_that_apply_to_selected_text() {
use crate::tests::panel_harness::Panel;
use craft::ui::contract::Role;
fn draw(app: &mut VectorcraftApp, ui: &mut egui::Ui) {
model::refresh(app, ui.ctx());
craft::menu::MenuBarUi::new(&app.menus.laid).show(ui);
}
const TO_AREA: &str = "Convert To Area Type";
const TO_POINT: &str = "Convert To Point Type";
crate::i18n::set_current(crate::i18n::Lang::EN);
let mut app = VectorcraftApp::new(vectorcraft_engine::Session::new(), crate::Services::default());
app.run("file.new", json!({})).unwrap();
let point = app.run("text.create", json!({"x": 20, "y": 40, "text": "Point type"})).unwrap()["id"].clone();
let area = app.run("text.create", json!({"x": 20, "y": 100, "text": "Area type", "area": {"width": 120, "height": 60}})).unwrap()["id"].clone();
let rectangle = app.run("shape.rectangle", json!({"x": 160, "y": 40, "width": 40, "height": 40})).unwrap()["id"].clone();
app.run("select.set", json!({"ids": [point.clone()]})).unwrap();
let mut menu = Panel::new(app, draw);
menu.click("Type");
assert!(menu.menu_item_enabled(TO_AREA));
assert!(!menu.shows_role(TO_POINT, Role::MENU_ITEM));
menu.click_menu_item(TO_AREA);
menu.click("Type");
assert!(menu.menu_item_enabled(TO_POINT));
assert!(!menu.shows_role(TO_AREA, Role::MENU_ITEM));
menu.click_menu_item(TO_POINT);
menu.click("Type");
assert!(menu.menu_item_enabled(TO_AREA));
assert!(!menu.shows_role(TO_POINT, Role::MENU_ITEM));
menu.click("Type");
menu.app().run("select.set", json!({"ids": [point.clone(), area]})).unwrap();
menu.click("Type");
assert!(menu.menu_item_enabled(TO_AREA));
assert!(menu.menu_item_enabled(TO_POINT));
menu.click("Type");
menu.app().run("select.set", json!({"ids": []})).unwrap();
menu.click("Type");
assert!(!menu.shows_role(TO_AREA, Role::MENU_ITEM));
assert!(!menu.shows_role(TO_POINT, Role::MENU_ITEM));
menu.click("Type");
menu.app().run("select.set", json!({"ids": [rectangle.clone()]})).unwrap();
menu.click("Type");
assert!(!menu.shows_role(TO_AREA, Role::MENU_ITEM));
assert!(!menu.shows_role(TO_POINT, Role::MENU_ITEM));
menu.click("Type");
menu.app().run("select.set", json!({"ids": [rectangle, point]})).unwrap();
let group = menu.app().run("object.group", json!({})).unwrap()["id"].clone();
menu.app().run("select.set", json!({"ids": [group]})).unwrap();
menu.click("Type");
assert!(menu.menu_item_enabled(TO_AREA));
assert!(!menu.shows_role(TO_POINT, Role::MENU_ITEM));
}
/// The Window menu keeps one check column: the labels of checked and unchecked panels, of plain
/// commands and of submenus all start at the same x.
#[test]
+10 -9
View File
@@ -128,8 +128,8 @@ pub(crate) fn corner_length(c: &LiveCorners, k: usize) -> f64 {
}
/// What a corner field edits, as its edit target: the active document's uid, how many times
/// File › Revert and Undo or Redo replaced its content (after which a node id can name another
/// object), the selected objects in id order, and `corners`, the corners the field sets (a picked
/// File › Revert, Undo or Redo and other rollbacks (`DocState::rollbacks`) replaced its content
/// (after which a node id can name another object), the selected objects in id order, and `corners`, the corners the field sets (a picked
/// corner as its [`CornerPlace`]). A field drops a value typed and not yet committed when this
/// changes, even where the new corners have the same radius, and keeps it when the same objects
/// are selected in another order. Rounding a corner replaces its anchors without changing the
@@ -142,7 +142,7 @@ pub(crate) fn corner_target(app: &VectorcraftApp, corners: impl Hash) -> u64 {
.map(|st| {
let mut objects = st.selection.objects.to_vec();
objects.sort_unstable();
(st.uid, st.reverts, st.history_restores, objects)
(st.uid, st.reverts, st.history_restores, st.rollbacks, objects)
})
.hash(&mut hasher);
corners.hash(&mut hasher);
@@ -899,11 +899,12 @@ pub(crate) fn current_transparency(app: &VectorcraftApp) -> Option<(f32, BlendMo
Some(picked.unwrap_or((n.opacity, n.blend)))
}
/// The objects a selection field edits, as a field's edit target: the document with how many times File › Revert and
/// Undo or Redo replaced its content (after which a node id can name another object), the selected objects (or the
/// object targeted in the Layers panel) in id order, and the selected symbol part. A field with an unfinished value
/// drops it when these change, and keeps it when the same objects are selected in another order.
pub(crate) type SelectionTarget = (Option<(u64, u64, u64)>, Vec<NodeId>, Option<(NodeId, Vec<u32>)>);
/// The objects a selection field edits, as a field's edit target: the document with how many times File › Revert,
/// Undo or Redo and other rollbacks (`DocState::rollbacks`) replaced its content (after which a node id can name
/// another object), the selected objects (or the object targeted in the Layers panel) in id order, and the selected
/// symbol part. A field with an unfinished value drops it when these change, and keeps it when the same objects are
/// selected in another order.
pub(crate) type SelectionTarget = (Option<(u64, u64, u64, u64)>, Vec<NodeId>, Option<(NodeId, Vec<u32>)>);
/// The [`SelectionTarget`] of the active document.
pub(crate) fn selection_target(app: &VectorcraftApp) -> SelectionTarget {
@@ -911,7 +912,7 @@ pub(crate) fn selection_target(app: &VectorcraftApp) -> SelectionTarget {
let part = st.selection.symbol_part.as_ref().map(|p| (p.instance, p.path.clone()));
let mut subjects = st.selection.subjects().to_vec();
subjects.sort_unstable();
(Some((st.uid, st.reverts, st.history_restores)), subjects, part)
(Some((st.uid, st.reverts, st.history_restores, st.rollbacks)), subjects, part)
}
/// What the Transparency panel's and the Control bar's Opacity fields edit, as their edit target: the
+79 -27
View File
@@ -11,7 +11,7 @@ use craft::ui::layout_components::{Row, Stack};
use craft::ui::pickers::Select;
use craft::ui::text::{NumberField, link_toggle};
use craft::ui::value_drag::Slider;
use egui::Ui;
use egui::{IdSalt, Ui};
use serde_json::{Value, json};
use vectorcraft_doc::{LiveShape, Node, NodeKind};
use vectorcraft_geom::shapes::CornerKind;
@@ -42,14 +42,22 @@ const SIDES_SLIDER: RangeInclusive<f64> = 3.0..=20.0;
pub(crate) fn live_shape_rows(app: &mut VectorcraftApp, ui: &mut Ui, n: &Node, live: &LiveShape, headed: bool) -> bool {
match live {
LiveShape::Rectangle { .. } => under_heading(ui, headed.then(|| tl!("Rectangle Properties:")), |ui| {
angle_row(app, ui, live, "rectangleAngle");
let target = shape_edit_target(app);
angle_row(app, ui, live, "rectangleAngle", target);
corner_radius_row(app, ui, n);
}),
LiveShape::Polygon { .. } => under_heading(ui, headed.then(|| tl!("Polygon Properties:")), |ui| polygon_rows(app, ui, n, live)),
LiveShape::Star { .. } => under_heading(ui, headed.then(|| tl!("Star Properties:")), |ui| star_rows(app, ui, live)),
LiveShape::Polygon { .. } => under_heading(ui, headed.then(|| tl!("Polygon Properties:")), |ui| {
let target = shape_edit_target(app);
polygon_rows(app, ui, n, live, target);
}),
LiveShape::Star { .. } => under_heading(ui, headed.then(|| tl!("Star Properties:")), |ui| {
let target = shape_edit_target(app);
star_rows(app, ui, live, target);
}),
LiveShape::Ellipse { pie, .. } => under_heading(ui, Some(tl!("Ellipse Properties:")), |ui| {
angle_row(app, ui, live, "ellipseAngle");
pie_rows(app, ui, *pie);
let target = shape_edit_target(app);
angle_row(app, ui, live, "ellipseAngle", target);
pie_rows(app, ui, *pie, target);
}),
LiveShape::Line { .. } => return line_rows(app, ui, live),
_ => return false,
@@ -57,6 +65,27 @@ pub(crate) fn live_shape_rows(app: &mut VectorcraftApp, ui: &mut Ui, n: &Node, l
true
}
/// The edit target of the live shape number fields: the active document, how many times File › Revert replaced its
/// content, how many times Undo or Redo restored an older snapshot, how many times another rollback put one back
/// (`DocState::rollbacks`; after either, the same node ID can name another object), and the selected objects in
/// selection order, which `object.setLiveShape` changes. The first selected object picks the rows, so the same objects
/// in another order can put another property's field in the same place. A field drops a value typed and not yet
/// committed when this changes, even where the newly selected shape shows the same value. Hashed once per (document
/// uid, revision): the panels read it every frame, and Select All can select hundreds of thousands of shapes. The
/// revision is not part of the target, so an edit that leaves the selection as it is keeps the value typed so far.
pub(crate) fn shape_edit_target(app: &mut VectorcraftApp) -> IdSalt {
let Some(st) = app.session.active() else { return IdSalt::new(None::<()>) };
let key = (st.uid, st.revision);
if let Some((k, target)) = app.canvas.shape_edit_target
&& k == key
{
return target;
}
let target = IdSalt::new(Some((st.uid, st.reverts, st.history_restores, st.rollbacks, st.selection.objects.as_slice())));
app.canvas.shape_edit_target = Some((key, target));
target
}
/// `rows` under a sub-heading, or bare when there is none.
fn under_heading(ui: &mut Ui, heading: Option<&'static str>, mut rows: impl FnMut(&mut Ui)) {
match heading {
@@ -75,7 +104,16 @@ fn set_live_shape(app: &mut VectorcraftApp, params: Value) {
}
/// One labelled number field whose edits send `params(number)` to `object.setLiveShape`; a scrub is one undo step.
fn number_row(app: &mut VectorcraftApp, ui: &mut Ui, label: &'static str, value: Option<f64>, quantity: Quantity, params: impl Fn(f64) -> Value) {
/// `target` is the field's [`shape_edit_target`].
fn number_row(
app: &mut VectorcraftApp,
ui: &mut Ui,
label: &'static str,
value: Option<f64>,
quantity: Quantity,
target: IdSalt,
params: impl Fn(f64) -> Value,
) {
let mut edit = None;
Field::new(label).show(ui, |ui, _| {
let bind = Bind::given(value);
@@ -84,7 +122,7 @@ fn number_row(app: &mut VectorcraftApp, ui: &mut Ui, label: &'static str, value:
Quantity::Degrees => NumberField::new(label, bind).unit("°").commit_decimals(1),
Quantity::Ratio => NumberField::new(label, bind).range(0.001..=1.0).step(0.001).commit_decimals(3),
};
edit = Some(field.show(ui).edit);
edit = Some(field.edit_target(target).show(ui).edit);
});
if let Some(edit) = edit {
// `Scope`, not `Preview`: `Preview` names one command, and each field sends its own params.
@@ -99,9 +137,9 @@ fn number_row(app: &mut VectorcraftApp, ui: &mut Ui, label: &'static str, value:
/// A live rectangle's, ellipse's or polygon's Angle row (counterclockwise): the angle the selected shapes of its
/// kind share, blank when they differ. `key` is the `object.setLiveShape` param an edit sets, which turns each of
/// them about its own center.
fn angle_row(app: &mut VectorcraftApp, ui: &mut Ui, live: &LiveShape, key: &'static str) {
fn angle_row(app: &mut VectorcraftApp, ui: &mut Ui, live: &LiveShape, key: &'static str, target: IdSalt) {
let angle = shared_shape_angle(app, live);
number_row(app, ui, tl!("Angle"), angle, Quantity::Degrees, |a| json!({ key: a }));
number_row(app, ui, tl!("Angle"), angle, Quantity::Degrees, target, |a| json!({ key: a }));
}
/// The angle ([`LiveShape::shape_angle`]) every selected live shape of `live`'s kind shares, `None` when they
@@ -151,9 +189,11 @@ fn line_rows(app: &mut VectorcraftApp, ui: &mut Ui, live: &LiveShape) -> bool {
if !only_lines_selected(app) {
return false;
}
let target = shape_edit_target(app);
under_heading(ui, Some(tl!("Line Properties:")), |ui| {
number_row(app, ui, tl!("Line Length"), live.line_length(), Quantity::Length, |l| json!({ "lineLength": l }));
number_row(app, ui, tl!("Line Angle"), Some(live.line_angle().unwrap_or(0.0)), Quantity::Degrees, |a| json!({ "lineAngle": a }));
number_row(app, ui, tl!("Line Length"), live.line_length(), Quantity::Length, target, |l| json!({ "lineLength": l }));
let angle = Some(live.line_angle().unwrap_or(0.0));
number_row(app, ui, tl!("Line Angle"), angle, Quantity::Degrees, target, |a| json!({ "lineAngle": a }));
});
true
}
@@ -161,13 +201,13 @@ fn line_rows(app: &mut VectorcraftApp, ui: &mut Ui, live: &LiveShape) -> bool {
/// An ellipse's Pie Start and End Angle (degrees, counterclockwise from 3 o'clock; 0 to 360 is the whole
/// ellipse), the Constrain Pie Angle link beside them, and Invert Pie, which shows the other part of it. With the
/// link on, a typed angle moves the other one by as much, so each selected ellipse keeps its span.
fn pie_rows(app: &mut VectorcraftApp, ui: &mut Ui, pie: (f64, f64)) {
fn pie_rows(app: &mut VectorcraftApp, ui: &mut Ui, pie: (f64, f64), target: IdSalt) {
let constrain = app.ui.constrain_pie_angle;
// The link sits halfway between the two fields, with no bracket drawn to them.
Row::new().bracket(Bracket::Unlinked).show(ui, |ui, _| {
Stack::new().show(ui, |ui, _| {
for (label, key, v) in [(tl!("Pie Start Angle"), "pieStart", pie.0), (tl!("Pie End Angle"), "pieEnd", pie.1)] {
number_row(app, ui, label, Some(v), Quantity::Degrees, |a| {
number_row(app, ui, label, Some(v), Quantity::Degrees, target, |a| {
if constrain { json!({ key: a, "constrainPie": true }) } else { json!({ key: a }) }
});
}
@@ -181,16 +221,16 @@ fn pie_rows(app: &mut VectorcraftApp, ui: &mut Ui, pie: (f64, f64)) {
/// A live polygon's Polygon Properties: its side count (a field and a slider), angle (counterclockwise), corner
/// type and radius, radius (center to vertex) and side length, and Make Sides Equal, which an uneven scale enables.
fn polygon_rows(app: &mut VectorcraftApp, ui: &mut Ui, n: &Node, live: &LiveShape) {
fn polygon_rows(app: &mut VectorcraftApp, ui: &mut Ui, n: &Node, live: &LiveShape, target: IdSalt) {
let LiveShape::Polygon { sides, .. } = live else { return };
let radius = live.polygon_radius();
let side = radius.map(|r| 2.0 * r * (std::f64::consts::PI / f64::from((*sides).max(3))).sin());
sides_row(app, ui, *sides);
angle_row(app, ui, live, "polygonAngle");
sides_row(app, ui, *sides, target);
angle_row(app, ui, live, "polygonAngle", target);
corner_kind_row(app, ui, corner_style(app, n).1);
Field::new(tl!("Corner Radius")).show(ui, |ui, _| corner_radius_field(app, ui, n));
number_row(app, ui, tl!("Radius"), radius, Quantity::Length, |r| json!({ "polygonRadius": r }));
number_row(app, ui, tl!("Side Length"), side, Quantity::Length, |l| json!({ "sideLength": l }));
number_row(app, ui, tl!("Radius"), radius, Quantity::Length, target, |r| json!({ "polygonRadius": r }));
number_row(app, ui, tl!("Side Length"), side, Quantity::Length, target, |l| json!({ "sideLength": l }));
if Button::new(tl!("Make Sides Equal")).enabled(!live.polygon_sides_equal()).show(ui).clicked() {
set_live_shape(app, json!({"makeSidesEqual": true}));
}
@@ -200,18 +240,27 @@ fn polygon_rows(app: &mut VectorcraftApp, ui: &mut Ui, n: &Node, live: &LiveShap
/// over [`SIDES_SLIDER`]. A typed count is one undo step. A slider drag previews the count and its release records
/// one undo step; Escape during the drag puts the count back. A click on the rail or an arrow key sets the count in
/// one undo step. A count above 20 puts the thumb at the rail's right end, and screen readers read the real count.
fn sides_row(app: &mut VectorcraftApp, ui: &mut Ui, sides: u32) {
count_row(app, ui, tl!("Sides"), "sides", sides, 3.0);
fn sides_row(app: &mut VectorcraftApp, ui: &mut Ui, sides: u32, target: IdSalt) {
count_row(app, ui, tl!("Sides"), "sides", sides, 3.0, target);
}
/// A count row (Polygon Properties' Sides, Star Properties' Points) whose edits set `key`: a field that takes `min`
/// to 1000 and a slider over [`SIDES_SLIDER`], as [`sides_row`] describes.
fn count_row(app: &mut VectorcraftApp, ui: &mut Ui, label: &'static str, key: &'static str, sides: u32, min: f64) {
/// to 1000 and a slider over [`SIDES_SLIDER`], as [`sides_row`] describes. The field drops an unfinished value when
/// `target` changes.
fn count_row(app: &mut VectorcraftApp, ui: &mut Ui, label: &'static str, key: &'static str, sides: u32, min: f64, target: IdSalt) {
let count = f64::from(sides);
let (mut typed, mut slid) = (None, None);
Field::new(label).show(ui, |ui, _| {
Row::new().show(ui, |ui, _| {
typed = Some(NumberField::new(label, Bind::given(Some(count))).range(min..=1000.0).fixed_decimals(0).id_salt("field").show(ui).edit);
typed = Some(
NumberField::new(label, Bind::given(Some(count)))
.range(min..=1000.0)
.fixed_decimals(0)
.id_salt("field")
.edit_target(target)
.show(ui)
.edit,
);
let (lo, hi) = (*SIDES_SLIDER.start(), *SIDES_SLIDER.end());
slid = Some(
Slider::new(Bind::given(count.clamp(lo, hi)), SIDES_SLIDER)
@@ -241,10 +290,10 @@ fn count_row(app: &mut VectorcraftApp, ui: &mut Ui, label: &'static str, key: &'
/// A live star's Star Properties: its point count (a field that takes 2 to 1000 and a slider over 3 to 20) and its
/// ratio (inner radius over outer radius, 0.001 to 1). Its corners stay with Live Corners and Direct Selection, as any
/// path's do.
fn star_rows(app: &mut VectorcraftApp, ui: &mut Ui, live: &LiveShape) {
fn star_rows(app: &mut VectorcraftApp, ui: &mut Ui, live: &LiveShape, target: IdSalt) {
let Some(points) = live.star_points() else { return };
count_row(app, ui, tl!("Points"), "points", points, 2.0);
number_row(app, ui, tl!("Ratio"), live.star_ratio(), Quantity::Ratio, |r| json!({ "ratio": r }));
count_row(app, ui, tl!("Points"), "points", points, 2.0, target);
number_row(app, ui, tl!("Ratio"), live.star_ratio(), Quantity::Ratio, target, |r| json!({ "ratio": r }));
}
/// The polygon's Corner type select, blank while `kind` is `None` (the corners differ), one number cell wide as the
@@ -259,3 +308,6 @@ fn corner_kind_row(app: &mut VectorcraftApp, ui: &mut Ui, kind: Option<CornerKin
apply_edits(app, &edit, EditPath::Scope, |app, k, _| set_live_shape(app, json!({ "kind": k })));
}
}
#[cfg(test)]
mod tests;
@@ -0,0 +1,421 @@
use craft::ui::contract::Role;
use egui::{Key, Modifiers};
use vectorcraft_doc::Unit;
use super::*;
use crate::tests::panel_harness::Panel;
/// An app with a new document holding two shapes made by `cmd` with `a` and `b`, and their ids.
fn two(cmd: &str, a: Value, b: Value) -> (VectorcraftApp, Value, Value) {
let mut app = VectorcraftApp::new(vectorcraft_engine::Session::new(), Default::default());
app.run("file.new", json!({"width": 400, "height": 400})).unwrap();
let a = app.run(cmd, a).unwrap()["id"].clone();
let b = app.run(cmd, b).unwrap()["id"].clone();
(app, a, b)
}
/// Selects `a`, types "3+" into field `name` drawn by `draw`, selects `b`, then types "7" and Enter. Returns the
/// field's value just after `b` is selected, after the Enter, and with `a` selected again.
fn type_across_a_selection_change(
app: VectorcraftApp,
draw: fn(&mut VectorcraftApp, &mut Ui),
a: &Value,
b: &Value,
name: &str,
) -> (Option<String>, Option<String>, Option<String>) {
let mut app = app;
app.run("select.set", json!({"ids": [a]})).unwrap();
let mut p = Panel::new(app, draw);
p.click_role(name, Role::SPIN_BUTTON);
p.key(Key::A, Modifiers::COMMAND);
p.type_text("3+");
p.app().run("select.set", json!({"ids": [b]})).unwrap();
p.frame();
let switched = p.value_role(name, Role::SPIN_BUTTON);
p.type_text("7");
p.key(Key::Enter, Modifiers::NONE);
p.frame();
let after = p.value_role(name, Role::SPIN_BUTTON);
p.app().run("select.set", json!({"ids": [a]})).unwrap();
p.frame();
(switched, after, p.value_role(name, Role::SPIN_BUTTON))
}
/// Checks that a value typed into field `name` for `a` and not finished is dropped when `b`, which shows `shown`
/// there as `a` does, is selected: the field shows `shown`, "7" and Enter then give `b` 7 (`seven`), not 3+7, and
/// `a` keeps `shown`.
fn check_field(app: VectorcraftApp, draw: fn(&mut VectorcraftApp, &mut Ui), a: &Value, b: &Value, name: &str, shown: &str, seven: &str) {
let (switched, after, first) = type_across_a_selection_change(app, draw, a, b, name);
assert_eq!(switched.as_deref(), Some(shown), "{name}: the field shows the newly selected shape's value");
assert_eq!(after.as_deref(), Some(seven), "{name}: the newly selected shape takes 7, not the unfinished 3+ and 7");
assert_eq!(first.as_deref(), Some(shown), "{name}: the shape the value was first typed for keeps its value");
}
fn pt(v: f64) -> String {
Unit::Points.format(v)
}
fn rectangles() -> (VectorcraftApp, Value, Value) {
two("shape.rectangle", json!({"x": 0, "y": 0, "width": 30, "height": 30}), json!({"x": 100, "y": 0, "width": 30, "height": 30}))
}
fn polygons() -> (VectorcraftApp, Value, Value) {
two("shape.polygon", json!({"cx": 60, "cy": 60, "radius": 40, "sides": 5}), json!({"cx": 200, "cy": 60, "radius": 40, "sides": 5}))
}
fn ellipses() -> (VectorcraftApp, Value, Value) {
two("shape.ellipse", json!({"x": 0, "y": 0, "width": 40, "height": 30}), json!({"x": 100, "y": 0, "width": 40, "height": 30}))
}
fn lines() -> (VectorcraftApp, Value, Value) {
two("shape.line", json!({"x1": 20, "y1": 20, "x2": 120, "y2": 20}), json!({"x1": 20, "y1": 200, "x2": 120, "y2": 200}))
}
#[test]
fn an_unfinished_rectangle_angle_does_not_reach_another_rectangle() {
let (app, a, b) = rectangles();
check_field(app, crate::panels::transform::show, &a, &b, "Angle", "0°", "7°");
let (app, a, b) = rectangles();
check_field(app, crate::panels::properties::show, &a, &b, "Angle", "0°", "7°");
}
#[test]
fn an_unfinished_polygon_sides_count_does_not_reach_another_polygon() {
let (app, a, b) = polygons();
check_field(app, crate::panels::transform::show, &a, &b, "Sides", "5", "7");
}
#[test]
fn an_unfinished_polygon_angle_radius_or_side_length_does_not_reach_another_polygon() {
let (app, a, b) = polygons();
check_field(app, crate::panels::transform::show, &a, &b, "Angle", "0°", "7°");
let (app, a, b) = polygons();
check_field(app, crate::panels::transform::show, &a, &b, "Radius", &pt(40.0), &pt(7.0));
let (app, a, b) = polygons();
let side = pt(2.0 * 40.0 * (std::f64::consts::PI / 5.0).sin());
check_field(app, crate::panels::transform::show, &a, &b, "Side Length", &side, &pt(7.0));
}
/// After Undo removes the shape a value was typed for, a new shape can take its node ID. The value is dropped when
/// that shape is selected, so it does not reach an object it was not typed for.
#[test]
fn an_unfinished_angle_does_not_reach_a_shape_that_takes_an_undone_shapes_id() {
let mut app = VectorcraftApp::new(vectorcraft_engine::Session::new(), Default::default());
app.run("file.new", json!({"width": 400, "height": 400})).unwrap();
let rect = app.run("shape.rectangle", json!({"x": 0, "y": 0, "width": 30, "height": 30})).unwrap()["id"].clone();
app.run("select.set", json!({"ids": [rect]})).unwrap();
let mut p = Panel::new(app, crate::panels::transform::show);
p.click_role("Angle", Role::SPIN_BUTTON);
p.key(Key::A, Modifiers::COMMAND);
p.type_text("3+");
p.app().run("edit.undo", json!({})).unwrap();
let ellipse = p.app().run("shape.ellipse", json!({"x": 100, "y": 0, "width": 40, "height": 30})).unwrap()["id"].clone();
assert_eq!(ellipse, rect, "the ellipse takes the undone rectangle's node ID");
p.app().run("select.set", json!({"ids": [ellipse]})).unwrap();
p.frame();
assert_eq!(p.value_role("Angle", Role::SPIN_BUTTON).as_deref(), Some("0°"), "the field shows the ellipse's angle");
p.type_text("7");
p.key(Key::Enter, Modifiers::NONE);
p.frame();
assert_eq!(p.value_role("Angle", Role::SPIN_BUTTON).as_deref(), Some("7°"), "the ellipse takes 7°, not the unfinished 3+ and 7");
}
/// A canceled undo group removes the shape a value was typed for, and a new shape can take its node ID. The value is
/// dropped when that shape is selected.
#[test]
fn an_unfinished_angle_does_not_reach_a_shape_that_takes_a_canceled_groups_shapes_id() {
let mut app = VectorcraftApp::new(vectorcraft_engine::Session::new(), Default::default());
app.run("file.new", json!({"width": 400, "height": 400})).unwrap();
app.run("edit.undoGroup.begin", json!({})).unwrap();
let rect = app.run("shape.rectangle", json!({"x": 0, "y": 0, "width": 30, "height": 30})).unwrap()["id"].clone();
app.run("select.set", json!({"ids": [rect]})).unwrap();
let mut p = Panel::new(app, crate::panels::transform::show);
p.click_role("Angle", Role::SPIN_BUTTON);
p.key(Key::A, Modifiers::COMMAND);
p.type_text("3+");
p.app().run("edit.undoGroup.end", json!({"cancel": true})).unwrap();
let ellipse = p.app().run("shape.ellipse", json!({"x": 100, "y": 0, "width": 40, "height": 30})).unwrap()["id"].clone();
assert_eq!(ellipse, rect, "the ellipse takes the canceled group's rectangle's node ID");
p.app().run("select.set", json!({"ids": [ellipse]})).unwrap();
p.frame();
assert_eq!(p.value_role("Angle", Role::SPIN_BUTTON).as_deref(), Some("0°"), "the field shows the new shape's angle");
p.type_text("7");
p.key(Key::Enter, Modifiers::NONE);
p.frame();
assert_eq!(p.value_role("Angle", Role::SPIN_BUTTON).as_deref(), Some("7°"), "the ellipse takes 7°, not the unfinished 3+ and 7");
}
/// A canceled interaction removes the shape its preview made and a Corner Radius value was typed for, and a new shape
/// made by `cmd` with `args` takes its node ID. The value is dropped when that shape is selected in the panel `draw`
/// draws.
fn check_corner_radius_after_a_canceled_preview(draw: fn(&mut VectorcraftApp, &mut Ui), cmd: &str, args: Value, panel: &str) {
let mut app = VectorcraftApp::new(vectorcraft_engine::Session::new(), Default::default());
app.run("file.new", json!({"width": 400, "height": 400})).unwrap();
app.session.begin_interaction("Shape").unwrap();
let first = app.session.preview(cmd, &args).unwrap()["id"].clone();
let selected = app.session.active().map(|st| st.selection.objects.clone()).unwrap_or_default();
assert_eq!(json!(selected.iter().map(|id| id.0).collect::<Vec<_>>()), json!([first]), "{panel} {cmd}: the preview selects its shape");
let mut p = Panel::new(app, draw);
p.click_role("Corner Radius", Role::SPIN_BUTTON);
p.key(Key::A, Modifiers::COMMAND);
p.type_text("3+");
p.app().session.cancel_interaction().unwrap();
let second = p.app().run(cmd, args).unwrap()["id"].clone();
assert_eq!(second, first, "{panel} {cmd}: the new shape takes the canceled preview's shape's node ID");
p.app().run("select.set", json!({"ids": [second]})).unwrap();
p.frame();
let shown = p.value_role("Corner Radius", Role::SPIN_BUTTON);
assert_eq!(shown.as_deref(), Some(pt(0.0).as_str()), "{panel} {cmd}: the field shows the new shape's corner radius");
p.type_text("7");
p.key(Key::Enter, Modifiers::NONE);
p.frame();
let after = p.value_role("Corner Radius", Role::SPIN_BUTTON);
assert_eq!(after.as_deref(), Some(pt(7.0).as_str()), "{panel} {cmd}: the new shape takes 7, not the unfinished 3+ and 7");
}
#[test]
fn an_unfinished_rectangle_corner_radius_does_not_reach_a_shape_that_takes_a_canceled_previews_shapes_id() {
let rect = json!({"x": 0, "y": 0, "width": 30, "height": 30});
check_corner_radius_after_a_canceled_preview(crate::panels::transform::show, "shape.rectangle", rect, "Transform");
}
#[test]
fn an_unfinished_polygon_corner_radius_does_not_reach_a_shape_that_takes_a_canceled_previews_shapes_id() {
let polygon = json!({"cx": 60, "cy": 60, "radius": 40, "sides": 5});
check_corner_radius_after_a_canceled_preview(crate::panels::transform::show, "shape.polygon", polygon, "Transform");
}
#[test]
fn an_unfinished_rectangle_corner_radius_in_the_properties_panel_does_not_reach_a_shape_that_takes_a_canceled_previews_shapes_id() {
let rect = json!({"x": 0, "y": 0, "width": 30, "height": 30});
check_corner_radius_after_a_canceled_preview(crate::panels::properties::show, "shape.rectangle", rect, "Properties");
}
#[test]
fn an_unfinished_polygon_corner_radius_in_the_properties_panel_does_not_reach_a_shape_that_takes_a_canceled_previews_shapes_id() {
let polygon = json!({"cx": 60, "cy": 60, "radius": 40, "sides": 5});
check_corner_radius_after_a_canceled_preview(crate::panels::properties::show, "shape.polygon", polygon, "Properties");
}
/// Exit Symbol Editing Mode with nothing changed takes back the entering step, which removes the editing copy a value
/// was typed for, and a new shape can take the copy's node ID. The value is dropped when that shape is selected.
#[test]
fn an_unfinished_angle_does_not_reach_a_shape_that_takes_an_unchanged_symbol_copys_id() {
let mut app = VectorcraftApp::new(vectorcraft_engine::Session::new(), Default::default());
app.run("file.new", json!({"width": 400, "height": 400})).unwrap();
app.run("shape.rectangle", json!({"x": 0, "y": 0, "width": 30, "height": 30})).unwrap();
app.run("symbol.new", json!({"name": "Box"})).unwrap();
app.run("symbol.edit", json!({})).unwrap();
let copy = app.session.active().map(|st| st.selection.objects.clone()).unwrap_or_default();
assert_eq!(copy.len(), 1, "symbol editing selects the editing copy");
let mut p = Panel::new(app, crate::panels::transform::show);
p.click_role("Angle", Role::SPIN_BUTTON);
p.key(Key::A, Modifiers::COMMAND);
p.type_text("3+");
p.app().run("symbol.exitEditing", json!({})).unwrap();
p.app().run("shape.rectangle", json!({"x": 100, "y": 0, "width": 40, "height": 30})).unwrap();
let rect = p.app().run("shape.rectangle", json!({"x": 200, "y": 0, "width": 40, "height": 30})).unwrap()["id"].clone();
assert_eq!(rect, json!(copy[0].0), "the second new rectangle takes the editing copy's node ID");
p.app().run("select.set", json!({"ids": [rect]})).unwrap();
p.frame();
assert_eq!(p.value_role("Angle", Role::SPIN_BUTTON).as_deref(), Some("0°"), "the field shows the new rectangle's angle");
p.type_text("7");
p.key(Key::Enter, Modifiers::NONE);
p.frame();
assert_eq!(p.value_role("Angle", Role::SPIN_BUTTON).as_deref(), Some("7°"), "the rectangle takes 7°, not the unfinished 3+ and 7");
}
/// A canceled interaction removes a shape its preview made and a value was typed for, and a new shape can take that
/// shape's node ID. The value is dropped when that shape is selected.
#[test]
fn an_unfinished_angle_does_not_reach_a_shape_that_takes_a_canceled_previews_shapes_id() {
let mut app = VectorcraftApp::new(vectorcraft_engine::Session::new(), Default::default());
app.run("file.new", json!({"width": 400, "height": 400})).unwrap();
app.session.begin_interaction("Rectangle").unwrap();
let previewed = app.session.preview("shape.rectangle", &json!({"x": 0, "y": 0, "width": 30, "height": 30})).unwrap()["id"].clone();
let selected = app.session.active().map(|st| st.selection.objects.clone()).unwrap_or_default();
assert_eq!(json!(selected.iter().map(|id| id.0).collect::<Vec<_>>()), json!([previewed]), "the preview selects its rectangle");
let mut p = Panel::new(app, crate::panels::transform::show);
p.click_role("Angle", Role::SPIN_BUTTON);
p.key(Key::A, Modifiers::COMMAND);
p.type_text("3+");
p.app().session.cancel_interaction().unwrap();
let rect = p.app().run("shape.rectangle", json!({"x": 100, "y": 0, "width": 40, "height": 30})).unwrap()["id"].clone();
assert_eq!(rect, previewed, "the new rectangle takes the canceled preview's rectangle's node ID");
p.app().run("select.set", json!({"ids": [rect]})).unwrap();
p.frame();
assert_eq!(p.value_role("Angle", Role::SPIN_BUTTON).as_deref(), Some("0°"), "the field shows the new rectangle's angle");
p.type_text("7");
p.key(Key::Enter, Modifiers::NONE);
p.frame();
assert_eq!(p.value_role("Angle", Role::SPIN_BUTTON).as_deref(), Some("7°"), "the rectangle takes 7°, not the unfinished 3+ and 7");
}
/// A replacement preview reuses the discarded rectangle's node ID and drops its unfinished angle.
/// The replacement rectangle takes the next angle typed into the field.
#[test]
fn an_unfinished_angle_does_not_reach_a_replacement_preview_that_reuses_a_discarded_shapes_id() {
let mut app = VectorcraftApp::new(vectorcraft_engine::Session::new(), Default::default());
app.run("file.new", json!({"width": 400, "height": 400})).unwrap();
app.session.begin_interaction("Rectangle").unwrap();
let previewed = app.session.preview("shape.rectangle", &json!({"x": 0, "y": 0, "width": 30, "height": 30})).unwrap()["id"].clone();
let mut p = Panel::new(app, crate::panels::transform::show);
p.click_role("Angle", Role::SPIN_BUTTON);
p.key(Key::A, Modifiers::COMMAND);
p.type_text("3+");
let steps = json!({"commands": [
{"command": "shape.rectangle", "params": {"x": 100, "y": 10, "width": 40, "height": 30}}
]});
let replacement = p.app().session.preview("command.batch", &steps).unwrap();
let rect = replacement["results"][0]["id"].clone();
assert_eq!(rect, previewed, "the replacement rectangle reuses the discarded rectangle's node ID");
let selected = p.app().session.active().map(|st| st.selection.objects.clone()).unwrap_or_default();
assert_eq!(json!(selected.iter().map(|id| id.0).collect::<Vec<_>>()), json!([rect]), "the preview selects the replacement rectangle");
p.frame();
assert_eq!(p.value_role("Angle", Role::SPIN_BUTTON).as_deref(), Some("0°"), "the field shows the replacement rectangle's angle");
p.type_text("7");
p.key(Key::Enter, Modifiers::NONE);
p.frame();
assert_eq!(p.value_role("Angle", Role::SPIN_BUTTON).as_deref(), Some("7°"), "the replacement rectangle takes 7°, not the unfinished 3+ and 7");
}
#[test]
fn an_unfinished_ellipse_angle_or_pie_angle_does_not_reach_another_ellipse() {
for (name, shown) in [("Angle", "0°"), ("Pie Start Angle", "0°"), ("Pie End Angle", "360°")] {
let (app, a, b) = ellipses();
check_field(app, crate::panels::transform::show, &a, &b, name, shown, "7°");
}
}
#[test]
fn an_unfinished_star_points_or_ratio_does_not_reach_another_star() {
let stars = || {
two(
"shape.star",
json!({"cx": 60, "cy": 60, "radius1": 40, "radius2": 20, "points": 5}),
json!({"cx": 200, "cy": 60, "radius1": 40, "radius2": 20, "points": 5}),
)
};
let (app, a, b) = stars();
check_field(app, crate::panels::transform::show, &a, &b, "Points", "5", "7");
let (app, a, b) = stars();
check_field(app, crate::panels::transform::show, &a, &b, "Ratio", "0.5", "1");
}
#[test]
fn an_unfinished_line_length_or_angle_does_not_reach_another_line() {
let (app, a, b) = lines();
check_field(app, crate::panels::transform::show, &a, &b, "Line Length", &pt(100.0), &pt(7.0));
let (app, a, b) = lines();
check_field(app, crate::panels::transform::show, &a, &b, "Line Angle", "0°", "7°");
}
/// A value typed for a rectangle and not finished is dropped when File Revert replaces the document's content or
/// another document becomes active, even where the selection has the same ids and the same angle.
#[test]
fn an_unfinished_angle_is_dropped_by_file_revert_or_another_document() {
type Change = fn(&mut VectorcraftApp);
let changes: [(&str, Change); 2] = [
("File Revert", |app| {
// The same content again, with the same rectangle selected after it.
let st = app.session.active().unwrap();
let (doc, ids) = ((*st.doc).clone(), st.selection.objects.clone());
assert!(app.session.replace_document(0, doc));
app.run("select.set", json!({"ids": ids.iter().map(|id| id.0).collect::<Vec<_>>()})).unwrap();
}),
("another document became active", |app| {
app.run("document.activate", json!({"index": 1})).unwrap();
}),
];
// The angle of the rectangle in each open document, in whole degrees, and the index of the active document.
let angles = |p: &Panel| -> (Vec<Option<i64>>, Option<usize>) {
let app = p.app();
let docs = app.session.documents();
let angles = docs.iter().map(|st| st.doc.node(st.selection.objects[0]).and_then(|n| n.live_shape()?.shape_angle()).map(|a| a.round() as i64));
let active = app.session.active().map(|a| a.uid);
(angles.collect(), docs.iter().position(|st| Some(st.uid) == active))
};
for (change, apply) in changes {
let mut app = VectorcraftApp::new(vectorcraft_engine::Session::new(), Default::default());
for _ in 0..2 {
app.run("file.new", json!({"width": 400, "height": 400})).unwrap();
let id = app.run("shape.rectangle", json!({"x": 0, "y": 0, "width": 30, "height": 30})).unwrap()["id"].clone();
app.run("select.set", json!({"ids": [id]})).unwrap();
}
app.run("document.activate", json!({"index": 0})).unwrap();
let mut p = Panel::new(app, crate::panels::transform::show);
p.click_role("Angle", Role::SPIN_BUTTON);
p.key(Key::A, Modifiers::COMMAND);
p.type_text("3+");
apply(&mut p.app());
p.frame();
assert_eq!(p.value_role("Angle", Role::SPIN_BUTTON).as_deref(), Some("0°"), "{change}: the field shows the rectangle's angle");
p.type_text("7");
p.key(Key::Enter, Modifiers::NONE);
let (got, active) = angles(&p);
let active = active.unwrap();
let mut want = vec![Some(0), Some(0)];
want[active] = Some(7);
assert_eq!(got, want, "{change}: the rectangle takes 7°, not the unfinished 3+ and 7");
}
}
/// While the selection stays the same, a value typed over several frames is kept and committed whole, also when an
/// edit to an unselected object changes the document in between.
#[test]
fn a_value_typed_with_the_same_selection_is_kept_across_frames() {
let (mut app, a, b) = rectangles();
app.run("select.set", json!({"ids": [a]})).unwrap();
let mut p = Panel::new(app, crate::panels::transform::show);
p.click_role("Angle", Role::SPIN_BUTTON);
p.key(Key::A, Modifiers::COMMAND);
p.type_text("3+");
p.frame();
let revision = p.app().session.active().unwrap().revision;
p.app().run("stroke.set", json!({"ids": [b], "weight": 4})).unwrap();
assert_ne!(p.app().session.active().unwrap().revision, revision, "the document changed");
p.frame();
p.type_text("7");
p.key(Key::Enter, Modifiers::NONE);
p.frame();
assert_eq!(p.value_role("Angle", Role::SPIN_BUTTON).as_deref(), Some("10°"), "3+7 is committed to the same rectangle");
}
/// An unfinished Sides value is dropped when selecting the star first replaces Sides with Points.
#[test]
fn an_unfinished_sides_count_does_not_reach_a_star_selected_first() {
let mut app = VectorcraftApp::new(vectorcraft_engine::Session::new(), Default::default());
app.run("file.new", json!({"width": 400, "height": 400})).unwrap();
let polygon = app.run("shape.polygon", json!({"cx": 60, "cy": 60, "radius": 40, "sides": 5})).unwrap()["id"].clone();
let star = app.run("shape.star", json!({"cx": 200, "cy": 60, "radius1": 40, "radius2": 20, "points": 5})).unwrap()["id"].clone();
app.run("select.set", json!({"ids": [polygon, star]})).unwrap();
let mut p = Panel::new(app, crate::panels::transform::show);
p.click_role("Sides", Role::SPIN_BUTTON);
p.key(Key::A, Modifiers::COMMAND);
p.type_text("3+");
p.app().run("select.set", json!({"ids": [star, polygon]})).unwrap();
p.frame();
assert_eq!(p.value_role("Points", Role::SPIN_BUTTON).as_deref(), Some("5"), "the field shows the star's points");
p.type_text("7");
p.key(Key::Enter, Modifiers::NONE);
p.frame();
assert_eq!(p.value_role("Points", Role::SPIN_BUTTON).as_deref(), Some("7"), "the star takes 7 points, not the unfinished 3+ and 7");
}
/// An Angle value typed across frames is kept when another corner of the same rectangle is Direct-Selected.
#[test]
fn a_value_typed_for_the_same_shape_is_kept_when_direct_selected_anchors_change() {
let (mut app, a, _) = rectangles();
let id = a.as_u64().unwrap();
app.run("select.anchors", json!({"id": id, "anchors": [[0, 0]], "mode": "set"})).unwrap();
let mut p = Panel::new(app, crate::panels::transform::show);
p.click_role("Angle", Role::SPIN_BUTTON);
p.key(Key::A, Modifiers::COMMAND);
p.type_text("3+");
p.app().run("select.anchors", json!({"id": id, "anchors": [[0, 2]], "mode": "set"})).unwrap();
p.frame();
p.type_text("7");
p.key(Key::Enter, Modifiers::NONE);
p.frame();
assert_eq!(p.value_role("Angle", Role::SPIN_BUTTON).as_deref(), Some("10°"), "3+7 is committed to the same rectangle");
}
+35
View File
@@ -744,6 +744,41 @@ mod tests {
assert_eq!(opacity_of(&panel, &b), 0.01, "Undo drops the unfinished value: 1%, not 20+1");
}
/// A canceled undo group drops an unfinished Opacity expression, though the object it takes away and the object
/// made and selected after it have the same id and opacity.
#[test]
fn unfinished_opacity_is_dropped_by_a_canceled_undo_group() {
let mut app = new_app();
run_cmd(&mut app, "edit.undoGroup.begin", json!({}));
let a = run_cmd(&mut app, "shape.rectangle", json!({"x": 0, "y": 0, "width": 30, "height": 30}))["id"].clone();
run_cmd(&mut app, "select.set", json!({"ids": [a]}));
let mut panel = Panel::new(app, show);
unfinished_opacity(&mut panel);
run_cmd(&mut panel.app(), "edit.undoGroup.end", json!({"cancel": true}));
let b = run_cmd(&mut panel.app(), "shape.rectangle", json!({"x": 50, "y": 0, "width": 30, "height": 30}))["id"].clone();
assert_eq!(b, a, "the new rectangle has the canceled group's rectangle's id");
run_cmd(&mut panel.app(), "select.set", json!({"ids": [b]}));
finish_opacity(&mut panel);
assert_eq!(opacity_of(&panel, &b), 0.01, "the canceled group drops the unfinished value: 1%, not 20+1");
}
/// Discard Empty Type drops an unfinished Opacity expression when it takes back the step that made the empty
/// text, though the object made and selected after it has the same id and opacity.
#[test]
fn unfinished_opacity_is_dropped_by_discard_empty_type() {
let mut app = new_app();
let a = run_cmd(&mut app, "text.create", json!({"x": 10, "y": 40, "text": ""}))["id"].clone();
run_cmd(&mut app, "select.set", json!({"ids": [a]}));
let mut panel = Panel::new(app, show);
unfinished_opacity(&mut panel);
run_cmd(&mut panel.app(), "text.discardEmpty", json!({"id": a}));
let b = run_cmd(&mut panel.app(), "shape.rectangle", json!({"x": 50, "y": 0, "width": 30, "height": 30}))["id"].clone();
assert_eq!(b, a, "the new rectangle has the discarded text's id");
run_cmd(&mut panel.app(), "select.set", json!({"ids": [b]}));
finish_opacity(&mut panel);
assert_eq!(opacity_of(&panel, &b), 0.01, "Discard Empty Type drops the unfinished value: 1%, not 20+1");
}
/// The same objects selected in another order keep an unfinished Opacity expression.
#[test]
fn unfinished_opacity_stays_when_the_same_objects_are_selected_in_another_order() {
+1 -1
View File
@@ -186,7 +186,7 @@ fn categories(app: &VectorcraftApp) -> impl Iterator<Item = &'static str> {
let _ = app;
None
};
PREF_CATEGORIES.iter().copied().chain(agents)
PREF_CATEGORIES.iter().copied().chain([crate::language_packs::PAGE]).chain(agents)
}
/// The agent settings as the AI Integrations page edits them; `None` where the window has no such page.
+16 -6
View File
@@ -380,15 +380,22 @@ impl Live<'_> {
impl PreferencesModel for Live<'_> {
fn pages(&self) -> Vec<PageSpec<'_>> {
let pages = PREF_CATEGORIES.iter().map(|&cat| self.page(cat));
let mut pages: Vec<PageSpec<'_>> = PREF_CATEGORIES.iter().map(|&cat| self.page(cat)).collect();
// Language Packs after Hyphenation: a page of its own, which installs and removes at once (nothing waits for
// OK, and there is nothing to reset).
let packs = PageSpec::custom(crate::language_packs::PAGE, tl!(crate::language_packs::PAGE))
.resettable(false)
.keywords(tl!("spelling dictionary hyphenation language download install remove"));
let at = pages.iter().position(|p| p.id == "Hyphenation").map_or(pages.len(), |i| i + 1);
pages.insert(at, packs);
// The agent settings, drawn whole by the framework's Agents page, on the desktop.
#[cfg(not(target_arch = "wasm32"))]
let pages = pages.chain(self.app.agents.is_some().then(|| {
if self.app.agents.is_some() {
use crate::agents::PAGE_TITLE;
let keywords = "agents AI MCP ArtCraft Launcher control port folders";
PageSpec::custom(PAGE_TITLE, tl!(PAGE_TITLE)).keywords(keywords).resettable(false)
}));
pages.collect()
pages.push(PageSpec::custom(PAGE_TITLE, tl!(PAGE_TITLE)).keywords(keywords).resettable(false));
}
pages
}
fn set(&mut self, key: &str, value: PrefValue) {
@@ -464,7 +471,10 @@ impl PreferencesModel for Live<'_> {
if page == crate::agents::PAGE_TITLE {
return agents_page(self, ui);
}
let _ = (ui, page);
if page == crate::language_packs::PAGE {
crate::language_packs::page(self.app, ui);
}
// Nothing of the draft changes: a pack installs or is removed at once.
false
}
+2 -1
View File
@@ -551,7 +551,7 @@ macOS cursor delivery (#2292) is narrowed to a native host adapter using the exi
- **Done:** COLR and SVG glyphs go with type that geometry effects reshape, into Expand Appearance and EMF/WMF
export, where the type's outlines used to leave them out; bitmap glyphs (emoji) too, as images that hold their
own pixels until a document takes them in; estimate unchanged.
- **Done:** spell check (#4936): engine (`text.spelling.check` and `text.spelling.suggest` on craft-proof); custom dictionary and Ignore All (`text.spelling.addWord`, `removeWord`, `changeWord`, `dictionary`, `ignoreAll`); Auto Spell Check (`edit.autoSpellCheck`) with red wavy underlines and canvas context menu suggestions, Ignore All and Add to Dictionary; Edit › Edit Custom Dictionary…; and modal Check Spelling dialog (Edit › Spelling › Check Spelling…, and Spelling › Check Spelling… in the canvas context menu of type, `ui.checkSpelling`) with sentence context, suggestions list, "Change to" edit, Ignore, Ignore All, Change, Change All, Add to Dictionary, Done, Cancel, and keyboard navigation; Language packs for languages other than English, read from the Craft apps' shared font store, with `proof.packs`, `proof.installPack` and `proof.removePack` (a Preferences page to install them and the missing-pack bar remain). Estimate unchanged.
- **Done:** spell check (#4936): engine (`text.spelling.check` and `text.spelling.suggest` on craft-proof); custom dictionary and Ignore All (`text.spelling.addWord`, `removeWord`, `changeWord`, `dictionary`, `ignoreAll`); Auto Spell Check (`edit.autoSpellCheck`) with red wavy underlines and canvas context menu suggestions, Ignore All and Add to Dictionary; Edit › Edit Custom Dictionary…; and modal Check Spelling dialog (Edit › Spelling › Check Spelling…, and Spelling › Check Spelling… in the canvas context menu of type, `ui.checkSpelling`) with sentence context, suggestions list, "Change to" edit, Ignore, Ignore All, Change, Change All, Add to Dictionary, Done, Cancel, and keyboard navigation; Language packs for languages other than English, read from the Craft apps' shared font store, with `proof.packs`, `proof.installPack` and `proof.removePack` ; Edit › Preferences › Language Packs lists them (size, what each provides, licence) with Install, Remove, progress and errors, and a dismissible bar over the canvas offers a pack when the downloaded list contains one for a document language without a dictionary (`proof.packs` `missing`); the person's own click turns downloading on, an injected one never does; the web build has no packs yet (craft-libs#745). Estimate unchanged.
- **Missing:** CJK vertical
composition (custom mojikumi sets and the Mojikumi Settings dialog), Middle Eastern
features beyond bidi, digit types, Character Direction and Kashidas (a split caret; the Middle Eastern & South Asian composers are done, #4935),
@@ -1069,6 +1069,7 @@ trap, and the defaults (0.25 pt, 100%, 40%) are VectorCraft's own, the pages giv
| Date | Change | Summary |
|---|---|---|
| 2026-12-02 | minor | G16: Web: Gujarati can be selected as the interface language; the web fetches Noto Sans Gujarati when the interface needs it (`crates/text/web-fonts.txt`, `demand`), as it does Noto Sans Devanagari for Hindi. Status/error messages remain partial. Scores and estimates unchanged. |
| 2026-12-02 | minor | G4 type: Language packs UI (#4936): Edit › Preferences › Language Packs lists the installed packs and the packs on the downloadable list (size, spelling, hyphenation, licence) with Install, Remove, progress and errors; a dismissible missing-pack bar over the canvas offers Install when the downloaded list has a pack for a document language without a dictionary, or Get Language Pack before the list is fetched; `proof.packs` reports `missing`; only the person's own click turns downloading on; not on the web (craft-libs#745); scores and estimates unchanged. |
| 2026-11-27 | minor | G4 type: Language packs (#4936): spelling and hyphenation read the packs installed in the Craft apps' shared font store, and `proof.packs`, `proof.installPack` and `proof.removePack` list, install and remove them (installs need downloading on, which only the person turns on); a Preferences page to install them and the missing-pack bar remain; scores and estimates unchanged. |
| 2026-11-24 | minor | G12: History row context menus use shared Craft List and Menu controls after rebasing onto the panel migration. App-specific actions retain the chosen snapshot across pending edits and dismiss on document switches; keyboard context requests and focus restoration use the shared runtime. Regression cases retained (#8845); scores and estimates unchanged. |
| 2026-11-23 | minor | Gradient stop editor: a compact Color-tab menu offers Grayscale Slider, RGB Sliders, HSB Sliders, CMYK Sliders and Web Color Sliders, sharing the Color panel mode and conversion behavior (#7918). Choosing a mode keeps the editor open; Escape closes the menu first. Scores and estimates unchanged. |
+5 -2
View File
@@ -15119,14 +15119,17 @@ installed packs; the web app has none, and no `proof.*` commands.
running (`installing`, with bytes `done` of `total`), whether the index is being fetched (`refreshing`), the last
failure of each locale (`errors`; `""` is the index fetch), whether downloading is on (`downloads`), a test index
used instead of the pinned one (`indexOverride`, from `CRAFT_LANGUAGE_PACK_INDEX`) and whether there is a store to
install into (`available`). `refresh: true` fetches the index again.
install into (`available`), and the languages of the front document's visible, unlocked type that have no
dictionary (`missing`: each `lang` with its pack's `locale`, `null` before the index is first fetched; a language the
fetched index has no pack for is left out). `refresh: true` fetches the index again.
- `proof.installPack {locale}` downloads a pack, checks its sha256 and installs it (fetching the index first when it
doesn't list the locale). Every open document is laid out and checked again with it. `locale` is the pack's tag,
like `nl` or `pt-br` (`pt_BR` reads as `pt-br`).
- `proof.removePack {locale}` removes an installed pack, not while it installs.
Installs and index fetches need downloading on. Only the person using a Craft app turns it on, with their own click
(the setting is the font store's, shared by the apps): no command turns it on, and until then an install is an error
(in VectorCraft: Install, Refresh List or Get Language Pack in Edit › Preferences › Language Packs, or in the bar over
the canvas that offers a missing language's pack; the setting is the font store's, shared by the apps): no command, and no click the control channel injects (`ui.click`), turns it on, and until then an install is an error
that says so. A caller with automation roots (`--automation-read-root`, `--automation-write-root`) can list packs
but not fetch, install or remove them, since the store is outside its roots. A script cannot run the `proof.*`
commands at all, since a run's rollback cannot put the store back. In the desktop app installs and fetches
+3 -2
View File
@@ -1,7 +1,7 @@
# Roadmap: milestones and what's next
> Status-bar snapping quick access (#8687, #8779): the bottom right offers Smart Guides, Snap to Point and Snap to Grid toggles plus the same live Snapping menu as the Control bar. Both use existing commands. Framework fit ranks omit the direct group first, then the dropdown, before the existing readouts or core status content narrow. The native buttons expose their current selected state. Scores and estimates are unchanged.
> **Last reviewed:** 2026-10-10 · **Last updated:** 2026-11-29 · **Change:** minor (M2: Smart Guides: in a document with more than 20,000 anchors, the snap targets are gathered topmost first, so the objects in front, the newest, keep their anchors, edges and centre as targets for ruler guides, moves, scaling and drawing (#8531); scores and estimates unchanged; previously: M4: `.ai` import: type whose font record keeps no version is set in the installed copy of its font that sets the characters at the widths the file's PDF part gives them (its first 512 characters; without those widths, or with no copy that sets them all, the pick is the one before), #8087; scores and estimates unchanged; previously: G12: History row menus adapted to shared Craft list/menu controls after rebase (#8845); scores and estimates unchanged; previously: G12/M14: History row context menus, pending-edit snapshot targeting, keyboard access and document-switch dismissal (#8845); scores and estimates unchanged; previously: G12: Asset Export tile context menus; scores and estimates unchanged; previously: M14/G12: Appearance panel row context menus, #8809; previously: M1: Layers: a targeted item with an appearance of its own keeps its inner ring visible around a smaller appearance dot, so the target circle's four looks differ, #8711; scores and estimates unchanged; previously: M11: 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, #8363; scores and estimates unchanged; previously: Scissors shows the actual proposed cut point while hovering, using its existing snapping and cut target (#8655); scores and estimates unchanged; previously: 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; previously: Image Trace Ignore Color keeps the canvas View and stays armed on a missed pixel (#8068); M11: a tool drag held near an edge of the canvas scrolls the view, #8551; scores and estimates unchanged; previously: All Tools drawer: a tool the toolbar holds is dimmed in the readable dim text colour, not the disabled colour that was unreadable against the panel, and a hovered dimmed row takes the panel's darker fill so it stays readable, #8294; scores and estimates unchanged; previously: Layers: selected guide rows stay highlighted after the pointer leaves (#7344); scores and estimates unchanged; previously: M4: PDF import: type filled and stroked after a page of type filled only comes in filled and stroked, #8549 follow-up; scores and estimates unchanged; previously: selected Dimension extension-line color and weight in Properties (#7078; four focused UI regressions passed); scores and estimates unchanged; previously: Brush Options Key Color: restore canvas input for the existing one-shot pick, then resume the retained draft and previous tool (#8284; six full-app input regressions passed); scores and estimates unchanged; previously: M4: `.ai` and EPS import: an Art brush in Tints of a swatch-linked stroke color comes in brushed, #8200; scores and estimates unchanged; previously: Ellipse: Up/Down changes Anchors while drawing (#7840); scores and estimates unchanged; previously: Windows/Linux menu access keys and localized cues (#6596); previously: Backquote/~ arrow pattern nudges (#7717); scores and estimates unchanged; previously: Window > Toolbars > Compact Tools offers optional denser main Tools spacing (#7234); default layout, scores and estimates unchanged; previously: Direct Selection: Space during an ordinary path's handle drag repositions its anchor and handles, including a Pen loan (#7237, request 3 only; scores and estimates unchanged); previously: M4: `.ai` and EPS import: clipping paths grouped in a compound path are its subpaths, #8128; scores and estimates unchanged; previously: import: type filled and stroked by a `TJ` whose kerning starts a new line comes in filled and stroked, #8543; PDF Retype phase 1 (#4934): Type › Retype (`type.retype`) turns outlined text that exactly matches an available font back into point text; scores and estimates unchanged; previously: 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 gLine truncated
> **Last reviewed:** 2026-10-10 · **Last updated:** 2026-11-29 · **Change:** minor (M2: Draw Inside keeps the object it draws into as the clip group's clipping path with its fill and stroke, so its stroke stays whole over the art drawn inside it, #8753; scores and estimates unchanged; previously: M2: Smart Guides: in a document with more than 20,000 anchors, the snap targets are gathered topmost first, so the objects in front, the newest, keep their anchors, edges and centre as targets for ruler guides, moves, scaling and drawing (#8531); scores and estimates unchanged; previously: M4: `.ai` import: type whose font record keeps no version is set in the installed copy of its font that sets the characters at the widths the file's PDF part gives them (its first 512 characters; without those widths, or with no copy that sets them all, the pick is the one before), #8087; scores and estimates unchanged; previously: G12: History row menus adapted to shared Craft list/menu controls after rebase (#8845); scores and estimates unchanged; previously: G12/M14: History row context menus, pending-edit snapshot targeting, keyboard access and document-switch dismissal (#8845); scores and estimates unchanged; previously: G12: Asset Export tile context menus; scores and estimates unchanged; previously: M14/G12: Appearance panel row context menus, #8809; previously: M1: Layers: a targeted item with an appearance of its own keeps its inner ring visible around a smaller appearance dot, so the target circle's four looks differ, #8711; scores and estimates unchanged; previously: M11: 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, #8363; scores and estimates unchanged; previously: Scissors shows the actual proposed cut point while hovering, using its existing snapping and cut target (#8655); scores and estimates unchanged; previously: 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; previously: Image Trace Ignore Color keeps the canvas View and stays armed on a missed pixel (#8068); M11: a tool drag held near an edge of the canvas scrolls the view, #8551; scores and estimates unchanged; previously: All Tools drawer: a tool the toolbar holds is dimmed in the readable dim text colour, not the disabled colour that was unreadable against the panel, and a hovered dimmed row takes the panel's darker fill so it stays readable, #8294; scores and estimates unchanged; previously: Layers: selected guide rows stay highlighted after the pointer leaves (#7344); scores and estimates unchanged; previously: M4: PDF import: type filled and stroked after a page of type filled only comes in filled and stroked, #8549 follow-up; scores and estimates unchanged; previously: selected Dimension extension-line color and weight in Properties (#7078; four focused UI regressions passed); scores and estimates unchanged; previously: Brush Options Key Color: restore canvas input for the existing one-shot pick, then resume the retained draft and previous tool (#8284; six full-app input regressions passed); scores and estimates unchanged; previously: M4: `.ai` and EPS import: an Art brush in Tints of a swatch-linked stroke color comes in brushed, #8200; scores and estimates unchanged; previously: Ellipse: Up/Down changes Anchors while drawing (#7840); scores and estimates unchanged; previously: Windows/Linux menu access keys and localized cues (#6596); previously: Backquote/~ arrow pattern nudges (#7717); scores and estimates unchanged; previously: Window > Toolbars > Compact Tools offers optional denser main Tools spacing (#7234); default layout, scores and estimates unchanged; previously: Direct Selection: Space during an ordinary path's handle drag repositions its anchor and handles, including a Pen loan (#7237, request 3 only; scores and estimates unchanged); previously: M4: `.ai` and EPS import: clipping paths grouped in a compound path are its subpaths, #8128; scores and estimates unchanged; previously: import: type filled and stroked by a `TJ` whose kerning starts a new line comes in filled and stroked, #8543; PDF Retype phase 1 (#4934): Type › Retype (`type.retype`) turns outlined text that exactly matches an available font back into point text; scores and estimates unchanged; previously: 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 Line truncated
> Panel readout copy (#8432, #8826): Info values and paint names, Links information, and named Document Info rows with no separate value follow the guarded immediate-copy policy landed in #9353. A plain first click copies the full value and reports "Copied the value"; accessible activation copies it too. Selectable readouts retain word selection on double-click, Shift/drag selection and keyboard Copy/Cut. Links Location retains #9521's path fitting and full-path tooltip as static text, with the same full-value primary/accessible copy and a native Copy Location button for keyboard use. Scores and estimates are unchanged.
@@ -197,7 +197,7 @@ Gujarati interface follow-up (2026-11-14): the catalog and zero/one plural rule
|---|---|---|---|
| M0 | Skeleton + vertical slice | ✅ done | — |
| M1 | Selection, transform, layers, MCP (common command tools, strict keys, session resources and version-aware result hints) | ✅ mostly done (a targeted Layers item with an appearance of its own shows its inner ring around a smaller appearance dot (#8711); path and compound-path interior selection follows enabled fill rows (#6625); a marquee leaves locked or hidden guide paths out inside groups, as clicks do (#8538); hidden-fill and no-fill stroke cap/join CPU regressions passed; document-tab artwork drag with lossless resource transfer and one target Undo; malformed MCP app replies discard the connection without replay, #1761; bounded control socket waits and connection-slot recovery, #1726; bounded synthetic control input, #1709; no-op anchor Align keeps Undo, Redo and saved state (#1180 follow-up); transform reference point snaps to anchors/centres; rotated objects keep a rotated bounding box and their angle; Free Transform, Scale and Reflect along a rotated box pending; the Transform fields take one Tab each, the W/H link after them); Layers own appearance has a hollow diamond and tooltip distinct from targeting/selection (#8710), retaining Hassan1305's #8757 ring-visibility fix; validation pending | 4–6 |
| M2 | Drawing tools + smart guides | ✅ mostly done (Eraser preserves fill outside fixed and varied tip sweeps and Alt-drag marquees on fill-only open paths and keeps their compound holes; clipping masks retain surviving contours or empty geometry in the same node; ordinary Group/Layer paints and evaluated gradient placements are preserved when the stored paint reproduces their appearance; hidden Rasterize and Along/Across stroke rows do not block visible gradients; replacement-art effects, plug-ins/Rasterize, along/across-stroke gradients and placements that cannot be reproduced keep their existing fitting; stroked open paths retain main behavior (#6582); #3380 deletion creates independent selected path pieces and keeps bounds-fitted gradients in place; endpoint highlighting remains open; Polygon/Star exact-size count persistence, with repeated-drag, tool-switch and Cancel regression coverage; Curvature point markers without direction handles (#1236, in part); Direct Selection segment click/Delete preserves neighboring edges, #1278; Flare, Reshape, Live Corners widget dragging and per-corner radii and kinds landed, on any path's corners; Shaper rough-shape recognition and orientation steps, the remaining Pen modifier nuances; Shaper Groups with editable sources and separate fill/stroke edits landed; custom ruler origin with drag preview, active-artboard reset, relative X/Y fields and native round-trip (#1212); construction widget/refinements pending); a shape just drawn moves by its centre point and turns from the zone outside a corner with its tool still active (#5477); Tangent and straight-segment perpendicular snapping use saved Smart Guides Geometric Guides preferences and Control bar quick access (#2537), including the existing Snap to Glyph and Alignment Guides toggles (#6164); View › Snapping consolidates five existing toggles and Pixel Snapping Options…, retaining top-level entries and shortcuts (G13); Copy and Cut with the Pen or Curvature tool take the anchors a Cmd/Ctrl-lent Direct Selection picked (#6123); Scissors hover and cuts use the Pen's path/align/intersect/anchor snaps, with Alt Add Anchor and cut endpoint selection retained (#6470); Scissors previews the current anchor or curve cut point (#8655); in a document with more than 20,000 anchors the topmost, newest objects keep their Smart Guides targets (#8531) | 12–18 |
| M2 | Drawing tools + smart guides | ✅ mostly done (Eraser preserves fill outside fixed and varied tip sweeps and Alt-drag marquees on fill-only open paths and keeps their compound holes; clipping masks retain surviving contours or empty geometry in the same node; ordinary Group/Layer paints and evaluated gradient placements are preserved when the stored paint reproduces their appearance; hidden Rasterize and Along/Across stroke rows do not block visible gradients; replacement-art effects, plug-ins/Rasterize, along/across-stroke gradients and placements that cannot be reproduced keep their existing fitting; stroked open paths retain main behavior (#6582); #3380 deletion creates independent selected path pieces and keeps bounds-fitted gradients in place; endpoint highlighting remains open; Polygon/Star exact-size count persistence, with repeated-drag, tool-switch and Cancel regression coverage; Curvature point markers without direction handles (#1236, in part); Direct Selection segment click/Delete preserves neighboring edges, #1278; Flare, Reshape, Live Corners widget dragging and per-corner radii and kinds landed, on any path's corners; Shaper rough-shape recognition and orientation steps, the remaining Pen modifier nuances; Shaper Groups with editable sources and separate fill/stroke edits landed; custom ruler origin with drag preview, active-artboard reset, relative X/Y fields and native round-trip (#1212); construction widget/refinements pending); a shape just drawn moves by its centre point and turns from the zone outside a corner with its tool still active (#5477); Tangent and straight-segment perpendicular snapping use saved Smart Guides Geometric Guides preferences and Control bar quick access (#2537), including the existing Snap to Glyph and Alignment Guides toggles (#6164); View › Snapping consolidates five existing toggles and Pixel Snapping Options…, retaining top-level entries and shortcuts (G13); Copy and Cut with the Pen or Curvature tool take the anchors a Cmd/Ctrl-lent Direct Selection picked (#6123); Scissors hover and cuts use the Pen's path/align/intersect/anchor snaps, with Alt Add Anchor and cut endpoint selection retained (#6470); Scissors previews the current anchor or curve cut point (#8655); in a document with more than 20,000 anchors the topmost, newest objects keep their Smart Guides targets (#8531); Draw Inside keeps the object it draws into, with its fill and stroke, as the clipping path (#8753) | 12–18 |
| M3 | Paint & appearance (swatches, color, gradient, stroke, appearance, transparency, styles) | ✅ done (M3.7–M3.98): swatches, groups, libraries, tints, Lab spots and Registration; Eyedropper copies transformed character dimensions (#6404) and styles highlighted text only (atomic transparency rejection); Eyedropper reads visible locked and outside-isolation sources (#1251); Color Picker, Color panel (its spectrum grows with a resized panel, #8005), Color Guide, Color Themes, Edit Colors and Recolor Artwork (screen-bounded Edit chip list, #3416; native Lab entry and swatch libraries in the picker, Assign-row menus, #8031/#4028; Recolor with Preset asks whether to limit the colors to a swatch library first); gradients that follow every transform, the annotator, linked stops, freeform gradients, focal points, gradients on strokes and Expand; visible strokes when paint is added to inherited None/zero-width art (#1253); stroke geometry, arrowheads, dashes fitted to corners, stroke on type, width profiles and the Width tool (Shift-double-click enables adjoining adjustment in Width Point Edit; finite-arithmetic follow-up regressions and full CI passed ([Validation evidence](target-app-parity.md#evidence-what-ships-today-by-area))), Scale Strokes and preview bounds; Appearance targeting, container appearance, target circles, Expand Appearance; knockout, isolation, blend accuracy, CMYK blending, overprint, Attributes, masks and clipping, Flatten Transparency; graphic styles, links and libraries; CSS library export preserves fractional linear and radial gradient stop positions. Left: freeform gradients in SVG/PDF, mixed spot/process gradients in SVG and PDF gradients mixing a spot color with RGB or Lab stops export as stops or process colors; PDF export writes dithered gradient fills with spot stops, and Perceptual spot gradients with RGB or Lab stops other than white or more than 4,096 stops on their curve, as images in process colors; confirm the Scale Strokes & Effects default; Recolor model selection is available through the engine and MCP only (#2520); the dialog retains its existing controls; Library panels' lists (swatch, Color Book, brush, symbol and graphic style libraries) fill a taller panel above its footer (#2992; scores and estimates unchanged); Graphic Styles list fills a taller panel above its footer (#2992; scores and estimates unchanged); Swatches list fills a taller panel above its footer (#1638; `the_list_fills_a_tall_panel_above_its_footer`; scores and estimates unchanged); the stop editor offers the five Color panel modes (#7918); native port validation pending | 4–8 |
| M4 | Files (native, SVG, PDF, raster, Export for Screens, clipboard interop) | DWG import: DWG drawings open and place through the DXF reader (#10802; estimates unchanged); DWG export: Export As → DWG writes the DXF export's drawing as DWG 2000 to 2018 (estimates unchanged); `.ai` import: type takes the installed copy of its font that sets its PDF part's widths (#8087; estimates unchanged); `.ai` and EPS import: clipping paths grouped in a compound path are its subpaths (#8128; estimates unchanged); Production Preflight checks fonts, overflow, links and image resolution with clickable findings and automatic rechecking (VectorCraft addition; estimates unchanged); PDF import: a glyph filled only after a glyph filled and stroked comes in filled only, not stroked (#8300; estimates unchanged); PDF import: type filled and stroked by one text-showing operator comes in as one filled and stroked type object (#8015; not for type filled and stroked at less than full opacity, which still comes in as a filled object and a stroked one, as the file composites them; estimates unchanged); PDF import: type filled and stroked by a `TJ` whose kerning starts a new line part way through comes in filled and stroked, a type object for each part, also where it draws a glyph again where it drew one, in an `ActualText` span too, where it stays one replacement type object on the first glyph's line and in its style; a `TJ` over more than 65 lines (the 64 its fill pass finished, kept back, and the open one) stays a filled object and a stroked one for each part (#8543; estimates unchanged); PDF import: type filled and stroked after a page of type filled only (more than 64 lines) comes in as one filled and stroked type object again, with or without a path between, and a `TJ` over more lines than are kept with a glyph kept as an outline still stays a filled object and a stroked one for each part (#8549 follow-up; estimates unchanged); PDF import: stroked type keeps the file's line cap, line join and miter limit (#7741; estimates unchanged); Rename artboards in Export for Screens (#7275); Explicit editing-data import keeps oversized capped-page artboards (#6865; estimates unchanged); Save refusal continuation (#6146): ordinary Save offers Save As; unchanged format keeps options, changed format opens its Save options; cancellation/automation isolation; focused UI regressions passed, native acceptance pending; PDF authored ActualText preserved once in editable import (#6165; first-glyph line/style, bounded input; estimates unchanged); PDF export keeps harakat and zero-advance Noto Arabic dot glyphs in one compatible batch per layout line, with per-glyph vertical offsets (#6309). `crates/pdf/src/tests/realtext.rs` (`mark_text_*`) checks decoded cluster mappings, mixed Arabic/Latin/digits, contour placement against outline export, vertical columns, differing path rotations and PDF/X-1a/3/4. Editable-text import preserves authored ActualText separately (#6165), with cross-line/style layout limits; separately styled or differently rotated clusters and external viewer search/copy remain outside this export-only evidence. `.ai`/EPS type from the text document keeps its paragraphs' tab stops (#6147); `.ai`/EPS type from the text document keeps auto leading per line, its hyphenation options, and may show more of the last lines the file sets in an area frame of its own, when growing the frame by its lines' deepest descent plus 0.05 pt shows them (#6137); ✅ done (M4.14–M4.98 on 2026-10-05): Save As/Save a Copy/Revert/templates, Data Recovery and background save, SVG import and export fidelity (units, text, symbols, filters, SVGZ, Preserve Editing, SVG Options), shared guarded PDF writer and windowed reader ([pdf-backend.md](pdf-backend.md)), PDF import (colours, layers, masks, editable text, security) and export (presets, marks, bleed, ICC and output intent, raster effects, subset fonts, PDF/X-1a, X-3 and X-4, PDF layers, overprint, page thumbnails, fast web view, PDF 1.3), Place and Links, Package, EPS and DXF in and out (EPS legacy mesh corners, vector opacity masks and raster page comparison verified; closed SPLINE flags round-trip and circular paths export as native CIRCLE/ARC, #1299), EMF/WMF, TIFF/BMP/Targa/PSD/GIF/PNG-8 export, Print and print presets, slices, Save for Web, TIFF in Export for Screens and Asset Export, clipboard flavours, File Info; AF.1–AF.4 add Affinity import (native layers, artboards, vectors, text and images from Affinity 1–3 files; the embedded preview only as a warned fallback; AF.4 expands current `.af` fixtures and every-board round-trip validation); EPS Save and Save As keep an opened EPS as EPS with its page frame and complete editable VectorCraft document (2026-10-26; G9 import fidelity unchanged). Left: DWG export as R13 and R14, PSD placement as layers, overprint read back from PDF, Affinity export, polish; View and Links controls and command access for transient missing-link canvas markers (#5547); SVGLine truncated
| M5 | Performance | 🟡 background render + caches + MT done; text thread overlays index repeated selection lookups, keeping the first lookup and singleton selections direct (#6543); `vectorcraft-cli bench` and `vectorcraft-cli perf` (budget suite); opaque solid-fill knockout paths draw once in hard-edge/supersampled raster export, with analytical-AA compositing unchanged; file format v2 opens 3× faster (50k paths: 722 → 244 ms); raster effects (glows, shadows, blur, feather) no longer force the whole frame single-threaded (filtered offscreen per effect, verified equal to the single-threaded reference); Craquelure/Mosaic Tiles/Stained Glass distance searches optimized with pixel-invariance checks and the `texture_drag_perf` probe (#1257); effect-heavy demos need a clean-machine benchmark; in the web build an edit while the view of a heavy document moves draws only the part it changed into the last frame (#8688); dirty-region rendering, GPU backend spike pending | 15–25 |
@@ -262,6 +262,7 @@ not take the artwork yet. Overflow-menu drag remains separate. Scores and hours
| 2026-11-21 | minor | G13: View › Snapping groups five existing toggles and Pixel Snapping Options…; top-level commands and shortcuts remain; headless click/checkmark coverage added; scores and estimates unchanged. |
| 2026-11-21 | minor | G12: Properties Quick Actions offer Ungroup when any selected object is a group, Isolate Group only for one group, and Unite only for selections of at least two objects, each a non-guide path or a compound path. Headless regressions: `panels::properties::tests::two_groups_offer_ungroup_without_isolate_group`, `one_group_offers_ungroup_and_isolate_group`, `several_paths_offer_group_clipping_mask_and_unite`. Scores and estimates unchanged. |
| 2026-11-21 | minor | G12/M14: History row context menus retain the chosen snapshot while the menu is open and pending edits settle; jumps settle typing before counting undo/redo, and discarded states report that they are unavailable. Shift+F10 opens the focused row menu, Escape restores row focus, and switching documents dismisses the popup. History checklist, area and milestone evidence updated (#8845); scores and estimates unchanged. |
| 2026-11-20 | minor | M2: Draw Inside makes the object it draws into the clip group's clipping path, keeping its fill and stroke, instead of clipping by an unpainted copy of it: its centred stroke is no longer clipped by its own outline and paints over the art drawn inside it ([drawing modes](https://helpx.adobe.com/illustrator/desktop/draw-shapes-and-paths/learn-drawing-basics/drawing-modes-overview.html), [archived](https://web.archive.org/web/20261111110310/https://helpx.adobe.com/illustrator/desktop/draw-shapes-and-paths/learn-drawing-basics/drawing-modes-overview.html)) (#8753). Scores and estimates unchanged. |
| 2026-11-20 | minor | M2: Smart Guides: in a document with more than 20,000 anchors, the snap targets are gathered topmost first, so the objects in front, the newest, keep their anchors, edges and centre as targets for ruler guides, moves, scaling and drawing (#8531). Scores and estimates unchanged. |
| 2026-11-20 | minor | Color conversion indexes global swatch bases and linked-paint lookups (#8804); scores, estimates and measured budgets unchanged. |
| 2026-11-20 | minor | G12: Asset Export tiles have item context menus for Export, Remove, Rename, Select Artwork on Canvas and collecting selected artwork; right-click selects an unselected tile and preserves an existing multi-selection. Headless regressions: panels::tests_asset_export. Scores and estimates unchanged. |
+3 -2
View File
@@ -3,7 +3,7 @@
Native saves on Unix flush the destination directory after writing or replacing a file. If the directory cannot be flushed, the save returns an error stating that the file was written.
> Status-bar snapping quick access (#8687, #8779): the bottom right offers Smart Guides, Snap to Point and Snap to Grid toggles plus the same live Snapping menu as the Control bar. Both use existing commands. Framework fit ranks omit the direct group first, then the dropdown, before the existing readouts or core status content narrow. The native buttons expose their current selected state. Scores and estimates are unchanged.
> **Last reviewed:** 2026-10-10 · **Last updated:** 2026-11-29 · **Change:** minor (Smart Guides: in a document with more than 20,000 anchors, the snap targets are gathered topmost first, so the objects in front, the newest, keep their anchors, edges and centre as targets for ruler guides, moves, scaling and drawing (#8531); scores and estimates unchanged; previously: `.ai` import: type whose font record keeps no version is set in the installed copy of its font that sets the characters at the widths the file's PDF part gives them (its first 512 characters; without those widths, or with no copy that sets them all, the pick is the one before), follows #6983; scores and estimates unchanged; previously: Essentials readiness row: Shape Builder item names its remaining depth, #937's fix unconfirmed on the reporter's file, #8314; scores and estimates unchanged; previously: G12: History row context menus use shared Craft controls, snapshot targeting, keyboard access and document-switch dismissal (#8845); scores and estimates unchanged; previously: G12: Document Info Selection Only counts the selection, and with no artwork selected it shows (No artwork selected) and artboards the Artboard tool has selected still show; scores and estimates unchanged; previously: Pencil Edit Selected Paths follows lifted strokes, carves, loops, closes and redraws compound paths; Layers: a targeted item with an appearance of its own keeps its inner ring visible around a smaller appearance dot, so the target circle's four looks differ, #8711; scores and estimates unchanged; previously: G12: Asset Export tile context menus; scores and estimates unchanged; previously: M14/G12: Appearance panel: right-click item context menus for rows (Duplicate, Delete, Hide/Show, Edit Effect, Clear Appearance, Reduce to Basic Appearance) with selection handling, #8809; previously: Text styles panel: right-click item context menus for Character Styles and Paragraph Styles with Options, Duplicate, Delete, Redefine, Clear Overrides; scores and estimates unchanged; previously: 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; previously: Layers: a targeted item with an appearance of its own keeps its inner ring visible around a smaller appearance dot, so the target circle's four looks differ, #8711; scores and estimates unchanged; previously: 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, #8363; scores and estimates unchanged; previously: Scissors shows the actual proposed cut point while hovering, using its existing snapping and cut target (#8655); scores and estimates unchanged; previously: G12: Brushes panel: item right-click context menu (Brush Options, Duplicate Brush, Delete Brush) with selection handling; scores and estimates unchanged; previously: Graphic Styles panel: right-click item context menu for tiles and rows with Options, Duplicate, Delete, Redefine, Break Link; scores and estimates unchanged; previously: 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, and edits that go on once the view is still don't put off its render (#8688); scores and estimates unchanged; previously: G12: Links panel row context menu (Relink…, Go To Link, Update Link, Edit Original, Show in Folder, Embed Image / Unembed…) with selection handling; scores and estimates unchanged; previously: Artboard tool: Shift held once a move or Alt-copy drag is under way keeps it to the level, upright or 45° line, #8580; scores and estimates unchanged; previously: Image Trace Ignore Color keeps the canvas View and stays armed on a missed pixel (#8068); a tool drag held near an edge of the canvas scrolls the view, #8551; scores and estimates unchanged; previously: G12: Place: show progress window with Cancel for slow placed files exceeding 0.4 s, part of #5930; scores and estimates unchanged; previously: All Tools drawer: a tool the toolbar holds is dimmed in the readable dim text colour, not the disabled colour that was unreadable against the panel, and a hovered dimmed row takes the panel's darker fill so it stays readable, #8294; scores and estimates unchanged; previously: Layers: selected guide rows stay highlighted after the pointer leaves (#7344); scores and estimates unchanged; previously: PDF import: type filled and stroked after a page of type filled only comes in filled and stroked, #8549 follow-up; scores and estimates unchanged; previoLine truncated
> **Last reviewed:** 2026-10-10 · **Last updated:** 2026-11-29 · **Change:** minor (Draw Inside keeps the object it draws into as the clip group's clipping path with its fill and stroke, so its stroke stays whole over the art drawn inside it, #8753; scores and estimates unchanged; previously: Smart Guides: in a document with more than 20,000 anchors, the snap targets are gathered topmost first, so the objects in front, the newest, keep their anchors, edges and centre as targets for ruler guides, moves, scaling and drawing (#8531); scores and estimates unchanged; previously: `.ai` import: type whose font record keeps no version is set in the installed copy of its font that sets the characters at the widths the file's PDF part gives them (its first 512 characters; without those widths, or with no copy that sets them all, the pick is the one before), follows #6983; scores and estimates unchanged; previously: Essentials readiness row: Shape Builder item names its remaining depth, #937's fix unconfirmed on the reporter's file, #8314; scores and estimates unchanged; previously: G12: History row context menus use shared Craft controls, snapshot targeting, keyboard access and document-switch dismissal (#8845); scores and estimates unchanged; previously: G12: Document Info Selection Only counts the selection, and with no artwork selected it shows (No artwork selected) and artboards the Artboard tool has selected still show; scores and estimates unchanged; previously: Pencil Edit Selected Paths follows lifted strokes, carves, loops, closes and redraws compound paths; Layers: a targeted item with an appearance of its own keeps its inner ring visible around a smaller appearance dot, so the target circle's four looks differ, #8711; scores and estimates unchanged; previously: G12: Asset Export tile context menus; scores and estimates unchanged; previously: M14/G12: Appearance panel: right-click item context menus for rows (Duplicate, Delete, Hide/Show, Edit Effect, Clear Appearance, Reduce to Basic Appearance) with selection handling, #8809; previously: Text styles panel: right-click item context menus for Character Styles and Paragraph Styles with Options, Duplicate, Delete, Redefine, Clear Overrides; scores and estimates unchanged; previously: 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; previously: Layers: a targeted item with an appearance of its own keeps its inner ring visible around a smaller appearance dot, so the target circle's four looks differ, #8711; scores and estimates unchanged; previously: 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, #8363; scores and estimates unchanged; previously: Scissors shows the actual proposed cut point while hovering, using its existing snapping and cut target (#8655); scores and estimates unchanged; previously: G12: Brushes panel: item right-click context menu (Brush Options, Duplicate Brush, Delete Brush) with selection handling; scores and estimates unchanged; previously: Graphic Styles panel: right-click item context menu for tiles and rows with Options, Duplicate, Delete, Redefine, Break Link; scores and estimates unchanged; previously: 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, and edits that go on once the view is still don't put off its render (#8688); scores and estimates unchanged; previously: G12: Links panel row context menu (Relink…, Go To Link, Update Link, Edit Original, Show in Folder, Embed Image / Unembed…) with selection handling; scores and estimates unchanged; previously: Artboard tool: Shift held once a move or Alt-copy drag is under way keeps it to the level, upright or 45° line, #8580; scores and estimates unchanged; previously: Image Trace Ignore Color keeps the canvas View and stays armed on a missed pixel (#8068); a tool drag held near an edge of the canvas scrolls the view, #8551; scores and estimates unchanged; previously: G12: Place: show progress window with Cancel for slow placed files exceeding 0.4 s, part of #5930; scores and estimates unchanged; previously: All Tools drawer: a tool the toolbar holds is dimmed in the readable dim text colour, not the disabled colour that was unreadable against the panel, and a hovered dimmed row takes the panel's darker fill so it stays readable, #8294; scores and estimates unchanged; previously: Layers: selected guide rows stay highlighted after the pointer leaLine truncated
> Panel readout copy (#8432, #8826): Info values and paint names, Links information, and named Document Info rows with no separate value follow the guarded immediate-copy policy landed in #9353. A plain first click copies the full value and reports "Copied the value"; accessible activation copies it too. Selectable readouts retain word selection on double-click, Shift/drag selection and keyboard Copy/Cut. Links Location retains #9521's path fitting and full-path tooltip as static text, with the same full-value primary/accessible copy and a native Copy Location button for keyboard use. Scores and estimates are unchanged.
>
@@ -1592,7 +1592,7 @@ Moved from the ROADMAP's "Shipped so far" on 2026-10-10. Update it when a featur
- **Compound paths:** Make keeps the backmost object's appearance and each contour; selecting a member in Direct Selection reads and changes the compound's fill rule in Attributes. Direction remains a per-member edit. Rendered holes, unchanged contour geometry, no-op history and Undo/Redo are covered by `engine/tests/it/compound_attributes.rs` (#1197). Behaviour reference: [public compound-path documentation](https://helpx.adobe.com/illustrator/desktop/manage-objects/reshape-transform-objects/create-compound-paths.html). Make Compound Path on a group (such as outlined type) keeps the paint of its backmost path instead of drawing nothing, and compound paths joined into one keep their holes (#1537).
- **Saved selections:** Select ▸ Save Selection… asks for a name and keeps the selection in the document (saved with the file, undoable, up to 25); each one is listed at the bottom of the Select menu and a click selects its objects again; Edit Selection… lists them to rename or delete, applied together on OK. A file's saved selections are capped and checked against its objects when it opens.
Select ▸ Update Selection replaces the objects of the saved selection last recalled with the selected objects, in one undo step that marks the document changed (`select.update`). After Edit Selection… renames that saved selection, Update Selection replaces it under the new name; after Edit Selection… deletes it, Update Selection is disabled until another saved selection is recalled or the delete is undone. Undo and Redo do not change which saved selection is recalled.
- **Drawing modes:** in Draw Inside, a double-click with a selection tool outside the object being drawn into sets the drawing mode to Draw Normal, as Shift+D does. Pastes follow the drawing mode ([drawing modes](https://helpx.adobe.com/illustrator/desktop/draw-shapes-and-paths/learn-drawing-basics/drawing-modes-overview.html)) (#3705): in Draw Inside, Paste, Paste in Place and Paste on All Artboards put the copies inside the object drawn into, in one undo step, Paste Remembers Layers aside; in Draw Behind, Paste in Place and Paste on All Artboards put them just below the selection; Paste in Front and Paste in Back ignore the mode. Shift+D cycles Draw Normal → Draw Behind → Draw Inside → Draw Normal, skipping Draw Inside unless one path, compound path or type is selected. With the object drawn into isolated (a double-click on it with the Selection tool), art drawn or pasted inside it takes isolation mode into its clip group, so it can be clicked and isn't dimmed, as art added in isolation mode belongs with what is isolated ([isolation mode](https://helpx.adobe.com/illustrator/desktop/manage-objects/select-objects/isolate-objects.html)) (#3705); undo or redo that removes the isolated object ends isolation mode. While Draw Inside lasts, a dotted open rectangle marks the corners of the object drawn into (#4319). In Draw Behind, New Layer (the Layers panel's button, its menu, Ctrl/Cmd+L and the Layer Options dialog) puts the new layer directly below the current layer, at its level, as [the help page](https://help.adobe.com/archive/en_US/illustrator/cs5/illustrator_cs5_help.pdf#page=234) describes and [drawing modes](https://helpx.adobe.com/illustrator/desktop/draw-shapes-and-paths/learn-drawing-basics/drawing-modes-overview.html) lists; Ctrl/Cmd-click still puts it on top and Ctrl/Cmd+Alt-click below, and New Sublayer is not affected (VectorCraft's own rule). In Draw Behind, an Alt-drag copy made with the Selection or Direct Selection tool goes directly below its original and is selected, as [drawing modes](https://helpx.adobe.com/illustrator/desktop/draw-shapes-and-paths/learn-drawing-basics/drawing-modes-overview.html) lists duplicating by Alt-drag among the actions the mode applies to; with several objects, each copy goes below its own original in that original's group or layer, the copy of the clipping path of a clip group or a clipping layer goes directly above it so the clipping path stays the bottom object, and in Draw Normal and Draw Inside, and for the transform dialogs' Copy, Duplicate and Transform Again, copies still go above (VectorCraft's own rules). In Draw Behind, a placed symbol instance (Place Symbol Instance in the Symbols panel, and a symbol dragged onto the canvas from the Symbols panel or a symbol library) goes directly below the selected object, or at the bottom of the current layer with nothing selected, as [drawing modes](https://helpx.adobe.com/illustrator/desktop/draw-shapes-and-paths/learn-drawing-basics/drawing-modes-overview.html) describes for placing symbols; below the bottommost of several selected objects, beside the compound path that holds a selected path, and above a clipping path are VectorCraft's own rules. Draw Normal and Draw Inside keep it on top of the current layer.
- **Drawing modes:** in Draw Inside, a double-click with a selection tool outside the object being drawn into sets the drawing mode to Draw Normal, as Shift+D does. Pastes follow the drawing mode ([drawing modes](https://helpx.adobe.com/illustrator/desktop/draw-shapes-and-paths/learn-drawing-basics/drawing-modes-overview.html)) (#3705): in Draw Inside, Paste, Paste in Place and Paste on All Artboards put the copies inside the object drawn into, in one undo step, Paste Remembers Layers aside; in Draw Behind, Paste in Place and Paste on All Artboards put them just below the selection; Paste in Front and Paste in Back ignore the mode. Shift+D cycles Draw Normal → Draw Behind → Draw Inside → Draw Normal, skipping Draw Inside unless one path, compound path or type is selected. With the object drawn into isolated (a double-click on it with the Selection tool), art drawn or pasted inside it takes isolation mode into its clip group, so it can be clicked and isn't dimmed, as art added in isolation mode belongs with what is isolated ([isolation mode](https://helpx.adobe.com/illustrator/desktop/manage-objects/select-objects/isolate-objects.html)) (#3705); undo or redo that removes the isolated object ends isolation mode. While Draw Inside lasts, a dotted open rectangle marks the corners of the object drawn into (#4319). The object drawn into becomes the clip group's clipping path and keeps its fills and strokes, as [drawing modes](https://helpx.adobe.com/illustrator/desktop/draw-shapes-and-paths/learn-drawing-basics/drawing-modes-overview.html) ([archived](https://web.archive.org/web/20261111110310/https://helpx.adobe.com/illustrator/desktop/draw-shapes-and-paths/learn-drawing-basics/drawing-modes-overview.html)) says Draw Inside clipping masks do: its fills paint behind the art drawn inside it and its strokes over that art, unclipped, so a centred stroke stays whole (#8753, `tests::file::draw_inside_keeps_the_objects_stroke_whole_and_over_the_new_art`). Its effects draw with its fills inside the clip group, so the part of a drop shadow that falls outside its outline is cut, as in any clip group. In Draw Behind, New Layer (the Layers panel's button, its menu, Ctrl/Cmd+L and the Layer Options dialog) puts the new layer directly below the current layer, at its level, as [the help page](https://help.adobe.com/archive/en_US/illustrator/cs5/illustrator_cs5_help.pdf#page=234) describes and [drawing modes](https://helpx.adobe.com/illustrator/desktop/draw-shapes-and-paths/learn-drawing-basics/drawing-modes-overview.html) lists; Ctrl/Cmd-click still puts it on top and Ctrl/Cmd+Alt-click below, and New Sublayer is not affected (VectorCraft's own rule). In Draw Behind, an Alt-drag copy made with the Selection or Direct Selection tool goes directly below its original and is selected, as [drawing modes](https://helpx.adobe.com/illustrator/desktop/draw-shapes-and-paths/learn-drawing-basics/drawing-modes-overview.html) lists duplicating by Alt-drag among the actions the mode applies to; with several objects, each copy goes below its own original in that original's group or layer, the copy of the clipping path of a clip group or a clipping layer goes directly above it so the clipping path stays the bottom object, and in Draw Normal and Draw Inside, and for the transform dialogs' Copy, Duplicate and Transform Again, copies still go above (VectorCraft's own rules). In Draw Behind, a placed symbol instance (Place Symbol Instance in the Symbols panel, and a symbol dragged onto the canvas from the Symbols panel or a symbol library) goes directly below the selected object, or at the bottom of the current layer with nothing selected, as [drawing modes](https://helpx.adobe.com/illustrator/desktop/draw-shapes-and-paths/learn-drawing-basics/drawing-modes-overview.html) describes for placing symbols; below the bottommost of several selected objects, beside the compound path that holds a selected path, and above a clipping path are VectorCraft's own rules. Draw Normal and Draw Inside keep it on top of the current layer.
- **Drawing:** Pen, Curvature, anchor tools, Pencil, Paintbrush, Blob Brush, Smooth, Path Eraser, Join. Direction handles dragged with Direct Selection or the Anchor Point tool snap to smart guides, and Shift keeps them at 45° steps from their anchor. The Pen continues any open path from the end clicked, and while drawing, a click on an end of another open path joins the two into one (#776). The Curvature tool edits any selected path, whatever drew it, keeping its shape except where edited (#798): a click on a point makes it current and a drag moves it, re-curving only its two segments; double-click, or Alt-click on any point but an end of an open path, toggles it smooth or corner and Delete removes it; a click on a segment adds a point without changing the shape; with an end of an open path current, clicks go on from it and its other end closes it (`path.curvatureEdit`). An Alt-click on an end of a selected open path makes that end current without changing it, so the next click goes on from it, as [the help page](https://helpx.adobe.com/illustrator/desktop/draw-shapes-and-paths/draw-shapes/draw-shapes-with-the-curvature-tool.html) describes for continuing a path; an Alt-click that starts a new path places a corner point, as later Alt-clicks do. Every point a drawing tool places snaps to Smart Guides through one snapper (#506): the Pen's and Curvature tool's anchors, the Pencil's ends, the shape tools' start and dragged corner or radius (Rectangle, Rounded Rectangle, Ellipse, Polygon, Star, Line Segment, Arc, Spiral, the grids), the Type tool's click and frame, a new artboard's corners. A filled Pencil path keeps a stroke of None (#1804, part of #1679). While a Pencil or Paintbrush stroke is drawn back to within Close Paths When Ends Are Within of its start, the cursor shows the closing ring and a release there closes the path, as [Draw straight lines with the Pencil tool](https://helpx.adobe.com/illustrator/desktop/draw-shapes-and-paths/draw-shapes/draw-straight-lines-with-the-pencil-tool.html) describes for the Pencil. The [ and ] keys reach the Blob Brush, the Eraser and the Symbolism tools in the app (#1734, part of #1661).
Blob Brush and Eraser Tool Options' Size is Fixed or Pressure with a Variation (#4590, #3961), and the Blob Brush's Size also offers Stylus Wheel (see Blob Brush Size on the stylus wheel): with Pressure a pen stroke is Size − Variation wide where it presses lightest and Size + Variation where it presses hardest, and a mouse stroke keeps the Size.
`path.blob` and `path.eraseRegion` refuse a Size outside 0.1 to 1000 pt and a Variation outside 0 to 1000 pt, also with Size set to Fixed, and the drawing commands that read pen values refuse a pressure outside 0 to 1, a tilt outside −90° to 90°, a rotation outside 0° to 360°, a stylus wheel reading outside 0 to 1 and a point array of more than seven numbers (the wheel is the seventh), with an error naming the key; the document, the selection and the undo history stay as they were. The pressure and tilt ranges are those of [Pointer Events](https://www.w3.org/TR/pointerevents3/); the Size, Variation, rotation and wheel ranges are VectorCraft's own values (`tests::draw2::pen_values_outside_their_ranges_are_refused`).
@@ -3495,6 +3495,7 @@ Edit › Copy and Cut put the selected ruler guides on the clipboard, with the s
| 2026-11-21 | minor | G13: View › Snapping groups five existing toggles and Pixel Snapping Options…; top-level commands and shortcuts remain; headless click/checkmark coverage added; scores and estimates unchanged. |
| 2026-11-21 | minor | G12: Properties Quick Actions offer Ungroup when any selected object is a group, Isolate Group only for one group, and Unite only for selections of at least two objects, each a non-guide path or a compound path. Headless regressions: `panels::properties::tests::two_groups_offer_ungroup_without_isolate_group`, `one_group_offers_ungroup_and_isolate_group`, `several_paths_offer_group_clipping_mask_and_unite`. Scores and estimates unchanged. |
| 2026-11-21 | minor | G12: Document Info Selection Only (`ui.docInfo.selectionOnly`) counts the selection through `document.info`; with no artwork selected it shows (No artwork selected) and artboards the Artboard tool has selected still show. Headless regressions: `panels::doc_info::tests::test_doc_info_counts_entire_document`, `test_doc_info_selection_only_toggles_and_filters_counts`, `test_doc_info_selection_only_keeps_selected_artboard`, `test_doc_info_panel_menu_toggles_state`. Scores and estimates unchanged. |
| 2026-11-20 | minor | Draw Inside makes the object it draws into the clip group's clipping path, keeping its fill and stroke, instead of clipping by an unpainted copy of it: its centred stroke is no longer clipped by its own outline and paints over the art drawn inside it ([drawing modes](https://helpx.adobe.com/illustrator/desktop/draw-shapes-and-paths/learn-drawing-basics/drawing-modes-overview.html), [archived](https://web.archive.org/web/20261111110310/https://helpx.adobe.com/illustrator/desktop/draw-shapes-and-paths/learn-drawing-basics/drawing-modes-overview.html)) (#8753). Scores and estimates unchanged. |
| 2026-11-20 | minor | Color conversion indexes global swatch bases and linked-paint lookups (#8804); scores, estimates and measured budgets unchanged. |
| 2026-11-20 | minor | G12: Asset Export tiles have item context menus for Export, Remove, Rename, Select Artwork on Canvas and collecting selected artwork; right-click selects an unselected tile and preserves an existing multi-selection. Headless regressions: panels::tests_asset_export. Scores and estimates unchanged. |
| 2026-11-19 | minor | Layers: a target circle whose item is targeted and has an appearance of its own keeps its inner ring visible around a smaller appearance dot, so the four looks (not targeted, targeted, with an appearance, both) differ (#8711). Scores and estimates unchanged. |
+3 -2
View File
@@ -1,6 +1,6 @@
# Type parity
> **Last reviewed:** 2026-10-10 · **Last updated:** 2026-11-18 · **Change:** minor (Retype phase 1 (#4934): Type › Retype (`type.retype`) turns outlined text that exactly matches an available font back into point text; scores and estimates unchanged; previously: modal Check Spelling dialog: Edit › Spelling › Check Spelling…, `ui.checkSpelling`, #4936; spell check complete; previously minor: Paragraph composers (#4935): the Paragraph panel menu and paragraph styles offer four composers, the Middle Eastern & South Asian Single-line and Every-line (how all type is set, and the default) and a Standard Single-line and Every-line that set Indic, Arabic and Hebrew type glyph by glyph as the font maps it, for legacy fonts that keep a script on Latin character codes; `.ai` and EPS files do not carry the choice; scores and estimates unchanged; previously minor: kerning at the Type tool's caret at the start of a line sets the space before the character after it, #5111; previously minor: type's strokes in an envelope paint along its bent glyph outlines at their own weight, Distort Appearance on or off, as users' `.ai` files draw them, #6644; previously minor: a centred or right-aligned line of tracked type is aligned without the tracking after its last character, as the page of users' `.ai` files aligns it, #6610; previously minor: tracking and manual kerning in horizontally scaled type are thousandths of the em as the Horizontal Scale draws it, as the page of users' `.ai` files spaces such type; previously minor: Edit › Edit Custom Dictionary…: its dialog adds, deletes and changes the custom dictionary's words, #4936; previously minor: Direct Selection shows and drags the direction handles of type on a path's path, #3565; previously minor: right-click on type: Spelling › Auto Spell Check, with its check mark, #4936; previously minor: right-click on a word Auto Spell Check underlined: its suggestions, Ignore All and Add to Dictionary, #4936; previously minor: Auto Spell Check: `edit.autoSpellCheck` underlines the unknown words, #4936; previously minor: PDF marked-text export (#6309): compatible glyphs stay on one layout line with per-glyph offsets; scores and estimates unchanged; paint-only Arabic harakat keep joining with GDEF-mark ownership and Insert Kashidas base-letter paint; scores and estimates unchanged; custom dictionary and Ignore All: `text.spelling.addWord`, `removeWord`, `changeWord`, `dictionary` and `ignoreAll`, #4936; previously minor: spell check engine: `text.spelling.check` and `text.spelling.suggest` on craft-proof, #4936; previously minor: right-aligned area type sets the text after a line's last tab against the right edge; a soft return in justified type no longer keeps its line from being justified; Character Styles panel: a double-click on a style's row opens its Character Style Options; the dialog keeps a fixed width and scrolls its sections, so its buttons stay on screen) · **Target:** Adobe Illustrator 2026 (30.x)
> **Last reviewed:** 2026-10-10 · **Last updated:** 2026-12-02 · **Change:** minor (Language packs (#4936): Edit › Preferences › Language Packs and the missing-pack bar; previously: Retype phase 1 (#4934): Type › Retype (`type.retype`) turns outlined text that exactly matches an available font back into point text; scores and estimates unchanged; previously: modal Check Spelling dialog: Edit › Spelling › Check Spelling…, `ui.checkSpelling`, #4936; spell check complete; previously minor: Paragraph composers (#4935): the Paragraph panel menu and paragraph styles offer four composers, the Middle Eastern & South Asian Single-line and Every-line (how all type is set, and the default) and a Standard Single-line and Every-line that set Indic, Arabic and Hebrew type glyph by glyph as the font maps it, for legacy fonts that keep a script on Latin character codes; `.ai` and EPS files do not carry the choice; scores and estimates unchanged; previously minor: kerning at the Type tool's caret at the start of a line sets the space before the character after it, #5111; previously minor: type's strokes in an envelope paint along its bent glyph outlines at their own weight, Distort Appearance on or off, as users' `.ai` files draw them, #6644; previously minor: a centred or right-aligned line of tracked type is aligned without the tracking after its last character, as the page of users' `.ai` files aligns it, #6610; previously minor: tracking and manual kerning in horizontally scaled type are thousandths of the em as the Horizontal Scale draws it, as the page of users' `.ai` files spaces such type; previously minor: Edit › Edit Custom Dictionary…: its dialog adds, deletes and changes the custom dictionary's words, #4936; previously minor: Direct Selection shows and drags the direction handles of type on a path's path, #3565; previously minor: right-click on type: Spelling › Auto Spell Check, with its check mark, #4936; previously minor: right-click on a word Auto Spell Check underlined: its suggestions, Ignore All and Add to Dictionary, #4936; previously minor: Auto Spell Check: `edit.autoSpellCheck` underlines the unknown words, #4936; previously minor: PDF marked-text export (#6309): compatible glyphs stay on one layout line with per-glyph offsets; scores and estimates unchanged; paint-only Arabic harakat keep joining with GDEF-mark ownership and Insert Kashidas base-letter paint; scores and estimates unchanged; custom dictionary and Ignore All: `text.spelling.addWord`, `removeWord`, `changeWord`, `dictionary` and `ignoreAll`, #4936; previously minor: spell check engine: `text.spelling.check` and `text.spelling.suggest` on craft-proof, #4936; previously minor: right-aligned area type sets the text after a line's last tab against the right edge; a soft return in justified type no longer keeps its line from being justified; Character Styles panel: a double-click on a style's row opens its Character Style Options; the dialog keeps a fixed width and scrolls its sections, so its buttons stay on screen) · **Target:** Adobe Illustrator 2026 (30.x)
> **File-font hardening status (2026-11-12, #4569):** implementation and synthetic regressions added; compilation and runtime checks pending. Scores and estimates unchanged.
>
@@ -55,7 +55,7 @@ against Illustrator's public documentation; **estimated** unless noted.
| Hyphenation… and Justification… options | done | Eleven Indian languages use attributed patterns and preserve syllables in both composers (#4947). Hyphenation… (`ui.hyphenation`, `text.setFormat`) sets each paragraph's Words Longer Than, After First, Before Last, Hyphen Limit, Hyphenation Zone (Single-line Composer only) and Hyphenate Capitalized Words, and paragraph styles carry them (#2310). Justification… (`ui.justification`, `text.setFormat`, #2755) sets Word Spacing, Letter Spacing and Glyph Scaling (Minimum, Desired, Maximum), Auto Leading and Single Word Justification; Desired applies to every line, justified lines and the Every-line Composer use the ranges. Vertical type isn't glyph scaled. Auto Leading also sets the Leading the Character panel shows for Auto type, the leading Alt+↑/↓ (`type.step`) steps from, per paragraph, and the lines Fill with Placeholder Text counts. Evidence: `crates/text/src/tests/justify.rs`, `dialogs::justification::tests`, `tests_prefs::auto_leading_steps_and_fills_from_the_paragraph_auto_leading`, `panels::character` test `leading_field_shows_the_paragraph_auto_leading` |
| Tab stops and leaders; Tabs panel | partial | Tabs panel and stops with leaders in the model (`text.tabs.set`); a stop drags from where the press landed (#1458); leaders fill the tab's gap, repeated on a grid so they line up from line to line (#1877); Ctrl-dragging a stop (Command on macOS) moves all the stops together; in right-aligned area type the text before a line's last tab sits at its stops, from the left edge, and the text after it against the right edge, as Illustrator's own layout in a user's `.ai` sets a price list (evidence: `tests::right_aligned_area_type_sets_the_text_after_its_last_tab_against_the_edge`; centred lines are still aligned as a whole); in justified area type the text up to a line's last tab keeps its spacing and its tabs their stops, and the text after the last tab takes the line's room to the far edge, VectorCraft's own rule (evidence: `tests::justify::a_justified_line_with_a_tab_spreads_the_text_after_it_to_the_edge` and the other tab tests in `crates/text/src/tests/justify.rs`) |
| Hidden characters (Show Hidden Characters) | done | `type.hiddenCharacters`: marks spaces, tabs, nonbreaking and narrow nonbreaking spaces, the spaces of a set width, discretionary hyphens, forced line breaks, paragraph ends and the story's end, in horizontal, vertical and right-to-left type and on a path, and none on type in a hidden group or layer; the mark shapes are VectorCraft's own. Evidence: `canvas::tests::hidden_characters_*` |
| Spell check (Check Spelling, Auto Spell Check, custom dictionary) | done | the engine (#4936): `text.spelling.check` lists the unknown words of the document's type, each run in its Language, at the bytes `text.editRange` changes, and `text.spelling.suggest` gives suggestions, both from craft-proof, each paragraph on its own (English from the first dictionary it finds: a Hunspell dictionary in the user's dictionaries folder, the SCOWL dictionary built in from craft-i18n, a system Hunspell dictionary, and last the public-domain Moby word list built into it; other languages from the dictionaries craft-proof finds for them). The custom dictionary commands are done: `text.spelling.addWord`, `removeWord` and `changeWord` (Add, and Edit Custom Dictionary's Add, Delete and Change), and `text.spelling.dictionary` lists the words, saved to `Custom Dictionary.txt` beside the preferences; Ignore All: `text.spelling.ignoreAll` skips a word in the active document while it is open. Auto Spell Check is done: Edit › Spelling › Auto Spell Check (`edit.autoSpellCheck`, off at first, saved with the view settings) draws a red wavy line under the unknown words of the visible type, leaves out type with effects, and follows edits, the custom dictionary and Ignore All. A right-click on an underlined word lists the words its dictionary suggests (each replaces it in one undo step, `text.editRange`), or No Suggestions, then Ignore All and Add to Dictionary, and a right-click on type has Spelling › Auto Spell Check, checked while it is on. Edit › Edit Custom Dictionary… lists the custom dictionary's words, with an Entry field and Add, Delete and Change, applied on Done (Cancel leaves the dictionary as it was). The modal Check Spelling dialog is done: Edit › Spelling › Check Spelling… (`Cmd+I`, `ui.checkSpelling`) opens a modal dialog displaying the unrecognized word in sentence context ("Not in Dictionary"), a list of suggestions with double-click or selection to replace ("Change to" field), and action buttons: Ignore, Ignore All, Change (one-step Undo/Redo via `text.editRange`), Change All (batched across occurrences in a single undo step), Add to Dictionary (`text.spelling.addWord`), Done and Cancel, with keyboard navigation (Tab between controls, Enter to Change or Done, Escape to close). Evidence: `crates/engine/src/tests/spelling.rs`, `crates/ui-egui/src/canvas/tests.rs` (`auto_spell_check_*`), `crates/ui-egui/src/tests/contextmenu.rs` (the right-click), `crates/ui-egui/src/dialogs/custom_dictionary.rs` (the dialog), `crates/ui-egui/src/dialogs/check_spelling.rs` (the Check Spelling dialog). |
| Spell check (Check Spelling, Auto Spell Check, custom dictionary) | done | the engine (#4936): `text.spelling.check` lists the unknown words of the document's type, each run in its Language, at the bytes `text.editRange` changes, and `text.spelling.suggest` gives suggestions, both from craft-proof, each paragraph on its own (English from the first dictionary it finds: a Hunspell dictionary in the user's dictionaries folder, the SCOWL dictionary built in from craft-i18n, a system Hunspell dictionary, and last the public-domain Moby word list built into it; other languages from the dictionaries craft-proof finds for them). The custom dictionary commands are done: `text.spelling.addWord`, `removeWord` and `changeWord` (Add, and Edit Custom Dictionary's Add, Delete and Change), and `text.spelling.dictionary` lists the words, saved to `Custom Dictionary.txt` beside the preferences; Ignore All: `text.spelling.ignoreAll` skips a word in the active document while it is open. Auto Spell Check is done: Edit › Spelling › Auto Spell Check (`edit.autoSpellCheck`, off at first, saved with the view settings) draws a red wavy line under the unknown words of the visible type, leaves out type with effects, and follows edits, the custom dictionary and Ignore All. A right-click on an underlined word lists the words its dictionary suggests (each replaces it in one undo step, `text.editRange`), or No Suggestions, then Ignore All and Add to Dictionary, and a right-click on type has Spelling › Auto Spell Check, checked while it is on. Edit › Edit Custom Dictionary… lists the custom dictionary's words, with an Entry field and Add, Delete and Change, applied on Done (Cancel leaves the dictionary as it was). The modal Check Spelling dialog is done: Edit › Spelling › Check Spelling… (`Cmd+I`, `ui.checkSpelling`) opens a modal dialog displaying the unrecognized word in sentence context ("Not in Dictionary"), a list of suggestions with double-click or selection to replace ("Change to" field), and action buttons: Ignore, Ignore All, Change (one-step Undo/Redo via `text.editRange`), Change All (batched across occurrences in a single undo step), Add to Dictionary (`text.spelling.addWord`), Done and Cancel, with keyboard navigation (Tab between controls, Enter to Change or Done, Escape to close). Language packs (#4936) spell-check and hyphenate other languages: Edit › Preferences › Language Packs installs and removes them (`proof.installPack`, `proof.removePack`), and a bar over the canvas offers the pack for a language of the document's type that has no dictionary. Evidence: `crates/engine/src/tests/spelling.rs`, `crates/ui-egui/src/canvas/tests.rs` (`auto_spell_check_*`), `crates/ui-egui/src/tests/contextmenu.rs` (the right-click), `crates/ui-egui/src/dialogs/custom_dictionary.rs` (the dialog), `crates/ui-egui/src/dialogs/check_spelling.rs` (the Check Spelling dialog), `crates/engine/src/tests/packs.rs` and `crates/ui-egui/src/language_packs/desktop/tests.rs` (Language packs). |
| Smart Punctuation, Change Case, Find & Replace | done | Type › Smart Punctuation… opens a dialog with the ff, fi, ffi and ff, fl, ffl ligatures, Smart Quotes, Smart Spaces, En, Em Dashes, Ellipses and Expert Fractions, Replace In and Report Results, which lists the count of each replacement; ligatures and fractions are written only where the font has a glyph for them. Evidence: `tests::menucmds::smart_punctuation_ligatures_spaces_and_fractions_are_counted`, `smart_punctuation_skips_ligatures_and_fractions_the_font_lacks`, `smart_spaces_keeps_one_space_after_a_period`, `dialogs::smart_punctuation::tests::menu_item_opens_the_dialog_and_ok_reports_the_counts` |
| Alt + numeric-keypad codes while typing (Windows: `Alt+0176` → °) | partial | #5108: on Windows the character Windows posts when Alt comes up after keypad digits is typed at the caret like any other, in the typing's undo step (winit reports it as typed text), and the keypad digits typed with Alt run no shortcut. With NumLock off the keypad keys (Insert, End, arrows, Clear, Home, Page Up/Down without the extended-key flag) count as digits too and don't move the caret (`windows_alt_codes` unit tests; neither NumLock on nor off has been tried on a Windows machine yet). `type.insert {code}` (Windows Alt+0 code, Windows-1252 for 128–159) and `{unicode}` (hex code point) insert a character by its code (`menucmds::insert_a_character_by_its_code`). macOS and Linux have no such system convention and egui reports a keypad digit as the top-row digit, so there it does nothing; in a floating panel window the keypad digits typed with Alt are not taken out of the frame |
| Caret: the arrows and Delete step over whole clusters (Thai consonant with its marks, combining accents, emoji); Backspace removes one character | done | in text with right-to-left characters the arrows move in visual order and stop on both sides of a character drawn with no width, such as a zero width non-joiner |
@@ -93,6 +93,7 @@ Character Styles menu New/Redefine and footer New capture the first selected cha
| Date | Change | Summary |
|---|---|---|
| 2026-12-02 | minor | Language packs (#4936): Edit › Preferences › Language Packs lists, installs and removes the packs that spell-check and hyphenate languages other than English, and a dismissible bar over the canvas offers the pack for a language of the document's type without a dictionary; not on the web yet. |
| 2026-11-12 | minor | #4569: file-font identity, ownership and live-face allowance hardening; forged internal family names no longer select global file fonts. Preserve owned fallback bindings through installed-font removal, placement, older saves and recovery. Added synthetic regressions; format-only verification, runtime proof pending. Scores and estimates unchanged. |
| 2026-11-18 | minor | Retype phase 1 (#4934): `type.retype` turns outlined glyphs that exactly match an available font back into point text (font, size, baseline, turn, paint), reporting the shapes it cannot match; the Retype row is now partial. Scores and estimates unchanged |
| 2026-11-15 | minor | Check Spelling dialog (#4936): Edit › Spelling › Check Spelling… (`Cmd+I`, `ui.checkSpelling`) modal dialog with sentence context, suggestions, Ignore, Ignore All, Change, Change All, Add to Dictionary, Done/Cancel, keyboard navigation, and one-step Undo/Redo; spell check complete. Scores and estimates unchanged. |
+4 -1
View File
@@ -1,7 +1,7 @@
# UI and interaction parity
> Status-bar snapping quick access (#8687, #8779): the bottom right offers Smart Guides, Snap to Point and Snap to Grid toggles plus the same live Snapping menu as the Control bar. Both use existing commands. Framework fit ranks omit the direct group first, then the dropdown, before the existing readouts or core status content narrow. The native buttons expose their current selected state. Scores and estimates are unchanged.
> **Last reviewed:** 2026-10-10 · **Last updated:** 2026-12-02 · **Change:** minor (G12: Retype panel font rows have an item context menu (Apply Font, sample sizes, Reset Retype Panel); scores and estimates unchanged; previously: G12: SVG Interactivity event rows have an item menu; scores and estimates unchanged; earlier: RFC-0052 Headless section, all unknown; earlier: Ctrl/Cmd+arrow fine nudge, #5258; scores and estimates unchanged; previously: Smart Guides: in a document with more than 20,000 anchors, the snap targets are gathered topmost first, so the objects in front, the newest, keep their anchors, edges and centre as targets for ruler guides, moves, scaling and drawing (#8531); scores and estimates unchanged; previously: 3D effect options: unchanged values preserve the document and add no Undo; scores and estimates unchanged); previously: minor (G12: History row menus adapted to shared Craft list/menu controls after rebase (#8845); scores and estimates unchanged; previously: G12/M14: History row context menus, pending-edit snapshot targeting, keyboard access and document-switch dismissal (#8845); scores and estimates unchanged; previously: Pencil Edit Selected Paths follows lifted strokes, carves, loops, closes and redraws compound paths; Layers: a targeted item with an appearance of its own keeps its inner ring visible around a smaller appearance dot, so the target circle's four looks differ, #8711; scores and estimates unchanged; previously: G12: Asset Export tile context menus; scores and estimates unchanged; previously: Properties panel per context (G12): contextual text Quick Actions (Create Outlines, Retype, Find and Replace…); scores and estimates unchanged; previously: Layers: a targeted item with an appearance of its own keeps its inner ring visible around a smaller appearance dot, so the target circle's four looks differ, #8711; scores and estimates unchanged; previously: 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, #8363; scores and estimates unchanged; previously: Scissors shows the actual proposed cut point while hovering, using its existing snapping and cut target (#8655); scores and estimates unchanged; previously: Graphic Styles panel: right-click item context menu for tiles and rows with Options, Duplicate, Delete, Redefine, Break Link; scores and estimates unchanged; previously: Artboard tool: Shift held once a move or Alt-copy drag is under way keeps it to the level, upright or 45° line, #8580; scores and estimates unchanged; previously: Image Trace Ignore Color keeps the canvas View and stays armed on a missed pixel (#8068); Canvas context menu: a right-click on a path offers Simplify… next to Smooth…, opening the Simplify slider, or the Simplify dialog kept for next time, as Object › Path › Simplify… does, #8344; scores and estimates unchanged; previously: a tool drag held near an edge of the canvas scrolls the view, #8551; scores and estimates unchanged; previously: G12: Place: show progress window with Cancel for slow placed files exceeding 0.4 s, part of #5930; scores and estimates unchanged; previously: All Tools drawer: a tool the toolbar holds is dimmed in the readable dim text colour, not the disabled colour that was unreadable against the panel, and a hovered dimmed row takes the panel's darker fill so it stays readable, #8294; scores and estimates unchanged; previously: : selected guide rows stay highlighted after the pointer leaves (#7344); scores and estimates unchanged; previously: Layersselected Dimension extension-line color and weight in Properties (#7078; four focused UI regressions passed); scores and estimates unchanged; previously: Brush Options Key Color: restore canvas input for the existing one-shot pick, then resume the retained draft and previous tool (#8284; six full-app input regressions passed); scores and estimates unchanged; previously: Ellipse: Up/Down changes Anchors while drawing (#7840); scores and estimates unchanged; previously: Windows/Linux menu access keys and localized cues (#6596); previously: Backquote/~ arrow pattern nudges (#7717); scores and estimates unchanged; previously: Window > Toolbars > Compact Tools offers optional denser main Tools spacing (#7234); default layout, scores and estimates unchanged; previously: Direct Selection: Space during an ordinary path's handle drag repositions its anchor and handles, including a Pen loan (#7237, request 3 only; scores and estimates unchanged); previously: Floating panels keep their window level while focus moves between the app's windows, so a press on one panel's bar no longer hands the keyboard to another, #6986; scores and estimates unchanged; previously minor: 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 gLine truncated
> **Last reviewed:** 2026-10-10 · **Last updated:** 2026-12-02 · **Change:** minor (Draw Inside keeps the object it draws into as the clip group's clipping path with its fill and stroke, so its stroke stays whole over the art drawn inside it, #8753; scores and estimates unchanged; previously: G12: Retype panel font rows have an item context menu (Apply Font, sample sizes, Reset Retype Panel); scores and estimates unchanged; previously: G12: SVG Interactivity event rows have an item menu; scores and estimates unchanged; earlier: RFC-0052 Headless section, all unknown; earlier: Ctrl/Cmd+arrow fine nudge, #5258; scores and estimates unchanged; previously: Smart Guides: in a document with more than 20,000 anchors, the snap targets are gathered topmost first, so the objects in front, the newest, keep their anchors, edges and centre as targets for ruler guides, moves, scaling and drawing (#8531); scores and estimates unchanged; previously: 3D effect options: unchanged values preserve the document and add no Undo; scores and estimates unchanged); previously: minor (G12: History row menus adapted to shared Craft list/menu controls after rebase (#8845); scores and estimates unchanged; previously: G12/M14: History row context menus, pending-edit snapshot targeting, keyboard access and document-switch dismissal (#8845); scores and estimates unchanged; previously: Pencil Edit Selected Paths follows lifted strokes, carves, loops, closes and redraws compound paths; Layers: a targeted item with an appearance of its own keeps its inner ring visible around a smaller appearance dot, so the target circle's four looks differ, #8711; scores and estimates unchanged; previously: G12: Asset Export tile context menus; scores and estimates unchanged; previously: Properties panel per context (G12): contextual text Quick Actions (Create Outlines, Retype, Find and Replace…); scores and estimates unchanged; previously: Layers: a targeted item with an appearance of its own keeps its inner ring visible around a smaller appearance dot, so the target circle's four looks differ, #8711; scores and estimates unchanged; previously: 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, #8363; scores and estimates unchanged; previously: Scissors shows the actual proposed cut point while hovering, using its existing snapping and cut target (#8655); scores and estimates unchanged; previously: Graphic Styles panel: right-click item context menu for tiles and rows with Options, Duplicate, Delete, Redefine, Break Link; scores and estimates unchanged; previously: Artboard tool: Shift held once a move or Alt-copy drag is under way keeps it to the level, upright or 45° line, #8580; scores and estimates unchanged; previously: Image Trace Ignore Color keeps the canvas View and stays armed on a missed pixel (#8068); Canvas context menu: a right-click on a path offers Simplify… next to Smooth…, opening the Simplify slider, or the Simplify dialog kept for next time, as Object › Path › Simplify… does, #8344; scores and estimates unchanged; previously: a tool drag held near an edge of the canvas scrolls the view, #8551; scores and estimates unchanged; previously: G12: Place: show progress window with Cancel for slow placed files exceeding 0.4 s, part of #5930; scores and estimates unchanged; previously: All Tools drawer: a tool the toolbar holds is dimmed in the readable dim text colour, not the disabled colour that was unreadable against the panel, and a hovered dimmed row takes the panel's darker fill so it stays readable, #8294; scores and estimates unchanged; previously: : selected guide rows stay highlighted after the pointer leaves (#7344); scores and estimates unchanged; previously: Layersselected Dimension extension-line color and weight in Properties (#7078; four focused UI regressions passed); scores and estimates unchanged; previously: Brush Options Key Color: restore canvas input for the existing one-shot pick, then resume the retained draft and previous tool (#8284; six full-app input regressions passed); scores and estimates unchanged; previously: Ellipse: Up/Down changes Anchors while drawing (#7840); scores and estimates unchanged; previously: Windows/Linux menu access keys and localized cues (#6596); previously: Backquote/~ arrow pattern nudges (#7717); scores and estimates unchanged; previously: Window > Toolbars > Compact Tools offers optional denser main Tools spacing (#7234); default layout, scores and estimates unchanged; previously: Direct Selection: Space during an ordinary path's handle drag repositions its anchor and handles, including a Pen loan (#7237, request 3 only; scores and estimates unchanged); previously: Floating panels keep their window level while focus moves between the app's windows, so a press on one panel's bar no longer hands the keyboard to another, #6986; scores and estimates unchanged; previously minor: Lock Guides: a selection maLine truncated
> Panel readout copy (#8432, #8826): Info values and paint names, Links information, and named Document Info rows with no separate value follow the guarded immediate-copy policy landed in #9353. A plain first click copies the full value and reports "Copied the value"; accessible activation copies it too. Selectable readouts retain word selection on double-click, Shift/drag selection and keyboard Copy/Cut. Links Location retains #9521's path fitting and full-path tooltip as static text, with the same full-value primary/accessible copy and a native Copy Location button for keyboard use. Scores and estimates are unchanged.
>
@@ -84,6 +84,7 @@ Artboard Options forwards the active Artboard tool's Scale Artwork with Artboard
| 2026-12-02 | minor | Canvas context menu: rows for edit, group, path, type, view and artboard commands show a leading icon from the app's icon set, so a row can be found by its shape; rows without a fitting glyph stay text only (#4602); scores and estimates unchanged |
| 2026-12-02 | minor | Retype panel (G12): font rows have an item context menu: a secondary click or Shift+F10 selects the row and offers Apply Font (what a click on the row does; off without live text selected), the panel menu's Small, Medium and Large sample sizes and Reset Retype Panel; the menu closes when the list or the document changes. Headless regressions: `panels::retype::tests`. Scores and estimates unchanged. |
| 2026-12-02 | minor | Headless (RFC-0052) column on the Summary table and every behaviour table: 365 unknown, with marking rules |
| 2026-12-02 | minor | G4 (desktop only; the web page says packs can't be installed there yet): Edit › Preferences › Language Packs (after Hyphenation) lists the installed Language packs, with Remove, and the packs on the downloadable list, with Install, each with its progress and errors; a dismissible bar at the foot of the canvas offers the pack for a language of the document's type without a dictionary when the downloadable list has one, or to fetch the list when none was fetched yet; a language with no pack in the list (Gujarati in the pinned list) gets no offer (#4936); scores and estimates unchanged. |
| 2026-11-24 | minor | G12: History row context menus use shared Craft List and Menu controls after rebasing onto the panel migration. App-specific actions retain the chosen snapshot across pending edits and dismiss on document switches; keyboard context requests and focus restoration use the shared runtime. Regression cases retained (#8845); scores and estimates unchanged. |
| 2026-11-21 | minor | G12/M14: History row context menus retain the chosen snapshot while the menu is open and pending edits settle; jumps settle typing before counting undo/redo, and discarded states report that they are unavailable. Shift+F10 opens the focused row menu, Escape restores row focus, and switching documents dismisses the popup. History checklist, area and milestone evidence updated (#8845); scores and estimates unchanged. |
| 2026-11-20 | minor | G12: Asset Export tiles have item context menus for Export, Remove, Rename, Select Artwork on Canvas and collecting selected artwork; right-click selects an unselected tile and preserves an existing multi-selection. Headless regressions: panels::tests_asset_export. Scores and estimates unchanged. |
@@ -259,6 +260,7 @@ Every parity table on this page has a Headless column: the Summary table (12 are
| Smooth (Object › Path › Smooth…: slider from minimum to maximum smoothing, Auto-Smooth) ([smooth slider](https://helpx.adobe.com/illustrator/desktop/draw-shapes-and-paths/modify-paths/refine-path-segments-with-the-smooth-slider.html)) | done | #4115: the slider under the selection previews `object.path.smooth {level}`, Auto-Smooth picks level 50 and takes a shaky line to one smooth curve, direct-selected anchors smooth only their section, Enter or a click outside keeps one undo step and Escape restores; the smoothing rule beyond the two ends is VectorCraft's own (`tests/smooth_path.rs`, `smooth_slider_previews_auto_smooth_and_keeps_the_result`) | unknown |
| Draw Inside in isolation mode: art drawn or pasted inside the isolated object takes isolation mode into its clip group, clickable and undimmed ([isolation mode](https://helpx.adobe.com/illustrator/desktop/manage-objects/select-objects/isolate-objects.html), [drawing modes](https://helpx.adobe.com/illustrator/desktop/draw-shapes-and-paths/learn-drawing-basics/drawing-modes-overview.html)) | done | #3705; `drawing_inside_an_isolated_object_keeps_the_new_art_in_isolation_mode` | unknown |
| Draw Inside marks the object it draws into: a dotted open rectangle round its corners, in its layer's colour, while the mode lasts, selected or not | done | #4319, `canvas::tests::draw_inside_marks_the_corners_of_its_object` ([drawing modes](https://helpx.adobe.com/illustrator/desktop/draw-shapes-and-paths/learn-drawing-basics/drawing-modes-overview.html)) | unknown |
| Draw Inside keeps the object it draws into as the clipping path with its appearance: its fills paint behind the art drawn inside it and its strokes over that art, unclipped | done | #8753, `tests::file::draw_inside_keeps_the_objects_stroke_whole_and_over_the_new_art` ([drawing modes](https://helpx.adobe.com/illustrator/desktop/draw-shapes-and-paths/learn-drawing-basics/drawing-modes-overview.html), [archived](https://web.archive.org/web/20261111110310/https://helpx.adobe.com/illustrator/desktop/draw-shapes-and-paths/learn-drawing-basics/drawing-modes-overview.html)) | unknown |
| Simplify (slider, auto, corner angle threshold) | done | Tolerance, default-on Preview and original/new point counts (#1272); Corner Point Angle Threshold, Convert to Straight Lines and Show Original Path; the slider under the selection with Auto-Simplify and More Options, and the dialog's option to open it directly with its last settings; the slider opens at the Auto-Simplify level (#3750), and with part of a path direct-selected only the selected runs are simplified (#3814) | unknown |
| Simplify (slider, auto, corner angle threshold) | partial | Tolerance, default-on Preview and original/new point counts (#1272); Corner Point Angle Threshold, Convert to Straight Lines and Show Original Path; the slider under the selection with Auto-Simplify and More Options, opening at the Auto-Simplify level for the selection with that result previewed, and the dialog's option to open it directly with its last settings; with part of a path direct-selected, only the selected runs are simplified (#3814) | unknown |
@@ -697,6 +699,7 @@ before release (#6373). [Paint faces and edges](https://helpx.adobe.com/illustra
| 2026-11-21 | minor | G13: View › Snapping groups five existing toggles and Pixel Snapping Options…; top-level commands and shortcuts remain; headless click/checkmark coverage added; scores and estimates unchanged. |
| 2026-11-21 | minor | G12: Properties Quick Actions offer Ungroup when any selected object is a group, Isolate Group only for one group, and Unite only for selections of at least two objects, each a non-guide path or a compound path. Headless regressions: `panels::properties::tests::two_groups_offer_ungroup_without_isolate_group`, `one_group_offers_ungroup_and_isolate_group`, `several_paths_offer_group_clipping_mask_and_unite`. Scores and estimates unchanged. |
| 2026-11-21 | minor | G12/M14: History row context menus retain the chosen snapshot while the menu is open and pending edits settle; jumps settle typing before counting undo/redo, and discarded states report that they are unavailable. Shift+F10 opens the focused row menu, Escape restores row focus, and switching documents dismisses the popup. History checklist, area and milestone evidence updated (#8845); scores and estimates unchanged. |
| 2026-11-20 | minor | Draw Inside makes the object it draws into the clip group's clipping path, keeping its fill and stroke, instead of clipping by an unpainted copy of it: its centred stroke is no longer clipped by its own outline and paints over the art drawn inside it ([drawing modes](https://helpx.adobe.com/illustrator/desktop/draw-shapes-and-paths/learn-drawing-basics/drawing-modes-overview.html), [archived](https://web.archive.org/web/20261111110310/https://helpx.adobe.com/illustrator/desktop/draw-shapes-and-paths/learn-drawing-basics/drawing-modes-overview.html)) (#8753). Scores and estimates unchanged. |
| 2026-11-20 | minor | Smart Guides: in a document with more than 20,000 anchors, the snap targets are gathered topmost first, so the objects in front, the newest, keep their anchors, edges and centre as targets for ruler guides, moves, scaling and drawing (#8531). Scores and estimates unchanged. |
| 2026-11-20 | minor | G12: Asset Export tiles have item context menus for Export, Remove, Rename, Select Artwork on Canvas and collecting selected artwork; right-click selects an unselected tile and preserves an existing multi-selection. Headless regressions: panels::tests_asset_export. Scores and estimates unchanged. |
| 2026-11-20 | minor | G12: Appearance panel row context menus (Duplicate Stroke/Fill, Delete Stroke/Fill, Hide/Show Stroke/Fill, Edit Effect…, Duplicate Effect, Delete Effect, Hide/Show Effect, Clear Appearance, Reduce to Basic Appearance); right-clicking an unselected row targets that row first. Headless regressions: `panels::tests_appearance`. Scores and estimates unchanged. |
+1 -1
View File
@@ -5,7 +5,7 @@ use std::process::Command;
use serde_json::Value;
const REV: &str = "4f3e34d0dda2a6862f5ba5fc4cfe3e323602a2da";
const REV: &str = "bd7c9e342a33796c9b36b33763c5b63883a22b79";
const PACKAGES: &[(&str, &str, &str)] = &[
("craft-pdf", "0.1.0", REV),
("krilla", "0.8.2", REV),