Class AbstractShapeModel
java.lang.Object
org.csstudio.opibuilder.model.AbstractWidgetModel
org.csstudio.opibuilder.model.AbstractPVWidgetModel
org.csstudio.opibuilder.widgets.model.AbstractShapeModel
- All Implemented Interfaces:
IPVWidgetModel,IAdaptable,IPropertySource
- Direct Known Subclasses:
AbstractPolyModel,ArcModel,EllipseModel,RectangleModel,RoundedRectangleModel
The abstract widget model for all shape based widgets.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringAlpha value.static final StringTrue if anti alias is enabled for the figure.static final StringThe widget can be filled with foreground color if this is not zero.static final StringTrue if fill direction is horizontal.static final StringColor of the line.static final StringStyle of the line.static final StringWidth of the line.static final StringTrue if background is transparent.Fields inherited from class org.csstudio.opibuilder.model.AbstractWidgetModel
PROP_ACTIONS, PROP_BORDER_COLOR, PROP_BORDER_STYLE, PROP_BORDER_WIDTH, PROP_COLOR_BACKGROUND, PROP_COLOR_FOREGROUND, PROP_ENABLED, PROP_FONT, PROP_HEIGHT, PROP_NAME, PROP_RULES, PROP_SCALE_OPTIONS, PROP_SCRIPTS, PROP_SRC_CONNECTIONS, PROP_TGT_CONNECTIONS, PROP_TOOLTIP, PROP_VISIBLE, PROP_WIDGET_TYPE, PROP_WIDGET_UID, PROP_WIDTH, PROP_XPOS, PROP_YPOS, VERSIONFields inherited from interface org.csstudio.opibuilder.model.IPVWidgetModel
PROP_ALARM_PULSING, PROP_BACKCOLOR_ALARMSENSITIVE, PROP_BORDER_ALARMSENSITIVE, PROP_FORECOLOR_ALARMSENSITIVE, PROP_PVNAME, PROP_PVVALUE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidConfigure the properties of the widget.intgetAlpha()doubleReturns the fill grade.intGets the style of the line.intGets the width of the line.final booleanbooleanbooleanReturns, if this widget should have a transparent background.voidsetFillLevel(double value) set the fill levelvoidsetHoizontalFill(boolean value) voidsetLineStyle(int style) voidsetLineWidth(int width) voidsetTransparent(boolean value) Methods inherited from class org.csstudio.opibuilder.model.AbstractPVWidgetModel
configureBaseProperties, getDelegate, getPVName, getTooltip, isAlarmPulsing, isBackColorAlarmSensitve, isBorderAlarmSensitve, isForeColorAlarmSensitve, processVersionDifferenceMethods inherited from class org.csstudio.opibuilder.model.AbstractWidgetModel
addConnection, addProperty, addProperty, addPVProperty, doScale, flipHorizontally, flipHorizontally, flipVertically, flipVertically, generateNewWUID, getActionsInput, getAdapter, getAllPropertyIDs, getBackgroundColor, getBorderColor, getBorderStyle, getBorderWidth, getBounds, getCastedPropertyValue, getEditableValue, getExecutionMode, getFont, getForegroundColor, getHeight, getIndex, getLocation, getName, getNestedDepth, getOriginLocation, getOriginSize, getParent, getProperty, getPropertyDescriptors, getPropertyValue, getPVMap, getRawPropertyValue, getRawTooltip, getRGBFromColorProperty, getRootDisplayModel, getRootDisplayModel, getRulesInput, getRuntimePropertyList, getScaledSize, getScaleOptions, getScriptsInput, getSize, getSourceConnections, getSWTColorFromColorProperty, getTargetConnections, getType, getTypeID, getVersion, getVersionOnFile, getWidgetType, getWidth, getWUID, getX, getY, isEnabled, isPropertySet, isVisible, removeProperty, removePVProperty, resetPropertyValue, rotate90, rotate90, scale, scaleConnections, setBackgroundColor, setBorderColor, setBorderStyle, setBorderWidth, setBounds, setBounds, setEnabled, setExecutionMode, setForegroundColor, setHeight, setLocation, setLocation, setName, setParent, setPropertyDescription, setPropertyValue, setPropertyValue, setPropertyVisible, setPropertyVisibleAndSavable, setScaleOptions, setSize, setSize, setTooltip, setVersionOnFile, setWidth, setX, setY
-
Field Details
-
PROP_LINE_WIDTH
Width of the line.- See Also:
-
PROP_LINE_STYLE
Style of the line.- See Also:
-
PROP_LINE_COLOR
Color of the line.- See Also:
-
PROP_FILL_LEVEL
The widget can be filled with foreground color if this is not zero. It must be a value between 0 to 100.- See Also:
-
PROP_HORIZONTAL_FILL
True if fill direction is horizontal.- See Also:
-
PROP_ANTIALIAS
True if anti alias is enabled for the figure.- See Also:
-
PROP_ALPHA
Alpha value.- See Also:
-
PROP_TRANSPARENT
True if background is transparent.- See Also:
-
-
Constructor Details
-
AbstractShapeModel
public AbstractShapeModel()
-
-
Method Details
-
configureProperties
protected void configureProperties()Description copied from class:AbstractWidgetModelConfigure the properties of the widget. Subclass should add new properties in this method.- Specified by:
configurePropertiesin classAbstractWidgetModel
-
isAntiAlias
public final boolean isAntiAlias()- Returns:
- true if the graphics's antiAlias is on.
-
getAlpha
public int getAlpha() -
getFillLevel
public double getFillLevel()Returns the fill grade.- Returns:
- the fill grade
-
setFillLevel
public void setFillLevel(double value) set the fill level- Parameters:
value-
-
isHorizontalFill
public boolean isHorizontalFill() -
setHoizontalFill
public void setHoizontalFill(boolean value) -
getLineWidth
public int getLineWidth()Gets the width of the line.- Returns:
- int The width of the line
-
setLineWidth
public void setLineWidth(int width) -
setLineStyle
public void setLineStyle(int style) - Parameters:
style- the integer value corresponding toLineStyle
-
getLineStyle
public int getLineStyle()Gets the style of the line.- Returns:
- int The style of the line
-
getLineColor
-
isTransparent
public boolean isTransparent()Returns, if this widget should have a transparent background.- Returns:
- boolean True, if it should have a transparent background, false otherwise
-
setTransparent
public void setTransparent(boolean value)
-