Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

adding C-c C-f C-p shortcut for \textipa

9 views
Skip to first unread message

Roger Levy

unread,
Jan 21, 2008, 6:18:13 PM1/21/08
to
I am a linguist who uses AucTeX and I would like to add a key binding
for C-c C-f C-p that behaves exactly like other C-c C-f * commands
(e.g., C-c C-f C-e for \emph), but introduces the textfont \textipa
(for the International Phonetic Alphabet). How would I do this? It
looks to me like I need to customize TeX-font-list but I'm not sure
the best way to do it (I'd prefer to doing this in my .emacs file
directly to using Emacs customization menus).

Many thanks,

Roger Levy

Stephen Berman

unread,
Jan 22, 2008, 12:54:00 PM1/22/08
to help-gn...@gnu.org

Does this work?

(add-to-list 'TeX-font-list '(?\C-p "\\textipa{" "}"))

Steve Berman

Roger Levy

unread,
Jan 22, 2008, 2:49:52 PM1/22/08
to
On Jan 22, 9:54 am, Stephen Berman <Stephen.Ber...@gmx.net> wrote:

> On Mon, 21 Jan 2008 15:18:13 -0800 (PST) Roger Levy <sinos...@gmail.com> wrote:
>
> > I am a linguist who uses AucTeX and I would like to add a key binding
> > for C-c C-f C-p that behaves exactly like other C-c C-f * commands
> > (e.g., C-c C-f C-e for \emph), but introduces the textfont \textipa
> > (for the International Phonetic Alphabet). How would I do this? It
> > looks to me like I need to customize TeX-font-list but I'm not sure
> > the best way to do it (I'd prefer to doing this in my .emacs file
> > directly to using Emacs customization menus).
>
> Does this work?
>
> (add-to-list 'TeX-font-list '(?\C-p "\\textipa{" "}"))

Nope...but thanks for the suggestion! (Also, putting that straight
into .emacs causes emacs to balk on startup, presumably because it
doesn't know anything about 'TeX-font-list.)

Actually, please don't respond further to this message as I think the
AUCTeX mailing list is a more appropriate forum.

Roger

Roger Levy

unread,
Jan 30, 2008, 10:08:55 AM1/30/08
to

Just FYI: there are two solutions that were generously provided to me
by Ralf Angeli on the AUCTeX mailing list:

1) Do M-x customize-variable <RET> LaTeX-font-list <RET> and add the
\textipa{} key binding through the Emacs customization menu. (You'll
need to do C-q C-p to enter the ^P character -- this should be more
transparent after you get to the menu.)

2) Add the following line to your init file:

(eval-after-load "latex"
'(add-to-list 'LaTeX-font-list '(?\C-p "\\textipa{" "}")))

which should do the trick as well.

I believe that in both cases you'll need AUCTeX installed.
Roger

0 new messages