unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Stefan Monnier via "Bug reports for GNU Emacs, the Swiss army knife of text editors" <bug-gnu-emacs@gnu.org>
To: Visuwesh <visuweshm@gmail.com>
Cc: 56796@debbugs.gnu.org, eliz@gnu.org
Subject: bug#56796: 29.0.50; Hard newlines not respected in code comments?
Date: Fri, 29 Jul 2022 11:47:09 -0400	[thread overview]
Message-ID: <jwv35ek7wnu.fsf-monnier+emacs@gnu.org> (raw)
In-Reply-To: <87fsikynn1.fsf@gmail.com> (Visuwesh's message of "Fri, 29 Jul 2022 20:25:14 +0530")

> More generally: I'm not sure how common this pattern is but I tend to do
>
>     ;; TODO/FIXME: Something...
>     ;; Ideas and thoughts on how to clear it here.
>
> Now if you do M-q there, your neatly arranged text is destroyed.  (I am
> probably biased) I also catch this pattern in the Emacs source tree as
> well.

It never occurred to me to use hard newlines for such cases.  What I use
instead is either:
- add extra newlines to mark the paragraph boundaries to use
  (that's just as easy as adding hard newlines, but requires removing
  those extra newlines afterward).
- Select the intended paragraph rather than rely on M-q's automatic
  decision of what's a paragraph.

Hard newlines are a good idea, for this use-case, indeed, tho it would
be even better if we could somehow represent that info in the text
itself so it's properly saved into the file.


        Stefan






      parent reply	other threads:[~2022-07-29 15:47 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-07-27 15:49 bug#56796: 29.0.50; Hard newlines not respected in code comments? Visuwesh
2022-07-28  7:26 ` Eli Zaretskii
2022-07-28  8:20   ` Visuwesh
2022-07-29 14:32   ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-07-29 14:55     ` Visuwesh
2022-07-29 15:02       ` Visuwesh
2022-07-29 15:41         ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-07-29 16:16           ` Visuwesh
2022-07-29 15:47       ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors [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.gnu.org/software/emacs/

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

  git send-email \
    --in-reply-to=jwv35ek7wnu.fsf-monnier+emacs@gnu.org \
    --to=bug-gnu-emacs@gnu.org \
    --cc=56796@debbugs.gnu.org \
    --cc=eliz@gnu.org \
    --cc=monnier@iro.umontreal.ca \
    --cc=visuweshm@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.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).