summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog7
-rw-r--r--Src/Zle/complist.c5
-rw-r--r--Src/Zle/zle_tricky.c5
3 files changed, 15 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog
index 3555b4490..0eef57c47 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2001-05-08  Sven Wischnowsky  <wischnow@zsh.org>
+
+	* 14251: Src/Zle/complist.c, Src/Zle/zle_tricky.c: print
+	space/backspace when reaching the last column while printing
+	descriptions and the like to avoid a cursor positioning bug
+	depending on the kind of terminal (autowrap)
+
 2001-05-07  Sven Wischnowsky  <wischnow@zsh.org>
 
 	* 14240: Completion/Unix/Type/_files: double all backslashes
diff --git a/Src/Zle/complist.c b/Src/Zle/complist.c
index ffefb7fec..4975a39ae 100644
--- a/Src/Zle/complist.c
+++ b/Src/Zle/complist.c
@@ -576,6 +576,7 @@ clnicezputs(Listcols c, char *s, int ml)
 		    return ask;
 		}
 		col = 0;
+                fputs(" \010", shout);
 	    }
 	}
     }
@@ -895,8 +896,10 @@ compprintfmt(char *fmt, int n, int dopr, int doesc, int ml, int *stop)
 		    continue;
 		}
 		putc(*p, shout);
-		if ((beg = !(cc % columns)) && !stat)
+		if ((beg = !(cc % columns)) && !stat) {
 		    ml++;
+                    fputs(" \010", shout);
+                }
 		if (mscroll && beg && !--mrestlines && (ask = asklistscroll(ml))) {
 		    *stop = 1;
 		    if (stat && n)
diff --git a/Src/Zle/zle_tricky.c b/Src/Zle/zle_tricky.c
index 31556041c..e30bf45e5 100644
--- a/Src/Zle/zle_tricky.c
+++ b/Src/Zle/zle_tricky.c
@@ -1917,8 +1917,11 @@ printfmt(char *fmt, int n, int dopr, int doesc)
 		l += 1 + (cc / columns);
 		cc = 0;
 	    }
-	    if (dopr)
+	    if (dopr) {
 		putc(*p, shout);
+                if (!(cc % columns))
+                    fputs(" \010", shout);
+            }
 	}
     }
     if (dopr) {