Skip to content

armgit / zed

Public Imported from GitHub
0

Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.

linux/text: fix invalid span creation (#8286)

Paul Berg9b44ba9382c0
diff --git a/crates/gpui/src/platform/linux/text_system.rs b/crates/gpui/src/platform/linux/text_system.rs
index 683ef6a6629..e4ed7a43cf2 100644
--- a/crates/gpui/src/platform/linux/text_system.rs
+++ b/crates/gpui/src/platform/linux/text_system.rs
@@ -329,7 +329,7 @@ impl LinuxTextSystemState {
let font = &self.fonts[run.font_id.0];
let font = self.font_system.db().face(font.id()).unwrap();
attrs_list.add_span(
- offs..run.len,
+ offs..offs + run.len,
Attrs::new()
.family(Family::Name(&font.families.first().unwrap().0))
.stretch(font.stretch)