2422 Commits
Author SHA1 Message Date
Dylan M. TaylorandDylan Taylor f90d286721 chore: resolve SonarCloud maintainability issues (#1698)
* chore: resolve SonarCloud maintainability issues

- Replace lambda closures with method references (S1612)
- Replace wildcard imports with explicit imports (S2208)
- Refactor complex functions with extracted helpers (S3776)
- Replace OR pattern with range pattern in math parser (S9047)

* style: apply rustfmt to warichu helper

* fix(compose): revert slice conversion in tests and remove unused var in warichu

* Group warichu row layout scalars to satisfy S107 parameter limit

* style: satisfy rustfmt in warichu.rs

---------

Co-authored-by: Dylan Taylor <dylan@craftmaker.dev>
2026-10-24 03:54:24 -04:00
skylar taylor-barrick 00d5fa5cdd M6: reject unreadable PDF trailer history links (#1670)
Reject a non-null Prev entry that cannot be read as an offset instead of silently treating it as the end of the guarded trailer chain. Keep absent/null end markers and readable numeric offsets unchanged.

Reproduced CodeRabbit discussion_r4366245854 with an independent probe and a failing native regression before the fix. The synthetic regression covers seven unreadable value types plus absent/null and integer/real history controls.

Validation: all 9 cargo xtask ci gates passed (3063 tests passed, 6 skipped; 16 WASM-safe crates). One unrelated GPU test was labelled leaky by nextest in that run and passed cleanly in an isolated rerun. Independent checks: 17 original supported PDF variants still pass qpdf, logical preservation and Poppler pixels; 6 original refusal cases remain refused. All 11 additional Prev controls pass (7 refused, 4 accepted).
2026-10-24 00:40:33 -06:00
skylar taylor-barrick 7427a15863 M6: harden placed PDF layer variants (#1670)
Integrate current main (d8d78851) without rewriting the contributor's commits, retaining craft-libs 9f75d3dc.

Accept literal null trailer entries while rejecting actual or ambiguous encryption/hybrid markers. Structurally inspect bounded xref/trailer history instead of adopting trailer-looking comments. Preflight all selected source variants before editing/undo; preserve reset-to-defaults. Suppress stale unrewritable canvas overrides rather than revealing source content. Keep conservative all-content crop fallback without overcropping layerless/null stubs.

Validation: cargo xtask ci, all 9 gates passed; 3062 tests passed, 6 skipped; all 16 WASM-safe crates checked. 17 supported variants passed independent qpdf, logical preservation and Poppler pixel checks; 6 unsupported/repair-only cases refused. Direct-harness Claude Opus 5 reviewed the exact main-relative delta with no blocking findings.

No native-format changes or unrelated layer features. Synthetic regression fixtures are generated in test code.
2026-10-24 00:18:22 -06:00
aiongg d8d7885172 Anchored objects: Relative to Spine mirrors custom positions on right-hand pages (#1702)
* Anchored objects: Relative to Spine mirrors custom positions on right-hand pages

* Anchored objects: page side from the frame's spread position; footnote cache keyed by page side
2026-10-24 01:34:05 -04:00
aiongg 3b71900097 Links: resolve stored paths with craft-docpath's resolve_absolute (#1399)
* Links: use resolve_absolute for stored paths

* Links: check for a missing linked file with is_ok_and

* CI: release only with git dependencies from storytold

The winit patch from skylartaylor/winit at its pinned rev is the one other source allowed.

* Links: Relink to Folder only uses a name that stays a file name in the folder

* CI: the git-sources check reads Cargo.lock as TOML, needs it current and refuses config patches

* CI: the git-sources check parses .cargo/config and .cargo/config.toml for source replacement, patches and paths

* Links: rustfmt

* Links: Relink to Folder only takes a file directly in the chosen folder

* Links: Relink to Folder compares folders as the file system resolves them
2026-10-23 21:19:50 -04:00
Davit MatchakhelidzeandClaude Opus 5.5 80d13911b2 fonts: Georgian UI text from craft-fonts' Noto Sans Georgian (#1270)
* fonts: Georgian UI text from craft-fonts' Noto Sans Georgian

font_definitions registers the Geor face and appends it to every family, like
Arabic (and to the Arabic families after the CJK faces); the wasm filter in
crates/fonts/build.rs keeps the face. The installed-font probe for Geor stays
skipped whenever craft-fonts covers the script. Bump craft-fonts-ref to a71c20e
(storytold/craft-fonts#27).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01YMTAbGNRxnMEzRvYnQGphF

* Release: build the web version with craft-fonts too (web-craft-fonts)

The shared release workflow builds the web release without CRAFT_FONTS_DIR unless web-craft-fonts
is set, so the web version would still have no Georgian face (CodeRabbit on vectorcraft#2934).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01YMTAbGNRxnMEzRvYnQGphF

* test: the Arabic New Document test scrolls to Height like the other fields

With craft-fonts' Noto Sans Arabic (from a71c20e3) the rows above Height are taller, so at
392x271 the field starts partly below the dialog body's clip and the test's unscrolled
visible_label check failed (FreeBSD jobs). It stays reachable: scroll to it as the test
already does for Gutter and the margins.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01YMTAbGNRxnMEzRvYnQGphF

* CI: same craft-fonts pin as release (a71c20e3), so the gate checks the Georgian face

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01YMTAbGNRxnMEzRvYnQGphF

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-23 19:47:45 -04:00
Brandon Thomas 058b369b53 Merge storytold/main into squad/pdfx-unembedded-fonts
# Conflicts:
#	docs/gaps.md
#	docs/target-app-parity.md
2026-10-23 17:30:20 -04:00
Brandon Thomas 79c4ed5d3a Merge pull request #1308 from Silvertree2010/fix/h553-ase-export-corrupts-the-file-whe
Truncate ASE swatch names that overflow the u16 length field
2026-10-23 17:30:14 -04:00
Brandon Thomas 8ce126407e Merge pull request #1310 from Silvertree2010/fix/h572-docx-import-stores-out-of-range
Drop out-of-range font sizes on DOCX import
2026-10-23 17:30:10 -04:00
Brandon Thomas a77660b9fa Merge pull request #1319 from Silvertree2010/fix/h679-docx-xlsx-xml-parser-silently-dr
Keep CDATA text in the DOCX/XLSX XML parser
2026-10-23 17:30:07 -04:00
Brandon Thomas ce7d993f52 Merge pull request #1442 from HEOJUNFO/fix/grey-tiff-device-gray
Export placed greyscale TIFFs as DeviceGray
2026-10-23 17:30:03 -04:00
Brandon Thomas ae550aa670 Merge pull request #1470 from nikolainyegaard/language-picker-order
Preferences: list the languages alphabetically by their own name
2026-10-23 17:29:59 -04:00
Brandon Thomas 807d9b5723 Merge pull request #1491 from Hamza0101/fix/underline-under-tabs
An underline runs across a tab, as the rest of the line's text (#1466)
2026-10-23 17:29:54 -04:00
Brandon Thomas d45a7baf4c Merge storytold/main into fix/h1246-idml-round-trip-renames-styles-w
# Conflicts:
#	crates/idml/src/tests.rs
2026-10-23 17:29:40 -04:00
Brandon Thomas aaa18ad1c2 Merge pull request #1550 from Silvertree2010/fix/h1233-text-frame-column-count-is-trunc
Clamp text frame column count before narrowing to u32
2026-10-23 17:29:35 -04:00
Brandon Thomas 8eb4f5590a Merge storytold/main into feat/cell-rotation-reported
# Conflicts:
#	crates/idml/src/tests.rs
2026-10-23 17:29:22 -04:00
Brandon Thomas 98f957ed6b Merge storytold/main into fix/rtl-first-line-indent
# Conflicts:
#	crates/compose/src/tests.rs
2026-10-23 17:29:07 -04:00
Brandon Thomas 17d197dbef Merge pull request #1567 from Hamza0101/fix/insert-pages-count
A page count Insert Pages cannot mean is refused
2026-10-23 17:29:02 -04:00
Brandon Thomas 44ddf8e857 Merge pull request #1553 from PiMinusMax/gradient-drag-to-swatches
Gradient panel: drag the gradient onto the Swatches panel to keep it
2026-10-23 17:28:58 -04:00
Brandon Thomas 3e783b2671 Merge pull request #1562 from Hamza0101/fix/duplicate-page-in-export-list
A page named twice in an export list is exported once
2026-10-23 17:28:54 -04:00
Brandon Thomas 515796aa1c Merge pull request #1571 from Hamza0101/fix/unique-anchor-name
A text anchor's name is the document's, so it is not reused
2026-10-23 17:28:50 -04:00
Brandon Thomas fc2e42738c Merge pull request #1397 from Silvertree2010/fix/h951-tagged-text-export-strips-from-s
Keep ':', '<', '>' and '\' in Tagged Text style names
2026-10-23 17:28:47 -04:00
Brandon Thomas 132a0816e1 Merge pull request #1376 from Silvertree2010/fix/h869-table-alternating-fill-counts-ar
Saturate table alternating-fill and index paragraph counts
2026-10-23 17:28:43 -04:00
Brandon Thomas 4144b7414d Merge pull request #1378 from Silvertree2010/fix/1337-bug-unable-to-insert-a-multi-pag
Refuse PDF page ranges in the Place PDF dialog instead of using page 1
2026-10-23 17:28:39 -04:00
Brandon Thomas bd418b3913 Merge pull request #1383 from Silvertree2010/fix/1340-bug-the-preview-box-in-the-parag
Remember the Preview checkbox in Paragraph/Character Style Options
2026-10-23 17:28:32 -04:00
Brandon Thomas b892eccaa8 Merge pull request #1368 from Silvertree2010/fix/h836-pica-cicero-formatting-shows-0p0
Fix "-0p0" for tiny negative pica/cicero values
2026-10-23 17:28:27 -04:00
Brandon Thomas dd9ab4b6d9 Merge pull request #1369 from Silvertree2010/fix/h850-polygon-side-count-is-truncated
Clamp polygon side count before narrowing to u32
2026-10-23 17:28:24 -04:00
Brandon Thomas 306292c750 Merge storytold/main into test/backfill-regression-tests
# Conflicts:
#	crates/ui-egui/src/menus.rs
2026-10-23 17:28:11 -04:00
Brandon Thomas abda81d473 Merge pull request #1661 from marcoarnulfo/fix/align-key-object
Align: a click on one of several selected objects makes it the key object
2026-10-23 17:28:06 -04:00
Brandon Thomas 0092906ea8 Merge pull request #1664 from MarekSpodBiedry/issue-1623
idml: explicit zero cell edge weights hide the default table border (#1623)
2026-10-23 17:28:02 -04:00
Brandon Thomas f0907d3831 Merge pull request #1665 from MarekSpodBiedry/issue-1624
find: search and change text inside table cells in document scope (#1624)
2026-10-23 17:27:58 -04:00
Brandon Thomas f3ad8f9a68 Merge pull request #1667 from MarekSpodBiedry/issue-1655
Make the start screen scrollable on short windows (#1655)
2026-10-23 17:27:55 -04:00
Brandon Thomas c6dc102524 Merge pull request #1669 from Silvertree2010/fix/1474-color-settings-a-loaded-icc-work
Reload ICC profiles loaded in Color Settings at start-up
2026-10-23 17:27:51 -04:00
Brandon Thomas b84f268430 Merge storytold/main into fix/1589-audit-dc-08-non-finite-idml-numb
# Conflicts:
#	crates/idml/src/tests.rs
2026-10-23 17:27:37 -04:00
Brandon Thomas c882fd0f58 Merge storytold/main into feat/save-dialog-folder 2026-10-23 17:27:23 -04:00
Brandon Thomas 597fc5c900 Merge pull request #1574 from Hamza0101/fix/character-size-bounds
A type size outside 0.1 to 1296 pt is refused
2026-10-23 17:27:18 -04:00
Brandon Thomas a627c88e45 Merge pull request #1396 from Silvertree2010/fix/h957-rtf-import-wraps-out-of-range-un
Drop out-of-range RTF \uN values instead of wrapping them
2026-10-23 17:27:14 -04:00
Brandon Thomas e70fdb4f14 Merge pull request #1607 from Silvertree2010/fix/h1298-rtf-import-doubles-characters-an
Skip control words and symbols used as RTF \uN fallbacks
2026-10-23 17:27:11 -04:00
Brandon Thomas 0336beb15c Merge pull request #1608 from devius/discord-button-fits-label
ui: the Discord button widens to fit its label instead of spilling out
2026-10-23 17:27:07 -04:00
Brandon Thomas a0b5f6d5c1 Merge pull request #1609 from Silvertree2010/fix/h1332-placing-a-utf-16-plain-text-file
Decode UTF-16 plain text files by BOM on import
2026-10-23 17:27:03 -04:00
Brandon Thomas 89d1c0b4ba Merge pull request #1612 from MarekSpodBiedry/issue-1544
Cursors: paint the tool cursors in the window on Wayland, so they keep the system size (#1544)
2026-10-23 17:26:59 -04:00
Brandon Thomas f064aeed7f Merge pull request #1613 from MarekSpodBiedry/issue-1551
IDML export: write the graphic placed in a table cell (#1551)
2026-10-23 17:26:55 -04:00
Brandon Thomas b04ab04062 Merge pull request #1614 from MarekSpodBiedry/issue-1577
Align towards/away from spine on parent-page folios by page side (#1577)
2026-10-23 17:26:50 -04:00
Brandon Thomas 681e37d2cb Merge pull request #1615 from MarekSpodBiedry/issue-1591
Fix slice panics in the PDF post-passes on malformed page trees and metadata (#1591)
2026-10-23 17:26:46 -04:00
Brandon Thomas dc968ecdff Merge pull request #1629 from marcoarnulfo/feat/autoflow-existing-pages
Autoflow: fill the pages that follow before adding pages at the end
2026-10-23 17:26:42 -04:00
Brandon ThomasandClaude Opus 5.5 1e86a669ca table: the rotation comment names only the IDML import warning
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-23 17:18:56 -04:00
Brandon ThomasandClaude Opus 5.5 253be57a85 layout.pages.insert: range-check the count before narrowing to usize
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-23 17:18:46 -04:00
Brandon ThomasandClaude Opus 5.5 96a3290021 Tagged Text: decode only the escapes we write; other backslashes stay literal
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-23 17:16:26 -04:00
Brandon ThomasandClaude Opus 5.5 50161d0d42 Index: next-paragraph ranges saturate and read the paragraph list with get
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-23 17:15:22 -04:00
Brandon ThomasandClaude Opus 5.5 0d139559bd Place PDF: the page field takes one whole page number of 1 or more
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-23 17:11:13 -04:00