javax.swing.plaf
Class ListUI

java.lang.Object sample code for java.lang.Object definition code for java.lang.Object 
  extended by javax.swing.plaf.ComponentUI sample code for javax.swing.plaf.ComponentUI definition code for javax.swing.plaf.ComponentUI 
      extended by javax.swing.plaf.ListUI
Direct Known Subclasses:
BasicListUI sample code for javax.swing.plaf.basic.BasicListUI definition code for javax.swing.plaf.basic.BasicListUI , MultiListUI sample code for javax.swing.plaf.multi.MultiListUI definition code for javax.swing.plaf.multi.MultiListUI

public abstract class ListUI
extends ComponentUI sample code for javax.swing.plaf.ComponentUI definition code for javax.swing.plaf.ComponentUI

The JList pluggable look and feel delegate. This interface adds methods that allow the JList component to map locations, e.g. mouse coordinates, to list cells and from cell indices to the bounds of the cell.


Constructor Summary
ListUI sample code for javax.swing.plaf.ListUI.ListUI() definition code for javax.swing.plaf.ListUI.ListUI() ()
           
 
Method Summary
abstract  Rectangle sample code for java.awt.Rectangle definition code for java.awt.Rectangle getCellBounds sample code for javax.swing.plaf.ListUI.getCellBounds(javax.swing.JList, int, int) definition code for javax.swing.plaf.ListUI.getCellBounds(javax.swing.JList, int, int) (JList sample code for javax.swing.JList definition code for javax.swing.JList  list, int index1, int index2)
          Returns the bounds of the specified item in JList coordinates, null if index isn't valid.
abstract  Point sample code for java.awt.Point definition code for java.awt.Point indexToLocation sample code for javax.swing.plaf.ListUI.indexToLocation(javax.swing.JList, int) definition code for javax.swing.plaf.ListUI.indexToLocation(javax.swing.JList, int) (JList sample code for javax.swing.JList definition code for javax.swing.JList  list, int index)
          Returns the origin of the specified item in JList coordinates, null if index isn't valid.
abstract  int locationToIndex sample code for javax.swing.plaf.ListUI.locationToIndex(javax.swing.JList, java.awt.Point) definition code for javax.swing.plaf.ListUI.locationToIndex(javax.swing.JList, java.awt.Point) (JList sample code for javax.swing.JList definition code for javax.swing.JList  list, Point sample code for java.awt.Point definition code for java.awt.Point  location)
          Convert a point in JList coordinates to the closest index of the cell at that location.
 
Methods inherited from class javax.swing.plaf.ComponentUI sample code for javax.swing.plaf.ComponentUI definition code for javax.swing.plaf.ComponentUI
contains sample code for javax.swing.plaf.ComponentUI.contains(javax.swing.JComponent, int, int) definition code for javax.swing.plaf.ComponentUI.contains(javax.swing.JComponent, int, int) , createUI sample code for javax.swing.plaf.ComponentUI.createUI(javax.swing.JComponent) definition code for javax.swing.plaf.ComponentUI.createUI(javax.swing.JComponent) , getAccessibleChild sample code for javax.swing.plaf.ComponentUI.getAccessibleChild(javax.swing.JComponent, int) definition code for javax.swing.plaf.ComponentUI.getAccessibleChild(javax.swing.JComponent, int) , getAccessibleChildrenCount sample code for javax.swing.plaf.ComponentUI.getAccessibleChildrenCount(javax.swing.JComponent) definition code for javax.swing.plaf.ComponentUI.getAccessibleChildrenCount(javax.swing.JComponent) , getMaximumSize sample code for javax.swing.plaf.ComponentUI.getMaximumSize(javax.swing.JComponent) definition code for javax.swing.plaf.ComponentUI.getMaximumSize(javax.swing.JComponent) , getMinimumSize sample code for javax.swing.plaf.ComponentUI.getMinimumSize(javax.swing.JComponent) definition code for javax.swing.plaf.ComponentUI.getMinimumSize(javax.swing.JComponent) , getPreferredSize sample code for javax.swing.plaf.ComponentUI.getPreferredSize(javax.swing.JComponent) definition code for javax.swing.plaf.ComponentUI.getPreferredSize(javax.swing.JComponent) , installUI sample code for javax.swing.plaf.ComponentUI.installUI(javax.swing.JComponent) definition code for javax.swing.plaf.ComponentUI.installUI(javax.swing.JComponent) , paint sample code for javax.swing.plaf.ComponentUI.paint(java.awt.Graphics, javax.swing.JComponent) definition code for javax.swing.plaf.ComponentUI.paint(java.awt.Graphics, javax.swing.JComponent) , uninstallUI sample code for javax.swing.plaf.ComponentUI.uninstallUI(javax.swing.JComponent) definition code for javax.swing.plaf.ComponentUI.uninstallUI(javax.swing.JComponent) , update sample code for javax.swing.plaf.ComponentUI.update(java.awt.Graphics, javax.swing.JComponent) definition code for javax.swing.plaf.ComponentUI.update(java.awt.Graphics, javax.swing.JComponent)
 
