Commit Graph
24403 Commits
Author SHA1 Message Date
dotCooCoo a7e5bcbaba Dependencies: pin craft-libs at 77ade517
storytold/craft-libs#4634 merged as b942e743. Every craft-libs rev in
Cargo.toml, apps/vectorcraft-web/Cargo.toml, Cargo.lock and
xtask/src/pdf_deps.rs moves from 965c7bee to craft-libs main at
77ade517, which contains that merge. The egui revs move from 07c20531
to 861d60a6, the revs craft-libs pins at 77ade517. winit stays at
0dfcec0e.
2026-12-01 20:39:46 -08:00
dotCooCoo b2cbd0ceaf Merge main into fix/linked-corner-menu-width 2026-12-01 20:39:18 -08:00
.CooCoo 22bc29d69d Merge pull request #10460 from dotCooCoo/fix/test-lint-mirror-false-alarms
xtask: test-lint mirror leaves out entry reads, never-run follows #[path] modules
2026-12-01 20:19:50 -08:00
.CooCoo 50608f3cdf Merge pull request #10519 from dotCooCoo/fix/panels-test-pass
Tests: panel tests check results, not that a list is non-empty or every catalog has a row
2026-12-01 19:41:44 -08:00
.CooCoo 51ea77a565 Merge pull request #10509 from dotCooCoo/fix/drag-frame-ui-cost
Properties: a drag does not measure the panel's sections on each move
2026-12-01 19:32:03 -08:00
.CooCoo 802a869c68 Merge pull request #10517 from dotCooCoo/fix/test-pass-remaining-crates
Tests: assert list lengths and saved names in tool, path, 3D, brush and CAD tests
2026-12-01 19:28:41 -08:00
.CooCoo a5393f577c Merge pull request #10515 from dotCooCoo/fix/tests-render-trace
Tests: render and trace tests check what they claim
2026-12-01 19:22:45 -08:00
.CooCoo e8a6aa85c0 Merge pull request #10513 from dotCooCoo/fix/tests-text-doc
Tests: text and doc tests check what the code returns, not only that it is there
2026-12-01 19:12:22 -08:00
.CooCoo 3860a8025c Merge pull request #10502 from dotCooCoo/fix/common-tangents-metaball
Path Precision Tools: Common Tangents and Smooth Bridge are one dialog
2026-12-01 18:28:19 -08:00
dotCooCoo c1b9fb98c3 Merge main into fix/test-lint-mirror-false-alarms 2026-12-01 18:24:34 -08:00
.CooCoo 2b67583bf0 Merge pull request #10516 from dotCooCoo/test/svg-pdf-eps-pass
Tests: SVG, PDF and EPS tests check what they claim, and a gradient without stops exports as one that pads
2026-12-01 18:24:21 -08:00
.CooCoo d6c378d227 Merge pull request #10512 from dotCooCoo/fix/import-fuzz-tests
Tests: import_fuzz's two regression tests check that their input reaches the export
2026-12-01 18:17:26 -08:00
.CooCoo b12269e64e Merge pull request #10514 from dotCooCoo/chore/tests-color-effects
Tests: color and effects tests check behavior, not their own tables
2026-12-01 18:05:06 -08:00
dotCooCoo 2b50799ed5 Merge main into fix/tests-text-doc 2026-12-01 17:53:19 -08:00
dotCooCoo 5071f17319 Tests: skip the Hebrew mark cluster test when no font covers Hebrew
hebrew_marks_stay_with_base_clusters asserts exact glyph start offsets,
which depend on the face that shapes the word. It now skips, as the
sibling font-dependent tests do, when no installed face covers shin,
lamed, vav and final mem.
2026-12-01 17:53:19 -08:00
.CooCoo 051e5e385f Merge pull request #10368 from dotCooCoo/fix/new-document-spacing
New Document: Preset Details rows stand a stack gap apart
2026-12-01 17:52:03 -08:00
dotCooCoo 86e3970b2a Merge main into fix/panels-test-pass 2026-12-01 17:49:01 -08:00
dotCooCoo 771e73d405 Tests: Hebrew mark clusters must cover the whole word
hebrew_marks_stay_with_base_clusters now calls assert_source_coverage, so
glyphs that start at the four letters but leave the marks out of their
source ranges fail the test.
2026-12-01 17:47:59 -08:00
dotCooCoo 22cdb2f9ab Merge main into fix/tests-render-trace 2026-12-01 17:42:49 -08:00
dotCooCoo c6662b1f24 Tests: presets_resolve checks every listed preset name resolves
`presets()` leaves out a name that `preset` does not know, so the test
now compares its length with `PRESET_NAMES` and checks that list holds 15
names, in place of a fixed count of 15 resolved presets.
2026-12-01 17:42:49 -08:00
dotCooCoo 293bde7afe Tests: panel tests check results, not that a list is non-empty or every catalog has a row
Panel tests that could pass on an empty list, that only checked a control was
there, or that looped over every language or preset now check the result:

