Sublime Text 2_vim Configuration and quick key settings

Source: Internet
Author: User

1.preferences->settings-user Add the following:

"Ignored_packages": [],                 
"Vintage_start_in_command_mode": true,   //When opening a file for command mode
"Vintage_ctrl_keys": True		//Replace Windows with Vim's CTRL shortcut key

The simple operation of Vim can be modified and the 2nd step is required to use VIM's command mode.


2. Install Vintageex

Download the right side of the page after decompression, put the Packages directory preferences (%%\appdata\roaming\sublime Text 2\packages), can also be Preferences->browse Packages ... Open the directory.

A simple command of vim can be used once the reboot is restarted.


3. Custom shortcut keys

Map the ESC key to a different key and modify the Vintage/default.sublime-keymap file in the packages directory above to add content:

	{"Keys": ["Shift+space"], "command": "Exit_insert_mode",
		"context":
		[	
			{key]: "Setting.command_mode", " Operand ": false},
			{" key ":" Setting.is_widget "," operand ": false}
		]
	},

	{" Keys ": [" Shift+space "]," Command ":" Hide_auto_complete "," context ":
		[
			{" Key ":" Auto_complete_visible "," operator ":" Equal "," operand " : true}
		]
	},

	{"Keys": ["Shift+space"], "command": "Vi_cancel_current_action", "context":
		[
			{"Key": "Setting.command_mode"},
			{"Key": "Selection_empty", "operator": "Equal", "operand": true, "Match_all": false},
			{"key": "Vi_has_input_state " }
		]
	}
The shift+space is mapped to ESC.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

Tags Index: