From: Tim Landscheidt <tim@tim-landscheidt.de>
To: help-gnu-emacs@gnu.org
Subject: Re: the «inverse» function of join-lines
Date: Tue, 24 Oct 2023 10:10:13 +0000 [thread overview]
Message-ID: <87sf602uwq.fsf@vagabond.tim-landscheidt.de> (raw)
In-Reply-To: <87zg08pe1q.fsf@mat.ucm.es> (Uwe Brauer's message of "Tue, 24 Oct 2023 11:25:53 +0200")
Uwe Brauer <oub@mat.ucm.es> wrote:
> I am not sure that the term inverse is here very appropriate, but I
> can't come with another term.
> Here is the problem. Suppose you have text like this
> this is important blabla
> but we also want
> So I want to obtain
> this is important blabla but we also want
> The easiest way of doing it, is to put the cursor on b of but and run
> joint-line (which is an alias for delete-indentation)
> However most of the time my cursor is on a in blabla, if I then run
> kill-line I obtain
> this is important blabla but we also want
> And I need to run delete-horizontal-space.
> If I define
> (defun my-join-line-from-above ()
> (interactive)
> (save-excursion
> (kill-line nil)
> (delete-horizontal-space nil)))
> And use it I end up
> this is important blablabut we also want
> So I wonder is there a function that does what I want, and is a bit more
> sophisticated then what I cooked up?
My work flow usually assumes that "related" text lines form
a paragraph. Thus, I use fill-paragraph (M-q) to (re-)for-
mat those, normalizing whitespace along the way.
Tim
next prev parent reply other threads:[~2023-10-24 10:10 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-10-24 9:25 the «inverse» function of join-lines Uwe Brauer
2023-10-24 9:37 ` Emanuel Berg
2023-10-24 9:47 ` Yuri Khan
2023-10-24 10:12 ` Yuri Khan
2023-10-24 12:17 ` Uwe Brauer
2023-10-24 14:23 ` Yuri Khan
2023-10-24 10:10 ` Tim Landscheidt [this message]
2023-10-24 12:18 ` Uwe Brauer
2023-10-24 12:50 ` Nikolay Kudryavtsev
2023-10-24 14:43 ` Uwe Brauer
2023-11-23 15:50 ` Nikolay Kudryavtsev
2023-11-23 20:57 ` Emanuel Berg
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=87sf602uwq.fsf@vagabond.tim-landscheidt.de \
--to=tim@tim-landscheidt.de \
--cc=help-gnu-emacs@gnu.org \
/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.
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).