[Top][All Lists]

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

Re: Spaces rather than tabs by a major mode hook

From: Eli Zaretskii
Subject: Re: Spaces rather than tabs by a major mode hook
Date: Sat, 11 Jun 2022 13:33:59 +0300

> Date: Sat, 11 Jun 2022 10:20:39 +0000
> From: goncholden <>
> Cc:
> > > For instance, how can I get the tab key to just make a tab and
> > > pressing it again to make another tab. As I can do with spaces.
> >
> >
> > You shouldn't need this, not at all. If you set the indentation
> > levels and variables for the style of these files, typing TAB will
> > insert as many TAB characters as needed to get to the correct column.
> > For example, if the line should be indented 3 tab stops, typing TAB
> > just once will insert all the 3 TABs in one go.
> >
> > That is what Emacs indentation commands are about: they insert the
> > whitespace as necessary according to your settings, so that you never
> > again should need to count TABs or insert them one by one.
> >
> > You should embrace this powerful feature instead of fighting against
> > it. It does need some setup to adapt to a particular style of
> > indentation, but that is one-time only, so really worth it.
> The point here is that they do not have a specific style, meaning the styles 
> vary, but emacs imposes some specific style that one has to set up.  And you 
> cannot degress from it.

Emacs doesn't impose any style.  By "style" I meant how many columns
should each construct be indented.  In Emacs, you can set all the
parameters of the style one by one via the menu I mentioned, and you
can do that according to the style used by whoever wrote these files.
Then you save your customizations, and Emacs will henceforth
automatically indent according to the style you defined by your

reply via email to

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