[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: position on changing defaults?
From: |
Stefan Monnier |
Subject: |
Re: position on changing defaults? |
Date: |
Thu, 06 Mar 2008 11:46:58 -0500 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (gnu/linux) |
> How about adding a new type of binding, a "modifier binding", which
> could serve to implement CUA movement, and replace the current automatic
> S-foo => foo remapping.
I'm not sure I understand what you're proposing.
One thing we can do right now is:
(define-key function-key-map [S-up]
(lambda (prompt) (setq foo-shited t) [up]))
and one thing I'd like to do is to replace the C-level mapping of S-foo
to foo by some entry in function-key-map. This requires extending the
function-key-map mechanism, tho. I don't know what it would look like,
but just to make it more concrete, here's one possible way:
(define-key function-key-map [S-*]
(lambda (prompt key) (vector (remove-shift key))))
Obviously, this can't work as is. Maybe an even better generalization
would be
(define-key function-key-map [is-shifted-p]
(lambda (prompt key) (vector (remove-shift key))))
(define-key function-key-map [is-mouse-4-p]
(lambda (prompt key)
(vector (combine-modifiers (modifiers key) 'mwheel-up)))
where `is-shifted-p' and `is-mouse-4-p' are Lisp functions.
Stefan
- Re: Shift-movement selection, (continued)
- Re: Shift-movement selection, Richard Stallman, 2008/03/11
- Re: Shift-movement selection, Richard Stallman, 2008/03/10
- Re: Shift-movement selection, Stefan Monnier, 2008/03/10
- Re: Shift-movement selection, Richard Stallman, 2008/03/11
- Re: Shift-movement selection, Lennart Borgman (gmail), 2008/03/11
- Re: Shift-movement selection, Richard Stallman, 2008/03/12
- Re: Shift-movement selection, Alan Mackenzie, 2008/03/11
- Re: position on changing defaults?,
Stefan Monnier <=
- Re: position on changing defaults?, Miles Bader, 2008/03/06
- Re: position on changing defaults?, Richard Stallman, 2008/03/08
- Re: position on changing defaults?, Richard Stallman, 2008/03/08
- Re: position on changing defaults?, Kim F. Storm, 2008/03/08
- Re: position on changing defaults?, Kim F. Storm, 2008/03/08
- Re: position on changing defaults?, Stefan Monnier, 2008/03/08
- Re: position on changing defaults?, Richard Stallman, 2008/03/09
- Re: position on changing defaults?, Stefan Monnier, 2008/03/09
- Re: position on changing defaults?, Kim F. Storm, 2008/03/09
- Re: position on changing defaults?, Lennart Borgman (gmail), 2008/03/09