|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objecteu.webtoolkit.jwt.WPen
public class WPen
A value class that defines the style for pen strokes.
A pen defines the properties of how lines (that may surround shapes) are rendered.
A pen with width 0 is a cosmetic pen, and is always rendered as 1
pixel width, regardless of transformations. Otherwized, the pen width is
modified by the transformation set on
the painter.
WPainter.setPen(WPen p),
WBrush| Constructor Summary | |
|---|---|
WPen()
Creates a black cosmetic pen. |
|
WPen(PenStyle style)
Creates a black pen with a particular style. |
|
WPen(WColor color)
Creates a solid pen of a particular color. |
|
| Method Summary | |
|---|---|
WPen |
clone()
Clone method. |
boolean |
equals(WPen other)
Indicates whether some other object is "equal to" this one. |
PenCapStyle |
getCapStyle()
Returns the style for rendering line ends. |
WColor |
getColor()
Returns the pen color. |
PenJoinStyle |
getJoinStyle()
Returns the style for rendering line joins. |
PenStyle |
getStyle()
Returns the pen style. |
WLength |
getWidth()
Returns the pen width. |
void |
setCapStyle(PenCapStyle style)
Sets the style for rendering line ends. |
void |
setColor(WColor color)
Sets the pen color. |
void |
setJoinStyle(PenJoinStyle style)
Sets the style for rendering line joins. |
void |
setStyle(PenStyle style)
Sets the pen style. |
void |
setWidth(WLength width)
Sets the pen width. |
| Methods inherited from class java.lang.Object |
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public WPen()
Constructs a black solid pen of 0 width (i.e. cosmetic single pixel
width), with SquareCap line ends and
BevelJoin line join style.
public WPen(PenStyle style)
Constructs a black pen of 0 width (i.e. cosmetic single pixel width),
with SquareCap line ends and
BevelJoin line join style.
The line style is set to style.
public WPen(WColor color)
Constructs a solid pen of 0 width (i.e. cosmetic single pixel width),
with SquareCap line ends and
BevelJoin line join style.
The pen color is set to color.
| Method Detail |
|---|
public WPen clone()
Clones this pen.
clone in class java.lang.Objectpublic boolean equals(WPen other)
Returns true if the pens are exactly the same.
public void setStyle(PenStyle style)
getStyle()public PenStyle getStyle()
setStyle(PenStyle style)public void setCapStyle(PenCapStyle style)
getCapStyle()public PenCapStyle getCapStyle()
setCapStyle(PenCapStyle style)public void setJoinStyle(PenJoinStyle style)
getJoinStyle()public PenJoinStyle getJoinStyle()
setJoinStyle(PenJoinStyle style)public void setWidth(WLength width)
A pen width must be specified using
WLength.Unit.Pixel units.
getWidth()public WLength getWidth()
setWidth(WLength width)public void setColor(WColor color)
getColor()public WColor getColor()
getColor()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||