SVG - ViewPort


viewport in SVG.

The following elements establish new viewports:

  • The svg element with the dimension defined the viewBox attribute
  • A ‘symbol’ element define new viewports whenever they are instanced by a ‘use’ element.
  • An ‘image’ element that references an SVG file will result in the establishment of a temporary new viewport since the referenced resource by definition will have an ‘svg’ element.
  • A ‘foreignObject’ element creates a new viewport for rendering the content that is within the element.

At any point in an SVG drawing, you can establish a new viewport into which all contained graphics is drawn by including an ‘svg’ element inside SVG content.

By establishing a new viewport, you also implicitly establish:

Documentation / Reference

Powered by ComboStrap