Subject: [PATCH] Fix `window-state-put' `min-width' (bug#79013)

From: Derick Eddington <[email-masked]>
Date: Mon, 14 Jul 2025 09:08:05 +0000

Fixes: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=79013
by simply changing the single `'min-weight' typo to `'min-width'.

From f2a41a72642f6495ecfa67ff8bf86aa9ec0a2c1a Mon Sep 17 00:00:00 2001
From: Derick Eddington <[email-masked]>
Date: Mon, 14 Jul 2025 01:27:13 -0700
Subject: [PATCH] Fix `window-state-put' `min-width' (bug#79013)

* lisp/window.el (window-state-put):
Fix incorrect `'min-weight' key that should be `'min-width' instead,
for the lookup in the alist.  This mistake was introduced in commit
880e615 "Support resizing frames and windows pixelwise." in the year
2013.  Previously, `'min-width' had been used, but when that commit
introduced `'min-pixel-width' it also typoed as `'min-weight' its
attempt at preserving the `'min-width'.

Signed-off-by: Derick Eddington <[email-masked]>
---
 lisp/window.el | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lisp/window.el b/lisp/window.el
index e229562163b..5509f36fbe9 100644
--- a/lisp/window.el
+++ b/lisp/window.el
@@ -6803,7 +6803,7 @@ was killed since STATE was made, it will consult the variable
 			   (if pixelwise 'min-pixel-height 'min-height)
 			   head)))
 	 (min-width (cdr (assq
-			  (if pixelwise 'min-pixel-width 'min-weight)
+			  (if pixelwise 'min-pixel-width 'min-width)
 			  head)))
 	 ;; Bind the following two variables.  `window--state-put-1' has
 	 ;; to fully control them (see Bug#50867 and Bug#64405).
-- 
2.47.2