# Give captures their own coordinates instead of borrowing the editor's · dara/icarus

[View on GitCafe](https://git.cafe/dara/icarus/commit/fd8a351934c231fb1b4d345c59ef93d009e83b8f)

Repository: [dara/icarus](https://git.cafe/dara/icarus)

Visibility: public

Requested revision: fd8a351934c231fb1b4d345c59ef93d009e83b8f

Requested commit: fd8a351934c231fb1b4d345c59ef93d009e83b8f

Commit: fd8a351934c231fb1b4d345c59ef93d009e83b8f

Tree: 5e94b9d2e5159d31543b647ccf637ff3b0f8881a

Author: Dara Adedeji

Committer: Dara Adedeji

## Message

```
Give captures their own coordinates instead of borrowing the editor's

Screenshots and video export switched the app's one CoordinateSystem to
1920x1080 for the whole capture, then switched it back. Anything the
editor did meanwhile used the wrong coordinates, and some of it could
leave the editor stuck in them. A side switch (Shift+F) during a video
export rebuilds the map, which replaces the CoordinateSystem; the export
then restored the old object and left the new one in screenshot mode,
so every stroke drawn afterwards was saved in the wrong place. A drag
while a capture ran was converted the same wrong way.

A capture now runs in a zone that supplies its own 1920x1080
coordinates (CoordinateSystem.runInCapture): inside it, and in every
Future and timer it starts, CoordinateSystem.instance is the capture's;
the editor, whose frames run outside it, keeps its own throughout. The
drawing layer's post-frame path rebuild holds on to the coordinates it
was built with, so in a capture it still sees the capture's.

With the editor never switched, the video dialog no longer flips it for
the export, and neither it nor the screenshot button needs to repair
the editor's drawing paths afterwards.

Tests: a capture keeps its coordinates across its awaits while the
editor re-lays itself out, and the editor's come back unchanged even
when the capture fails; the screenshot and video export tests now check
the editor never sees screenshot coordinates while they run.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

```

## Parents

- [3d8cfab202d52ef33d7475bc90302fc1b3373dc7](https://git.cafe/dara/icarus/commit/3d8cfab202d52ef33d7475bc90302fc1b3373dc7?format=markdown)

[Source at this commit](https://git.cafe/dara/icarus/tree/fd8a351934c231fb1b4d345c59ef93d009e83b8f?format=markdown)
