Bug 427480 - [GTK3] [GTK3.10] Trees/Tables display issues when expanded elements require Scroll
Summary: [GTK3] [GTK3.10] Trees/Tables display issues when expanded elements require S...
Status: RESOLVED FIXED
Alias: None
Product: Platform
Classification: Eclipse Project
Component: SWT (show other bugs)
Version: 4.4   Edit
Hardware: PC Linux
: P3 major with 1 vote (vote)
Target Milestone: ---   Edit
Assignee: Platform-SWT-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
: 427487 (view as bug list)
Depends on:
Blocks:
 
Reported: 2014-02-05 10:38 EST by Mickael Istria CLA
Modified: 2015-05-08 16:45 EDT (History)
9 users (show)

See Also:
akurtakov: review+


Attachments
Small SWT + Jface program (1.22 KB, text/plain)
2015-03-02 18:45 EST, Marc-André Laperle CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Mickael Istria CLA 2014-02-05 10:38:10 EST
I have the following issue with Luna M5 on GTK3, in any circumstances (can be views, wizards...).
When a TreeItem gets expended so that the Tree is bigger than its container and requires scroll, display becomes crazy so that:
* Things get drawn out of the Tree parent
* The TreeItem are not displayed any more inside the Tree widget (blank, see only expand buttons).
Comment 1 Mickael Istria CLA 2014-02-05 11:34:58 EST
This is to be still happening with build I20140204-0800
In order to reproduce it, the conditions are:
* Tree must fit inside its parent when item are collapsed
* You can expand items without any issue while they still fit in the parent
* Whenever you expand an item which make the Tree bigger that the parent and the parent need to add Scrollbars, you see the issue
Comment 2 Mickael Istria CLA 2014-04-23 09:11:50 EDT
This may be a consequence of bug 427511
Comment 3 Snjezana Peco CLA 2014-04-29 16:16:50 EDT
GTK >= 3.10 erases a tree area when scrolling the tree. I suppose the issue has been caused by the changes in the scrolling code described in http://blogs.gnome.org/alexl/2013/11/04/the-modern-gtk-drawing-model/

I have made a temporary fix that forces native painting.

The patch: https://git.eclipse.org/r/#/c/25758
Requirement: https://git.eclipse.org/r/#/c/25668
Comment 4 Alexander Kurtakov CLA 2014-05-09 07:23:42 EDT
Definetely improves the current situation significantly. Let's push it.
Comment 5 Alexander Kurtakov CLA 2014-05-09 07:26:03 EDT
Arun, as there is already the review would you please push if you agree with it?
Comment 6 Arun Thondapu CLA 2014-05-09 12:14:23 EDT
(In reply to Alexander Kurtakov from comment #5)
> Arun, as there is already the review would you please push if you agree with
> it?

Link to the git commit - http://git.eclipse.org/c/platform/eclipse.platform.swt.git/commit/?id=cc78900f837ae57b63ebd7ad5fb7e94c20673c8f
Comment 7 Marc-André Laperle CLA 2014-05-13 13:38:24 EDT
Snjezana, I think the same work around needs to be applied to Table. I see a very similar issue when doing Open Type (Ctrl+shift+T), doing content assist, etc. As soon as there is a scollbar necessary, the content disappears.

Patch:
https://git.eclipse.org/r/26471
Comment 8 Snjezana Peco CLA 2014-05-13 14:23:18 EDT
(In reply to Marc-Andre Laperle from comment #7)
> Snjezana, I think the same work around needs to be applied to Table. I see a
> very similar issue when doing Open Type (Ctrl+shift+T), doing content
> assist, etc. As soon as there is a scollbar necessary, the content
> disappears.
> 
> Patch:
> https://git.eclipse.org/r/26471

I can reproduce the issue you are talking about.
The patch fixes it.
Comment 9 Alexander Kurtakov CLA 2014-05-14 02:58:35 EDT
Review +1 for Marc's patch too (aka the flag still true) as stated in gerrit too.
Comment 10 Arun Thondapu CLA 2014-05-14 05:58:13 EDT
(In reply to Marc-Andre Laperle from comment #7)
> Snjezana, I think the same work around needs to be applied to Table. I see a
> very similar issue when doing Open Type (Ctrl+shift+T), doing content
> assist, etc. As soon as there is a scollbar necessary, the content
> disappears.
> 
> Patch:
> https://git.eclipse.org/r/26471

Pushed - http://git.eclipse.org/c/platform/eclipse.platform.swt.git/commit/?id=2958e16615b4d5e0811266d64a0c720c35a392bf
Comment 11 Marc-André Laperle CLA 2014-05-26 13:41:01 EDT
*** Bug 427487 has been marked as a duplicate of this bug. ***
Comment 12 Snjezana Peco CLA 2014-07-16 14:11:47 EDT
Alexander, Arun,

I think we can mark this bug as resolved.
Comment 13 Alexander Kurtakov CLA 2014-07-22 09:23:35 EDT
Marking as fixed now.
Comment 14 Marc-André Laperle CLA 2015-03-02 18:45:14 EST
Created attachment 251230 [details]
Small SWT + Jface program

This snippet reproduces the bug, after reverting http://git.eclipse.org/c/platform/eclipse.platform.swt.git/commit/?id=2958e16615b4d5e0811266d64a0c720c35a392bf
Comment 15 Jonny Lamb CLA 2015-03-06 08:58:18 EST
(In reply to Marc-Andre Laperle from comment #14)
> Created attachment 251230 [details]
> Small SWT + Jface program
> 
> This snippet reproduces the bug, after reverting
> http://git.eclipse.org/c/platform/eclipse.platform.swt.git/commit/
> ?id=2958e16615b4d5e0811266d64a0c720c35a392bf

(In order to fix bug #446075,) I've been looking at this bug and how it was fixed. As a little test I stopped overriding the GtkCellRendererClass.render function (in Display.rendererClassInitProc) and let the individual GtkCellRenderers render themselves... and everything displays correctly.

I had a look around lots of Eclipse dialogs and couldn't see any Table/Tree out of place. Looking back at the history, this class function was overridden a long time ago with little clue left as to why. Maybe I'm missing something important here and it would break some common use case, but could it be removed?
Comment 16 Jonny Lamb CLA 2015-03-06 15:42:34 EST
(In reply to Jonny Lamb from comment #15)
> Maybe I'm missing something important here and it would break some
> common use case,

fwiw, bold text doesn't seem to work.
Comment 17 ArronM CLA 2015-05-08 16:45:36 EDT
I believe this caused Bug 461251