emacs-orgmode
[Top][All Lists]
Advanced

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

Should we make org-fill-element respect the selected region and not expa


From: Ihor Radchenko
Subject: Should we make org-fill-element respect the selected region and not expand the selection to the element boundaties? (was: Bug: org-fill-paragraph [9.3 (release_9.3 @ /usr/share/emacs/27.1/lisp/org/)])
Date: Thu, 06 Oct 2022 16:38:36 +0800

Ihor Radchenko <yantar92@gmail.com> writes:

> Edrie Ddrie <planete3@gmail.com> writes:
>
>> When using `org-fill-paragraph' on a part of a paragraph, e.g. with halve
>> the lines as active region, it still uses the unselected text around when
>> filling.
>> This works different than `fill-paragraph', `fill-region' and
>> `fill-region-as-paragraph' that fill only the selected part of a paragraph
>> WITHOUT effecting the text around.
>> I don't know if this is a real bug but it is confusing, and annoying
>> because org-mode overrides the default `C-q' key binding for
>> `fill-paragraph' so I have to invoke that command via M-x.
>
> Confirmed

While I understand that the current behaviour is unexpected, it is
internally consistent within Org for different kind of Org elements:
paragraphs, source blocks, comments, tables etc. For all the elements,
Org effectively expands the region boundaries to the beginning/end of
the first/last element in the selected region.

If we do decide to change expanding the selection to the element
boundaries, it should be done across all filled element types.

It will also be a breaking change.

Should we go for it?

-- 
Ihor Radchenko // yantar92,
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 via email to

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