From: Tassilo Horn <tassilo@member.fsf.org>
To: help-gnu-emacs@gnu.org
Subject: Re: Problem with keybindings
Date: Fri, 14 Nov 2008 13:17:39 +0100 [thread overview]
Message-ID: <871vxeh57g.fsf@thinkpad.tsdh.de> (raw)
In-Reply-To: a2b3004b0811140357s31a77847kb3bdaa2f395dcda1@mail.gmail.com
"Lorenzo Isella" <lorenzo.isella@gmail.com> writes:
Hi Lorenzo,
> (defun my-latex-bindings ()
> (define-key LaTeX-mode-map [_] 'latex-subscript)
> (define-key LaTeX-mode-map [^] 'latex-superscript)
I think the key syntax is wrong. It's best to always use the `kbd'
function. There you can enter the keys as they're printed by `C-h k'.
(define-key LaTeX-mode-map (kbd "_") 'latex-subscript)
(define-key LaTeX-mode-map (kbd "^") 'latex-superscript)
> (define-key LaTeX-mode-map [(control down)] 'latex-next-section)
> (define-key LaTeX-mode-map [(control up)] 'latex-previous-section)
Although that's the right syntax, I assume that
(define-key LaTeX-mode-map (kbd "<C-down>") 'latex-next-section)
(define-key LaTeX-mode-map (kbd "<C-up>") 'latex-previous-section)
is a bit easier to read and write.
Bye,
Tassilo
--
[Emacs] is written in Lisp, which is the only computer language that is
beautiful. -- Neal Stephenson, _In the Beginning was the Command Line_
prev parent reply other threads:[~2008-11-14 12:17 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-11-14 11:57 Problem with keybindings Lorenzo Isella
2008-11-14 12:17 ` Tassilo Horn [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=871vxeh57g.fsf@thinkpad.tsdh.de \
--to=tassilo@member.fsf.org \
--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).