org.apache.pivot.wtk
Interface TextPane.Skin

All Known Implementing Classes:
TerraTextPaneSkin, TextPaneSkin
Enclosing class:
TextPane

public static interface TextPane.Skin

Text pane skin interface. Text pane skins are required to implement this.


Method Summary
 Bounds getCharacterBounds(int offset)
          Returns the bounds of the character at a given offset within the document.
 int getInsertionPoint(int x, int y)
          Returns the insertion point for a given location.
 int getNextInsertionPoint(int x, int from, TextPane.ScrollDirection direction)
          Returns the next insertion point given an x coordinate and a character offset.
 int getRowAt(int offset)
          Returns the row index of the character at a given offset within the document.
 int getRowCount()
          Returns the total number of rows in the document.
 

Method Detail

getInsertionPoint

int getInsertionPoint(int x,
                      int y)
Returns the insertion point for a given location.

Parameters:
x -
y -
Returns:
The insertion point for the given location.

getNextInsertionPoint

int getNextInsertionPoint(int x,
                          int from,
                          TextPane.ScrollDirection direction)
Returns the next insertion point given an x coordinate and a character offset.

Parameters:
x -
from -
direction -
Returns:
The next insertion point.

getRowAt

int getRowAt(int offset)
Returns the row index of the character at a given offset within the document.

Parameters:
offset -
Returns:
The row index of the character at the given offset.

getRowCount

int getRowCount()
Returns the total number of rows in the document.

Returns:
The number of rows in the document.

getCharacterBounds

Bounds getCharacterBounds(int offset)
Returns the bounds of the character at a given offset within the document.

Parameters:
offset -
Returns:
The bounds of the character at the given offset.