org.apache.pivot.wtk
Interface Spinner.ItemRenderer
- All Superinterfaces:
- ConstrainedVisual, Renderer, Visual
- All Known Implementing Classes:
- SpinnerItemRenderer, TerraCalendarSkin.MonthSpinnerItemRenderer
- Enclosing class:
- Spinner
public static interface Spinner.ItemRenderer
- extends Renderer
Renderer
interface to customize the appearance of the data in a Spinner.
render
void render(Object item,
Spinner spinner)
- Prepares the renderer for layout or paint.
- Parameters:
item
- The item to render, or null if called to calculate preferred
height for skins that assume a fixed renderer height.spinner
- The host component.
toString
String toString(Object item)
- Converts a spinner item to a string representation.
- Parameters:
item
-
- Returns:
- The item's string representation, or null if the item does not
have a string representation.
Note that this method may be called often during keyboard navigation, so
implementations should avoid unnecessary string allocations.