Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.
gpui: Disable rounding in the layout engine (#31836)
wafflef738fbd4f875
diff --git a/crates/editor/src/editor_tests.rs b/crates/editor/src/editor_tests.rsindex a6460a50483..7f4e19e7d4f 100644--- a/crates/editor/src/editor_tests.rs+++ b/crates/editor/src/editor_tests.rs@@ -15440,7 +15440,7 @@ async fn test_completions_default_resolve_data_handling(cx: &mut TestAppContext)// Completions that have already been resolved are skipped.assert_eq!(*resolved_items.lock(),- items[items.len() - 16..items.len() - 4]+ items[items.len() - 17..items.len() - 4].iter().cloned().map(|mut item| {diff --git a/crates/gpui/src/taffy.rs b/crates/gpui/src/taffy.rsindex 597bff13e2a..f12c62d5043 100644--- a/crates/gpui/src/taffy.rs+++ b/crates/gpui/src/taffy.rs@@ -28,8 +28,10 @@ const EXPECT_MESSAGE: &str = "we should avoid taffy layout errors by constructioimpl TaffyLayoutEngine {pub fn new() -> Self {+ let mut taffy = TaffyTree::new();+ taffy.disable_rounding();TaffyLayoutEngine {- taffy: TaffyTree::new(),+ taffy,absolute_layout_bounds: FxHashMap::default(),computed_layouts: FxHashSet::default(),}