All Packages Class Hierarchy This Package Previous Next Index
Class jp.kyasu.awt.text.TextView
java.lang.Object
|
+----java.awt.Component
|
+----jp.kyasu.awt.KComponent
|
+----jp.kyasu.awt.text.TextView
- public abstract class TextView
- extends KComponent
- implements Scrollable
The TextView
class is an abstract base class that views
the TextLayout
object.
- Version:
- 20 Nov 1999
- Author:
- Kazuki YASUMATSU
-
DEFAULT_BACKGROUND
- The default background color.
-
DEFAULT_FOREGROUND
- The default foreground color.
-
DEFAULT_SELECTION_BACKGROUND
- The default selection background color.
-
DEFAULT_SELECTION_FOREGROUND
- The default selection foreground color.
-
TextView(int)
- Constructs a text view with the specified line wrapping style.
-
addScrollListener(ScrollListener)
- Add a listener to recieve scroll events when the value
of the scroll component changes.
-
getColumns()
- Returns the number of columns.
-
getHBlockIncrement()
- Gets the horizontal block value increment for the scrollable object.
-
getHMaximum()
- Gets the horizontal maximum value of the scrollable object.
-
getHMinimum()
- Gets the horizontal minimum value of the scrollable object.
-
getHUnitIncrement()
- Gets the horizontal unit value increment for the scrollable object.
-
getHValue()
- Gets the horizontal current value of the scrollable object.
-
getHVisibleAmount()
- Gets the horizontal length of the propertional indicator.
-
getLineWrap()
- Returns the line wrapping style.
-
getLocationOfText()
- Returns the location of the
TextLayout
object.
-
getMinimumSize()
- Returns the minimum size of this view.
-
getPreferredHeight(int)
- Returns the preferred height of this view with the specified number
of rows.
-
getPreferredSize()
- Returns the preferred size of this view.
-
getPreferredSize(int, int)
- Returns the preferred size of this view with the specified number
of rows and columns.
-
getPreferredWidth(int)
- Returns the preferred width of this view with the specified number
of columns.
-
getRichText()
- Returns the
RichText
object being viewed.
-
getRows()
- Returns the number of rows.
-
getSelectionBackground()
- Returns the selection background color.
-
getSelectionForeground()
- Returns the selection foreground color.
-
getVBlockIncrement()
- Gets the vertical block value increment for the scrollable object.
-
getVMaximum()
- Gets the vertical maximum value of the scrollable object.
-
getVMinimum()
- Gets the vertical minimum value of the scrollable object.
-
getVUnitIncrement()
- Gets the vertical unit value increment for the scrollable object.
-
getVValue()
- Gets the vertical current value of the scrollable object.
-
getVVisibleAmount()
- Gets the vertical length of the propertional indicator.
-
isFocusTraversable()
- Tests if the view can be traversed using Tab or Shift-Tab keyboard
focus traversal.
-
isSelectionVisible()
- Tests if the selection is visible.
-
removeScrollListener(ScrollListener)
- Removes an scroll listener.
-
setBounds(int, int, int, int)
- Moves and resizes this view.
-
setHValue(int)
- Sets the horizontal current value of the scrollable object.
-
setLineWrap(int)
- Sets the line wrapping style.
-
setLocale(Locale)
- Sets the locale of this view.
-
setLocationOfText(Point)
- Sets the location of the
TextLayout
object.
-
setSelectionBackground(Color)
- Sets the selection background color.
-
setSelectionForeground(Color)
- Sets the selection foreground color.
-
setSelectionVisible(boolean)
- Makes the selection visible.
-
setVValue(int)
- Sets the vertical current value of the scrollable object.
DEFAULT_FOREGROUND
public static final Color DEFAULT_FOREGROUND
- The default foreground color.
DEFAULT_BACKGROUND
public static final Color DEFAULT_BACKGROUND
- The default background color.
DEFAULT_SELECTION_FOREGROUND
public static final Color DEFAULT_SELECTION_FOREGROUND
- The default selection foreground color.
DEFAULT_SELECTION_BACKGROUND
public static final Color DEFAULT_SELECTION_BACKGROUND
- The default selection background color.
TextView
public TextView(int lineWrap)
- Constructs a text view with the specified line wrapping style.
- Parameters:
- lineWrap - the line wrapping style.
- See Also:
- CHAR_WRAP, WORD_WRAP, NO_WRAP
getRichText
public abstract RichText getRichText()
- Returns the
RichText
object being viewed.
getLineWrap
public int getLineWrap()
- Returns the line wrapping style.
- See Also:
- setLineWrap
setLineWrap
public synchronized void setLineWrap(int lineWrap)
- Sets the line wrapping style.
- Parameters:
- lineWrap - the line wrapping style.
- See Also:
- getLineWrap, CHAR_WRAP, WORD_WRAP, NO_WRAP
setLocale
public synchronized void setLocale(Locale l)
- Sets the locale of this view.
- Overrides:
- setLocale in class Component
isFocusTraversable
public boolean isFocusTraversable()
- Tests if the view can be traversed using Tab or Shift-Tab keyboard
focus traversal.
- Overrides:
- isFocusTraversable in class KComponent
getLocationOfText
public Point getLocationOfText()
- Returns the location of the
TextLayout
object.
- See Also:
- setLocationOfText
setLocationOfText
public void setLocationOfText(Point p)
- Sets the location of the
TextLayout
object.
- See Also:
- getLocationOfText
isSelectionVisible
public boolean isSelectionVisible()
- Tests if the selection is visible.
- See Also:
- setSelectionVisible
setSelectionVisible
public synchronized void setSelectionVisible(boolean b)
- Makes the selection visible.
- See Also:
- isSelectionVisible
getSelectionForeground
public Color getSelectionForeground()
- Returns the selection foreground color.
- See Also:
- setSelectionForeground
setSelectionForeground
public synchronized void setSelectionForeground(Color c)
- Sets the selection foreground color.
- See Also:
- getSelectionForeground
getSelectionBackground
public Color getSelectionBackground()
- Returns the selection background color.
- See Also:
- setSelectionBackground
setSelectionBackground
public synchronized void setSelectionBackground(Color c)
- Sets the selection background color.
- See Also:
- getSelectionBackground
getPreferredSize
public Dimension getPreferredSize()
- Returns the preferred size of this view.
- Overrides:
- getPreferredSize in class KComponent
getMinimumSize
public Dimension getMinimumSize()
- Returns the minimum size of this view.
- Overrides:
- getMinimumSize in class KComponent
getPreferredSize
public Dimension getPreferredSize(int rows,
int columns)
- Returns the preferred size of this view with the specified number
of rows and columns.
- Parameters:
- rows - the number of rows.
- columns - the number of columns.
- Returns:
- the preferred size with the specified number of rows and columns.
getPreferredWidth
public int getPreferredWidth(int columns)
- Returns the preferred width of this view with the specified number
of columns.
- Parameters:
- columns - the number of columns.
- Returns:
- the preferred width with the specified number of columns.
getPreferredHeight
public int getPreferredHeight(int rows)
- Returns the preferred height of this view with the specified number
of rows.
- Parameters:
- rows - the number of rows.
- Returns:
- the preferred height with the specified number of rows.
getRows
public int getRows()
- Returns the number of rows.
getColumns
public int getColumns()
- Returns the number of columns.
setBounds
public synchronized void setBounds(int x,
int y,
int width,
int height)
- Moves and resizes this view.
- Parameters:
-
x
- The new x-coordinate of this view.
-
y
- The new y-coordinate of this view.
-
width
- The new width
of this view.
-
height
- The new height
of this view.
- Overrides:
- setBounds in class KComponent
getVMinimum
public int getVMinimum()
- Gets the vertical minimum value of the scrollable object.
- See Also:
- Scrollable
getHMinimum
public int getHMinimum()
- Gets the horizontal minimum value of the scrollable object.
- See Also:
- Scrollable
getVMaximum
public int getVMaximum()
- Gets the vertical maximum value of the scrollable object.
- See Also:
- Scrollable
getHMaximum
public int getHMaximum()
- Gets the horizontal maximum value of the scrollable object.
- See Also:
- Scrollable
getVUnitIncrement
public int getVUnitIncrement()
- Gets the vertical unit value increment for the scrollable object.
- See Also:
- Scrollable
getHUnitIncrement
public int getHUnitIncrement()
- Gets the horizontal unit value increment for the scrollable object.
- See Also:
- Scrollable
getVBlockIncrement
public int getVBlockIncrement()
- Gets the vertical block value increment for the scrollable object.
- See Also:
- Scrollable
getHBlockIncrement
public int getHBlockIncrement()
- Gets the horizontal block value increment for the scrollable object.
- See Also:
- Scrollable
getVVisibleAmount
public int getVVisibleAmount()
- Gets the vertical length of the propertional indicator.
- See Also:
- Scrollable
getHVisibleAmount
public int getHVisibleAmount()
- Gets the horizontal length of the propertional indicator.
- See Also:
- Scrollable
getVValue
public int getVValue()
- Gets the vertical current value of the scrollable object.
- See Also:
- Scrollable
getHValue
public int getHValue()
- Gets the horizontal current value of the scrollable object.
- See Also:
- Scrollable
setVValue
public void setVValue(int v)
- Sets the vertical current value of the scrollable object.
- Parameters:
- v - the current value.
- See Also:
- Scrollable
setHValue
public void setHValue(int v)
- Sets the horizontal current value of the scrollable object.
- Parameters:
- v - the current value.
- See Also:
- Scrollable
addScrollListener
public void addScrollListener(ScrollListener l)
- Add a listener to recieve scroll events when the value
of the scroll component changes.
- Parameters:
- l - the listener to recieve events.
- See Also:
- Scrollable
removeScrollListener
public void removeScrollListener(ScrollListener l)
- Removes an scroll listener.
- Parameters:
- l - the listener being removed.
- See Also:
- Scrollable
All Packages Class Hierarchy This Package Previous Next Index