After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 692232 - Window size does not correspond to the window being created
Window size does not correspond to the window being created
Status: RESOLVED FIXED
Product: gtk+
Classification: Platform
Component: Backend: Win32
2.24.x
Other Windows
: Normal normal
: ---
Assigned To: gtk-win32 maintainers
gtk-bugs
Depends on:
Blocks:
 
 
Reported: 2013-01-21 20:02 UTC by Pavel
Modified: 2014-03-16 13:05 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Patch for inappropriate window size calculation (2.29 KB, patch)
2013-01-21 20:02 UTC, Pavel
none Details | Review

Description Pavel 2013-01-21 20:02:21 UTC
Created attachment 234044 [details] [review]
Patch for inappropriate window size calculation

The problem appears for example with Gimp running in multiple window mode under MS Windows. Each time Gimp is restarted, its tool windows are re-created a little bit taller than were previously saved in the sessionrc.

The problem is in gtk+, in gdk/win32 module, namely in "_gdk_win32_display_create_window_impl" function of gdkwindow-win32.c file. The window extent is calculated in this method using AdjustWindowRectEx call with arguments dwStyle and dwExStyle. Later, these two arguments are used in CreateWindowExW call, but at lease dwExStyle is changed between adjusting the rectangle and creating the window. Thus the window size is calculated for different window type, namely the windows with ex-style WS_EX_TOOLWINDOW are affected by this mistake.

Attached is the patch for the problem.