- Character, Glyphs and OpenType: the underline, kashida, size, Up/Down, glyph
  form and Proportional Metrics checks compare the text each setting reaches
  (for example "AB" underlined, then none) instead of `all()` over the runs,
  which passed when a frame had no runs.
- Actions: the built-in actions play on a selection and each makes an undo
  step, instead of only looking up their command ids.
- Color Wheel: Show Out-of-Gamut Colors is checked by what the wheel and the
  box draw with it on and off. The test that loaded a profile and only checked
  the box was shown is removed, and two copies of the junk-parameter test are
  removed (the one in tests_color_wheel_vision.rs runs with and without a
  document). The error-translation tests check German and Japanese instead of
  every catalog.
- History and Paragraph: the name and Mojikumi checks use a few languages
  instead of every catalog, and the Numbered List presets are checked by one
  style instead of every number style.
- Graphic Styles, Stroke and Swatches: the rename, profile preview and row
  menu checks count what they read before checking each item.
- Image Trace: the off-thread trace test waits on the trace's own channel
  through a new test-only `trace_runs::finish_all`, instead of polling with a
  sleep for up to 30 seconds.
2026-12-01 17:41:04 -08:00
dotCooCoo ee56902432 Merge main into fix/tests-text-doc 2026-12-01 17:38:46 -08:00
dotCooCoo 52d08f0f9c Tests: SVG, PDF and EPS tests check what they claim
Assertions that ran all() over a list that could be empty now check the
list's length first: mesh points, image inks, glyph origins, imported
text, the PDF mesh and arrowhead paths, and the resampled CMYK pixels.
An image that takes a Warp from its art style is checked to keep none of
the look's fills and strokes, instead of checking each of none.

The convolve-matrix tests check that the filtered rectangle is imported,
not only that the import returned Ok. The fan-out clip path test moves
to a unit test that counts the clip paths read. The self-nesting symbol
test checks that the other symbol comes back. The EPS level and preview
id test checks the param values and the trimming and case rules instead
of looping over every value. The ignored PDF text-heavy timing run says
why it is ignored.

A gradient that repeats or reflects with no stops now paints as one
that pads. Before, PDF export wrote it as two 160 by 160 images and EPS
wrote three runs of a conic where one that pads writes one;
`Gradient::is_spread` is false without stops. `paint.setFill`'s params
still report the spread.
2026-12-01 17:38:19 -08:00
.CooCoo 6c3e10a8fd Merge pull request #10503 from dotCooCoo/fix/gradient-cmyk-sliders
Gradient: the stop popover's CMYK sliders keep the stop's own values
2026-12-01 17:36:51 -08:00
dotCooCoo 4999f88b5d Merge main into fix/test-pass-remaining-crates 2026-12-01 17:35:30 -08:00
dotCooCoo ccf5765419 Tests: assert counts and saved names in tool, path, 3D, brush and CAD tests
Tests whose all() passed on an empty list now check the list's length or
that it is not empty:
- huge_circles_bridge_with_finite_anchors_or_are_refused (pathops bridge)
- smooth_rounds_corners (pathops ops): the four corners stay, smoothed
- a_held_rotation_turns_the_art_around_its_pin (tools ARAP): one point
  per mesh vertex
