On 06/04/11 12:54, Stephen Lee wrote:
Hello


I am trying to expand the command window a bit so that it becomes a
simple option selector (I put "set cmdheight=5" in vimrc). I echo
those options like:
(they are longer than the window)

1. Option 1 -- ..............Long
Explanation.................................
2. Option 2 -- ..............Long
Explanation.................................
3. Option 3 -- ..............Long
Explanation.................................
4. Option 4 -- ..............Long
Explanation.................................
5. Option 5 -- ..............Long
Explanation.................................
|<--                         ScrollBar                          -->|


However I cannot make those options nowrap around the end of the line
as it will be ugly like this:

1. Option 1 -- ..............Long Explanation......................
............
2. Option 2 -- ..............Long Explanation......................
............
3. Option 3 -- ..............Long Explanation......................
............
4. Option 4 -- ..............Long Explanation......................
............
5. Option 5 -- ..............Long Explanation......................
............
|<--                         ScrollBar                          -->|


I see the scrollbar but cannot scroll as the lines wrap at the end.
"echo" or "echohl" simply does not listen to "set nowrap" or "setlocal
nowrap". I search a lot including manual and books but cannot find.


I wonder if they follow some basic formatting settings:

When wrap-on:
setlocal linebreak + breakat

When wrap-off:
setlocal scrolloff=2
setlocal sidescrolloff=2


Could anyone tell me how to nowrap the echoes?

Thankyou


Rather than reinventing the wheel, have you tried using the :options command?


Best regards,
Tony.
--
Don't let your mind wander -- it's too little to be let out alone.

--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

Raspunde prin e-mail lui