[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: TAB key to insert tab character
From: |
Eli Zaretskii |
Subject: |
Re: TAB key to insert tab character |
Date: |
Sun, 10 Feb 2008 06:14:27 +0200 |
> From: Blake McBride <blake@mcbride.name>
> Date: Sat, 09 Feb 2008 14:56:02 -0600
>
> > You could do what I do - bind Ctrl-Tab to insert an ASCII <tab>:
> >
> > (global-set-key [C-tab] (lambda () (interactive) (insert-char 9 1)))
> >
> > - Will
>
> I don't want to globally set anything. I like the way the TAB key works
> in C and Lisp modes. I just want to change its behavior in TEXT and
> FUNDAMENTAL modes.
Did you actually try that? I think mode-specific key bindings always
override global bindings, so the above will not affect C mode. for
example.
But if you want to bind TAB in Text mode, then try the below:
(define-key text-mode-map "\C-i" 'self-insert-command)
You will need to do this in a text-mode-hook.
- TAB key to insert tab character, Blake McBride, 2008/02/08
- Re: TAB key to insert tab character, Peter Dyballa, 2008/02/09
- Message not available
- Re: TAB key to insert tab character, Blake McBride, 2008/02/09
- Re: TAB key to insert tab character, Will Parsons, 2008/02/09
- Re: TAB key to insert tab character, Eli Zaretskii, 2008/02/09
- Re: TAB key to insert tab character, Blake McBride, 2008/02/09
- Re: TAB key to insert tab character,
Eli Zaretskii <=
- Message not available
- Re: TAB key to insert tab character, Blake McBride, 2008/02/12
- Re: TAB key to insert tab character, Eli Zaretskii, 2008/02/12
- Message not available
- Re: TAB key to insert tab character, Will Parsons, 2008/02/09