diff options
author | Tanaka Akira <akr@users.sourceforge.net> | 1999-04-15 18:25:40 +0000 |
---|---|---|
committer | Tanaka Akira <akr@users.sourceforge.net> | 1999-04-15 18:25:40 +0000 |
commit | 8ceb54fbc2f879e0e80f58c18761bd54db07e5f7 (patch) | |
tree | d97bf208b73d5385b174c454e4f41839dc421d25 /Src/Zle/zle_refresh.c | |
parent | 6c1fb551ba0973c9a86e1ea479d553d66c6bf6b7 (diff) | |
download | zsh-8ceb54fbc2f879e0e80f58c18761bd54db07e5f7.tar.gz zsh-8ceb54fbc2f879e0e80f58c18761bd54db07e5f7.tar.xz zsh-8ceb54fbc2f879e0e80f58c18761bd54db07e5f7.zip |
zsh-3.1.5-pws-15 dot-zsh-3.1.5-pws-15-last-snapshot-
Diffstat (limited to 'Src/Zle/zle_refresh.c')
-rw-r--r-- | Src/Zle/zle_refresh.c | 29 |
1 files changed, 23 insertions, 6 deletions
diff --git a/Src/Zle/zle_refresh.c b/Src/Zle/zle_refresh.c index b9f39b70b..1f1063b8d 100644 --- a/Src/Zle/zle_refresh.c +++ b/Src/Zle/zle_refresh.c @@ -53,6 +53,11 @@ int nlnct; /**/ int showinglist; +/* Non-zero if a completion list was displayed. */ + +/**/ +int listshown; + /* Non-zero if ALWAYS_LAST_PROMPT has been used, meaning that the * * screen below the buffer display should not be cleared by * * zrefresh(), but should be by trashzle(). */ @@ -253,13 +258,23 @@ zrefresh(void) if (inlist) return; - if (clearlist) { - invalidatelist(); - moveto(0, 0); - clearflag = 0; - resetneeded = 1; - clearlist = 0; + if (clearlist && listshown) { + if (tccan(TCCLEAREOD)) { + int ovln = vln, ovcs = vcs; + + moveto(nlnct, 0); + tcout(TCCLEAREOD); + moveto(ovln, ovcs); + } else { + invalidatelist(); + moveto(0, 0); + clearflag = 0; + resetneeded = 1; + } + listshown = 0; } + clearlist = 0; + #ifdef HAVE_SELECT cost = 0; /* reset */ #endif @@ -287,6 +302,7 @@ zrefresh(void) moveto(0, 0); t0 = olnct; /* this is to clear extra lines even when */ winchanged = 0; /* the terminal cannot TCCLEAREOD */ + listshown = 0; } #endif resetvideo(); @@ -303,6 +319,7 @@ zrefresh(void) tcout(TCCLEAREOD); else cleareol = 1; /* request: clear to end of line */ + listshown = 0; } if (t0 > -1) olnct = t0; |