sgtplot
Class PointAttribute
- java.lang.Object
-
- sgtplot.PointAttribute
-
- All Implemented Interfaces:
- java.io.Serializable, java.lang.Cloneable, Attribute
public class PointAttribute extends java.lang.Object implements Attribute, java.lang.Cloneable
Set the rendereing style for point data.Color, width, and mark type arePointAttributeproperties.- Since:
- 1.0
- See Also:
CartesianGraph,PointCartesianRenderer,PlotMark, Serialized Form
-
-
Field Summary
Fields Modifier and Type Field and Description static intCENTEREDPosition label over the pointstatic intEPosition label east of the pointstatic intNPosition label north of the pointstatic intNEPosition label northeast of the pointstatic intNWPosition label northwest of the pointstatic intSPosition label south of the pointstatic intSEPosition label southeast of the pointstatic intSWPosition label southwest of the pointstatic intWPosition label west of the point
-
Constructor Summary
Constructors Constructor and Description PointAttribute()Default constructor.PointAttribute(int mark, java.awt.Color color)Constructor for plot marks.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description voidaddPropertyChangeListener(java.beans.PropertyChangeListener listener)Add listener to changes inPointAttributeproperties.PointAttributecopy()Copy thePointAttribute.booleanequals(java.lang.Object obj)java.awt.ColorgetColor()Get PointColor.java.lang.StringgetId()Get attribute id.java.awt.ColorgetLabelColor()Get labelColor.java.awt.FontgetLabelFont()Get labelFont.doublegetLabelHeightP()Get label height.intgetLabelPosition()Get label position.intgetMark()Get plot markdoublegetMarkHeightP()Get mark heightdoublegetWidthP()Get Point width.booleanisBatch()Is the attribute in batch mode?booleanisDrawLabel()Is label drawing on?voidremovePropertyChangeListener(java.beans.PropertyChangeListener listener)Remove change listener.voidsetBatch(boolean batch)Batch the changes to the attribute.voidsetBatch(boolean batch, boolean local)Batch the changes to the attribute and set local flag.voidsetColor(java.awt.Color c)Set the pointColor.voidsetDrawLabel(boolean dl)Set label drawing.voidsetId(java.lang.String id)Set attribute id.voidsetLabelColor(java.awt.Color col)Set labelColor.voidsetLabelFont(java.awt.Font font)Set labelFont.voidsetLabelHeightP(double h)Set label height.voidsetLabelPosition(int pos)Set label position.voidsetMark(int mark)Set plot mark
Property Change:mark.voidsetMarkHeightP(double markh)Set mark height.voidsetWidthP(double t)Set the Point width in physical units.java.lang.StringtoString()Get aStringrepresentation of thePointAttribute.
-
-
-
Field Detail
-
CENTERED
public static final int CENTERED
Position label over the point- See Also:
- Constant Field Values
-
N
public static final int N
Position label north of the point- See Also:
- Constant Field Values
-
NE
public static final int NE
Position label northeast of the point- See Also:
- Constant Field Values
-
E
public static final int E
Position label east of the point- See Also:
- Constant Field Values
-
SE
public static final int SE
Position label southeast of the point- See Also:
- Constant Field Values
-
S
public static final int S
Position label south of the point- See Also:
- Constant Field Values
-
SW
public static final int SW
Position label southwest of the point- See Also:
- Constant Field Values
-
W
public static final int W
Position label west of the point- See Also:
- Constant Field Values
-
NW
public static final int NW
Position label northwest of the point- See Also:
- Constant Field Values
-
-
Constructor Detail
-
PointAttribute
public PointAttribute()
Default constructor. Default mark is 2 and default color is red.
-
PointAttribute
public PointAttribute(int mark, java.awt.Color color)Constructor for plot marks.- Parameters:
mark- plot markcolor- Point color- See Also:
PlotMark
-
-
Method Detail
-
copy
public PointAttribute copy()
Copy thePointAttribute.- Returns:
- new
PointAttribute
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equalsin classjava.lang.Object- Since:
- 3.0
-
setMarkHeightP
public void setMarkHeightP(double markh)
Set mark height.
Property Change:markHeightP.- Parameters:
markh- mark height
-
getMarkHeightP
public double getMarkHeightP()
Get mark height- Returns:
- mark height
-
setColor
public void setColor(java.awt.Color c)
Set the pointColor.
Property Change:color.- Parameters:
c- pointColor
-
setWidthP
public void setWidthP(double t)
Set the Point width in physical units.
Property Change:widthP.- Parameters:
t- Point width
-
getColor
public java.awt.Color getColor()
Get PointColor.- Returns:
- Point
Color
-
getWidthP
public double getWidthP()
Get Point width.- Returns:
- Point width in physcial coordinates.
-
setMark
public void setMark(int mark)
Set plot mark
Property Change:mark.- Parameters:
mark- the plot mark- See Also:
PlotMark
-
getMark
public int getMark()
Get plot mark- Returns:
- plot mark
- See Also:
PlotMark
-
setLabelPosition
public void setLabelPosition(int pos)
Set label position.
Property Change:labelPosition.
-
getLabelPosition
public int getLabelPosition()
Get label position.
-
setLabelColor
public void setLabelColor(java.awt.Color col)
Set labelColor.
Property Change:labelColor.
-
getLabelColor
public java.awt.Color getLabelColor()
Get labelColor.
-
setLabelFont
public void setLabelFont(java.awt.Font font)
Set labelFont.
Property Change:labelFont.
-
getLabelFont
public java.awt.Font getLabelFont()
Get labelFont.
-
setLabelHeightP
public void setLabelHeightP(double h)
Set label height.
Property Change:labelHeightP.
-
getLabelHeightP
public double getLabelHeightP()
Get label height.
-
setDrawLabel
public void setDrawLabel(boolean dl)
Set label drawing.
Property Change:drawLabel.
-
isDrawLabel
public boolean isDrawLabel()
Is label drawing on?
-
toString
public java.lang.String toString()
Get aStringrepresentation of thePointAttribute.
-
addPropertyChangeListener
public void addPropertyChangeListener(java.beans.PropertyChangeListener listener)
Add listener to changes inPointAttributeproperties.- Specified by:
addPropertyChangeListenerin interfaceAttribute
-
removePropertyChangeListener
public void removePropertyChangeListener(java.beans.PropertyChangeListener listener)
Description copied from interface:AttributeRemove change listener.- Specified by:
removePropertyChangeListenerin interfaceAttribute
-
setId
public void setId(java.lang.String id)
Description copied from interface:AttributeSet attribute id.
-
getId
public java.lang.String getId()
Description copied from interface:AttributeGet attribute id.
-
setBatch
public void setBatch(boolean batch)
Description copied from interface:AttributeBatch the changes to the attribute.
-
setBatch
public void setBatch(boolean batch, boolean local)Description copied from interface:AttributeBatch the changes to the attribute and set local flag. Determines whetherAttributeChangeEventwill be set local.
-
-
DMelt 3.0 © DataMelt by jWork.ORG