edu.washington.cs.supple.wlib.java2
Class TextAreaWidget
java.lang.Object
edu.washington.cs.supple.render.AbstractWidget
edu.washington.cs.supple.render.SimpleWidget
edu.washington.cs.supple.wlib.java2.SimpleSwingWidget
edu.washington.cs.supple.wlib.java2.TextAreaWidget
- All Implemented Interfaces:
- java.lang.Cloneable, java.util.EventListener, java.beans.PropertyChangeListener, SwingWidget, UnwrappedWidget, Widget
- public class TextAreaWidget
- extends SimpleSwingWidget
- Author:
- kgajos
|
Method Summary |
protected WidgetDescriptor |
generateWidgetDescriptor()
Subclasses can override this method if their widget descriptor include
extra information |
int |
getHeight()
|
javax.swing.JComponent |
getSwingComponent(int hints)
|
int |
getWidth()
|
static boolean |
rendersObject(UiObject object)
A static method for testing the applicability of the widget given a type
of the UI component to be rendered |
void |
setEnabled(boolean enabled)
This method is exposed only so that wrappers can access it; others should
stay away |
java.lang.String |
toString()
|
protected void |
valueChanged(java.beans.PropertyChangeEvent evt)
Subclasses should override this method if they want to update display the
value of the underlying type changes |
| Methods inherited from class edu.washington.cs.supple.render.AbstractWidget |
anotherPropertyChanged, clone, clone, disengage, dismissCurrentView, displayDynamic, equals, executeAction, getBag, getConcreteWidget, getCost, getParent, getPath, getSizeCache, getTextLabel, getType, getUiObject, getWidgetDescriptor, indexChanged, isEngaged, isEquivalent, legalValuesChanged, likelyValuesChanged, propertyChange, reportActionExecutionEvent, reportValueChangedEvent, setBag, setCost, setParent, setSizeCache, setValue, setWrapper, unwrapWidget |
| Methods inherited from class java.lang.Object |
finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface edu.washington.cs.supple.render.Widget |
childIterator, clone, clone, disengage, getBag, getConcreteWidget, getCost, getEffortEstimate, getPath, getSizeCache, getTextLabel, getType, getUiObject, getWidgetDescriptor, hasChildren, isEngaged, isEquivalent, setBag, setCost, setParent, setSizeCache, setWrapper, unwrapWidget |
width
protected int width
height
protected int height
textType
protected TextType textType
textArea
protected javax.swing.JTextArea textArea
WIDTH_PROPERTY
public static final java.lang.String WIDTH_PROPERTY
- See Also:
- Constant Field Values
HEIGHT_PROPERTY
public static final java.lang.String HEIGHT_PROPERTY
- See Also:
- Constant Field Values
TextAreaWidget
public TextAreaWidget(UiObject object,
int width,
int height)
- Parameters:
object -
TextAreaWidget
public TextAreaWidget(UiObject object,
WidgetDescriptor wd,
WidgetFactory f)
generateWidgetDescriptor
protected WidgetDescriptor generateWidgetDescriptor()
- Description copied from class:
AbstractWidget
- Subclasses can override this method if their widget descriptor include
extra information
- Overrides:
generateWidgetDescriptor in class AbstractWidget
- Returns:
- a new widget descriptor for this widge
rendersObject
public static boolean rendersObject(UiObject object)
- A static method for testing the applicability of the widget given a type
of the UI component to be rendered
- Returns:
- true for all instances of the Text type
getSwingComponent
public javax.swing.JComponent getSwingComponent(int hints)
- Parameters:
hints - specifies the variant of the widget to be rendered
- Returns:
- a renderable component
valueChanged
protected void valueChanged(java.beans.PropertyChangeEvent evt)
- Description copied from class:
AbstractWidget
- Subclasses should override this method if they want to update display the
value of the underlying type changes
- Overrides:
valueChanged in class AbstractWidget
- Parameters:
evt - property change event with details
getHeight
public int getHeight()
- Returns:
- Returns the height.
getWidth
public int getWidth()
- Returns:
- Returns the width.
setEnabled
public void setEnabled(boolean enabled)
- Description copied from interface:
Widget
- This method is exposed only so that wrappers can access it; others should
stay away
- Specified by:
setEnabled in interface Widget- Overrides:
setEnabled in class AbstractWidget
- Parameters:
enabled - indicates if the underlying object is active
toString
public java.lang.String toString()
- Overrides:
toString in class AbstractWidget