Marcus Aurelius wrote:
[...]
If the user wants to edit long lines, (s)he cannot write a quick mapping
on-the-fly, because he needs something like this:
map <buffer> <silent> <up> gk
imap <buffer> <silent> <up> <C-o>gk
map <buffer> <silent> <down> gj
imap <buffer> <silent> <down> <C-o>gj
map <buffer> <silent> <home> g<home>
imap <buffer> <silent> <home> <C-o>g<home>
map <buffer> <silent> <end> g<end>
imap <buffer> <silent> <end> <C-o>g<end>
***May i suggest a new command (or a standard plugin that is easy to find) that
would do all of the above in one easy step?***
Optionally, the user could want this too:
setlocal linebreak
setlocal nolist " Necessary for linebreak
setlocal display+=lastline
I'm not sure if it's OK or if it's going too far :-)
[...]
The following (among others) are set once and for all in my vimrc:
set nojoinspaces
set selection=inclusive keymodel=startsel
set mousemodel=popup selectmode=mouse,key
set laststatus=2
set display=lastline
set list listchars=tab:\|_,eol:ΒΆ
silent! set listchars+=nbsp:~
" Up, Down move up/down by "screen lines"
" j k (default) move down/up by "file lines"
map <Down> gj
imap <Down> <C-O>gj
map <Up> gk
imap <Up> <C-O>gk
No problem for me, and no need to change them from file to file.
Best regards,
Tony.