GNOME Bugzilla – Bug 625972
gdk_window_ensure_native changes window position
Last modified: 2018-02-10 03:26:00 UTC
When I call gdk_window_ensure_native() on a GdkWindow, the window moves to the point (0, 0). I'm attaching a test program that creates a GtkDrawingArea, and paints it red in the expose callback. On Ubuntu Intrepid it works fine. On windows, the drawing area does not get painted correctly. Using winspector spy, I see that the native window is positioned at the (0, 0) coordinates of the window. The width and height seem to be correct. The program works fine if the call to gdk_window_ensure_native() is commented out.
Created attachment 167120 [details] Test C File
One more thing to note: this bug was opened because of our development on Miro. We ran into a problem embedding XULRunner and VLC when upgrading from GTK 2.16 to 2.20. Here's a bug in our tracker with some more details: http://bugzilla.pculture.org/show_bug.cgi?id=14037
One more note: I misreported by ubuntu version. It's 10.4, AKA Lucid.
There is more broken with Gtk 2.2x (and 2.18) on win32. See: http://mail.gnome.org/archives/gtk-devel-list/2010-August/msg00200.html
Thanks for working on this issue. If I can be of any help, please tell me what to do. I would love to get this working for the next version of GTK. The functionality is for much more than just eclipse, embedding other components (which is what we do for Miro) seems like a pretty common use case.
I've just pushed my changes to gtk-2-22 branch, so it should work a bit better now. It would be nice to have this confirmed.
(In reply to comment #6) > I've just pushed my changes to gtk-2-22 branch, so it should work a bit better > now. It would be nice to have this confirmed. Hans, while you have a working dev. setup, would you mind committing the patches on bug 598299 to the gtk-2-22 branch?
We're moving to gitlab! As part of this move, we are closing bugs that haven't seen activity in more than 5 years. If this issue is still imporant to you and still relevant with GTK+ 3.22 or master, please consider creating a gitlab issue for it.