summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--term.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/term.c b/term.c
index 52e9257..c71d4dc 100644
--- a/term.c
+++ b/term.c
@@ -202,8 +202,13 @@ ACTION(nl) {
 		Y = MIN(Y + 1, B);
 	}
 }
-ACTION(ind) { scrollUp(t, 1); }
-ACTION(ri)  { scrollDown(t, 1); }
+ACTION(ri) {
+	if (Y == t->scroll.top) {
+		scrollDown(t, 1);
+	} else {
+		if (Y) Y--;
+	}
+}
 ACTION(su)  { scrollUp(t, MIN(P(0, 1), t->scroll.bot - t->scroll.top)); }
 ACTION(sd)  { scrollDown(t, MIN(P(0, 1), t->scroll.bot - t->scroll.top)); }
 ACTION(decstbm) {
@@ -364,7 +369,6 @@ static Action *Actions[][128] = {
 	[ESC]['8'] = decrc,
 	[ESC]['='] = nop,
 	[ESC]['>'] = nop,
-	[ESC]['D'] = ind,
 	[ESC]['M'] = ri,
 	[ESC]['['] = csi,
 	[ESC][']'] = osc,
d> 2014-01-09README: Fix dependenciesLukas Fleischer * Remove the dependency on Git (which can be obtained automatically when building, using either the Git submodule or `make get-git`). * Use proper upstream names of dependencies. Signed-off-by: Lukas Fleischer <cgit@cryptocrack.de> 2014-01-08README: Spelling and formatting fixesLukas Fleischer * Several small spelling and capitalization fixes. * Use consistent and better-looking formatting that is compatible with AsciiDoc (and partly compatible with RST). Signed-off-by: Lukas Fleischer <cgit@cryptocrack.de> 2014-01-08Fix UTF-8 with syntax-highlighting.pyPřemysl Janouch Previously the script tried to encode output from Pygments with the ASCII codec, which failed. Signed-off-by: Přemysl Janouch <p.janouch@gmail.com> 2014-01-08Add a suggestion to the manpagePřemysl Janouch So that people wishing to use "enable-http-clone" don't have to find out the correct settings on their own. Signed-off-by: Přemysl Janouch <p.janouch@gmail.com> 2014-01-08Fix the example configurationPřemysl Janouch "enable-git-clone" doesn't exist, replaced with "enable-http-clone". Signed-off-by: Přemysl Janouch <p.janouch@gmail.com> 2014-01-08Fix about-formatting.shPřemysl Janouch dash failed to parse the script. Signed-off-by: Přemysl Janouch <p.janouch@gmail.com> 2014-01-08Fix some spelling errorsPřemysl Janouch Signed-off-by: Přemysl Janouch <p.janouch@gmail.com> 2014-01-08filters: highlight.sh: add css comments for highlight 2.6 and 3.8Ferry Huberts