public interface Stroke
Stroke接口允许
Graphics2D对象获得
Shape是装饰的轮廓,或文体表现的大纲、指定的
Shape。抚摸着
Shape就像用记号笔在适当的尺寸和形状跟踪其轮廓。该地区的笔将墨水用的轮廓
Shape所包围的区域。
那用大纲Shape的Graphics2D接口的方法返回的对象包括Stroke draw和任何其他的方法,在该方法的实现,如drawLine,drawRect,drawRoundRect,drawOval,drawArc,drawPolyline,和drawPolygon。
实施Stroke类的对象必须是只读的,Graphics2D不复制这些对象时设置为一个属性与setStroke方法或当Graphics2D对象本身是克隆。如果一个Stroke对象后,设置在那么Graphics2D语境后续的渲染行为会定义的修改。
| Modifier and Type | Method and Description |
|---|---|
Shape |
createStrokedShape(Shape p)
返回一个轮廓
Shape包围的地区,应该画在
Shape时根据对象实施
Stroke接口定义的规则。
|
Submit a bug or feature
For further API reference and developer documentation, see Java SE Documentation. That documentation contains more detailed, developer-targeted descriptions, with conceptual overviews, definitions of terms, workarounds, and working code examples.
Copyright © 1993, 2014, Oracle and/or its affiliates. All rights reserved.