Commit Graph
515 Commits
Author SHA1 Message Date
.CooCoo ecd771c54c Merge pull request #10644 from dotCooCoo/fix/popout-stable-measure
Panels: the Color and Gradient pop-outs run one pass a frame
2026-12-04 17:03:21 -08:00
dotCooCoo 19eb6cd88c Merge main into fix/popout-stable-measure 2026-12-04 15:00:25 -08:00
dotCooCoo 11a5801b63 Merge main into fix/compress-i18n-catalogs 2026-12-04 14:56:42 -08:00
dotCooCoo 26f5b4ae58 i18n: embed the interface language catalogs Brotli-compressed
The 29 catalogs in crates/ui-egui/src/i18n were embedded with include_str!,
21,861,200 bytes of text in every build. build.rs now compresses each
*.tsv with Brotli (quality 9, 4 MiB window) into OUT_DIR, and the
interface unpacks them when it first needs its catalogs and hands them to
I18n::from_owned. The embedded catalogs take 5,316,158 bytes.

- build.rs finds the catalogs in the folder, so adding a language is
  adding its .tsv. A catalog over 8 MiB, or one it can't read, stops the
  build.
- A catalog that does not unpack to exactly its recorded length of UTF-8
  is left out and logged, and its language is not offered.
- On the desktop the catalogs are unpacked on several threads.
2026-12-04 14:34:45 -08:00
dotCooCoo 829f85298e Merge main into fix/popout-stable-measure 2026-12-04 10:14:11 -08:00
dotCooCoo 9c08ad9395 Merge main into fix/font-hinting-blue-zone-hang 2026-12-04 10:09:33 -08:00
.CooCoo 2675e1291f Merge pull request #10802 from dotCooCoo/fix/open-dwg-files
File formats: DWG drawings open and place through the DXF reader
2026-12-04 09:38:29 -08:00
.CooCoo edcb80db38 Merge pull request #10429 from dotCooCoo/feat/3d-rendered-tier
3D: Render Settings › Rendered draws the solid as a lit image with shadows from every light
2026-12-04 09:24:53 -08:00
.CooCoo afd0c9ab22 Merge pull request #10814 from dotCooCoo/fix/frame-buffer-no-copy
Render: a full-frame render hands its pixels over without a fill and a copy
2026-12-04 09:24:32 -08:00
dotCooCoo cc7c7675a7 File formats: a failed DWG conversion is tried again after 10 seconds
A failed conversion was returned for the same bytes until another
drawing replaced it, so a worker stopped by its deadline, by a lack of
memory or by a failed start kept failing after the cause was gone. The
failure is now kept for 10 seconds from when the conversion returned,
which still covers the reads of one Open, and the next read converts
the drawing again. A conversion that worked is kept as before.
2026-12-04 07:23:53 -08:00
dotCooCoo 2e030ec46d Merge main into fix/open-dwg-files 2026-12-04 06:36:17 -08:00
dotCooCoo 0a01b65903 Merge main into fix/popout-stable-measure 2026-12-04 01:53:17 -08:00
dotCooCoo afc4de9b07 Render: a full-frame render hands its pixels over without a fill and a copy
Renderer::render, render_node, render_pattern_swatch and the image of
Effect > Rasterize copied the rendered pixmap into a new Vec<u8>. They
now take the pixmap's buffer and cast it to bytes in place
(group::into_bytes); a buffer the cast cannot take is still copied.
The target pixmap with nothing under it is allocated zeroed
(group::blank_pixmap) instead of being filled pixel by pixel. At
2880x1800 that removes one 20.7 MB fill and one 20.7 MB copy from every
whole-frame render. The pixels are the same bytes.

Part of #1172
2026-12-04 01:41:07 -08:00
dotCooCoo 094f60b2fb Tests: DWG opens through the DXF Import Options dialog and the CLI worker
- The DXF Import Options dialog test opens a DWG, confirms it at 1:1
  in model space and places it.
- `vectorcraft-cli info` reads a DWG as the DXF it was written from,
  and five damaged copies (cut short, overwritten, bytes flipped) end
  in an error that names DWG or open with warnings, with the process
  exiting normally.
