|
Components |
|
| |||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
com.sas.visuals.TabButton
public class TabButton
TabButton is a subclass of ToggleButton that implements the TabButtonInterface.
This allows it to be used in the TabBar. The TabButtonInterface has an orientation property.
On the TabButton, this changes the display of the border. The TabButton uses a special
border and buttonModel. The border is the TabBorder and the buttonModel is the TabButtonModel.
Notes:
BaseButton
,
ToggleButton
,
TabBorder
,
TabButtonModel
,
TabButtonInterface
,
Serialized FormField Summary | |
---|---|
static int |
NONE
NONE orientation value |
protected int |
orientation
int value representing orientation of the TabButton |
static java.lang.String |
RB_KEY
|
Fields inherited from class com.sas.visuals.ToggleButton |
---|
contentShift, label, textBounds |
Fields inherited from class com.sas.visuals.BaseButton |
---|
actionCommand, actionListenerList, borderPainted, BOTTOM, buttonListener, buttonModel, currentInsets, defaultIcon, disabledIcon, displayTransform, focusGap, focusPainted, gap, hasFocus, horizontalAlignment, horizontalTextAlignment, item, itemListenerList, LEFT, pressedIcon, resizeToFit, RIGHT, rolloverIcon, selectedIcon, text, textPosition, TOP, updateItem, updateText, verticalAlignment, verticalTextAlignment |
Fields inherited from interface com.sas.visuals.Alignment |
---|
BEGIN, CENTER, END |
Constructor Summary | |
---|---|
TabButton()
Default constructor. |
|
TabButton(com.sas.visuals.IconInterface defaultImg)
Constructor that sets the defaultIcon. |
|
TabButton(java.lang.String txt)
Constructor that sets the text on the TabButton. |
|
TabButton(java.lang.String txt,
com.sas.visuals.IconInterface defaultImg)
Constructor that sets the text and the defaultIcon of the TabButton. |
|
TabButton(java.lang.String txt,
com.sas.visuals.IconInterface defaultImg,
boolean selected)
Constructor that sets the text, the defaultIcon, and the selected state of the TabButton. |
Method Summary | |
---|---|
protected void |
buttonModelPressed(ButtonModelInterface btnModel)
Handles change in buttonModel pressed property. |
static int |
getDefaultHeight()
Returns the default height in pixels |
static int |
getDefaultWidth()
Returns the default width in pixels |
static com.sas.beans.ExtendedBeanInfo |
getExtendedBeanInfo()
Returns information used by the com.sas.beans.Introspector to
augment the automatically introspected information about this TabButton. |
int |
getOrientation()
Get the orientation of the TabButton. |
boolean |
isFocusTraversable()
Determines if the TabButton is focusTraversable. |
protected void |
paintBackground(java.awt.Graphics g)
Paint the background on the ToggleButton. |
static void |
setDefaultHeight(int newHeight)
Sets the default height in pixels |
static void |
setDefaultWidth(int newWidth)
Sets the default widthin pixels |
void |
setOrientation(int orient)
Sets the orientation of the TabButton. |
java.lang.String |
toString()
Returns the toString representation of the TabButton. |
Methods inherited from class com.sas.visuals.ToggleButton |
---|
buttonModelArmed, buttonModelSelected, clone, contentShift, getContentShift, getMinimumSize, getSelectionGroup, getSource, getTextBounds, paint, paintFocus, setContentShift, setFont, setHorizontalTextAlignment, setSelected, setSelectionGroup, setSource, setText, setVerticalTextAlignment |
Methods inherited from interface com.sas.visuals.TabButtonInterface |
---|
getActionCommand, setActionCommand |
Methods inherited from interface com.sas.visuals.SelectableInterface |
---|
getButtonModel, getDisplayTransform, getItem, getSelectionGroup, setDisplayTransform, setItem, setSelectionGroup |
Methods inherited from interface com.sas.awt.ActionSource |
---|
addActionListener, removeActionListener |
Methods inherited from interface com.sas.awt.ContainerInterface |
---|
getComponents, getLayout, invalidate, setLayout, validate |
Field Detail |
---|
public static final java.lang.String RB_KEY
public static final int NONE
protected int orientation
Constructor Detail |
---|
public TabButton()
public TabButton(java.lang.String txt)
txt
- the text for the TabButtonpublic TabButton(com.sas.visuals.IconInterface defaultImg)
defaultImg
- the defaultIcon objectpublic TabButton(java.lang.String txt, com.sas.visuals.IconInterface defaultImg)
txt
- the text for the TabButtondefaultImg
- the defaultIcon objectpublic TabButton(java.lang.String txt, com.sas.visuals.IconInterface defaultImg, boolean selected)
txt
- the text for the TabButtondefaultImg
- the defaultIcon objectselected
- the selected state of the TabButtonMethod Detail |
---|
public static int getDefaultHeight()
setDefaultHeight(int)
public static int getDefaultWidth()
setDefaultWidth(int)
public static void setDefaultHeight(int newHeight)
newHeight
- the desired default height in pixelsgetDefaultHeight()
public static void setDefaultWidth(int newWidth)
newWidth
- the desired default width in pixelssetDefaultWidth(int)
public static com.sas.beans.ExtendedBeanInfo getExtendedBeanInfo()
com.sas.beans.Introspector
to
augment the automatically introspected information about this TabButton.
protected void buttonModelPressed(ButtonModelInterface btnModel)
buttonModelPressed
in class ToggleButton
btnModel
- the buttonModel that changed.public boolean isFocusTraversable()
isFocusTraversable
in class BaseButton
Component.isFocusTraversable()
public int getOrientation()
getOrientation
in interface TabButtonInterface
setOrientation(int)
protected void paintBackground(java.awt.Graphics g)
paintBackground
in class ToggleButton
g
- the Graphics contextpublic void setOrientation(int orient)
setOrientation
in interface TabButtonInterface
orient
- an orientation value: TOP, BOTTOM, LEFT, RIGHT, or NONEOrientations
,
getOrientation()
public java.lang.String toString()
toString
in class java.awt.Component
Component.toString()
|
Components |
|
| |||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |