[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Portable key sequences [was: key sequences aren't specified...]

From: Stephen J. Turnbull
Subject: Portable key sequences [was: key sequences aren't specified...]
Date: Sun, 20 Nov 2005 00:48:31 +0900
User-agent: Gnus/5.1007 (Gnus v5.10.7) XEmacs/21.5-b23 (daikon, linux)

Alan Mackenzie wrote:

    >> In fact, I figured out "[?\C-c \C-backspace]" by just such
    >> experimentation. Trouble is, this is rejected by XEmacs, and I
    >> want the specification to be portable.

As far as I know there is no portable way to express all key sequences
in all Emacsen, even of v21 or later vintage.  Even if XEmacs were
disposed to give up the regularity and readability of the vector of
lists of symbols representation, the fact remains that for at least 8
years that representation has been the one guaranteed to work for
arbitrary sequences of gestures, and only a minimum of effort has been
put into string representations.  Which string representations we
support has varied over the last few years, I believe.

>>>>> "Ted" == Edward O'Connor <address@hidden> writes:

    Ted> I should think (kbd "C-c C-DEL") would DTRT under both
    Ted> Emacsen.

Do you really mean "DEL"?  That's definitely wrong in XEmacs; `(kbd
"C-c C-<backspace>")' is the canonical way to express it (ie, that's
what would be generated by insert-kbd-macro).

Using `kbd' probably is fairly portable, but there's no guarantee that
symbols that are used in recording keyboard macros will be the same.
For example it happens to be the case that both `(kbd "C-BS")' and
`(kbd "C-backspace")' produce `[(control backspace)]' in XEmacs, but
it could easily be true that Emacs only handles "C-BS" while XEmacs
only recognizes "C-backspace".  And "C-<backspace>" is the only thing
guaranteed to work in XEmacs.

School of Systems and Information Engineering http://turnbull.sk.tsukuba.ac.jp
University of Tsukuba                    Tennodai 1-1-1 Tsukuba 305-8573 JAPAN
               Ask not how you can "do" free software business;
              ask what your business can "do for" free software.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]