- The engine's DWG and DXF test modules are listed in order.
2026-12-03 20:36:08 -08:00
David Mann 7c96961420 Merge remote-tracking branch 'upstream/main' into feat/agents-open-window
# Conflicts:
#	apps/vectorcraft-cli/src/main.rs
2026-12-04 00:12:25 +01:00
dotCooCoo 7841c460a1 Fonts: a face without hinting instructions no longer hangs the font list
egui hints text by default, so a TrueType face without hinting
instructions goes through skrifa's automatic hinter. In skrifa 0.44,
which epaint, glifo and usvg use, the hinter's long blue-zone search
never ends for a tall narrow Hebrew letter such as U+05D1, so the
font list stopped responding as soon as a row drew that letter in
such a face.

- Cargo.toml: skrifa 0.44 in [patch.crates-io] comes from craft-libs
  vendor/skrifa, which adds skrifa 0.46's exit to that loop, and
  every craft-libs rev moves to that commit.
- apps/vectorcraft-web/Cargo.toml and xtask/src/pdf_deps.rs: the same
  craft-libs rev.
- font_menu tests: a face built in memory with no hinting
  instructions lays out U+05D1 through egui's Fonts with the default
  text options.

Fixes #10493
2026-12-03 13:04:40 -08:00
dotCooCoo e58a626b41 Merge main into fix/open-dwg-files 2026-12-03 11:57:45 -08:00
dotCooCoo bb4e3308af File formats: DWG drawings open and place through the DXF reader
File > Open, File > Place and document.dxfInfo read DWG drawings. The
craft-libs craft-dwg bridge converts the drawing to DXF bytes and the
existing DXF reader reads them, so a DWG takes the DXF Import Options
(layout, ratio or fit, lineweights, centering, merged layers) and comes
in with the same layers, blocks and units as the DXF it converts to.
What the conversion skips is listed in the warnings.

- vectorcraft-cad: dwg module. On desktop the conversion runs in a copy
  of the program started with --dwg-worker (vectorcraft and
  vectorcraft-cli call serve_if_asked and use_own_worker), so a damaged
  file ends that copy, not the app. Inputs over 512 MiB, or a DXF
  rendition over 1 GiB, are refused. The last conversion (up to 128 MiB
  of DXF), or its error, is kept, so the dialog's layout list, each
  layout preview and the open read the file once. R1.x and R2.x
  drawings are refused with a hint to save as DXF.
- Engine: a read-only dwg format (detected by content or by .dwg),
  in the open and place extension lists, not associated with the app
  by packaging. DWG leaves the unsupported list; exporting to it says
  to export DXF instead, Export As keeps it greyed out, and Save over
  the drawing is refused.
- UI: the DXF Import Options dialog opens for .dwg files on Open,
  Place and a Shift-click with the place cursor.
- NOTICE and licenses/acadrust-0.6.6/: acadrust 0.6.6 (MPL-2.0,
  unmodified) and its third-party notices.
- Docs: docs/mcp.md, docs/file-format-parity.md, docs/roadmap.md and
  the progress line in docs/target-app-parity.md.

Tests build DWG files from DXF drawings with craft-dwg's writer: a DWG
comes in as its DXF does (layers, bounds, strokes, units, blocks), with
the DXF options, through Place, and in dxfInfo; a truncated DWG is an
error; saving or exporting a DWG writes nothing.

Fixes #3450
2026-12-03 11:57:39 -08:00
dotCooCoo 014ed9a190 Merge main into feat/3d-rendered-tier 2026-12-03 10:38:52 -08:00
dotCooCoo d180564bb1 Merge main into fix/popout-stable-measure 2026-12-03 10:35:45 -08:00
dotCooCoo 7cba3b786d Links: clicking a link on desktop opens it in the browser again
The desktop app sends every link it opens (Help menu community links, the
app bar's Discord button, Home's Community links, About and credits, help
links in dialogs, the updater's Open URL, an object's URL attribute) as
egui's OpenUrl output. The app built eframe without its `links` feature, so
egui-winit only logged "Cannot open url - feature \"links\" not enabled." and
nothing opened.

