<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>SVG矢量缩放图形</title>
<style type="text/css">
svg {
border: 1px solid #000;
}
rect {
fill:transparent;
stroke: #000;
}
ellipse{
fill:transparent;
stroke: black;
}
</style>
</head>
<body>
<svg width="500px" height="500px">
<polygon points="170 150,190 130,210 150,230 130,250 150,270 130,290 150" ></polygon>
<!-- 大脸 -->
<rect x="150" y="150" width="160" height="160" rx="20" ry="20"></rect>
<!-- 眼睛 -->
<circle r="15" cx="190" cy="200" fill="transparent" stroke="black"></circle>
<!-- 眼球 -->
<circle r="5" cx="196" cy="206"></circle>
<!-- 眼睛 -->
<circle r="15" cx="270" cy="200" fill="transparent" stroke="black"></circle>
<!-- 眼球 -->
<circle r="5" cx="276" cy="206"></circle>
<!-- 鼻子 -->
<polygon points="230 225,224 245,236 245" fill="transparent" stroke="black"></polygon>
<!-- 大嘴巴 -->
<ellipse cx="230" cy="265" rx="30" ry="12" ></ellipse>
<!-- 文字 -->
<text x="190" y="330" fill="mediumspringgreen">hello,world</text>
</svg>
</body>
</html>