除了eclipse还有没有其他的可以自定义光标快捷键的编辑器啊?
- oldfeel
- 帖子: 134
- 注册时间: 2011-08-09 20:46
除了eclipse还有没有其他的可以自定义光标快捷键的编辑器啊?
最近学习html5经常要敲各种标签引号,用gedit编辑没有光标快捷键(上下左右/行首/行尾)感觉甚是难受。用eclipse写html又很卡,所以想换一种编辑器了。请大神们指引有没有什么编辑器可以自定义光标快捷键,像这个一样http://www.oldfeel.cn/?p=479
- lilydjwg
- 论坛版主
- 帖子: 4258
- 注册时间: 2009-04-11 23:46
- 系统: Arch Linux
- 联系:
Re: 除了eclipse还有没有其他的可以自定义光标快捷键的编辑器啊?
vim, emacs.
- lilydjwg
- 论坛版主
- 帖子: 4258
- 注册时间: 2009-04-11 23:46
- 系统: Arch Linux
- 联系:
Re: 除了eclipse还有没有其他的可以自定义光标快捷键的编辑器啊?
PS: 这么简单的键绑定 GTK 2 也能做到。
PPS: 新版的 GTK 3 目前还做不到。
PPS: 新版的 GTK 3 目前还做不到。
- oldfeel
- 帖子: 134
- 注册时间: 2011-08-09 20:46
Re: 除了eclipse还有没有其他的可以自定义光标快捷键的编辑器啊?
哥~vim不能在编辑状态下定义光标快捷键,emacs的插件安装太复杂,小菜连个格式化代码都装不好,有木有其他的了?lilydjwg 写了:vim, emacs.
- oldfeel
- 帖子: 134
- 注册时间: 2011-08-09 20:46
Re: 除了eclipse还有没有其他的可以自定义光标快捷键的编辑器啊?
具体怎么操作啊??lilydjwg 写了:PS: 这么简单的键绑定 GTK 2 也能做到。
PPS: 新版的 GTK 3 目前还做不到。
- qute
- 帖子: 24
- 注册时间: 2011-05-24 17:05
- 系统: ubuntu
Re: 除了eclipse还有没有其他的可以自定义光标快捷键的编辑器啊?
Emacs无误
代码: 全选
_____________
< Hello World >
-------------
\ ^__^
\ (oo)\_______
(__)\ )\/\
||----w |
|| ||
- lilydjwg
- 论坛版主
- 帖子: 4258
- 注册时间: 2009-04-11 23:46
- 系统: Arch Linux
- 联系:
Re: 除了eclipse还有没有其他的可以自定义光标快捷键的编辑器啊?
谁说不能?oldfeel 写了:哥~vim不能在编辑状态下定义光标快捷键,emacs的插件安装太复杂,小菜连个格式化代码都装不好,有木有其他的了?lilydjwg 写了:vim, emacs.
代码: 全选
noremap! <C-B> <Left>
noremap! <C-F> <Right>
noremap! <C-A> <Home>
inoremap <C-E> <End>
inoremap <C-P> <Up>
inoremap <C-N> <Down>
noremap! <M-b> <S-Left>
noremap! <M-f> <S-Right>
- oldfeel
- 帖子: 134
- 注册时间: 2011-08-09 20:46
Re: 除了eclipse还有没有其他的可以自定义光标快捷键的编辑器啊?
lilydjwg 写了:谁说不能?oldfeel 写了:哥~vim不能在编辑状态下定义光标快捷键,emacs的插件安装太复杂,小菜连个格式化代码都装不好,有木有其他的了?lilydjwg 写了:vim, emacs.代码: 全选
noremap! <C-B> <Left> noremap! <C-F> <Right> noremap! <C-A> <Home> inoremap <C-E> <End> inoremap <C-P> <Up> inoremap <C-N> <Down> noremap! <M-b> <S-Left> noremap! <M-f> <S-Right>

