aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorMartin Rudalics2019-10-16 11:02:56 +0200
committerMartin Rudalics2019-10-16 11:02:56 +0200
commitd68e8495e032890fbfd31935b9f660400641f1d9 (patch)
tree49b9525b093a210bb84c213a78d1971a2fc7d2f6 /src
parent068b4fce52dce410a9cc1ee22649541a1823c711 (diff)
downloademacs-d68e8495e032890fbfd31935b9f660400641f1d9.tar.gz
emacs-d68e8495e032890fbfd31935b9f660400641f1d9.zip
Handle top margin change in adjust_frame_size
* src/frame.c (adjust_frame_size): Handle case where only pseudo windows changed height so the top margin has to be adjusted. * src/window.c (Fset_window_configuration): Call adjust_frame_size with inhibit 4.
Diffstat (limited to 'src')
-rw-r--r--src/frame.c11
-rw-r--r--src/window.c7
2 files changed, 9 insertions, 9 deletions
diff --git a/src/frame.c b/src/frame.c
index cc76cf4f697..8ca5106cb2a 100644
--- a/src/frame.c
+++ b/src/frame.c
@@ -704,18 +704,17 @@ adjust_frame_size (struct frame *f, int new_width, int new_height, int inhibit,
704 inhibit_vertical ? Qt : Qnil)); 704 inhibit_vertical ? Qt : Qnil));
705 705
706 if (FRAME_TERMINAL (f)->set_window_size_hook) 706 if (FRAME_TERMINAL (f)->set_window_size_hook)
707 FRAME_TERMINAL (f)->set_window_size_hook (f, 707 FRAME_TERMINAL (f)->set_window_size_hook
708 0, 708 (f, 0, new_text_width, new_text_height, 1);
709 new_text_width,
710 new_text_height,
711 1);
712 f->resized_p = true; 709 f->resized_p = true;
713 710
714 return; 711 return;
715 } 712 }
716#endif 713#endif
717 714
718 if (new_text_width == old_text_width 715 if ((XWINDOW (FRAME_ROOT_WINDOW (f))->pixel_top
716 == FRAME_TOP_MARGIN_HEIGHT (f))
717 && new_text_width == old_text_width
719 && new_text_height == old_text_height 718 && new_text_height == old_text_height
720 && new_windows_width == old_windows_width 719 && new_windows_width == old_windows_width
721 && new_windows_height == old_windows_height 720 && new_windows_height == old_windows_height
diff --git a/src/window.c b/src/window.c
index ba9af3b9b0c..1e6e148bf48 100644
--- a/src/window.c
+++ b/src/window.c
@@ -7129,10 +7129,11 @@ the return value is nil. Otherwise the value is t. */)
7129 if (NILP (leaf_windows[i]->contents)) 7129 if (NILP (leaf_windows[i]->contents))
7130 free_window_matrices (leaf_windows[i]); 7130 free_window_matrices (leaf_windows[i]);
7131 7131
7132 /* Allow set_window_size_hook again and apply frame size changes 7132 /* Allow set_window_size_hook again and resize frame's windows
7133 if needed. */ 7133 if necessary. But change frame size only to preserve window
7134 minimum sizes. */
7134 f->can_set_window_size = true; 7135 f->can_set_window_size = true;
7135 adjust_frame_size (f, -1, -1, 1, false, Qset_window_configuration); 7136 adjust_frame_size (f, -1, -1, 4, false, Qset_window_configuration);
7136 7137
7137 adjust_frame_glyphs (f); 7138 adjust_frame_glyphs (f);
7138 unblock_input (); 7139 unblock_input ();