mirror of
https://github.com/storytold/pdfcraft.git
synced 2026-10-25 18:47:22 -06:00
* M7: a moved text box's drag preview shows the box alone (#4464) While an added text box or picture was dragged, the pixels that followed the pointer were cut from the page raster inside the item's box, so whatever the box covered at its first place (a filled shape, a picture, other text) was carried along with it. The drag now renders the item alone too: a copy of the document whose page keeps only the item's own content stream and no annotations, drawn on a transparent page (`pdfcraft_edit::isolate_content`, `Document::added_content_alone`). Those pixels follow the pointer over the page rendered without the item, so what it covered stays put. The preview shows once both rasters are in; until then the item stays where it is, as before. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_0175FWj4xFhMhSH3UpMU8DSC * M7: drop the move preview's earlier rasters when a re-render fails (#4464) When the scale changed after both the page-without-item and item-alone rasters were in, and a render at the new scale failed, only the renderers were cleared. The old textures stayed, so the item kept following the pointer from them although the preview had given up. A failure now clears both texture slots too, so the item stays where it is while dragged. The receive step moves into its own method so a test can drive it with a pool whose renders always fail. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_0175FWj4xFhMhSH3UpMU8DSC --------- Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>