Join MDN and developers like you at Mozilla's View Source conference, 12-14 September in Berlin, Germany. Learn more at https://viewsourceconf.org

points

我們的志工尚未將此文章翻譯為 正體中文 (繁體) 版本。加入我們,幫忙翻譯!

« SVG Attribute reference home

The points attribute define a list of points required to draw a  <polyline> or <polygon> element.

Each point is define by a X and a Y coordinate in the user coordinate system. It's a common practice (but not required) to use a comma to mark out the X and Y coordinate of each point and to use space to mark out each point.

Usage context

Categories None
Value <list-of-points>
Animatable Yes
Normative document SVG 1.1 (2nd Edition): The polyline element
SVG 1.1 (2nd Edition): The polygon element

Example

<svg xmlns="http://www.w3.org/2000/svg" version="1.1">
  <polygon points="100,10 250,150 200,110"
           style="fill:lime;stroke:purple;stroke-width:1" />
</svg>

Elements

The following elements can use the points attribute

文件標籤與貢獻者

 此頁面的貢獻者: Jeremie, rshetty
 最近更新: Jeremie,