web_sys/features/
gen_SvgsvgElement.rs

1#![allow(unused_imports)]
2#![allow(clippy::all)]
3use super::*;
4use wasm_bindgen::prelude::*;
5#[wasm_bindgen]
6extern "C" {
7    # [wasm_bindgen (extends = SvgGraphicsElement , extends = SvgElement , extends = Element , extends = Node , extends = EventTarget , extends = :: js_sys :: Object , js_name = SVGSVGElement , typescript_type = "SVGSVGElement")]
8    #[derive(Debug, Clone, PartialEq, Eq)]
9    #[doc = "The `SvgsvgElement` class."]
10    #[doc = ""]
11    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/SVGSVGElement)"]
12    #[doc = ""]
13    #[doc = "*This API requires the following crate features to be activated: `SvgsvgElement`*"]
14    pub type SvgsvgElement;
15    #[cfg(feature = "SvgAnimatedLength")]
16    # [wasm_bindgen (structural , method , getter , js_class = "SVGSVGElement" , js_name = x)]
17    #[doc = "Getter for the `x` field of this object."]
18    #[doc = ""]
19    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/SVGSVGElement/x)"]
20    #[doc = ""]
21    #[doc = "*This API requires the following crate features to be activated: `SvgAnimatedLength`, `SvgsvgElement`*"]
22    pub fn x(this: &SvgsvgElement) -> SvgAnimatedLength;
23    #[cfg(feature = "SvgAnimatedLength")]
24    # [wasm_bindgen (structural , method , getter , js_class = "SVGSVGElement" , js_name = y)]
25    #[doc = "Getter for the `y` field of this object."]
26    #[doc = ""]
27    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/SVGSVGElement/y)"]
28    #[doc = ""]
29    #[doc = "*This API requires the following crate features to be activated: `SvgAnimatedLength`, `SvgsvgElement`*"]
30    pub fn y(this: &SvgsvgElement) -> SvgAnimatedLength;
31    #[cfg(feature = "SvgAnimatedLength")]
32    # [wasm_bindgen (structural , method , getter , js_class = "SVGSVGElement" , js_name = width)]
33    #[doc = "Getter for the `width` field of this object."]
34    #[doc = ""]
35    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/SVGSVGElement/width)"]
36    #[doc = ""]
37    #[doc = "*This API requires the following crate features to be activated: `SvgAnimatedLength`, `SvgsvgElement`*"]
38    pub fn width(this: &SvgsvgElement) -> SvgAnimatedLength;
39    #[cfg(feature = "SvgAnimatedLength")]
40    # [wasm_bindgen (structural , method , getter , js_class = "SVGSVGElement" , js_name = height)]
41    #[doc = "Getter for the `height` field of this object."]
42    #[doc = ""]
43    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/SVGSVGElement/height)"]
44    #[doc = ""]
45    #[doc = "*This API requires the following crate features to be activated: `SvgAnimatedLength`, `SvgsvgElement`*"]
46    pub fn height(this: &SvgsvgElement) -> SvgAnimatedLength;
47    # [wasm_bindgen (structural , method , getter , js_class = "SVGSVGElement" , js_name = useCurrentView)]
48    #[doc = "Getter for the `useCurrentView` field of this object."]
49    #[doc = ""]
50    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/SVGSVGElement/useCurrentView)"]
51    #[doc = ""]
52    #[doc = "*This API requires the following crate features to be activated: `SvgsvgElement`*"]
53    pub fn use_current_view(this: &SvgsvgElement) -> bool;
54    # [wasm_bindgen (structural , method , getter , js_class = "SVGSVGElement" , js_name = currentScale)]
55    #[doc = "Getter for the `currentScale` field of this object."]
56    #[doc = ""]
57    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/SVGSVGElement/currentScale)"]
58    #[doc = ""]
59    #[doc = "*This API requires the following crate features to be activated: `SvgsvgElement`*"]
60    pub fn current_scale(this: &SvgsvgElement) -> f32;
61    # [wasm_bindgen (structural , method , setter , js_class = "SVGSVGElement" , js_name = currentScale)]
62    #[doc = "Setter for the `currentScale` field of this object."]
63    #[doc = ""]
64    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/SVGSVGElement/currentScale)"]
65    #[doc = ""]
66    #[doc = "*This API requires the following crate features to be activated: `SvgsvgElement`*"]
67    pub fn set_current_scale(this: &SvgsvgElement, value: f32);
68    #[cfg(feature = "SvgPoint")]
69    # [wasm_bindgen (structural , method , getter , js_class = "SVGSVGElement" , js_name = currentTranslate)]
70    #[doc = "Getter for the `currentTranslate` field of this object."]
71    #[doc = ""]
72    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/SVGSVGElement/currentTranslate)"]
73    #[doc = ""]
74    #[doc = "*This API requires the following crate features to be activated: `SvgPoint`, `SvgsvgElement`*"]
75    pub fn current_translate(this: &SvgsvgElement) -> SvgPoint;
76    #[cfg(feature = "SvgAnimatedRect")]
77    # [wasm_bindgen (structural , method , getter , js_class = "SVGSVGElement" , js_name = viewBox)]
78    #[doc = "Getter for the `viewBox` field of this object."]
79    #[doc = ""]
80    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/SVGSVGElement/viewBox)"]
81    #[doc = ""]
82    #[doc = "*This API requires the following crate features to be activated: `SvgAnimatedRect`, `SvgsvgElement`*"]
83    pub fn view_box(this: &SvgsvgElement) -> SvgAnimatedRect;
84    #[cfg(feature = "SvgAnimatedPreserveAspectRatio")]
85    # [wasm_bindgen (structural , method , getter , js_class = "SVGSVGElement" , js_name = preserveAspectRatio)]
86    #[doc = "Getter for the `preserveAspectRatio` field of this object."]
87    #[doc = ""]
88    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/SVGSVGElement/preserveAspectRatio)"]
89    #[doc = ""]
90    #[doc = "*This API requires the following crate features to be activated: `SvgAnimatedPreserveAspectRatio`, `SvgsvgElement`*"]
91    pub fn preserve_aspect_ratio(this: &SvgsvgElement) -> SvgAnimatedPreserveAspectRatio;
92    # [wasm_bindgen (structural , method , getter , js_class = "SVGSVGElement" , js_name = zoomAndPan)]
93    #[doc = "Getter for the `zoomAndPan` field of this object."]
94    #[doc = ""]
95    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/SVGSVGElement/zoomAndPan)"]
96    #[doc = ""]
97    #[doc = "*This API requires the following crate features to be activated: `SvgsvgElement`*"]
98    pub fn zoom_and_pan(this: &SvgsvgElement) -> u16;
99    # [wasm_bindgen (structural , method , setter , js_class = "SVGSVGElement" , js_name = zoomAndPan)]
100    #[doc = "Setter for the `zoomAndPan` field of this object."]
101    #[doc = ""]
102    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/SVGSVGElement/zoomAndPan)"]
103    #[doc = ""]
104    #[doc = "*This API requires the following crate features to be activated: `SvgsvgElement`*"]
105    pub fn set_zoom_and_pan(this: &SvgsvgElement, value: u16);
106    # [wasm_bindgen (method , structural , js_class = "SVGSVGElement" , js_name = animationsPaused)]
107    #[doc = "The `animationsPaused()` method."]
108    #[doc = ""]
109    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/SVGSVGElement/animationsPaused)"]
110    #[doc = ""]
111    #[doc = "*This API requires the following crate features to be activated: `SvgsvgElement`*"]
112    pub fn animations_paused(this: &SvgsvgElement) -> bool;
113    #[cfg(feature = "SvgAngle")]
114    # [wasm_bindgen (method , structural , js_class = "SVGSVGElement" , js_name = createSVGAngle)]
115    #[doc = "The `createSVGAngle()` method."]
116    #[doc = ""]
117    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/SVGSVGElement/createSVGAngle)"]
118    #[doc = ""]
119    #[doc = "*This API requires the following crate features to be activated: `SvgAngle`, `SvgsvgElement`*"]
120    pub fn create_svg_angle(this: &SvgsvgElement) -> SvgAngle;
121    #[cfg(feature = "SvgLength")]
122    # [wasm_bindgen (method , structural , js_class = "SVGSVGElement" , js_name = createSVGLength)]
123    #[doc = "The `createSVGLength()` method."]
124    #[doc = ""]
125    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/SVGSVGElement/createSVGLength)"]
126    #[doc = ""]
127    #[doc = "*This API requires the following crate features to be activated: `SvgLength`, `SvgsvgElement`*"]
128    pub fn create_svg_length(this: &SvgsvgElement) -> SvgLength;
129    #[cfg(feature = "SvgMatrix")]
130    # [wasm_bindgen (method , structural , js_class = "SVGSVGElement" , js_name = createSVGMatrix)]
131    #[doc = "The `createSVGMatrix()` method."]
132    #[doc = ""]
133    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/SVGSVGElement/createSVGMatrix)"]
134    #[doc = ""]
135    #[doc = "*This API requires the following crate features to be activated: `SvgMatrix`, `SvgsvgElement`*"]
136    pub fn create_svg_matrix(this: &SvgsvgElement) -> SvgMatrix;
137    #[cfg(feature = "SvgNumber")]
138    # [wasm_bindgen (method , structural , js_class = "SVGSVGElement" , js_name = createSVGNumber)]
139    #[doc = "The `createSVGNumber()` method."]
140    #[doc = ""]
141    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/SVGSVGElement/createSVGNumber)"]
142    #[doc = ""]
143    #[doc = "*This API requires the following crate features to be activated: `SvgNumber`, `SvgsvgElement`*"]
144    pub fn create_svg_number(this: &SvgsvgElement) -> SvgNumber;
145    #[cfg(feature = "SvgPoint")]
146    # [wasm_bindgen (method , structural , js_class = "SVGSVGElement" , js_name = createSVGPoint)]
147    #[doc = "The `createSVGPoint()` method."]
148    #[doc = ""]
149    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/SVGSVGElement/createSVGPoint)"]
150    #[doc = ""]
151    #[doc = "*This API requires the following crate features to be activated: `SvgPoint`, `SvgsvgElement`*"]
152    pub fn create_svg_point(this: &SvgsvgElement) -> SvgPoint;
153    #[cfg(feature = "SvgRect")]
154    # [wasm_bindgen (method , structural , js_class = "SVGSVGElement" , js_name = createSVGRect)]
155    #[doc = "The `createSVGRect()` method."]
156    #[doc = ""]
157    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/SVGSVGElement/createSVGRect)"]
158    #[doc = ""]
159    #[doc = "*This API requires the following crate features to be activated: `SvgRect`, `SvgsvgElement`*"]
160    pub fn create_svg_rect(this: &SvgsvgElement) -> SvgRect;
161    #[cfg(feature = "SvgTransform")]
162    # [wasm_bindgen (method , structural , js_class = "SVGSVGElement" , js_name = createSVGTransform)]
163    #[doc = "The `createSVGTransform()` method."]
164    #[doc = ""]
165    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/SVGSVGElement/createSVGTransform)"]
166    #[doc = ""]
167    #[doc = "*This API requires the following crate features to be activated: `SvgTransform`, `SvgsvgElement`*"]
168    pub fn create_svg_transform(this: &SvgsvgElement) -> SvgTransform;
169    #[cfg(all(feature = "SvgMatrix", feature = "SvgTransform",))]
170    # [wasm_bindgen (method , structural , js_class = "SVGSVGElement" , js_name = createSVGTransformFromMatrix)]
171    #[doc = "The `createSVGTransformFromMatrix()` method."]
172    #[doc = ""]
173    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/SVGSVGElement/createSVGTransformFromMatrix)"]
174    #[doc = ""]
175    #[doc = "*This API requires the following crate features to be activated: `SvgMatrix`, `SvgTransform`, `SvgsvgElement`*"]
176    pub fn create_svg_transform_from_matrix(
177        this: &SvgsvgElement,
178        matrix: &SvgMatrix,
179    ) -> SvgTransform;
180    # [wasm_bindgen (method , structural , js_class = "SVGSVGElement" , js_name = deselectAll)]
181    #[doc = "The `deselectAll()` method."]
182    #[doc = ""]
183    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/SVGSVGElement/deselectAll)"]
184    #[doc = ""]
185    #[doc = "*This API requires the following crate features to be activated: `SvgsvgElement`*"]
186    pub fn deselect_all(this: &SvgsvgElement);
187    # [wasm_bindgen (method , structural , js_class = "SVGSVGElement" , js_name = forceRedraw)]
188    #[doc = "The `forceRedraw()` method."]
189    #[doc = ""]
190    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/SVGSVGElement/forceRedraw)"]
191    #[doc = ""]
192    #[doc = "*This API requires the following crate features to be activated: `SvgsvgElement`*"]
193    pub fn force_redraw(this: &SvgsvgElement);
194    # [wasm_bindgen (method , structural , js_class = "SVGSVGElement" , js_name = getCurrentTime)]
195    #[doc = "The `getCurrentTime()` method."]
196    #[doc = ""]
197    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/SVGSVGElement/getCurrentTime)"]
198    #[doc = ""]
199    #[doc = "*This API requires the following crate features to be activated: `SvgsvgElement`*"]
200    pub fn get_current_time(this: &SvgsvgElement) -> f32;
201    # [wasm_bindgen (method , structural , js_class = "SVGSVGElement" , js_name = getElementById)]
202    #[doc = "The `getElementById()` method."]
203    #[doc = ""]
204    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/SVGSVGElement/getElementById)"]
205    #[doc = ""]
206    #[doc = "*This API requires the following crate features to be activated: `SvgsvgElement`*"]
207    pub fn get_element_by_id(this: &SvgsvgElement, element_id: &str) -> Option<Element>;
208    # [wasm_bindgen (method , structural , js_class = "SVGSVGElement" , js_name = pauseAnimations)]
209    #[doc = "The `pauseAnimations()` method."]
210    #[doc = ""]
211    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/SVGSVGElement/pauseAnimations)"]
212    #[doc = ""]
213    #[doc = "*This API requires the following crate features to be activated: `SvgsvgElement`*"]
214    pub fn pause_animations(this: &SvgsvgElement);
215    # [wasm_bindgen (method , structural , js_class = "SVGSVGElement" , js_name = setCurrentTime)]
216    #[doc = "The `setCurrentTime()` method."]
217    #[doc = ""]
218    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/SVGSVGElement/setCurrentTime)"]
219    #[doc = ""]
220    #[doc = "*This API requires the following crate features to be activated: `SvgsvgElement`*"]
221    pub fn set_current_time(this: &SvgsvgElement, seconds: f32);
222    # [wasm_bindgen (method , structural , js_class = "SVGSVGElement" , js_name = suspendRedraw)]
223    #[doc = "The `suspendRedraw()` method."]
224    #[doc = ""]
225    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/SVGSVGElement/suspendRedraw)"]
226    #[doc = ""]
227    #[doc = "*This API requires the following crate features to be activated: `SvgsvgElement`*"]
228    pub fn suspend_redraw(this: &SvgsvgElement, max_wait_milliseconds: u32) -> u32;
229    # [wasm_bindgen (method , structural , js_class = "SVGSVGElement" , js_name = unpauseAnimations)]
230    #[doc = "The `unpauseAnimations()` method."]
231    #[doc = ""]
232    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/SVGSVGElement/unpauseAnimations)"]
233    #[doc = ""]
234    #[doc = "*This API requires the following crate features to be activated: `SvgsvgElement`*"]
235    pub fn unpause_animations(this: &SvgsvgElement);
236    # [wasm_bindgen (method , structural , js_class = "SVGSVGElement" , js_name = unsuspendRedraw)]
237    #[doc = "The `unsuspendRedraw()` method."]
238    #[doc = ""]
239    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/SVGSVGElement/unsuspendRedraw)"]
240    #[doc = ""]
241    #[doc = "*This API requires the following crate features to be activated: `SvgsvgElement`*"]
242    pub fn unsuspend_redraw(this: &SvgsvgElement, suspend_handle_id: u32);
243    # [wasm_bindgen (method , structural , js_class = "SVGSVGElement" , js_name = unsuspendRedrawAll)]
244    #[doc = "The `unsuspendRedrawAll()` method."]
245    #[doc = ""]
246    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/SVGSVGElement/unsuspendRedrawAll)"]
247    #[doc = ""]
248    #[doc = "*This API requires the following crate features to be activated: `SvgsvgElement`*"]
249    pub fn unsuspend_redraw_all(this: &SvgsvgElement);
250}
251impl SvgsvgElement {
252    #[doc = "The `SVGSVGElement.SVG_ZOOMANDPAN_UNKNOWN` const."]
253    #[doc = ""]
254    #[doc = "*This API requires the following crate features to be activated: `SvgsvgElement`*"]
255    pub const SVG_ZOOMANDPAN_UNKNOWN: u16 = 0i64 as u16;
256    #[doc = "The `SVGSVGElement.SVG_ZOOMANDPAN_DISABLE` const."]
257    #[doc = ""]
258    #[doc = "*This API requires the following crate features to be activated: `SvgsvgElement`*"]
259    pub const SVG_ZOOMANDPAN_DISABLE: u16 = 1u64 as u16;
260    #[doc = "The `SVGSVGElement.SVG_ZOOMANDPAN_MAGNIFY` const."]
261    #[doc = ""]
262    #[doc = "*This API requires the following crate features to be activated: `SvgsvgElement`*"]
263    pub const SVG_ZOOMANDPAN_MAGNIFY: u16 = 2u64 as u16;
264}