- the_eraser_drag_area_matches_the_release_when_pressure_or_a_mode_starts_during_the_drag
  (tools gesture): one released point per press
- every_effect_casts_a_shadow, inflate_cells_across_a_hole_edge_are_cut_to_the_shape,
  a_plane_has_only_a_front_and_a_hollow_solid_none and
  perspective_runs_0_to_160_degrees_with_the_eye_outside_the_object (three-d)
- a_file_two_branches_include_is_followed_from_the_shallower_one
  (scriptcheck): one row per include line
- pens_pick_colors_and_widths (cad HP-GL): four widths
- junk_pressure_brushes_draw_finite_art (brush): all 12 cases draw

Round trips that hold by construction (parse finds the id in ALL) are
replaced with one saved name that must parse and one that must not:
follow_names_parse (pathops shared edge), the shape kinds (pathops
shapes), surfaces_parse_from_their_ids (three-d), the Quick Pen actions
(tools), names_parse_and_serialize_as_names (plugins) and the brush
variation modes, which also compare the serde names with the ids.

crop_keeps_an_instance_whose_art_reaches_the_region (cad) names the
entities written instead of checking that some were.
the_saved_engine_preference_is_found (app) pins the GPU choices the
preferences offer to the three the app reads.
timing_unite_1000_circles (pathops) gets an ignore reason and checks
that Unite gives one shape.

Each changed assertion fails when the code under test is broken (an id
renamed, a list emptied, a flush or instance dropped) and passes when it
is restored.
2026-12-01 17:35:21 -08:00
.CooCoo 44522e9b7e Merge pull request #10506 from dotCooCoo/fix/include-bleed-native-files
Export for Screens: Include Bleed files of an artboard hold the bleed once
2026-12-01 17:32:13 -08:00
dotCooCoo bad0792043 Merge main into fix/drag-frame-ui-cost 2026-12-01 17:28:06 -08:00
dotCooCoo 5b2b29c73f Properties: an edit made during a drag is measured when the drag ends
A scrubbed field or a canvas drag moves the revision while the sections
are not measured. When the release itself left the revision unchanged,
the panel skipped the measurement and kept the sizes from before the
drag. The edit now stays pending until a frame runs without a drag or
an open undo group.
2026-12-01 17:28:06 -08:00
dotCooCoo f0dbad051c Tests: render and trace tests check what they claim
Weak tests in vectorcraft-render and vectorcraft-trace now assert the
behavior they name:

- The stroke glow test checks that the glow is drawn and that four
  threads draw what one does, instead of only rendering.
- The JPEG and palette id tests name saved ids and labels directly
  (gray, optimized, none, blackWhite), unknown and empty ids, instead
  of looping over every value and reading its own id back.
- The trace presets test drops the loop over every preset name, which
  presets().len() already covers, and checks the [Default] and padded
  name lookups by their result.
- Nested discs each get the disc below them as parent, checked exactly.
- A 20 degree bend gets no corner under a 30 degree minimum turn, and
  gets one under a 10 degree minimum.
- The gray BMP, reduced CMYK and tiled image tests check the size of
  what they read, and the long stroke tests check that one outline was
  made before checking that none is cropped.
- The three drag timing probes assert that the frame after the drag is
  what a fresh renderer draws, in place of printing two hashes.
2026-12-01 17:25:41 -08:00
dotCooCoo beeeacafe5 Tests: text and doc tests check what the code returns, not only that it is there
Tests in vectorcraft-text and vectorcraft-doc that could pass on an empty
result, or that only checked a result exists, now assert the values:

- Blend: gradient steps assert their stop count before checking each
  stop's swatch, tint and plates; the odd dash blended to solid asserts
  the whole pattern; a copied step asserts its members.
- Symbols: limiting depth keeps every symbol; a stroke override on type
  keeps the run it styles.
- File fonts: an extreme descent clamps to the lowest table value and
  the Windows descent still fits.
- Invert wrap on a tangled shape asserts the line still meets it.
- Bidi, ligature carets, Thai and whitespace fallback: the glyph and
  line counts are asserted, Hebrew points stay in their letters'
  clusters, and every character of an isolate test has a glyph.
