0
0
mirror of https://github.com/vim/vim.git synced 2025-09-24 03:44:06 -04:00

Make CTRL-L in command line mode respect 'ignorecase' and 'smartcase'. (Martin

Toft)
This commit is contained in:
Bram Moolenaar
2010-07-11 20:46:53 +02:00
parent a3f4166286
commit a9dc375744
7 changed files with 62 additions and 50 deletions

View File

@@ -1411,6 +1411,11 @@ getcmdline(firstc, count, indent)
&& !equalpos(curwin->w_cursor, old_cursor))
{
c = gchar_cursor();
/* If 'ignorecase' and 'smartcase' are set and the
* command line has no uppercase characters, convert
* the character to lowercase */
if (p_ic && p_scs && !pat_has_uppercase(ccline.cmdbuff))
c = MB_TOLOWER(c);
if (c != NUL)
{
if (c == firstc || vim_strchr((char_u *)(