summaryrefslogtreecommitdiff
path: root/src/frame.h
diff options
context:
space:
mode:
authorMartin Rudalics <rudalics@gmx.at>2021-05-12 09:44:02 +0200
committerMartin Rudalics <rudalics@gmx.at>2021-05-12 09:44:02 +0200
commitb41f39d22cdb921fe88311f4fd113cbb9c2f0c76 (patch)
tree6bdb2ec7ead4dace5a00914a12b2b90e3a7921f9 /src/frame.h
parent47070ed39eda524d334e5f82dc7f4a50b8d3252c (diff)
downloademacs-b41f39d22cdb921fe88311f4fd113cbb9c2f0c76.tar.gz
Handle Bug#24526 without breaking Emacs on tiling WMs (Bug#48268)
Since tiling window managers may react allergically to resize requests immediately following MapNotify events on X, make sure that such requests are issued only when a new frame should not become visible and a size has been explicitly requested for it. * lisp/faces.el (x-create-frame-with-faces): Mark frame as 'was-invisible' if it should be initially invisible or iconified and has its size specified explicitly. * src/frame.c (make_frame): Initialize new frame's was_invisible flag. (Fframe__set_was_invisible): New internal function. * src/frame.h (struct frame): Specify size of new_size_p slot. New flag was_invisible. * src/w32fns.c (Fx_create_frame) * src/nsfns.m (Fx_create_frame) * src/xfns.c (Fx_create_frame): Set new frame's was_invisible flag. * src/xterm.c (handle_one_xevent): Call xg_frame_set_char_size after a PropertyNotify or MapNotify event only if F's was_invisible flag was set.
Diffstat (limited to 'src/frame.h')
-rw-r--r--src/frame.h6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/frame.h b/src/frame.h
index 744b95e1e04..75a0b184c19 100644
--- a/src/frame.h
+++ b/src/frame.h
@@ -456,7 +456,11 @@ struct frame
/* True when new_width or new_height were set by change_frame_size,
false when they were set by adjust_frame_size internally or not
set. */
- bool_bf new_size_p;
+ bool_bf new_size_p : 1;
+
+ /* True when frame was invisible before first MapNotify event. Used
+ in X builds only. */
+ bool_bf was_invisible : 1;
/* Bitfield area ends here. */