Setting Tab-Order / Reorder Components

Swing Designer allows you to quickly create the frames, panels, dialogs, applets and other UI elements that comprise Java Swing applications.

Moderators: Konstantin.Scheglov, gnebling, Alexander.Mitin, jwren, Eric Clayberg

Setting Tab-Order / Reorder Components

Postby lophiomys » Wed Aug 24, 2005 12:41 am

Is there a visual editor for setting the tab order in Swing Desginer?

In the SWT forum I found a "Reorder Components"-window,
which I cannot find for Swing/JGoodies Form Layout or Spring Layout?

Moving the compontes in the control tree, moves the controls to akward
positions/cells in JG Form Layout.

Kind Regards,
Lophiomys
using 4.1.1 build 2005/8/21
lophiomys
 
Posts: 8
Joined: Mon Mar 07, 2005 3:21 am

Re: Setting Tab-Order / Reorder Components

Postby Eric Clayberg » Wed Aug 24, 2005 1:50 pm

lophiomys wrote:Is there a visual editor for setting the tab order in Swing Desginer?

No. Swing has its own peculiar notions of tab order. In order to override them, you need to create a subclass of FocusTraversalPolicy and use setFocusTraversalPolicy() to apply it to the container.

We might be able to provode graphical support for that at some point in the future.
Eric Clayberg
Software Engineering Manager
Google
http://code.google.com/webtoolkit/download.html

Author: "Eclipse Plug-ins"
http://www.qualityeclipse.com
Eric Clayberg
Moderator
 
Posts: 4503
Joined: Tue Sep 30, 2003 6:39 am
Location: Boston, MA USA

Re: Setting Tab-Order / Reorder Components

Postby Eric Clayberg » Tue Sep 06, 2005 5:01 pm

Eric Clayberg wrote:In order to override them, you need to create a subclass of FocusTraversalPolicy and use setFocusTraversalPolicy() to apply it to the container. We might be able to provide graphical support for that at some point in the future.

The latest v4.1.1 build now provides the ability to set the tab order for Swing components by setting the focusTraversalPolicy property.

Image

As a convenience, you can also right-click on a container and select the Set tab order command.

Image
Eric Clayberg
Software Engineering Manager
Google
http://code.google.com/webtoolkit/download.html

Author: "Eclipse Plug-ins"
http://www.qualityeclipse.com
Eric Clayberg
Moderator
 
Posts: 4503
Joined: Tue Sep 30, 2003 6:39 am
Location: Boston, MA USA

Postby lophiomys » Tue Sep 06, 2005 11:50 pm

Thank you very much for implementing it so quickly.

Cheers,
Lophiomys
lophiomys
 
Posts: 8
Joined: Mon Mar 07, 2005 3:21 am


Return to Swing Designer

Who is online

Users browsing this forum: No registered users and 1 guest