textual
textual copied to clipboard
Better focus order
trafficstars
We have a fairly naive approach to the focus order in Textual.
Textual will go through widgets in the order they are defined within children.
What should probably occur is that the children are scanned in the order they appear on screen, i.e. left to right, then top to bottom.
We should probably also implement a switch to got from right to left for future rtl language support.
This can be implemented in App.focus_chain. I suspect we need to sort the focusable_children attribute in that property.
I would be happy to help with this.