Thursday, October 28, 2010

Re: difference command line and menu?

On Oct 28, 12:26 am, John Little <john.b.lit...@gmail.com> wrote:
>
> This shows there is indeed a difference between the menu entry and the
> mapping, to do with the range given with the '< and '> marks; using
> the mapping as above fails if the visual selection is still displayed,
> because the marks are entered twice.  You'd need another mapping for
> visual mode:
>
> vmap <F4> :s/^\([-*]\\|\d*\.\)\s*\l/\U&/gc<CR>
>

If I'm not mistaken, you could also use :<C-U>'<,'> instead of
just :'<,'>. I don't think it matters in menus, but in mappings this
will also solve any problems with the user entering a count first.

--
You received this message from the "vim_use" 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

No comments:

Post a Comment