all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Uwe Brauer <oub@mat.ucm.es>
To: help-gnu-emacs@gnu.org
Subject: the «inverse» function of join-lines
Date: Tue, 24 Oct 2023 11:25:53 +0200	[thread overview]
Message-ID: <87zg08pe1q.fsf@mat.ucm.es> (raw)


Hi


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?

Thanks

Uwe Brauer 


-- 
Warning: Content may be disturbing to some audiences
I strongly condemn Hamas bestialic terroristic attack on Israel, especially the despicable pogroms.
I strongly condemn Putin's war of aggression against Ukraine.
I support to deliver weapons to Ukraine's military. 
I support the NATO membership of Ukraine.
I support the EU membership of Ukraine. 
https://addons.thunderbird.net/en-US/thunderbird/addon/gmail-conversation-view/




             reply	other threads:[~2023-10-24  9:25 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-10-24  9:25 Uwe Brauer [this message]
2023-10-24  9:37 ` the «inverse» function of join-lines 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
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

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

  git send-email \
    --in-reply-to=87zg08pe1q.fsf@mat.ucm.es \
    --to=oub@mat.ucm.es \
    --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.
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.