|
JIDE 3.5.15 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object javax.swing.plaf.ComponentUI javax.swing.plaf.ButtonUI javax.swing.plaf.MenuItemUI com.jidesoft.plaf.vsnet.VsnetMenuItemUI com.jidesoft.plaf.vsnet.VsnetMenuUI com.jidesoft.plaf.basic.BasicJideSplitButtonUI
public class BasicJideSplitButtonUI
SplitButtonUI implementation
Nested Class Summary | |
---|---|
protected class |
BasicJideSplitButtonUI.MouseInputHandler
|
Nested classes/interfaces inherited from class com.jidesoft.plaf.vsnet.VsnetMenuUI |
---|
VsnetMenuUI.PostAction |
Field Summary | |
---|---|
protected Color |
_darkShadowColor
|
protected Color |
_highlight
|
protected boolean |
_isFloatingIcon
|
protected Color |
_lightHighlightColor
|
protected ThemePainter |
_painter
|
protected Color |
_shadowColor
|
protected int |
_splitButtonMargin
|
protected int |
_splitButtonMarginOnMenu
|
Fields inherited from class com.jidesoft.plaf.vsnet.VsnetMenuUI |
---|
changeListener, menuListener, propertyChangeListener |
Fields inherited from class com.jidesoft.plaf.vsnet.VsnetMenuItemUI |
---|
acceleratorFont, acceleratorForeground, acceleratorRect, acceleratorSelectionForeground, arrowIcon, arrowIconRect, backgroundColor, borderColor, checkIcon, checkIconRect, defaultAccelEndGap, defaultShadowWidth, defaultTextIconGap, disabledForeground, iconRect, menuDragMouseListener, menuItem, menuKeyListener, mouseInputListener, oldBorderPainted, selectionBackground, selectionForeground, shadowColor, textRect, viewRect, windowInputMap, zeroRect |
Constructor Summary | |
---|---|
BasicJideSplitButtonUI()
|
Method Summary | |
---|---|
protected MouseInputListener |
createMouseInputListener(JComponent c)
|
static ComponentUI |
createUI(JComponent x)
|
protected static void |
downButtonPressed(JMenu menu)
|
protected void |
drawStringUnderlineCharAt(JComponent c,
Graphics g,
String text,
int underlinedIndex,
int x,
int y)
|
static int |
getAdjustExtraWidth(Component c,
String text,
int extraWidth)
|
protected Rectangle |
getButtonRect(JComponent c,
int orientation,
int width,
int height)
Gets the bounds for the button part of the JideSplitButton . |
protected Rectangle |
getDropDownRect(JComponent c,
int orientation,
int width,
int height)
Gets the bounds for the drop down part of the JideSplitButton . |
protected static Container |
getFirstParentMenuElement(Component comp)
|
protected Icon |
getIcon(AbstractButton b)
|
InputMap |
getInputMap(int condition,
JComponent c)
Returns the InputMap for condition condition . |
Dimension |
getMaximumSize(JComponent c)
|
static String |
getMaxLengthWord(String text)
|
Dimension |
getMinimumSize(JComponent c)
|
protected int |
getOffset()
The gap between the button part and the drop down menu part. |
Dimension |
getPreferredSize(JComponent c)
|
protected String |
getPropertyPrefix()
|
protected int |
getRightMargin()
|
static String[] |
getWrappedText(String text)
Gets the text after wrapping. |
protected void |
installDefaults()
|
protected void |
installKeyboardActions()
|
protected void |
installListeners()
|
protected boolean |
isAlwaysDropdown(JMenuItem menuItem)
|
protected boolean |
isFloatingIcon()
|
static void |
loadActionMap(LazyActionMap map)
Populates Buttons actions. |
protected void |
paintArrow(JMenuItem menuItem,
Graphics g)
|
protected void |
paintBackground(Graphics g,
JMenuItem menuItem,
Color bgColor)
Draws the background of the menu item. |
protected void |
paintIcon(JMenuItem b,
Graphics g)
|
protected void |
paintRaised2Border(Graphics g,
Rectangle b)
|
protected void |
paintRaisedBorder(Graphics g,
Rectangle b)
|
protected void |
paintSunken2Border(Graphics g,
Rectangle b)
|
protected void |
paintSunkenBorder(Graphics g,
Rectangle b)
|
protected void |
paintText(Graphics g,
JMenuItem menuItem,
Rectangle textRect,
String text)
Method which renders the text of the current menu item. |
protected void |
uninstallDefaults()
|
protected void |
uninstallKeyboardActions()
|
protected void |
uninstallListeners()
|
protected void |
updateMnemonicBinding()
|
Methods inherited from class com.jidesoft.plaf.vsnet.VsnetMenuUI |
---|
appendPath, createActionMap, createChangeListener, createMenuDragMouseListener, createMenuKeyListener, createMenuListener, createPopupMenuListener, createPropertyChangeListener, getActionMap, isMouseOver, setMouseOver, setupPostTimer |
Methods inherited from class com.jidesoft.plaf.vsnet.VsnetMenuItemUI |
---|
createInputMap, doClick, getPainter, getPath, getPreferredMenuItemSize, installComponents, installUI, isDownArrowVisible, paint, paintCheckBox, paintMenuItem, uninstallComponents, uninstallUI, update, useCheckAndArrow |
Methods inherited from class javax.swing.plaf.ComponentUI |
---|
contains, getAccessibleChild, getAccessibleChildrenCount, getBaseline, getBaselineResizeBehavior |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected ThemePainter _painter
protected Color _shadowColor
protected Color _darkShadowColor
protected Color _highlight
protected Color _lightHighlightColor
protected int _splitButtonMargin
protected int _splitButtonMarginOnMenu
protected boolean _isFloatingIcon
Constructor Detail |
---|
public BasicJideSplitButtonUI()
Method Detail |
---|
public static ComponentUI createUI(JComponent x)
protected String getPropertyPrefix()
getPropertyPrefix
in class VsnetMenuUI
protected void installDefaults()
installDefaults
in class VsnetMenuUI
protected void uninstallDefaults()
uninstallDefaults
in class VsnetMenuUI
protected void installListeners()
installListeners
in class VsnetMenuUI
protected void uninstallListeners()
uninstallListeners
in class VsnetMenuUI
public InputMap getInputMap(int condition, JComponent c)
condition
. Called as part of
installKeyboardActions
.
condition
- the conditionc
- the component
protected void installKeyboardActions()
installKeyboardActions
in class VsnetMenuUI
protected void uninstallKeyboardActions()
uninstallKeyboardActions
in class VsnetMenuUI
protected MouseInputListener createMouseInputListener(JComponent c)
createMouseInputListener
in class VsnetMenuUI
protected void paintBackground(Graphics g, JMenuItem menuItem, Color bgColor)
VsnetMenuItemUI
paintBackground
in class VsnetMenuUI
g
- the paint graphicsmenuItem
- menu item to be paintedbgColor
- selection background colorprotected void paintArrow(JMenuItem menuItem, Graphics g)
protected Rectangle getDropDownRect(JComponent c, int orientation, int width, int height)
JideSplitButton
.
c
- the component. In this case, it is the JideSplitButton
.orientation
- the orientation.width
- the width of the JideSplitButton
height
- the height of the JideSplitButton
.
JideSplitButton
.protected Rectangle getButtonRect(JComponent c, int orientation, int width, int height)
JideSplitButton
.
c
- the component. In this case, it is the JideSplitButton
.orientation
- the orientation.width
- the width of the JideSplitButton
height
- the height of the JideSplitButton
.
JideSplitButton
.protected void paintSunkenBorder(Graphics g, Rectangle b)
protected void paintSunken2Border(Graphics g, Rectangle b)
protected void paintRaised2Border(Graphics g, Rectangle b)
protected void paintRaisedBorder(Graphics g, Rectangle b)
public Dimension getPreferredSize(JComponent c)
getPreferredSize
in class VsnetMenuUI
public Dimension getMinimumSize(JComponent c)
getMinimumSize
in class VsnetMenuItemUI
public Dimension getMaximumSize(JComponent c)
getMaximumSize
in class VsnetMenuUI
protected void paintText(Graphics g, JMenuItem menuItem, Rectangle textRect, String text)
VsnetMenuUI
paintText
in class VsnetMenuUI
g
- Graphics contextmenuItem
- Current menu item to rendertextRect
- Bounding rectangle to render the text.text
- String to renderprotected void drawStringUnderlineCharAt(JComponent c, Graphics g, String text, int underlinedIndex, int x, int y)
protected void paintIcon(JMenuItem b, Graphics g)
paintIcon
in class VsnetMenuItemUI
protected boolean isFloatingIcon()
isFloatingIcon
in class VsnetMenuItemUI
protected Icon getIcon(AbstractButton b)
getIcon
in class VsnetMenuItemUI
protected int getOffset()
protected boolean isAlwaysDropdown(JMenuItem menuItem)
protected int getRightMargin()
getRightMargin
in class VsnetMenuItemUI
public static void loadActionMap(LazyActionMap map)
map
- the mapprotected void updateMnemonicBinding()
updateMnemonicBinding
in class VsnetMenuUI
protected static void downButtonPressed(JMenu menu)
protected static Container getFirstParentMenuElement(Component comp)
public static int getAdjustExtraWidth(Component c, String text, int extraWidth)
c
- the componenttext
- the textextraWidth
- the extra width
public static String getMaxLengthWord(String text)
public static String[] getWrappedText(String text)
text
- the text
|
JIDE 3.5.15 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |