mirror of
https://github.com/itchyny/lightline.vim.git
synced 2025-11-13 05:53:51 -05:00
s/winwidth('.')/winwidth(0)/g
This commit is contained in:
16
README.md
16
README.md
@@ -574,19 +574,19 @@ function! MyFugitive()
|
|||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! MyFileformat()
|
function! MyFileformat()
|
||||||
return winwidth('.') > 70 ? &fileformat : ''
|
return winwidth(0) > 70 ? &fileformat : ''
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! MyFiletype()
|
function! MyFiletype()
|
||||||
return winwidth('.') > 70 ? (strlen(&filetype) ? &filetype : 'no ft') : ''
|
return winwidth(0) > 70 ? (strlen(&filetype) ? &filetype : 'no ft') : ''
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! MyFileencoding()
|
function! MyFileencoding()
|
||||||
return winwidth('.') > 70 ? (strlen(&fenc) ? &fenc : &enc) : ''
|
return winwidth(0) > 70 ? (strlen(&fenc) ? &fenc : &enc) : ''
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! MyMode()
|
function! MyMode()
|
||||||
return winwidth('.') > 60 ? lightline#mode() : ''
|
return winwidth(0) > 60 ? lightline#mode() : ''
|
||||||
endfunction
|
endfunction
|
||||||
```
|
```
|
||||||
When the current window width is narrow, the mode component and the file information component collapse.
|
When the current window width is narrow, the mode component and the file information component collapse.
|
||||||
@@ -671,15 +671,15 @@ function! MyFugitive()
|
|||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! MyFileformat()
|
function! MyFileformat()
|
||||||
return winwidth('.') > 70 ? &fileformat : ''
|
return winwidth(0) > 70 ? &fileformat : ''
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! MyFiletype()
|
function! MyFiletype()
|
||||||
return winwidth('.') > 70 ? (strlen(&filetype) ? &filetype : 'no ft') : ''
|
return winwidth(0) > 70 ? (strlen(&filetype) ? &filetype : 'no ft') : ''
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! MyFileencoding()
|
function! MyFileencoding()
|
||||||
return winwidth('.') > 70 ? (strlen(&fenc) ? &fenc : &enc) : ''
|
return winwidth(0) > 70 ? (strlen(&fenc) ? &fenc : &enc) : ''
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! MyMode()
|
function! MyMode()
|
||||||
@@ -692,7 +692,7 @@ function! MyMode()
|
|||||||
\ &ft == 'unite' ? 'Unite' :
|
\ &ft == 'unite' ? 'Unite' :
|
||||||
\ &ft == 'vimfiler' ? 'VimFiler' :
|
\ &ft == 'vimfiler' ? 'VimFiler' :
|
||||||
\ &ft == 'vimshell' ? 'VimShell' :
|
\ &ft == 'vimshell' ? 'VimShell' :
|
||||||
\ winwidth('.') > 60 ? lightline#mode() : ''
|
\ winwidth(0) > 60 ? lightline#mode() : ''
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! CtrlPMark()
|
function! CtrlPMark()
|
||||||
|
|||||||
@@ -692,15 +692,15 @@ For users who uses lots of plugins:
|
|||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! MyFileformat()
|
function! MyFileformat()
|
||||||
return winwidth('.') > 70 ? &fileformat : ''
|
return winwidth(0) > 70 ? &fileformat : ''
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! MyFiletype()
|
function! MyFiletype()
|
||||||
return winwidth('.') > 70 ? (strlen(&filetype) ? &filetype : 'no ft') : ''
|
return winwidth(0) > 70 ? (strlen(&filetype) ? &filetype : 'no ft') : ''
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! MyFileencoding()
|
function! MyFileencoding()
|
||||||
return winwidth('.') > 70 ? (strlen(&fenc) ? &fenc : &enc) : ''
|
return winwidth(0) > 70 ? (strlen(&fenc) ? &fenc : &enc) : ''
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! MyMode()
|
function! MyMode()
|
||||||
@@ -713,7 +713,7 @@ For users who uses lots of plugins:
|
|||||||
\ &ft == 'unite' ? 'Unite' :
|
\ &ft == 'unite' ? 'Unite' :
|
||||||
\ &ft == 'vimfiler' ? 'VimFiler' :
|
\ &ft == 'vimfiler' ? 'VimFiler' :
|
||||||
\ &ft == 'vimshell' ? 'VimShell' :
|
\ &ft == 'vimshell' ? 'VimShell' :
|
||||||
\ winwidth('.') > 60 ? lightline#mode() : ''
|
\ winwidth(0) > 60 ? lightline#mode() : ''
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! CtrlPMark()
|
function! CtrlPMark()
|
||||||
|
|||||||
Reference in New Issue
Block a user