public class RJHelper
extends java.lang.Object
Constructor and Description |
---|
RJHelper() |
Modifier and Type | Method and Description |
---|---|
void |
add(javax.swing.JComponent aComponent,
javax.swing.JComponent aChild)
Adds a child into the parent's component heirarchy.
|
void |
focusGained(javax.swing.JComponent aComponent,
java.awt.event.FocusEvent fe)
Called by default focus listener when the component gains focus.
|
void |
focusLost(javax.swing.JComponent aComponent,
java.awt.event.FocusEvent fe)
Called by the default focus listener when focus is lost on a component,
but before any action is fired.
|
void |
fromXML(javax.swing.JComponent aComponent,
RXArchiver anArchiver,
RXElement anElement)
XML unarchival utility method.
|
void |
fromXMLDeep(javax.swing.JComponent aComponent,
RXArchiver anArchiver,
RXElement anElement)
XML unarchival utility method.
|
javax.swing.JComponent |
get(javax.swing.JComponent aComponent,
java.lang.String aName)
Returns the given component or any of its children that have the give name.
|
java.awt.event.ActionListener |
getActionListener()
Returns an action listener suitable for many controls.
|
java.lang.Boolean |
getAutoscrolls(javax.swing.JComponent aComponent)
Returns whether a component autoscrolls if explicitly set, null otherwise.
|
java.lang.String |
getAutosizing(javax.swing.JComponent aComponent)
Returns the autosizing for the given component.
|
java.awt.Color |
getBackground(javax.swing.JComponent aComponent)
Returns the given component's background color if explicitly set, otherwise null.
|
java.lang.String |
getBindKey(javax.swing.JComponent aComponent)
Returns this component's bind key chain.
|
java.lang.Boolean |
getBooleanValue(javax.swing.JComponent aComponent)
Returns a component's value as a Boolean.
|
boolean |
getBoolValue(javax.swing.JComponent aComponent)
Returns a component's value as a boolean.
|
java.lang.String |
getCallback(javax.swing.JComponent aComponent)
Returns given component's callback method (respondUI is the default).
|
javax.swing.event.ChangeListener |
getChangeListener()
Returns a change listener suitable for some controls.
|
java.awt.Color |
getColorValue(javax.swing.JComponent aComponent)
Returns a component's value as color.
|
javax.swing.JComponent |
getComponent(javax.swing.JComponent aComponent,
int anIndex)
Returns the Ribs-relevant child component at the given index.
|
int |
getComponentCount(javax.swing.JComponent aComponent)
Returns the Ribs-relevant child component count.
|
float |
getFloatValue(javax.swing.JComponent aComponent)
Returns a component's value as a float.
|
java.awt.event.FocusListener |
getFocusListener()
Returns a focus listener suitable for the occasional control.
|
java.awt.Color |
getForeground(javax.swing.JComponent aComponent)
Returns the given component's foreground color if explicitly set, otherwise null.
|
int |
getIntValue(javax.swing.JComponent aComponent)
Returns a component's value as an int.
|
RJPanel |
getMaster(javax.swing.JComponent aComponent)
Returns the top level panel of the rib file (the one that given component was loaded from).
|
java.awt.Dimension |
getMaximumSize(javax.swing.JComponent aComponent)
Returns null unless the maximum size has explicitly been set by the
user, in which case it uses the component's maximum size.
|
java.awt.Dimension |
getMinimumSize(javax.swing.JComponent aComponent)
Returns null unless the minimum size has explicitly been set by the
user, in which case it uses the component's minimum size.
|
java.lang.Object |
getOwner(javax.swing.JComponent aComponent)
Returns given component's owner.
|
int |
getRibHeight(javax.swing.JComponent aComponent)
Returns the original height of the given component as defined in the rib file.
|
int |
getRibWidth(javax.swing.JComponent aComponent)
Returns the original width of the given component as defined in the rib file.
|
int |
getRibX(javax.swing.JComponent aComponent)
Returns the original X of the given component as defined in the rib file.
|
int |
getRibY(javax.swing.JComponent aComponent)
Returns the original Y of the given component as defined in the rib file.
|
boolean |
getSendActionOnFocusLost(javax.swing.JComponent aComponent)
Returns whether this component sends action when it loses focus.
|
java.lang.String |
getStringValue(javax.swing.JComponent aComponent)
Returns a component's value as a string.
|
java.lang.String |
getSubstitutionClassString(javax.swing.JComponent aComponent)
Returns the subclass string for the given component.
|
java.lang.Object |
getValue(javax.swing.JComponent aComponent)
Returns a component's value.
|
void |
initInstance(javax.swing.JComponent aComponent)
Initializes the given instance (actually called the first time an owner is set).
|
java.lang.Boolean |
isOpaque(javax.swing.JComponent aComponent)
Returns component's opacity if explicitly set, null otherwise.
|
java.lang.Object |
newInstance(RXElement anElement)
Creates a new instance of class for given element.
|
void |
performBindKeyGet(javax.swing.JComponent aComponent)
Performs bind key get.
|
void |
performBindKeySet(javax.swing.JComponent aComponent)
Performs bind key set.
|
void |
sendAction(javax.swing.JComponent aComponent,
RJAction anAction)
Sends action for the given component.
|
void |
setAutoscrolls(javax.swing.JComponent aComponent,
java.lang.Boolean aValue)
Sets whether a component autoscrolls and client property (so we know it was explicitly set).
|
void |
setAutosizing(javax.swing.JComponent aComponent,
java.lang.String aValue)
Sets the autosizing for the given component.
|
void |
setBackground(javax.swing.JComponent aComponent,
java.awt.Color aColor)
Sets the given component's background color and client property (so we know it was explicitly set).
|
void |
setBindKey(javax.swing.JComponent aComponent,
java.lang.String aBindKey)
Sets this component's bind key chain.
|
void |
setCallback(javax.swing.JComponent aComponent,
java.lang.String aCallback)
Sets given component's callback method (respondUI is the default).
|
void |
setForeground(javax.swing.JComponent aComponent,
java.awt.Color aColor)
Sets the given component's foreground color and client property (so we know it was explicitly set).
|
void |
setMaster(javax.swing.JComponent aComponent,
RJPanel aMaster)
Sets the top level panel of this rib file (the one that the given component was loaded from).
|
void |
setMaximumSize(javax.swing.JComponent aComponent,
java.awt.Dimension max)
Sets the maximum size for a component and records the fact that we've changed it.
|
void |
setMinimumSize(javax.swing.JComponent aComponent,
java.awt.Dimension min)
Sets the minimum size for a component and records the fact that we've changed it.
|
void |
setOpaque(javax.swing.JComponent aComponent,
java.lang.Boolean aValue)
Set component's opacity and client property (so we know it was explicitly set).
|
void |
setOwner(javax.swing.JComponent aComponent,
java.lang.Object anOwner)
Sets given component's owner.
|
void |
setSendActionOnFocusLost(javax.swing.JComponent aComponent,
boolean aValue)
Sets whether this text field sends action when it loses focus.
|
void |
setSubstitutionClassString(javax.swing.JComponent aComponent,
java.lang.String aClassString)
Sets the subclass string for the given component.
|
void |
setValue(javax.swing.JComponent aComponent,
boolean aValue)
Sets a component's value from given boolean.
|
void |
setValue(javax.swing.JComponent aComponent,
java.lang.Boolean aValue)
Sets a component's value from given Boolean.
|
void |
setValue(javax.swing.JComponent aComponent,
java.awt.Color aValue)
Sets a component's value from given Color.
|
void |
setValue(javax.swing.JComponent aComponent,
float aValue)
Sets a component's value from given float.
|
void |
setValue(javax.swing.JComponent aComponent,
int aValue)
Sets a component's value from given int.
|
void |
setValue(javax.swing.JComponent aComponent,
java.lang.Object aValue)
Sets a component's value.
|
void |
setValue(javax.swing.JComponent aComponent,
java.lang.String aValue)
Sets a component's value from given string.
|
void |
takeFloatValue(javax.swing.JComponent aComponent,
javax.swing.JComponent aCaller)
A generic callback method for component to component callbacks.
|
void |
takeIntValue(javax.swing.JComponent aComponent,
javax.swing.JComponent aCaller)
A generic callback method for component to component callbacks.
|
void |
testOutBeanBag(javax.swing.JComponent c) |
RXElement |
toXML(javax.swing.JComponent aComponent,
RXArchiver anArchiver)
XML archival utility method.
|
void |
toXMLDeep(javax.swing.JComponent aComponent,
RXArchiver anArchiver,
RXElement anElement)
XML archival utility method.
|
public java.lang.Object newInstance(RXElement anElement)
public void initInstance(javax.swing.JComponent aComponent)
public int getComponentCount(javax.swing.JComponent aComponent)
public javax.swing.JComponent getComponent(javax.swing.JComponent aComponent, int anIndex)
public javax.swing.JComponent get(javax.swing.JComponent aComponent, java.lang.String aName)
public void add(javax.swing.JComponent aComponent, javax.swing.JComponent aChild)
public java.lang.Object getOwner(javax.swing.JComponent aComponent)
public void setOwner(javax.swing.JComponent aComponent, java.lang.Object anOwner)
public RJPanel getMaster(javax.swing.JComponent aComponent)
public void setMaster(javax.swing.JComponent aComponent, RJPanel aMaster)
public java.lang.String getCallback(javax.swing.JComponent aComponent)
public void setCallback(javax.swing.JComponent aComponent, java.lang.String aCallback)
public java.lang.String getBindKey(javax.swing.JComponent aComponent)
public void setBindKey(javax.swing.JComponent aComponent, java.lang.String aBindKey)
public void sendAction(javax.swing.JComponent aComponent, RJAction anAction)
public void performBindKeyGet(javax.swing.JComponent aComponent)
public void performBindKeySet(javax.swing.JComponent aComponent)
public java.lang.String getSubstitutionClassString(javax.swing.JComponent aComponent)
public void setSubstitutionClassString(javax.swing.JComponent aComponent, java.lang.String aClassString)
public java.lang.String getAutosizing(javax.swing.JComponent aComponent)
public void setAutosizing(javax.swing.JComponent aComponent, java.lang.String aValue)
public int getRibX(javax.swing.JComponent aComponent)
public int getRibY(javax.swing.JComponent aComponent)
public int getRibWidth(javax.swing.JComponent aComponent)
public int getRibHeight(javax.swing.JComponent aComponent)
public void setMinimumSize(javax.swing.JComponent aComponent, java.awt.Dimension min)
public java.awt.Dimension getMinimumSize(javax.swing.JComponent aComponent)
public void setMaximumSize(javax.swing.JComponent aComponent, java.awt.Dimension max)
public java.awt.Dimension getMaximumSize(javax.swing.JComponent aComponent)
public java.lang.Object getValue(javax.swing.JComponent aComponent)
public void setValue(javax.swing.JComponent aComponent, java.lang.Object aValue)
public java.lang.String getStringValue(javax.swing.JComponent aComponent)
public void setValue(javax.swing.JComponent aComponent, java.lang.String aValue)
public java.lang.Boolean getBooleanValue(javax.swing.JComponent aComponent)
public void setValue(javax.swing.JComponent aComponent, java.lang.Boolean aValue)
public boolean getBoolValue(javax.swing.JComponent aComponent)
public void setValue(javax.swing.JComponent aComponent, boolean aValue)
public int getIntValue(javax.swing.JComponent aComponent)
public void setValue(javax.swing.JComponent aComponent, int aValue)
public float getFloatValue(javax.swing.JComponent aComponent)
public void setValue(javax.swing.JComponent aComponent, float aValue)
public java.awt.Color getColorValue(javax.swing.JComponent aComponent)
public void setValue(javax.swing.JComponent aComponent, java.awt.Color aValue)
public java.awt.event.ActionListener getActionListener()
public javax.swing.event.ChangeListener getChangeListener()
public java.awt.event.FocusListener getFocusListener()
public java.lang.Boolean getAutoscrolls(javax.swing.JComponent aComponent)
public void setAutoscrolls(javax.swing.JComponent aComponent, java.lang.Boolean aValue)
public java.awt.Color getForeground(javax.swing.JComponent aComponent)
public void setForeground(javax.swing.JComponent aComponent, java.awt.Color aColor)
public java.awt.Color getBackground(javax.swing.JComponent aComponent)
public void setBackground(javax.swing.JComponent aComponent, java.awt.Color aColor)
public java.lang.Boolean isOpaque(javax.swing.JComponent aComponent)
public void setOpaque(javax.swing.JComponent aComponent, java.lang.Boolean aValue)
public void focusGained(javax.swing.JComponent aComponent, java.awt.event.FocusEvent fe)
public void focusLost(javax.swing.JComponent aComponent, java.awt.event.FocusEvent fe)
public boolean getSendActionOnFocusLost(javax.swing.JComponent aComponent)
public void setSendActionOnFocusLost(javax.swing.JComponent aComponent, boolean aValue)
public void takeIntValue(javax.swing.JComponent aComponent, javax.swing.JComponent aCaller)
public void takeFloatValue(javax.swing.JComponent aComponent, javax.swing.JComponent aCaller)
public RXElement toXML(javax.swing.JComponent aComponent, RXArchiver anArchiver)
public void toXMLDeep(javax.swing.JComponent aComponent, RXArchiver anArchiver, RXElement anElement)
public void fromXML(javax.swing.JComponent aComponent, RXArchiver anArchiver, RXElement anElement)
public void fromXMLDeep(javax.swing.JComponent aComponent, RXArchiver anArchiver, RXElement anElement)
public void testOutBeanBag(javax.swing.JComponent c)