From: Jesper Harder <harder@myrealbox.com>
Subject: Re: Any hope of being able to redefine C-x without problems???
Date: Sun, 21 Sep 2003 21:38:07 +0200 [thread overview]
Message-ID: <m3pthuj5k0.fsf@defun.localdomain> (raw)
In-Reply-To: m3ad8yku23.fsf@defun.localdomain
Jesper Harder <harder@myrealbox.com> writes:
> seberino@spawar.navy.mil (Christian Seberino) writes:
>
>> There is no way to write some lisp code that makes me able to
>> define C-x and alter gdb to not have a problem? I thought you
>> could do anything in elisp?
>
> It's possible. But `C-x' is used as prefix by hundreds of basic
> Emacs functions -- not just gdb. You'll have redefine the bindings
> for all of them.
>
> A lot of tedious work for something which can easily be avoided by
> using another key-binding which is guaranteed not to conflict with any
> pre-defined Emacs bindings.
OK, it's not so tedious after all. If you want to bind a function,
say, `my-function' to `C-x' you can do this:
(keyboard-translate ?\C-x 'foo)
(global-set-key [foo] 'my-function)
If you need to call a function that's normally bound to a C-x sequence
you can redefine another key, e.g. F5, to act as C-x:
(define-key key-translation-map [f5] "\C-x")
Then you can type `F5 C-f' to call `find-file' which is bound to
`C-x C-f'.
prev parent reply other threads:[~2003-09-21 19:38 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-09-18 22:17 Any hope of being able to redefine C-x without problems??? Christian Seberino
2003-09-18 22:44 ` Jesper Harder
2003-09-21 6:47 ` Christian Seberino
2003-09-21 16:03 ` Jesper Harder
2003-09-21 19:38 ` Jesper Harder [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=m3pthuj5k0.fsf@defun.localdomain \
--to=harder@myrealbox.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).