SvgSvgElement Class

https://w3c.github.io/svgwg/svg2-draft/struct.html#svgsvgelement

public sealed class SvgSvgElement : SvgGraphicsElement
Inheritance
SvgGraphicsElement SvgSvgElement

Properties

NameDescription
CurrentScalehttps://svgwg.org/svg2-draft/struct.html#__svg__SVGSVGElement__currentScale
CurrentTranslatehttps://svgwg.org/svg2-draft/struct.html#__svg__SVGSVGElement__currentTranslate
HeightGets the height attribute as a SVGAnimatedLength object.
OnAfterPrintGets or sets the event handler of the afterprint event (the onafterprint event handler attribute).
OnBeforePrintGets or sets the event handler of the beforeprint event (the onbeforeprint event handler attribute).
OnBeforeUnloadGets or sets the event handler of the beforeunload event (the onbeforeunload event handler attribute).
OnHashChangeGets or sets the event handler of the hashchange event (the onhashchange event handler attribute).
OnLanguageChangeGets or sets the event handler of the languagechange event (the onlanguagechange event handler attribute).
OnMessageGets or sets the event handler of the message event (the onmessage event handler attribute).
OnMessageErrorGets or sets the event handler of the messageerror event (the onmessageerror event handler attribute).
OnOfflineGets or sets the event handler of the offline event (the onoffline event handler attribute).
OnOnlineGets or sets the event handler of the online event (the ononline event handler attribute).
OnPageHideGets or sets the event handler of the pagehide event (the onpagehide event handler attribute).
OnPageRevealGets or sets the event handler of the pagereveal event (the onpagereveal event handler attribute).
OnPageShowGets or sets the event handler of the pageshow event (the onpageshow event handler attribute).
OnPageSwapGets or sets the event handler of the pageswap event (the onpageswap event handler attribute).
OnPopStateGets or sets the event handler of the popstate event (the onpopstate event handler attribute).
OnRejectionHandledGets or sets the event handler of the rejectionhandled event (the onrejectionhandled event handler attribute).
OnStorageGets or sets the event handler of the storage event (the onstorage event handler attribute).
OnUnhandledRejectionGets or sets the event handler of the unhandledrejection event (the onunhandledrejection event handler attribute).
OnUnloadGets or sets the event handler of the unload event (the onunload event handler attribute).
PreserveAspectRatioGets the preserveAspectRatio attribute as a SVGAnimatedPreserveAspectRatio object.
ViewBoxGets the viewBox attribute as a SVGAnimatedRect object.
WidthGets the width attribute as a SVGAnimatedLength object.
XGets the x attribute as a SVGAnimatedLength object.
YGets the y attribute as a SVGAnimatedLength object.

CurrentScale

SvgElements.cs

https://svgwg.org/svg2-draft/struct.html#__svg__SVGSVGElement__currentScale

public float CurrentScale { get; set; }

CurrentTranslate

SvgElements.cs

https://svgwg.org/svg2-draft/struct.html#__svg__SVGSVGElement__currentTranslate

public DomPoint CurrentTranslate { get; }

Gets the height attribute as a SVGAnimatedLength object.

public SvgAnimatedLength Height { get; }

OnAfterPrint

SvgElements.g.cs

Gets or sets the event handler of the afterprint event (the onafterprint event handler attribute).

public Action<Event>? OnAfterPrint { get; set; }

OnBeforePrint

SvgElements.g.cs

Gets or sets the event handler of the beforeprint event (the onbeforeprint event handler attribute).

public Action<Event>? OnBeforePrint { get; set; }

OnBeforeUnload

SvgElements.g.cs

Gets or sets the event handler of the beforeunload event (the onbeforeunload event handler attribute).

public Action<Event>? OnBeforeUnload { get; set; }

OnHashChange

SvgElements.g.cs

Gets or sets the event handler of the hashchange event (the onhashchange event handler attribute).

public Action<Event>? OnHashChange { get; set; }

OnLanguageChange

SvgElements.g.cs

Gets or sets the event handler of the languagechange event (the onlanguagechange event handler attribute).

public Action<Event>? OnLanguageChange { get; set; }

Gets or sets the event handler of the message event (the onmessage event handler attribute).

public Action<Event>? OnMessage { get; set; }

OnMessageError

SvgElements.g.cs

Gets or sets the event handler of the messageerror event (the onmessageerror event handler attribute).

public Action<Event>? OnMessageError { get; set; }

Gets or sets the event handler of the offline event (the onoffline event handler attribute).

public Action<Event>? OnOffline { get; set; }

Gets or sets the event handler of the online event (the ononline event handler attribute).

public Action<Event>? OnOnline { get; set; }

Gets or sets the event handler of the pagehide event (the onpagehide event handler attribute).

