diff --git a/doc/unimpaired.txt b/doc/unimpaired.txt index c258f51..6d62009 100644 --- a/doc/unimpaired.txt +++ b/doc/unimpaired.txt @@ -78,6 +78,7 @@ On Off Toggle Option *[ob* *]ob* *yob* 'background' (dark is off, light is on) *[oc* *]oc* *yoc* 'cursorline' *[od* *]od* *yod* 'diff' (actually |:diffthis| / |:diffoff|) +*[oe* *]oe* *yoe* 'conceallevel' (|[oe| and |]oe| cycle conceallevel) *[oh* *]oh* *yoh* 'hlsearch' *[oi* *]oi* *yoi* 'ignorecase' *[ol* *]ol* *yol* 'list' diff --git a/plugin/unimpaired.vim b/plugin/unimpaired.vim index 41872fa..00e3881 100644 --- a/plugin/unimpaired.vim +++ b/plugin/unimpaired.vim @@ -271,6 +271,9 @@ call s:option_map('', 'cursorcolumn', 'setlocal') call s:map('n', '[od', ':diffthis') call s:map('n', ']od', ':diffoff') call s:map('n', 'yod', ':=&diff ? "diffoff" : "diffthis"') +call s:map('n', '[oe', ':set ="conceallevel=".(&conceallevel+1)%4') +call s:map('n', ']oe', ':set ="conceallevel=".float2nr(&conceallevel-1-(4*floor((&conceallevel-1)/4.0)))') +call s:map('n', 'yoe', ':set =&conceallevel ? "conceallevel=0" : "conceallevel=2"') call s:option_map('h', 'hlsearch', 'set') call s:option_map('i', 'ignorecase', 'set') call s:option_map('l', 'list', 'setlocal')