diff options
author | Dongdong Zhou <dzhou121@gmail.com> | 2017-02-23 09:53:12 +0000 |
---|---|---|
committer | Björn Linse <bjorn.linse@gmail.com> | 2017-10-26 09:35:12 +0200 |
commit | 6e90bc7200c87f0af448a8cf0998715db9175f15 (patch) | |
tree | 0795eb9366cdc56ed8bfb1058d51922b201c9e4b /src/nvim/eval.c | |
parent | 439c39a2cfb0712eb68ad76354b1fd7e92bb71fe (diff) | |
download | rneovim-6e90bc7200c87f0af448a8cf0998715db9175f15.tar.gz rneovim-6e90bc7200c87f0af448a8cf0998715db9175f15.tar.bz2 rneovim-6e90bc7200c87f0af448a8cf0998715db9175f15.zip |
ext_cmdline: Added cmdline prompt
Diffstat (limited to 'src/nvim/eval.c')
-rw-r--r-- | src/nvim/eval.c | 18 |
1 files changed, 11 insertions, 7 deletions
diff --git a/src/nvim/eval.c b/src/nvim/eval.c index aab777955c..72b97cbab9 100644 --- a/src/nvim/eval.c +++ b/src/nvim/eval.c @@ -11149,15 +11149,19 @@ void get_user_input(const typval_T *const argvars, // Only the part of the message after the last NL is considered as // prompt for the command line. const char *p = strrchr(prompt, '\n'); - if (p == NULL) { + if (ui_is_external(kUICmdline)) { p = prompt; } else { - p++; - msg_start(); - msg_clr_eos(); - msg_puts_attr_len(prompt, p - prompt, echo_attr); - msg_didout = false; - msg_starthere(); + if (p == NULL) { + p = prompt; + } else { + p++; + msg_start(); + msg_clr_eos(); + msg_puts_attr_len(prompt, p - prompt, echo_attr); + msg_didout = false; + msg_starthere(); + } } cmdline_row = msg_row; |