Turn on eframe's `links` feature in apps/vectorcraft. Cargo.lock adds
webbrowser 1.2.8. The web build does not use egui-winit and is unchanged.
The feature can be removed once the craft-libs pin includes
storytold/craft-libs#5083, which opens links in the shared app setup.
2026-12-03 09:36:33 -08:00
BFlat 9daf4163eb Merge pull request #10568 from ruchirguitar/fix/web-served-fonts
Web: the site publishes the interface's served fonts under fonts/ui/
2026-12-03 23:14:15 +07:00
.CooCoo 7a14274d56 Merge pull request #10211 from dotCooCoo/feat/vector-3d-materials
3D: Roughness and Metallic on the Materials tab shade and export the surface
2026-12-03 07:21:12 -08:00
.CooCoo 79fdfedfb5 Merge pull request #9075 from dotCooCoo/feat/scripts-api-d8c-rasterize-capture
Scripts: Document.rasterize and Document.imageCapture with their option classes
2026-12-03 07:14:28 -08:00
ruchirguitar e2e4b3b917 xtask: web-fonts writes its scratch table in a private tempfile folder 2026-12-03 14:25:33 +05:30
dotCooCoo 5e68ecd7c8 macOS: closing Preferences no longer crashes on Macs with a Touch Bar
Clicking OK or Cancel in Preferences ended the app with an uncaught
NSRangeException from -[_NSTouchBarFinderObservation invalidate]
whenever the Touch Bar server runs (any Mac with a Touch Bar). When a
window closes, accesskit_macos 0.27.1 put the content view's original
class back, which removed the key-value observing subclass AppKit's
Touch Bar support had installed on the view. AppKit then failed to
remove its observer.

