广西快乐10分开奖记录|广西快乐10分走势图表
THE WORLD'S LARGEST WEB DEVELOPER SITE
HTMLCSSJAVASCRIPTSQLPHPBOOTSTRAPJQUERYANGULARXML
 

SVG Tutorial


SVG
SVG

SVG stands for Scalable Vector Graphics.

SVG defines vector-based graphics in XML format.


Examples in Each Chapter

With our "Try it Yourself" editor, you can edit the SVG, and click on a button to view the result.

SVG Example

<html>
<body>

<h1>My first SVG</h1>

<svg width="100" height="100">
  <circle cx="50" cy="50" r="40" stroke="green" stroke-width="4" fill="yellow" />
</svg>

</body>
</html>
Try it yourself »

What you should already know

Before you continue, you should have some basic understanding of the following:

  • HTML
  • Basic XML

If you want to study these subjects first, find the tutorials on our Home page.


What is SVG?

  • SVG stands for Scalable Vector Graphics
  • SVG is used to define vector-based graphics for the Web
  • SVG defines the graphics in XML format
  • SVG graphics do NOT lose any quality if they are zoomed or resized
  • Every element and every attribute in SVG files can be animated
  • SVG is a W3C recommendation
  • SVG integrates with other W3C standards such as the DOM and XSL

SVG is a W3C Recommendation

SVG 1.0 became a W3C Recommendation on 4 September 2001.

SVG 1.1 became a W3C Recommendation on 14 January 2003.

SVG 1.1 (Second Edition) became a W3C Recommendation on 16 August 2011.


SVG Advantages

Advantages of using SVG over other image formats (like JPEG and GIF) are:

  • SVG images can be created and edited with any text editor
  • SVG images can be searched, indexed, scripted, and compressed
  • SVG images are scalable
  • SVG images can be printed with high quality at any resolution
  • SVG images are zoomable (and the image can be zoomed without degradation)
  • SVG is an open standard
  • SVG files are pure XML

The main competitor to SVG is Flash.

The biggest advantage SVG has over Flash is the compliance with other standards (e.g. XSL and the DOM). Flash relies on proprietary technology that is not open source.


Creating SVG Images

SVG images can be created with any text editor, but it is often more convenient to create SVG images with a drawing program, like Inkscape.


广西快乐10分开奖记录 球探篮球比分win 258彩票网2019年最新 上海时时彩 竟彩足球指数 老时时彩 足彩即时赔率哪个网站好 河北十一选五 哪个app能买浙江11选5 广西十一选五 2018辽宁麻将玩法