|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.google.code.validationframework.swing.resulthandler.bool.TabIconBooleanFeedback
public class TabIconBooleanFeedback
Result handler showing an icon in the tab of a specific index inside a tabbed pane.
Note that the tab to which it
is attached must already be present in the tabbed pane. This restriction will be lifted out in the
future.
Finally, note that any icon set using the method JTabbedPane.setIconAt(int, Icon) will not be
shown.
| Field Summary | |
|---|---|
static int |
DEFAULT_ICON_POSITION
Default icon position with respect to the tab title. |
static int |
DEFAULT_ICON_TEXT_GAP
Default spacing between the icon and the tab title. |
static Icon |
DEFAULT_INVALID_ICON
Default icon to represent invalid results. |
static Icon |
DEFAULT_VALID_ICON
Default icon to represent valid results. |
| Constructor Summary | |
|---|---|
TabIconBooleanFeedback(JTabbedPane tabbedPane,
int tabIndex)
Constructor specifying the tabbed pane and the index of the tab to show the decoration on. The default valid icon and default invalid icons will be used. |
|
TabIconBooleanFeedback(JTabbedPane tabbedPane,
int tabIndex,
Icon invalidIcon,
String invalidText)
Constructor specifying the tabbed pane, the index of the tab to show the decoration on, the invalid icon and the tooltip text to be shown for the invalid icon. No valid icon will be shown. |
|
TabIconBooleanFeedback(JTabbedPane tabbedPane,
int tabIndex,
Icon validIcon,
String validText,
Icon invalidIcon,
String invalidText)
Constructor specifying the tabbed pane and the index of the tab to show the decoration on, as well as the icon and tooltip text representing valid and invalid results. |
|
TabIconBooleanFeedback(JTabbedPane tabbedPane,
int tabIndex,
Icon validIcon,
String validText,
Icon invalidIcon,
String invalidText,
int iconPosition,
int iconTextGap)
Constructor specifying the tabbed pane and the index of the tab to show the decoration on, as well as the icon and tooltip text representing valid and invalid results, and the position and spacing of the decoration icon with respect to the tab title. |
|
TabIconBooleanFeedback(JTabbedPane tabbedPane,
int tabIndex,
String invalidText)
Constructor specifying the tabbed pane, the index of the tab to show the decoration on, and the tooltip text to be shown for the invalid icon. No valid icon will be shown, and the default invalid icon will be used. |
|
| Method Summary | |
|---|---|
void |
dispose()
|
void |
handleResult(Boolean result)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final Icon DEFAULT_VALID_ICON
public static final Icon DEFAULT_INVALID_ICON
public static final int DEFAULT_ICON_POSITION
public static final int DEFAULT_ICON_TEXT_GAP
| Constructor Detail |
|---|
public TabIconBooleanFeedback(JTabbedPane tabbedPane,
int tabIndex)
tabbedPane - Tabbed pane to show the icon tip feedback on.tabIndex - Index of the tab to show the icon tip feedback on.
public TabIconBooleanFeedback(JTabbedPane tabbedPane,
int tabIndex,
String invalidText)
tabbedPane - Tabbed pane to show the icon tip feedback on.tabIndex - Index of the tab to show the icon tip feedback on.invalidText - Tooltip text to be shown for the invalid icon, or null.
public TabIconBooleanFeedback(JTabbedPane tabbedPane,
int tabIndex,
Icon invalidIcon,
String invalidText)
tabbedPane - Tabbed pane to show the icon tip feedback on.tabIndex - Index of the tab to show the icon tip feedback on.invalidIcon - Icon representing invalid results, or null.invalidText - Tooltip text to be shown for the invalid icon, or null.
public TabIconBooleanFeedback(JTabbedPane tabbedPane,
int tabIndex,
Icon validIcon,
String validText,
Icon invalidIcon,
String invalidText)
tabbedPane - Tabbed pane to show the icon tip feedback on.tabIndex - Index of the tab to show the icon tip feedback on.validIcon - Icon representing valid results, or null.validText - Tooltip text on the valid icon explaining the valid results, or null.invalidIcon - Icon representing invalid results, or null.invalidText - Tooltip text on the invalid icon explaining the invalid results, or null.
public TabIconBooleanFeedback(JTabbedPane tabbedPane,
int tabIndex,
Icon validIcon,
String validText,
Icon invalidIcon,
String invalidText,
int iconPosition,
int iconTextGap)
tabbedPane - Tabbed pane to show the icon tip feedback on.tabIndex - Index of the tab to show the icon tip feedback on.validIcon - Icon representing valid results, or null.validText - Tooltip text on the valid icon explaining the valid results, or null.invalidIcon - Icon representing invalid results, or null.invalidText - Tooltip text on the invalid icon explaining the invalid results, or null.iconPosition - Position of the icon with respect to the tab title.SwingConstants.LEADING, SwingConstants.LEFT, SwingConstants.TRAILING or
SwingConstants.RIGHT.iconTextGap - Spacing between the icon and the text.| Method Detail |
|---|
public void handleResult(Boolean result)
handleResult in interface com.google.code.validationframework.api.resulthandler.ResultHandler<Boolean>ResultHandler.handleResult(Object)public void dispose()
dispose in interface com.google.code.validationframework.api.common.DisposableDisposable.dispose()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||