Preserve the former writer as a test-only byte oracle, including the original Brandon Thomas and Nikita Rakitin implementation history. Keep app XML admission and all existing table tests unchanged.
* Shapes: the 3- and 4-bend elbow and curved connectors follow presetShapeDefinitions
PowerPoint routes connectors around shapes with bentConnector4 and 5 and
their curved counterparts. They were drawn as bentConnector3 and
curvedConnector3, using adj1 alone, and curvedConnector2 as a two-cubic
S where the spec has one cubic. Each now draws the spec's path, and the
elbows get a handle per adjust value where the spec puts it.
None of these is in the gallery, so their adjust values had no defaults:
a file giving none, or only adj2, drew them at 0. adjust_defaults() adds
the spec's 50000s for presets outside the gallery, and the reader, writer,
Adjust command and handle drag use it.
* Shapes: elbow handles take the spec's whole adjust range
The handles clamped a dragged value to ±1000000, so dragging one on an
imported route with a value beyond that moved the route. They now take
presetShapeDefinitions' ±2147483647 (noted in review).
deckcraft-color re-exports craft_drawingml::color (Rgba, SchemeSlot,
ColorScheme, ColorTransform, presets and transforms) and its own copy is
deleted. The existing colour tests run unchanged against the shared module.
ColorScheme literals use ColorScheme::new, since the shared scheme also keeps
extra colours and tint rows.
DeckCraft's pptx crate carried a copy of GridCraft's CFB directory walk to tell an
encrypted package from other compound files. It now asks the shared craft-cfb
(has_entry_named, same UTF-16 fallback for damaged directories, directory entries
capped at 4096 as before). The placeholder for missing picture media keeps its
exact bytes, written as a constant instead of through a hand-rolled CRC/Adler/PNG
encoder.
Part of storytold/craft-libs#778 and storytold/craft-libs#792.
Keep both sets of import state: the rollback's kept-chart key log and main's
chart decode budget (rejected_kept, chart_decode_bytes). A capture refused by
the retained-byte check records no key; chart decode work stays charged across
a rollback.
* M1951: document the PPTX slide-list import limit
* M1951: expose the slide-list limit in public API docs
---------
Co-authored-by: cloutier <1014864+cloutier@users.noreply.github.com>
* PPTX: evaluate a custom geometry's guide lists once per coordinate space
* address review: exempt guide-free geometries from the space cap
* address review: budget guide-name bytes cached across coordinate spaces
* Apply review fixes
- crates/pptx/src/custgeom.rs
* fix(pptx): warn when custom geometry paths are left out for the guide-cache limits
---------
Co-authored-by: autocraft-bot[bot] <354215646+autocraft-bot[bot]@users.noreply.github.com>
Review fixes: an entry's size, weight and colour are read from its
paragraph (a:p) first and from a:lstStyle only where the paragraph
sets none, as DrawingML inherits them; the writer keeps sizes to the
reader's 1-400 pt, so a size reads back as written; and the legend
draws an entry at its own size up to 400 pt rather than up to 8 times
the legend's.
A c:legendEntry can give one legend entry its own text (c:txPr), as
decks do to make legend text white on a dark chart. It was never read,
so every entry drew in the legend's text. The chart model keeps each
entry's size, bold and colour (Chart::legend_entries); the reader
takes them from the entry's c:txPr, the legend draws each name, key
and row at its entry's size and in its weight and colour, and a chart
rebuilt after an edit writes them back before c:overlay, in schema
order. Entries that set none of the three are not kept.
Fixes#2067
* PPTX export: stop adding chart series once a group's caches pass a point budget
* address review: size chart exports from the caches each group writes
* address review: cut each chart data cache at a cap far above Excel's 32,000 points per series, so the first series is bounded without failing export
* PPTX: charge repeated chart decodes and sidecar copies to presentation-wide budgets
* address review: count all chart vectors and relationship strings; reject a chart that crosses the presentation limit
* address review: charge chart part names/content types, roll back rejected capture
* address review: bound chart decode work across rejected and repeated references, cache refused sidecar captures
* address review: keep a chart past the presentation chart limits as its original part and closure, so a save writes it back
* pptx: preserve SmartArt node text when dgm:cxnLst has no parent-child connections
* fix(pptx): apply unconnected-point SmartArt outline fallback when type="doc" point is absent
* fix(pptx): restrict SmartArt pt_order fallback to empty parOf graphs and preserve cached Picture/Connector children
* fix(pptx): convert default rect geometry to line for connectors in diagram drawings
* docs(pptx): note flat ptLst order fallback on dgm::outline