Area shape 属性
描述
shape 属性设置或返回 area 的 shape 属性值。
shape 属性指定 area 的形状。
shape 属性与 coords 属性一起使用,以指定 area 的大小、形状和位置。
提示:使用 coords 属性来设置或返回 area 的 coords 属性值。
浏览器支持
属性 | |||||
---|---|---|---|---|---|
shape | 是 | 是 | 是 | 是 | 是 |
语法
返回 shape 属性
areaObject.shape
设置 shape 属性
areaObject.shape = "default|rect|circle|poly"
属性值
值 | 描述 |
---|---|
default | 指定整个区域 |
rect | 定义矩形区域 |
circle | 定义圆形区域 |
poly | 定义多边形区域 |
技术详情
返回值 | 一个字符串,表示 area 的形状类型 |
---|
更多示例
相关页面
HTML 参考: HTML <area> shape 属性
❮ Area 对象