A simple CPU rendered GUI IDE experience.
Diffstat (limited to 'src/text.rs')
| -rw-r--r-- | src/text.rs | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/text.rs b/src/text.rs index 0c963fc..8dec0ae 100644 --- a/src/text.rs +++ b/src/text.rs @@ -210,7 +210,8 @@ impl Diff { let (cu, co, vo) = self.data[redo as usize]; t.cursor = cu; t.column = co; - t.vo = vo; + t.scroll_to_cursor_centering(); + // t.vo = vo; } } @@ -1768,7 +1769,7 @@ impl<'a> Output<'a> { pub trait CoerceOption<T> { fn coerce(self) -> impl Iterator<Item = T>; } -impl<I: Iterator<Item = T>, T> CoerceOption<T> for Option<I> { +impl<I: IntoIterator<Item = T>, T> CoerceOption<T> for Option<I> { #[allow(refining_impl_trait)] fn coerce(self) -> std::iter::Flatten<std::option::IntoIter<I>> { self.into_iter().flatten() |