summaryrefslogtreecommitdiff
path: root/Src
diff options
context:
space:
mode:
Diffstat (limited to 'Src')
-rw-r--r--Src/Zle/iwidgets.list2
-rw-r--r--Src/Zle/zle_hist.c20
2 files changed, 12 insertions, 10 deletions
diff --git a/Src/Zle/iwidgets.list b/Src/Zle/iwidgets.list
index dc7e8008d..0401397e1 100644
--- a/Src/Zle/iwidgets.list
+++ b/Src/Zle/iwidgets.list
@@ -41,6 +41,7 @@
"digit-argument", digitargument, ZLE_MENUCMP | ZLE_KEEPSUFFIX | ZLE_LASTCOL | ZLE_NOTCOMMAND
"down-case-word", downcaseword, 0
"down-history", downhistory, 0
+"down-line", downline, ZLE_LINEMOVE | ZLE_LASTCOL
"down-line-or-history", downlineorhistory, ZLE_LINEMOVE | ZLE_LASTCOL
"down-line-or-search", downlineorsearch, ZLE_LINEMOVE | ZLE_LASTCOL
"emacs-backward-word", emacsbackwardword, 0
@@ -112,6 +113,7 @@
"universal-argument", universalargument, ZLE_MENUCMP | ZLE_KEEPSUFFIX | ZLE_LASTCOL | ZLE_NOTCOMMAND
"up-case-word", upcaseword, 0
"up-history", uphistory, 0
+"up-line", upline, ZLE_LINEMOVE | ZLE_LASTCOL
"up-line-or-history", uplineorhistory, ZLE_LINEMOVE | ZLE_LASTCOL
"up-line-or-search", uplineorsearch, ZLE_LINEMOVE | ZLE_LASTCOL
"vi-add-eol", viaddeol, 0
diff --git a/Src/Zle/zle_hist.c b/Src/Zle/zle_hist.c
index 44b39d186..bf7b5f46d 100644
--- a/Src/Zle/zle_hist.c
+++ b/Src/Zle/zle_hist.c
@@ -227,14 +227,14 @@ uphistory(UNUSED(char **args))
}
/**/
-static int
-upline(void)
+int
+upline(char **args)
{
int n = zmult;
if (n < 0) {
zmult = -zmult;
- n = -downline();
+ n = -downline(args);
zmult = -zmult;
return n;
}
@@ -270,7 +270,7 @@ int
uplineorhistory(char **args)
{
int ocs = zlecs;
- int n = upline();
+ int n = upline(args);
if (n) {
int m = zmult, ret;
@@ -300,7 +300,7 @@ int
uplineorsearch(char **args)
{
int ocs = zlecs;
- int n = upline();
+ int n = upline(args);
if (n) {
int m = zmult, ret;
@@ -316,14 +316,14 @@ uplineorsearch(char **args)
}
/**/
-static int
-downline(void)
+int
+downline(char **args)
{
int n = zmult;
if (n < 0) {
zmult = -zmult;
- n = -upline();
+ n = -upline(args);
zmult = -zmult;
return n;
}
@@ -358,7 +358,7 @@ int
downlineorhistory(char **args)
{
int ocs = zlecs;
- int n = downline();
+ int n = downline(args);
if (n) {
int m = zmult, ret;
@@ -388,7 +388,7 @@ int
downlineorsearch(char **args)
{
int ocs = zlecs;
- int n = downline();
+ int n = downline(args);
if (n) {
int m = zmult, ret;