help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: viper-ESC-moves-cursor-back affected by Vimpulse


From: Elena
Subject: Re: viper-ESC-moves-cursor-back affected by Vimpulse
Date: Tue, 28 Jul 2009 06:03:41 -0700 (PDT)
User-agent: G2/1.0

On 25 Lug, 19:24, Elena <egarr...@gmail.com> wrote:
> Hello,
>
> I'd like the cursor not moving back whenever I hit ESC to enter
> command mode in Viper. That should be accomplished by setting viper-
> ESC-moves-cursor-back to nil. However, in "emacs -q" such setting
> works, whilst in "emacs -q" plus loading Vimpulse it doesn't.
>
> Here is how I load Viper+Vimpulse:
>
> (setq viper-mode t)
> (setq viper-ex-style-editing nil)
> (require 'viper)
> (setq vimpulse-experimental t)
> (require 'vimpulse "vimpulse-0.3.0.el")
> (setq woman-use-own-frame nil)
> (setq woman-use-topic-at-point t)
>
> Software:
> - GNU Emacs 23.1.50.1
> - Vimpulse 0.30.0
> - Ubuntu Linux 9.04
>
> Thanks

Well, it turned out it was the function "viper-exit-insert-state"
defined by Vimpulse. I had to comment out the final section, like
this:

  ;; (if (and (/= (char-before (point)) ?\r)
  ;;       (/= (char-before (point)) ?\n))
  ;;     (backward-char 1))  ; <---------- a[ESC] leaves the cursor
                                        ; where it was before in VIM, without
                                        ; backward-char it advances 1 character.

Furthermore, I had to put:

(setq viper-ESC-moves-cursor-back nil)

before:

(require 'viper)                           ; load Viper

because nil-ing it by Customize didn't last, even when saved for
future sessions.

Cheers.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]