Error: "nothing in register" for visual block mode

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Error: "nothing in register" for visual block mode

Ulrich Leopold
Dear list,

I tried to install gvim-6.3 under Windows XP updated version. When trying to
use the visual block mode with crtl+v I get the error message "nothing in
register". How can this be solved?

I installed gvim on several other machines with Windows without getting this
message. Is it related to Windows, or the language settings or something else?

Cheers, Ulrich
Reply | Threaded
Open this post in threaded view
|

Re: Error: "nothing in register" for visual block mode

Stefan Karlsson-3
Your ctrl-v is probably mapped to behave like in Windows (i.e. to
paste). Type :map to see which mappings are active.

The ctrl-v is mapped to behave this way in mswin.vim, so check if you
source this file (e.g. in your .vimrc).

-- Stefan



Ulrich Leopold wrote:

>Dear list,
>
>I tried to install gvim-6.3 under Windows XP updated version. When trying to
>use the visual block mode with crtl+v I get the error message "nothing in
>register". How can this be solved?
>
>I installed gvim on several other machines with Windows without getting this
>message. Is it related to Windows, or the language settings or something else?
>
>Cheers, Ulrich
>
>  
>
Reply | Threaded
Open this post in threaded view
|

Re: Error: "nothing in register" for visual block mode

A.J.Mechelynck
In reply to this post by Ulrich Leopold
----- Original Message -----
From: "Ulrich Leopold" <[hidden email]>
To: <[hidden email]>
Cc: <[hidden email]>
Sent: Tuesday, August 30, 2005 10:11 AM
Subject: Error: "nothing in register" for visual block mode


> Dear list,
>
> I tried to install gvim-6.3 under Windows XP updated version. When trying
> to
> use the visual block mode with crtl+v I get the error message "nothing in
> register". How can this be solved?
>
> I installed gvim on several other machines with Windows without getting
> this
> message. Is it related to Windows, or the language settings or something
> else?
>
> Cheers, Ulrich

I believe someone has slipped mswin.vim into your vimrc. This is what I
suggest:

Method I: Check your vimrc on the "problem" machine, and if you find a line
like

    source $VIMRUNTIME/mswin.vim
or
    runtime mswin.vim

delete it. [That script only creates non-Vim-compatible mappings, in the
(IMHO misguided) hope to make Vim "more friendly" to Windows users. I don't
use it, and it doesn't give me any problems.]
=Note:= If you see "source $VIMRUNTIME/vimrc_example.vim" or "runtime
vimrc_example.vim", do NOT delete it. *That* script contains a lot of useful
settings. If you don't like some of them, change them _after_ sourcing the
script.

Method II: Use Ctrl-Q instead of Ctrl-V (not only for block-visual but also
in Insert and Command-line modes).

Method III: use an other keystroke, for instance F12, by means of the
following mappings:

    noremap    <F12>    <C-V>
    noremap!    <F12>    <C-V>

where < is less-than, > is greater-than, and all the rest is also typed
as-is.


Best regards,
Tony.