Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
tags
*.swp
6 changes: 3 additions & 3 deletions autoload/wrapwidth.vim
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ function! s:SetWrapwidth(on, ll) abort
endfunction

let s:vc = items(#{OptionSet: 'ac', WinResized: 'ad', TextChanged: 'bc',
\InsertLeave: 'bc', WinEnter: 'bc', BufWinEnter: 'bc',
\InsertLeave: 'bc', WinEnter: 'bc', BufEnter: 'bc',
\BufHidden: 'bc', BufUnload: 'bc', BufDelete: 'bc'})

function! s:SetEvent(on) abort
Expand Down Expand Up @@ -227,8 +227,8 @@ function! s:CheckEvent(en, ...) abort
let bw.wd = winwidth(wn)
endif
endfor
elseif ev == 'WinEnter' || ev == 'BufWinEnter'
if ev == 'BufWinEnter' | call s:SetProptype(cb, 1) | endif
elseif ev == 'WinEnter' || ev == 'BufEnter'
if ev == 'BufEnter' | call s:SetProptype(cb, 1) | endif
let bw = getbufvar(cb, s:ww)
if bw.wd != winwidth(cw)
let wl += [cw]
Expand Down