mirror of
https://github.com/vim-airline/vim-airline.git
synced 2025-12-09 05:24:47 +08:00
shorten filetype only when winwidth is < 90
This commit is contained in:
@@ -84,7 +84,7 @@ function! airline#parts#readonly()
|
|||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! airline#parts#filetype()
|
function! airline#parts#filetype()
|
||||||
return winwidth(0) < 100 && strlen(&filetype) > 3 ? matchstr(&filetype, '...'). (&encoding is? 'utf-8' ? '…' : '>') : &filetype
|
return winwidth(0) < 90 && strlen(&filetype) > 3 ? matchstr(&filetype, '...'). (&encoding is? 'utf-8' ? '…' : '>') : &filetype
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! airline#parts#ffenc()
|
function! airline#parts#ffenc()
|
||||||
|
|||||||
Reference in New Issue
Block a user