>>>> "Hrvoje" == Hrvoje Niksic
<hniksic(a)arsdigita.com> writes:
Hrvoje> "Stephen J. Turnbull" <turnbull(a)sk.tsukuba.ac.jp> writes:
mb> It should be possible to define a key as a character, e.g.
mb> (define-key [(Cyrillic_hardsign)] ?ÿ)
> I like this interface.
Hrvoje> I'm not so sure about it. What if ÿ itself is bound to
Hrvoje> something other than self-insert-command? Do we still
Hrvoje> insert ÿ, or do we call that other command?
I would say define as self-insert. To get the definition of ÿ, we
already have the form
(define-key global-map [(Cyrillic_hardsign)] (cons global-map ?ÿ)).
which makes it clear what we're doing in that case.
Your interpretation is plausible, so someone who hasn't RTFM'd might
get a little confused. It's also maybe a little confusing since many
insert commands take strings or characters and "do the right thing",
whereas here strings and characters would have very different
interpretations (keyboard macro and self-insert, respectively).
But I still like it. :-)
>>> "mb" == Martin Buchholz
<martin(a)xemacs.org> writes:
mb> Historical note: keystrokes and characters have been confused,
mb> since they are somewhat indistinguishable on a tty.
mb> The default (fallback) binding of a character should be
mb> self-insert-key (except without the need to hack the
mb> ascii-character property).
?? Does this have specifically to do with the define-key thread, or
are we now talking about the master plan to revamp the keyboard code?
In the context of define-key, I see no reason for such complexity. We
just decide what we want an object of character type to mean when
presented to define-key as the DEF arg. No need for fallbacks,
defaults, user configuration or anything. Right? You can have them
if you want, but IMHO they'd be really confusing.
It would be very straightforward to implement your original two-line
proposal as a defadvice of define-key, right?
--
University of Tsukuba Tennodai 1-1-1 Tsukuba 305-8573 JAPAN
Institute of Policy and Planning Sciences Tel/fax: +81 (298) 53-5091
_________________ _________________ _________________ _________________
What are those straight lines for? "XEmacs rules."