• Post Reply Bookmark Topic Watch Topic
  • New Topic

Swing Tabbing Order  RSS feed

 
arunkumar sundar
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all,
Tabbing order in the panel is not as expected.I am using a null layout manager.I thought the order of the focus traversal depends upon the order in which the components are added.But it behaves abnormally.I dont want to change the layout manager hereafter(So many panels have this problem).Is there any way i can change the tabbing order as expected.

Thanks,

Arunkumar
 
Frank Ertl
Ranch Hand
Posts: 59
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I think you mean the way the focus changes by pressing the "tab"-key, right?
Try the setNextFocusableComponent()-Method in JComponent (All Swing -components inherit from JComponent, so it will be available for all your components).
 
arunkumar sundar
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi

Thanks Frank Ertl.But it is not possible for me to now give the nextfocusable component to each and every component.there are so many components in the panel and so many panels!.Is there any other way to sort this out.

Thanks for all

Arunkumar
 
Murugan Patham
Greenhorn
Posts: 20
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator


Create CrsrTrvlMeth Class with the cursor Travel method you want and pass the array of all traversable components in order.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!