emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Ihor Radchenko <yantar92@gmail.com>
To: Max Nikulin <manikulin@gmail.com>
Cc: emacs-orgmode@gnu.org,  Matt Beshara <m@mfa.pw>
Subject: Re: Should page break (^L) work as paragraph element separator and be included into Org syntax? (was: [BUG] org-fill-paragraph doesn't handle ^L correctly)
Date: Wed, 28 Sep 2022 09:00:29 +0800	[thread overview]
Message-ID: <87edvwgvo2.fsf@localhost> (raw)
In-Reply-To: <63621195-babb-8599-7086-5a00976cff59@gmail.com>

Max Nikulin <manikulin@gmail.com> writes:

>  > Actually ^L is a *page* separator (to be exact “FORM FEED”).
>
> I have realized that page separator for plain text is not necessary 
> paragraph separator. The same paragraph may continue on the next page. 
> It makes things more tricky. ^L should be kept on its own line while 
> text around should be wrapped.

Good point.

> However from a discussion happened a year ago I concluded that it may be 
> not so trivial to tune `org-fill-element' for special cases.
>
> Timothy. Re: [PATCH] Don't fill displayed equations. Sun, 03 Oct 2021 
> 16:50:54 +0800. https://list.orgmode.org/875yueij6r.fsf@gmail.com

Actually, it is not that much hard. At least, it is not that hard for
paragraphs.

The linked discussion had other caveats involving whether
special filling is even reasonable for the discussed elements
(AFAIR).

However, org-fill-element actually does have a special treatment for
line-break objects inside paragraphs. There is nothing preventing us
from special treatment of other types of objects in similar fashion.

In fact, we may even utilize Emacs built-ins for page break symbols
specifically. Just use fill-region instead of fill-region-as-paragraph.
Similar to https://orgmode.org/list/875yhiyxnb.fsf@localhost
It's just that I am not sure about other possible side effects of such
change.

P.S. Does LaTeX understand ^L?

-- 
Ihor Radchenko,
Org mode contributor,
Learn more about Org mode at https://orgmode.org/.
Support Org development at https://liberapay.com/org-mode,
or support my work at https://liberapay.com/yantar92


      reply	other threads:[~2022-09-28  1:00 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-09-24 23:39 [BUG] org-fill-paragraph doesn't handle ^L correctly [9.5.4 (release_9.5.4-19-g4dff42 @ /home/matt/Code/emacs/lisp/org/)] Matt Beshara
2022-09-26 11:39 ` Should page break (^L) work as paragraph element separator and be included into Org syntax? (was: [BUG] org-fill-paragraph doesn't handle ^L correctly [9.5.4 (release_9.5.4-19-g4dff42 @ /home/matt/Code/emacs/lisp/org/)]) Ihor Radchenko
2022-09-26 15:10   ` Matt Beshara
2022-09-27  6:21     ` Robert Klein
2022-09-26 16:13   ` Max Nikulin
2022-09-26 20:13     ` Tim Cross
2022-09-27 10:48       ` Should page break (^L) work as paragraph element separator and be included into Org syntax? (was: [BUG] org-fill-paragraph doesn't handle ^L correctly) Max Nikulin
2022-09-28  1:00         ` Ihor Radchenko [this message]

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=87edvwgvo2.fsf@localhost \
    --to=yantar92@gmail.com \
    --cc=emacs-orgmode@gnu.org \
    --cc=m@mfa.pw \
    --cc=manikulin@gmail.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).