From f2e4db2f4bf1341f806b0f3dafae544a4f52be71 Mon Sep 17 00:00:00 2001 From: MinusGix Date: Sun, 17 Jul 2022 20:10:24 -0500 Subject: [PATCH] Check if line is at the max in line styles --- lapce-core/src/style.rs | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/lapce-core/src/style.rs b/lapce-core/src/style.rs index 2f5cd51d..9c4b8e8e 100644 --- a/lapce-core/src/style.rs +++ b/lapce-core/src/style.rs @@ -9,7 +9,7 @@ Language, LossyUtf8, Node, Point, Query, QueryCaptures, QueryCursor, QueryError, QueryMatch, Range, Tree, }; -use xi_rope::{spans::Spans, Rope}; +use xi_rope::{spans::Spans, LinesMetric, Rope}; const CANCELLATION_CHECK_INTERVAL: usize = 100; const BUFFER_HTML_RESERVE_CAPACITY: usize = 10 * 1024; @@ -967,6 +967,12 @@ pub fn line_styles( line: usize, styles: &Spans