1 To: vim_dev@googlegroups.com
4 From: Bram Moolenaar <Bram@moolenaar.net>
6 Content-Type: text/plain; charset=UTF-8
7 Content-Transfer-Encoding: 8bit
11 Problem: With GTK, when gvim is full-screen and a tab is opened and using a
12 specific monitor configuration the window is too big.
13 Solution: Adjust the window size like on MS-Windows. (Yukihiro Nakadaira)
14 Files: src/gui.c, src/gui_gtk_x11.c, src/proto/gui_gtk_x11.pro
17 *** ../vim-7.3.278/src/gui.c 2011-06-26 04:48:56.000000000 +0200
18 --- src/gui.c 2011-08-10 17:40:31.000000000 +0200
21 if (!gui.shell_created)
25 /* If not setting to a user specified size and maximized, calculate the
26 * number of characters that fit in the maximized window. */
27 if (!mustset && gui_mch_maximized())
29 if (!gui.shell_created)
32 ! #if defined(MSWIN) || defined(FEAT_GUI_GTK)
33 /* If not setting to a user specified size and maximized, calculate the
34 * number of characters that fit in the maximized window. */
35 if (!mustset && gui_mch_maximized())
36 *** ../vim-7.3.278/src/gui_gtk_x11.c 2011-06-26 04:48:56.000000000 +0200
37 --- src/gui_gtk_x11.c 2011-08-10 17:42:19.000000000 +0200
44 + * Called when the font changed while the window is maximized. Compute the
45 + * new Rows and Columns. This is like resizing the window.
52 + gtk_window_get_size(GTK_WINDOW(gui.mainwin), &w, &h);
53 + w -= get_menu_tool_width();
54 + h -= get_menu_tool_height();
55 + gui_resize_shell(w, h);
59 * Set the windows size.
65 if (gui_mch_maximized())
69 /* Update lines and columns in accordance with the new font, keep the
70 * window maximized. */
71 ! gtk_window_get_size(GTK_WINDOW(gui.mainwin), &w, &h);
72 ! w -= get_menu_tool_width();
73 ! h -= get_menu_tool_height();
74 ! gui_resize_shell(w, h);
80 if (gui_mch_maximized())
82 /* Update lines and columns in accordance with the new font, keep the
83 * window maximized. */
88 *** ../vim-7.3.278/src/proto/gui_gtk_x11.pro 2010-08-15 21:57:28.000000000 +0200
89 --- src/proto/gui_gtk_x11.pro 2011-08-10 17:42:29.000000000 +0200
93 void gui_mch_set_winpos __ARGS((int x, int y));
94 int gui_mch_maximized __ARGS((void));
95 void gui_mch_unmaximize __ARGS((void));
96 + void gui_mch_newfont __ARGS((void));
97 void gui_mch_set_shellsize __ARGS((int width, int height, int min_width, int min_height, int base_width, int base_height, int direction));
98 void gui_mch_get_screen_dimensions __ARGS((int *screen_w, int *screen_h));
99 void gui_mch_settitle __ARGS((char_u *title, char_u *icon));
100 *** ../vim-7.3.278/src/version.c 2011-08-10 17:25:48.000000000 +0200
101 --- src/version.c 2011-08-10 17:43:22.000000000 +0200
105 { /* Add new patch number below this line */
111 LAUNCELOT: Isn't there a St. Aaaaarrrrrrggghhh's in Cornwall?
112 ARTHUR: No, that's Saint Ives.
113 "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD
115 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\
116 /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
117 \\\ an exciting new programming language -- http://www.Zimbu.org ///
118 \\\ help me help AIDS victims -- http://ICCF-Holland.org ///