Package com.im.ijc.core.api.views
Class FormDataBean
- java.lang.Object
-
- com.im.ijc.core.api.views.FormDataBean
-
public class FormDataBean extends java.lang.Object
FormDataBean
serves as a communication bridge between IJC form view and awidget
. Form view is using information provided by this class to e.g. compute the size of the box into which the widget is placed.
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
PROP_INTERNAL_BORDER_SPACING_ON
static java.lang.String
PROP_PREFERRED_SIZE
static int
RESIZE_BOTH
static int
RESIZE_HORIZONTAL
static int
RESIZE_NONE
static int
RESIZE_VERTICAL
-
Constructor Summary
Constructors Constructor Description FormDataBean()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addPropertyChangeListener(java.beans.PropertyChangeListener l)
void
addSizeChangedCallback(com.im.commons.Callback<java.awt.Dimension> callback)
The given callback is called when there ischange request
pushed.void
addSizeQuery(java.util.concurrent.Callable<java.awt.Rectangle> callable)
java.awt.Rectangle
getBounds()
Returns org.netbeans.api.visual.widget.Widget.getBounds().java.awt.Dimension
getPreferredSize()
int
getResizeDirections()
boolean
isInternalBorderSpacingOn()
Whether there should be spacing between inner Swing component pertaining to (or wrapped by) IJC widget and its titled border.void
pushSizeChangeRequest(java.awt.Dimension requestedSizeDelta)
Communicates to the form view that the size of the widget should be changed according to the givendelta
.void
removePropertyChangeListener(java.beans.PropertyChangeListener l)
void
setInternalBorderSpacingOn(boolean internalBorderSpacingOn, boolean fire)
Set whether there should be spacing between inner Swing component pertaining to (or wrapped by) IJC widget and its titled border.void
setPreferredSize(java.awt.Dimension preferredSize)
void
setResizeDirections(int resizeDirections)
-
-
-
Field Detail
-
PROP_INTERNAL_BORDER_SPACING_ON
public static final java.lang.String PROP_INTERNAL_BORDER_SPACING_ON
- See Also:
- Constant Field Values
-
PROP_PREFERRED_SIZE
public static final java.lang.String PROP_PREFERRED_SIZE
- See Also:
- Constant Field Values
-
RESIZE_NONE
public static final int RESIZE_NONE
- See Also:
- Constant Field Values
-
RESIZE_HORIZONTAL
public static final int RESIZE_HORIZONTAL
- See Also:
- Constant Field Values
-
RESIZE_VERTICAL
public static final int RESIZE_VERTICAL
- See Also:
- Constant Field Values
-
RESIZE_BOTH
public static final int RESIZE_BOTH
- See Also:
- Constant Field Values
-
-
Method Detail
-
getPreferredSize
public java.awt.Dimension getPreferredSize()
-
setPreferredSize
public void setPreferredSize(java.awt.Dimension preferredSize)
-
getResizeDirections
public int getResizeDirections()
-
setResizeDirections
public void setResizeDirections(int resizeDirections)
-
getBounds
public java.awt.Rectangle getBounds()
Returns org.netbeans.api.visual.widget.Widget.getBounds().- Returns:
- Rectangle bounds
-
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, boolean)
-
setInternalBorderSpacingOn
public void setInternalBorderSpacingOn(boolean internalBorderSpacingOn, boolean fire)
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 titled border?fire
- whether to notify registered listeners about this change
-
pushSizeChangeRequest
public void pushSizeChangeRequest(java.awt.Dimension requestedSizeDelta)
Communicates to the form view that the size of the widget should be changed according to the givendelta
.- Parameters:
requestedSizeDelta
- the wanted change
-
addSizeChangedCallback
public void addSizeChangedCallback(com.im.commons.Callback<java.awt.Dimension> callback)
The given callback is called when there ischange request
pushed.
-
addSizeQuery
public void addSizeQuery(java.util.concurrent.Callable<java.awt.Rectangle> callable)
-
addPropertyChangeListener
public final void addPropertyChangeListener(java.beans.PropertyChangeListener l)
-
removePropertyChangeListener
public final void removePropertyChangeListener(java.beans.PropertyChangeListener l)
-
-