Package games.stendhal.client.gui.styled
Class StyledButtonUI
java.lang.Object
javax.swing.plaf.ComponentUI
javax.swing.plaf.ButtonUI
javax.swing.plaf.basic.BasicButtonUI
games.stendhal.client.gui.styled.StyledButtonUI
ButtonUI implementation for drawing PixmapStyle buttons.
-
Field Summary
Fields inherited from class javax.swing.plaf.basic.BasicButtonUI
defaultTextIconGap, defaultTextShiftOffset -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic ComponentUIcreateUI(JComponent button) Required by UIManager.getPreferredSize(JComponent button) voidinstallUI(JComponent button) voidpaint(Graphics graphics, JComponent button) protected voidpaintButtonPressed(Graphics graphics, AbstractButton button) protected voidpaintFocus(Graphics graphics, AbstractButton button, Rectangle viewRect, Rectangle textRect, Rectangle iconRect) protected voidpaintText(Graphics graphics, AbstractButton button, Rectangle textRect, String text) Methods inherited from class javax.swing.plaf.basic.BasicButtonUI
clearTextShiftOffset, createButtonListener, getBaseline, getBaselineResizeBehavior, getDefaultTextIconGap, getMaximumSize, getMinimumSize, getPropertyPrefix, getTextShiftOffset, installDefaults, installKeyboardActions, installListeners, paintIcon, paintText, setTextShiftOffset, uninstallDefaults, uninstallKeyboardActions, uninstallListeners, uninstallUIMethods inherited from class javax.swing.plaf.ComponentUI
contains, getAccessibleChild, getAccessibleChildrenCount, update
-
Constructor Details
-
StyledButtonUI
Create a new StyledButtonUI.- Parameters:
style- used pixmap style
-
-
Method Details
-
createUI
Required by UIManager.- Parameters:
button- component to create UI for- Returns:
- UI delegate
-
paint
- Overrides:
paintin classBasicButtonUI
-
paintButtonPressed
- Overrides:
paintButtonPressedin classBasicButtonUI
-
paintText
- Overrides:
paintTextin classBasicButtonUI
-
paintFocus
protected void paintFocus(Graphics graphics, AbstractButton button, Rectangle viewRect, Rectangle textRect, Rectangle iconRect) - Overrides:
paintFocusin classBasicButtonUI
-
getPreferredSize
- Overrides:
getPreferredSizein classBasicButtonUI
-
installUI
- Overrides:
installUIin classBasicButtonUI
-