evil-mode

Emacs Key Binding Precedence

﹥>﹥吖頭↗ 提交于 2019-12-20 06:42:38
问题 I'm frustrated with the default behavior of autocomplete overriding key bindings used by yasnippets . Is there a way to set a precedence so that tab will try to expand a snippet before trying to autocomplete the word? Quick disclosure: I'm using evil-mode. 回答1: If they're both minor modes, then precedence is determined by the order of elements in minor-mode-map-alist which, unless explicitly manipulated, is simply determined by the order in which the libraries were loaded. Ensure that

bind emacs evil window commands to g prefix

强颜欢笑 提交于 2019-12-13 04:46:44
问题 I'm new to Emacs. I have Emacs 24.3.1 with evil mode installed. I'm trying to bind gw as a prefix to the various evil-window functions. For example, I would like gwl to focus the window to the right, and gwh the window to the left. Of course, this is done in vim like so: nnoremap gw <c-w> . In .emacs.d/config/init-bindings.el , I added: (define-key evil-normal-state-map (kbd "g w h") 'evil-window-left) (define-key evil-normal-state-map (kbd "g w j") 'evil-window-down) (define-key evil-normal

key chords in isearch

吃可爱长大的小学妹 提交于 2019-12-08 01:48:57
问题 I really love key-chord.el. It's become an integral part of my workflow, but sometimes I wish I could have them in the minibuffer (for things like evil-search). Specifically, I'd like jj to exit out of evil-search and move down a line. Is this possible? I know I can hack together a command that acts as both a prefix and a command (see this SO question), so I could bind j to a self inserting command, and jj to my special command. How would I be able to break the event loop after a specified

How to map “jj” to Esc in emacs Evil mode

对着背影说爱祢 提交于 2019-12-03 03:31:00
问题 Recently I tried Emacs and found Evil helpful to keep my vim custom. I'm used to typing "jj" to return normal mode from insert mode like many Vimers do but don't know how to make it in Evil mode. I map it like this but seems not correct: (define-key evil-insert-state-map (kbd "jj") 'evil-normal-state) 回答1: This works for me. It requires the KeyChord library: ;;Exit insert mode by pressing j and then j quickly (setq key-chord-two-keys-delay 0.5) (key-chord-define evil-insert-state-map "jj"

How to map “jj” to Esc in emacs Evil mode

我只是一个虾纸丫 提交于 2019-12-02 17:54:06
Recently I tried Emacs and found Evil helpful to keep my vim custom. I'm used to typing "jj" to return normal mode from insert mode like many Vimers do but don't know how to make it in Evil mode. I map it like this but seems not correct: (define-key evil-insert-state-map (kbd "jj") 'evil-normal-state) This works for me. It requires the KeyChord library: ;;Exit insert mode by pressing j and then j quickly (setq key-chord-two-keys-delay 0.5) (key-chord-define evil-insert-state-map "jj" 'evil-normal-state) (key-chord-mode 1) It is inspired by @phils answer above and based on Simon's Coding Blog:

Emacs Key Binding Precedence

ぐ巨炮叔叔 提交于 2019-12-02 07:56:02
I'm frustrated with the default behavior of autocomplete overriding key bindings used by yasnippets . Is there a way to set a precedence so that tab will try to expand a snippet before trying to autocomplete the word? Quick disclosure: I'm using evil-mode. If they're both minor modes, then precedence is determined by the order of elements in minor-mode-map-alist which, unless explicitly manipulated, is simply determined by the order in which the libraries were loaded. Ensure that autocomplete is loaded before yasnippet , and yasnippet's minor mode map would have precedence. You could also use

Difference between Viper, Vimpulse and Evil for Emacs?

无人久伴 提交于 2019-11-30 04:40:10
I have recently started using Emacs after using Vim for a long time now (like many others out there), and I personally feel that Vim movement keys and text objects are one of the best things an editor can have. I heard about emulating these features in Emacs using the different plugins, but after reading a bit more on the internet, I'm confused. I have come across three modes specially: Viper , Vimpulse , and Evil . Can someone please help me out with understanding how to use these modes to achieve a near perfect Vim emulation? Do I need to install all three of them? What is the difference

Software Requirements for Code Creation / Editor with RSI Type Symptoms (unusable fingers)

Deadly 提交于 2019-11-29 08:10:53
I do know and have read the appropriate topics section for this site. I have seen various topics about RSI, posture etc closed as being off topic and referred to another site/section. I think however that my question will be worded such that it comes under the "Software Requirements" section as I am looking for input on specific types as well as configuration of software for some very specific medical issues I have. This is not a topic about prevention of RSI, it is just the closest I can put in a title that people will understand off the bat. I may have already answered my question just by

Difference between Viper, Vimpulse and Evil for Emacs?

随声附和 提交于 2019-11-29 02:07:08
问题 I have recently started using Emacs after using Vim for a long time now (like many others out there), and I personally feel that Vim movement keys and text objects are one of the best things an editor can have. I heard about emulating these features in Emacs using the different plugins, but after reading a bit more on the internet, I'm confused. I have come across three modes specially: Viper , Vimpulse , and Evil . Can someone please help me out with understanding how to use these modes to

Software Requirements for Code Creation / Editor with RSI Type Symptoms (unusable fingers)

孤街醉人 提交于 2019-11-28 01:42:17
问题 I do know and have read the appropriate topics section for this site. I have seen various topics about RSI, posture etc closed as being off topic and referred to another site/section. I think however that my question will be worded such that it comes under the "Software Requirements" section as I am looking for input on specific types as well as configuration of software for some very specific medical issues I have. This is not a topic about prevention of RSI, it is just the closest I can put