GNOME Bugzilla – Bug 591373
In Eclipse, buttons associated with a detached view vanish when it is moved
Last modified: 2009-09-03 12:42:54 UTC
Please describe the problem: (An Eclipse-specific bug, sorry. I've not found anything simpler that reproduces it.) In Eclipse, views such as the Console or Search view have a toolbar of buttons that appears to the right of the tab bearing the name of the view. Starting in gtk+ 2.17.3 (2.17.2 is not affected), this toolbar of buttons disappears when the view is dragged between windows, and will then not reappear until Eclipse is restarted. Steps to reproduce: 1. Start Eclipse, and ensure that the Console and/or Search views are visible and docked within the main window. If they were not already, quit and restart Eclipse now. 2. Observe that a toolbar of buttons relating to the view is present to the right of its tab. 3. Drag the view so that it becomes detached from the main window. 4. Observe that the toolbar has vanished. Actual results: (see above) Expected results: The toolbar should not disappear Does this happen every time? Yes. Other information: Ubuntu Karmic (development release), up to date. gtk+ 2.17.6. Rolling back to previous versions isolates the introduction of the problem to between 2.17.2 and 2.17.3. However, hacking the source of gdk_window_new to create all windows as native, which alleviates several other bugs, does *not* alleviate this one.
Can you please retry with 2.17.7 (or even better with 2.17.8, due out later this week). Several csw regressions have been fixed since 2.17.6.
Still a problem with 2.17.7. I'll attempt to build git HEAD and try it, though I've never built gtk+ before.
"which alleviates several other bugs" Are these bugs filed in bugzilla? If so, could you tag them with "csw" in the whiteboard?
Also, i'm not quite sure what you mean by the toolbar. Can you attach a screenshot of what you mean?
(In reply to comment #3) > "which alleviates several other bugs" > > Are these bugs filed in bugzilla? If so, could you tag them with "csw" in the > whiteboard? http://bugzilla.gnome.org/show_bug.cgi?id=589963 - Not tagged, Bugzilla seems to be denying me the right to edit the whiteboard. http://bugzilla.gnome.org/show_bug.cgi?id=588437 - Was already tagged, and RESOLVED FIXED.
Created attachment 140978 [details] Screenshot showing the problem.
Created attachment 140979 [details] Screenshot showing what is supposed to appear
(In reply to comment #4) > Also, i'm not quite sure what you mean by the toolbar. Can you attach a > screenshot of what you mean? I've attached two screenshots, one showing the view appearing correctly immediately after Eclipse startup, and one showing the same view with some UI elements missing after docking it and undocking it.
I confirm still an issue in git 2.17.7-36-gc930f3a.
I found this lovely piece of SWT in Control.setZOrder() http://demo.spars.info/j/show.cgi?compo_id=145868&ref=1#METHOD3316 It calls XReconfigureWMWindow direcly, thus making gdks knowledge of the stacking order incorrect wrt what is on the Xserver and what SWT wants/needs. This happens even pre-csw, but with csw it is more problematic as this information is used to calculate window clip regions, leading to this bug.
Bug filed against swt: https://bugs.eclipse.org/bugs/show_bug.cgi?id=287307
I added a workaround mode that uses only native windows that can be enabled with GDK_NATIVE_WINDOWS. If this is enable then this bug disappears. I don't see any other way to reliably fix this, but it would be nice to fix future SWT releases to not need this.
I added gdk_window_restack which can be used to fix this. I verified this by writing a eclipse patch to use it and it fixed the issue. The patch is attached to the eclipse bug report. I consider this closed from the gtk+ side.