Subject: Re: bug#75576: [PATCH] Take the tab-line into account when computing the window edges

From: Juri Linkov <[email-masked]>
Date: Thu, 16 Jan 2025 19:34:40 +0200

BTW, I don't know how this slipped through the cracks,
but now I checked again, and found more occurrences
to fix on master:

diff --git a/lisp/mouse.el b/lisp/mouse.el
index 6fe691693b4..dd0a2231c94 100644
--- a/lisp/mouse.el
+++ b/lisp/mouse.el
@@ -906,7 +906,9 @@ mouse-drag-line
 		  ;; If necessary, add height of header line to `position'
 		  (when (memq (posn-area start)
 			      '(nil left-fringe right-fringe left-margin right-margin))
-		    (setq position (+ (window-header-line-height posn-window) position))))
+		    (setq position (+ (window-header-line-height posn-window)
+				      (window-tab-line-height posn-window)
+				      position))))
 		;; When the cursor overshoots after shrinking a window to its
 		;; minimum size and the dragging direction changes, have the
 		;; cursor first catch up with the window edge.
diff --git a/lisp/gnus/gnus-art.el b/lisp/gnus/gnus-art.el
index 47499262b37..fd7fe01d2d8 100644
--- a/lisp/gnus/gnus-art.el
+++ b/lisp/gnus/gnus-art.el
@@ -6747,6 +6747,7 @@ gnus-article-beginning-of-window
 	  (max 1 (- (window-height)
 		    (if mode-line-format 1 0)
 		    (if header-line-format 1 0)
+		    (if tab-line-format 1 0)
 		    2))))))
 
 (defvar scroll-in-place)