Monday, October 1, 2012

Mapping for visual mode that starts from insert mode?

Hi, I know title is unclear, but my English skill is so limited, forgive
me please, I will try my best to make my expression more clear.

I have set mouse=a, so I can drag mouse to start a selection in
normal/insert mode, I notice that when start selection in normal mode, the
status line will show: -- VISUAL --, when start selection in insert mode,
the status line will show: -- (insert) VISUAL --.

When I have selection in insert mode, I often want to replace/delete the
seleciton, but I don't have this need for the selection starting from
normal mode, so my question is, how to make <key>s and <backspace> can
replace/delete the selection *only* when starts from insert mode.

I don't know if it's clear now, thank you!

--
Regards,
WU Yue

State Key laboratory of Natural Products and Functions
Key Laboratory of Modern Chinese Medicines
Department of Traditional Chinese Medicine
China Pharmaceutical University
No.24, Tongjia Xiang Street, Nanjing 210009, China

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