Stroke interface allows a {@link Graphics2D} object to obtain a {@link Shape} that is thedecorated outline, or stylistic representation of the outline, of the specified Shape. Stroking a Shape is like tracing its outline with a marking pen of the appropriate size and shape. The area where the pen would place ink is the area enclosed by the outline Shape. The methods of the Graphics2D interface that use the outline Shape returned by a Stroke object include draw and any other methods that are implemented in terms of that method, such as drawLine, drawRect, drawRoundRect, drawOval, drawArc, drawPolyline, and drawPolygon.
The objects of the classes implementing Stroke must be read-only because Graphics2D does not clone these objects either when they are set as an attribute with the setStroke method or when the Graphics2D object is itself cloned. If a Stroke object is modified after it is set in the Graphics2D context then the behavior of subsequent rendering would be undefined.
@see BasicStroke
@see Graphics2D#setStroke
dispose() method.
Stroke interface allows a {@link Graphics2D} object to obtain a {@link Shape} that is the decorated outline, or stylistic representation of the outline, of the specified Shape. Stroking a Shape is like tracing its outline with a marking pen of the appropriate size and shape. The area where the pen would place ink is the area enclosed by the outline Shape. The methods of the Graphics2D interface that use the outline Shape returned by a Stroke object include draw and any other methods that are implemented in terms of that method, such as drawLine, drawRect, drawRoundRect, drawOval, drawArc, drawPolyline, and drawPolygon.
The objects of the classes implementing Stroke must be read-only because Graphics2D does not clone these objects either when they are set as an attribute with the setStroke method or when the Graphics2D object is itself cloned. If a Stroke object is modified after it is set in the Graphics2D context then the behavior of subsequent rendering would be undefined.
@see BasicStroke
@see Graphics2D#setStroke
@version 1.23, 11/17/05
<xsd:element name="Stroke"> <xsd:annotation> <xsd:documentation> A "Stroke" specifies the appearance of a linear geometry. It is defined in parallel with SVG strokes. The following CssParameters may be used: "stroke" (color), "stroke-opacity", "stroke-width", "stroke-linejoin", "stroke-linecap", "stroke-dasharray", and "stroke-dashoffset". </xsd:documentation> </xsd:annotation> <xsd:complexType> <xsd:sequence> <xsd:choice minOccurs="0"> <xsd:element ref="sld:GraphicFill"/> <xsd:element ref="sld:GraphicStroke"/> </xsd:choice> <xsd:element ref="sld:CssParameter" minOccurs="0" maxOccurs="unbounded"/> </xsd:sequence> </xsd:complexType> </xsd:element> Renderers can use this information when displaying styled features, though it must be remembered that not all renderers will be able to fully represent strokes as set out by this interface. For example, opacity may not be supported.
Notes:
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |