aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--vim/vimrc14
1 files changed, 9 insertions, 5 deletions
diff --git a/vim/vimrc b/vim/vimrc
index 45751577..a454246e 100644
--- a/vim/vimrc
+++ b/vim/vimrc
@@ -117,11 +117,6 @@ endif
" do clever things with indenting will often assume this is set
set autoindent
-" Indent broken lines
-if v:version > 704 || v:version == 704 && has('patch338')
- set breakindent
-endif
-
" Use spaces instead of tabs
set expandtab
@@ -511,6 +506,9 @@ nnoremap k gk
if has('linebreak')
set linebreak
set showbreak=...
+ if v:version > 704 || v:version == 704 && has('patch338')
+ set breakindent
+ endif
" Bind \b to turn off linebreak and toggle the showbreak characters on and
" off for convenience of copypasting multiple lines from terminal emulators.
@@ -519,9 +517,15 @@ if has('linebreak')
if &linebreak
set nolinebreak
set showbreak=
+ if v:version > 704 || v:version == 704 && has('patch338')
+ set nobreakindent
+ endif
else
set linebreak
set showbreak=...
+ if v:version > 704 || v:version == 704 && has('patch338')
+ set breakindent
+ endif
endif
endfunction
nnoremap <silent> <leader>b :<C-U>call ToggleBreak()<CR>