Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 353910 - Scrollbar.getSelection() behavior differs greatly on Linux GTK
Summary: Scrollbar.getSelection() behavior differs greatly on Linux GTK
Status: RESOLVED WONTFIX
Alias: None
Product: Platform
Classification: Eclipse Project
Component: SWT (show other bugs)
Version: 3.7   Edit
Hardware: PC Linux-GTK
: P3 major (vote)
Target Milestone: ---   Edit
Assignee: Platform-SWT-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-08-04 11:39 EDT by Markus Tiede CLA
Modified: 2011-08-04 11:54 EDT (History)
1 user (show)

See Also:


Attachments
Fedora 8 GTK 32bit behavior (125.09 KB, image/png)
2011-08-04 11:39 EDT, Markus Tiede CLA
no flags Details
Windows 2008 32bit behavior (22.67 KB, image/png)
2011-08-04 11:39 EDT, Markus Tiede CLA
no flags Details
Mac OS X 10.6.8 64bit Cocoa behavior (112.00 KB, image/png)
2011-08-04 11:40 EDT, Markus Tiede CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Markus Tiede CLA 2011-08-04 11:39:44 EDT
Created attachment 200931 [details]
Fedora 8 GTK 32bit behavior

The SWT API behavior differs greatly when running on Linux GTK:

Calling getSelection() on a Scrollbar, e.g. a List's getVerticalBar(), returns differently scaled selections for the current Scrollbar state, as soon as the Scrollable is scrolled to display a list item.

See the attached screenshots for further information: I used Mac OS X 10.6 Cocoa
and Windows 2008 32bit as reference platforms to show the "normal" behavior. In
addition to that I started the same application on Fedora 8 GTK 32bit.

I "produced" the output as follows:
 - launch the snippet application, re-size it to show only e.g. 4 items, place
it to the top (to avoid too big screen coordinates - easier to read and
understand ;) )
 - select the first item 0 and successively select item n + 1 and so on
 - as soon as the scrolling starts (In my case item 3) the behavior differs on
Linux GTK
Comment 1 Markus Tiede CLA 2011-08-04 11:39:57 EDT
Created attachment 200932 [details]
Windows 2008 32bit behavior
Comment 2 Markus Tiede CLA 2011-08-04 11:40:13 EDT
Created attachment 200933 [details]
Mac OS X 10.6.8 64bit Cocoa behavior
Comment 3 Felipe Heidrich CLA 2011-08-04 11:54:07 EDT
This is not a bug.
The meaning of selection value depends in the native control implementation.
On GTK, the GTK developer chose to a pixel based scrollbar.
On Win32 and Cocoa the scrollbar is item based.

closing as wont fix.