Package org.compiere.plaf
Class CompiereToggleButtonUI
- java.lang.Object
-
- javax.swing.plaf.ComponentUI
-
- javax.swing.plaf.ButtonUI
-
- javax.swing.plaf.basic.BasicButtonUI
-
- javax.swing.plaf.basic.BasicToggleButtonUI
-
- javax.swing.plaf.metal.MetalToggleButtonUI
-
- org.compiere.plaf.CompiereToggleButtonUI
-
public class CompiereToggleButtonUI extends MetalToggleButtonUI
Adempiere Toggle Button UI- Version:
- $Id: AdempiereToggleButtonUI.java,v 1.2 2006/07/30 00:52:24 jjanke Exp $
- Author:
- Jorg Janke
-
-
Field Summary
-
Fields inherited from class javax.swing.plaf.metal.MetalToggleButtonUI
disabledTextColor, focusColor, selectColor
-
Fields inherited from class javax.swing.plaf.basic.BasicButtonUI
defaultTextIconGap, defaultTextShiftOffset
-
-
Constructor Summary
Constructors Constructor Description CompiereToggleButtonUI()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static ComponentUI
createUI(JComponent c)
Static Create UIvoid
installDefaults(AbstractButton b)
Install Defaultsvoid
paint(Graphics g, JComponent c)
Paint 3D Boxprotected void
paintButtonPressed(Graphics g, AbstractButton b)
Don't get selected Color - use default (otherwise the pressed button is gray)void
update(Graphics g, JComponent c)
Update - This method is invoked byJComponent
when the specified component is being painted.-
Methods inherited from class javax.swing.plaf.metal.MetalToggleButtonUI
getDisabledTextColor, getFocusColor, getSelectColor, paintFocus, paintIcon, paintText, uninstallDefaults
-
Methods inherited from class javax.swing.plaf.basic.BasicToggleButtonUI
getPropertyPrefix, getTextShiftOffset
-
Methods inherited from class javax.swing.plaf.basic.BasicButtonUI
clearTextShiftOffset, createButtonListener, getBaseline, getBaselineResizeBehavior, getDefaultTextIconGap, getMaximumSize, getMinimumSize, getPreferredSize, installKeyboardActions, installListeners, installUI, paintIcon, paintText, setTextShiftOffset, uninstallKeyboardActions, uninstallListeners, uninstallUI
-
Methods inherited from class javax.swing.plaf.ComponentUI
contains, getAccessibleChild, getAccessibleChildrenCount
-
-
-
-
Method Detail
-
createUI
public static ComponentUI createUI(JComponent c)
Static Create UI- Parameters:
c
- Component- Returns:
- Adempiere ToggleButton UI
-
installDefaults
public void installDefaults(AbstractButton b)
Install Defaults- Overrides:
installDefaults
in classMetalToggleButtonUI
- Parameters:
b
-
-
update
public void update(Graphics g, JComponent c)
Update - This method is invoked byJComponent
when the specified component is being painted. By default this method will fill the specified component with its background color (if itsopaque
property istrue
) and then immediately callpaint
.- Overrides:
update
in classMetalToggleButtonUI
- Parameters:
g
- theGraphics
context in which to paintc
- the component being painted- See Also:
paint(java.awt.Graphics, javax.swing.JComponent)
,JComponent.paintComponent(java.awt.Graphics)
-
paint
public void paint(Graphics g, JComponent c)
Paint 3D Box- Overrides:
paint
in classBasicToggleButtonUI
- Parameters:
g
- Graphicsc
- Component
-
paintButtonPressed
protected void paintButtonPressed(Graphics g, AbstractButton b)
Don't get selected Color - use default (otherwise the pressed button is gray)- Overrides:
paintButtonPressed
in classMetalToggleButtonUI
- Parameters:
g
-b
-
-
-