- Glyph categories, trace views, compound shape modes and digit
  systems check written-out ids instead of a round trip over every
  value.

Removed joins_on_a_circle_are_measured, which printed measurements and
asserted nothing, and chord_placement_leaves_the_join_gap_above_the_baseline,
which checked arithmetic done in the test itself;
joined_glyphs_meet_on_a_curved_path covers joined type on a curve.
2026-12-01 17:25:24 -08:00
dotCooCoo c58415b307 Tests: color and effects tests check behavior, not their own tables
Parse tests in the color crate looped over every id or label and parsed
it back. Blend modes, policies, harmony rules, recolor methods and WCAG
categories parse by looking the text up in that same table, so those
loops could not fail. They now parse representative ids, labels and
spellings, and the edge cases: "Color" next to "Color Burn", empty
text, and a label where only ids parse.

- default_swatches_parse read swatch.rs as text. It now checks the
  built swatches: no two solid swatches share a color (a bad hex
  literal falls back to black), and the Sunset and Ocean stops equal
  the swatches their literals name.
- loads_system_cmyk_icc ran only on macOS and returned early without
  the system profile. loads_icc_files_and_refuses_bad_ones runs on every
  native target: a missing file is an I/O error naming the path, a file
  that is not a profile is refused, and a built-in profile's bytes are
  refused for their name.
- the_other_libraries_keep_classic_mixing_and_centered_midpoints is
  removed: those libraries are built with Gradient::new's defaults.
- pixel_timings and bench_catalog_lookup are removed. They were ignored
  and only printed timings.
- Checks over lists that can be empty now also check the count:
  reverse and move keep every stop, a conic draws its 4 wedges, each
  harmony gives at least two colors, the fit leaves patches out, the
  wireframe draws edges, a flat warp keeps its anchors, a gradient
  stroke has slices, and fitted dashes on a curve are drawn.
- the_effects_are_colour_adjustments_in_their_own_menu checks one
  add-on effect and one effect outside it instead of every entry.
2026-12-01 17:24:39 -08:00
dotCooCoo 21f9323fcf Tests: import_fuzz's two regression tests check that their input reaches the export
svg_type_shifted_two_billion_points_exports_to_pdf now checks that the
SVG import keeps the type's shift of more than 2,000,000,000 pt, and that
the exported PDF leaves the type out, read back with the PDF importer.
Before, it checked only that the export returned Ok, so an import that
dropped or clamped the shift made it pass without reaching the bound.

a_long_thin_shape_with_a_shadow_renders_and_exports now checks that the
Affinity import gives exactly one shape with a drop shadow, more than
3,000,000 pt wide, before it renders and exports it. Before, an import
that dropped the shadow made it pass without drawing one.

The other 66 test-lint hits in import_fuzz.rs are property tests whose
claim is that hostile input loads, renders and exports without a panic.
Their helpers (survive, survive_library and the others) fail the case
through TestCaseError, which the no-assertion rule does not count.
2026-12-01 17:22:04 -08:00
FredApps b242c6498a Merge pull request #9214 from tareq-halaby/feat/arabic-language-support
refactor(i18n): prepare Arabic language registration and 6-form plurals
2026-12-02 02:21:19 +01:00
dotCooCoo 61fe7e7733 Merge main into fix/test-lint-mirror-false-alarms 2026-12-01 17:06:07 -08:00
dotCooCoo e19e96f810 xtask: test-lint reads base roots, module scopes and whole literals
- Changed mode builds the base's target-root routes from the base tree,
  so a deleted tests/<root>.rs still counts as loading tests/common/mod.rs.
- A base test is matched by its name, its inline modules and its place
  among same-named tests in them, so removing `mod a` does not let
  `a::t` hide a newly off `b::t`.
- reads-source looks through grouping around the read path and names a
  file only from a complete literal, a format!/concat! call or
  Path::new/PathBuf::from; `"data.json".trim_end_matches(".rs")` no
  longer counts as a .rs file.
- mirror keys keep a raw literal whole up to its own delimiter, and a
  key must be one complete string literal.
