blob: 8b979adadbee38952d696192ed7e512534485c32 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
|
---
title: polygon
slug: Web/SVG/Element/polygon
tags:
- SVG
- SVG图形
- 元素
- 参考
translation_of: Web/SVG/Element/polygon
---
<div>{{SVGRef}}</div>
<p><code>polygon元素定义了一个由一组首尾相连的直线线段构成的闭合多边形形状。最后一点连接到第一点。欲了解开放形状,请看{{SVGElement("polyline")}}元素。</code></p>
<h2 id="用法">用法</h2>
<p>{{svginfo}}</p>
<h2 id="示例">示例</h2>
<p>» <a href="https://developer.mozilla.org/files/3259/polygon.svg" title="https://developer.mozilla.org/files/3259/polygon.svg">polygon.svg</a></p>
<h2 id="属性">属性</h2>
<h3 id="全局属性">全局属性</h3>
<ul>
<li><a href="/en/SVG/Attribute#ConditionalProccessing" title="en/SVG/Attribute#ConditionalProccessing">条件处理属性</a> »</li>
<li><a href="/en/SVG/Attribute#Core" title="en/SVG/Attribute#Core">核心属性</a> »</li>
<li><a href="/en/SVG/Attribute#GraphicalEvent" title="en/SVG/Attribute#GraphicalEvent">图形事件属性</a> »</li>
<li><a href="/en/SVG/Attribute#Presentation" title="en/SVG/Attribute#Presentation">外观属性</a> »</li>
<li>{{ SVGAttr("class") }}</li>
<li>{{ SVGAttr("style") }}</li>
<li>{{ SVGAttr("externalResourcesRequired") }}</li>
<li>{{ SVGAttr("transform") }}</li>
</ul>
<h3 id="专有属性">专有属性</h3>
<ul>
<li>{{ SVGAttr("points") }}</li>
</ul>
<h2 id="DOM_接口">DOM 接口</h2>
<p>该元素实现了<code><a href="/en/DOM/SVGPolygonElement" title="en/DOM/SVGPolygonElement">SVGPolygonElement</a>接口。</code></p>
<h2 id="浏览器兼容性">浏览器兼容性</h2>
{{Compat("svg.elements.polygon")}}
<h2 id="相关内容">相关内容</h2>
<ul>
<li>{{ SVGElement("polyline") }}</li>
</ul>
|