|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.mindfusion.diagramming.Pen
public class Pen
Pen objects are used to draw the borders and decoration lines of boxes, the
frame lines of tables and cells and the segments of arrows. A pen is
assigned to an item via the DiagramItem.setPen(com.mindfusion.diagramming.Pen)
method.
Constructor Summary | |
---|---|
Pen()
Initializes a new Pen instance. |
|
Pen(float width,
Brush brush)
Initializes a new Pen instance. |
|
Pen(float width,
java.awt.Color color)
Initializes a new Pen instance. |
|
Pen(float width,
java.awt.Color color,
DashStyle dashStyle)
Initializes a new Pen instance. |
Method Summary | |
---|---|
void |
applyTo(java.awt.Graphics2D g)
Sets the pen as the current pen for the specified Graphics2D object. |
void |
applyTo(java.awt.Graphics2D g,
java.awt.geom.Rectangle2D bounds)
Sets the pen as the current pen for the specified Graphics2D object. |
java.lang.Object |
clone()
Creates a copy of this pen. |
Brush |
getBrush()
Gets the color of this pen. |
java.awt.Color |
getColor()
Gets the color of this pen. |
DashStyle |
getDashStyle()
Gets the dash style of this pen. |
int |
getLineJoin()
|
float |
getWidth()
Gets the width of the lines drawn with this pen. |
void |
readExternal(java.io.ObjectInput in)
Implements Externalizable. |
void |
setBrush(Brush value)
Gets the color of this pen. |
void |
setColor(java.awt.Color value)
Sets the color of this pen. |
void |
setDashStyle(DashStyle value)
Sets the dash style of this pen. |
void |
setLineJoin(int value)
|
void |
setWidth(float value)
Sets what the width of the lines drawn with this pen should be. |
void |
writeExternal(java.io.ObjectOutput out)
Implements Externalizable. |
Methods inherited from class java.lang.Object |
---|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Pen()
public Pen(float width, java.awt.Color color)
width
- A float value representing the pen width.color
- A Color
object representing the pen color.public Pen(float width, Brush brush)
Pen
instance.
Instances of the Pen class created using this constructor
are currently not serialized.
width
- A float value representing the pen width.color
- A Brush
object representing the pen color.public Pen(float width, java.awt.Color color, DashStyle dashStyle)
width
- A float value representing the pen width.color
- A Color
object representing the pen color.dashStyle
- A DashStyle
object representing the pen's dash pattern.Method Detail |
---|
public void applyTo(java.awt.Graphics2D g)
public void applyTo(java.awt.Graphics2D g, java.awt.geom.Rectangle2D bounds)
public java.lang.Object clone()
clone
in class java.lang.Object
public Brush getBrush()
Brush
object representing the pen color.public void setBrush(Brush value)
value
- A Brush
object representing the pen color.public java.awt.Color getColor()
Color
object representing the pen color.public void setColor(java.awt.Color value)
value
- A Color
object representing the pen color.public float getWidth()
public void setWidth(float value)
value
- A float value representing the pen width.public DashStyle getDashStyle()
DashStyle
object representing the pen's dash pattern.public void setDashStyle(DashStyle value)
value
- A DashStyle
object representing the pen's dash pattern.public int getLineJoin()
public void setLineJoin(int value)
public void writeExternal(java.io.ObjectOutput out) throws java.io.IOException
writeExternal
in interface java.io.Externalizable
java.io.IOException
public void readExternal(java.io.ObjectInput in) throws java.io.IOException, java.lang.ClassNotFoundException
readExternal
in interface java.io.Externalizable
java.io.IOException
java.lang.ClassNotFoundException
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |