Bug 574307 - [GTK3] Autohiding scrollbar does not trigger redraw
Summary: [GTK3] Autohiding scrollbar does not trigger redraw
Status: NEW
Alias: None
Product: Platform
Classification: Eclipse Project
Component: SWT (show other bugs)
Version: 4.21   Edit
Hardware: PC Linux
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Platform-SWT-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-06-18 08:10 EDT by Thomas Singer CLA
Modified: 2021-06-21 11:56 EDT (History)
2 users (show)

See Also:


Attachments
Snippet to reproduce (909 bytes, text/plain)
2021-06-18 08:27 EDT, Thomas Singer CLA
no flags Details
Screenshot initially (3.97 KB, image/png)
2021-06-18 08:33 EDT, Thomas Singer CLA
no flags Details
Screenshot after the scrollbar automatically hid (3.82 KB, image/png)
2021-06-18 08:36 EDT, Thomas Singer CLA
no flags Details
Screenshot with scrollbar (3.96 KB, image/png)
2021-06-18 08:38 EDT, Thomas Singer CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Thomas Singer CLA 2021-06-18 08:10:05 EDT
Please launch the attached snippet on Linux. It should show a right-aligned text and a vertical scrollbar. If there is an autohiding scrollbar, it can be shown by moving the mouse over the control. When moving it away, it will hide. Problem is, that the scrollbar is shown in front of the text, when hiding an empty area remains without redrawing.
Comment 1 Thomas Singer CLA 2021-06-18 08:27:02 EDT
Created attachment 286622 [details]
Snippet to reproduce
Comment 2 Thomas Singer CLA 2021-06-18 08:33:07 EDT
Created attachment 286623 [details]
Screenshot initially
Comment 3 Thomas Singer CLA 2021-06-18 08:36:42 EDT
Created attachment 286624 [details]
Screenshot after the scrollbar automatically hid
Comment 4 Thomas Singer CLA 2021-06-18 08:38:31 EDT
Created attachment 286625 [details]
Screenshot with scrollbar
Comment 5 Joel Majano CLA 2021-06-21 11:14:33 EDT
Reproduced the bug on my environment using the provided snippet, I will take a look at this. From a quick glance at the snippet, causing a redraw by means of resizing window brings back the string.
Comment 6 Joel Majano CLA 2021-06-21 11:56:02 EDT
The paint event that would redraw the part of the string that's cutoff is being discarded.

From this bug: https://bugs.eclipse.org/bugs/show_bug.cgi?id=546248

If I comment out the 'return 0' which discards Paint events, the snippet works as intended. Of course, this would undo the work the bug was trying to achieve so I'll have to look into this more.