aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/ChangeLog14
-rw-r--r--src/window.c2
-rw-r--r--src/xfns.c9
-rw-r--r--src/xterm.c25
4 files changed, 31 insertions, 19 deletions
diff --git a/src/ChangeLog b/src/ChangeLog
index 58495874b2b..d8bbe5a97be 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,3 +1,17 @@
12013-12-11 Martin Rudalics <rudalics@gmx.at>
2
3 * window.c (resize_frame_windows): Don't return immediately when
4 the root window's size doesn't change - the minibuffer window
5 may still have to be repositioned/resized.
6 * xfns.c (Fx_create_frame): Always change the frame size after
7 initializing the frame's faces.
8 * xterm.c (handle_one_xevent): Don't set pixel sizes here,
9 change_frame_size should already have done it.
10 (x_new_font): Assign new tool- and menu-bar heights.
11 (x_set_window_size_1): Account for tool- and menu-bar heights
12 (Bug#16013). Don't set pixel sizes since change_frame_size
13 should already have done it.
14
12013-12-11 Paul Eggert <eggert@cs.ucla.edu> 152013-12-11 Paul Eggert <eggert@cs.ucla.edu>
2 16
3 Remove the option of using libcrypto. 17 Remove the option of using libcrypto.
diff --git a/src/window.c b/src/window.c
index 426edc6099c..9bf6ad4b8f3 100644
--- a/src/window.c
+++ b/src/window.c
@@ -4057,7 +4057,7 @@ resize_frame_windows (struct frame *f, int size, bool horflag, bool pixelwise)
4057 r->pixel_top = FRAME_TOP_MARGIN_HEIGHT (f); 4057 r->pixel_top = FRAME_TOP_MARGIN_HEIGHT (f);
4058 4058
4059 if (new_pixel_size == old_pixel_size) 4059 if (new_pixel_size == old_pixel_size)
4060 return; 4060 ;
4061 else if (WINDOW_LEAF_P (r)) 4061 else if (WINDOW_LEAF_P (r))
4062 /* For a leaf root window just set the size. */ 4062 /* For a leaf root window just set the size. */
4063 if (horflag) 4063 if (horflag)
diff --git a/src/xfns.c b/src/xfns.c
index 3c8df12f8c5..7200c5fb2e7 100644
--- a/src/xfns.c
+++ b/src/xfns.c
@@ -3069,7 +3069,6 @@ This function is an internal primitive--use `make-frame' instead. */)
3069 happen. */ 3069 happen. */
3070 init_frame_faces (f); 3070 init_frame_faces (f);
3071 3071
3072#ifdef USE_GTK
3073 /* PXW: This is a duplicate from below. We have to do it here since 3072 /* PXW: This is a duplicate from below. We have to do it here since
3074 otherwise x_set_tool_bar_lines will work with the character sizes 3073 otherwise x_set_tool_bar_lines will work with the character sizes
3075 installed by init_frame_faces while the frame's pixel size is still 3074 installed by init_frame_faces while the frame's pixel size is still
@@ -3078,12 +3077,8 @@ This function is an internal primitive--use `make-frame' instead. */)
3078 non-pixelwise code apparently worked around this because it had one 3077 non-pixelwise code apparently worked around this because it had one
3079 frame line vs one toolbar line which left us with a zero root 3078 frame line vs one toolbar line which left us with a zero root
3080 window height which was obviously wrong as well ... */ 3079 window height which was obviously wrong as well ... */
3081 width = FRAME_TEXT_WIDTH (f); 3080 change_frame_size (f, FRAME_COLS (f) * FRAME_COLUMN_WIDTH (f),
3082 height = FRAME_TEXT_HEIGHT (f); 3081 FRAME_LINES (f) * FRAME_LINE_HEIGHT (f), 1, 0, 0, 1);
3083 FRAME_TEXT_HEIGHT (f) = 0;
3084 SET_FRAME_WIDTH (f, 0);
3085 change_frame_size (f, width, height, 1, 0, 0, 1);
3086#endif /* USE_GTK */
3087 3082
3088 /* Set the menu-bar-lines and tool-bar-lines parameters. We don't 3083 /* Set the menu-bar-lines and tool-bar-lines parameters. We don't
3089 look up the X resources controlling the menu-bar and tool-bar 3084 look up the X resources controlling the menu-bar and tool-bar
diff --git a/src/xterm.c b/src/xterm.c
index 90c7c36c44f..27d3d4a4bd1 100644
--- a/src/xterm.c
+++ b/src/xterm.c
@@ -6622,8 +6622,8 @@ handle_one_xevent (struct x_display_info *dpyinfo,
6622 cancel_mouse_face (f); 6622 cancel_mouse_face (f);
6623 } 6623 }
6624 6624
6625 FRAME_PIXEL_WIDTH (f) = event->xconfigure.width; 6625/** FRAME_PIXEL_WIDTH (f) = event->xconfigure.width; **/
6626 FRAME_PIXEL_HEIGHT (f) = event->xconfigure.height; 6626/** FRAME_PIXEL_HEIGHT (f) = event->xconfigure.height; **/
6627#endif /* not USE_GTK */ 6627#endif /* not USE_GTK */
6628#endif 6628#endif
6629 6629
@@ -7689,6 +7689,9 @@ x_new_font (struct frame *f, Lisp_Object font_object, int fontset)
7689 FRAME_COLUMN_WIDTH (f) = font->average_width; 7689 FRAME_COLUMN_WIDTH (f) = font->average_width;
7690 FRAME_LINE_HEIGHT (f) = FONT_HEIGHT (font); 7690 FRAME_LINE_HEIGHT (f) = FONT_HEIGHT (font);
7691 7691
7692 FRAME_TOOL_BAR_HEIGHT (f) = FRAME_TOOL_BAR_LINES (f) * FRAME_LINE_HEIGHT (f);
7693 FRAME_MENU_BAR_HEIGHT (f) = FRAME_MENU_BAR_LINES (f) * FRAME_LINE_HEIGHT (f);
7694
7692 compute_fringe_widths (f, 1); 7695 compute_fringe_widths (f, 1);
7693 7696
7694 /* Compute the scroll bar width in character columns. */ 7697 /* Compute the scroll bar width in character columns. */
@@ -8541,13 +8544,15 @@ x_set_window_size_1 (struct frame *f, int change_gravity, int width, int height,
8541 8544
8542 compute_fringe_widths (f, 0); 8545 compute_fringe_widths (f, 0);
8543 8546
8544 pixelwidth = 8547 pixelwidth = ((pixelwise
8545 (pixelwise ? width : FRAME_TEXT_COLS_TO_PIXEL_WIDTH (f, width)) 8548 ? FRAME_TEXT_TO_PIXEL_WIDTH (f, width)
8546 + FRAME_TOOLBAR_WIDTH (f); 8549 : FRAME_TEXT_COLS_TO_PIXEL_WIDTH (f, width))
8547 pixelheight = 8550 + FRAME_TOOLBAR_WIDTH (f));
8548 (pixelwise ? height : FRAME_TEXT_LINES_TO_PIXEL_HEIGHT (f, height)) 8551 pixelheight = ((pixelwise
8549 + FRAME_MENUBAR_HEIGHT (f) + FRAME_TOOLBAR_HEIGHT (f); 8552 ? FRAME_TEXT_TO_PIXEL_HEIGHT (f, height)
8550 8553 : FRAME_TEXT_LINES_TO_PIXEL_HEIGHT (f, height))
8554 + FRAME_MENUBAR_HEIGHT (f)
8555 + FRAME_TOOLBAR_HEIGHT (f));
8551 if (change_gravity) f->win_gravity = NorthWestGravity; 8556 if (change_gravity) f->win_gravity = NorthWestGravity;
8552 x_wm_set_size_hint (f, (long) 0, 0); 8557 x_wm_set_size_hint (f, (long) 0, 0);
8553 XResizeWindow (FRAME_X_DISPLAY (f), FRAME_OUTER_WINDOW (f), 8558 XResizeWindow (FRAME_X_DISPLAY (f), FRAME_OUTER_WINDOW (f),
@@ -8582,8 +8587,6 @@ x_set_window_size_1 (struct frame *f, int change_gravity, int width, int height,
8582 else 8587 else
8583 { 8588 {
8584 change_frame_size (f, width, height, 0, 1, 0, 1); 8589 change_frame_size (f, width, height, 0, 1, 0, 1);
8585 FRAME_PIXEL_WIDTH (f) = pixelwidth;
8586 FRAME_PIXEL_HEIGHT (f) = pixelheight;
8587 x_sync (f); 8590 x_sync (f);
8588 } 8591 }
8589} 8592}