Methods inherited from class java.lang.Object sample code for java.lang.Object definition code for java.lang.Object
clone sample code for java.lang.Object.clone() definition code for java.lang.Object.clone() , equals sample code for java.lang.Object.equals(java.lang.Object) definition code for java.lang.Object.equals(java.lang.Object) , finalize sample code for java.lang.Object.finalize() definition code for java.lang.Object.finalize() , getClass sample code for java.lang.Object.getClass() definition code for java.lang.Object.getClass() , hashCode sample code for java.lang.Object.hashCode() definition code for java.lang.Object.hashCode() , notify sample code for java.lang.Object.notify() definition code for java.lang.Object.notify() , notifyAll sample code for java.lang.Object.notifyAll() definition code for java.lang.Object.notifyAll() , toString sample code for java.lang.Object.toString() definition code for java.lang.Object.toString() , wait sample code for java.lang.Object.wait() definition code for java.lang.Object.wait() , wait sample code for java.lang.Object.wait(long) definition code for java.lang.Object.wait(long) , wait sample code for java.lang.Object.wait(long, int) definition code for java.lang.Object.wait(long, int)
 

Constructor Detail

ListUI sample code for javax.swing.plaf.ListUI() definition code for javax.swing.plaf.ListUI()

public ListUI()
Method Detail

locationToIndex sample code for javax.swing.plaf.ListUI.locationToIndex(javax.swing.JList, java.awt.Point) definition code for javax.swing.plaf.ListUI.locationToIndex(javax.swing.JList, java.awt.Point)

public abstract int locationToIndex(JList sample code for javax.swing.JList definition code for javax.swing.JList  list,
                                    Point sample code for java.awt.Point definition code for java.awt.Point  location)
Convert a point in JList coordinates to the closest index of the cell at that location. To determine if the cell actually contains the specified location use a combination of this method and getCellBounds. Returns -1 if the model is empty.

Parameters:
location - The JList relative coordinates of the cell
Returns:
The index of the cell at location, or -1.

indexToLocation sample code for javax.swing.plaf.ListUI.indexToLocation(javax.swing.JList, int) definition code for javax.swing.plaf.ListUI.indexToLocation(javax.swing.JList, int)

public abstract Point sample code for java.awt.Point definition code for java.awt.Point  indexToLocation(JList sample code for javax.swing.JList definition code for javax.swing.JList  list,
                                      int index)
Returns the origin of the specified item in JList coordinates, null if index isn't valid.

Parameters:
index - The index of the JList cell.
Returns:
The origin of the index'th cell.

getCellBounds sample code for javax.swing.plaf.ListUI.getCellBounds(javax.swing.JList, int, int) definition code for javax.swing.plaf.ListUI.getCellBounds(javax.swing.JList, int, int)

public abstract Rectangle sample code for java.awt.Rectangle definition code for java.awt.Rectangle  getCellBounds(JList sample code for javax.swing.JList definition code for javax.swing.JList  list,
                                        int index1,
                                        int index2)
Returns the bounds of the specified item in JList coordinates, null if index isn't valid.

Parameters:
index - The index of the JList cell.
Returns:
The bounds of the index'th cell.