After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 778811 - Enter submenus when activating their parent item
Enter submenus when activating their parent item
Status: RESOLVED FIXED
Product: gtk+
Classification: Platform
Component: Widget: GtkMenu
3.22.x
Other All
: Normal normal
: ---
Assigned To: gtk-bugs
gtk-bugs
Depends on:
Blocks:
 
 
Reported: 2017-02-17 08:56 UTC by Colomban Wendling
Modified: 2017-10-05 09:52 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Enter submenus when activating their parent item (1.24 KB, patch)
2017-02-17 08:56 UTC, Colomban Wendling
committed Details | Review

Description Colomban Wendling 2017-02-17 08:56:50 UTC
Created attachment 346043 [details] [review]
Enter submenus when activating their parent item

Enter submenus when activating their parent item (e.g. with Return)

This gives consistent behavior with e.g. Qt, Mozilla's suites and LibreOffice (with non-truly native backends like "gen" and "gtk", but unlike "gtk2" and "gtk3" ones that probably use true GTK menus).

This behavior is expected by at least some accessibility users, and it seems best to behave like other common applications and toolkits in this area.  There should be no issue in doing so either for current users, as it only enters the submenu instead of not doing anything.
Comment 1 Alex ARNAUD 2017-02-17 10:21:56 UTC
Hello all,

Thanks Colomban for the work on this, it's important for blind people that have no representation of the screen.
It's not consistent for a blind person to press right arrow or left arrow to enter inside a submenu because it's only dependent to the position of the menu on the screen. If the menu is on the right side of the screen you need to press left arrow and if the menu is on the left side of the screen you need to press right arrow but a blind user hasn't this information so enter will solve this important issue.


Another issue that should be solve is the ability to press "escape" to leave a submenu for the same accessibility reason. 
Could GTK developers tell us if they could accept a change of the escape behavior to make GTK+ more user-friendly for blind people ?
If yes, Colomban could work on this also :).


Thanks in advance for reviewing the patch.


Best regards.
Comment 2 Alex ARNAUD 2017-02-21 14:46:15 UTC
(In reply to Alex ARNAUD from comment #1)
> Another issue that should be solve is the ability to press "escape" to leave
> a submenu for the same accessibility reason. 
> Could GTK developers tell us if they could accept a change of the escape
> behavior to make GTK+ more user-friendly for blind people ?

After a discussion with blinds people It seems that only enter is needed, not escape. Sorry for the noise.

Best regards.
Comment 3 Colomban Wendling 2017-03-07 09:11:25 UTC
ping?
Comment 4 Daniel Boles 2017-08-28 00:33:32 UTC
(In reply to Alex ARNAUD from comment #1)
> Thanks Colomban for the work on this, it's important for blind people that
> have no representation of the screen.
> It's not consistent for a blind person to press right arrow or left arrow to
> enter inside a submenu because it's only dependent to the position of the
> menu on the screen. [...] but a blind user hasn't this information

That's a convincing reason to me. Let's ping some more!
Comment 5 Samuel Thibault 2017-09-19 17:08:45 UTC
Hello,

Is there any question with this change proposal?

To summarize, all it does is change the behavior when pressing enter while the focus is on a menu entry for a submenu.

Currently it only opens the submenu, that is not very useful, and not consistent with the behavior of other toolkits: to enter the submenu one has to press the right arrow, which does not make sense for a blind user.

With the change, pressing enter will open the submenu and place the focus on the first item of the submenu. It is more useful and way more logical for blind users. Is there really a reason for not doing this?

Samuel
Comment 6 Daniel Boles 2017-10-04 21:05:29 UTC
I'll probably just take a gamble and say this is good, and put it in.

Before that, though - it did make me wonder, is there no equivalent a11y-friendly way to go back to the parent menu of the submenu you opened? Esc just closes, and all I found so far was pressing the opposite arrow we currently use to open it, which obviously shows the same problem as this bug.
Comment 7 Daniel Boles 2017-10-04 22:03:31 UTC
Attachment 346043 [details] pushed as 367ff36 - Enter submenus when activating their parent item
Comment 8 Jean-Philippe MENGUAL 2017-10-05 09:37:37 UTC
Hi Daniel,

FOr most end-users when they want to close submenu the simplest is indeed to escape and restart the process from the beginning. So it should fit.

However, if we would like to be really perfect, we should have imagined the capability to exit the submenu where we enter with Enter via Escape key. It would do:
- enter in a submenu via Enter or right key 
- exit via escape or left arrow

Maybe we could add a new patch for it, but it will be the next step, I think it does not prevent from applying the current patch.

Best regards
Comment 9 Daniel Boles 2017-10-05 09:46:10 UTC
(In reply to Jean-Philippe MENGUAL from comment #8)
> However, if we would like to be really perfect, we should have imagined the
> capability to exit the submenu where we enter with Enter via Escape key. It
> would do:
> - enter in a submenu via Enter or right key 
> - exit via escape or left arrow

It's tricky as it *is* good to have a key to close the entire menu tree, so I don't know if it'd be ideal to change its existing behaviour. Then again, it's not easy to think of a nice additional shortcut that could be added to only close the current submenu.


> Maybe we could add a new patch for it, but it will be the next step, I think
> it does not prevent from applying the current patch.

Sure, please open a bug for closing if you'd like.

In contrast to that, the patch for Enter/Space/etc seems only to be good for everyone by making navigation more useful, so I pushed it. Looking forward to using it in my own apps!
Comment 10 Jean-Philippe MENGUAL 2017-10-05 09:52:36 UTC
You are right, that is why I did not think of requesting such a key to exit. Usually the process is escape to close submenu, escape again to close the menu. But probably not easy to implement here.

regards,