Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.flexdock.dockbar.util
Class TextIcon

    java.lang.Object
      org.flexdock.dockbar.util.TextIcon

All Implemented Interfaces:
  PropertyChangeListener, EventListener, Icon

    public class TextIcon

extends Object
implements Icon, PropertyChangeListener

Author:
  Andreas Ernst, Christopher Butler

Field Summary
`static int` | `ROTATE_LEFT`
`static int` | `ROTATE_NONE`
`static int` | `ROTATE_RIGHT`

Constructor Summary
`TextIcon(Component cmp, int space, int inset)` Creates a `TextIcon` for the specified `component` with the specified `label`.

Method Summary
`int` | `getIconHeight()`
`int` | `getIconWidth()`
`String` | `getText()`
`static int` | `getValidRotation(int rotation)`
`void` | `paintIcon(Component c, Graphics g, int x, int y)`
`void` | `propertyChange(PropertyChangeEvent e)`
`void` | `setIcon(Icon icon)`
`void` | `setRotation(int rotation)`
`void` | `setText(String text)`
`void` | `validate()`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### ROTATE_NONE

    public static final int ROTATE_NONE

See Also:
  Constant Field Values

### ROTATE_LEFT

    public static final int ROTATE_LEFT

See Also:
  Constant Field Values

### ROTATE_RIGHT

    public static final int ROTATE_RIGHT

See Also:
  Constant Field Values

Constructor Detail

### TextIcon

    public TextIcon(Component cmp,
                    int space,
                    int inset)

  Creates a `TextIcon` for the specified `component` with the specified `label`. It sets the orientation to the provided value if it's legal for the string

Method Detail

### getText

    public String getText()

### setText

    public void setText(String text)

### setIcon

    public void setIcon(Icon icon)

### setRotation

    public void setRotation(int rotation)

### getValidRotation

    public static int getValidRotation(int rotation)

### propertyChange

    public void propertyChange(PropertyChangeEvent e)

  Specified by:
    `propertyChange` in interface `PropertyChangeListener`

### getIconWidth

    public int getIconWidth()

  Specified by:
    `getIconWidth` in interface `Icon`

### getIconHeight

    public int getIconHeight()

  Specified by:
    `getIconHeight` in interface `Icon`

### paintIcon

    public void paintIcon(Component c,
                          Graphics g,
                          int x,
                          int y)

  Specified by:
    `paintIcon` in interface `Icon`

### validate

    public void validate()

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD