From: the matt <matt@kettlewell.net>
To: help-gnu-emacs@gnu.org
Subject: Re: Setting Keyboard bindings for C-Right
Date: Sun, 05 Aug 2007 14:53:34 -0700 [thread overview]
Message-ID: <1186350814.126331.299400@i13g2000prf.googlegroups.com> (raw)
In-Reply-To: <mailman.4421.1186344683.32220.help-gnu-emacs@gnu.org>
On Aug 5, 2:11 pm, Peter Dyballa <Peter_Dyba...@Web.DE> wrote:
> Am 04.08.2007 um 20:30 schrieb the matt:
>
> > Any help in translating "ESC [ 1 ; 5 C" into an emacs keybinding would
> > be much appreciated.
>
> You could look into xterm.el - it has lines like:
>
> (define-key map "\e[1;5C" [C-right])
>
> The whole block, starting with
>
> (let ((map (make-sparse-keymap)))
>
> has a comment
>
> ;; xterm from X.org 6.8.2 uses these key definitions.
>
> and ends with
>
> ;; Use inheritance to let the main keymap override those
> defaults.
> ;; This way we don't override terminfo-derived settings or
> settings
> ;; made in the .emacs file.
> (set-keymap-parent map (keymap-parent function-key-map))
> (set-keymap-parent function-key-map map))
>
> Could be it's worth to patch <your terminal>.el with the 300 lines
> from xterm.el.
>
> --
> Greetings
>
> Pete
>
> There is no national science just as there is no national
> multiplication table; what is national is no longer science.
> -- Anton Checov
Thanks Pete,
That's the pointer that I was needing
In the end I added the following to my .emacs file
(right, wrong or indiferent, it's what I did, and where I put it):
(define-key function-key-map "\e[1;5C" [C-
right])
(define-key function-key-map "\e[1;5D" [C-
left])
(global-set-key [(C-right)] 'forward-
word)
(global-set-key [(C-left)] 'backward-word)
Thanks again,
Matt
prev parent reply other threads:[~2007-08-05 21:53 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-08-04 18:30 Setting Keyboard bindings for C-Right the matt
2007-08-05 3:26 ` weber
2007-08-05 3:39 ` the matt
2007-08-05 20:11 ` Peter Dyballa
[not found] ` <mailman.4421.1186344683.32220.help-gnu-emacs@gnu.org>
2007-08-05 21:53 ` the matt [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=1186350814.126331.299400@i13g2000prf.googlegroups.com \
--to=matt@kettlewell.net \
--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.
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).