Mercurial > vim
changeset 6164:00f58478e38b v7.4.418
updated for version 7.4.418
Problem: When leaving ":append" the cursor shape is like in Insert mode.
(Jacob Niehus)
Solution: Do not have State set to INSERT when calling getline().
author | Bram Moolenaar <bram@vim.org> |
---|---|
date | Fri, 29 Aug 2014 09:02:27 +0200 |
parents | 6ff8e0d745af |
children | ed87285c8ec1 |
files | src/ex_cmds.c src/version.c |
diffstat | 2 files changed, 10 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/src/ex_cmds.c +++ b/src/ex_cmds.c @@ -4011,11 +4011,19 @@ ex_append(eap) eap->nextcmd = p; } else + { + int save_State = State; + + /* Set State to avoid the cursor shape to be set to INSERT mode + * when getline() returns. */ + State = CMDLINE; theline = eap->getline( #ifdef FEAT_EVAL eap->cstack->cs_looplevel > 0 ? -1 : #endif NUL, eap->cookie, indent); + State = save_State; + } lines_left = Rows - 1; if (theline == NULL) break;