- for, if let, while let, let and match patterns keep word boundaries
  (`mut n` binds `n`), and a struct pattern's braces are not taken as
  the loop or if-let body.
- #[path] and cfg_attr path values accept raw string literals.
2026-12-01 17:06:07 -08:00
FredApps 7fc3da2964 Merge branch 'main' into feat/arabic-language-support 2026-12-02 01:45:37 +01:00
.CooCoo 5970647dec Merge pull request #10508 from dotCooCoo/fix/quick-pen-touchpad-test-lint
Tests: exempt the macOS-only Quick Pen touchpad test from never-run
2026-12-01 16:18:04 -08:00
dotCooCoo a61a9ba254 Merge main into fix/test-lint-mirror-false-alarms 2026-12-01 16:17:26 -08:00
dotCooCoo a7654fc638 xtask: test-lint matches base tests by place and keeps route kinds apart
- never-run in changed mode lints the file as it was at the base and
  matches a test by its name and its place among tests of that name, so
  a test that was already off is not counted again when lines move.
- A file reached by name inherits only the gates of named declarations,
  and one reached through #[path] only those of #[path] declarations.
- The changed-file walk also reads the base child declarations of a
  #[path]-loaded file, so a removed `mod child;` still reaches the child.
- reads-source classifies the outer path step, not a join nested in its
  argument.
- mirror treats complete raw string literals as keys.
- A raw cfg value keeps the quotes inside it (r#""unix""# is not unix).
- census keeps word boundaries, so `k as usize` reads `k` and the local
  `kasusize` does not.
- fixture-only finds a for loop's `in` across line breaks.
2026-12-01 16:17:26 -08:00
dotCooCoo e1b60100b1 Merge main into fix/drag-frame-ui-cost 2026-12-01 16:14:56 -08:00
dotCooCoo 4bbb277a86 Properties: a drag does not measure the panel's sections on each move
The Properties panel measured all of its sections before showing them
whenever the document's revision changed. A Selection tool drag changes
the revision on every pointer move, so each frame of the drag ran the
whole panel twice. On a blank document with one rectangle, a drag frame
ran 396 components where a hover frame ran 170.

The revision is now kept apart from the selection, tool and isolation
key. While a canvas drag or a scrubbed field is in progress, a new
revision alone does not measure the sections; the edit is measured once
when the drag ends. A drag frame now runs 168 components and each frame
still takes one pass.
2026-12-01 16:14:39 -08:00
FredApps c3d4cd7444 Merge branch 'main' into feat/arabic-language-support 2026-12-02 01:08:16 +01:00
FredApps b13b1457d2 Merge pull request #5450 from Taha-Mahmoodi/svg/export-length-unit
Fix #4462: SVG export can write width and height in mm, cm or in
2026-12-02 01:07:05 +01:00
dotCooCoo a0f7ba0ed1 Tests: exempt the macOS-only Quick Pen touchpad test from never-run
main's CI fails at test-lint since #8808 merged: keys_held_during_a_touchpad_gesture_count_until_it_ends is compiled only on macOS, which no CI test leg runs. egui reports a touchpad gesture's phases only on macOS; on Windows and Linux it reads a touchpad's Ctrl+scroll as a pinch, so the test cannot run there. The allow comment names that reason.
2026-12-01 15:40:44 -08:00
dotCooCoo 2157200131 Merge main into fix/new-document-spacing 2026-12-01 15:38:11 -08:00
FredApps 559a2205d5 Merge branch 'main' into svg/export-length-unit 2026-12-02 00:35:06 +01:00
.CooCoo 3852fa4afb Merge pull request #10484 from dotCooCoo/fix/pathops-cap-reports
Pathfinder: Divide and Live Paint report paths too complex to map
2026-12-01 15:33:36 -08:00
FredApps 5a4a558f5c Merge branch 'main' into svg/export-length-unit 2026-12-02 00:29:33 +01:00
.CooCoo 977062a652 Merge pull request #10462 from dotCooCoo/fix/colorcontrast-isolating-group-test
Tests: check the contrast answer for a Difference square in an isolating group
2026-12-01 15:19:00 -08:00