Bug 14131 - Unexpected tab traversal order
Summary: Unexpected tab traversal order
Status: CLOSED WONTFIX
Alias: None
Product: Platform
Classification: Eclipse Project
Component: SWT (show other bugs)
Version: 2.0   Edit
Hardware: PC Linux-Motif
: P2 major (vote)
Target Milestone: ---   Edit
Assignee: Grant Gayed CLA
QA Contact:
URL:
Whiteboard:
Keywords: accessibility
Depends on:
Blocks:
 
Reported: 2002-04-18 12:48 EDT by Naomi Miyamoto CLA
Modified: 2002-04-19 02:02 EDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Naomi Miyamoto CLA 2002-04-18 12:48:56 EDT
Env. : Red Hat 7.2

Tab traversal order seems wrong in modal dialog which extends jface.dialog.

Here is a sample class.

public class MyDialog extends org.eclipse.jface.dialogs.Dialog {
    Text fileText;
    Button browseButton;

    protected Control createDialogArea(Composite parent) {
        Composite composite = new Composite(parent, SWT.NONE);
        GridLayout layout = new GridLayout();
        layout.numColumns = 3;
        composite.setLayout(layout);
        composite.setLayoutData(new GridData(GridData.FILL_BOTH));
        Label label = new Label(composite, SWT.NONE);
        label.setText("File:");
        fileText = new Text(composite, SWT.BORDER);
        browseButton = new Button(composite, SWT.PUSH);
        browseButton.setText("Browse...");
        fileText.setFocus();
        return composite;
    }
}

Tab traversal order in Windows is;
    (1) Text widget
    (2) [Browse...] Button widget
    (3) [OK] Button widget
    (4) [Cancel] Button widget
    (5) Text widget

Tab traversal order in Linux is;
    (1) Text widget
    (2) [OK] Button widget
    (3) [Browse...] Button widget
    (4) Text widget

Expected tab traversal order in Linux is;
    (1) Text widget
    (2) [Browse...] Button widget
    (3) [OK] Button widget
    (4) Text widget
Comment 1 Nick Edgar CLA 2002-04-18 14:04:19 EDT
Tab order should be consistent between platforms.
org.eclipse.jface.Dialog creates the OK and Cancel buttons after calling 
createDialogArea, but other than that it has no impact on the tab order.
Comment 2 Mike Wilson CLA 2002-04-18 14:18:37 EDT
What about the fact that focus never goes to the Cancel button on linux?
Comment 3 Steve Northover CLA 2002-04-18 17:55:18 EDT
Buttons on Linux are tab items and are traversed using the arrow keys.  Try the 
native file dialog to see this behavior.  Buttons on Windows are tab groups.  
This is the behavior you expected to see on Linux but this goes against the 
platform look and feel.
Comment 4 Naomi Miyamoto CLA 2002-04-19 02:02:24 EDT
I see. Thank you.