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