bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#8135: Problem about TAB in emacs23


From: Glenn Morris
Subject: bug#8135: Problem about TAB in emacs23
Date: Mon, 28 Feb 2011 14:51:19 -0500
User-agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/)

dexter K wrote:

> I want have a real tab , when I press TAB, it goes like 8 spaces distances..
> I did it with this code:
> -------
>
> (global-set-key (kbd "TAB") 'self-insert-command)
> (setq default-tab-width 8)
> (setq tab-width 8)
> (setq c-basic-indent 8)
>
> (global-set-key [delete] 'delete-char)
> (global-set-key [backspace] 'delete-backward-char)
>
> -------
>
> it works both on windows & mac , the most important is I can delete a whole
> tab distances like 8 spaces when I press [BackSpace] key
> But it failed again in my Centos ,when I done complie emacs 23.2



This does not look like an Emacs bug, and probably would have been
better suited to the help-gnu-emacs mailing list.

Comments:
1) The default tab-width is 8.
2) There is no `c-basic-indent' variable. Maybe you meant c-basic-offset?
3) delete runs `delete-char' by default.
4) C-h k BACKSPACE tells me that I can customize the behaviour
by setting `backward-delete-char-untabify-method'.

So in Emacs 23.2 I get the behaviour that you want simply with:

(global-set-key (kbd "TAB") 'self-insert-command)
(setq backward-delete-char-untabify-method nil)





reply via email to

[Prev in Thread] Current Thread [Next in Thread]