public Action<Event>? OnPageHide { get; set; }

OnPageReveal

SvgElements.g.cs

Gets or sets the event handler of the pagereveal event (the onpagereveal event handler attribute).

public Action<Event>? OnPageReveal { get; set; }

Gets or sets the event handler of the pageshow event (the onpageshow event handler attribute).

public Action<Event>? OnPageShow { get; set; }

Gets or sets the event handler of the pageswap event (the onpageswap event handler attribute).

public Action<Event>? OnPageSwap { get; set; }

Gets or sets the event handler of the popstate event (the onpopstate event handler attribute).

public Action<Event>? OnPopState { get; set; }

OnRejectionHandled

SvgElements.g.cs

Gets or sets the event handler of the rejectionhandled event (the onrejectionhandled event handler attribute).

public Action<Event>? OnRejectionHandled { get; set; }

Gets or sets the event handler of the storage event (the onstorage event handler attribute).

public Action<Event>? OnStorage { get; set; }

OnUnhandledRejection

SvgElements.g.cs

Gets or sets the event handler of the unhandledrejection event (the onunhandledrejection event handler attribute).

public Action<Event>? OnUnhandledRejection { get; set; }

Gets or sets the event handler of the unload event (the onunload event handler attribute).

public Action<Event>? OnUnload { get; set; }

PreserveAspectRatio

SvgElements.g.cs

Gets the preserveAspectRatio attribute as a SVGAnimatedPreserveAspectRatio object.

public SvgAnimatedPreserveAspectRatio PreserveAspectRatio { get; }

Gets the viewBox attribute as a SVGAnimatedRect object.

public SvgAnimatedRect ViewBox { get; }

Gets the width attribute as a SVGAnimatedLength object.

public SvgAnimatedLength Width { get; }

Gets the x attribute as a SVGAnimatedLength object.

public SvgAnimatedLength X { get; }

Gets the y attribute as a SVGAnimatedLength object.

public SvgAnimatedLength Y { get; }

Methods

NameDescription
AnimationsPaused()Returns whether the animations are paused.
CheckEnclosure(SvgElement, DomRectReadOnly)https://svgwg.org/svg2-draft/struct.html#__svg__SVGSVGElement__checkEnclosure: whether the rendered bounding box of the element is inside the rectangle.
CheckIntersection(SvgElement, DomRectReadOnly)https://svgwg.org/svg2-draft/struct.html#__svg__SVGSVGElement__checkIntersection: whether the rendered bounding box of the element intersects the rectangle.
CreateSvgAngle()Creates an angle with the value 0.
CreateSvgLength()Creates a length with the value 0.
CreateSvgMatrix()Creates an identity matrix.
CreateSvgNumber()Creates a number with the value 0.
CreateSvgPoint()Creates a point at the origin (0, 0).
CreateSvgRect()Creates a rectangle whose position and size are all zero.
CreateSvgTransform()Creates a transform of type SVG_TRANSFORM_MATRIX with the identity matrix.
CreateSvgTransformFromMatrix(DomMatrix2DInit?)Creates a transform of type SVG_TRANSFORM_MATRIX from the given matrix.
DeselectAll()https://svgwg.org/svg2-draft/struct.html#__svg__SVGSVGElement__deselectAll: clears the selection of the document.
ForceRedraw()Forces a redraw of the element; it has no effect because nothing is rendered.
GetCurrentTime()Returns the current time, in seconds, of the timeline of the document fragment.
GetElementById(string)https://svgwg.org/svg2-draft/struct.html#__svg__SVGSVGElement__getElementById: the first descendant element with the id.
GetEnclosureList(DomRectReadOnly, SvgElement?)https://svgwg.org/svg2-draft/struct.html#__svg__SVGSVGElement__getEnclosureList: the graphics elements whose rendered bounding box is entirely inside the rectangle (see SvgSvgElement.GetIntersectionList).
GetIntersectionList(DomRectReadOnly, SvgElement?)https://svgwg.org/svg2-draft/struct.html#__svg__SVGSVGElement__getIntersectionList: the graphics elements of the subtree of the element (or of referenceElement) whose rendered bounding box, in the user space of this element, intersects the rectangle, in document order (as in the browsers, the bounding boxes are tested and the clipping is ignored).
PauseAnimations()Pauses the animations of the document fragment: its timeline stops.
SetCurrentTime(float)Sets the current time, in seconds, of the timeline of the document fragment: the animations are sampled at once. Before the timeline begins (the load event of the document), the time is the time it begins at.
SuspendRedraw(uint)Suspends the redrawing of the element; as nothing is rendered, it only returns a handle.
UnpauseAnimations()Resumes the animations of the document fragment.
UnsuspendRedraw(uint)Cancels a suspension returned by suspendRedraw(); it has no effect because nothing is rendered.
UnsuspendRedrawAll()Cancels all the suspensions of redrawing; it has no effect because nothing is rendered.

