viewport attribute | viewport property
Gets or sets the current viewport.
![]() ![]() |
Syntax
| HTML |
|---|
<element viewport="pViewportRect" ... > |
| JavaScript |
|---|
pViewportRect = object.viewport |
Property values
Type: Object
The current viewport.
Standards information
- Scalable Vector Graphics: Document Structure, Section 5.11.2
Remarks
Often, the current viewport is the nearest ancestor svg element. A value of NULL is returned if the given element is the outermost or furthest ancestor svg element.
See also
Show:

