Class java.awt.TextComponent
All Packages  Class Hierarchy  This Package  Previous  Next  Index
  Class java.awt.TextComponent
java.lang.Object
   |
   +----java.awt.Component
           |
           +----java.awt.TextComponent
  -  public class TextComponent
  -  extends Component
A TextComponent is a component that allows the editing of some text.
   
  -   getSelectedText() getSelectedText()
-  Returns the selected text contained in this TextComponent.
  
-   getSelectionEnd() getSelectionEnd()
-  Returns the selected text's end position.
  
-   getSelectionStart() getSelectionStart()
-  Returns the selected text's start position.
  
-   getText() getText()
-  Returns the text contained in this TextComponent.
  
-   isEditable() isEditable()
-  Returns the boolean indicating whether this TextComponent is editable or not.
  
-   paramString() paramString()
-  Returns the String of parameters for this TextComponent.
  
-   removeNotify() removeNotify()
-  Removes the TextComponent's peer.
  
-   select(int, int) select(int, int)
-  Selects the text found between the specified start and end locations.
  
-   selectAll() selectAll()
-  Selects all the text in the TextComponent.
  
-   setEditable(boolean) setEditable(boolean)
-  Sets the specified boolean to indicate whether or not this TextComponent should be 
editable.
  
-   setText(String) setText(String)
-  Sets the text of this TextComponent to the specified text.
   
 removeNotify
removeNotify
  public synchronized void removeNotify()
  -  Removes the TextComponent's peer.  The peer allows us to modify the appearance
of the TextComponent without changing its functionality.
  
    -  Overrides:
    
-  removeNotify in class Component
  
 
 setText
setText
  public void setText(String t)
  -  Sets the text of this TextComponent to the specified text.
  
    -  Parameters:
    
-  t - the new text to be set
    
-  See Also:
    
-  getText
  
 
 getText
getText
  public String getText()
  -  Returns the text contained in this TextComponent.
  
    -  See Also:
    
-  setText
  
 
 getSelectedText
getSelectedText
  public String getSelectedText()
  -  Returns the selected text contained in this TextComponent.
  
    -  See Also:
    
-  setText
  
 
 isEditable
isEditable
  public boolean isEditable()
  -  Returns the boolean indicating whether this TextComponent is editable or not.
  
    -  See Also:
    
-  setEditable
  
 
 setEditable
setEditable
  public void setEditable(boolean t)
  -  Sets the specified boolean to indicate whether or not this TextComponent should be 
editable.
  
    -  Parameters:
    
-  t - the boolean to be set
    
-  See Also:
    
-  isEditable
  
 
 getSelectionStart
getSelectionStart
  public int getSelectionStart()
  -  Returns the selected text's start position.
 getSelectionEnd
getSelectionEnd
  public int getSelectionEnd()
  -  Returns the selected text's end position.
 select
select
  public void select(int selStart,
                     int selEnd)
  -  Selects the text found between the specified start and end locations.
  
    -  Parameters:
    
-  selStart - the start position of the text
    -  selEnd - the end position of the text
  
 
 selectAll
selectAll
  public void selectAll()
  -  Selects all the text in the TextComponent.
 paramString
paramString
  protected String paramString()
  -  Returns the String of parameters for this TextComponent.
  
    -  Overrides:
    
-  paramString in class Component
  
 
All Packages  Class Hierarchy  This Package  Previous  Next  Index