accesskit_macos 0.27.2 leaves the class alone when key-value observing
has subclassed the view (AccessKit/accesskit#835). Cargo.lock moves to
it, with accesskit 0.25.2 and accesskit_consumer 0.39.2, which it
requires.

Fixes #10473
2026-12-02 23:39:52 -08:00
dotCooCoo 14e8959bc0 Scripts: tighten rasterize clip bounds and imageCapture destination checks
- object.rasterize and Document.rasterize refuse clipBounds that reach
  none of the selected objects' own bounds, including a rectangle in the
  gap between two of them, instead of replacing the art with a
  background-only image.
- imageCapture checks its destination again on every write the export
  makes and as the file is committed, so a destination that becomes a
  link to an open document or a linked file while the art renders is
  refused.
- imageCapture refuses a destination whose real path is not valid UTF-8
  instead of writing under a name with its bytes replaced.
- A missing linked file's name in the other Unicode normalization form
  counts as the linked file in folders that ignore the form (macOS, and
  casefolded folders on Linux).
- The hard-link tests skip on volumes without hard links.
- docs/mcp.md: imageCapture rounds clip dimensions to the nearest pixel;
  rasterize rounds fractional dimensions up.
2026-12-02 22:19:16 -08:00
David MannandClaude Opus 5.5 3e699b4d21 feat(automation): agents in the open window through the ArtCraft Launcher's switch
While the launcher's Settings > AI agents switch names VectorCraft, the
window serves its control channel on loopback with craft-libs' AgentLink
and publishes agent-connection.json; plain `vectorcraft-cli mcp` finds it
on every tool call through the shared Live (challenge handshake, no port or
token in client configs) and otherwise runs headless or follows the
closed-app choice. Agent requests in the window are confined to the agent
folders. Preferences gets an AI Integrations page (the shared Agents page),
saved through the new UI command prefs.agents, which agents can't change.
New MCP tool agent_folders; `--when-closed`; `--connect` deprecated.

Closes #10621, closes #1470, closes #10453.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-12-03 02:07:29 +01:00
dotCooCoo df634f8a0b Panels: the Color and Gradient pop-outs run one pass a frame
With the Color or Gradient panel open as a pop-out, every second frame
at rest ran the whole window twice: egui discarded the first pass
because a content column in the panel body measured differently from
the transcript its flyout kept. storytold/craft-libs#4932 fixes the
layout memory, and this moves the craft-libs pin to its head
c2a47dfe, which is craft-libs main 092a2c6b with the fix. The egui and
winit revisions are unchanged.

The bump also brings in craft-libs #4584, #4804, #2415, #4531, #4676,
#3061 and #4050.

Test: with either pop-out open, each of 10 frames at rest runs one pass.
2026-12-02 16:26:28 -08:00
ruchirguitar dd9f8e6d10 Web: the site publishes the interface's served fonts under fonts/ui/
The web interface font stack fetches its craft-fonts faces from the
`fonts/ui/` URLs in SERVED_FONTS, but only crates/text/build.rs's
OUT_DIR held those files: the Trunk hook copied the `fonts/<sha16>/`
faces alone. On a built site every served interface face (Noto Sans
Arabic, Thai and Georgian, NanumGothic, Noto Sans Devanagari) failed to
load, and the interface drew those scripts as missing-glyph boxes.

`cargo xtask web-fonts` now also publishes the `startup` and `demand`
faces of crates/text/web-fonts.txt under `fonts/ui/`, licence beside
each, with the same craft-fonts-build `Embed::serve` that build.rs
uses, so the files match the table's URLs and integrity values.

Test: publishes_the_interface_faces_at_their_served_urls.

Fixes #10567.
2026-12-02 19:43:47 +05:30
dotCooCoo f902da5d30 Merge main into feat/vector-3d-materials 2026-12-02 02:25:15 -08:00
dotCooCoo c0d184b457 Merge main into feat/3d-rendered-tier 2026-12-02 00:28:46 -08:00
dotCooCoo c6c7de257f Dependencies: move the craft-libs pin to craft-libs main 77ade517
craft-libs #4659 (swatch chips that fit a one-column rail) and #4723
have merged, so every craft-libs rev moves from #4659's head edbf2117
to craft-libs main at 77ade517. The egui revisions move to 861d60a6,
the ones that craft-libs rev pins; winit stays at 0dfcec0e. Cargo.lock
changes only the sources of those packages.
2026-12-01 20:14:00 -08:00
dotCooCoo 184978b9a6 Tools: Color, Gradient and None share one line in a one-column rail
craft-libs #4609 measures the Fill and Stroke proxy at the width of its
column, so the proxy no longer widens a one-column Tools panel. The
column is then one rail button less one tight gap wide, and the three
swatch chips (a third of a rail button each, a tight gap apart) took
more than that: None wrapped onto a second line.

The craft-libs pin moves to storytold/craft-libs#4659, which sizes a
swatch chip so the three chips and their gaps fit the column. That rev
also carries #4609 and the other craft-libs changes merged up to
d73e274a. The one-column toolbar test now also checks that the chips
stay inside the column of tools and do not overlap, and a new test
checks the same at UI scale 2.
2026-12-01 14:44:03 -08:00
dotCooCoo 55cba88a89 Merge main into fix/toolbar-chips-one-line 2026-12-01 13:58:56 -08:00
dotCooCoo 7da8771139 Tests: check Affinity pixels and DXF goldens against the formats
The Affinity raster tests compared decoded pixels with CRCs captured from
the reader's own output, so a decoding error present when the CRC was
taken would pass. They now read the image's tiles straight from the
archive (256-byte by 256-row planes, states 2 and 4), interleave them,
scale 16-bit samples with rounding, and compare the whole buffer. The
Affinity 3 signatures drop the CRC of the model's Debug output and keep
the feature counts.

The DXF golden test no longer rewrites its expected files when
WRITE_DXF_GOLDENS is set. Each golden file is first checked against the
drawing it should hold (rectangle corners, circle center, radius and
bulges, ACI and true colors, lineweights), and a mismatch saves the
output to the temp directory for review.
2026-12-01 02:34:00 -08:00
dotCooCoo 93e67218ba Merge feat/vector-3d-materials into feat/3d-rendered-tier 2026-11-30 20:43:17 -08:00
dotCooCoo 946774792a Pin craft-libs at 965c7beeb 2026-11-30 20:40:43 -08:00
dotCooCoo e880f695a2 New Document: Preset Details rows stand a stack gap apart
The Preset Details rows stood a tight gap apart, so each caption touched
the field above it. craft-libs now lays them out a stack gap apart, with
a fixed details column and Create and Close at its foot (storytold/
craft-libs e93e6f62a and e433cdfa8). The pin moves to craft-libs main
26f293d78, which holds both; the egui and winit revisions are unchanged.

- More Settings and Manage Profiles stand side by side, each as wide as
  its words, instead of two buttons across the whole column.
- The pin brings two API changes: CanvasScrollbars::clear_of takes
  ShownBars, and a LegacyFile lists its paths and parses one slot per
  path.
- Accessible names now read a line break as a space, so the Color Wheel
  document-color tests name a swatch "#0000ff Used 1 time".
- The small-window test accepts the Bleed fields in one row when the
  fixed column holds them.
2026-11-30 20:40:26 -08:00
dotCooCoo 86a036f724 Merge main into feat/vector-3d-materials 2026-11-30 15:37:03 -08:00
.CooCoo 90e08df23f Merge pull request #10312 from dotCooCoo/fix/ui-frame-stability
Menus: a menu opens under its title on a monitor beside a portrait one
2026-11-30 15:02:38 -08:00
BFlat 77ed301775 SVG import: refuse an SVG the memory can't hold instead of running out (#10303)
* SVG import: refuse an SVG the memory can't hold instead of running out

The element limit now follows the installed memory, or the process's
cgroup limit where that is lower: about 8 KB an element, up to the
999,999 elements usvg reads. Past it the SVG is refused with an error
naming the memory, before usvg makes its tree.

Fixes #10165

* Tests: the shared element limit test follows the machine's limit
2026-12-01 03:42:59 +07:00
dotCooCoo 58923e0d78 Menus: a menu opens under its title on a monitor beside a portrait one
Moves craft-libs to a5669ed2f, which places overlays in the room of the
monitor the window is on (craft-libs f31beb26d, merged in #4506). The
old room assumed monitors tile the desktop by their size, so on a
landscape monitor to the right of a portrait one the File menu opened
at (726, 442), far from its title, with scroll arrows.

The new pin is craft-libs main just before #4278, whose dialog changes
need VectorCraft test updates that come with a later pin bump.

The new test menu_on_second_monitor opens the File menu with the window
on the landscape monitor at 1x and 1.5x; it fails on the old pin with
the menu at (726, 442).
2026-11-30 12:21:21 -08:00
dotCooCoo 0f3aee366c Merge main into feat/vector-3d-materials 2026-11-30 05:33:55 -08:00
dotCooCoo 1cb36511e9 Merge main into feat/3d-rendered-tier
# Conflicts:
#	Cargo.lock
#	Cargo.toml
#	apps/vectorcraft-web/Cargo.toml
#	xtask/src/pdf_deps.rs
2026-11-30 05:18:11 -08:00
.CooCoo ba67cc58eb Merge pull request #10195 from dotCooCoo/fix/layers-order-revision
Layers: a selection change keeps the panel's row order
2026-11-30 04:21:58 -08:00
dotCooCoo 1c5a867855 3D: Render Settings › Rendered draws the solid as a lit image with shadows from every light
Extrude & Bevel, Revolve, Inflate and Rotate take render.mode "rendered",
with quality (low, medium or high: 1, 2 x 2 or 3 x 3 samples a pixel),
resolution (null for Document Raster Effects Settings, or 1 to 2400 ppi)
and background (transparent or white). The effect then draws its solid
as one image made with craft-raster3d: a depth buffer, the effect's
lights in linear light with the material's roughness and metallic, and
shadow maps for each light, over the effect's vector shadow. The image
lies where the vector faces lie: each mesh point goes through the
projection the effect draws its faces with (MeshProjection).

The shaded faces are drawn instead, and the status bar and the
effect.apply and effect.setParams results carry a "warning", when the
image would pass 16,777,216 pixels at one sample a pixel, or when the
solid is painted with a gradient, a pattern, graphics, an opacity below
100% or a blending mode other than Normal, and for Revolve on a group or
on a fill or stroke. The warning check measures the image without
rasterizing it.

The 3D and Materials panel's Render Settings menu gains Rendered and Low,
Medium and High Quality. Each choice is one undo step for the selection,
and each object keeps its other render settings.

The effect-art cache now includes the document's raster resolution, so
changing Document Raster Effects Settings redraws rendered images.

Every craft-libs rev moves to 64383b59, which adds crates/raster3d.

Docs: docs/three-d.md, docs/mcp.md, docs/target-app-parity.md.
2026-11-30 04:13:14 -08:00
dotCooCoo 41ab3908ef Dependencies: craft-libs moves to 2680a3b3f and egui to 07c20531
craft-libs main at 2680a3b3f adds #4364 (its egui pin moves to
07c20531, which VectorCraft's egui lines now match), #4425, #4409, #4414,
#4406, #4349, #4393, #4392, #4398, #4415, #4411, #4402, #4400, #4417,
#4399, #4407, #4375, #4428 and #4451. winit stays at 0dfcec0e, the rev
craft-libs pins. craft-nightly and craft-web-api move with the other
craft-libs crates, and xtask pdf-deps checks the new rev. Cargo.lock:
epaint_default_fonts now depends on brotli 9.1.3 and brotli-decompressor
6.3.2.
2026-11-30 02:52:53 -08:00
Codex 8cc75fd856 Release: VectorCraft v0.25.1 2026-11-30 11:35:00 +01:00
dotCooCoo b8b8f4c110 Merge main into feat/vector-3d-materials 2026-11-29 23:33:15 -08:00