[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Changed list indentation behavior: how to revert?
From: |
Detlef Steuer |
Subject: |
Re: Changed list indentation behavior: how to revert? |
Date: |
Sun, 15 Nov 2020 12:58:30 +0100 |
Am Sun, 15 Nov 2020 08:48:56 -0300
schrieb Gustavo Barros <gtvbrs@gmail.com>:
> Hi All,
>
> On Sun, 15 Nov 2020 at 13:37, Greg Minshall <minshall@umich.edu>
> wrote:
>
> > hi, all.
> >
> > David Rogers <davidandrewrogers@gmail.com> wrote:
> >
> >> Am I crazy to say that your last example of unwanted behavior is
> >> easier for me to read and understand? (and to me the common
> >> indenting is a hopeless mess?)
> >
> > yes, in fact, the "new" way sort of has the buffer indentation match
> > that of the outline structure of the file (specified by asterisks).
> > there's a lot to be said for that. (though, obviously, it's not
> > what everyone would want.)
> >
> > if the new mode stays as the standard, maybe we'd want to capture an
> > asterisk typed immediately after a newline that would (by default),
> > put that line-beginning asterisk back in column one?
> >
> > otherwise, this is what one gets (without remembering to do a C-j
> > instead of <RET>):
> > -----
> > * i wanted a headline<RET>
> > * i wanted a subhead, but it's ignored by org mode
> > -----
> > which is maybe not optimal?
> >
> > in most non-org modes (including in Org Src... buffers, and in org
> > files when writing org-mode lists), i'm a big fan of electric
> > indent mode.
> >
> > maybe an org-specific setting, "org-file-indent-follows-structure"?
> > if true, it means the user wants to have a "raw" org document laid
> > out according to the outline structure of the document. if false,
> > it means one, in general, wants the org file laid out with
> > left-alignment (or, right, in right-to-left) languages (not
> > including embedded lists, and whatever else i might be ignoring).
> >
> > cheers, Greg
>
> I'm quite surprised by the reaction to this issue, because
> `electric-indent-mode' *does not change Org's indentation settings*,
> it just applies them alongside RET. Which makes me think that those
> who've been so bitten by it where actually manually overriding (their
> own) settings in this area by never applying indentation. If that's
> your case, you'd probably be very surprised of running
> `org-indent-region' in your documents (don't do it, I don't want to
> break them).
>
> In particular, one "surprising" result of the "new behavior" is that
> of indentation after a heading. That was already and continues to be
> controlled by the user option `org-adapt-indentation'. If you don't
> want your content to be indented after a heading, set it to nil. And
> `electric-indent-mode' should do what you expect in this regard.
>
> I'm not sure if thus overriding your own (or Org's, if you prefer)
> indentation settings by selectively applying indentation is a sane
> approach, so perhaps `electric-indent-mode' may help you discipline
> your editing to your benefit. And make you more conscious of Org
> indentation. Especially because indentation is not a "free variable"
> in Org, it is a syntactical aspect of an Org document and,
> conspicuously, is critical to the definition of a heading and of
> plain lists.
>
> An example from Greg:
>
> > -----
> > * i wanted a headline<RET>
> > * i wanted a subhead, but it's ignored by org mode
> > -----
>
> That's because the first one is indeed a heading, and the second is
> not, it is a plain list item. By definition a heading must start at
> the left margin.
>
> You (plural) could probably also get some juice from looking into, and
> incorporating to muscle memory, `M-RET', `C-RET' and `C-j'.
>
> Of course, with that said, if you really don't like
> `electric-indent-mode' for Org, you can disable it as described in the
> Org News, previously linked to in this thread. There is ground to
> prefer this, particularly for the list case, mentioned by Karl in the
> original message of this thread. But `electric-indent-mode' does not
> induce a new pattern of indentation for Org, it just applies your
> settings in this area, whose defaults have not changed of recent, as
> far as I recall.
>
> Finally, the "change" was not brought about by Org, but by Emacs. Org
> just (belatedly) tagged along.
>
> Best regards,
> Gustavo.
>
Thank you for clearing that up!
Detlef
- Re: Changed list indentation behavior: how to revert?, (continued)
- Re: Changed list indentation behavior: how to revert?, Jean Louis, 2020/11/13
- Re: Changed list indentation behavior: how to revert?, David Rogers, 2020/11/14
- Re: Changed list indentation behavior: how to revert?, Jean Louis, 2020/11/15
- Re: Changed list indentation behavior: how to revert?, David Rogers, 2020/11/15
- Re: Changed list indentation behavior: how to revert?, Jean Louis, 2020/11/15
- Re: Changed list indentation behavior: how to revert?, Greg Minshall, 2020/11/15
- Re: Changed list indentation behavior: how to revert?, Tim Cross, 2020/11/15
- Re: Changed list indentation behavior: how to revert?, Gustavo Barros, 2020/11/15
- Re: Changed list indentation behavior: how to revert?,
Detlef Steuer <=
- Re: Changed list indentation behavior: how to revert?, Jean Louis, 2020/11/15
- Re: Changed list indentation behavior: how to revert?, Gustavo Barros, 2020/11/15
- Re: Changed list indentation behavior: how to revert?, Jean Louis, 2020/11/15
- Re: Changed list indentation behavior: how to revert?, Dr. Arne Babenhauserheide, 2020/11/15
- Re: Changed list indentation behavior: how to revert?, Detlef Steuer, 2020/11/15
- Re: Changed list indentation behavior: how to revert?, Kévin Le Gouguec, 2020/11/15
- Re: Changed list indentation behavior: how to revert?, Kyle Meyer, 2020/11/16
- Re: Changed list indentation behavior: how to revert?, Tim Cross, 2020/11/16
- Re: Changed list indentation behavior: how to revert?, Tim Cross, 2020/11/16
- Re: Changed list indentation behavior: how to revert?, Gustavo Barros, 2020/11/16