emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Ihor Radchenko <yantar92@gmail.com>
To: Fabio Natali <me@fabionatali.com>
Cc: emacs-orgmode@gnu.org
Subject: Re: Allowed characters/formatting in Org text blocks
Date: Sun, 26 Jun 2022 19:39:25 +0800	[thread overview]
Message-ID: <875ykn3b82.fsf@localhost> (raw)
In-Reply-To: <Yrg+W9Rs8TYjSplY@localhost>

Fabio Natali <me@fabionatali.com> writes:

> Incidentally and FWIW, this is a bit counter-intuitive to me. I'd have
> expected everything withing a comment or literal block to be treated as
> content until the ending statement, =#+end_comment= or =#+end_src=
> respectively. I suppose that this makes sense in the larger scheme of
> Org things though?

Each Org document consists of an optional first chapter followed by a
sequence of headlines. Each headline is a sequence of optional section
followed by sequence of child headlines. Each section is a sequence of
ordinary syntax elements. No syntax element ever intersect other
element.

So, headlines always have higher priority over other elements because
they always serve as separators of the document or parent heading
contents.

The high priority of headline elements has prons and cons.
Consider the following markdown markup:

     test 1
==============

```
    (message "Hello world!")

... 100 headings not shown ...

     test 2
==============

    (message "Hello world!")

```

Should "test 2" be considered a heading?
The answer is not so important in short documents, but long documents
with large number of headings may become very sensitive to incomplete or
broken markup like the above.
In Org, you just need to care about getting the headings right. Issues
with all other markup elements should never go beyond the containing
headline section, which is especially useful when Org document is used
as todo-list with large number of headings.

Best,
Ihor


  reply	other threads:[~2022-06-26 11:39 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-06-26  0:12 Allowed characters/formatting in Org text blocks Fabio Natali
2022-06-26  0:29 ` Ihor Radchenko
2022-06-26 11:09   ` Fabio Natali
2022-06-26 11:39     ` Ihor Radchenko [this message]
2022-06-26 17:31       ` Fabio Natali

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=875ykn3b82.fsf@localhost \
    --to=yantar92@gmail.com \
    --cc=emacs-orgmode@gnu.org \
    --cc=me@fabionatali.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).