by agate - Published: 2010-04-10 [10:07 下午] - Category: 软件使用
Tags: [ ] - Comments: View Comments
by agate - Published: 2008-12-07 [8:18 上午] - Category: 开发环境

i feel uncomfortable while i using vim and having to move way up to reach Escape key. so i swaped the Escape and CapsLock keys by under steps:

first, open your terminal. and type:
$vim ~/.xmodmap

second, add under statements into ./xmodmap file.
remove Lock = Caps_Lock
keysym Caps_Lock = Escape
keysym Escape = Caps_Lock
add Lock = Caps_Lock

last, restart your X env.
(maybe you can use CTRL + ALT + BackSpace)

after these configurations, i found it's easier than move way up to reach Esc while using vim.

ps. thanks forrest, thanks leon! i found i fell in love with vim!!! it's really powerful!

Tags: [ , , ] - Comments: View Comments
by agate - Published: 2008-11-03 [12:32 下午] - Category: 开发环境

我是使用 Ubuntu 操作系统的, 其默认的终端编码方式是 UTF-8. 在我使用中文语言作为系统的语言环境后, 我在使用 VIM 自带的 Tutor 教程学习的时候就出现了乱码现象. 究其原因是因为默认中文的 Tutor 是以 GB2312 的编码方式进行编码的. 所以很简单的解决方式是:
$sudo cp /usr/share/vim/vim71/tutor/tutor.zh.euc /usr/share/vim/vim71/tutor/tutor.zh.euc_bak
$sudo gedit /usr/share/vim/vim71/tutor/tutor.zh.euc
另存为 --> 设置为 UTF-8 编码 --> 确认 --> Done

解决! 这里注意的是不同的操作系统可能 VIM 安装的路径以及版本不同, 具体的修改一下就好了!

Tags: [ ] - Comments: View Comments