com.im.ijc.widgets/1 5.9.1

com.im.ijc.widgets.abstractwidget
Class CommonWidgetSettings

java.lang.Object
  extended by com.im.ijc.widgets.abstractwidget.CommonWidgetSettings
Direct Known Subclasses:
TableWidgetSettings, WidgetSettingsWithRenderer

public class CommonWidgetSettings
extends Object

Represents settings with properties that are common to all IJC widgets. Currently those are:


Field Summary
static String PROP_BORDER
          Property code name for the widget border.
static String PROP_TOOLTIP
          Property code name for the widget tooltip.
 
Constructor Summary
CommonWidgetSettings()
           
 
Method Summary
 void addPropertyChangeListener(PropertyChangeListener l)
           
protected  void firePropertyChange(String propertyName, Object oldValue, Object newValue)
           
 WidgetBorder getBorder()
          Get the widget border.
 WidgetToolTip getToolTip()
          Get the widget tooltip.
 DFField getToolTipField()
          Utility method returning getToolTip().getField() iff the tooltip is not null; return null otherwise.
 boolean isInternalBorderSpacingOn()
          Whether there should be spacing between inner Swing component pertaining to (or wrapped by) IJC widget and its titled border.
 void removePropertyChangeListener(PropertyChangeListener l)
           
 void setBorder(Font font)
           
 void setBorder(String title)
           
 void setBorder(WidgetBorder border)
          Set the widget's border.
 void setBorderType(WidgetBorder.BorderType type)
           
 void setInternalBorderSpacingOn(boolean internalBorderSpacingOn)
          Set whether there should be spacing between inner Swing component pertaining to (or wrapped by) IJC widget and its titled border.
 void setToolTip(WidgetToolTip toolTip)
          Set the widget's tooltip.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

PROP_BORDER

public static final String PROP_BORDER
Property code name for the widget border.

See Also:
Constant Field Values

PROP_TOOLTIP

public static final String PROP_TOOLTIP
Property code name for the widget tooltip.

See Also:
Constant Field Values
Constructor Detail

CommonWidgetSettings

public CommonWidgetSettings()
Method Detail

setBorder

public void setBorder(WidgetBorder border)
Set the widget's border.

Parameters:
border - the new Title

setBorder

public void setBorder(String title)

setBorder

public void setBorder(Font font)

setBorderType

public void setBorderType(WidgetBorder.BorderType type)

getBorder

public WidgetBorder getBorder()
Get the widget border.

Returns:
the border

setToolTip

public void setToolTip(WidgetToolTip toolTip)
Set the widget's tooltip. See WidgetToolTip for more.

Parameters:
toolTip - the new tooltip

getToolTipField

public DFField getToolTipField()
Utility method returning getToolTip().getField() iff the tooltip is not null; return null otherwise.

Returns:
maybe tooltip's field

getToolTip

public WidgetToolTip getToolTip()
Get the widget tooltip.

Returns:
the tooltip; might be null

setInternalBorderSpacingOn

public void setInternalBorderSpacingOn(boolean internalBorderSpacingOn)
Set whether there should be spacing between inner Swing component pertaining to (or wrapped by) IJC widget and its titled border. Thus the property is applicable only to titled border.

Widget is supposed to keep its original space thus providing more space for the inner component (like textfield).

Parameters:
internalBorderSpacingOn - should be there spacing between Swing widget and the border?

isInternalBorderSpacingOn

public boolean isInternalBorderSpacingOn()
Whether there should be spacing between inner Swing component pertaining to (or wrapped by) IJC widget and its titled border. Thus the property is applicable only to titled border.

Returns:
should be there spacing between Swing widget and the titled border?
See Also:
setInternalBorderSpacingOn(boolean)

firePropertyChange

protected final void firePropertyChange(String propertyName,
                                        Object oldValue,
                                        Object newValue)

addPropertyChangeListener

public final void addPropertyChangeListener(PropertyChangeListener l)

removePropertyChangeListener

public final void removePropertyChangeListener(PropertyChangeListener l)

com.im.ijc.widgets/1 5.9.1