]> git.eshelyaron.com Git - emacs.git/commitdiff
Prevent matrices from remaining invalid post mini-window resize
authorPo Lu <luangruo@yahoo.com>
Thu, 25 Jan 2024 04:17:54 +0000 (12:17 +0800)
committerEshel Yaron <me@eshelyaron.com>
Thu, 25 Jan 2024 18:04:43 +0000 (19:04 +0100)
* src/androidfns.c (android_create_tip_frame): Enable building
with GLYPH_DEBUG.

* src/window.c (resize_mini_window_apply): Garbage the frame if
F->redisplay is already set to indicate that redisplay_internal
should nevertheless return to it.

(cherry picked from commit caea0c1649d1df96b811c1388fde396e66bc356b)

src/androidfns.c
src/window.c

index bf8ab5b45cca19dd9cec2243972337bd77278fef..34f1f53368446a74f2b64fe09a97496029b047f6 100644 (file)
@@ -1931,9 +1931,6 @@ android_create_tip_frame (struct android_display_info *dpyinfo,
 
   image_cache_refcount
     = FRAME_IMAGE_CACHE (f) ? FRAME_IMAGE_CACHE (f)->refcount : 0;
-#ifdef GLYPH_DEBUG
-  dpyinfo_refcount = dpyinfo->reference_count;
-#endif /* GLYPH_DEBUG */
 
   gui_default_parameter (f, parms, Qfont_backend, Qnil,
                          "fontBackend", "FontBackend", RES_TYPE_STRING);
index 3a54f7ce7b11ee9e3385b92e48ae58d9eb7de2ec..915f591221d0dbcf50e31a4255f17d8990bc84ed 100644 (file)
@@ -5331,7 +5331,17 @@ resize_mini_window_apply (struct window *w, int delta)
   w->pixel_top = r->pixel_top + r->pixel_height;
   w->top_line = r->top_line + r->total_lines;
 
-  /* Enforce full redisplay of the frame.  */
+  /* Enforce full redisplay of the frame.  If f->redisplay is already
+     set, which it generally is in the wake of a ConfigureNotify
+     (frame resize) event, merely setting f->redisplay is insufficient
+     for redisplay_internal to continue redisplaying the frame, as
+     redisplay_internal cannot distinguish between f->redisplay set
+     before it calls redisplay_window and that after, so garbage the
+     frame as well.  */
+
+  if (f->redisplay)
+    SET_FRAME_GARBAGED (f);
+
   /* FIXME: Shouldn't some of the caller do it?  */
   fset_redisplay (f);
   adjust_frame_glyphs (f);