master a1fa3714885: Draw NS window title with dimensions only when being dragged (bug#81458)

Alan Third <[email protected]> Thu, 30 Jul 2026 18:11:02 -0400 (EDT)
Newsgroups gmane.emacs.diffs
Message-ID <[email protected]>
branch: master
commit a1fa3714885c194aaaf807d762c8a1372c5b844f
Author: Stéphane Marks <[email protected]>
Commit: Alan Third <[email protected]>

    Draw NS window title with dimensions only when being dragged (bug#81458)
    
    This avoids stale temporary window titles when resizing is
    initiated mechanically via Applescript or using a macOS window
    manager like yabai.
    
    * src/nsterm.m: ([EmacsView windowWillResize:toSize]): Draw
    window title with new dimensions only when inLiveResize is true.
---
 src/nsterm.m | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/src/nsterm.m b/src/nsterm.m
index a7f3fc292c7..2c6954f0264 100644
--- a/src/nsterm.m
+++ b/src/nsterm.m
@@ -8266,7 +8266,10 @@ ns_in_echo_area (void)
             old_title = 0;
           }
       }
-    else if (fs_state == FULLSCREEN_NONE && ! maximizing_resize
+    /* Redraw the window title with new dimensions only when actively
+       being resized by a user.  */
+    else if ([[self window] inLiveResize]
+	     && fs_state == FULLSCREEN_NONE && ! maximizing_resize
              && [[self window] title] != NULL)
       {
         char *size_title;