aboutsummaryrefslogtreecommitdiff
path: root/terminal.h
diff options
context:
space:
mode:
authorDaniel Eklöf <daniel@ekloef.se>2019-10-29 20:09:37 +0000
committerDaniel Eklöf <daniel@ekloef.se>2019-10-29 20:09:37 +0000
commita42df2434b796f19ff729e194dd6a22f5128b89a (patch)
treec95df42d6b884b22c8815661f2391ecdc53ffcef /terminal.h
parentrender: regression: don't apply scroll damage when view is in scrollback (diff)
scrollback: regression: fix rendering of scrollback diffs less than a screen
When doing "small" scrolls (typically done via mouse wheel or similar), we render the scrolling by emitting a "scroll damage". A recent commit changed how scroll damage is rendered; only when the view is at the bottom ("following" the screen output) do we render the damage. To fix this, add a new type of scroll damage, SCROLL_DAMAGE_IN_VIEW and SCROLL_DAMAGE_REVERSE_IN_VIEW. These signal to the renderer that it should always render the damage.
Diffstat (limited to 'terminal.h')
-rw-r--r--terminal.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/terminal.h b/terminal.h
index 6f6e1d53..2a014d90 100644
--- a/terminal.h
+++ b/terminal.h
@@ -129,7 +129,9 @@ struct coord {
int row;
};
-enum damage_type {DAMAGE_SCROLL, DAMAGE_SCROLL_REVERSE};
+enum damage_type {DAMAGE_SCROLL, DAMAGE_SCROLL_REVERSE,
+ DAMAGE_SCROLL_IN_VIEW, DAMAGE_SCROLL_REVERSE_IN_VIEW};
+
struct damage {
enum damage_type type;
/* DAMAGE_SCROLL, DAMAGE_SCROLL_REVERSE */