Keyboard Navigation for GNOME 2.0 (Draft)

Contents > GTK Widgets > Buttons
 
 

Buttons

In dialogs, when a control that doesn't accept keyboard input has focus (textfields, tree/list-derived widgets), suggest that all mnemonics in context are active whether or not the Alt key is pressed at the same time. In particular, in a simple message box, it should be possible to select any of the command buttons just by pressing the underlined character on any of those buttons, unmodified.

Status at 8-Jan-2002:  this doesn't seem to work, at least not in the message boxes in gtk-demo and testgtk.


 

Pushbutton (testgtk, "button box"; testgtk, "buttons"; gtk-demo, "button boxes")

 
Java
JButton
MSWin
CButton
Gtk1.2.9
GtkButton
Gtk Proposed
Bug #57309
Status at
8-Jan-2002

Patch pending review? NO

Navigate in - Tab Navigate in - Tab, or Alt+mnemonic if more than one control in context with same mnemonic. Navigate in - Tab, arrow keys.
Navigate in - Tab, or Alt+mnemonic if more than one control in context with same mnemonic.
OK
Navigate out - Tab, Shift+Tab (reverses direction)  Navigate out - Tab, Shift+Tab (reverses direction)  Navigate out - Tab, arrow keys 
Navigate out - Tab, Shift+Tab (reverses direction).
OK
Activate - Spacebar Activate - Spacebar, Enter or Alt+mnemonic (if mnemonic is unique). As MSWin
Activate - Spacebar, (also Enter if button is default), Alt+mnemonic (if mnemonic is unique).
OKish - does also Enter currently activate focused button, or does it activate default regardless?  Hard to tell, because currently focusing it also makes it the default-- not sure if we want this or not.  (See note below).
Enter (activates default button, the button doesn't require keyboard focus to occur)  Enter (or spacebar) activates the button that currently has keyboard focus. If a non-button control has focus, Enter (but not spacebar) activates the default button As MSWin Enter activates window's default button, regardless of which button currently has keyboard focus (if any). OKish -- currently works if Enter isn't trapped by focused widget.  This is correct, but too many widgets are still using Enter to activate them when they should only be using Spacebar, e.g. colour wells in Color Selector
Esc (activates the Cancel/Close button, the button doesn't require keyboard focus to occur) Esc (activates the Cancel/Close button, the button doesn't require keyboard focus to occur) As MSWin Activate Cancel Button (in dialog) - Esc (activates the Cancel-- but not Close-- button.  The button doesn't require keyboard focus to occur) OK


Currently (8/1/02), clicking a button also makes it the default if it wasn't before-- do we want this behaviour, or should the default not be changed?  I know this is how Windows does it, but I'm unclear why.  The GNOME UI Guidelines also advise against changing the default button during the lifetime of a dialog for accessibility reasons.



Toggle Button (testgtk, "toggle buttons")

 
Java
JToggleButton
MSWin
CButton
Gtk 1.2.9
GtkToggleButton
Gtk Proposed
Bug #53577
Status at
8-Jan-02

Patch pending review? NO

Navigate in - Tab What's the equivalent in Windows? Graphical checkbox/radiobutton? Navigate in - Tab, arrow keys Navigate in - Tab, Alt+mnemonic (if mnemonic not unique in context) OK
Navigate out - Tab, Shift+Tab (reverses direction) " Navigate out - Tab, Shift+Tab, arrow keys. Navigate out - Tab OK
Navigate within - Arrow keys " Navigate within - arrow keys, tab. (Neither method contains the focus within the group of buttons, though). Navigate within group- Arrow keys.  If user attempts to move focus past beginning or end of group, focus should not wrap around, but system warning beep should be played. TBD
Toggle on/off- Spacebar " Toggle on/off - Enter, Spacebar or Alt+mnemonic. Toggle state - Spacebar or Alt+mnemonic (if mnemonic is unique in context). 

(Not Enter, which should activate the window's default command button, if it has one).

Spacebar OK, but currently also implements Enter as well, which it shouldn't

 
 

Checkboxes (testgtk, "check buttons")

 
Java
JCheckBox
MSWin
CButton
Gtk 1.2.9
GtkCheckButton
Gtk Proposed
Bug #53577
Status at
1-Feb-02

Patch pending review? NO

Navigate in - Tab Navigate in - Tab, or Alt+mnemonic if mnemonic is non-unique. Navigate in - Tab or arrow keys. Navigate in - Tab, Alt+mnemonic (if mnemonic not unique in context) OK
Navigate out - Tab, Shift+Tab (reverses direction)  Navigate out - Tab, Shift+Tab (reverses direction) Navigate out - Tab , Shift+Tab, arrow keys Navigate out - Tab OK
Navigate within - Arrow Keys Navigate within - Arrow Keys Navigate within - Arrow keys, Tab. Neither contain the focus within the group of checkboxes, though. Navigate within group - Arrow keys.  If user attempts to move focus past beginning or end of group, focus should not wrap around, but system warning beep should be played. Broken; arrow keynav works but wraps around.
Toggle Check/Uncheck - Spacebar Toggle Check/Uncheck - Spacebar or Alt+unique mnemonic. Toggle Check/Uncheck- Spacebar, Enter or Alt+mnemonic.
Toggle state - Spacebar or Alt+mnemonic (if mnemonic is unique in context).
Spacebar OK, but  Enter also still toggles checkbox.... Enter should activate default button, if there is one.

 
 








Radio Buttons (testgtk, "radio buttons")

 
Java
JRadioButton
MSWin
CButton
Gtk 1.2.9
GtkRadioButton
Gtk Proposed
Bug #53577
Status at
1-Feb-02

Patch pending review? NO

Navigate in - Tab Navigate in - Tab, or Alt+mnemonic if mnemonic is non-unique. Navigate in - Tab or arrow keys. Navigate in - Tab, Alt+mnemonic (if mnemonic not unique in context) OK
Navigate out - Tab, Shift+Tab (reverses direction) Navigate out - Tab, Shift+Tab (reverses direction) Navigate out - Tab , Shift+Tab, arrow keys Navigate out - Tab OK
Navigate within - Arrow keys  Navigate within - Arrow keys Navigate within - Arrow keys, Tab. Neither contain the focus within the group of checkboxes, though. Navigate within group - Arrow keys.  If user attempts to move focus past beginning or end of group, focus should not wrap around, but system warning beep should be played. Broken; arrow keynav works but wraps around.
Toggle on/off- Spacebar Toggle on/off- Spacebar Toggle Check/Uncheck- Spacebar, Enter or Alt+mnemonic.
Select button - Spacebar or Alt+mnemonic (if mnemonic is unique in context). 
(Not Enter, which should activate the window's default command button, if it has one).
Spacebar OK, but Enter also still toggles radiobutton.... Enter should activate default button, if there is one.

Users · Developers · ViewCVS · FTP · Bugzilla · Software Map · Contact