public interface ITabbedPane extends IBorderPanel
JTabbedPane.
Supports lazily created tab components which is very useful because only non-lazy tabs are created on first show which might be significantly faster, also if a user never clicks on a tab, it is never created.
Supports hiding tabs in a way that hidden tabs (both tab title and content components) remain in the component tree (which means bounded
ISettingChangeListeners will properly be removed if ISettingsGui.removeAllBoundedScl(JComponent) is called on a parent.
IGuiFactory.newTabbedPane()| Modifier and Type | Method and Description |
|---|---|
void |
addTab(java.lang.String title,
IRIcon ricon,
javax.swing.JComponent tab,
boolean addTabMnemonic)
Adds a new non-closeable tab.
|
void |
addTab(java.lang.String title,
IRIcon ricon,
javax.swing.JComponent tab,
boolean addTabMnemonic,
boolean closeable,
java.lang.Runnable beforeCloseTask)
Adds a new tab.
|
void |
addTab(java.lang.String title,
IRIcon ricon,
Producer<javax.swing.JComponent> tabProducer,
boolean addTabMnemonic)
Adds a new, lazily created non-closeable tab.
|
void |
addTab(java.lang.String title,
IRIcon ricon,
Producer<javax.swing.JComponent> tabProducer,
boolean addTabMnemonic,
boolean closeable,
java.lang.Runnable beforeCloseTask)
Adds a new, lazily created tab.
|
IBorderPanel |
asBorderPanel()
Casts this instance to
IBorderPanel. |
int |
getHiddenTabCount()
Returns the hidden tab count.
|
int |
getTabCount()
Returns the visible tab count.
|
javax.swing.JTabbedPane |
getWrappedTabbedPane()
Returns the wrapped
JTabbedPane. |
void |
hideTab(int idx)
Hides the tab at the specified index.
|
void |
unhideTab(int hiddenIdx,
int toIdx)
Unhides a tab specified by its hidden index, and inserts it to the specified index.
|
IBorderPanel asBorderPanel()
IBorderPanel.this as a IBorderPaneljavax.swing.JTabbedPane getWrappedTabbedPane()
JTabbedPane.JTabbedPanevoid addTab(java.lang.String title,
IRIcon ricon,
Producer<javax.swing.JComponent> tabProducer,
boolean addTabMnemonic)
title - title of the tabricon - ricon of the tabtabProducer - tab component produceraddTabMnemonic - tells if a tab mnemonic has to be addedvoid addTab(java.lang.String title,
IRIcon ricon,
Producer<javax.swing.JComponent> tabProducer,
boolean addTabMnemonic,
boolean closeable,
java.lang.Runnable beforeCloseTask)
title - title of the tabricon - ricon of the tabtabProducer - tab component produceraddTabMnemonic - tells if a tab mnemonic has to be addedcloseable - tells if the tab is closeable (adds a close icon if it is)beforeCloseTask - optional task to be executed before close in case of closeable tabsvoid addTab(java.lang.String title,
IRIcon ricon,
javax.swing.JComponent tab,
boolean addTabMnemonic)
title - title of the tabricon - ricon of the tabtab - tab component to be addedaddTabMnemonic - tells if a tab mnemonic has to be addedvoid addTab(java.lang.String title,
IRIcon ricon,
javax.swing.JComponent tab,
boolean addTabMnemonic,
boolean closeable,
java.lang.Runnable beforeCloseTask)
title - title of the tabricon - ricon of the tabtab - tab component to be addedaddTabMnemonic - tells if a tab mnemonic has to be addedcloseable - tells if the tab is closeable (adds a close icon if it is)beforeCloseTask - optional task to be executed before close in case of closeable tabsvoid hideTab(int idx)
idx - index of the tab to be hiddenvoid unhideTab(int hiddenIdx,
int toIdx)
hiddenIdx - index of the tab to be unhidden, amongst the hidden tabstoIdx - index to show the tab atint getTabCount()
int getHiddenTabCount()
This API documentation is public and is intended for / allowed to be used by anyone.
Scelight home page: https://sites.google.com/site/scelight/
Scelight is a trademark of András Belicza. Copyright © András Belicza, 2013-2015. All rights reserved.