de.hillenbrand.jreqtools
Class TextRequester

java.lang.Object
  extended by de.hillenbrand.jreqtools.AbstractRequester
      extended by de.hillenbrand.jreqtools.OkCancelRequester
          extended by de.hillenbrand.jreqtools.TextRequester

public class TextRequester
extends OkCancelRequester

This is a requester for complete texts.


Field Summary
 
Fields inherited from class de.hillenbrand.jreqtools.OkCancelRequester
answer, cancel, comment, drawFirstSeparator, drawSecondSeparator, icon, ok
 
Fields inherited from class de.hillenbrand.jreqtools.AbstractRequester
CANCEL, dialog, listener, message, OK, title
 
Constructor Summary
TextRequester(java.lang.String message, java.lang.String defaultstring)
          Constructs a new TextRequester.
TextRequester(java.lang.String title, java.lang.String message, java.lang.String defaultstring)
          Constructs a new TextRequester.
 
Method Summary
 int getTabSize()
           
 java.lang.String getText()
          Gets the string which has been entered by the user.
protected  javax.swing.JPanel getUserPanel()
           
 boolean getWrapStyleWord()
           
protected  void ok()
           
protected  void prepareForRequest()
          This method is being called directly before the dialog will be shown.
 void setFont(java.awt.Font f)
           
 void setLineWrap(boolean b)
          Sets the line-wrapping policy of the text area.
 void setTabSize(int i)
           
 void setText(java.lang.String newText)
          Sets the string in the requester.
 void setWrapStyleWord(boolean b)
          Sets the style of wrapping used if the text area is wrapping lines.
 
Methods inherited from class de.hillenbrand.jreqtools.OkCancelRequester
cancel, createContentPane, getComment, getDefaultButton, getIcon, getOkTriggerComponent, getPreferredRequesterSize, getReturnValue, isDrawFirstSeparator, isDrawSecondSeparator, setCancelButtonText, setComment, setDrawFirstSeparator, setDrawSecondSeparator, setDrawSeparators, setIcon, setOkButtonText, simulateCancelPressed, simulateOkPressed, validateData
 
Methods inherited from class de.hillenbrand.jreqtools.AbstractRequester
_checkLocation, _checkLocation, _checkSize, _checkSize, checkForClass, enableHelpKey4JavaHelp, getBounds, getLocation, getMessage, getSize, getTitle, request, request, request, setBorder, setBounds, setBounds, setLocation, setLocation, setMessage, setSize, setSize, setTitle, setVisible, showError, showException, showMessage
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TextRequester

public TextRequester(java.lang.String message,
                     java.lang.String defaultstring)
Constructs a new TextRequester.

Parameters:
message - - The message to be shown in the requester.
defaultstring - - The initial value of the text field.

TextRequester

public TextRequester(java.lang.String title,
                     java.lang.String message,
                     java.lang.String defaultstring)
Constructs a new TextRequester.

Parameters:
title - - Title of the requester.
message - - The message to be shown in the requester.
defaultstring - - The initial value of the text field.
Method Detail

getTabSize

public int getTabSize()

getText

public java.lang.String getText()
Gets the string which has been entered by the user.

Returns:

getUserPanel

protected javax.swing.JPanel getUserPanel()
Specified by:
getUserPanel in class OkCancelRequester

getWrapStyleWord

public boolean getWrapStyleWord()

ok

protected void ok()
Overrides:
ok in class OkCancelRequester

prepareForRequest

protected void prepareForRequest()
Description copied from class: AbstractRequester
This method is being called directly before the dialog will be shown.

Overrides:
prepareForRequest in class OkCancelRequester

setLineWrap

public void setLineWrap(boolean b)
Sets the line-wrapping policy of the text area. If set to true the lines will be wrapped if they are too long to fit within the allocated width. If set to false, the lines will always be unwrapped. By default this property is true.

Parameters:
b -

setTabSize

public void setTabSize(int i)

setText

public final void setText(java.lang.String newText)
Sets the string in the requester.

Parameters:
newText -

setWrapStyleWord

public void setWrapStyleWord(boolean b)
Sets the style of wrapping used if the text area is wrapping lines. If set to true the lines will be wrapped at word boundaries (whitespace) if they are too long to fit within the allocated width. If set to false, the lines will be wrapped at character boundaries. By default this property is true.

Parameters:
b -

setFont

public void setFont(java.awt.Font f)