所有模式下的蛇毒模式 [英] Viper mode in all modes

查看:147
本文介绍了所有模式下的蛇毒模式的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我从vi到emacs,使用viper和vimpulse,当我 Cw Cw 到一个窗口时,它变得非常烦人,不能回到原来的一个使用相同的命令,因为可能是帮助缓冲区的其他缓冲区不在Viper模式。我如何解决这个问题?



我尝试添加其他模式到viper配置,并使它们以蛇形模式启动默认使用钩子:

(add-to-list viper-vi-state-mode-list'help-mode)
(add-hook'help-mode(lambda() setq viper-mode t)))

但是这些命令都没有起作用。事实上,第一个产生以下错误:

 
警告(初始化):加载`/ home / konrad /时发生错误。 emacs.d / init.el':

错误的类型参数:symbolp,(basic-mode ...

除了 Cw Cw ,我也怀念无法使用hjkl导航。没有办法重用由viper设置的键绑定,而不是重新绑定对于每个模式?

解决方案

查看我发现的内容: http://www.emacswiki.org/emacs/viper-in-more-modes.el


I'm moving from vi to emacs and, using viper and vimpulse, it gets pretty annoying when I C-w C-w to a window and cannot get back to the original one with the same command because the other buffer, which could be a help buffer, is not in the Viper mode. How can I fix this?

I tried to add other modes to the viper configuration and make them start with the viper mode on by default using hooks:

(add-to-list viper-vi-state-mode-list 'help-mode)
(add-hook 'help-mode (lambda () (setq viper-mode t)))

But none of these commands did work. In fact, the first one yielded the following error:

Warning (initialization): An error occurred while loading `/home/konrad/.emacs.d/init.el':

Wrong type argument: symbolp, (fundamental-mode ...

Besides the C-w C-w, I also miss not being able to navigate using hjkl. Isn't there a way to reuse the keybindings set by viper, instead of rebinding them again for every mode?

解决方案

Look at what I've found: http://www.emacswiki.org/emacs/viper-in-more-modes.el

这篇关于所有模式下的蛇毒模式的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