public class PenStroke extends BasicStroke implements Stroke
CAP_BUTT, CAP_ROUND, CAP_SQUARE, JOIN_BEVEL, JOIN_MITER, JOIN_ROUND
Constructor and Description |
---|
PenStroke(float width)
Constructs a solid
BasicStroke with the specified
line width and with default values for the cap and join
styles. |
Modifier and Type | Method and Description |
---|---|
Shape |
createStrokedShape(Shape s)
Returns a
Shape whose interior defines the
stroked outline of a specified Shape . |
equals, getDashArray, getDashPhase, getEndCap, getLineJoin, getLineWidth, getMiterLimit, hashCode
public PenStroke(float width)
BasicStroke
with the specified
line width and with default values for the cap and join
styles.width
- the width of the BasicStroke
IllegalArgumentException
- if width
is negativepublic final Shape createStrokedShape(Shape s)
Shape
whose interior defines the
stroked outline of a specified Shape
.createStrokedShape
in interface Stroke
createStrokedShape
in class BasicStroke
s
- the Shape
boundary be strokedShape
of the stroked outline.Copyright © 2024 Central Laboratory of the Research Councils. All Rights Reserved.