From: Stefan Horomnea <stefan@softexperience.ro>
To: help-gnu-emacs@gnu.org
Subject: Re: bind the Ctrl-m key but not bind return
Date: Thu, 20 Sep 2007 11:47:38 +0300 [thread overview]
Message-ID: <46F233AA.8000104@softexperience.ro> (raw)
In-Reply-To: <46F0E229.1070601@softexperience.ro>
Ok, I got it.
You put something like this in the map file you load with loadkeys:
control keycode 50 = F2
that means ctrl + m will send the F2 key.
and in your .emacs file you put:
(define-key globalmap [(f2)] 'my-command)
So, I use an additional function key (F2) for linking the ctlr+m stuff
to it.
Maybe it could be done more ellegant, that's the solution I've found.
But pay attention: in X (fedora and red had) probably won't work,
because X settings override the keymap file somehow.
But in X you can use xmodmap.
Stefan Horomnea wrote:
> Hello,
>
> I really needed to bind Ctrl-M key to some command, but if I bind it,
> i've seen that return is also bind to that command.
> So, I did some research and ctrl-m IS return.
>
> I solved this problem in KDE like this:
> - that command is bound to Ctrl-`
> - I used kcontrolcenter to translate my input of ctlr-m in ctrl-`
>
> And I used this solution for 2 years or so. But now I want to use
> emacs over ssh, meaning i won't have X or KDE. And I am very used and
> pleased with my Ctrl-m shortcut.
>
> Is there any solution ? Maybe using loadkeys command and .keymap file
> in linux ? But how ?
>
> Thank you,
> Stefan
>
>
> _______________________________________________
> help-gnu-emacs mailing list
> help-gnu-emacs@gnu.org
> http://lists.gnu.org/mailman/listinfo/help-gnu-emacs
>
prev parent reply other threads:[~2007-09-20 8:47 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-09-19 8:47 bind the Ctrl-m key but not bind return Stefan Horomnea
2007-09-20 8:47 ` Stefan Horomnea [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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=46F233AA.8000104@softexperience.ro \
--to=stefan@softexperience.ro \
--cc=help-gnu-emacs@gnu.org \
/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.