diff --git a/examples/editor-orbclient/src/main.rs b/examples/editor-orbclient/src/main.rs index 7127ba9..debcbe9 100644 --- a/examples/editor-orbclient/src/main.rs +++ b/examples/editor-orbclient/src/main.rs @@ -80,6 +80,8 @@ fn main() { loop { let mut force_drag = true; + buffer.shape_until_scroll(); + if buffer.redraw { let instant = Instant::now(); diff --git a/src/buffer.rs b/src/buffer.rs index 61e4ac4..de4afb0 100644 --- a/src/buffer.rs +++ b/src/buffer.rs @@ -354,7 +354,7 @@ impl<'a> TextBuffer<'a> { self.shape_until_scroll(); } - fn shape_until_scroll(&mut self) { + pub fn shape_until_scroll(&mut self) { let lines = self.lines(); let scroll_end = self.scroll + lines;