Icon
, org.pushingpixels.flamingo.api.common.icon.ResizableIcon
public class TransitionAwareResizableIcon extends Object implements org.pushingpixels.flamingo.api.common.icon.ResizableIcon
Modifier and Type | Class | Description |
---|---|---|
static interface |
TransitionAwareResizableIcon.Delegate |
The delegate needs to implement the method in this interface based on the
provided theme.
|
static interface |
TransitionAwareResizableIcon.StateTransitionTrackerDelegate |
Modifier and Type | Field | Description |
---|---|---|
protected int |
height |
The height of the rendered image.
|
protected int |
width |
The width of the rendered image.
|
Constructor | Description |
---|---|
TransitionAwareResizableIcon(org.pushingpixels.flamingo.api.common.AbstractCommandButton button,
TransitionAwareResizableIcon.StateTransitionTrackerDelegate stateTransitionTrackerDelegate,
TransitionAwareResizableIcon.Delegate delegate,
Dimension initialDim) |
Creates a new transition-aware icon.
|
Modifier and Type | Method | Description |
---|---|---|
int |
getIconHeight() |
|
int |
getIconWidth() |
|
void |
paintIcon(Component c,
Graphics g,
int x,
int y) |
|
void |
setDimension(Dimension newDimension) |
protected int width
protected int height
public TransitionAwareResizableIcon(org.pushingpixels.flamingo.api.common.AbstractCommandButton button, TransitionAwareResizableIcon.StateTransitionTrackerDelegate stateTransitionTrackerDelegate, TransitionAwareResizableIcon.Delegate delegate, Dimension initialDim)
button
- Associated command button.delegate
- Delegate to compute the actual icons.initialDim
- Initial icon dimension.public void setDimension(Dimension newDimension)
setDimension
in interface org.pushingpixels.flamingo.api.common.icon.ResizableIcon
public int getIconHeight()
getIconHeight
in interface Icon
public int getIconWidth()
getIconWidth
in interface Icon