Granny's Programming Pearls
"inside of every large program is a small program struggling to get out"
JavaRanch.com/granny.jsp
Win a copy of The Java Performance Companion this week in the Performance forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

HBox, ChoiceBox and tab-order weirdness

 
iain coghill
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Some unexpected tab-order oddities have cropped up when I use javafx.scene.control.ChoiceBox within an HBox.

Try the following:



What tab-order would you expect? I expected the first TextBox to have initial focus and on pressing <TAB> to cycle through the ChoiceBox then last two TextBox controls in order. What I get is rather different. The ChoiceBox gets initial focus and pressing <TAB> jumps back to first TextBox, then forward to the last two TextBoxs in order. Adding more ChoiceBox controls just adds to the weirdness, it seems ChoiceBox gets first preference in tab-order within the HBox, regardless of actual order. Replace HBox with VBox in the above code and things work in the manner you would expect

Anybody else experienced similar? Any way to manually assign tab-order or otherwise sidestep the issue?
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic