* bug#2820: 23.0.91; ruby-mode binds keys it probably shouldn't
@ 2009-03-30 8:21 Miles Bader
2012-09-04 5:02 ` Dmitry Gutov
0 siblings, 1 reply; 4+ messages in thread
From: Miles Bader @ 2009-03-30 8:21 UTC (permalink / raw)
To: emacs-pretest-bug
ruby-mode-map contains a bunch of rebindings of standard key sequences,
many of which would better be done using other mechanisms.
E.g.:
(define-key map (kbd "M-C-a") 'ruby-beginning-of-defun)
should use `beginning-of-defun-function' instead.
(define-key map (kbd "TAB") 'ruby-indent-line)
should use `indent-line-function' instead.
etc, etc.
-Miles
In GNU Emacs 23.0.91.2 (x86_64-unknown-linux-gnu, GTK+ Version 2.16.0)
of 2009-03-30 on dhlpc061
Windowing system distributor `The X.Org Foundation', version 11.0.10599902
Important settings:
value of $LC_ALL: nil
value of $LC_COLLATE: nil
value of $LC_CTYPE: nil
value of $LC_MESSAGES: nil
value of $LC_MONETARY: nil
value of $LC_NUMERIC: nil
value of $LC_TIME: nil
value of $LANG: ja_JP.UTF-8
value of $XMODIFIERS: @im=SCIM
locale-coding-system: utf-8-unix
default-enable-multibyte-characters: t
Major mode: Emacs-Lisp
Minor modes in effect:
shell-dirtrack-mode: t
show-paren-mode: t
recentf-mode: t
rcirc-track-minor-mode: t
minibuffer-electric-default-mode: t
display-time-mode: t
desktop-save-mode: t
tooltip-mode: t
mouse-wheel-mode: t
file-name-shadow-mode: t
global-font-lock-mode: t
font-lock-mode: t
global-auto-composition-mode: t
auto-composition-mode: t
auto-encryption-mode: t
auto-compression-mode: t
temp-buffer-resize-mode: t
line-number-mode: t
transient-mark-mode: t
Recent input:
! <backspace> <backspace> r e b i n d i n g SPC i s
SPC g e n e r a l l y SPC a SPC b a d SPC i d e a SPC
u n l e s s SPC y o u SPC h a v <escape> h <escape>
h <escape> h i f SPC t h e r e ' s SPC a SPC b e t
t e r SPC i d e a <return> <tab> <tab> i t ' s SPC
c r u f t y <return> <return> <tab> <tab> t y p i c
a l SPC o f SPC m o d e s SPC <escape> h SPC M-h M-h
g r a n C-a C-k <tab> b e c a u s e SPC o n SPC X ,
SPC t a b SPC g e n d s SPC t o <escape> h <escape>
h t e n d s SPC t o SPC g e t SPC t r r a <backspace>
<backspace> a n s l a t e d C-a M-f M-f M-b i SPC g
u e s s SPC C-e SPC t h o <backspace> r o u g SPC N
SPC l a y e r s SPC o f SPC r e m p a p i g n s <escape>
h r e p <backspace> a <backspace> m a p p i n s <return>
w h e r e a s C-a C-k C-x b <return> C-f C-f C-f C-f
C-f C-f C-f C-f C-M-b C-s C-w C-w C-w C-s C-s C-s C-s
C-a C-x C-g C-x s C-x k <return> <escape> x r e <backspace>
<backspace> r e p o r t - e m SPC <return>
Recent messages:
Auto-saving...
x*DING*
Quit
(New file)
TAB (translated from <tab>) runs the command ruby-indent-line
Type C-x 1 to delete the help window, C-M-v to scroll help.
mouse-2, RET: find function's definition
x*DING*
Mark saved where search started
x*DING*
--
Non-combatant, n. A dead Quaker.
^ permalink raw reply [flat|nested] 4+ messages in thread
* bug#2820: 23.0.91; ruby-mode binds keys it probably shouldn't
2009-03-30 8:21 bug#2820: 23.0.91; ruby-mode binds keys it probably shouldn't Miles Bader
@ 2012-09-04 5:02 ` Dmitry Gutov
2012-09-04 14:39 ` Stefan Monnier
0 siblings, 1 reply; 4+ messages in thread
From: Dmitry Gutov @ 2012-09-04 5:02 UTC (permalink / raw)
To: 2820
Revision 109870 has cleaned up most of the keybindings, including
ruby-beginning-of-defun.
I left out these:
1) ruby-forward/backward-sexp - because these functions are sufficiently
different from the default (forward-sexp).
Just setting forward-sexp-function value would break `up-list' and
`backward-up-list', for example.
2) ruby-indent-exp - because it's more useful than `prog-indent-sexp',
and the latter uses `forward-sexp'.
Can we consider this bug fixed?
--Dmitry
^ permalink raw reply [flat|nested] 4+ messages in thread
* bug#2820: 23.0.91; ruby-mode binds keys it probably shouldn't
2012-09-04 5:02 ` Dmitry Gutov
@ 2012-09-04 14:39 ` Stefan Monnier
2012-09-04 19:10 ` Dmitry Gutov
0 siblings, 1 reply; 4+ messages in thread
From: Stefan Monnier @ 2012-09-04 14:39 UTC (permalink / raw)
To: Dmitry Gutov; +Cc: 2820
> Just setting forward-sexp-function value would break `up-list' and
> backward-up-list', for example.
That's a problem, yes. We need a better story to extend
forward-sexp-function to up-list (probably with something like
the addition of an up-list-function).
> 2) ruby-indent-exp - because it's more useful than `prog-indent-sexp', and
> the latter uses `forward-sexp'.
That's fine: it's a different command, but its intention is the same.
So I guess it should use command remapping.
Stefan
^ permalink raw reply [flat|nested] 4+ messages in thread
* bug#2820: 23.0.91; ruby-mode binds keys it probably shouldn't
2012-09-04 14:39 ` Stefan Monnier
@ 2012-09-04 19:10 ` Dmitry Gutov
0 siblings, 0 replies; 4+ messages in thread
From: Dmitry Gutov @ 2012-09-04 19:10 UTC (permalink / raw)
To: Stefan Monnier; +Cc: 2820
On 04.09.2012 18:39, Stefan Monnier wrote:
>> Just setting forward-sexp-function value would break `up-list' and
>> backward-up-list', for example.
>
> That's a problem, yes. We need a better story to extend
> forward-sexp-function to up-list (probably with something like
> the addition of an up-list-function).
That would be one way to solve it, I guess. In js2-mode-forward-sexp, I
just decided to emulate the default behavior - signal scan-error with
the right message and arguments when appropriate - because `up-list'
expects the error with the right arguments, and autopair actually checks
the error message for the word "prematurely".
There may be other third-party packages that rely on its behavior.
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2012-09-04 19:10 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-03-30 8:21 bug#2820: 23.0.91; ruby-mode binds keys it probably shouldn't Miles Bader
2012-09-04 5:02 ` Dmitry Gutov
2012-09-04 14:39 ` Stefan Monnier
2012-09-04 19:10 ` Dmitry Gutov
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.