- lilydjwg
- 论坛版主
- 帖子: 4258
- 注册时间: 2009-04-11 23:46
- 系统: Arch Linux
- 联系:
Re: 除了eclipse还有没有其他的可以自定义光标快捷键的编辑器啊?
oldfeel 写了:具体怎么操作啊??lilydjwg 写了:PS: 这么简单的键绑定 GTK 2 也能做到。
PPS: 新版的 GTK 3 目前还做不到。
代码: 全选
#
# Bindings for GtkTextView and GtkEntry
#
binding "gtk-emacs-text-entry" {
bind "<ctrl>b" { "move-cursor" (logical-positions, -1, 0) }
bind "<shift><ctrl>b" { "move-cursor" (logical-positions, -1, 1) }
bind "<ctrl>f" { "move-cursor" (logical-positions, 1, 0) }
bind "<shift><ctrl>f" { "move-cursor" (logical-positions, 1, 1) }
bind "<alt>b" { "move-cursor" (words, -1, 0) }
bind "<shift><alt>b" { "move-cursor" (words, -1, 1) }
bind "<alt>f" { "move-cursor" (words, 1, 0) }
bind "<shift><alt>f" { "move-cursor" (words, 1, 1) }
bind "<ctrl>a" { "move-cursor" (paragraph-ends, -1, 0) }
bind "<shift><ctrl>a" { "move-cursor" (paragraph-ends, -1, 1) }
bind "<ctrl>e" { "move-cursor" (paragraph-ends, 1, 0) }
bind "<shift><ctrl>e" { "move-cursor" (paragraph-ends, 1, 1) }
bind "<ctrl>y" { "paste-clipboard" () }
bind "<ctrl>d" { "delete-from-cursor" (chars, 1) }
bind "<alt>h" { "delete-from-cursor" (chars, 1) }
bind "<alt>d" { "delete-from-cursor" (word-ends, 1) }
bind "<ctrl>k" { "delete-from-cursor" (paragraph-ends, 1) }
bind "<ctrl>u" {
"delete-from-cursor" (paragraph-ends, -1)
}
bind "<ctrl>h" { "delete-from-cursor" (chars, -1) }
bind "<ctrl>w" { "delete-from-cursor" (word-ends, -1) }
}
#
# Bindings for GtkTextView
#
binding "gtk-emacs-text-view"
{
bind "<ctrl>p" { "move-cursor" (display-lines, -1, 0) }
bind "<shift><ctrl>p" { "move-cursor" (display-lines, -1, 1) }
bind "<ctrl>n" { "move-cursor" (display-lines, 1, 0) }
bind "<shift><ctrl>n" { "move-cursor" (display-lines, 1, 1) }
}
#
# Bindings for GtkTreeView
#
binding "gtk-emacs-tree-view"
{
bind "<ctrl>n" { "move-cursor" (logical-positions, 1) }
bind "<ctrl>p" { "move-cursor" (logical-positions, -1) }
}
#
# Bindings for menus
#
binding "gtk-emacs-menu"
{
bind "<ctrl>n" { "move-current" (next) }
bind "<ctrl>p" { "move-current" (prev) }
bind "<ctrl>f" { "move-current" (child) }
bind "<ctrl>b" { "move-current" (parent) }
}
class "GtkEntry" binding "gtk-emacs-text-entry"
class "GtkTextView" binding "gtk-emacs-text-entry"
class "GtkTextView" binding "gtk-emacs-text-view"
class "GtkTreeView" binding "gtk-emacs-tree-view"
class "GtkMenuShell" binding "gtk-emacs-menu"
- lilydjwg
- 论坛版主
- 帖子: 4258
- 注册时间: 2009-04-11 23:46
- 系统: Arch Linux
- 联系:
Re: 除了eclipse还有没有其他的可以自定义光标快捷键的编辑器啊?
觉得好用的话不妨试试整个配置:oldfeel 写了:lilydjwg 写了:代码: 全选
noremap! <C-B> <Left> noremap! <C-F> <Right> noremap! <C-A> <Home> inoremap <C-E> <End> inoremap <C-P> <Up> inoremap <C-N> <Down> noremap! <M-b> <S-Left> noremap! <M-f> <S-Right>
谢谢!!!小看vim了,以后就用这个了。。。
https://github.com/lilydjwg/dotvim/blob ... n/bash.vim
终端下配合这个不然 Alt 组合键有问题:
https://github.com/lilydjwg/dotvim/blob ... escalt.vim
- oldfeel
- 帖子: 134
- 注册时间: 2011-08-09 20:46
Re: 除了eclipse还有没有其他的可以自定义光标快捷键的编辑器啊?
恩,我试试。今晚又要熬夜了lilydjwg 写了:觉得好用的话不妨试试整个配置:oldfeel 写了:lilydjwg 写了:代码: 全选
noremap! <C-B> <Left> noremap! <C-F> <Right> noremap! <C-A> <Home> inoremap <C-E> <End> inoremap <C-P> <Up> inoremap <C-N> <Down> noremap! <M-b> <S-Left> noremap! <M-f> <S-Right>
谢谢!!!小看vim了,以后就用这个了。。。
https://github.com/lilydjwg/dotvim/blob ... n/bash.vim
终端下配合这个不然 Alt 组合键有问题:
https://github.com/lilydjwg/dotvim/blob ... escalt.vim
