Skip to content

Instantly share code, notes, and snippets.

@bronson
Created August 6, 2010 19:13
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bronson/511822 to your computer and use it in GitHub Desktop.
Save bronson/511822 to your computer and use it in GitHub Desktop.
" Make \w toggle through the three wrapping modes.
" Add this to your vimrc:
:function ToggleWrap()
: if (&wrap == 1)
: if (&linebreak == 0)
: set linebreak
: else
: set nowrap
: endif
: else
: set wrap
: set nolinebreak
: endif
:endfunction
map <leader>w :call ToggleWrap()<CR>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment