Commit Graph
7039 Commits
Author SHA1 Message Date
Dylan M. Taylor 86621fbab3 Keep GIF render batches palette-quantized 2026-11-13 22:49:33 +00:00
Dylan M. Taylor 9405f3652b Merge remote-tracking branch 'origin/main' into codex/craft-jxl-extraction 2026-11-13 22:47:47 +00:00
Dylan M. Taylor 4d3e920954 Add shared JPEG XL decoder and encoder 2026-11-13 22:47:47 +00:00
Dylan M. Taylor 888bffcbb3 Add shared DWG-DXF byte bridge 2026-11-13 22:45:07 +00:00
Dylan M. Taylor 92afe40396 Format XFL reader diagnostic test 2026-11-13 22:33:13 +00:00
Dylan M. Taylor 389aef0fda Use neutral errors in shared XFL reader 2026-11-13 22:27:35 +00:00
Dylan M. Taylor f399135165 Merge remote-tracking branch 'origin/main' into codex/gif-animation-writer 2026-11-13 22:22:08 +00:00
Bra1nZ ef03e1b1df fix(print): trust one side of a legacy V3 driver's paper metric
Legacy V3 GDI drivers (HP LaserJet P1102) keep the paper metric in their
DEVMODE extension and report MediaSizeWidth = 0 while the height is right,
so verify_ticket refused with "a paper without a size (a roll?)" and
nothing was sent (storytold/craft-libs#7230).

verify_ticket now fails closed only when neither side is known or the
request itself names no sheet; otherwise it goes on with the requested
size, but only while the side the driver did report agrees with the
request to a quarter of a millimetre. matching_paper gains a partial
record as a candidate of last resort, and driver_ticket takes the wanted
size from the sheet the job asked for, not from the zero record.
The fallback is logged; log moves to the common dependencies so the
warning compiles on Windows too (caught by the windows-gnu check).
2026-11-14 01:19:29 +03:00
Dylan M. Taylor 68b8171b0d Merge pull request #1215 from dylanmtaylor/codex/lightcraft-gif-frame-decode
gif: bound frame decoding and expose ICC metadata
2026-11-13 17:18:28 -05:00
Dylan M. Taylor a9080bf1fd Merge remote-tracking branch 'origin/main' into codex/eps-postscript-api 2026-11-13 22:16:25 +00:00
Dylan M. Taylor 2fea4b4ce2 Merge pull request #1217 from dylanmtaylor/codex/eps-embedded-font-fix
Fix EPS embedded font token scanning
2026-11-13 17:15:50 -05:00
Dylan M. Taylor 6d0b33c0cd Read conventional XLSX shared strings without a relationship 2026-11-13 22:11:05 +00:00
Dylan M. Taylor 6159ef9c39 Bound streaming GIF writer lifecycle 2026-11-13 22:09:54 +00:00
Dylan M. Taylor 8b8603c6e7 Support streaming animated GIF output 2026-11-13 22:08:57 +00:00
Dylan M. Taylor b4d1e249d9 Add bounded XFL FLA package reader 2026-11-13 22:05:11 +00:00
Dylan M. Taylor 2b4f6b4f87 Add shared animated GIF writer 2026-11-13 22:05:00 +00:00
Dylan M. Taylor d62c51645e Add bounded PostScript VM primitives 2026-11-13 21:59:03 +00:00
dotCooCoo 8a2c27ee2d craft-hdr: refuse buffers past isize::MAX bytes when limits are raised
With a raised max_pixels on wasm32, a picture could pass every check and
then ask vec! for more than isize::MAX bytes for its scan line or its
float picture, which panics with a capacity overflow instead of returning
an error.

- decode checks the byte count of the scan line and of the float picture
  against isize::MAX before allocating either, and returns
  LimitExceeded("pixel count") when one is over.
- Each header line is measured as text after invalid bytes become U+FFFD,
  and a line over isize::MAX bytes is LimitExceeded("header length").
- The resolution line reads its first four tokens without collecting the
  rest.
- The size checks take the bound as a value, and tests check them against
  the 32-bit bound without allocating.
2026-11-13 13:43:35 -08:00
Dylan M. Taylor 69e457a8eb Add strict UTF-8 text decoder 2026-11-13 21:38:11 +00:00
Dylan M. Taylor ab51daff1a Respect PostScript delimiters after literal names 2026-11-13 21:29:53 +00:00
dotCooCoo 261e7a4c5c craft-texture: keep image planes within isize::MAX bytes when limits are raised
With raised Limits, a gray image over 512 MiB could be converted to
color on wasm32, where the color plane needs more than isize::MAX bytes
and vec! panics with capacity overflow.

- Limits::check returns TooLarge when the byte count is over isize::MAX,
  so the try_ forms report the size instead of OutOfMemory.
- map, to_color and to_kind clamp each side to 1..=MAX_SIDE when the
  result would be over isize::MAX bytes, and map the top-left part.
- The size checks are pure functions that take the bound as a value, and
  three tests check them against the 32-bit bound without allocating.
2026-11-13 13:28:35 -08:00
Dylan M. Taylor 74337e8fc5 fix(gif): report frame cap after merging 2026-11-13 21:27:44 +00:00
Dylan M. Taylor 4cc86fc7cf Add reusable PostScript EPS scanner 2026-11-13 21:21:47 +00:00
Dylan M. Taylor 24a011ae59 Fix lexical EPS embedded font scanning 2026-11-13 21:17:24 +00:00
dotCooCoo 3c3a83151d craft-texture: add bounded float image planes and texture sampling
Adds crates/texture (craft-texture), the first step of RFC-0032
(storytold/craft-contrib#50). The code comes from MaterialCraft
crates/image/src/lib.rs at 31330629, with its six tests unchanged. No app
uses the crate yet.

Changes from the source:
- Image fields are private; from_data checks the size and the buffer
  length, so a zero side can no longer reach a panic and a short buffer
  is rejected instead of read with defaults.
- Limits caps the side, pixels and bytes; the try_ constructors and
  try_map, try_to_kind, try_resize and try_to_rgba8_display reserve
  memory first and return an error.
- Repeat sampling reduces the coordinate to its fractional part, so the
  period holds at large coordinates.
- Bilinear sampling sums the four weighted texels and skips zero weights;
  box shrinking sums in f64.
- generate_uv clamps the size before computing pixel centers.
- linear_to_srgb(NaN) returns NaN.
- rayon is behind the parallel feature.
2026-11-13 13:14:55 -08:00
Dylan M. Taylor 830e897714 Merge craft-libs main after GIF limits 2026-11-13 21:09:43 +00:00
Dylan M. Taylor b5b8a7750d Merge pull request #1192 from dylanmtaylor/codex/effectcraft-shared-format-cutover
fix: bound GIF allocations and clarify WebP canvas limits
2026-11-13 16:06:01 -05:00
Dylan M. Taylor 61cfc7f3d1 Merge pull request #1212 from storytold/codex/craft-eps-fontscan
Extract embedded PostScript font scanning to craft-eps
2026-11-13 16:05:35 -05:00
Dylan M. Taylor acfcaa1b0e Merge pull request #1209 from storytold/fix/csv-delimiter-quote-boundaries
fix(csv): preserve quoted delimiter coherence
2026-11-13 15:51:25 -05:00
Dylan M. Taylor 669d62e755 docs(gif): clarify combined allocation budget 2026-11-13 20:36:02 +00:00
Dylan M. Taylor dd21ee372d Merge remote-tracking branch 'origin/main' into codex/effectcraft-gif-review-fix 2026-11-13 20:11:02 +00:00
Dylan M. Taylor 142102fc94 Merge remote-tracking branch 'origin/main' into codex/craft-eps-fontscan 2026-11-13 20:02:18 +00:00
Dylan M. Taylor ededdd75c9 gif: expose first-frame data byte count 2026-11-13 19:51:49 +00:00
Dylan M. Taylor 0b73ba5337 Clarify GIF decoder combined allocation budget 2026-11-13 19:43:38 +00:00
aiongg 54c2116152 docs: contract-api and components-index regenerated 2026-11-13 19:30:04 +00:00
aiongg eee9ab4e6d Ramp size roles say what reads them; trials: a container sharing a scrolled view keeps its content height when taller and runs its body at most the draft more than in a plain Stack 2026-11-13 19:26:51 +00:00
aiongg 0b723e6686 Color panel trial: the channel sliders end at one x (shared value and unit columns); SliderField's field-width comment names the column group 2026-11-13 19:26:50 +00:00
aiongg 17b0290d77 docs: a scrolled Stack body shares its view among the children that fill its height 2026-11-13 19:26:50 +00:00
aiongg 05b1103621 Scrolled Stack bodies share their view: the children that fill y take what the view leaves, at least their content, and the body scrolls past it; the Color panel body scrolls in every mode 2026-11-13 19:26:50 +00:00
aiongg fdeeec6d41 cargo fmt 2026-11-13 19:26:50 +00:00
aiongg 7d64b7ddee Faced sliders keep the groove's ramp thickness; a triangle-pointer slider (colour channel) shows its face as a band of size.ramp.bar 2026-11-13 19:26:50 +00:00
aiongg 1e2a432679 SwatchPair: round wells take the pointer in their circle, trial for the well shape per theme; Color panel slider modes: the ramp takes the room the channel rows leave (least size.ramp.bar); SliderField keeps its field width from its measure; story-render --theme/--mode; Fixture::theme_id 2026-11-13 19:26:50 +00:00
aiongg 9a2efb6cbb Color panel: the slider modes' ramp is the body's footer outside the scroll; channel rows in a FieldGroup (shared letter column, FieldGroup::gap); a content-sized text field goes without the short-length floor (hex field sized to # and its digits) 2026-11-13 19:26:50 +00:00
aiongg 833cc71505 Token dumps carry shape.wells 2026-11-13 19:26:50 +00:00
aiongg 5b3749e34a docs: PaintUi::measure in contract-api 2026-11-13 19:26:50 +00:00
aiongg f04b5867fa Color panel look (fix round): channel rows at production density with content-sized fields and the colour band of size.ramp.bar; readout letters and fold; framed edited well; gamut warning beside its swatch; ramp a control tall
- PaintUi::measure: a composite measures a child as PaintUi::child shows it.
- SliderField::field_sizing; the Inline field takes its measured width.
- Slider: the triangle starts under the colour band; TrackLook::ramp is size.ramp.bar.
- NumberField: a field that rounds what it commits is sized at those places; a mixed field is sized as with a value.
- ColorReadout: a wrapping row, the hex field then R, G, B fields after their letters, each content-sized.
- SwatchPair::frame_active; ColorWarningChip::beside.
2026-11-13 19:26:50 +00:00
aiongg c17531be51 cargo fmt 2026-11-13 19:26:50 +00:00
aiongg acb9642b06 Color panel: Sizing::Fill leaves report that they fill; the readout shares its column's width; trials for the cubes' room and one-line channels 2026-11-13 19:26:50 +00:00
aiongg 622f18768c Color panel look: a leaf with Sizing::Fill fills both axes; the Hue and Brightness Cubes take the height the readout leaves; ChannelRow is one line with the channel's letter and a triangle thumb (SliderField::thumb) 2026-11-13 19:26:50 +00:00
aiongg cc4b4ec895 Trial: register the Color panel menu trial with the crate's harness 2026-11-13 19:26:50 +00:00