Bug 577831 - [GTK4] Tab TraverseEvents not working
Summary: [GTK4] Tab TraverseEvents not working
Status: VERIFIED FIXED
Alias: None
Product: Platform
Classification: Eclipse Project
Component: SWT (show other bugs)
Version: 4.23   Edit
Hardware: PC Linux
: P3 normal (vote)
Target Milestone: 4.24 M1   Edit
Assignee: Joel Majano CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on: 578203
Blocks: 540385 567257
  Show dependency tree
 
Reported: 2021-12-15 13:06 EST by Joel Majano CLA
Modified: 2022-04-06 13:56 EDT (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Joel Majano CLA 2021-12-15 13:06:23 EST
In a simple snippet that creates a TraverseListener, with a print statement if one is detected, I observe that nothing is printed in GTK4. In GTK3 this works with no issues but in GTK 4 I can see that no TraverseEvent is created.
Comment 1 Joel Majano CLA 2022-01-10 10:33:28 EST
It appears that there is no event being emitted when TAB is pressed, or the method used to emit the key press is not being captured by SWT. A relevant line from the GTK4 docs that was not present in the GTK3 docs: "GTK reserves the Tab key to move the focus to the next location, and Shift-Tab to move it back to the previous one", maybe this causes issues?

Also a relevant bug that is currently still open in the Gnome issues tracker: https://gitlab.gnome.org/GNOME/gtk/-/issues/3544. 

I will continue investigating, but this might require a native snippet to check how TAB is handled in the text widget.
Comment 2 Joel Majano CLA 2022-03-17 10:28:10 EDT
With the patches to bugs 579299 and 579056, tab traverse events are now working!

Tested using Snippet 241 to verify it works as expected in GTK4.