From: Felix Lechner via "Bug reports for GNU Emacs, the Swiss army knife of text editors" <bug-gnu-emacs@gnu.org>
To: 56197@debbugs.gnu.org
Cc: Lars Ingebrigtsen <larsi@gnus.org>, Eli Zaretskii <eliz@gnu.org>,
Stefan Kangas <stefankangas@gmail.com>,
Maxim Cournoyer <maxim.cournoyer@gmail.com>
Subject: bug#56197: 28.1; lisp-fill-paragraph result regressed with Emacs 28
Date: Wed, 25 Dec 2024 12:15:44 -0800 [thread overview]
Message-ID: <87bjwzr027.fsf@lease-up.com> (raw)
In-Reply-To: <CADwFkmmR8Edn7k33WUj6ytMx_VqqRce+UcVE6NVfXt9daNdauQ@mail.gmail.com>
Hi everyone,
> fill the string using fill-column, or [...] fill the text as is in the
> buffer
> It's now filling that string as if it, well, is a string, so that if
> you insert it somewhere, the lines have similar lengths. The previous
> behaviour was to fill "what you see in the buffer"
> The former sounds more useful, IMO. I don't want to mess up my strings
> just to have pretty source code
Filling strings in code would be useful, but isn't that a separate,
don't-break-my-strings feature?
Historically, the point of text justification is to make text fit on a
screen. For example, the documentation for fill-region refers to
columns, which are features of buffers:
Column beyond which automatic line-wrapping should happen.
Auto-fill-mode is consistent:
inserting a space at a column beyond current-fill-column
automatically breaks the line
In a grand sweep, the manual explains what needs to fit where:
“Filling” text means breaking it up into lines that fit a specified
width.
Section 26.6.2 ("Explicit Fill Commands") is even more, well, explicit:
The command ‘M-q’ (‘fill-paragraph’) “fills” the current paragraph.
It redistributes the line breaks within the paragraph, and deletes
any excess space and tab characters occurring within the paragraph,
in such a way that the lines end up fitting within a certain maximum
width.
How text shows on a screen is clearly a central feature. The manual
continues:
The maximum line width for filling is specified by the buffer-local
variable ‘fill-column’. The default value (*note Locals::) is 70.
The easiest way to set ‘fill-column’ in the current buffer is to use
the command ‘C-x f’ (‘set-fill-column’). [...] Note that, by its
very nature, ‘fill-column’ is measured in column units; the actual
position of that column on a graphical display depends on the font
being used. In particular, using variable-pitch fonts will cause
the ‘fill-column’ occupy different horizontal positions on display
in different lines.
In my view, the string interpretation calls for a different, though
related feature.
Maybe there could be (setq fill-strings-instead-of-text t) ? Thanks!
Kind regards
Felix
next prev parent reply other threads:[~2024-12-25 20:15 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-06-24 16:17 bug#56197: 28.1; lisp-fill-paragraph result regressed with Emacs 28 Maxim Cournoyer
2022-06-25 11:53 ` Lars Ingebrigtsen
2022-06-25 12:42 ` Eli Zaretskii
2022-06-25 12:45 ` Lars Ingebrigtsen
2022-06-25 12:48 ` Lars Ingebrigtsen
2022-06-25 13:00 ` Lars Ingebrigtsen
2022-06-29 18:03 ` Stefan Kangas
2022-06-30 9:32 ` Lars Ingebrigtsen
2022-06-30 9:33 ` Lars Ingebrigtsen
2024-12-26 15:16 ` Stefan Kangas
2022-06-30 11:31 ` Maxim Cournoyer
2022-07-01 9:05 ` Lars Ingebrigtsen
2024-12-25 20:15 ` Felix Lechner via Bug reports for GNU Emacs, the Swiss army knife of text editors [this message]
2024-12-26 6:21 ` Eli Zaretskii
2022-06-27 1:53 ` Maxim Cournoyer
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87bjwzr027.fsf@lease-up.com \
--to=bug-gnu-emacs@gnu.org \
--cc=56197@debbugs.gnu.org \
--cc=eliz@gnu.org \
--cc=felix.lechner@lease-up.com \
--cc=larsi@gnus.org \
--cc=maxim.cournoyer@gmail.com \
--cc=stefankangas@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 external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.