java.awt
Interface Stroke

All Known Implementing Classes:
BasicStroke

public interface Stroke

This interface allows a Graphics2D to grab the outline of a shape, as if stroked by a marking pen of appropriate size and shape. The area inked by the pen is the area of this stroke. Anything in the graphic which traces an outline will use this stroke, such as drawLine. Strokes must be immutable, because the graphics object does not clone them.

Since:
1.1
See Also:
BasicStroke, Graphics2D.setStroke(Stroke)

Method Summary
 Shape createStrokedShape(Shape s)
          Returns a shape which outlines the boundary of the given shape, in effect converting the infinitely thin line into a new shape.
 

Method Detail

createStrokedShape

Shape createStrokedShape(Shape s)
Returns a shape which outlines the boundary of the given shape, in effect converting the infinitely thin line into a new shape.

Parameters:
s - the shape to stroke
Returns:
the stroked outline shape