All Packages Class Hierarchy This Package Previous Next Index
Class com.sun.java.swing.JListBox
java.lang.Object
|
+----java.awt.Component
|
+----java.awt.Container
|
+----com.sun.java.swing.JComponent
|
+----com.sun.java.swing.JListBox
- public class JListBox
- extends JComponent
- implements Accessible
-
cellRenderer
-
-
dataListener
-
-
dataModel
-
-
fallbackUI
-
-
fixedRowHeight
-
-
nCellsVisible
-
-
selectionModel
-
-
selectionPainted
-
-
JListBox()
-
-
JListBox(ListModel)
-
-
JListBox(Object[])
-
-
JListBox(Vector)
-
-
addSelectionInterval(int, int)
-
-
clearSelection()
-
-
createDataListener()
-
-
createDefaultCellRenderer()
-
-
createDefaultSelectionModel()
-
-
ensureIndexIsVisible(int)
-
-
getAccessibleAt(Point)
- Returns the Accessible child contained at the local coordinate
Point, if one exists.
-
getAccessibleRole()
- Get the role of this object.
-
getAccessibleStateSet()
- Get the state set of this object.
-
getAnchorSelectionIndex()
-
-
getCellBounds(int, int)
-
-
getCellRenderer()
-
-
getFirstVisibleIndex()
-
-
getLastVisibleIndex()
-
-
getLeadSelectionIndex()
-
-
getMaxSelectionIndex()
-
-
getMinSelectionIndex()
-
-
getModel()
-
-
getNCellsVisible()
- Gets the number of cells visible.
-
getSelectedIndex()
-
-
getSelectedIndices()
-
-
getSelectedValue()
-
-
getSelectedValues()
-
-
getSelectionModel()
-
-
getUI()
-
-
indexToLocation(int)
-
-
isFixedRowHeight()
-
-
isOpaque()
- Returns true if this component is completely opaque.
-
isSelectedIndex(int)
-
-
isSelectionEmpty()
-
-
isSelectionPainted()
- Returns true if the JListBox is painting the selection for rows
-
locationToIndex(Point)
-
-
removeSelectionInterval(int, int)
-
-
setCellRenderer(ListCellRenderer)
-
-
setFixedRowHeight(boolean)
-
-
setListData(Object[])
-
-
setListData(Vector)
-
-
setModel(ListModel)
-
-
setNCellsVisible(int)
- Sets the number of cells visible.
-
setSelectedIndex(int)
-
-
setSelectedIndices(int[])
-
-
setSelectedValue(Object)
-
-
setSelectedValue(Object, boolean)
-
-
setSelectionInterval(int, int)
-
-
setSelectionPainted(boolean)
- Sets whether the JListBox is painting the selection for rows.
-
setUI(ListBoxUI)
-
-
updateUI()
- Notification from the UIFactory that the L&F
has changed.
fallbackUI
protected static String fallbackUI
selectionModel
protected ListSelectionModel selectionModel
dataModel
protected ListModel dataModel
dataListener
protected ListDataListener dataListener
cellRenderer
protected ListCellRenderer cellRenderer
fixedRowHeight
protected boolean fixedRowHeight
nCellsVisible
protected int nCellsVisible
selectionPainted
protected boolean selectionPainted
JListBox
public JListBox(ListModel x)
JListBox
public JListBox(Object x[])
JListBox
public JListBox(Vector x)
JListBox
public JListBox()
getUI
public ListBoxUI getUI()
setUI
public void setUI(ListBoxUI ui)
updateUI
public void updateUI()
- Notification from the UIFactory that the L&F
has changed.
- Overrides:
- updateUI in class JComponent
getNCellsVisible
public int getNCellsVisible()
- Gets the number of cells visible.
- Returns:
- the value of the nCellsVisible property
- See Also:
- setNCellsVisible
setNCellsVisible
public void setNCellsVisible(int newValue)
- Sets the number of cells visible.
This value is stored as the JavaBeans bound property nCellsVisible.
- See Also:
- getNCellsVisible, addPropertyChangeListener, removePropertyChangeListener
getCellRenderer
public ListCellRenderer getCellRenderer()
setCellRenderer
public void setCellRenderer(ListCellRenderer newValue)
isFixedRowHeight
public boolean isFixedRowHeight()
setFixedRowHeight
public void setFixedRowHeight(boolean newValue)
locationToIndex
public int locationToIndex(Point location)
indexToLocation
public Point indexToLocation(int index)
getCellBounds
public Rectangle getCellBounds(int index1,
int index2)
getFirstVisibleIndex
public int getFirstVisibleIndex()
getLastVisibleIndex
public int getLastVisibleIndex()
ensureIndexIsVisible
public void ensureIndexIsVisible(int index)
getModel
public ListModel getModel()
setModel
public void setModel(ListModel newValue)
setListData
public void setListData(Vector x)
setListData
public void setListData(Object x[])
getSelectionModel
public ListSelectionModel getSelectionModel()
getAnchorSelectionIndex
public int getAnchorSelectionIndex()
getLeadSelectionIndex
public int getLeadSelectionIndex()
getMinSelectionIndex
public int getMinSelectionIndex()
getMaxSelectionIndex
public int getMaxSelectionIndex()
isSelectedIndex
public boolean isSelectedIndex(int index)
isSelectionEmpty
public boolean isSelectionEmpty()
clearSelection
public void clearSelection()
setSelectionInterval
public void setSelectionInterval(int anchor,
int lead)
addSelectionInterval
public void addSelectionInterval(int anchor,
int lead)
removeSelectionInterval
public void removeSelectionInterval(int index0,
int index1)
getSelectedIndices
public int[] getSelectedIndices()
setSelectedIndices
public void setSelectedIndices(int x[])
getSelectedValues
public Object[] getSelectedValues()
getSelectedIndex
public int getSelectedIndex()
setSelectedIndex
public void setSelectedIndex(int i)
getSelectedValue
public Object getSelectedValue()
setSelectedValue
public void setSelectedValue(Object anObject,
boolean shouldScroll)
setSelectedValue
public void setSelectedValue(Object anObject)
createDefaultCellRenderer
protected ListCellRenderer createDefaultCellRenderer()
createDefaultSelectionModel
protected ListSelectionModel createDefaultSelectionModel()
createDataListener
protected ListDataListener createDataListener()
isSelectionPainted
public boolean isSelectionPainted()
- Returns true if the JListBox is painting the selection for rows
setSelectionPainted
public void setSelectionPainted(boolean b)
- Sets whether the JListBox is painting the selection for rows.
isOpaque
public boolean isOpaque()
- Returns true if this component is completely opaque.
- Overrides:
- isOpaque in class JComponent
getAccessibleStateSet
public AccessibleStateSet getAccessibleStateSet()
- Get the state set of this object.
- Returns:
- an instance of AccessibleState containing the current state
of the object
- Overrides:
- getAccessibleStateSet in class JComponent
- See Also:
- AccessibleState
getAccessibleRole
public AccessibleRole getAccessibleRole()
- Get the role of this object.
- Returns:
- an instance of AccessibleRole describing the role of the object
- Overrides:
- getAccessibleRole in class JComponent
- See Also:
- AccessibleRole
getAccessibleAt
public Accessible getAccessibleAt(Point p)
- Returns the Accessible child contained at the local coordinate
Point, if one exists.
- Returns:
- the Accessible at the specified location, if it exists
- Overrides:
- getAccessibleAt in class JComponent
All Packages Class Hierarchy This Package Previous Next Index