JHotDraw 7.5.1

org.jhotdraw.gui
Interface AttributeEditor<T>

All Known Implementing Classes:
JAttributeSlider, JAttributeTextArea, JAttributeTextField

@NotNull
public interface AttributeEditor<T>

Interface for a field or any other kind of editor which can be used to edit an attribute of the selected Figures in a DrawingView.

The AttributeEditor can be attached to a single DrawingView or to the whole DrawingEditor by means of an AttributeFieldHandler.

Version:
$Id: AttributeEditor.java 654 2010-06-25 13:27:08Z rawcoder $
Author:
Werner Randelshofer

Field Summary
static java.lang.String ATTRIBUTE_VALUE_PROPERTY
           
static java.lang.String MULTIPLE_VALUES_PROPERTY
           
 
Method Summary
 void addPropertyChangeListener(java.beans.PropertyChangeListener l)
          Adds a property change listener.
 T getAttributeValue()
          Gets the attribute value.
 javax.swing.JComponent getComponent()
          Returns the JComponent of the attribute field.
 boolean getValueIsAdjusting()
          Returns true if the field is currently adjusting the value.
 boolean isMultipleValues()
          This method returns the value of the multipleValues property.
 void removePropertyChangeListener(java.beans.PropertyChangeListener l)
          Removes a property change listener.
 void setAttributeValue(T newValue)
          Sets the attribute value.
 void setMultipleValues(boolean newValue)
          This method is called, if the figures of the attribute field have multiple values.
 

Field Detail

ATTRIBUTE_VALUE_PROPERTY

static final java.lang.String ATTRIBUTE_VALUE_PROPERTY
See Also:
Constant Field Values

MULTIPLE_VALUES_PROPERTY

static final java.lang.String MULTIPLE_VALUES_PROPERTY
See Also:
Constant Field Values
Method Detail

getComponent

javax.swing.JComponent getComponent()
Returns the JComponent of the attribute field.


setAttributeValue

void setAttributeValue(T newValue)
Sets the attribute value. This is a bound property.

Parameters:
newValue -

getAttributeValue

T getAttributeValue()
Gets the attribute value.


setMultipleValues

void setMultipleValues(boolean newValue)
This method is called, if the figures of the attribute field have multiple values.

Parameters:
newValue -

isMultipleValues

boolean isMultipleValues()
This method returns the value of the multipleValues property.


getValueIsAdjusting

boolean getValueIsAdjusting()
Returns true if the field is currently adjusting the value.


addPropertyChangeListener

void addPropertyChangeListener(java.beans.PropertyChangeListener l)
Adds a property change listener.

Parameters:
l -

removePropertyChangeListener

void removePropertyChangeListener(java.beans.PropertyChangeListener l)
Removes a property change listener.

Parameters:
l -

Copyright 1996-2010 (c) by the authors and contributors of the JHotDraw project.
Some rights reserved.