| Summary: | [GTK3] Layout problem makes a group invisible | ||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| Product: | [Eclipse Project] Platform | Reporter: | Marc-André Laperle <malaperle> | ||||||||
| Component: | SWT | Assignee: | Platform-SWT-Inbox <platform-swt-inbox> | ||||||||
| Status: | CLOSED DUPLICATE | QA Contact: | |||||||||
| Severity: | normal | ||||||||||
| Priority: | P3 | CC: | akurtakov, bernd.hufmann, ericwill | ||||||||
| Version: | 4.4 | ||||||||||
| Target Milestone: | --- | ||||||||||
| Hardware: | PC | ||||||||||
| OS: | Linux | ||||||||||
| See Also: |
https://bugzilla.gnome.org/show_bug.cgi?id=662915 https://git.eclipse.org/r/#/c/55819/ |
||||||||||
| Whiteboard: | |||||||||||
| Bug Depends on: | |||||||||||
| Bug Blocks: | 441566, 474628 | ||||||||||
| Attachments: |
|
||||||||||
|
Description
Marc-André Laperle
Created attachment 243962 [details]
Code snippet
Created attachment 244016 [details]
Spelling preferences GTK3
It looks like the spelling preference page is affected by a similar issue.
I can also reproduce the issue on Fedora 20. (In reply to Marc-Andre Laperle from comment #3) > I can also reproduce the issue on Fedora 20. Can you reproduce the problem on fully uptodate Fedora 20? I was working on the problem but after last updates it magically doesn't happen anymore. I'll try tonight. If that's the case, it would be useful to know which commit fixed this so that it can be backported to Ubuntu LTS. I works now after the upgrades. Now if I open the spelling preference page and I resize the window horizontally, it shrinks to 1 pixel wide. I'm pretty sure this didn't happen before the updates since I did test the spelling preference page on Fedora too and I would've seen this. I also tried compiling both matching versions of glib (2.38.2) and gtk (3.10.9) on Ubuntu and I still can reproduce the bug *most* of the time. Maybe something else is at play. Running with GTK_DEBUG=geometry the output of the snippet is: gtk_widget_size_allocate: GtkWindow 0 0 200 200 gtk_widget_size_allocate: GtkWindow 0 0 200 200 gtk_widget_size_allocate: GtkWindow 0 0 200 200 gtk_widget_size_allocate: GtkWindow 0 0 1 1 gtk_widget_size_allocate: GtkBox 0 0 1200 675 gtk_widget_size_allocate: GtkScrolledWindow 0 0 1200 675 gtk_widget_size_allocate: SwtFixed 0 0 1200 675 gtk_widget_size_allocate: SwtFixed 0 0 0 0 gtk_widget_size_allocate: GtkFrame 0 0 56 22 gtk_widget_size_allocate: SwtFixed 1 21 54 1 gtk_widget_size_allocate: GtkLabel 4 0 48 21 gtk_widget_size_allocate: SwtFixed 0 0 1 1 gtk_widget_size_allocate: SwtFixed 0 0 0 0 gtk_widget_size_allocate: GtkFrame 0 0 2 2 gtk_widget_size_allocate: SwtFixed 1 1 1 1 gtk_widget_size_allocate: SwtFixed 0 0 1 1 gtk_widget_size_allocate: SwtFixed 0 0 1 1 gtk_widget_size_allocate: SwtFixed 0 0 1 1 gtk_widget_size_allocate: SwtFixed 0 0 1 1 gtk_widget_size_allocate: SwtFixed 0 0 1 1 gtk_widget_size_allocate: SwtFixed 5 5 0 86 gtk_widget_size_allocate: GtkFrame 0 0 1 86 gtk_widget_size_allocate: SwtFixed 1 1 1 84 (SWT:8404): Gtk-WARNING **: gtk_widget_size_allocate(): attempt to underallocate SwtFixed's child GtkFrame 0x7f6948455130. Allocation is 1x86, but minimum required size is 56x22. gtk_widget_size_allocate: GtkLabel 4 -32616 -5 32617 (SWT:8404): Gtk-CRITICAL **: gtk_widget_get_preferred_height_for_width: assertion 'width >= 0' failed (SWT:8404): Gtk-CRITICAL **: gtk_widget_get_preferred_height_for_width: assertion 'width >= 0' failed (SWT:8404): Gtk-WARNING **: gtk_widget_size_allocate(): attempt to underallocate GtkFrame's child GtkLabel 0x7f6948204480. Allocation is -5x32617, but minimum required size is 48x21. (SWT:8404): Gtk-WARNING **: gtk_widget_size_allocate(): attempt to allocate widget with width -5 and height 32617 gtk_widget_size_allocate: SwtFixed 5 96 0 0 gtk_widget_size_allocate: GtkFrame 0 0 2 2 gtk_widget_size_allocate: GtkWindow 0 0 1200 675 gtk_widget_size_allocate: GtkBox 0 0 1200 675 gtk_widget_size_allocate: GtkScrolledWindow 0 0 1200 675 gtk_widget_size_allocate: SwtFixed 0 0 1200 675 gtk_widget_size_allocate: SwtFixed 0 0 0 0 gtk_widget_size_allocate: SwtFixed 5 96 0 0 gtk_widget_size_allocate: GtkFrame 0 0 2 2 gtk_widget_size_allocate: GtkBox 0 0 1200 675 gtk_widget_size_allocate: GtkBox 0 0 1200 675 gtk_widget_size_allocate: SwtFixed 0 0 1200 675 gtk_widget_size_allocate: SwtFixed 5 96 0 0 gtk_widget_size_allocate: SwtFixed 0 0 1200 675 It looks like SwtFixed doesn't play well with GtkFrame label. Adding reference to gtk bug as it looks related. I haven't been able to reproduce the bug that is referenced. But I have managed to make a patch for GTK that fixes the SWT snippet. See attachment. I do not have a GTK-only code snippet to reproduce it though so the patch itself is not that useful yet. Created attachment 245623 [details]
gtk frame patch
Reproducible with current master on gtk3. Oddly, if I launch with SWT_GTK3=1 && GTK_DEBUG=geometry the issue doesn't occur. I've made a snippet using GTK only and opened a bug with the patch: https://bugzilla.gnome.org/show_bug.cgi?id=754976 Is this a duplicate of bug 470129? (In reply to Eric Williams from comment #14) > Is this a duplicate of bug 470129? Yes, at this point, we're fairly sure they are the same. *** This bug has been marked as a duplicate of bug 470129 *** |