From bbe1a12eeb1b91c843e3b531bd6cd14ed36a7b11 Mon Sep 17 00:00:00 2001 From: RiceDee <345114586+RiceDee@users.noreply.github.com> Date: Tue, 20 Oct 2026 15:29:27 +1100 Subject: [PATCH] test(ui-egui): idle harness scans system fonts before its first frame --- crates/ui-egui/src/idle_tests.rs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/crates/ui-egui/src/idle_tests.rs b/crates/ui-egui/src/idle_tests.rs index 6ae19546..192073b3 100644 --- a/crates/ui-egui/src/idle_tests.rs +++ b/crates/ui-egui/src/idle_tests.rs @@ -26,6 +26,10 @@ pub(crate) struct Harness { impl Harness { pub(crate) fn new(s: Session) -> Self { + // The one system font scan bumps the layout generation, which makes the canvas render + // again: scanned here, before the first frame, rather than by whichever test happens to + // run first while this one waits for idle (#333). + figcraft_text::scan_system_fonts(); Self { ctx: egui::Context::default(), app: FigApp::new(s, Box::new(NoServices)), time: 0.0 } }