Support Multiple Cursor mode
Detect the use of plugin https://github.com/mg979/vim-visual-multi and show mode "MULTI" when it is active. closes #1933
This commit is contained in:
parent
826561daf3
commit
28453d7038
@ -20,6 +20,7 @@ This is the Changelog for the vim-airline project.
|
|||||||
recreating the highlighting groups (which might have a serious performance
|
recreating the highlighting groups (which might have a serious performance
|
||||||
impact if done very often, as might be the case when the configuration variable
|
impact if done very often, as might be the case when the configuration variable
|
||||||
`airline_skip_empty_sections` is active).
|
`airline_skip_empty_sections` is active).
|
||||||
|
- airline can now also detect multiple cursor mode (issue #1933)
|
||||||
|
|
||||||
## [0.10] - 2018-12-15
|
## [0.10] - 2018-12-15
|
||||||
- New features
|
- New features
|
||||||
|
@ -226,7 +226,11 @@ function! airline#check_mode(winnr)
|
|||||||
else
|
else
|
||||||
let l:mode = ['normal']
|
let l:mode = ['normal']
|
||||||
endif
|
endif
|
||||||
if index(['Rv', 'no', 'ni', 'ix', 'ic'], l:m) == -1
|
if exists("*VMInfos") && !empty(VMInfos())
|
||||||
|
" Vim plugin Multiple Cursors https://github.com/mg979/vim-visual-multi
|
||||||
|
let l:m = 'multi'
|
||||||
|
endif
|
||||||
|
if index(['Rv', 'no', 'ni', 'ix', 'ic', 'multi'], l:m) == -1
|
||||||
let l:m = l:m[0]
|
let l:m = l:m[0]
|
||||||
endif
|
endif
|
||||||
let w:airline_current_mode = get(g:airline_mode_map, l:m, l:m)
|
let w:airline_current_mode = get(g:airline_mode_map, l:m, l:m)
|
||||||
|
@ -40,6 +40,7 @@ function! airline#init#bootstrap()
|
|||||||
\ 'i' : 'INSERT',
|
\ 'i' : 'INSERT',
|
||||||
\ 'ic' : 'INSERT COMPL',
|
\ 'ic' : 'INSERT COMPL',
|
||||||
\ 'ix' : 'INSERT COMPL',
|
\ 'ix' : 'INSERT COMPL',
|
||||||
|
\ 'multi' : 'MULTI',
|
||||||
\ 'n' : 'NORMAL',
|
\ 'n' : 'NORMAL',
|
||||||
\ 'ni' : '(INSERT)',
|
\ 'ni' : '(INSERT)',
|
||||||
\ 'no' : 'OP PENDING',
|
\ 'no' : 'OP PENDING',
|
||||||
|
@ -182,6 +182,7 @@ values):
|
|||||||
\ 'ic' : 'I',
|
\ 'ic' : 'I',
|
||||||
\ 'ix' : 'I',
|
\ 'ix' : 'I',
|
||||||
\ 'n' : 'N',
|
\ 'n' : 'N',
|
||||||
|
\ 'multi' : 'M',
|
||||||
\ 'ni' : 'N',
|
\ 'ni' : 'N',
|
||||||
\ 'no' : 'N',
|
\ 'no' : 'N',
|
||||||
\ 'R' : 'R',
|
\ 'R' : 'R',
|
||||||
@ -194,6 +195,7 @@ values):
|
|||||||
\ 'V' : 'V',
|
\ 'V' : 'V',
|
||||||
\ '' : 'V',
|
\ '' : 'V',
|
||||||
\ }
|
\ }
|
||||||
|
Note: 'multi' is for displaying the multiple cursor mode
|
||||||
<
|
<
|
||||||
* define the set of filename match queries which excludes a window from having
|
* define the set of filename match queries which excludes a window from having
|
||||||
its statusline modified >
|
its statusline modified >
|
||||||
|
Loading…
Reference in New Issue
Block a user