forked from 1b-agent/opencadstudio-upstream
- On file open and layout tab switch, restore the camera from the document's saved view (*Active VPort for model space, sheet viewport for paper space) instead of fitting to wire bounds. - After any zoom/pan/rotate, write the new camera position back to the document and mark the file dirty so it is saved with the file. - Uses last_synced_camera_gen to avoid marking the file dirty on the initial camera restore. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>