LinuxSir.cn,穿越时空的Linuxsir!

 找回密码
 注册
搜索
热搜: shell linux mysql
12
返回列表 发新帖
楼主: slinger

独立界面的emacs有什么好处呢?

[复制链接]
发表于 2006-5-3 12:45:54 | 显示全部楼层
我看了还有一个emacs2.map.gz,我加载那个东西仍然是不行的。
回复 支持 反对

使用道具 举报

发表于 2006-5-3 14:01:53 | 显示全部楼层
Oh I see. I was thinking you cannot use the left alt as the meta key.

Actually the right alt is reserved as AltGr. to see this, invoke
dumpkeys | grep Gr
and the keycode associated should be 100, which is the right alt key. This 100 can be obtained by running
showkeys
and then pressing your right alt key.

So, to assign the right alt as meta, you can now invoke
echo 'keycode 100 = Alt' | loadkeys
回复 支持 反对

使用道具 举报

发表于 2006-5-3 15:44:28 | 显示全部楼层
Post by galilette
Oh I see. I was thinking you cannot use the left alt as the meta key.

Actually the right alt is reserved as AltGr. to see this, invoke

and the keycode associated should be 100, which is the right alt key. This 100 can be obtained by running

and then pressing your right alt key.

So, to assign the right alt as meta, you can now invoke

哈哈!谢谢galilette,这下弄好了!不过有几点:
1。是 showkey 不是 showkeys ,我好不容易才从那个程序里面退出来,好像是等一会不按任何键就可以退出了。
2。光echo 'keycode 100 = Alt' | loadkeys是不行的,反正这样好像把键搞得乱七八糟的,我拷贝了/usr/share/keymaps/i386/qwerty/emacs.map.gz并把那行添加进去,在加载他就可以用了!
这下好了!呵呵!谢谢!
回复 支持 反对

使用道具 举报

发表于 2006-5-3 15:47:19 | 显示全部楼层
:ask: loadkeys 好像要root权限才能执行的,把他添加到哪个文件里面让他开机自动执行比较合适呢?
回复 支持 反对

使用道具 举报

发表于 2006-5-3 15:51:04 | 显示全部楼层
/etc/conf.d/local.start
回复 支持 反对

使用道具 举报

发表于 2006-5-3 16:13:18 | 显示全部楼层
Post by galilette
/etc/conf.d/local.start

不好意思,那个文件是干什么用的,因为我用的是Debian,不是Gentoo,好像我这儿没有这个文件,那个文件对应于Debian的文件是什么呀?:ask
回复 支持 反对

使用道具 举报

发表于 2006-5-3 16:58:00 | 显示全部楼层
Post by pluskid
哈哈!谢谢galilette,这下弄好了!不过有几点:
1。是 showkey 不是 showkeys ,我好不容易才从那个程序里面退出来,好像是等一会不按任何键就可以退出了。
2。光echo 'keycode 100 = Alt' | loadkeys是不行的,反正这样好像把键搞得乱七八糟的,我拷贝了/usr/share/keymaps/i386/qwerty/emacs.map.gz并把那行添加进去,在加载他就可以用了!
这下好了!呵呵!谢谢!
first, about the `echo | loadkeys' thing. Yes you are right. I checked `man keymaps', and I think the following will do the job:
echo -e `dumpkeys | grep keymaps` '\nkeycode 100 = Alt' | loadkeys

second, about debian. I happen to have access to a debian workstation. after browsing the /etc directory, I think all u need is to find /etc/console-tools/remap, and add a line like
s/AltGr/Alt/;
you may check debian's policy manual ( http://www.debian.org/doc/debian-policy/ ) for how to customizing startup keymaps the debian way.
回复 支持 反对

使用道具 举报

发表于 2006-5-3 18:36:44 | 显示全部楼层
Post by galilette
first, about the `echo | loadkeys' thing. Yes you are right. I checked `man keymaps', and I think the following will do the job:


second, about debian. I happen to have access to a debian workstation. after browsing the /etc directory, I think all u need is to find /etc/console-tools/remap, and add a line like

you may check debian's policy manual ( http://www.debian.org/doc/debian-policy/ ) for how to customizing startup keymaps the debian way.

恩,谢谢啦!我目前的解决办法是把emacs.map.gz复制一份,然后编辑一下,然后在/etc/init.d/keymaps.sh 后面加了一行加载那个keymap,不过我觉得这样应该不是正规的做法,我先看看你说的那种方法吧。
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

快速回复 返回顶部 返回列表