diff options
author | Christian Duerr <contact@christianduerr.com> | 2020-07-15 21:27:32 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-07-15 21:27:32 +0000 |
commit | 142f84efb955a9fa59f4205ec3a6db3964c5f433 (patch) | |
tree | 450d1f210dd961de872f8105cdb4290a13194d97 /alacritty_terminal/src/grid | |
parent | d868848ef162ce1d2d5e41b690a592199e9f652d (diff) | |
download | alacritty-142f84efb955a9fa59f4205ec3a6db3964c5f433.tar.gz alacritty-142f84efb955a9fa59f4205ec3a6db3964c5f433.zip |
Add support for searching without vi mode
This implements search without vi mode by using the selection to track
the active search match and advancing it on user input. The keys to go
to the next or previous match are not configurable and are bound to
enter and shift enter based on Firefox's behavior.
Fixes #3937.
Diffstat (limited to 'alacritty_terminal/src/grid')
-rw-r--r-- | alacritty_terminal/src/grid/mod.rs | 2 | ||||
-rw-r--r-- | alacritty_terminal/src/grid/tests.rs | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/alacritty_terminal/src/grid/mod.rs b/alacritty_terminal/src/grid/mod.rs index c1f980e8..5ab25c78 100644 --- a/alacritty_terminal/src/grid/mod.rs +++ b/alacritty_terminal/src/grid/mod.rs @@ -252,7 +252,7 @@ impl<T: GridCell + Default + PartialEq + Copy> Grid<T> { } } - /// Move lines at the bottom towards the top. + /// Move lines at the bottom toward the top. /// /// This is the performance-sensitive part of scrolling. pub fn scroll_up(&mut self, region: &Range<Line>, positions: Line, template: T) { diff --git a/alacritty_terminal/src/grid/tests.rs b/alacritty_terminal/src/grid/tests.rs index 1ed279a0..f86c77b5 100644 --- a/alacritty_terminal/src/grid/tests.rs +++ b/alacritty_terminal/src/grid/tests.rs @@ -56,7 +56,7 @@ fn visible_to_buffer() { assert_eq!(point, Point::new(4, Column(3))); } -// Scroll up moves lines upwards. +// Scroll up moves lines upward. #[test] fn scroll_up() { let mut grid = Grid::new(Line(10), Column(1), 0, 0); @@ -88,7 +88,7 @@ fn scroll_up() { assert_eq!(grid[Line(9)].occ, 0); } -// Scroll down moves lines downwards. +// Scroll down moves lines downward. #[test] fn scroll_down() { let mut grid = Grid::new(Line(10), Column(1), 0, 0); |