Re: test if insert mode

2006-07-19 Thread Benji Fisher
On Tue, Jul 18, 2006 at 11:49:52AM +0200, Eric Smith wrote: How do I implement a conditional to test if in insert or normal mode? Thanks If I am doing anything at all complicated, I use a function: :map F4 :call Foo()CR If I want to do something slightly different depending on the

test if insert mode

2006-07-18 Thread Eric Smith
How do I implement a conditional to test if in insert or normal mode? Thanks -- Eric Smith

Re: test if insert mode

2006-07-18 Thread Yakov Lerner
On 7/18/06, Eric Smith [EMAIL PROTECTED] wrote: How do I implement a conditional to test if in insert or normal mode? There is funciton mode(), but it might not work for you. But see cautionary sentence at the end of :help mode(). People reported problems. if mode() == 'i' in insert mode