aboutsummaryrefslogtreecommitdiff
path: root/src/term
diff options
context:
space:
mode:
authorChristian Duerr <contact@christianduerr.com>2018-03-10 20:24:10 +0100
committerJoe Wilm <joe@jwilm.com>2018-06-02 09:56:50 -0700
commit2c7bb9a4d3ce3ead6de4ca6485ca67c44c0bd1c1 (patch)
tree68616e8f2d0c2018d766d8462dc122bea1d70923 /src/term
parente20aa550cbcf7b3f7be6757c007960b3f9b1ac08 (diff)
downloadalacritty-2c7bb9a4d3ce3ead6de4ca6485ca67c44c0bd1c1.tar.gz
alacritty-2c7bb9a4d3ce3ead6de4ca6485ca67c44c0bd1c1.zip
Add scrollback hotkeys
This offers a few additional hotkeys that can be used in combination with scrollback. None of these are used by default yet. This implements the following bindings: - ScrollPageUp: Scroll exactly one screen height up - ScrollPageDown: Scroll exactly one screen height down - ScrollToTop: Scroll as far up as possible - ScrollToBottom: Scroll as far down as possible This fixes #1151.
Diffstat (limited to 'src/term')
-rw-r--r--src/term/mod.rs16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/term/mod.rs b/src/term/mod.rs
index c8017262..8e973b0b 100644
--- a/src/term/mod.rs
+++ b/src/term/mod.rs
@@ -831,6 +831,22 @@ impl Term {
pub fn reset_scroll(&mut self) {
self.grid.reset_scroll_display();
+ self.dirty = true;
+ }
+
+ pub fn scroll_to_top(&mut self) {
+ self.grid.scroll_to_top();
+ self.dirty = true;
+ }
+
+ pub fn scroll_page_up(&mut self) {
+ self.grid.scroll_page_up();
+ self.dirty = true;
+ }
+
+ pub fn scroll_page_down(&mut self) {
+ self.grid.scroll_page_down();
+ self.dirty = true;
}
#[inline]