From: Nikolaj Schumacher <me@nschum.de>
To: Xah <xahlee@gmail.com>
Cc: help-gnu-emacs@gnu.org
Subject: Re: how to get Meta+y to be Meta+Tab
Date: Sun, 26 Oct 2008 15:11:33 +0100 [thread overview]
Message-ID: <m2abcr78fe.fsf@nschum.de> (raw)
In-Reply-To: <f4ef5da9-54e6-4742-8ebe-f630f74b284a@r15g2000prh.googlegroups.com> (Xah's message of "Sat\, 25 Oct 2008 14\:40\:58 -0700 \(PDT\)")
Xah <xahlee@gmail.com> wrote:
> Xah wrote:
> «suppose i want to make Meta+y to function as pressing Meta+Tab.
> intuitively, i do this: (keyboard-translate ?\M-y ?\M-9) but that does
> not work.»
>
> B T Raven wrote:
> «Maybe (global-unset-key KEY)and then (global-set-key)? Some minor
> modes might override the new setting but probably most won't.»
It would be nice if you could use a more common quoting mechanism (like
a ">" prefix), so syntax highlighting picks up the quotation. It makes
reading much easier.
> am pretty sure that global-set-key cannot be used for the
> functionality of keyboard-translate.
In a way it can. You can bind it to a macro:
(global-set-key "\M-y" "\M-\t")
Using `keyboard-translate' is generally a little risky, because it will
change the key in all places. So people wouldn't be able to do use C-c M-y
anymore. So I would only use it to fix keyboard issues.
You can also write a function like this:
(defun do-what-backspace-does ()
(interactive)
(call-interactively (key-binding "\C-?")))
I've found that one to be the most reliable solution.
regards,
Nikolaj Schumacher
next prev parent reply other threads:[~2008-10-26 14:11 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-10-24 21:47 how to get Meta+y to be Meta+Tab Xah
2008-10-24 23:08 ` B. T. Raven
2008-10-25 21:40 ` Xah
2008-10-26 14:11 ` Nikolaj Schumacher [this message]
[not found] ` <mailman.2123.1225030309.25473.help-gnu-emacs@gnu.org>
2008-10-28 6:13 ` Xah
2008-10-25 23:01 ` Andreas Politz
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=m2abcr78fe.fsf@nschum.de \
--to=me@nschum.de \
--cc=help-gnu-emacs@gnu.org \
--cc=xahlee@gmail.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.
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.