From b65aa7e2a7d473fd6c0bf2964a0e88449d2cc572 Mon Sep 17 00:00:00 2001 From: Conrad Irwin Date: Wed, 13 Mar 2024 15:03:45 -0600 Subject: [PATCH] Fix accidental leak of text stack between frames (#9297) Co-Authored-By: Max Co-Authored-By: Marshall Release Notes: - Fixed a bug where text styles could leak between frames (preview only) Co-authored-by: Max Co-authored-by: Marshall --- crates/gpui/src/window/element_cx.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/crates/gpui/src/window/element_cx.rs b/crates/gpui/src/window/element_cx.rs index 37530ff059..c62ab96fea 100644 --- a/crates/gpui/src/window/element_cx.rs +++ b/crates/gpui/src/window/element_cx.rs @@ -432,6 +432,7 @@ impl<'a> ElementContext<'a> { ); self.window.next_frame.deferred_draws = deferred_draws; self.window.element_id_stack.clear(); + self.window.text_style_stack.clear(); } fn paint_deferred_draws(&mut self, deferred_draw_indices: &[usize]) {