emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[nongnu] elpa/visual-fill-column 043485d16a 026/137: Rename ::window-bod


From: ELPA Syncer
Subject: [nongnu] elpa/visual-fill-column 043485d16a 026/137: Rename ::window-body-width to ::window-max-text-width
Date: Sun, 2 Jan 2022 22:59:09 -0500 (EST)

branch: elpa/visual-fill-column
commit 043485d16a645c8c6df5d82bc77b8fc155a818aa
Author: Joost Kremers <joostkremers@fastmail.fm>
Commit: Joost Kremers <joostkremers@fastmail.fm>

    Rename ::window-body-width to ::window-max-text-width
---
 visual-fill-column.el | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/visual-fill-column.el b/visual-fill-column.el
index b1a21cb5db..3ab581d71b 100644
--- a/visual-fill-column.el
+++ b/visual-fill-column.el
@@ -100,11 +100,11 @@ in which `visual-line-mode' is active as well."
   (set-window-fringes (selected-window) nil nil 
visual-fill-column-fringes-outside-margins)
   (visual-fill-column--set-margins))
 
-(defun visual-fill-column--window-body-width (&optional window)
-  "Return the body width of WINDOW.
-The body width here refers to the width of the text area plus the
-margins, but excluding the fringes, scroll bar and right
-divider.  WINDOW defaults to the selected window."
+(defun visual-fill-column--window-max-text-width (&optional window)
+  "Return the maximum possible text width of WINDOW.
+The maximum possible text width is the width of the current text
+area plus the margins, but excluding the fringes, scroll bar and
+right divider.  WINDOW defaults to the selected window."
   (or window (setq window (selected-window)))
   (let ((margins (window-margins window)))
     (+ (window-width window)
@@ -115,7 +115,7 @@ divider.  WINDOW defaults to the selected window."
   "Set window margins for the current window."
   ;; calculate left & right margins
   (let* ((window (selected-window))
-         (total-width (visual-fill-column--window-body-width window))
+         (total-width (visual-fill-column--window-max-text-width window))
          (width (or visual-fill-column-width
                     fill-column))
          (margins (if (< (- total-width width) 0) ; margins must be >= 0



reply via email to

[Prev in Thread] Current Thread [Next in Thread]