From fcb097de775cd8609ec1f1b1d3f8285dfb2735fd Mon Sep 17 00:00:00 2001 From: bflatastic Date: Sun, 22 Nov 2026 20:29:30 +0700 Subject: [PATCH] Give a document opened through the session its view when the canvas shows it --- crates/ui-egui/src/canvas.rs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/crates/ui-egui/src/canvas.rs b/crates/ui-egui/src/canvas.rs index 99d3486841..768b4fc27f 100644 --- a/crates/ui-egui/src/canvas.rs +++ b/crates/ui-egui/src/canvas.rs @@ -96,6 +96,8 @@ pub(crate) fn show(app: &mut VectorcraftApp, ui: &mut Ui) { home(app, ui, full); return; } + // A document opened straight through the session has no view yet. + app.sync_views(); let Some(win) = doc_windows::current(app).filter(|_| app.session.active().is_some()) else { // No document and Show The Home Screen When No Documents Are Open off: an empty window. let env = Env::of(ui);