[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Spaces rather than tabs by a major mode hook
From: |
goncholden |
Subject: |
Re: Spaces rather than tabs by a major mode hook |
Date: |
Sat, 11 Jun 2022 20:02:57 +0000 |
------- Original Message -------
On Saturday, June 11th, 2022 at 11:50 PM, Eli Zaretskii <eliz@gnu.org> wrote:
> > Date: Sat, 11 Jun 2022 11:15:59 +0000
> > From: goncholden goncholden@protonmail.com
> > Cc: help-gnu-emacs@gnu.org
> >
> > > 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
> > > customizations.
> >
> > Let me rephrase again. Emacs imposes indentation rules by requiring said
> > customisations.
>
>
> Emacs requires you to customize, once, the indentation so that it
> could thereafter help you by indenting everything automatically to
> suit the indentation style. That's a win by any measure.
That the problem you are taking ages to understand. "Emacs requires you to
customize", the origin of the problem.
> > The question about how many columns should each construct be indented, has
> > no answer.
>
>
> It should be possible to answer that question by just examining the
> file you posted.
No, because there are thousands of files. That was just an example to show how
emacs takes over the file, disallowing tabs and certain formatting because it
assumes that fortran files have a single style. Not true.
> Alternatively, you could just reindent the entire file according to
> the defaults, like this:
>
> C-x h
> C-M-\
>
> and then keep making changes without any customizations.
That would destroy the possibilities of easily detecting code changes. Only
want emacs to recognise that one cannot impose a style on legacy code. It
should be able to go along with no style.
The mantra that things can always be customised implies observance to a single
formatting scheme. Legacy code does not even subscribe to that. They only had
simple editors. If I introduce tabs with
"C-q TAB", all those tabs get removed by emacs as soon as one presses return at
the end of the line.
Emacs is acting like a dictator.
- Re: Spaces rather than tabs by a major mode hook, (continued)
- Re: Spaces rather than tabs by a major mode hook, Emanuel Berg, 2022/06/11
- Re: Spaces rather than tabs by a major mode hook, Eli Zaretskii, 2022/06/11
- Re: Spaces rather than tabs by a major mode hook, goncholden, 2022/06/11
- Re: Spaces rather than tabs by a major mode hook, Eli Zaretskii, 2022/06/11
- Re: Spaces rather than tabs by a major mode hook, goncholden, 2022/06/11
- Re: Spaces rather than tabs by a major mode hook, Eli Zaretskii, 2022/06/11
- Re: Spaces rather than tabs by a major mode hook, goncholden, 2022/06/11
- Re: Spaces rather than tabs by a major mode hook, Eli Zaretskii, 2022/06/11
- Re: Spaces rather than tabs by a major mode hook, goncholden, 2022/06/11
- Re: Spaces rather than tabs by a major mode hook, Eli Zaretskii, 2022/06/11
- Re: Spaces rather than tabs by a major mode hook,
goncholden <=
- RE: [External] : Re: Spaces rather than tabs by a major mode hook, Drew Adams, 2022/06/11
- RE: [External] : Re: Spaces rather than tabs by a major mode hook, goncholden, 2022/06/11
- Re: [External] : Re: Spaces rather than tabs by a major mode hook, Eli Zaretskii, 2022/06/12
- Re: [External] : Re: Spaces rather than tabs by a major mode hook, goncholden, 2022/06/12
- Re: [External] : Re: Spaces rather than tabs by a major mode hook, Eli Zaretskii, 2022/06/12
- Re: [External] : Re: Spaces rather than tabs by a major mode hook, goncholden, 2022/06/12
- Re: [External] : Re: Spaces rather than tabs by a major mode hook, Po Lu, 2022/06/12
- Re: [External] : Re: Spaces rather than tabs by a major mode hook, goncholden, 2022/06/12
- Re: Spaces rather than tabs by a major mode hook, Eli Zaretskii, 2022/06/12
- Re: Spaces rather than tabs by a major mode hook, goncholden, 2022/06/12