Class LabeledShape
- All Implemented Interfaces:
Archivable
,DeepChangeListener
,RMPropertyChanger
,RMTypes
,PropertyChangeListener
,Cloneable
,EventListener
- Direct Known Subclasses:
AbstractButtonShape
,JLabelShape
A JComponentShape subclass for Labeled JComponents (JLabel, AbstractButton).
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.inductiveautomation.rm.base.RMTypes
RMTypes.Align, RMTypes.AlignX, RMTypes.AlignY
-
Field Summary
Fields inherited from class com.inductiveautomation.rm.shape.RMShape
BINDING_PROP_NAME, STROKE_BORDER, STROKE_DOUBLE, STROKE_HIDDEN, STROKE_SHAPE
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionboolean
Declare this for editing.protected void
configureComponent
(JBuilder aBldr, JComponent aComp) Override to apply subclass attributes.protected void
fromXMLShape
(RXArchiver anArchiver, RXElement anElement) XML unarchival.Returns the horizontal alignment.Returns the vertical alignment.int
Returns the HorizontalAlignment.int
Returns the default HorizontalAlignment.static Integer
getHorizontalAlignmentInt
(String aString) Sets the horizontal alignment of the given component as a string ("left", "center" or "right").static String
getHorizontalAlignmentString
(int anInt) Returns the horizontal alignment of the given component as a string ("left", "center" or "right").int
Returns the HorizontalTextPosition.static Integer
getHorizontalTextPositionInt
(String aString) Sets the label's horizontal text position as a string.static String
getHorizontalTextPositionString
(int anInt) Returns the labels horizontal text position as a string.getIcon()
Returns the icon.protected Icon
Returns an icon for given name.int
Returns the IconTextGap.Returns the image WebFile.getImageFile
(String aName) Returns the image WebFile.Returns the image name.getText()
Returns the text.int
Returns the VerticalAlignment.int
Returns the default VerticalAlignment.static Integer
getVerticalAlignmentInt
(String aString) Sets the vertical alignment of the given component as a string ("top", "center" or "bottom").static String
getVerticalAlignmentString
(int anInt) Returns the vertical alignment of the given component as a string ("top", "center" or "bottom").int
Returns the VerticalTextPosition.static Integer
getVerticalTextPositionInt
(String aString) Sets the label's vertical text position as a string.static String
getVerticalTextPositionString
(int anInt) Returns the labels vertical text position as a string.void
setAlignmentX
(RMTypes.AlignX anAlignX) Sets the alignment x.void
setAlignmentY
(RMTypes.AlignY anAlignY) Sets the alignment x.void
setHorizontalAlignment
(int aValue) Sets the HorizontalAlignment.void
setHorizontalTextPosition
(int aValue) Sets the HorizontalTextPosition.void
Sets the icon.void
setIconTextGap
(int aValue) Sets the IconTextGap.void
setImageName
(String aName) Sets the image name.void
Sets the text.void
setVerticalAlignment
(int aValue) Sets the VerticalAlignment.void
setVerticalTextPosition
(int aValue) Sets the VerticalTextPosition.protected RXElement
toXMLShape
(RXArchiver anArchiver) XML archival.Methods inherited from class com.inductiveautomation.rm.swing.shape.JComponentShape
acceptsMouse, clone, createComponent, createComponentDeep, dispatchEventToComponent, firePropertyChange, getAction, getAutoscrolls, getBackground, getBorder, getClientProperty, getComponent, getComponentClass, getFont, getForeground, getItemDisplayKey, getRealClassName, getSendActionOnFocusLost, getToolTipText, isEnabled, isFontSet, isOpaque, mouseClicked, mouseDragged, mouseEntered, mouseExited, mouseMoved, mousePressed, mouseReleased, paintShape, putClientProperty, setAction, setAutoscrolls, setBackground, setBorder, setEnabled, setFont, setForeground, setItemDisplayKey, setOpaque, setRealClassName, setSendActionOnFocusLost, setToolTipText, toXMLChildren
Methods inherited from class com.inductiveautomation.rm.shape.RMParentShape
addChild, addChild, addChild, addChild, addLayoutChild, bringShapesToFront, cloneDeep, computePrefHeight, computePrefWidth, divideShapeFromTop, fromXML, fromXMLChildren, getBoundsOfChildren, getChild, getChildArray, getChildContaining, getChildCount, getChildLast, getChildren, getChildrenIntersecting, getChildrenWithClass, getChildrenWithClass, getChildWithClass, getChildWithName, getLayout, getNeedsLayout, getSourceURL, indexOfChild, isHittable, isShowing, isSourceURLSet, layout, layoutChildren, relayout, removeChild, removeChild, removeChildren, removeLayoutChild, rpgAll, rpgChildren, sendShapesToBack, setHeight, setLayout, setNeedsLayout, setSourceURL, setWidth, toXML
Methods inherited from class com.inductiveautomation.rm.shape.RMShape
acceptsChildren, addBinding, addBinding, addDeepChangeListener, addMouseListener, animUpdate, bounds, contains, convertedPointFromShape, convertedPointToShape, convertedRectFromShape, convertedRectToShape, convertedVectorFromShape, convertedVectorToShape, convertFromShape, convertPathFromShape, convertPathToShape, convertPointFromShape, convertPointToShape, convertRectFromShape, convertRectToShape, convertToShape, convertVectorFromShape, convertVectorToShape, copyShape, createDivideShapeRemainder, deepChange, divideShapeFromEdge, get, get, getAlignment, getAncestor, getAncestorCount, getAncestorInCommon, getAnimator, getAnimator, getAutosizing, getAutosizingDefault, getBestHeight, getBestHeight, getBestWidth, getBestWidth, getBinding, getBinding, getBindingCount, getBindings, getBounds, getBoundsInside, getBoundsMarked, getBoundsMarkedDeep, getChildAnimator, getChildAnimator, getChildClipShape, getClipShape, getColor, getDashArrayString, getDashPhase, getDatasetEntity, getDatasetKey, getDisplayedFill, getDisplayedStroke, getDocument, getEffect, getEventAdapter, getFill, getFormat, getFrame, getFrameHeight, getFrameMaxX, getFrameMaxY, getFrameWidth, getFrameX, getFrameXY, getFrameY, getHeight, getHover, getLayoutInfo, getMaskPath, getMaxX, getMaxY, getMinHeight, getMinHeight, getMinWidth, getMinWidth, getName, getOpacity, getOpacityDeep, getOutline, getPageBreak, getPageBreakMax, getPageBreakPage, getPageBreakPageMax, getPageShape, getParent, getParent, getPath, getPathInBounds, getPrefHeight, getPrefHeight, getPrefWidth, getPrefWidth, getPropertyNameMapped, getPropertyNames, getPropertyNames, getRoll, getRootShape, getRSS, getScaleX, getScaleY, getShapesToAncestor, getShapesToDescendant, getShapesToShape, getSize, getSkewX, getSkewY, getStroke, getStrokeColor, getStrokeOnTop, getStrokeStyle, getStrokeWidth, getTextColor, getTimeline, getTimeline, getTransform, getTransformFromShape, getTransformInverse, getTransformToShape, getUndoer, getURL, getVisbileBounds, getVisibleBounds, getVisibleBounds, getVisibleBounds, getWidth, getX, getXY, getXYP, getY, height, indexOf, intersects, isAncestor, isAnimProperty, isDeletable, isDescendant, isEditing, isEnabled, isHittable, isLocked, isMinHeightSet, isMinWidthSet, isPrefHeightSet, isPrefWidthSet, isRoot, isRSS, isShowing, isUnderlined, isUseFill, isUseStroke, isViewing, isVisible, offsetXY, page, pageMax, paint, paintShapeAll, paintShapeChildren, paintShapeOver, propertyChange, put, removeBinding, removeBinding, removeDeepChangeListener, removeFromParent, removeMouseListener, repaint, repaint, resolvePageReferences, rpgBindings, rpgShape, setAlignment, setAutosizing, setBestHeight, setBestSize, setBounds, setBounds, setColor, setDashArrayString, setDashPhase, setEffect, setEnabled, setFill, setFormat, setFrame, setFrame, setFrameSize, setFrameX, setFrameXY, setFrameXY, setFrameY, setHover, setLayoutInfo, setLocked, setMinHeight, setMinSize, setMinWidth, setName, setOpacity, setOutline, setParent, setPrefHeight, setPrefWidth, setRoll, setScaleX, setScaleXY, setScaleY, setShowing, setSize, setSize, setSkewX, setSkewXY, setSkewY, setStroke, setStrokeColor, setStrokeStyle, setStrokeWidth, setTextColor, setTime, setTimeline, setUnderlined, setURL, setUseFill, setUseStroke, setVisible, setX, setXY, setXY, setXYP, setY, shapeHidden, shapeShown, superSelectable, toString, undoerDisable, undoerEnable, undoerSetUndoTitle, width, x, y
Methods inherited from class com.inductiveautomation.rm.base.RMObject
addPropertyChangeListener, firePropertyChange, firePropertyChange, getPCEvent, removePropertyChangeListener, sendPropertyChange
Methods inherited from class com.inductiveautomation.rm.base.RMListenerList
addListener, getListener, getListenerCount, getListenerCount, getListenerList, getListeners, hasListeners, removeListener
-
Constructor Details
-
LabeledShape
public LabeledShape()
-
-
Method Details
-
getText
Returns the text. -
setText
Sets the text. -
getImageName
Returns the image name. -
setImageName
Sets the image name. -
getImageFile
Returns the image WebFile. -
getImageFile
Returns the image WebFile. -
getHorizontalAlignment
public int getHorizontalAlignment()Returns the HorizontalAlignment. -
setHorizontalAlignment
public void setHorizontalAlignment(int aValue) Sets the HorizontalAlignment. -
getHorizontalAlignmentDefault
public int getHorizontalAlignmentDefault()Returns the default HorizontalAlignment. -
getAlignmentX
Returns the horizontal alignment.- Overrides:
getAlignmentX
in classRMShape
-
setAlignmentX
Sets the alignment x.- Overrides:
setAlignmentX
in classRMShape
-
getVerticalAlignment
public int getVerticalAlignment()Returns the VerticalAlignment. -
setVerticalAlignment
public void setVerticalAlignment(int aValue) Sets the VerticalAlignment. -
getVerticalAlignmentDefault
public int getVerticalAlignmentDefault()Returns the default VerticalAlignment. -
getAlignmentY
Returns the vertical alignment.- Overrides:
getAlignmentY
in classRMShape
-
setAlignmentY
Sets the alignment x.- Overrides:
setAlignmentY
in classRMShape
-
getHorizontalTextPosition
public int getHorizontalTextPosition()Returns the HorizontalTextPosition. -
setHorizontalTextPosition
public void setHorizontalTextPosition(int aValue) Sets the HorizontalTextPosition. -
getVerticalTextPosition
public int getVerticalTextPosition()Returns the VerticalTextPosition. -
setVerticalTextPosition
public void setVerticalTextPosition(int aValue) Sets the VerticalTextPosition. -
getIconTextGap
public int getIconTextGap()Returns the IconTextGap. -
setIconTextGap
public void setIconTextGap(int aValue) Sets the IconTextGap. -
getHorizontalAlignmentString
Returns the horizontal alignment of the given component as a string ("left", "center" or "right"). -
getHorizontalAlignmentInt
Sets the horizontal alignment of the given component as a string ("left", "center" or "right"). -
getVerticalAlignmentString
Returns the vertical alignment of the given component as a string ("top", "center" or "bottom"). -
getVerticalAlignmentInt
Sets the vertical alignment of the given component as a string ("top", "center" or "bottom"). -
getHorizontalTextPositionString
Returns the labels horizontal text position as a string. -
getHorizontalTextPositionInt
Sets the label's horizontal text position as a string. -
getVerticalTextPositionString
Returns the labels vertical text position as a string. -
getVerticalTextPositionInt
Sets the label's vertical text position as a string. -
getIcon
Returns the icon. -
setIcon
Sets the icon. -
configureComponent
Override to apply subclass attributes.- Overrides:
configureComponent
in classJComponentShape
-
getIcon
Returns an icon for given name. -
childrenSuperSelectImmediately
public boolean childrenSuperSelectImmediately()Declare this for editing.- Overrides:
childrenSuperSelectImmediately
in classRMShape
-
toXMLShape
XML archival.- Overrides:
toXMLShape
in classJComponentShape
-
fromXMLShape
XML unarchival.- Overrides:
fromXMLShape
in classJComponentShape
-