On 7/17/12, Christian Brabandt <cbli...@256bit.org> wrote:
>
> One way around it, is to use an expression mapping, e.g. something
> like this:
>
>  :map <expr> <F5> QuoteWord()
>
> fu! QuoteWord()
>      let r=''
>      if col('.') > 1
>         let r.='h'
>     endif
>     let r.='Ea"'. "\<Esc>Bi". '"'. "\<Esc>"
>     if line('.') < line('$')
>         let r.='j'
>     endif
>     return r
> endfu
>
> Or make use of the text-object (:h text-object)
> :map <f5> ciW"<C-R>""<Esc>j
>
> regards,
> Christian
>
>
I thank you both for your help, Christian and Gary, that does both
reveal and solve the problem.

-- 
Graham Lawrence

-- 
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

Reply via email to