diff options
author | Po Lu <luangruo@yahoo.com> | 2022-12-26 15:57:06 +0800 |
---|---|---|
committer | Po Lu <luangruo@yahoo.com> | 2022-12-26 15:57:48 +0800 |
commit | cc29fab3a66c59e77d0ff67c0f3e2e34ec80a03c (patch) | |
tree | 07d54371ad2a25bd0f01b0cfbfeffefb574f87cc /src/xterm.h | |
parent | 419ca81809c2eda9c9f102b7da820a6eb9685cc8 (diff) | |
download | emacs-cc29fab3a66c59e77d0ff67c0f3e2e34ec80a03c.tar.gz |
Redisplay "invisible" frames that are actually visible on modern X
* etc/NEWS: Document that "invisible" frames are now redisplayed
if the compositing manager is still displaying it as part of a
thumbnail out of Emacs's control.
* src/dispnew.c (Fredraw_display): Use FRAME_REDISPLAY_P.
* src/frame.h (FRAME_REDISPLAY_P): New macro.
* src/xdisp.c (clear_garbaged_frames, echo_area_display)
(prepare_menu_bars, redisplay_internal, display_and_set_cursor)
(gui_clear_cursor): Use FRAME_REDISPLAY_P to determine whether
or not a frame should be redisplayed.
* src/xfns.c (Fx_create_frame): Set visibility state initially.
* src/xterm.c (handle_one_xevent): Likewise.
* src/xterm.h (struct x_output): New field `visibility_state'.
Diffstat (limited to 'src/xterm.h')
-rw-r--r-- | src/xterm.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/xterm.h b/src/xterm.h index 832ffc172b9..f06e1ec5bc6 100644 --- a/src/xterm.h +++ b/src/xterm.h @@ -1290,6 +1290,11 @@ struct x_output strictly an optimization to avoid extraneous synchronizing in some cases. */ int root_x, root_y; + + /* The frame visibility state. This starts out + VisibilityFullyObscured, but is set to something else in + handle_one_xevent. */ + int visibility_state; }; enum @@ -1408,6 +1413,11 @@ extern void x_mark_frame_dirty (struct frame *f); /* And its corresponding visual info. */ #define FRAME_X_VISUAL_INFO(f) (&FRAME_DISPLAY_INFO (f)->visual_info) +/* Whether or not the frame is visible. Do not test this alone. + Instead, use FRAME_REDISPLAY_P. */ +#define FRAME_X_VISIBLE(f) (FRAME_X_OUTPUT (f)->visibility_state \ + != VisibilityFullyObscured) + #ifdef HAVE_XRENDER #define FRAME_X_PICTURE_FORMAT(f) FRAME_DISPLAY_INFO (f)->pict_format #define FRAME_X_PICTURE(f) ((f)->output_data.x->picture) |