AnimationsPaused()

SvgElements.cs

Returns whether the animations are paused.

public bool AnimationsPaused()

CheckEnclosure(SvgElement, DomRectReadOnly)

SvgElements.cs

https://svgwg.org/svg2-draft/struct.html#__svg__SVGSVGElement__checkEnclosure: whether the rendered bounding box of the element is inside the rectangle.

public bool CheckEnclosure(SvgElement element, DomRectReadOnly rect)

CheckIntersection(SvgElement, DomRectReadOnly)

SvgElements.cs

https://svgwg.org/svg2-draft/struct.html#__svg__SVGSVGElement__checkIntersection: whether the rendered bounding box of the element intersects the rectangle.

public bool CheckIntersection(SvgElement element, DomRectReadOnly rect)

CreateSvgAngle()

SvgElements.cs

Creates an angle with the value 0.

public SvgAngle CreateSvgAngle()

CreateSvgLength()

SvgElements.cs

Creates a length with the value 0.

public SvgLength CreateSvgLength()

CreateSvgMatrix()

SvgElements.cs

CreateSvgNumber()

SvgElements.cs

Creates a number with the value 0.

public SvgNumber CreateSvgNumber()

CreateSvgPoint()

SvgElements.cs

Creates a point at the origin (0, 0).

public DomPoint CreateSvgPoint()

CreateSvgRect()

SvgElements.cs

Creates a rectangle whose position and size are all zero.

public DomRect CreateSvgRect()

CreateSvgTransform()

SvgElements.cs

Creates a transform of type SVG_TRANSFORM_MATRIX with the identity matrix.

public SvgTransform CreateSvgTransform()

CreateSvgTransformFromMatrix(DomMatrix2DInit?)

SvgElements.cs

Creates a transform of type SVG_TRANSFORM_MATRIX from the given matrix.

public SvgTransform CreateSvgTransformFromMatrix(DomMatrix2DInit? matrix = null)

DeselectAll()

SvgElements.cs

https://svgwg.org/svg2-draft/struct.html#__svg__SVGSVGElement__deselectAll: clears the selection of the document.

public void DeselectAll()

ForceRedraw()

SvgElements.cs

Forces a redraw of the element; it has no effect because nothing is rendered.

public void ForceRedraw()

GetCurrentTime()

SvgElements.cs

Returns the current time, in seconds, of the timeline of the document fragment.

public float GetCurrentTime()

GetElementById(string)

SvgElements.cs

https://svgwg.org/svg2-draft/struct.html#__svg__SVGSVGElement__getElementById: the first descendant element with the id.

public Element? GetElementById(string elementId)

GetEnclosureList(DomRectReadOnly, SvgElement?)

SvgElements.cs

https://svgwg.org/svg2-draft/struct.html#__svg__SVGSVGElement__getEnclosureList: the graphics elements whose rendered bounding box is entirely inside the rectangle (see SvgSvgElement.GetIntersectionList).

public NodeList GetEnclosureList(DomRectReadOnly rect, SvgElement? referenceElement)

GetIntersectionList(DomRectReadOnly, SvgElement?)

SvgElements.cs

https://svgwg.org/svg2-draft/struct.html#__svg__SVGSVGElement__getIntersectionList: the graphics elements of the subtree of the element (or of referenceElement) whose rendered bounding box, in the user space of this element, intersects the rectangle, in document order (as in the browsers, the bounding boxes are tested and the clipping is ignored).

public NodeList GetIntersectionList(DomRectReadOnly rect, SvgElement? referenceElement)

PauseAnimations()

SvgElements.cs

Pauses the animations of the document fragment: its timeline stops.

public void PauseAnimations()

SetCurrentTime(float)

SvgElements.cs

Sets the current time, in seconds, of the timeline of the document fragment: the animations are sampled at once. Before the timeline begins (the load event of the document), the time is the time it begins at.

public void SetCurrentTime(float seconds)

SuspendRedraw(uint)

SvgElements.cs

Suspends the redrawing of the element; as nothing is rendered, it only returns a handle.

public uint SuspendRedraw(uint maxWaitMilliseconds)

UnpauseAnimations()

SvgElements.cs

Resumes the animations of the document fragment.

public void UnpauseAnimations()

UnsuspendRedraw(uint)

SvgElements.cs

Cancels a suspension returned by suspendRedraw(); it has no effect because nothing is rendered.

public void UnsuspendRedraw(uint suspendHandleId)

UnsuspendRedrawAll()

SvgElements.cs

Cancels all the suspensions of redrawing; it has no effect because nothing is rendered.

public void UnsuspendRedrawAll()