A DESCRIPTION OF THE REQUEST :
Tabs aren't Labeleds and so they don't have mnemonics
However giving them a Mnemonic, would be a worth-while addition.
If Tab can't extend Labeled, can it have similar mnemonic methods anyway?
JUSTIFICATION :
Being able to switch to *specific* tabs using mnemonics would make for a more-efficient UX.
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
One should be able to switch to a specific tab using a Mnemonic.
ACTUAL -
One can only traverse tabs in linear order, using CTRL + TAB
---------- BEGIN SOURCE ----------
Tab firstTab = new Tab("_First");
Tab secondTab = new Tab("_Second");
Tab thirdTab = new Tab("_Third");
TabPane tabPane = new TabPane(firstTab, secondTab, thirdTab);
---------- END SOURCE ----------
CUSTOMER SUBMITTED WORKAROUND :
I tried to .lookup Tab's label
firstTab.lookup(".label");
and add a Mnemonic directly to the label,
label.setMnemonicParsing(true);
label.setText("_First");
but this does not work because Tab's `.lookup()` method is package private and only looks up things in the Tab's content.
Tabs aren't Labeleds and so they don't have mnemonics
However giving them a Mnemonic, would be a worth-while addition.
If Tab can't extend Labeled, can it have similar mnemonic methods anyway?
JUSTIFICATION :
Being able to switch to *specific* tabs using mnemonics would make for a more-efficient UX.
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
One should be able to switch to a specific tab using a Mnemonic.
ACTUAL -
One can only traverse tabs in linear order, using CTRL + TAB
---------- BEGIN SOURCE ----------
Tab firstTab = new Tab("_First");
Tab secondTab = new Tab("_Second");
Tab thirdTab = new Tab("_Third");
TabPane tabPane = new TabPane(firstTab, secondTab, thirdTab);
---------- END SOURCE ----------
CUSTOMER SUBMITTED WORKAROUND :
I tried to .lookup Tab's label
firstTab.lookup(".label");
and add a Mnemonic directly to the label,
label.setMnemonicParsing(true);
label.setText("_First");
but this does not work because Tab's `.lookup()` method is package private and only looks up things in the Tab's content.