mirror of
https://github.com/storytold/wordcraft.git
synced 2026-10-19 02:10:15 -05:00
move_object anchored the object to the paragraph under the drop point and computed the offset from that paragraph origin. With a Square-wrapped object the surrounding text reflows once the object moves away, so the first paragraph of the target page - the anchor when dropping near its top - slides back to the previous page and the object follows it. Re-check the page after placing an object across pages and re-anchor when the placement did not land on the target page (up to three attempts). Same-page moves still place once, so resize and nudge are unchanged. Adds a kittest that presses, moves and releases onto the top of the next page and asserts the object stays on the page under the pointer. Co-authored-by: Brandon Thomas <echelon@gmail.com>