public class

SortArrowIcon

extends Object
implements Serializable Icon UIResource
java.lang.Object
   ↳ sun.swing.icon.SortArrowIcon

Class Overview

Sorting icon.

Summary

Public Constructors
SortArrowIcon(boolean ascending, Color color)
Creates a SortArrowIcon.
SortArrowIcon(boolean ascending, String colorKey)
Creates a SortArrowIcon.
Public Methods
int getIconHeight()
Returns the icon's height.
int getIconWidth()
Returns the icon's width.
void paintIcon(Component c, Graphics g, int x, int y)
Draw the icon at the specified location.
[Expand]
Inherited Methods
From class java.lang.Object
From interface javax.swing.Icon

Public Constructors

public SortArrowIcon (boolean ascending, Color color)

Creates a SortArrowIcon.

Parameters
ascending if true, icon respresenting ascending sort, otherwise descending
color the color to render the icon

public SortArrowIcon (boolean ascending, String colorKey)

Creates a SortArrowIcon.

Parameters
ascending if true, icon respresenting ascending sort, otherwise descending
colorKey the key used to find color in UIManager

Public Methods

public int getIconHeight ()

Returns the icon's height.

Returns
  • an int specifying the fixed height of the icon.

public int getIconWidth ()

Returns the icon's width.

Returns
  • an int specifying the fixed width of the icon.

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

Draw the icon at the specified location. Icon implementations may use the Component argument to get properties useful for painting, e.g. the foreground or background color.