Commit 09c220a5 authored by Eli Zaretskii's avatar Eli Zaretskii

Minor fixes for the last change

* lisp/simple.el (delete-indentation):
* doc/emacs/indent.texi (Indentation Commands):
* etc/NEWS: Fix last change.  (Bug#34796)
parent 8fa94a1e
Pipeline #1053 passed with stage
in 56 minutes and 42 seconds
...@@ -110,9 +110,9 @@ parentheses, or if the junction follows another newline. ...@@ -110,9 +110,9 @@ parentheses, or if the junction follows another newline.
If there is a fill prefix, @kbd{M-^} deletes the fill prefix if it If there is a fill prefix, @kbd{M-^} deletes the fill prefix if it
appears after the newline that is deleted. @xref{Fill Prefix}. appears after the newline that is deleted. @xref{Fill Prefix}.
With the universal prefix argument, join the current line line to the With a prefix argument, join the current line line to the following
following line. With the region active, join lines in the region. If line. If the region is active, and no prefix argument is given, join
both the argument is set and the region is active, the region is ignored. all lines in the region instead.
@item C-M-\ @item C-M-\
@kindex C-M-\ @kindex C-M-\
......
...@@ -370,8 +370,10 @@ region using a given replacement-function in a non-destructive manner ...@@ -370,8 +370,10 @@ region using a given replacement-function in a non-destructive manner
arguments mitigating performance issues when operating on huge arguments mitigating performance issues when operating on huge
buffers. buffers.
** The command `delete-indentation` now can operate on the active ** The command 'delete-indentation' now operates on the active region.
region If the region is active, the command joins all the lines in the
region. When there's no active region, the command works on the
current and the previous or the next line, as before.
+++ +++
......
...@@ -596,9 +596,10 @@ When called from Lisp code, ARG may be a prefix string to copy." ...@@ -596,9 +596,10 @@ When called from Lisp code, ARG may be a prefix string to copy."
(defun delete-indentation (&optional arg beg end) (defun delete-indentation (&optional arg beg end)
"Join this line to previous and fix up whitespace at join. "Join this line to previous and fix up whitespace at join.
If there is a fill prefix, delete it from the beginning of this If there is a fill prefix, delete it from the beginning of this
line. With prefix ARG, join the current line to the following line. line.
With the region active, join lines in the region. If both the With prefix ARG, join the current line to the following line.
argument is set and the region is active, the region is ignored." If the region is active, join all the lines in the region. (The
region is ignored if prefix argument is given.)"
(interactive "*P\nr") (interactive "*P\nr")
(if arg (forward-line 1) (if arg (forward-line 1)
(if (use-region-p) (if (use-region-p)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment