Cause:
- The presenter rasterises a whole frame once, capped at 16.8 MP (texture_scale), so a 1440 x 9701 frame is drawn at 1.0959 px per unit (1579 x 10632 px).
- On a 2x display at Fit width or 100% the GPU stretches that 1.8x with linear filtering; scrolling only pans, so the same texture is reused.
Fix:
- render: render_area_at(doc, ids, b, scale, time), the GIF-clock form of render_area.
- present/actions.rs: texture_scale split into pure texture_scale_for plus the ctx wrapper; pure detail_plan (the view plus a quarter margin each way, inside the frame, shrunk to the side and pixel caps; None when the whole texture is already at device scale); Presenter::detail_texture caches one detail for the current frame and renders it with render_area_at.
- present/draw.rs: paints the detail right after the base texture, so overlays still paint over it; it is re-rendered when it stops covering the view, and not while a fling, drag or the wheel moves the view (the capped texture shows then).
Verified:
- tall_frame_detail_plan_renders_the_view_at_device_scale: compile error on main (neither function existed).
- presenting_a_tall_frame_on_a_hidpi_display_draws_the_view_at_device_scale: failed on main at the size[0] >= 2878 assert (only present texture 1579 x 10632).
- present tests 99 passed; figcraft-ui-egui --lib 1107 passed; figcraft-render --lib 245 passed; clippy -D warnings, fmt and cargo xtask wasm clean.
Not changed:
- Transitions, smart animate, overlays, the bar thumbnail and the pane keep the capped whole-frame texture; MAX_TEXTURE_PIXELS is unchanged; no tiling.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Model-Effort: Opus 5.5 drove; Fable 5.1 briefed; Sonnet 5.5 wrote at medium
An instance scaled with the Scale tool in Figma stores `symbolData.uniformScaleFactor`; the importer never read it, so the layers of a 128 px instance of a 256 px component came in at 256 px with the main's radii, strokes and spacing. Layers of an instance now take the main's lengths times the factor (composed through nested instances), the same values the Scale tool scales, unless an override or derived row gives the value, which is already at the instance's scale. Eight tests: the reproducer, the round trip, a derived size row not scaled twice, override rows, auto layout gap/padding/text, nested composition, factor 1 or none, and junk factors ignored.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Model-Effort: Opus 5.5 drove; Opus 5.5 briefed; Sonnet 5.5 wrote at high