summaryrefslogtreecommitdiff
path: root/lisp/emacs-lisp
diff options
context:
space:
mode:
authorEli Zaretskii <eliz@gnu.org>2024-07-06 11:28:39 +0300
committerEli Zaretskii <eliz@gnu.org>2024-07-06 11:28:39 +0300
commita3e57a29becdc028d5a5059c35b5f7be7c1510e4 (patch)
treeb9d30ee6b9c9d0b4588814ec222b4fcf1f323db5 /lisp/emacs-lisp
parent1b5cf29431a0727329d5e223be68ea2499d872ea (diff)
downloademacs-a3e57a29becdc028d5a5059c35b5f7be7c1510e4.tar.gz
emacs-a3e57a29becdc028d5a5059c35b5f7be7c1510e4.tar.bz2
emacs-a3e57a29becdc028d5a5059c35b5f7be7c1510e4.zip
; Fix doc string of 'string-fill'
* lisp/emacs-lisp/subr-x.el (string-fill): Rename LENGTH to WIDTH and update the doc string accordingly. (Bug#71856)
Diffstat (limited to 'lisp/emacs-lisp')
-rw-r--r--lisp/emacs-lisp/subr-x.el12
1 files changed, 6 insertions, 6 deletions
diff --git a/lisp/emacs-lisp/subr-x.el b/lisp/emacs-lisp/subr-x.el
index e62a08b7a8b..e725c490aba 100644
--- a/lisp/emacs-lisp/subr-x.el
+++ b/lisp/emacs-lisp/subr-x.el
@@ -159,16 +159,16 @@ removed."
blank blank)))
;;;###autoload
-(defun string-fill (string length)
- "Try to word-wrap STRING so that no lines are longer than LENGTH.
-Wrapping is done where there is whitespace. If there are
-individual words in STRING that are longer than LENGTH, the
-result will have lines that are longer than LENGTH."
+(defun string-fill (string width)
+ "Try to word-wrap STRING so that it displays with lines no wider than WIDTH.
+STRING is wrapped where there is whitespace in it. If there are
+individual words in STRING that are wider than WIDTH, the result
+will have lines that are wider than WIDTH."
(declare (important-return-value t))
(with-temp-buffer
(insert string)
(goto-char (point-min))
- (let ((fill-column length)
+ (let ((fill-column width)
(adaptive-fill-mode nil))
(fill-region (point-min) (point-max)))
(buffer-string)))