1use crate::{
7 display::{Cookie, Display, DisplayExt},
8 Result,
9};
10use __private::Sealed;
11use alloc::borrow::Cow;
12#[allow(unused_imports)]
13use alloc::vec::Vec;
14use core::borrow::Borrow;
15
16cfg_async! {
17 use crate::{display::{AsyncDisplay, AsyncDisplayExt}, futures};
18 use __private::Sealed2;
19}
20
21pub trait DisplayFunctionsExt: Display + Sealed {
22 fn bigreq_enable(&mut self) -> Result<Cookie<types::bigreq::EnableReply>> {
23 let span = tracing::info_span!("bigreq_enable",);
24 let _enter = span.enter();
25 let request = types::bigreq::EnableRequest {};
26 let cookie = self.send_reply_request(request);
27 cookie
28 }
29 fn bigreq_enable_immediate(&mut self) -> Result<types::bigreq::EnableReply> {
30 let request = types::bigreq::EnableRequest {};
31 let cookie = self.send_reply_request(request)?;
32 self.wait_for_reply(cookie)
33 }
34
35 #[cfg(feature = "composite")]
36 fn composite_query_version(
37 &mut self,
38 client_major_version: types::Card32,
39 client_minor_version: types::Card32,
40 ) -> Result<Cookie<types::composite::QueryVersionReply>> {
41 let span = tracing::info_span!(
42 "composite_query_version",
43 client_major_version = ?client_major_version,
44 client_minor_version = ?client_minor_version,
45 );
46 let _enter = span.enter();
47 let request = types::composite::QueryVersionRequest {
48 client_major_version,
49 client_minor_version,
50 };
51 let cookie = self.send_reply_request(request);
52 cookie
53 }
54 #[cfg(feature = "composite")]
55 fn composite_query_version_immediate(
56 &mut self,
57 client_major_version: types::Card32,
58 client_minor_version: types::Card32,
59 ) -> Result<types::composite::QueryVersionReply> {
60 let request = types::composite::QueryVersionRequest {
61 client_major_version,
62 client_minor_version,
63 };
64 let cookie = self.send_reply_request(request)?;
65 self.wait_for_reply(cookie)
66 }
67 #[cfg(feature = "composite")]
68 fn composite_redirect_window(
69 &mut self,
70 window: types::xproto::Window,
71 update: types::Redirect,
72 ) -> Result<Cookie<()>> {
73 let span = tracing::info_span!(
74 "composite_redirect_window",
75 window = ?window,
76 update = ?update,
77 );
78 let _enter = span.enter();
79 let request = types::composite::RedirectWindowRequest { window, update };
80 let cookie = self.send_void_request(request, true);
81 cookie
82 }
83 #[cfg(feature = "composite")]
84 fn composite_redirect_window_checked(
85 &mut self,
86 window: types::xproto::Window,
87 update: types::Redirect,
88 ) -> Result<()> {
89 let request = types::composite::RedirectWindowRequest { window, update };
90 let cookie = self.send_void_request(request, false)?;
91 self.wait_for_reply(cookie)
92 }
93 #[cfg(feature = "composite")]
94 fn composite_redirect_subwindows(
95 &mut self,
96 window: types::xproto::Window,
97 update: types::Redirect,
98 ) -> Result<Cookie<()>> {
99 let span = tracing::info_span!(
100 "composite_redirect_subwindows",
101 window = ?window,
102 update = ?update,
103 );
104 let _enter = span.enter();
105 let request = types::composite::RedirectSubwindowsRequest { window, update };
106 let cookie = self.send_void_request(request, true);
107 cookie
108 }
109 #[cfg(feature = "composite")]
110 fn composite_redirect_subwindows_checked(
111 &mut self,
112 window: types::xproto::Window,
113 update: types::Redirect,
114 ) -> Result<()> {
115 let request = types::composite::RedirectSubwindowsRequest { window, update };
116 let cookie = self.send_void_request(request, false)?;
117 self.wait_for_reply(cookie)
118 }
119 #[cfg(feature = "composite")]
120 fn composite_unredirect_window(
121 &mut self,
122 window: types::xproto::Window,
123 update: types::Redirect,
124 ) -> Result<Cookie<()>> {
125 let span = tracing::info_span!(
126 "composite_unredirect_window",
127 window = ?window,
128 update = ?update,
129 );
130 let _enter = span.enter();
131 let request = types::composite::UnredirectWindowRequest { window, update };
132 let cookie = self.send_void_request(request, true);
133 cookie
134 }
135 #[cfg(feature = "composite")]
136 fn composite_unredirect_window_checked(
137 &mut self,
138 window: types::xproto::Window,
139 update: types::Redirect,
140 ) -> Result<()> {
141 let request = types::composite::UnredirectWindowRequest { window, update };
142 let cookie = self.send_void_request(request, false)?;
143 self.wait_for_reply(cookie)
144 }
145 #[cfg(feature = "composite")]
146 fn composite_unredirect_subwindows(
147 &mut self,
148 window: types::xproto::Window,
149 update: types::Redirect,
150 ) -> Result<Cookie<()>> {
151 let span = tracing::info_span!(
152 "composite_unredirect_subwindows",
153 window = ?window,
154 update = ?update,
155 );
156 let _enter = span.enter();
157 let request = types::composite::UnredirectSubwindowsRequest { window, update };
158 let cookie = self.send_void_request(request, true);
159 cookie
160 }
161 #[cfg(feature = "composite")]
162 fn composite_unredirect_subwindows_checked(
163 &mut self,
164 window: types::xproto::Window,
165 update: types::Redirect,
166 ) -> Result<()> {
167 let request = types::composite::UnredirectSubwindowsRequest { window, update };
168 let cookie = self.send_void_request(request, false)?;
169 self.wait_for_reply(cookie)
170 }
171 #[cfg(feature = "composite")]
172 fn composite_create_region_from_border_clip(
173 &mut self,
174 region: types::Region,
175 window: types::xproto::Window,
176 ) -> Result<Cookie<()>> {
177 let span = tracing::info_span!(
178 "composite_create_region_from_border_clip",
179 region = ?region,
180 window = ?window,
181 );
182 let _enter = span.enter();
183 let request = types::composite::CreateRegionFromBorderClipRequest { region, window };
184 let cookie = self.send_void_request(request, true);
185 cookie
186 }
187 #[cfg(feature = "composite")]
188 fn composite_create_region_from_border_clip_checked(
189 &mut self,
190 region: types::Region,
191 window: types::xproto::Window,
192 ) -> Result<()> {
193 let request = types::composite::CreateRegionFromBorderClipRequest { region, window };
194 let cookie = self.send_void_request(request, false)?;
195 self.wait_for_reply(cookie)
196 }
197 #[cfg(feature = "composite")]
198 fn composite_name_window_pixmap(
199 &mut self,
200 window: types::xproto::Window,
201 pixmap: types::xproto::Pixmap,
202 ) -> Result<Cookie<()>> {
203 let span = tracing::info_span!(
204 "composite_name_window_pixmap",
205 window = ?window,
206 pixmap = ?pixmap,
207 );
208 let _enter = span.enter();
209 let request = types::composite::NameWindowPixmapRequest { window, pixmap };
210 let cookie = self.send_void_request(request, true);
211 cookie
212 }
213 #[cfg(feature = "composite")]
214 fn composite_name_window_pixmap_checked(
215 &mut self,
216 window: types::xproto::Window,
217 pixmap: types::xproto::Pixmap,
218 ) -> Result<()> {
219 let request = types::composite::NameWindowPixmapRequest { window, pixmap };
220 let cookie = self.send_void_request(request, false)?;
221 self.wait_for_reply(cookie)
222 }
223 #[cfg(feature = "composite")]
224 fn composite_get_overlay_window(
225 &mut self,
226 window: types::xproto::Window,
227 ) -> Result<Cookie<types::composite::GetOverlayWindowReply>> {
228 let span = tracing::info_span!(
229 "composite_get_overlay_window",
230 window = ?window,
231 );
232 let _enter = span.enter();
233 let request = types::composite::GetOverlayWindowRequest { window };
234 let cookie = self.send_reply_request(request);
235 cookie
236 }
237 #[cfg(feature = "composite")]
238 fn composite_get_overlay_window_immediate(
239 &mut self,
240 window: types::xproto::Window,
241 ) -> Result<types::composite::GetOverlayWindowReply> {
242 let request = types::composite::GetOverlayWindowRequest { window };
243 let cookie = self.send_reply_request(request)?;
244 self.wait_for_reply(cookie)
245 }
246 #[cfg(feature = "composite")]
247 fn composite_release_overlay_window(
248 &mut self,
249 window: types::xproto::Window,
250 ) -> Result<Cookie<()>> {
251 let span = tracing::info_span!(
252 "composite_release_overlay_window",
253 window = ?window,
254 );
255 let _enter = span.enter();
256 let request = types::composite::ReleaseOverlayWindowRequest { window };
257 let cookie = self.send_void_request(request, true);
258 cookie
259 }
260 #[cfg(feature = "composite")]
261 fn composite_release_overlay_window_checked(
262 &mut self,
263 window: types::xproto::Window,
264 ) -> Result<()> {
265 let request = types::composite::ReleaseOverlayWindowRequest { window };
266 let cookie = self.send_void_request(request, false)?;
267 self.wait_for_reply(cookie)
268 }
269
270 #[cfg(feature = "damage")]
271 fn damage_query_version(
272 &mut self,
273 client_major_version: types::Card32,
274 client_minor_version: types::Card32,
275 ) -> Result<Cookie<types::damage::QueryVersionReply>> {
276 let span = tracing::info_span!(
277 "damage_query_version",
278 client_major_version = ?client_major_version,
279 client_minor_version = ?client_minor_version,
280 );
281 let _enter = span.enter();
282 let request = types::damage::QueryVersionRequest {
283 client_major_version,
284 client_minor_version,
285 };
286 let cookie = self.send_reply_request(request);
287 cookie
288 }
289 #[cfg(feature = "damage")]
290 fn damage_query_version_immediate(
291 &mut self,
292 client_major_version: types::Card32,
293 client_minor_version: types::Card32,
294 ) -> Result<types::damage::QueryVersionReply> {
295 let request = types::damage::QueryVersionRequest {
296 client_major_version,
297 client_minor_version,
298 };
299 let cookie = self.send_reply_request(request)?;
300 self.wait_for_reply(cookie)
301 }
302 #[cfg(feature = "damage")]
303 fn damage_create(
304 &mut self,
305 damage: types::Damage,
306 drawable: types::xproto::Drawable,
307 level: types::ReportLevel,
308 ) -> Result<Cookie<()>> {
309 let span = tracing::info_span!(
310 "damage_create",
311 damage = ?damage,
312 drawable = ?drawable,
313 level = ?level,
314 );
315 let _enter = span.enter();
316 let request = types::damage::CreateRequest {
317 damage,
318 drawable,
319 level,
320 };
321 let cookie = self.send_void_request(request, true);
322 cookie
323 }
324 #[cfg(feature = "damage")]
325 fn damage_create_checked(
326 &mut self,
327 damage: types::Damage,
328 drawable: types::xproto::Drawable,
329 level: types::ReportLevel,
330 ) -> Result<()> {
331 let request = types::damage::CreateRequest {
332 damage,
333 drawable,
334 level,
335 };
336 let cookie = self.send_void_request(request, false)?;
337 self.wait_for_reply(cookie)
338 }
339 #[cfg(feature = "damage")]
340 fn damage_destroy(&mut self, damage: types::Damage) -> Result<Cookie<()>> {
341 let span = tracing::info_span!(
342 "damage_destroy",
343 damage = ?damage,
344 );
345 let _enter = span.enter();
346 let request = types::damage::DestroyRequest { damage };
347 let cookie = self.send_void_request(request, true);
348 cookie
349 }
350 #[cfg(feature = "damage")]
351 fn damage_destroy_checked(&mut self, damage: types::Damage) -> Result<()> {
352 let request = types::damage::DestroyRequest { damage };
353 let cookie = self.send_void_request(request, false)?;
354 self.wait_for_reply(cookie)
355 }
356 #[cfg(feature = "damage")]
357 fn damage_subtract(
358 &mut self,
359 damage: types::Damage,
360 repair: impl Into<types::Region>,
361 parts: impl Into<types::Region>,
362 ) -> Result<Cookie<()>> {
363 let span = tracing::info_span!(
364 "damage_subtract",
365 damage = ?damage,
366 );
367 let _enter = span.enter();
368 let request = types::damage::SubtractRequest {
369 damage,
370 repair: Into::<u32>::into(repair.into()) as _,
371 parts: Into::<u32>::into(parts.into()) as _,
372 };
373 let cookie = self.send_void_request(request, true);
374 cookie
375 }
376 #[cfg(feature = "damage")]
377 fn damage_subtract_checked(
378 &mut self,
379 damage: types::Damage,
380 repair: impl Into<types::Region>,
381 parts: impl Into<types::Region>,
382 ) -> Result<()> {
383 let request = types::damage::SubtractRequest {
384 damage,
385 repair: Into::<u32>::into(repair.into()) as _,
386 parts: Into::<u32>::into(parts.into()) as _,
387 };
388 let cookie = self.send_void_request(request, false)?;
389 self.wait_for_reply(cookie)
390 }
391 #[cfg(feature = "damage")]
392 fn damage_add(
393 &mut self,
394 drawable: types::xproto::Drawable,
395 region: types::Region,
396 ) -> Result<Cookie<()>> {
397 let span = tracing::info_span!(
398 "damage_add",
399 drawable = ?drawable,
400 region = ?region,
401 );
402 let _enter = span.enter();
403 let request = types::damage::AddRequest { drawable, region };
404 let cookie = self.send_void_request(request, true);
405 cookie
406 }
407 #[cfg(feature = "damage")]
408 fn damage_add_checked(
409 &mut self,
410 drawable: types::xproto::Drawable,
411 region: types::Region,
412 ) -> Result<()> {
413 let request = types::damage::AddRequest { drawable, region };
414 let cookie = self.send_void_request(request, false)?;
415 self.wait_for_reply(cookie)
416 }
417
418 #[cfg(feature = "dpms")]
419 fn dpms_get_version(
420 &mut self,
421 client_major_version: types::Card16,
422 client_minor_version: types::Card16,
423 ) -> Result<Cookie<types::dpms::GetVersionReply>> {
424 let span = tracing::info_span!(
425 "dpms_get_version",
426 client_major_version = ?client_major_version,
427 client_minor_version = ?client_minor_version,
428 );
429 let _enter = span.enter();
430 let request = types::dpms::GetVersionRequest {
431 client_major_version,
432 client_minor_version,
433 };
434 let cookie = self.send_reply_request(request);
435 cookie
436 }
437 #[cfg(feature = "dpms")]
438 fn dpms_get_version_immediate(
439 &mut self,
440 client_major_version: types::Card16,
441 client_minor_version: types::Card16,
442 ) -> Result<types::dpms::GetVersionReply> {
443 let request = types::dpms::GetVersionRequest {
444 client_major_version,
445 client_minor_version,
446 };
447 let cookie = self.send_reply_request(request)?;
448 self.wait_for_reply(cookie)
449 }
450 #[cfg(feature = "dpms")]
451 fn dpms_capable(&mut self) -> Result<Cookie<types::dpms::CapableReply>> {
452 let span = tracing::info_span!("dpms_capable",);
453 let _enter = span.enter();
454 let request = types::dpms::CapableRequest {};
455 let cookie = self.send_reply_request(request);
456 cookie
457 }
458 #[cfg(feature = "dpms")]
459 fn dpms_capable_immediate(&mut self) -> Result<types::dpms::CapableReply> {
460 let request = types::dpms::CapableRequest {};
461 let cookie = self.send_reply_request(request)?;
462 self.wait_for_reply(cookie)
463 }
464 #[cfg(feature = "dpms")]
465 fn dpms_get_timeouts(&mut self) -> Result<Cookie<types::dpms::GetTimeoutsReply>> {
466 let span = tracing::info_span!("dpms_get_timeouts",);
467 let _enter = span.enter();
468 let request = types::dpms::GetTimeoutsRequest {};
469 let cookie = self.send_reply_request(request);
470 cookie
471 }
472 #[cfg(feature = "dpms")]
473 fn dpms_get_timeouts_immediate(&mut self) -> Result<types::dpms::GetTimeoutsReply> {
474 let request = types::dpms::GetTimeoutsRequest {};
475 let cookie = self.send_reply_request(request)?;
476 self.wait_for_reply(cookie)
477 }
478 #[cfg(feature = "dpms")]
479 fn dpms_set_timeouts(
480 &mut self,
481 standby_timeout: types::Card16,
482 suspend_timeout: types::Card16,
483 off_timeout: types::Card16,
484 ) -> Result<Cookie<()>> {
485 let span = tracing::info_span!(
486 "dpms_set_timeouts",
487 standby_timeout = ?standby_timeout,
488 suspend_timeout = ?suspend_timeout,
489 off_timeout = ?off_timeout,
490 );
491 let _enter = span.enter();
492 let request = types::dpms::SetTimeoutsRequest {
493 standby_timeout,
494 suspend_timeout,
495 off_timeout,
496 };
497 let cookie = self.send_void_request(request, true);
498 cookie
499 }
500 #[cfg(feature = "dpms")]
501 fn dpms_set_timeouts_checked(
502 &mut self,
503 standby_timeout: types::Card16,
504 suspend_timeout: types::Card16,
505 off_timeout: types::Card16,
506 ) -> Result<()> {
507 let request = types::dpms::SetTimeoutsRequest {
508 standby_timeout,
509 suspend_timeout,
510 off_timeout,
511 };
512 let cookie = self.send_void_request(request, false)?;
513 self.wait_for_reply(cookie)
514 }
515 #[cfg(feature = "dpms")]
516 fn dpms_enable(&mut self) -> Result<Cookie<()>> {
517 let span = tracing::info_span!("dpms_enable",);
518 let _enter = span.enter();
519 let request = types::dpms::EnableRequest {};
520 let cookie = self.send_void_request(request, true);
521 cookie
522 }
523 #[cfg(feature = "dpms")]
524 fn dpms_enable_checked(&mut self) -> Result<()> {
525 let request = types::dpms::EnableRequest {};
526 let cookie = self.send_void_request(request, false)?;
527 self.wait_for_reply(cookie)
528 }
529 #[cfg(feature = "dpms")]
530 fn dpms_disable(&mut self) -> Result<Cookie<()>> {
531 let span = tracing::info_span!("dpms_disable",);
532 let _enter = span.enter();
533 let request = types::dpms::DisableRequest {};
534 let cookie = self.send_void_request(request, true);
535 cookie
536 }
537 #[cfg(feature = "dpms")]
538 fn dpms_disable_checked(&mut self) -> Result<()> {
539 let request = types::dpms::DisableRequest {};
540 let cookie = self.send_void_request(request, false)?;
541 self.wait_for_reply(cookie)
542 }
543 #[cfg(feature = "dpms")]
544 fn dpms_force_level(&mut self, power_level: types::DPMSMode) -> Result<Cookie<()>> {
545 let span = tracing::info_span!(
546 "dpms_force_level",
547 power_level = ?power_level,
548 );
549 let _enter = span.enter();
550 let request = types::dpms::ForceLevelRequest { power_level };
551 let cookie = self.send_void_request(request, true);
552 cookie
553 }
554 #[cfg(feature = "dpms")]
555 fn dpms_force_level_checked(&mut self, power_level: types::DPMSMode) -> Result<()> {
556 let request = types::dpms::ForceLevelRequest { power_level };
557 let cookie = self.send_void_request(request, false)?;
558 self.wait_for_reply(cookie)
559 }
560 #[cfg(feature = "dpms")]
561 fn dpms_info(&mut self) -> Result<Cookie<types::dpms::InfoReply>> {
562 let span = tracing::info_span!("dpms_info",);
563 let _enter = span.enter();
564 let request = types::dpms::InfoRequest {};
565 let cookie = self.send_reply_request(request);
566 cookie
567 }
568 #[cfg(feature = "dpms")]
569 fn dpms_info_immediate(&mut self) -> Result<types::dpms::InfoReply> {
570 let request = types::dpms::InfoRequest {};
571 let cookie = self.send_reply_request(request)?;
572 self.wait_for_reply(cookie)
573 }
574
575 #[cfg(feature = "dri2")]
576 fn dri2_query_version(
577 &mut self,
578 major_version: types::Card32,
579 minor_version: types::Card32,
580 ) -> Result<Cookie<types::dri2::QueryVersionReply>> {
581 let span = tracing::info_span!(
582 "dri2_query_version",
583 major_version = ?major_version,
584 minor_version = ?minor_version,
585 );
586 let _enter = span.enter();
587 let request = types::dri2::QueryVersionRequest {
588 major_version,
589 minor_version,
590 };
591 let cookie = self.send_reply_request(request);
592 cookie
593 }
594 #[cfg(feature = "dri2")]
595 fn dri2_query_version_immediate(
596 &mut self,
597 major_version: types::Card32,
598 minor_version: types::Card32,
599 ) -> Result<types::dri2::QueryVersionReply> {
600 let request = types::dri2::QueryVersionRequest {
601 major_version,
602 minor_version,
603 };
604 let cookie = self.send_reply_request(request)?;
605 self.wait_for_reply(cookie)
606 }
607 #[cfg(feature = "dri2")]
608 fn dri2_connect(
609 &mut self,
610 window: types::xproto::Window,
611 driver_type: types::DriverType,
612 ) -> Result<Cookie<types::dri2::ConnectReply>> {
613 let span = tracing::info_span!(
614 "dri2_connect",
615 window = ?window,
616 driver_type = ?driver_type,
617 );
618 let _enter = span.enter();
619 let request = types::dri2::ConnectRequest {
620 window,
621 driver_type,
622 };
623 let cookie = self.send_reply_request(request);
624 cookie
625 }
626 #[cfg(feature = "dri2")]
627 fn dri2_connect_immediate(
628 &mut self,
629 window: types::xproto::Window,
630 driver_type: types::DriverType,
631 ) -> Result<types::dri2::ConnectReply> {
632 let request = types::dri2::ConnectRequest {
633 window,
634 driver_type,
635 };
636 let cookie = self.send_reply_request(request)?;
637 self.wait_for_reply(cookie)
638 }
639 #[cfg(feature = "dri2")]
640 fn dri2_authenticate(
641 &mut self,
642 window: types::xproto::Window,
643 magic: types::Card32,
644 ) -> Result<Cookie<types::dri2::AuthenticateReply>> {
645 let span = tracing::info_span!(
646 "dri2_authenticate",
647 window = ?window,
648 magic = ?magic,
649 );
650 let _enter = span.enter();
651 let request = types::dri2::AuthenticateRequest { window, magic };
652 let cookie = self.send_reply_request(request);
653 cookie
654 }
655 #[cfg(feature = "dri2")]
656 fn dri2_authenticate_immediate(
657 &mut self,
658 window: types::xproto::Window,
659 magic: types::Card32,
660 ) -> Result<types::dri2::AuthenticateReply> {
661 let request = types::dri2::AuthenticateRequest { window, magic };
662 let cookie = self.send_reply_request(request)?;
663 self.wait_for_reply(cookie)
664 }
665 #[cfg(feature = "dri2")]
666 fn dri2_create_drawable(&mut self, drawable: types::xproto::Drawable) -> Result<Cookie<()>> {
667 let span = tracing::info_span!(
668 "dri2_create_drawable",
669 drawable = ?drawable,
670 );
671 let _enter = span.enter();
672 let request = types::dri2::CreateDrawableRequest { drawable };
673 let cookie = self.send_void_request(request, true);
674 cookie
675 }
676 #[cfg(feature = "dri2")]
677 fn dri2_create_drawable_checked(&mut self, drawable: types::xproto::Drawable) -> Result<()> {
678 let request = types::dri2::CreateDrawableRequest { drawable };
679 let cookie = self.send_void_request(request, false)?;
680 self.wait_for_reply(cookie)
681 }
682 #[cfg(feature = "dri2")]
683 fn dri2_destroy_drawable(&mut self, drawable: types::xproto::Drawable) -> Result<Cookie<()>> {
684 let span = tracing::info_span!(
685 "dri2_destroy_drawable",
686 drawable = ?drawable,
687 );
688 let _enter = span.enter();
689 let request = types::dri2::DestroyDrawableRequest { drawable };
690 let cookie = self.send_void_request(request, true);
691 cookie
692 }
693 #[cfg(feature = "dri2")]
694 fn dri2_destroy_drawable_checked(&mut self, drawable: types::xproto::Drawable) -> Result<()> {
695 let request = types::dri2::DestroyDrawableRequest { drawable };
696 let cookie = self.send_void_request(request, false)?;
697 self.wait_for_reply(cookie)
698 }
699 #[cfg(feature = "dri2")]
700 fn dri2_copy_region(
701 &mut self,
702 drawable: types::xproto::Drawable,
703 region: types::Card32,
704 dest: types::Card32,
705 src: types::Card32,
706 ) -> Result<Cookie<types::dri2::CopyRegionReply>> {
707 let span = tracing::info_span!(
708 "dri2_copy_region",
709 drawable = ?drawable,
710 region = ?region,
711 dest = ?dest,
712 src = ?src,
713 );
714 let _enter = span.enter();
715 let request = types::dri2::CopyRegionRequest {
716 drawable,
717 region,
718 dest,
719 src,
720 };
721 let cookie = self.send_reply_request(request);
722 cookie
723 }
724 #[cfg(feature = "dri2")]
725 fn dri2_copy_region_immediate(
726 &mut self,
727 drawable: types::xproto::Drawable,
728 region: types::Card32,
729 dest: types::Card32,
730 src: types::Card32,
731 ) -> Result<types::dri2::CopyRegionReply> {
732 let request = types::dri2::CopyRegionRequest {
733 drawable,
734 region,
735 dest,
736 src,
737 };
738 let cookie = self.send_reply_request(request)?;
739 self.wait_for_reply(cookie)
740 }
741 #[cfg(feature = "dri2")]
742 fn dri2_swap_buffers(
743 &mut self,
744 drawable: types::xproto::Drawable,
745 target_msc_hi: types::Card32,
746 target_msc_lo: types::Card32,
747 divisor_hi: types::Card32,
748 divisor_lo: types::Card32,
749 remainder_hi: types::Card32,
750 remainder_lo: types::Card32,
751 ) -> Result<Cookie<types::dri2::SwapBuffersReply>> {
752 let span = tracing::info_span!(
753 "dri2_swap_buffers",
754 drawable = ?drawable,
755 target_msc_hi = ?target_msc_hi,
756 target_msc_lo = ?target_msc_lo,
757 divisor_hi = ?divisor_hi,
758 divisor_lo = ?divisor_lo,
759 remainder_hi = ?remainder_hi,
760 remainder_lo = ?remainder_lo,
761 );
762 let _enter = span.enter();
763 let request = types::dri2::SwapBuffersRequest {
764 drawable,
765 target_msc_hi,
766 target_msc_lo,
767 divisor_hi,
768 divisor_lo,
769 remainder_hi,
770 remainder_lo,
771 };
772 let cookie = self.send_reply_request(request);
773 cookie
774 }
775 #[cfg(feature = "dri2")]
776 fn dri2_swap_buffers_immediate(
777 &mut self,
778 drawable: types::xproto::Drawable,
779 target_msc_hi: types::Card32,
780 target_msc_lo: types::Card32,
781 divisor_hi: types::Card32,
782 divisor_lo: types::Card32,
783 remainder_hi: types::Card32,
784 remainder_lo: types::Card32,
785 ) -> Result<types::dri2::SwapBuffersReply> {
786 let request = types::dri2::SwapBuffersRequest {
787 drawable,
788 target_msc_hi,
789 target_msc_lo,
790 divisor_hi,
791 divisor_lo,
792 remainder_hi,
793 remainder_lo,
794 };
795 let cookie = self.send_reply_request(request)?;
796 self.wait_for_reply(cookie)
797 }
798 #[cfg(feature = "dri2")]
799 fn dri2_get_msc(
800 &mut self,
801 drawable: types::xproto::Drawable,
802 ) -> Result<Cookie<types::dri2::GetMSCReply>> {
803 let span = tracing::info_span!(
804 "dri2_get_msc",
805 drawable = ?drawable,
806 );
807 let _enter = span.enter();
808 let request = types::dri2::GetMSCRequest { drawable };
809 let cookie = self.send_reply_request(request);
810 cookie
811 }
812 #[cfg(feature = "dri2")]
813 fn dri2_get_msc_immediate(
814 &mut self,
815 drawable: types::xproto::Drawable,
816 ) -> Result<types::dri2::GetMSCReply> {
817 let request = types::dri2::GetMSCRequest { drawable };
818 let cookie = self.send_reply_request(request)?;
819 self.wait_for_reply(cookie)
820 }
821 #[cfg(feature = "dri2")]
822 fn dri2_wait_msc(
823 &mut self,
824 drawable: types::xproto::Drawable,
825 target_msc_hi: types::Card32,
826 target_msc_lo: types::Card32,
827 divisor_hi: types::Card32,
828 divisor_lo: types::Card32,
829 remainder_hi: types::Card32,
830 remainder_lo: types::Card32,
831 ) -> Result<Cookie<types::dri2::WaitMSCReply>> {
832 let span = tracing::info_span!(
833 "dri2_wait_msc",
834 drawable = ?drawable,
835 target_msc_hi = ?target_msc_hi,
836 target_msc_lo = ?target_msc_lo,
837 divisor_hi = ?divisor_hi,
838 divisor_lo = ?divisor_lo,
839 remainder_hi = ?remainder_hi,
840 remainder_lo = ?remainder_lo,
841 );
842 let _enter = span.enter();
843 let request = types::dri2::WaitMSCRequest {
844 drawable,
845 target_msc_hi,
846 target_msc_lo,
847 divisor_hi,
848 divisor_lo,
849 remainder_hi,
850 remainder_lo,
851 };
852 let cookie = self.send_reply_request(request);
853 cookie
854 }
855 #[cfg(feature = "dri2")]
856 fn dri2_wait_msc_immediate(
857 &mut self,
858 drawable: types::xproto::Drawable,
859 target_msc_hi: types::Card32,
860 target_msc_lo: types::Card32,
861 divisor_hi: types::Card32,
862 divisor_lo: types::Card32,
863 remainder_hi: types::Card32,
864 remainder_lo: types::Card32,
865 ) -> Result<types::dri2::WaitMSCReply> {
866 let request = types::dri2::WaitMSCRequest {
867 drawable,
868 target_msc_hi,
869 target_msc_lo,
870 divisor_hi,
871 divisor_lo,
872 remainder_hi,
873 remainder_lo,
874 };
875 let cookie = self.send_reply_request(request)?;
876 self.wait_for_reply(cookie)
877 }
878 #[cfg(feature = "dri2")]
879 fn dri2_wait_sbc(
880 &mut self,
881 drawable: types::xproto::Drawable,
882 target_sbc_hi: types::Card32,
883 target_sbc_lo: types::Card32,
884 ) -> Result<Cookie<types::dri2::WaitSBCReply>> {
885 let span = tracing::info_span!(
886 "dri2_wait_sbc",
887 drawable = ?drawable,
888 target_sbc_hi = ?target_sbc_hi,
889 target_sbc_lo = ?target_sbc_lo,
890 );
891 let _enter = span.enter();
892 let request = types::dri2::WaitSBCRequest {
893 drawable,
894 target_sbc_hi,
895 target_sbc_lo,
896 };
897 let cookie = self.send_reply_request(request);
898 cookie
899 }
900 #[cfg(feature = "dri2")]
901 fn dri2_wait_sbc_immediate(
902 &mut self,
903 drawable: types::xproto::Drawable,
904 target_sbc_hi: types::Card32,
905 target_sbc_lo: types::Card32,
906 ) -> Result<types::dri2::WaitSBCReply> {
907 let request = types::dri2::WaitSBCRequest {
908 drawable,
909 target_sbc_hi,
910 target_sbc_lo,
911 };
912 let cookie = self.send_reply_request(request)?;
913 self.wait_for_reply(cookie)
914 }
915 #[cfg(feature = "dri2")]
916 fn dri2_swap_interval(
917 &mut self,
918 drawable: types::xproto::Drawable,
919 interval: types::Card32,
920 ) -> Result<Cookie<()>> {
921 let span = tracing::info_span!(
922 "dri2_swap_interval",
923 drawable = ?drawable,
924 interval = ?interval,
925 );
926 let _enter = span.enter();
927 let request = types::dri2::SwapIntervalRequest { drawable, interval };
928 let cookie = self.send_void_request(request, true);
929 cookie
930 }
931 #[cfg(feature = "dri2")]
932 fn dri2_swap_interval_checked(
933 &mut self,
934 drawable: types::xproto::Drawable,
935 interval: types::Card32,
936 ) -> Result<()> {
937 let request = types::dri2::SwapIntervalRequest { drawable, interval };
938 let cookie = self.send_void_request(request, false)?;
939 self.wait_for_reply(cookie)
940 }
941 #[cfg(feature = "dri2")]
942 fn dri2_get_param(
943 &mut self,
944 drawable: types::xproto::Drawable,
945 param: types::Card32,
946 ) -> Result<Cookie<types::dri2::GetParamReply>> {
947 let span = tracing::info_span!(
948 "dri2_get_param",
949 drawable = ?drawable,
950 param = ?param,
951 );
952 let _enter = span.enter();
953 let request = types::dri2::GetParamRequest { drawable, param };
954 let cookie = self.send_reply_request(request);
955 cookie
956 }
957 #[cfg(feature = "dri2")]
958 fn dri2_get_param_immediate(
959 &mut self,
960 drawable: types::xproto::Drawable,
961 param: types::Card32,
962 ) -> Result<types::dri2::GetParamReply> {
963 let request = types::dri2::GetParamRequest { drawable, param };
964 let cookie = self.send_reply_request(request)?;
965 self.wait_for_reply(cookie)
966 }
967
968 #[cfg(feature = "dri3")]
969 fn dri3_query_version(
970 &mut self,
971 major_version: types::Card32,
972 minor_version: types::Card32,
973 ) -> Result<Cookie<types::dri3::QueryVersionReply>> {
974 let span = tracing::info_span!(
975 "dri3_query_version",
976 major_version = ?major_version,
977 minor_version = ?minor_version,
978 );
979 let _enter = span.enter();
980 let request = types::dri3::QueryVersionRequest {
981 major_version,
982 minor_version,
983 };
984 let cookie = self.send_reply_request(request);
985 cookie
986 }
987 #[cfg(feature = "dri3")]
988 fn dri3_query_version_immediate(
989 &mut self,
990 major_version: types::Card32,
991 minor_version: types::Card32,
992 ) -> Result<types::dri3::QueryVersionReply> {
993 let request = types::dri3::QueryVersionRequest {
994 major_version,
995 minor_version,
996 };
997 let cookie = self.send_reply_request(request)?;
998 self.wait_for_reply(cookie)
999 }
1000 #[cfg(feature = "dri3")]
1001 fn dri3_open(
1002 &mut self,
1003 drawable: types::xproto::Drawable,
1004 provider: types::Card32,
1005 ) -> Result<Cookie<types::dri3::OpenReply>> {
1006 let span = tracing::info_span!(
1007 "dri3_open",
1008 drawable = ?drawable,
1009 provider = ?provider,
1010 );
1011 let _enter = span.enter();
1012 let request = types::dri3::OpenRequest { drawable, provider };
1013 let cookie = self.send_reply_fd_request(request);
1014 cookie
1015 }
1016 #[cfg(feature = "dri3")]
1017 fn dri3_open_immediate(
1018 &mut self,
1019 drawable: types::xproto::Drawable,
1020 provider: types::Card32,
1021 ) -> Result<types::dri3::OpenReply> {
1022 let request = types::dri3::OpenRequest { drawable, provider };
1023 let cookie = self.send_reply_fd_request(request)?;
1024 self.wait_for_reply(cookie)
1025 }
1026 #[cfg(feature = "dri3")]
1027 fn dri3_pixmap_from_buffer(
1028 &mut self,
1029 pixmap: types::xproto::Pixmap,
1030 drawable: types::xproto::Drawable,
1031 size: types::Card32,
1032 width: types::Card16,
1033 height: types::Card16,
1034 stride: types::Card16,
1035 depth: types::Card8,
1036 bpp: types::Card8,
1037 pixmap_fd: types::Fd,
1038 ) -> Result<Cookie<()>> {
1039 let span = tracing::info_span!(
1040 "dri3_pixmap_from_buffer",
1041 pixmap = ?pixmap,
1042 drawable = ?drawable,
1043 size = ?size,
1044 width = ?width,
1045 height = ?height,
1046 stride = ?stride,
1047 depth = ?depth,
1048 bpp = ?bpp,
1049 pixmap_fd = ?pixmap_fd,
1050 );
1051 let _enter = span.enter();
1052 let request = types::dri3::PixmapFromBufferRequest {
1053 pixmap,
1054 drawable,
1055 size,
1056 width,
1057 height,
1058 stride,
1059 depth,
1060 bpp,
1061 pixmap_fd,
1062 };
1063 let cookie = self.send_void_request(request, true);
1064 cookie
1065 }
1066 #[cfg(feature = "dri3")]
1067 fn dri3_pixmap_from_buffer_checked(
1068 &mut self,
1069 pixmap: types::xproto::Pixmap,
1070 drawable: types::xproto::Drawable,
1071 size: types::Card32,
1072 width: types::Card16,
1073 height: types::Card16,
1074 stride: types::Card16,
1075 depth: types::Card8,
1076 bpp: types::Card8,
1077 pixmap_fd: types::Fd,
1078 ) -> Result<()> {
1079 let request = types::dri3::PixmapFromBufferRequest {
1080 pixmap,
1081 drawable,
1082 size,
1083 width,
1084 height,
1085 stride,
1086 depth,
1087 bpp,
1088 pixmap_fd,
1089 };
1090 let cookie = self.send_void_request(request, false)?;
1091 self.wait_for_reply(cookie)
1092 }
1093 #[cfg(feature = "dri3")]
1094 fn dri3_buffer_from_pixmap(
1095 &mut self,
1096 pixmap: types::xproto::Pixmap,
1097 ) -> Result<Cookie<types::dri3::BufferFromPixmapReply>> {
1098 let span = tracing::info_span!(
1099 "dri3_buffer_from_pixmap",
1100 pixmap = ?pixmap,
1101 );
1102 let _enter = span.enter();
1103 let request = types::dri3::BufferFromPixmapRequest { pixmap };
1104 let cookie = self.send_reply_fd_request(request);
1105 cookie
1106 }
1107 #[cfg(feature = "dri3")]
1108 fn dri3_buffer_from_pixmap_immediate(
1109 &mut self,
1110 pixmap: types::xproto::Pixmap,
1111 ) -> Result<types::dri3::BufferFromPixmapReply> {
1112 let request = types::dri3::BufferFromPixmapRequest { pixmap };
1113 let cookie = self.send_reply_fd_request(request)?;
1114 self.wait_for_reply(cookie)
1115 }
1116 #[cfg(feature = "dri3")]
1117 fn dri3_fence_from_fd(
1118 &mut self,
1119 drawable: types::xproto::Drawable,
1120 fence: types::Card32,
1121 initially_triggered: types::Bool,
1122 fence_fd: types::Fd,
1123 ) -> Result<Cookie<()>> {
1124 let span = tracing::info_span!(
1125 "dri3_fence_from_fd",
1126 drawable = ?drawable,
1127 fence = ?fence,
1128 initially_triggered = ?initially_triggered,
1129 fence_fd = ?fence_fd,
1130 );
1131 let _enter = span.enter();
1132 let request = types::dri3::FenceFromFDRequest {
1133 drawable,
1134 fence,
1135 initially_triggered,
1136 fence_fd,
1137 };
1138 let cookie = self.send_void_request(request, true);
1139 cookie
1140 }
1141 #[cfg(feature = "dri3")]
1142 fn dri3_fence_from_fd_checked(
1143 &mut self,
1144 drawable: types::xproto::Drawable,
1145 fence: types::Card32,
1146 initially_triggered: types::Bool,
1147 fence_fd: types::Fd,
1148 ) -> Result<()> {
1149 let request = types::dri3::FenceFromFDRequest {
1150 drawable,
1151 fence,
1152 initially_triggered,
1153 fence_fd,
1154 };
1155 let cookie = self.send_void_request(request, false)?;
1156 self.wait_for_reply(cookie)
1157 }
1158 #[cfg(feature = "dri3")]
1159 fn dri3_fd_from_fence(
1160 &mut self,
1161 drawable: types::xproto::Drawable,
1162 fence: types::Card32,
1163 ) -> Result<Cookie<types::dri3::FDFromFenceReply>> {
1164 let span = tracing::info_span!(
1165 "dri3_fd_from_fence",
1166 drawable = ?drawable,
1167 fence = ?fence,
1168 );
1169 let _enter = span.enter();
1170 let request = types::dri3::FDFromFenceRequest { drawable, fence };
1171 let cookie = self.send_reply_fd_request(request);
1172 cookie
1173 }
1174 #[cfg(feature = "dri3")]
1175 fn dri3_fd_from_fence_immediate(
1176 &mut self,
1177 drawable: types::xproto::Drawable,
1178 fence: types::Card32,
1179 ) -> Result<types::dri3::FDFromFenceReply> {
1180 let request = types::dri3::FDFromFenceRequest { drawable, fence };
1181 let cookie = self.send_reply_fd_request(request)?;
1182 self.wait_for_reply(cookie)
1183 }
1184 #[cfg(feature = "dri3")]
1185 fn dri3_get_supported_modifiers(
1186 &mut self,
1187 window: types::Card32,
1188 depth: types::Card8,
1189 bpp: types::Card8,
1190 ) -> Result<Cookie<types::dri3::GetSupportedModifiersReply>> {
1191 let span = tracing::info_span!(
1192 "dri3_get_supported_modifiers",
1193 window = ?window,
1194 depth = ?depth,
1195 bpp = ?bpp,
1196 );
1197 let _enter = span.enter();
1198 let request = types::dri3::GetSupportedModifiersRequest { window, depth, bpp };
1199 let cookie = self.send_reply_request(request);
1200 cookie
1201 }
1202 #[cfg(feature = "dri3")]
1203 fn dri3_get_supported_modifiers_immediate(
1204 &mut self,
1205 window: types::Card32,
1206 depth: types::Card8,
1207 bpp: types::Card8,
1208 ) -> Result<types::dri3::GetSupportedModifiersReply> {
1209 let request = types::dri3::GetSupportedModifiersRequest { window, depth, bpp };
1210 let cookie = self.send_reply_request(request)?;
1211 self.wait_for_reply(cookie)
1212 }
1213 #[cfg(feature = "dri3")]
1214 fn dri3_pixmap_from_buffers(
1215 &mut self,
1216 pixmap: types::xproto::Pixmap,
1217 window: types::xproto::Window,
1218 width: types::Card16,
1219 height: types::Card16,
1220 stride0: types::Card32,
1221 offset0: types::Card32,
1222 stride1: types::Card32,
1223 offset1: types::Card32,
1224 stride2: types::Card32,
1225 offset2: types::Card32,
1226 stride3: types::Card32,
1227 offset3: types::Card32,
1228 depth: types::Card8,
1229 bpp: types::Card8,
1230 modifier: types::Card64,
1231 buffers: Vec<types::Fd>,
1232 ) -> Result<Cookie<()>> {
1233 let span = tracing::info_span!(
1234 "dri3_pixmap_from_buffers",
1235 pixmap = ?pixmap,
1236 window = ?window,
1237 width = ?width,
1238 height = ?height,
1239 stride0 = ?stride0,
1240 offset0 = ?offset0,
1241 stride1 = ?stride1,
1242 offset1 = ?offset1,
1243 stride2 = ?stride2,
1244 offset2 = ?offset2,
1245 stride3 = ?stride3,
1246 offset3 = ?offset3,
1247 depth = ?depth,
1248 bpp = ?bpp,
1249 modifier = ?modifier,
1250 );
1251 let _enter = span.enter();
1252 let request = types::dri3::PixmapFromBuffersRequest {
1253 pixmap,
1254 window,
1255 width,
1256 height,
1257 stride0,
1258 offset0,
1259 stride1,
1260 offset1,
1261 stride2,
1262 offset2,
1263 stride3,
1264 offset3,
1265 depth,
1266 bpp,
1267 modifier,
1268 buffers,
1269 };
1270 let cookie = self.send_void_request(request, true);
1271 cookie
1272 }
1273 #[cfg(feature = "dri3")]
1274 fn dri3_pixmap_from_buffers_checked(
1275 &mut self,
1276 pixmap: types::xproto::Pixmap,
1277 window: types::xproto::Window,
1278 width: types::Card16,
1279 height: types::Card16,
1280 stride0: types::Card32,
1281 offset0: types::Card32,
1282 stride1: types::Card32,
1283 offset1: types::Card32,
1284 stride2: types::Card32,
1285 offset2: types::Card32,
1286 stride3: types::Card32,
1287 offset3: types::Card32,
1288 depth: types::Card8,
1289 bpp: types::Card8,
1290 modifier: types::Card64,
1291 buffers: Vec<types::Fd>,
1292 ) -> Result<()> {
1293 let request = types::dri3::PixmapFromBuffersRequest {
1294 pixmap,
1295 window,
1296 width,
1297 height,
1298 stride0,
1299 offset0,
1300 stride1,
1301 offset1,
1302 stride2,
1303 offset2,
1304 stride3,
1305 offset3,
1306 depth,
1307 bpp,
1308 modifier,
1309 buffers,
1310 };
1311 let cookie = self.send_void_request(request, false)?;
1312 self.wait_for_reply(cookie)
1313 }
1314 #[cfg(feature = "dri3")]
1315 fn dri3_buffers_from_pixmap(
1316 &mut self,
1317 pixmap: types::xproto::Pixmap,
1318 ) -> Result<Cookie<types::dri3::BuffersFromPixmapReply>> {
1319 let span = tracing::info_span!(
1320 "dri3_buffers_from_pixmap",
1321 pixmap = ?pixmap,
1322 );
1323 let _enter = span.enter();
1324 let request = types::dri3::BuffersFromPixmapRequest { pixmap };
1325 let cookie = self.send_reply_fd_request(request);
1326 cookie
1327 }
1328 #[cfg(feature = "dri3")]
1329 fn dri3_buffers_from_pixmap_immediate(
1330 &mut self,
1331 pixmap: types::xproto::Pixmap,
1332 ) -> Result<types::dri3::BuffersFromPixmapReply> {
1333 let request = types::dri3::BuffersFromPixmapRequest { pixmap };
1334 let cookie = self.send_reply_fd_request(request)?;
1335 self.wait_for_reply(cookie)
1336 }
1337
1338 fn ge_query_version(
1339 &mut self,
1340 client_major_version: types::Card16,
1341 client_minor_version: types::Card16,
1342 ) -> Result<Cookie<types::ge::QueryVersionReply>> {
1343 let span = tracing::info_span!(
1344 "ge_query_version",
1345 client_major_version = ?client_major_version,
1346 client_minor_version = ?client_minor_version,
1347 );
1348 let _enter = span.enter();
1349 let request = types::ge::QueryVersionRequest {
1350 client_major_version,
1351 client_minor_version,
1352 };
1353 let cookie = self.send_reply_request(request);
1354 cookie
1355 }
1356 fn ge_query_version_immediate(
1357 &mut self,
1358 client_major_version: types::Card16,
1359 client_minor_version: types::Card16,
1360 ) -> Result<types::ge::QueryVersionReply> {
1361 let request = types::ge::QueryVersionRequest {
1362 client_major_version,
1363 client_minor_version,
1364 };
1365 let cookie = self.send_reply_request(request)?;
1366 self.wait_for_reply(cookie)
1367 }
1368
1369 #[cfg(feature = "glx")]
1370 fn glx_render(
1371 &mut self,
1372 context_tag: types::ContextTag,
1373 data: impl AsRef<[types::Byte]>,
1374 ) -> Result<Cookie<()>> {
1375 let span = tracing::info_span!(
1376 "glx_render",
1377 context_tag = ?context_tag,
1378 );
1379 let _enter = span.enter();
1380 let request = types::glx::RenderRequest {
1381 context_tag,
1382 data: Cow::Borrowed(data.as_ref()),
1383 };
1384 let cookie = self.send_void_request(request, true);
1385 cookie
1386 }
1387 #[cfg(feature = "glx")]
1388 fn glx_render_checked(
1389 &mut self,
1390 context_tag: types::ContextTag,
1391 data: impl AsRef<[types::Byte]>,
1392 ) -> Result<()> {
1393 let request = types::glx::RenderRequest {
1394 context_tag,
1395 data: Cow::Borrowed(data.as_ref()),
1396 };
1397 let cookie = self.send_void_request(request, false)?;
1398 self.wait_for_reply(cookie)
1399 }
1400 #[cfg(feature = "glx")]
1401 fn glx_render_large(
1402 &mut self,
1403 context_tag: types::ContextTag,
1404 request_num: types::Card16,
1405 request_total: types::Card16,
1406 data: impl AsRef<[types::Byte]>,
1407 ) -> Result<Cookie<()>> {
1408 let span = tracing::info_span!(
1409 "glx_render_large",
1410 context_tag = ?context_tag,
1411 request_num = ?request_num,
1412 request_total = ?request_total,
1413 );
1414 let _enter = span.enter();
1415 let request = types::glx::RenderLargeRequest {
1416 context_tag,
1417 request_num,
1418 request_total,
1419 data: Cow::Borrowed(data.as_ref()),
1420 };
1421 let cookie = self.send_void_request(request, true);
1422 cookie
1423 }
1424 #[cfg(feature = "glx")]
1425 fn glx_render_large_checked(
1426 &mut self,
1427 context_tag: types::ContextTag,
1428 request_num: types::Card16,
1429 request_total: types::Card16,
1430 data: impl AsRef<[types::Byte]>,
1431 ) -> Result<()> {
1432 let request = types::glx::RenderLargeRequest {
1433 context_tag,
1434 request_num,
1435 request_total,
1436 data: Cow::Borrowed(data.as_ref()),
1437 };
1438 let cookie = self.send_void_request(request, false)?;
1439 self.wait_for_reply(cookie)
1440 }
1441 #[cfg(feature = "glx")]
1442 fn glx_create_context(
1443 &mut self,
1444 context: types::glx::Context,
1445 visual: types::Visualid,
1446 screen: types::Card32,
1447 share_list: types::glx::Context,
1448 is_direct: types::Bool,
1449 ) -> Result<Cookie<()>> {
1450 let span = tracing::info_span!(
1451 "glx_create_context",
1452 context = ?context,
1453 visual = ?visual,
1454 screen = ?screen,
1455 share_list = ?share_list,
1456 is_direct = ?is_direct,
1457 );
1458 let _enter = span.enter();
1459 let request = types::glx::CreateContextRequest {
1460 context,
1461 visual,
1462 screen,
1463 share_list,
1464 is_direct,
1465 };
1466 let cookie = self.send_void_request(request, true);
1467 cookie
1468 }
1469 #[cfg(feature = "glx")]
1470 fn glx_create_context_checked(
1471 &mut self,
1472 context: types::glx::Context,
1473 visual: types::Visualid,
1474 screen: types::Card32,
1475 share_list: types::glx::Context,
1476 is_direct: types::Bool,
1477 ) -> Result<()> {
1478 let request = types::glx::CreateContextRequest {
1479 context,
1480 visual,
1481 screen,
1482 share_list,
1483 is_direct,
1484 };
1485 let cookie = self.send_void_request(request, false)?;
1486 self.wait_for_reply(cookie)
1487 }
1488 #[cfg(feature = "glx")]
1489 fn glx_destroy_context(&mut self, context: types::glx::Context) -> Result<Cookie<()>> {
1490 let span = tracing::info_span!(
1491 "glx_destroy_context",
1492 context = ?context,
1493 );
1494 let _enter = span.enter();
1495 let request = types::glx::DestroyContextRequest { context };
1496 let cookie = self.send_void_request(request, true);
1497 cookie
1498 }
1499 #[cfg(feature = "glx")]
1500 fn glx_destroy_context_checked(&mut self, context: types::glx::Context) -> Result<()> {
1501 let request = types::glx::DestroyContextRequest { context };
1502 let cookie = self.send_void_request(request, false)?;
1503 self.wait_for_reply(cookie)
1504 }
1505 #[cfg(feature = "glx")]
1506 fn glx_make_current(
1507 &mut self,
1508 drawable: types::glx::Drawable,
1509 context: types::glx::Context,
1510 old_context_tag: types::ContextTag,
1511 ) -> Result<Cookie<types::glx::MakeCurrentReply>> {
1512 let span = tracing::info_span!(
1513 "glx_make_current",
1514 drawable = ?drawable,
1515 context = ?context,
1516 old_context_tag = ?old_context_tag,
1517 );
1518 let _enter = span.enter();
1519 let request = types::glx::MakeCurrentRequest {
1520 drawable,
1521 context,
1522 old_context_tag,
1523 };
1524 let cookie = self.send_reply_request(request);
1525 cookie
1526 }
1527 #[cfg(feature = "glx")]
1528 fn glx_make_current_immediate(
1529 &mut self,
1530 drawable: types::glx::Drawable,
1531 context: types::glx::Context,
1532 old_context_tag: types::ContextTag,
1533 ) -> Result<types::glx::MakeCurrentReply> {
1534 let request = types::glx::MakeCurrentRequest {
1535 drawable,
1536 context,
1537 old_context_tag,
1538 };
1539 let cookie = self.send_reply_request(request)?;
1540 self.wait_for_reply(cookie)
1541 }
1542 #[cfg(feature = "glx")]
1543 fn glx_is_direct(
1544 &mut self,
1545 context: types::glx::Context,
1546 ) -> Result<Cookie<types::glx::IsDirectReply>> {
1547 let span = tracing::info_span!(
1548 "glx_is_direct",
1549 context = ?context,
1550 );
1551 let _enter = span.enter();
1552 let request = types::glx::IsDirectRequest { context };
1553 let cookie = self.send_reply_request(request);
1554 cookie
1555 }
1556 #[cfg(feature = "glx")]
1557 fn glx_is_direct_immediate(
1558 &mut self,
1559 context: types::glx::Context,
1560 ) -> Result<types::glx::IsDirectReply> {
1561 let request = types::glx::IsDirectRequest { context };
1562 let cookie = self.send_reply_request(request)?;
1563 self.wait_for_reply(cookie)
1564 }
1565 #[cfg(feature = "glx")]
1566 fn glx_query_version(
1567 &mut self,
1568 major_version: types::Card32,
1569 minor_version: types::Card32,
1570 ) -> Result<Cookie<types::glx::QueryVersionReply>> {
1571 let span = tracing::info_span!(
1572 "glx_query_version",
1573 major_version = ?major_version,
1574 minor_version = ?minor_version,
1575 );
1576 let _enter = span.enter();
1577 let request = types::glx::QueryVersionRequest {
1578 major_version,
1579 minor_version,
1580 };
1581 let cookie = self.send_reply_request(request);
1582 cookie
1583 }
1584 #[cfg(feature = "glx")]
1585 fn glx_query_version_immediate(
1586 &mut self,
1587 major_version: types::Card32,
1588 minor_version: types::Card32,
1589 ) -> Result<types::glx::QueryVersionReply> {
1590 let request = types::glx::QueryVersionRequest {
1591 major_version,
1592 minor_version,
1593 };
1594 let cookie = self.send_reply_request(request)?;
1595 self.wait_for_reply(cookie)
1596 }
1597 #[cfg(feature = "glx")]
1598 fn glx_wait_gl(&mut self, context_tag: types::ContextTag) -> Result<Cookie<()>> {
1599 let span = tracing::info_span!(
1600 "glx_wait_gl",
1601 context_tag = ?context_tag,
1602 );
1603 let _enter = span.enter();
1604 let request = types::glx::WaitGLRequest { context_tag };
1605 let cookie = self.send_void_request(request, true);
1606 cookie
1607 }
1608 #[cfg(feature = "glx")]
1609 fn glx_wait_gl_checked(&mut self, context_tag: types::ContextTag) -> Result<()> {
1610 let request = types::glx::WaitGLRequest { context_tag };
1611 let cookie = self.send_void_request(request, false)?;
1612 self.wait_for_reply(cookie)
1613 }
1614 #[cfg(feature = "glx")]
1615 fn glx_wait_x(&mut self, context_tag: types::ContextTag) -> Result<Cookie<()>> {
1616 let span = tracing::info_span!(
1617 "glx_wait_x",
1618 context_tag = ?context_tag,
1619 );
1620 let _enter = span.enter();
1621 let request = types::glx::WaitXRequest { context_tag };
1622 let cookie = self.send_void_request(request, true);
1623 cookie
1624 }
1625 #[cfg(feature = "glx")]
1626 fn glx_wait_x_checked(&mut self, context_tag: types::ContextTag) -> Result<()> {
1627 let request = types::glx::WaitXRequest { context_tag };
1628 let cookie = self.send_void_request(request, false)?;
1629 self.wait_for_reply(cookie)
1630 }
1631 #[cfg(feature = "glx")]
1632 fn glx_copy_context(
1633 &mut self,
1634 src: types::glx::Context,
1635 dest: types::glx::Context,
1636 mask: types::Card32,
1637 src_context_tag: types::ContextTag,
1638 ) -> Result<Cookie<()>> {
1639 let span = tracing::info_span!(
1640 "glx_copy_context",
1641 src = ?src,
1642 dest = ?dest,
1643 mask = ?mask,
1644 src_context_tag = ?src_context_tag,
1645 );
1646 let _enter = span.enter();
1647 let request = types::glx::CopyContextRequest {
1648 src,
1649 dest,
1650 mask,
1651 src_context_tag,
1652 };
1653 let cookie = self.send_void_request(request, true);
1654 cookie
1655 }
1656 #[cfg(feature = "glx")]
1657 fn glx_copy_context_checked(
1658 &mut self,
1659 src: types::glx::Context,
1660 dest: types::glx::Context,
1661 mask: types::Card32,
1662 src_context_tag: types::ContextTag,
1663 ) -> Result<()> {
1664 let request = types::glx::CopyContextRequest {
1665 src,
1666 dest,
1667 mask,
1668 src_context_tag,
1669 };
1670 let cookie = self.send_void_request(request, false)?;
1671 self.wait_for_reply(cookie)
1672 }
1673 #[cfg(feature = "glx")]
1674 fn glx_swap_buffers(
1675 &mut self,
1676 context_tag: types::ContextTag,
1677 drawable: types::glx::Drawable,
1678 ) -> Result<Cookie<()>> {
1679 let span = tracing::info_span!(
1680 "glx_swap_buffers",
1681 context_tag = ?context_tag,
1682 drawable = ?drawable,
1683 );
1684 let _enter = span.enter();
1685 let request = types::glx::SwapBuffersRequest {
1686 context_tag,
1687 drawable,
1688 };
1689 let cookie = self.send_void_request(request, true);
1690 cookie
1691 }
1692 #[cfg(feature = "glx")]
1693 fn glx_swap_buffers_checked(
1694 &mut self,
1695 context_tag: types::ContextTag,
1696 drawable: types::glx::Drawable,
1697 ) -> Result<()> {
1698 let request = types::glx::SwapBuffersRequest {
1699 context_tag,
1700 drawable,
1701 };
1702 let cookie = self.send_void_request(request, false)?;
1703 self.wait_for_reply(cookie)
1704 }
1705 #[cfg(feature = "glx")]
1706 fn glx_use_x_font(
1707 &mut self,
1708 context_tag: types::ContextTag,
1709 font: types::Font,
1710 first: types::Card32,
1711 count: types::Card32,
1712 list_base: types::Card32,
1713 ) -> Result<Cookie<()>> {
1714 let span = tracing::info_span!(
1715 "glx_use_x_font",
1716 context_tag = ?context_tag,
1717 font = ?font,
1718 first = ?first,
1719 count = ?count,
1720 list_base = ?list_base,
1721 );
1722 let _enter = span.enter();
1723 let request = types::glx::UseXFontRequest {
1724 context_tag,
1725 font,
1726 first,
1727 count,
1728 list_base,
1729 };
1730 let cookie = self.send_void_request(request, true);
1731 cookie
1732 }
1733 #[cfg(feature = "glx")]
1734 fn glx_use_x_font_checked(
1735 &mut self,
1736 context_tag: types::ContextTag,
1737 font: types::Font,
1738 first: types::Card32,
1739 count: types::Card32,
1740 list_base: types::Card32,
1741 ) -> Result<()> {
1742 let request = types::glx::UseXFontRequest {
1743 context_tag,
1744 font,
1745 first,
1746 count,
1747 list_base,
1748 };
1749 let cookie = self.send_void_request(request, false)?;
1750 self.wait_for_reply(cookie)
1751 }
1752 #[cfg(feature = "glx")]
1753 fn glx_create_glx_pixmap(
1754 &mut self,
1755 screen: types::Card32,
1756 visual: types::Visualid,
1757 pixmap: types::xproto::Pixmap,
1758 glx_pixmap: types::glx::Pixmap,
1759 ) -> Result<Cookie<()>> {
1760 let span = tracing::info_span!(
1761 "glx_create_glx_pixmap",
1762 screen = ?screen,
1763 visual = ?visual,
1764 pixmap = ?pixmap,
1765 glx_pixmap = ?glx_pixmap,
1766 );
1767 let _enter = span.enter();
1768 let request = types::glx::CreateGLXPixmapRequest {
1769 screen,
1770 visual,
1771 pixmap,
1772 glx_pixmap,
1773 };
1774 let cookie = self.send_void_request(request, true);
1775 cookie
1776 }
1777 #[cfg(feature = "glx")]
1778 fn glx_create_glx_pixmap_checked(
1779 &mut self,
1780 screen: types::Card32,
1781 visual: types::Visualid,
1782 pixmap: types::xproto::Pixmap,
1783 glx_pixmap: types::glx::Pixmap,
1784 ) -> Result<()> {
1785 let request = types::glx::CreateGLXPixmapRequest {
1786 screen,
1787 visual,
1788 pixmap,
1789 glx_pixmap,
1790 };
1791 let cookie = self.send_void_request(request, false)?;
1792 self.wait_for_reply(cookie)
1793 }
1794 #[cfg(feature = "glx")]
1795 fn glx_get_visual_configs(
1796 &mut self,
1797 screen: types::Card32,
1798 ) -> Result<Cookie<types::glx::GetVisualConfigsReply>> {
1799 let span = tracing::info_span!(
1800 "glx_get_visual_configs",
1801 screen = ?screen,
1802 );
1803 let _enter = span.enter();
1804 let request = types::glx::GetVisualConfigsRequest { screen };
1805 let cookie = self.send_reply_request(request);
1806 cookie
1807 }
1808 #[cfg(feature = "glx")]
1809 fn glx_get_visual_configs_immediate(
1810 &mut self,
1811 screen: types::Card32,
1812 ) -> Result<types::glx::GetVisualConfigsReply> {
1813 let request = types::glx::GetVisualConfigsRequest { screen };
1814 let cookie = self.send_reply_request(request)?;
1815 self.wait_for_reply(cookie)
1816 }
1817 #[cfg(feature = "glx")]
1818 fn glx_destroy_glx_pixmap(&mut self, glx_pixmap: types::glx::Pixmap) -> Result<Cookie<()>> {
1819 let span = tracing::info_span!(
1820 "glx_destroy_glx_pixmap",
1821 glx_pixmap = ?glx_pixmap,
1822 );
1823 let _enter = span.enter();
1824 let request = types::glx::DestroyGLXPixmapRequest { glx_pixmap };
1825 let cookie = self.send_void_request(request, true);
1826 cookie
1827 }
1828 #[cfg(feature = "glx")]
1829 fn glx_destroy_glx_pixmap_checked(&mut self, glx_pixmap: types::glx::Pixmap) -> Result<()> {
1830 let request = types::glx::DestroyGLXPixmapRequest { glx_pixmap };
1831 let cookie = self.send_void_request(request, false)?;
1832 self.wait_for_reply(cookie)
1833 }
1834 #[cfg(feature = "glx")]
1835 fn glx_vendor_private(
1836 &mut self,
1837 vendor_code: types::Card32,
1838 context_tag: types::ContextTag,
1839 data: impl AsRef<[types::Byte]>,
1840 ) -> Result<Cookie<()>> {
1841 let span = tracing::info_span!(
1842 "glx_vendor_private",
1843 vendor_code = ?vendor_code,
1844 context_tag = ?context_tag,
1845 );
1846 let _enter = span.enter();
1847 let request = types::glx::VendorPrivateRequest {
1848 vendor_code,
1849 context_tag,
1850 data: Cow::Borrowed(data.as_ref()),
1851 };
1852 let cookie = self.send_void_request(request, true);
1853 cookie
1854 }
1855 #[cfg(feature = "glx")]
1856 fn glx_vendor_private_checked(
1857 &mut self,
1858 vendor_code: types::Card32,
1859 context_tag: types::ContextTag,
1860 data: impl AsRef<[types::Byte]>,
1861 ) -> Result<()> {
1862 let request = types::glx::VendorPrivateRequest {
1863 vendor_code,
1864 context_tag,
1865 data: Cow::Borrowed(data.as_ref()),
1866 };
1867 let cookie = self.send_void_request(request, false)?;
1868 self.wait_for_reply(cookie)
1869 }
1870 #[cfg(feature = "glx")]
1871 fn glx_vendor_private_with_reply(
1872 &mut self,
1873 vendor_code: types::Card32,
1874 context_tag: types::ContextTag,
1875 data: impl AsRef<[types::Byte]>,
1876 ) -> Result<Cookie<types::glx::VendorPrivateWithReplyReply>> {
1877 let span = tracing::info_span!(
1878 "glx_vendor_private_with_reply",
1879 vendor_code = ?vendor_code,
1880 context_tag = ?context_tag,
1881 );
1882 let _enter = span.enter();
1883 let request = types::glx::VendorPrivateWithReplyRequest {
1884 vendor_code,
1885 context_tag,
1886 data: Cow::Borrowed(data.as_ref()),
1887 };
1888 let cookie = self.send_reply_request(request);
1889 cookie
1890 }
1891 #[cfg(feature = "glx")]
1892 fn glx_vendor_private_with_reply_immediate(
1893 &mut self,
1894 vendor_code: types::Card32,
1895 context_tag: types::ContextTag,
1896 data: impl AsRef<[types::Byte]>,
1897 ) -> Result<types::glx::VendorPrivateWithReplyReply> {
1898 let request = types::glx::VendorPrivateWithReplyRequest {
1899 vendor_code,
1900 context_tag,
1901 data: Cow::Borrowed(data.as_ref()),
1902 };
1903 let cookie = self.send_reply_request(request)?;
1904 self.wait_for_reply(cookie)
1905 }
1906 #[cfg(feature = "glx")]
1907 fn glx_query_extensions_string(
1908 &mut self,
1909 screen: types::Card32,
1910 ) -> Result<Cookie<types::glx::QueryExtensionsStringReply>> {
1911 let span = tracing::info_span!(
1912 "glx_query_extensions_string",
1913 screen = ?screen,
1914 );
1915 let _enter = span.enter();
1916 let request = types::glx::QueryExtensionsStringRequest { screen };
1917 let cookie = self.send_reply_request(request);
1918 cookie
1919 }
1920 #[cfg(feature = "glx")]
1921 fn glx_query_extensions_string_immediate(
1922 &mut self,
1923 screen: types::Card32,
1924 ) -> Result<types::glx::QueryExtensionsStringReply> {
1925 let request = types::glx::QueryExtensionsStringRequest { screen };
1926 let cookie = self.send_reply_request(request)?;
1927 self.wait_for_reply(cookie)
1928 }
1929 #[cfg(feature = "glx")]
1930 fn glx_query_server_string(
1931 &mut self,
1932 screen: types::Card32,
1933 name: types::Card32,
1934 ) -> Result<Cookie<types::glx::QueryServerStringReply>> {
1935 let span = tracing::info_span!(
1936 "glx_query_server_string",
1937 screen = ?screen,
1938 name = ?name,
1939 );
1940 let _enter = span.enter();
1941 let request = types::glx::QueryServerStringRequest { screen, name };
1942 let cookie = self.send_reply_request(request);
1943 cookie
1944 }
1945 #[cfg(feature = "glx")]
1946 fn glx_query_server_string_immediate(
1947 &mut self,
1948 screen: types::Card32,
1949 name: types::Card32,
1950 ) -> Result<types::glx::QueryServerStringReply> {
1951 let request = types::glx::QueryServerStringRequest { screen, name };
1952 let cookie = self.send_reply_request(request)?;
1953 self.wait_for_reply(cookie)
1954 }
1955 #[cfg(feature = "glx")]
1956 fn glx_client_info(
1957 &mut self,
1958 major_version: types::Card32,
1959 minor_version: types::Card32,
1960 string: impl AsRef<[types::Char]>,
1961 ) -> Result<Cookie<()>> {
1962 let span = tracing::info_span!(
1963 "glx_client_info",
1964 major_version = ?major_version,
1965 minor_version = ?minor_version,
1966 );
1967 let _enter = span.enter();
1968 let request = types::glx::ClientInfoRequest {
1969 major_version,
1970 minor_version,
1971 string: Cow::Borrowed(string.as_ref()),
1972 };
1973 let cookie = self.send_void_request(request, true);
1974 cookie
1975 }
1976 #[cfg(feature = "glx")]
1977 fn glx_client_info_checked(
1978 &mut self,
1979 major_version: types::Card32,
1980 minor_version: types::Card32,
1981 string: impl AsRef<[types::Char]>,
1982 ) -> Result<()> {
1983 let request = types::glx::ClientInfoRequest {
1984 major_version,
1985 minor_version,
1986 string: Cow::Borrowed(string.as_ref()),
1987 };
1988 let cookie = self.send_void_request(request, false)?;
1989 self.wait_for_reply(cookie)
1990 }
1991 #[cfg(feature = "glx")]
1992 fn glx_get_fb_configs(
1993 &mut self,
1994 screen: types::Card32,
1995 ) -> Result<Cookie<types::glx::GetFBConfigsReply>> {
1996 let span = tracing::info_span!(
1997 "glx_get_fb_configs",
1998 screen = ?screen,
1999 );
2000 let _enter = span.enter();
2001 let request = types::glx::GetFBConfigsRequest { screen };
2002 let cookie = self.send_reply_request(request);
2003 cookie
2004 }
2005 #[cfg(feature = "glx")]
2006 fn glx_get_fb_configs_immediate(
2007 &mut self,
2008 screen: types::Card32,
2009 ) -> Result<types::glx::GetFBConfigsReply> {
2010 let request = types::glx::GetFBConfigsRequest { screen };
2011 let cookie = self.send_reply_request(request)?;
2012 self.wait_for_reply(cookie)
2013 }
2014 #[cfg(feature = "glx")]
2015 fn glx_create_pixmap(
2016 &mut self,
2017 screen: types::Card32,
2018 fbconfig: types::Fbconfig,
2019 pixmap: types::xproto::Pixmap,
2020 glx_pixmap: types::glx::Pixmap,
2021 attribs: impl AsRef<[types::Card32]>,
2022 ) -> Result<Cookie<()>> {
2023 let span = tracing::info_span!(
2024 "glx_create_pixmap",
2025 screen = ?screen,
2026 fbconfig = ?fbconfig,
2027 pixmap = ?pixmap,
2028 glx_pixmap = ?glx_pixmap,
2029 );
2030 let _enter = span.enter();
2031 let request = types::glx::CreatePixmapRequest {
2032 screen,
2033 fbconfig,
2034 pixmap,
2035 glx_pixmap,
2036 attribs: Cow::Borrowed(attribs.as_ref()),
2037 };
2038 let cookie = self.send_void_request(request, true);
2039 cookie
2040 }
2041 #[cfg(feature = "glx")]
2042 fn glx_create_pixmap_checked(
2043 &mut self,
2044 screen: types::Card32,
2045 fbconfig: types::Fbconfig,
2046 pixmap: types::xproto::Pixmap,
2047 glx_pixmap: types::glx::Pixmap,
2048 attribs: impl AsRef<[types::Card32]>,
2049 ) -> Result<()> {
2050 let request = types::glx::CreatePixmapRequest {
2051 screen,
2052 fbconfig,
2053 pixmap,
2054 glx_pixmap,
2055 attribs: Cow::Borrowed(attribs.as_ref()),
2056 };
2057 let cookie = self.send_void_request(request, false)?;
2058 self.wait_for_reply(cookie)
2059 }
2060 #[cfg(feature = "glx")]
2061 fn glx_destroy_pixmap(&mut self, glx_pixmap: types::glx::Pixmap) -> Result<Cookie<()>> {
2062 let span = tracing::info_span!(
2063 "glx_destroy_pixmap",
2064 glx_pixmap = ?glx_pixmap,
2065 );
2066 let _enter = span.enter();
2067 let request = types::glx::DestroyPixmapRequest { glx_pixmap };
2068 let cookie = self.send_void_request(request, true);
2069 cookie
2070 }
2071 #[cfg(feature = "glx")]
2072 fn glx_destroy_pixmap_checked(&mut self, glx_pixmap: types::glx::Pixmap) -> Result<()> {
2073 let request = types::glx::DestroyPixmapRequest { glx_pixmap };
2074 let cookie = self.send_void_request(request, false)?;
2075 self.wait_for_reply(cookie)
2076 }
2077 #[cfg(feature = "glx")]
2078 fn glx_create_new_context(
2079 &mut self,
2080 context: types::glx::Context,
2081 fbconfig: types::Fbconfig,
2082 screen: types::Card32,
2083 render_type: types::Card32,
2084 share_list: types::glx::Context,
2085 is_direct: types::Bool,
2086 ) -> Result<Cookie<()>> {
2087 let span = tracing::info_span!(
2088 "glx_create_new_context",
2089 context = ?context,
2090 fbconfig = ?fbconfig,
2091 screen = ?screen,
2092 render_type = ?render_type,
2093 share_list = ?share_list,
2094 is_direct = ?is_direct,
2095 );
2096 let _enter = span.enter();
2097 let request = types::glx::CreateNewContextRequest {
2098 context,
2099 fbconfig,
2100 screen,
2101 render_type,
2102 share_list,
2103 is_direct,
2104 };
2105 let cookie = self.send_void_request(request, true);
2106 cookie
2107 }
2108 #[cfg(feature = "glx")]
2109 fn glx_create_new_context_checked(
2110 &mut self,
2111 context: types::glx::Context,
2112 fbconfig: types::Fbconfig,
2113 screen: types::Card32,
2114 render_type: types::Card32,
2115 share_list: types::glx::Context,
2116 is_direct: types::Bool,
2117 ) -> Result<()> {
2118 let request = types::glx::CreateNewContextRequest {
2119 context,
2120 fbconfig,
2121 screen,
2122 render_type,
2123 share_list,
2124 is_direct,
2125 };
2126 let cookie = self.send_void_request(request, false)?;
2127 self.wait_for_reply(cookie)
2128 }
2129 #[cfg(feature = "glx")]
2130 fn glx_query_context(
2131 &mut self,
2132 context: types::glx::Context,
2133 ) -> Result<Cookie<types::glx::QueryContextReply>> {
2134 let span = tracing::info_span!(
2135 "glx_query_context",
2136 context = ?context,
2137 );
2138 let _enter = span.enter();
2139 let request = types::glx::QueryContextRequest { context };
2140 let cookie = self.send_reply_request(request);
2141 cookie
2142 }
2143 #[cfg(feature = "glx")]
2144 fn glx_query_context_immediate(
2145 &mut self,
2146 context: types::glx::Context,
2147 ) -> Result<types::glx::QueryContextReply> {
2148 let request = types::glx::QueryContextRequest { context };
2149 let cookie = self.send_reply_request(request)?;
2150 self.wait_for_reply(cookie)
2151 }
2152 #[cfg(feature = "glx")]
2153 fn glx_make_context_current(
2154 &mut self,
2155 old_context_tag: types::ContextTag,
2156 drawable: types::glx::Drawable,
2157 read_drawable: types::glx::Drawable,
2158 context: types::glx::Context,
2159 ) -> Result<Cookie<types::glx::MakeContextCurrentReply>> {
2160 let span = tracing::info_span!(
2161 "glx_make_context_current",
2162 old_context_tag = ?old_context_tag,
2163 drawable = ?drawable,
2164 read_drawable = ?read_drawable,
2165 context = ?context,
2166 );
2167 let _enter = span.enter();
2168 let request = types::glx::MakeContextCurrentRequest {
2169 old_context_tag,
2170 drawable,
2171 read_drawable,
2172 context,
2173 };
2174 let cookie = self.send_reply_request(request);
2175 cookie
2176 }
2177 #[cfg(feature = "glx")]
2178 fn glx_make_context_current_immediate(
2179 &mut self,
2180 old_context_tag: types::ContextTag,
2181 drawable: types::glx::Drawable,
2182 read_drawable: types::glx::Drawable,
2183 context: types::glx::Context,
2184 ) -> Result<types::glx::MakeContextCurrentReply> {
2185 let request = types::glx::MakeContextCurrentRequest {
2186 old_context_tag,
2187 drawable,
2188 read_drawable,
2189 context,
2190 };
2191 let cookie = self.send_reply_request(request)?;
2192 self.wait_for_reply(cookie)
2193 }
2194 #[cfg(feature = "glx")]
2195 fn glx_create_pbuffer(
2196 &mut self,
2197 screen: types::Card32,
2198 fbconfig: types::Fbconfig,
2199 pbuffer: types::Pbuffer,
2200 attribs: impl AsRef<[types::Card32]>,
2201 ) -> Result<Cookie<()>> {
2202 let span = tracing::info_span!(
2203 "glx_create_pbuffer",
2204 screen = ?screen,
2205 fbconfig = ?fbconfig,
2206 pbuffer = ?pbuffer,
2207 );
2208 let _enter = span.enter();
2209 let request = types::glx::CreatePbufferRequest {
2210 screen,
2211 fbconfig,
2212 pbuffer,
2213 attribs: Cow::Borrowed(attribs.as_ref()),
2214 };
2215 let cookie = self.send_void_request(request, true);
2216 cookie
2217 }
2218 #[cfg(feature = "glx")]
2219 fn glx_create_pbuffer_checked(
2220 &mut self,
2221 screen: types::Card32,
2222 fbconfig: types::Fbconfig,
2223 pbuffer: types::Pbuffer,
2224 attribs: impl AsRef<[types::Card32]>,
2225 ) -> Result<()> {
2226 let request = types::glx::CreatePbufferRequest {
2227 screen,
2228 fbconfig,
2229 pbuffer,
2230 attribs: Cow::Borrowed(attribs.as_ref()),
2231 };
2232 let cookie = self.send_void_request(request, false)?;
2233 self.wait_for_reply(cookie)
2234 }
2235 #[cfg(feature = "glx")]
2236 fn glx_destroy_pbuffer(&mut self, pbuffer: types::Pbuffer) -> Result<Cookie<()>> {
2237 let span = tracing::info_span!(
2238 "glx_destroy_pbuffer",
2239 pbuffer = ?pbuffer,
2240 );
2241 let _enter = span.enter();
2242 let request = types::glx::DestroyPbufferRequest { pbuffer };
2243 let cookie = self.send_void_request(request, true);
2244 cookie
2245 }
2246 #[cfg(feature = "glx")]
2247 fn glx_destroy_pbuffer_checked(&mut self, pbuffer: types::Pbuffer) -> Result<()> {
2248 let request = types::glx::DestroyPbufferRequest { pbuffer };
2249 let cookie = self.send_void_request(request, false)?;
2250 self.wait_for_reply(cookie)
2251 }
2252 #[cfg(feature = "glx")]
2253 fn glx_get_drawable_attributes(
2254 &mut self,
2255 drawable: types::glx::Drawable,
2256 ) -> Result<Cookie<types::glx::GetDrawableAttributesReply>> {
2257 let span = tracing::info_span!(
2258 "glx_get_drawable_attributes",
2259 drawable = ?drawable,
2260 );
2261 let _enter = span.enter();
2262 let request = types::glx::GetDrawableAttributesRequest { drawable };
2263 let cookie = self.send_reply_request(request);
2264 cookie
2265 }
2266 #[cfg(feature = "glx")]
2267 fn glx_get_drawable_attributes_immediate(
2268 &mut self,
2269 drawable: types::glx::Drawable,
2270 ) -> Result<types::glx::GetDrawableAttributesReply> {
2271 let request = types::glx::GetDrawableAttributesRequest { drawable };
2272 let cookie = self.send_reply_request(request)?;
2273 self.wait_for_reply(cookie)
2274 }
2275 #[cfg(feature = "glx")]
2276 fn glx_change_drawable_attributes(
2277 &mut self,
2278 drawable: types::glx::Drawable,
2279 attribs: impl AsRef<[types::Card32]>,
2280 ) -> Result<Cookie<()>> {
2281 let span = tracing::info_span!(
2282 "glx_change_drawable_attributes",
2283 drawable = ?drawable,
2284 );
2285 let _enter = span.enter();
2286 let request = types::glx::ChangeDrawableAttributesRequest {
2287 drawable,
2288 attribs: Cow::Borrowed(attribs.as_ref()),
2289 };
2290 let cookie = self.send_void_request(request, true);
2291 cookie
2292 }
2293 #[cfg(feature = "glx")]
2294 fn glx_change_drawable_attributes_checked(
2295 &mut self,
2296 drawable: types::glx::Drawable,
2297 attribs: impl AsRef<[types::Card32]>,
2298 ) -> Result<()> {
2299 let request = types::glx::ChangeDrawableAttributesRequest {
2300 drawable,
2301 attribs: Cow::Borrowed(attribs.as_ref()),
2302 };
2303 let cookie = self.send_void_request(request, false)?;
2304 self.wait_for_reply(cookie)
2305 }
2306 #[cfg(feature = "glx")]
2307 fn glx_create_window(
2308 &mut self,
2309 screen: types::Card32,
2310 fbconfig: types::Fbconfig,
2311 window: types::xproto::Window,
2312 glx_window: types::glx::Window,
2313 attribs: impl AsRef<[types::Card32]>,
2314 ) -> Result<Cookie<()>> {
2315 let span = tracing::info_span!(
2316 "glx_create_window",
2317 screen = ?screen,
2318 fbconfig = ?fbconfig,
2319 window = ?window,
2320 glx_window = ?glx_window,
2321 );
2322 let _enter = span.enter();
2323 let request = types::glx::CreateWindowRequest {
2324 screen,
2325 fbconfig,
2326 window,
2327 glx_window,
2328 attribs: Cow::Borrowed(attribs.as_ref()),
2329 };
2330 let cookie = self.send_void_request(request, true);
2331 cookie
2332 }
2333 #[cfg(feature = "glx")]
2334 fn glx_create_window_checked(
2335 &mut self,
2336 screen: types::Card32,
2337 fbconfig: types::Fbconfig,
2338 window: types::xproto::Window,
2339 glx_window: types::glx::Window,
2340 attribs: impl AsRef<[types::Card32]>,
2341 ) -> Result<()> {
2342 let request = types::glx::CreateWindowRequest {
2343 screen,
2344 fbconfig,
2345 window,
2346 glx_window,
2347 attribs: Cow::Borrowed(attribs.as_ref()),
2348 };
2349 let cookie = self.send_void_request(request, false)?;
2350 self.wait_for_reply(cookie)
2351 }
2352 #[cfg(feature = "glx")]
2353 fn glx_delete_window(&mut self, glxwindow: types::glx::Window) -> Result<Cookie<()>> {
2354 let span = tracing::info_span!(
2355 "glx_delete_window",
2356 glxwindow = ?glxwindow,
2357 );
2358 let _enter = span.enter();
2359 let request = types::glx::DeleteWindowRequest { glxwindow };
2360 let cookie = self.send_void_request(request, true);
2361 cookie
2362 }
2363 #[cfg(feature = "glx")]
2364 fn glx_delete_window_checked(&mut self, glxwindow: types::glx::Window) -> Result<()> {
2365 let request = types::glx::DeleteWindowRequest { glxwindow };
2366 let cookie = self.send_void_request(request, false)?;
2367 self.wait_for_reply(cookie)
2368 }
2369 #[cfg(feature = "glx")]
2370 fn glx_set_client_info_arb(
2371 &mut self,
2372 major_version: types::Card32,
2373 minor_version: types::Card32,
2374 gl_versions: impl AsRef<[types::Card32]>,
2375 gl_extension_string: impl AsRef<[types::Char]>,
2376 glx_extension_string: impl AsRef<[types::Char]>,
2377 ) -> Result<Cookie<()>> {
2378 let span = tracing::info_span!(
2379 "glx_set_client_info_arb",
2380 major_version = ?major_version,
2381 minor_version = ?minor_version,
2382 );
2383 let _enter = span.enter();
2384 let request = types::glx::SetClientInfoARBRequest {
2385 major_version,
2386 minor_version,
2387 gl_versions: Cow::Borrowed(gl_versions.as_ref()),
2388 gl_extension_string: Cow::Borrowed(gl_extension_string.as_ref()),
2389 glx_extension_string: Cow::Borrowed(glx_extension_string.as_ref()),
2390 };
2391 let cookie = self.send_void_request(request, true);
2392 cookie
2393 }
2394 #[cfg(feature = "glx")]
2395 fn glx_set_client_info_arb_checked(
2396 &mut self,
2397 major_version: types::Card32,
2398 minor_version: types::Card32,
2399 gl_versions: impl AsRef<[types::Card32]>,
2400 gl_extension_string: impl AsRef<[types::Char]>,
2401 glx_extension_string: impl AsRef<[types::Char]>,
2402 ) -> Result<()> {
2403 let request = types::glx::SetClientInfoARBRequest {
2404 major_version,
2405 minor_version,
2406 gl_versions: Cow::Borrowed(gl_versions.as_ref()),
2407 gl_extension_string: Cow::Borrowed(gl_extension_string.as_ref()),
2408 glx_extension_string: Cow::Borrowed(glx_extension_string.as_ref()),
2409 };
2410 let cookie = self.send_void_request(request, false)?;
2411 self.wait_for_reply(cookie)
2412 }
2413 #[cfg(feature = "glx")]
2414 fn glx_create_context_attribs_arb(
2415 &mut self,
2416 context: types::glx::Context,
2417 fbconfig: types::Fbconfig,
2418 screen: types::Card32,
2419 share_list: types::glx::Context,
2420 is_direct: types::Bool,
2421 attribs: impl AsRef<[types::Card32]>,
2422 ) -> Result<Cookie<()>> {
2423 let span = tracing::info_span!(
2424 "glx_create_context_attribs_arb",
2425 context = ?context,
2426 fbconfig = ?fbconfig,
2427 screen = ?screen,
2428 share_list = ?share_list,
2429 is_direct = ?is_direct,
2430 );
2431 let _enter = span.enter();
2432 let request = types::glx::CreateContextAttribsARBRequest {
2433 context,
2434 fbconfig,
2435 screen,
2436 share_list,
2437 is_direct,
2438 attribs: Cow::Borrowed(attribs.as_ref()),
2439 };
2440 let cookie = self.send_void_request(request, true);
2441 cookie
2442 }
2443 #[cfg(feature = "glx")]
2444 fn glx_create_context_attribs_arb_checked(
2445 &mut self,
2446 context: types::glx::Context,
2447 fbconfig: types::Fbconfig,
2448 screen: types::Card32,
2449 share_list: types::glx::Context,
2450 is_direct: types::Bool,
2451 attribs: impl AsRef<[types::Card32]>,
2452 ) -> Result<()> {
2453 let request = types::glx::CreateContextAttribsARBRequest {
2454 context,
2455 fbconfig,
2456 screen,
2457 share_list,
2458 is_direct,
2459 attribs: Cow::Borrowed(attribs.as_ref()),
2460 };
2461 let cookie = self.send_void_request(request, false)?;
2462 self.wait_for_reply(cookie)
2463 }
2464 #[cfg(feature = "glx")]
2465 fn glx_set_client_info2_arb(
2466 &mut self,
2467 major_version: types::Card32,
2468 minor_version: types::Card32,
2469 gl_versions: impl AsRef<[types::Card32]>,
2470 gl_extension_string: impl AsRef<[types::Char]>,
2471 glx_extension_string: impl AsRef<[types::Char]>,
2472 ) -> Result<Cookie<()>> {
2473 let span = tracing::info_span!(
2474 "glx_set_client_info2_arb",
2475 major_version = ?major_version,
2476 minor_version = ?minor_version,
2477 );
2478 let _enter = span.enter();
2479 let request = types::glx::SetClientInfo2ARBRequest {
2480 major_version,
2481 minor_version,
2482 gl_versions: Cow::Borrowed(gl_versions.as_ref()),
2483 gl_extension_string: Cow::Borrowed(gl_extension_string.as_ref()),
2484 glx_extension_string: Cow::Borrowed(glx_extension_string.as_ref()),
2485 };
2486 let cookie = self.send_void_request(request, true);
2487 cookie
2488 }
2489 #[cfg(feature = "glx")]
2490 fn glx_set_client_info2_arb_checked(
2491 &mut self,
2492 major_version: types::Card32,
2493 minor_version: types::Card32,
2494 gl_versions: impl AsRef<[types::Card32]>,
2495 gl_extension_string: impl AsRef<[types::Char]>,
2496 glx_extension_string: impl AsRef<[types::Char]>,
2497 ) -> Result<()> {
2498 let request = types::glx::SetClientInfo2ARBRequest {
2499 major_version,
2500 minor_version,
2501 gl_versions: Cow::Borrowed(gl_versions.as_ref()),
2502 gl_extension_string: Cow::Borrowed(gl_extension_string.as_ref()),
2503 glx_extension_string: Cow::Borrowed(glx_extension_string.as_ref()),
2504 };
2505 let cookie = self.send_void_request(request, false)?;
2506 self.wait_for_reply(cookie)
2507 }
2508 #[cfg(feature = "glx")]
2509 fn glx_new_list(
2510 &mut self,
2511 context_tag: types::ContextTag,
2512 list: types::Card32,
2513 mode: types::Card32,
2514 ) -> Result<Cookie<()>> {
2515 let span = tracing::info_span!(
2516 "glx_new_list",
2517 context_tag = ?context_tag,
2518 list = ?list,
2519 mode = ?mode,
2520 );
2521 let _enter = span.enter();
2522 let request = types::glx::NewListRequest {
2523 context_tag,
2524 list,
2525 mode,
2526 };
2527 let cookie = self.send_void_request(request, true);
2528 cookie
2529 }
2530 #[cfg(feature = "glx")]
2531 fn glx_new_list_checked(
2532 &mut self,
2533 context_tag: types::ContextTag,
2534 list: types::Card32,
2535 mode: types::Card32,
2536 ) -> Result<()> {
2537 let request = types::glx::NewListRequest {
2538 context_tag,
2539 list,
2540 mode,
2541 };
2542 let cookie = self.send_void_request(request, false)?;
2543 self.wait_for_reply(cookie)
2544 }
2545 #[cfg(feature = "glx")]
2546 fn glx_end_list(&mut self, context_tag: types::ContextTag) -> Result<Cookie<()>> {
2547 let span = tracing::info_span!(
2548 "glx_end_list",
2549 context_tag = ?context_tag,
2550 );
2551 let _enter = span.enter();
2552 let request = types::glx::EndListRequest { context_tag };
2553 let cookie = self.send_void_request(request, true);
2554 cookie
2555 }
2556 #[cfg(feature = "glx")]
2557 fn glx_end_list_checked(&mut self, context_tag: types::ContextTag) -> Result<()> {
2558 let request = types::glx::EndListRequest { context_tag };
2559 let cookie = self.send_void_request(request, false)?;
2560 self.wait_for_reply(cookie)
2561 }
2562 #[cfg(feature = "glx")]
2563 fn glx_delete_lists(
2564 &mut self,
2565 context_tag: types::ContextTag,
2566 list: types::Card32,
2567 range: types::Int32,
2568 ) -> Result<Cookie<()>> {
2569 let span = tracing::info_span!(
2570 "glx_delete_lists",
2571 context_tag = ?context_tag,
2572 list = ?list,
2573 range = ?range,
2574 );
2575 let _enter = span.enter();
2576 let request = types::glx::DeleteListsRequest {
2577 context_tag,
2578 list,
2579 range,
2580 };
2581 let cookie = self.send_void_request(request, true);
2582 cookie
2583 }
2584 #[cfg(feature = "glx")]
2585 fn glx_delete_lists_checked(
2586 &mut self,
2587 context_tag: types::ContextTag,
2588 list: types::Card32,
2589 range: types::Int32,
2590 ) -> Result<()> {
2591 let request = types::glx::DeleteListsRequest {
2592 context_tag,
2593 list,
2594 range,
2595 };
2596 let cookie = self.send_void_request(request, false)?;
2597 self.wait_for_reply(cookie)
2598 }
2599 #[cfg(feature = "glx")]
2600 fn glx_gen_lists(
2601 &mut self,
2602 context_tag: types::ContextTag,
2603 range: types::Int32,
2604 ) -> Result<Cookie<types::glx::GenListsReply>> {
2605 let span = tracing::info_span!(
2606 "glx_gen_lists",
2607 context_tag = ?context_tag,
2608 range = ?range,
2609 );
2610 let _enter = span.enter();
2611 let request = types::glx::GenListsRequest { context_tag, range };
2612 let cookie = self.send_reply_request(request);
2613 cookie
2614 }
2615 #[cfg(feature = "glx")]
2616 fn glx_gen_lists_immediate(
2617 &mut self,
2618 context_tag: types::ContextTag,
2619 range: types::Int32,
2620 ) -> Result<types::glx::GenListsReply> {
2621 let request = types::glx::GenListsRequest { context_tag, range };
2622 let cookie = self.send_reply_request(request)?;
2623 self.wait_for_reply(cookie)
2624 }
2625 #[cfg(feature = "glx")]
2626 fn glx_feedback_buffer(
2627 &mut self,
2628 context_tag: types::ContextTag,
2629 size: types::Int32,
2630 type_: types::Int32,
2631 ) -> Result<Cookie<()>> {
2632 let span = tracing::info_span!(
2633 "glx_feedback_buffer",
2634 context_tag = ?context_tag,
2635 size = ?size,
2636 type_ = ?type_,
2637 );
2638 let _enter = span.enter();
2639 let request = types::glx::FeedbackBufferRequest {
2640 context_tag,
2641 size,
2642 type_,
2643 };
2644 let cookie = self.send_void_request(request, true);
2645 cookie
2646 }
2647 #[cfg(feature = "glx")]
2648 fn glx_feedback_buffer_checked(
2649 &mut self,
2650 context_tag: types::ContextTag,
2651 size: types::Int32,
2652 type_: types::Int32,
2653 ) -> Result<()> {
2654 let request = types::glx::FeedbackBufferRequest {
2655 context_tag,
2656 size,
2657 type_,
2658 };
2659 let cookie = self.send_void_request(request, false)?;
2660 self.wait_for_reply(cookie)
2661 }
2662 #[cfg(feature = "glx")]
2663 fn glx_select_buffer(
2664 &mut self,
2665 context_tag: types::ContextTag,
2666 size: types::Int32,
2667 ) -> Result<Cookie<()>> {
2668 let span = tracing::info_span!(
2669 "glx_select_buffer",
2670 context_tag = ?context_tag,
2671 size = ?size,
2672 );
2673 let _enter = span.enter();
2674 let request = types::glx::SelectBufferRequest { context_tag, size };
2675 let cookie = self.send_void_request(request, true);
2676 cookie
2677 }
2678 #[cfg(feature = "glx")]
2679 fn glx_select_buffer_checked(
2680 &mut self,
2681 context_tag: types::ContextTag,
2682 size: types::Int32,
2683 ) -> Result<()> {
2684 let request = types::glx::SelectBufferRequest { context_tag, size };
2685 let cookie = self.send_void_request(request, false)?;
2686 self.wait_for_reply(cookie)
2687 }
2688 #[cfg(feature = "glx")]
2689 fn glx_render_mode(
2690 &mut self,
2691 context_tag: types::ContextTag,
2692 mode: types::Card32,
2693 ) -> Result<Cookie<types::glx::RenderModeReply>> {
2694 let span = tracing::info_span!(
2695 "glx_render_mode",
2696 context_tag = ?context_tag,
2697 mode = ?mode,
2698 );
2699 let _enter = span.enter();
2700 let request = types::glx::RenderModeRequest { context_tag, mode };
2701 let cookie = self.send_reply_request(request);
2702 cookie
2703 }
2704 #[cfg(feature = "glx")]
2705 fn glx_render_mode_immediate(
2706 &mut self,
2707 context_tag: types::ContextTag,
2708 mode: types::Card32,
2709 ) -> Result<types::glx::RenderModeReply> {
2710 let request = types::glx::RenderModeRequest { context_tag, mode };
2711 let cookie = self.send_reply_request(request)?;
2712 self.wait_for_reply(cookie)
2713 }
2714 #[cfg(feature = "glx")]
2715 fn glx_finish(
2716 &mut self,
2717 context_tag: types::ContextTag,
2718 ) -> Result<Cookie<types::glx::FinishReply>> {
2719 let span = tracing::info_span!(
2720 "glx_finish",
2721 context_tag = ?context_tag,
2722 );
2723 let _enter = span.enter();
2724 let request = types::glx::FinishRequest { context_tag };
2725 let cookie = self.send_reply_request(request);
2726 cookie
2727 }
2728 #[cfg(feature = "glx")]
2729 fn glx_finish_immediate(
2730 &mut self,
2731 context_tag: types::ContextTag,
2732 ) -> Result<types::glx::FinishReply> {
2733 let request = types::glx::FinishRequest { context_tag };
2734 let cookie = self.send_reply_request(request)?;
2735 self.wait_for_reply(cookie)
2736 }
2737 #[cfg(feature = "glx")]
2738 fn glx_pixel_storef(
2739 &mut self,
2740 context_tag: types::ContextTag,
2741 pname: types::Card32,
2742 datum: types::Float32,
2743 ) -> Result<Cookie<()>> {
2744 let span = tracing::info_span!(
2745 "glx_pixel_storef",
2746 context_tag = ?context_tag,
2747 pname = ?pname,
2748 datum = ?datum,
2749 );
2750 let _enter = span.enter();
2751 let request = types::glx::PixelStorefRequest {
2752 context_tag,
2753 pname,
2754 datum,
2755 };
2756 let cookie = self.send_void_request(request, true);
2757 cookie
2758 }
2759 #[cfg(feature = "glx")]
2760 fn glx_pixel_storef_checked(
2761 &mut self,
2762 context_tag: types::ContextTag,
2763 pname: types::Card32,
2764 datum: types::Float32,
2765 ) -> Result<()> {
2766 let request = types::glx::PixelStorefRequest {
2767 context_tag,
2768 pname,
2769 datum,
2770 };
2771 let cookie = self.send_void_request(request, false)?;
2772 self.wait_for_reply(cookie)
2773 }
2774 #[cfg(feature = "glx")]
2775 fn glx_pixel_storei(
2776 &mut self,
2777 context_tag: types::ContextTag,
2778 pname: types::Card32,
2779 datum: types::Int32,
2780 ) -> Result<Cookie<()>> {
2781 let span = tracing::info_span!(
2782 "glx_pixel_storei",
2783 context_tag = ?context_tag,
2784 pname = ?pname,
2785 datum = ?datum,
2786 );
2787 let _enter = span.enter();
2788 let request = types::glx::PixelStoreiRequest {
2789 context_tag,
2790 pname,
2791 datum,
2792 };
2793 let cookie = self.send_void_request(request, true);
2794 cookie
2795 }
2796 #[cfg(feature = "glx")]
2797 fn glx_pixel_storei_checked(
2798 &mut self,
2799 context_tag: types::ContextTag,
2800 pname: types::Card32,
2801 datum: types::Int32,
2802 ) -> Result<()> {
2803 let request = types::glx::PixelStoreiRequest {
2804 context_tag,
2805 pname,
2806 datum,
2807 };
2808 let cookie = self.send_void_request(request, false)?;
2809 self.wait_for_reply(cookie)
2810 }
2811 #[cfg(feature = "glx")]
2812 fn glx_read_pixels(
2813 &mut self,
2814 context_tag: types::ContextTag,
2815 x: types::Int32,
2816 y: types::Int32,
2817 width: types::Int32,
2818 height: types::Int32,
2819 format: types::Card32,
2820 type_: types::Card32,
2821 swap_bytes: types::Bool,
2822 lsb_first: types::Bool,
2823 ) -> Result<Cookie<types::glx::ReadPixelsReply>> {
2824 let span = tracing::info_span!(
2825 "glx_read_pixels",
2826 context_tag = ?context_tag,
2827 x = ?x,
2828 y = ?y,
2829 width = ?width,
2830 height = ?height,
2831 format = ?format,
2832 type_ = ?type_,
2833 swap_bytes = ?swap_bytes,
2834 lsb_first = ?lsb_first,
2835 );
2836 let _enter = span.enter();
2837 let request = types::glx::ReadPixelsRequest {
2838 context_tag,
2839 x,
2840 y,
2841 width,
2842 height,
2843 format,
2844 type_,
2845 swap_bytes,
2846 lsb_first,
2847 };
2848 let cookie = self.send_reply_request(request);
2849 cookie
2850 }
2851 #[cfg(feature = "glx")]
2852 fn glx_read_pixels_immediate(
2853 &mut self,
2854 context_tag: types::ContextTag,
2855 x: types::Int32,
2856 y: types::Int32,
2857 width: types::Int32,
2858 height: types::Int32,
2859 format: types::Card32,
2860 type_: types::Card32,
2861 swap_bytes: types::Bool,
2862 lsb_first: types::Bool,
2863 ) -> Result<types::glx::ReadPixelsReply> {
2864 let request = types::glx::ReadPixelsRequest {
2865 context_tag,
2866 x,
2867 y,
2868 width,
2869 height,
2870 format,
2871 type_,
2872 swap_bytes,
2873 lsb_first,
2874 };
2875 let cookie = self.send_reply_request(request)?;
2876 self.wait_for_reply(cookie)
2877 }
2878 #[cfg(feature = "glx")]
2879 fn glx_get_booleanv(
2880 &mut self,
2881 context_tag: types::ContextTag,
2882 pname: types::Int32,
2883 ) -> Result<Cookie<types::glx::GetBooleanvReply>> {
2884 let span = tracing::info_span!(
2885 "glx_get_booleanv",
2886 context_tag = ?context_tag,
2887 pname = ?pname,
2888 );
2889 let _enter = span.enter();
2890 let request = types::glx::GetBooleanvRequest { context_tag, pname };
2891 let cookie = self.send_reply_request(request);
2892 cookie
2893 }
2894 #[cfg(feature = "glx")]
2895 fn glx_get_booleanv_immediate(
2896 &mut self,
2897 context_tag: types::ContextTag,
2898 pname: types::Int32,
2899 ) -> Result<types::glx::GetBooleanvReply> {
2900 let request = types::glx::GetBooleanvRequest { context_tag, pname };
2901 let cookie = self.send_reply_request(request)?;
2902 self.wait_for_reply(cookie)
2903 }
2904 #[cfg(feature = "glx")]
2905 fn glx_get_clip_plane(
2906 &mut self,
2907 context_tag: types::ContextTag,
2908 plane: types::Int32,
2909 ) -> Result<Cookie<types::glx::GetClipPlaneReply>> {
2910 let span = tracing::info_span!(
2911 "glx_get_clip_plane",
2912 context_tag = ?context_tag,
2913 plane = ?plane,
2914 );
2915 let _enter = span.enter();
2916 let request = types::glx::GetClipPlaneRequest { context_tag, plane };
2917 let cookie = self.send_reply_request(request);
2918 cookie
2919 }
2920 #[cfg(feature = "glx")]
2921 fn glx_get_clip_plane_immediate(
2922 &mut self,
2923 context_tag: types::ContextTag,
2924 plane: types::Int32,
2925 ) -> Result<types::glx::GetClipPlaneReply> {
2926 let request = types::glx::GetClipPlaneRequest { context_tag, plane };
2927 let cookie = self.send_reply_request(request)?;
2928 self.wait_for_reply(cookie)
2929 }
2930 #[cfg(feature = "glx")]
2931 fn glx_get_doublev(
2932 &mut self,
2933 context_tag: types::ContextTag,
2934 pname: types::Card32,
2935 ) -> Result<Cookie<types::glx::GetDoublevReply>> {
2936 let span = tracing::info_span!(
2937 "glx_get_doublev",
2938 context_tag = ?context_tag,
2939 pname = ?pname,
2940 );
2941 let _enter = span.enter();
2942 let request = types::glx::GetDoublevRequest { context_tag, pname };
2943 let cookie = self.send_reply_request(request);
2944 cookie
2945 }
2946 #[cfg(feature = "glx")]
2947 fn glx_get_doublev_immediate(
2948 &mut self,
2949 context_tag: types::ContextTag,
2950 pname: types::Card32,
2951 ) -> Result<types::glx::GetDoublevReply> {
2952 let request = types::glx::GetDoublevRequest { context_tag, pname };
2953 let cookie = self.send_reply_request(request)?;
2954 self.wait_for_reply(cookie)
2955 }
2956 #[cfg(feature = "glx")]
2957 fn glx_get_error(
2958 &mut self,
2959 context_tag: types::ContextTag,
2960 ) -> Result<Cookie<types::glx::GetErrorReply>> {
2961 let span = tracing::info_span!(
2962 "glx_get_error",
2963 context_tag = ?context_tag,
2964 );
2965 let _enter = span.enter();
2966 let request = types::glx::GetErrorRequest { context_tag };
2967 let cookie = self.send_reply_request(request);
2968 cookie
2969 }
2970 #[cfg(feature = "glx")]
2971 fn glx_get_error_immediate(
2972 &mut self,
2973 context_tag: types::ContextTag,
2974 ) -> Result<types::glx::GetErrorReply> {
2975 let request = types::glx::GetErrorRequest { context_tag };
2976 let cookie = self.send_reply_request(request)?;
2977 self.wait_for_reply(cookie)
2978 }
2979 #[cfg(feature = "glx")]
2980 fn glx_get_floatv(
2981 &mut self,
2982 context_tag: types::ContextTag,
2983 pname: types::Card32,
2984 ) -> Result<Cookie<types::glx::GetFloatvReply>> {
2985 let span = tracing::info_span!(
2986 "glx_get_floatv",
2987 context_tag = ?context_tag,
2988 pname = ?pname,
2989 );
2990 let _enter = span.enter();
2991 let request = types::glx::GetFloatvRequest { context_tag, pname };
2992 let cookie = self.send_reply_request(request);
2993 cookie
2994 }
2995 #[cfg(feature = "glx")]
2996 fn glx_get_floatv_immediate(
2997 &mut self,
2998 context_tag: types::ContextTag,
2999 pname: types::Card32,
3000 ) -> Result<types::glx::GetFloatvReply> {
3001 let request = types::glx::GetFloatvRequest { context_tag, pname };
3002 let cookie = self.send_reply_request(request)?;
3003 self.wait_for_reply(cookie)
3004 }
3005 #[cfg(feature = "glx")]
3006 fn glx_get_integerv(
3007 &mut self,
3008 context_tag: types::ContextTag,
3009 pname: types::Card32,
3010 ) -> Result<Cookie<types::glx::GetIntegervReply>> {
3011 let span = tracing::info_span!(
3012 "glx_get_integerv",
3013 context_tag = ?context_tag,
3014 pname = ?pname,
3015 );
3016 let _enter = span.enter();
3017 let request = types::glx::GetIntegervRequest { context_tag, pname };
3018 let cookie = self.send_reply_request(request);
3019 cookie
3020 }
3021 #[cfg(feature = "glx")]
3022 fn glx_get_integerv_immediate(
3023 &mut self,
3024 context_tag: types::ContextTag,
3025 pname: types::Card32,
3026 ) -> Result<types::glx::GetIntegervReply> {
3027 let request = types::glx::GetIntegervRequest { context_tag, pname };
3028 let cookie = self.send_reply_request(request)?;
3029 self.wait_for_reply(cookie)
3030 }
3031 #[cfg(feature = "glx")]
3032 fn glx_get_lightfv(
3033 &mut self,
3034 context_tag: types::ContextTag,
3035 light: types::Card32,
3036 pname: types::Card32,
3037 ) -> Result<Cookie<types::glx::GetLightfvReply>> {
3038 let span = tracing::info_span!(
3039 "glx_get_lightfv",
3040 context_tag = ?context_tag,
3041 light = ?light,
3042 pname = ?pname,
3043 );
3044 let _enter = span.enter();
3045 let request = types::glx::GetLightfvRequest {
3046 context_tag,
3047 light,
3048 pname,
3049 };
3050 let cookie = self.send_reply_request(request);
3051 cookie
3052 }
3053 #[cfg(feature = "glx")]
3054 fn glx_get_lightfv_immediate(
3055 &mut self,
3056 context_tag: types::ContextTag,
3057 light: types::Card32,
3058 pname: types::Card32,
3059 ) -> Result<types::glx::GetLightfvReply> {
3060 let request = types::glx::GetLightfvRequest {
3061 context_tag,
3062 light,
3063 pname,
3064 };
3065 let cookie = self.send_reply_request(request)?;
3066 self.wait_for_reply(cookie)
3067 }
3068 #[cfg(feature = "glx")]
3069 fn glx_get_lightiv(
3070 &mut self,
3071 context_tag: types::ContextTag,
3072 light: types::Card32,
3073 pname: types::Card32,
3074 ) -> Result<Cookie<types::glx::GetLightivReply>> {
3075 let span = tracing::info_span!(
3076 "glx_get_lightiv",
3077 context_tag = ?context_tag,
3078 light = ?light,
3079 pname = ?pname,
3080 );
3081 let _enter = span.enter();
3082 let request = types::glx::GetLightivRequest {
3083 context_tag,
3084 light,
3085 pname,
3086 };
3087 let cookie = self.send_reply_request(request);
3088 cookie
3089 }
3090 #[cfg(feature = "glx")]
3091 fn glx_get_lightiv_immediate(
3092 &mut self,
3093 context_tag: types::ContextTag,
3094 light: types::Card32,
3095 pname: types::Card32,
3096 ) -> Result<types::glx::GetLightivReply> {
3097 let request = types::glx::GetLightivRequest {
3098 context_tag,
3099 light,
3100 pname,
3101 };
3102 let cookie = self.send_reply_request(request)?;
3103 self.wait_for_reply(cookie)
3104 }
3105 #[cfg(feature = "glx")]
3106 fn glx_get_mapdv(
3107 &mut self,
3108 context_tag: types::ContextTag,
3109 target: types::Card32,
3110 query: types::Card32,
3111 ) -> Result<Cookie<types::glx::GetMapdvReply>> {
3112 let span = tracing::info_span!(
3113 "glx_get_mapdv",
3114 context_tag = ?context_tag,
3115 target = ?target,
3116 query = ?query,
3117 );
3118 let _enter = span.enter();
3119 let request = types::glx::GetMapdvRequest {
3120 context_tag,
3121 target,
3122 query,
3123 };
3124 let cookie = self.send_reply_request(request);
3125 cookie
3126 }
3127 #[cfg(feature = "glx")]
3128 fn glx_get_mapdv_immediate(
3129 &mut self,
3130 context_tag: types::ContextTag,
3131 target: types::Card32,
3132 query: types::Card32,
3133 ) -> Result<types::glx::GetMapdvReply> {
3134 let request = types::glx::GetMapdvRequest {
3135 context_tag,
3136 target,
3137 query,
3138 };
3139 let cookie = self.send_reply_request(request)?;
3140 self.wait_for_reply(cookie)
3141 }
3142 #[cfg(feature = "glx")]
3143 fn glx_get_mapfv(
3144 &mut self,
3145 context_tag: types::ContextTag,
3146 target: types::Card32,
3147 query: types::Card32,
3148 ) -> Result<Cookie<types::glx::GetMapfvReply>> {
3149 let span = tracing::info_span!(
3150 "glx_get_mapfv",
3151 context_tag = ?context_tag,
3152 target = ?target,
3153 query = ?query,
3154 );
3155 let _enter = span.enter();
3156 let request = types::glx::GetMapfvRequest {
3157 context_tag,
3158 target,
3159 query,
3160 };
3161 let cookie = self.send_reply_request(request);
3162 cookie
3163 }
3164 #[cfg(feature = "glx")]
3165 fn glx_get_mapfv_immediate(
3166 &mut self,
3167 context_tag: types::ContextTag,
3168 target: types::Card32,
3169 query: types::Card32,
3170 ) -> Result<types::glx::GetMapfvReply> {
3171 let request = types::glx::GetMapfvRequest {
3172 context_tag,
3173 target,
3174 query,
3175 };
3176 let cookie = self.send_reply_request(request)?;
3177 self.wait_for_reply(cookie)
3178 }
3179 #[cfg(feature = "glx")]
3180 fn glx_get_mapiv(
3181 &mut self,
3182 context_tag: types::ContextTag,
3183 target: types::Card32,
3184 query: types::Card32,
3185 ) -> Result<Cookie<types::glx::GetMapivReply>> {
3186 let span = tracing::info_span!(
3187 "glx_get_mapiv",
3188 context_tag = ?context_tag,
3189 target = ?target,
3190 query = ?query,
3191 );
3192 let _enter = span.enter();
3193 let request = types::glx::GetMapivRequest {
3194 context_tag,
3195 target,
3196 query,
3197 };
3198 let cookie = self.send_reply_request(request);
3199 cookie
3200 }
3201 #[cfg(feature = "glx")]
3202 fn glx_get_mapiv_immediate(
3203 &mut self,
3204 context_tag: types::ContextTag,
3205 target: types::Card32,
3206 query: types::Card32,
3207 ) -> Result<types::glx::GetMapivReply> {
3208 let request = types::glx::GetMapivRequest {
3209 context_tag,
3210 target,
3211 query,
3212 };
3213 let cookie = self.send_reply_request(request)?;
3214 self.wait_for_reply(cookie)
3215 }
3216 #[cfg(feature = "glx")]
3217 fn glx_get_materialfv(
3218 &mut self,
3219 context_tag: types::ContextTag,
3220 face: types::Card32,
3221 pname: types::Card32,
3222 ) -> Result<Cookie<types::glx::GetMaterialfvReply>> {
3223 let span = tracing::info_span!(
3224 "glx_get_materialfv",
3225 context_tag = ?context_tag,
3226 face = ?face,
3227 pname = ?pname,
3228 );
3229 let _enter = span.enter();
3230 let request = types::glx::GetMaterialfvRequest {
3231 context_tag,
3232 face,
3233 pname,
3234 };
3235 let cookie = self.send_reply_request(request);
3236 cookie
3237 }
3238 #[cfg(feature = "glx")]
3239 fn glx_get_materialfv_immediate(
3240 &mut self,
3241 context_tag: types::ContextTag,
3242 face: types::Card32,
3243 pname: types::Card32,
3244 ) -> Result<types::glx::GetMaterialfvReply> {
3245 let request = types::glx::GetMaterialfvRequest {
3246 context_tag,
3247 face,
3248 pname,
3249 };
3250 let cookie = self.send_reply_request(request)?;
3251 self.wait_for_reply(cookie)
3252 }
3253 #[cfg(feature = "glx")]
3254 fn glx_get_materialiv(
3255 &mut self,
3256 context_tag: types::ContextTag,
3257 face: types::Card32,
3258 pname: types::Card32,
3259 ) -> Result<Cookie<types::glx::GetMaterialivReply>> {
3260 let span = tracing::info_span!(
3261 "glx_get_materialiv",
3262 context_tag = ?context_tag,
3263 face = ?face,
3264 pname = ?pname,
3265 );
3266 let _enter = span.enter();
3267 let request = types::glx::GetMaterialivRequest {
3268 context_tag,
3269 face,
3270 pname,
3271 };
3272 let cookie = self.send_reply_request(request);
3273 cookie
3274 }
3275 #[cfg(feature = "glx")]
3276 fn glx_get_materialiv_immediate(
3277 &mut self,
3278 context_tag: types::ContextTag,
3279 face: types::Card32,
3280 pname: types::Card32,
3281 ) -> Result<types::glx::GetMaterialivReply> {
3282 let request = types::glx::GetMaterialivRequest {
3283 context_tag,
3284 face,
3285 pname,
3286 };
3287 let cookie = self.send_reply_request(request)?;
3288 self.wait_for_reply(cookie)
3289 }
3290 #[cfg(feature = "glx")]
3291 fn glx_get_pixel_mapfv(
3292 &mut self,
3293 context_tag: types::ContextTag,
3294 map: types::Card32,
3295 ) -> Result<Cookie<types::glx::GetPixelMapfvReply>> {
3296 let span = tracing::info_span!(
3297 "glx_get_pixel_mapfv",
3298 context_tag = ?context_tag,
3299 map = ?map,
3300 );
3301 let _enter = span.enter();
3302 let request = types::glx::GetPixelMapfvRequest { context_tag, map };
3303 let cookie = self.send_reply_request(request);
3304 cookie
3305 }
3306 #[cfg(feature = "glx")]
3307 fn glx_get_pixel_mapfv_immediate(
3308 &mut self,
3309 context_tag: types::ContextTag,
3310 map: types::Card32,
3311 ) -> Result<types::glx::GetPixelMapfvReply> {
3312 let request = types::glx::GetPixelMapfvRequest { context_tag, map };
3313 let cookie = self.send_reply_request(request)?;
3314 self.wait_for_reply(cookie)
3315 }
3316 #[cfg(feature = "glx")]
3317 fn glx_get_pixel_mapuiv(
3318 &mut self,
3319 context_tag: types::ContextTag,
3320 map: types::Card32,
3321 ) -> Result<Cookie<types::glx::GetPixelMapuivReply>> {
3322 let span = tracing::info_span!(
3323 "glx_get_pixel_mapuiv",
3324 context_tag = ?context_tag,
3325 map = ?map,
3326 );
3327 let _enter = span.enter();
3328 let request = types::glx::GetPixelMapuivRequest { context_tag, map };
3329 let cookie = self.send_reply_request(request);
3330 cookie
3331 }
3332 #[cfg(feature = "glx")]
3333 fn glx_get_pixel_mapuiv_immediate(
3334 &mut self,
3335 context_tag: types::ContextTag,
3336 map: types::Card32,
3337 ) -> Result<types::glx::GetPixelMapuivReply> {
3338 let request = types::glx::GetPixelMapuivRequest { context_tag, map };
3339 let cookie = self.send_reply_request(request)?;
3340 self.wait_for_reply(cookie)
3341 }
3342 #[cfg(feature = "glx")]
3343 fn glx_get_pixel_mapusv(
3344 &mut self,
3345 context_tag: types::ContextTag,
3346 map: types::Card32,
3347 ) -> Result<Cookie<types::glx::GetPixelMapusvReply>> {
3348 let span = tracing::info_span!(
3349 "glx_get_pixel_mapusv",
3350 context_tag = ?context_tag,
3351 map = ?map,
3352 );
3353 let _enter = span.enter();
3354 let request = types::glx::GetPixelMapusvRequest { context_tag, map };
3355 let cookie = self.send_reply_request(request);
3356 cookie
3357 }
3358 #[cfg(feature = "glx")]
3359 fn glx_get_pixel_mapusv_immediate(
3360 &mut self,
3361 context_tag: types::ContextTag,
3362 map: types::Card32,
3363 ) -> Result<types::glx::GetPixelMapusvReply> {
3364 let request = types::glx::GetPixelMapusvRequest { context_tag, map };
3365 let cookie = self.send_reply_request(request)?;
3366 self.wait_for_reply(cookie)
3367 }
3368 #[cfg(feature = "glx")]
3369 fn glx_get_polygon_stipple(
3370 &mut self,
3371 context_tag: types::ContextTag,
3372 lsb_first: types::Bool,
3373 ) -> Result<Cookie<types::glx::GetPolygonStippleReply>> {
3374 let span = tracing::info_span!(
3375 "glx_get_polygon_stipple",
3376 context_tag = ?context_tag,
3377 lsb_first = ?lsb_first,
3378 );
3379 let _enter = span.enter();
3380 let request = types::glx::GetPolygonStippleRequest {
3381 context_tag,
3382 lsb_first,
3383 };
3384 let cookie = self.send_reply_request(request);
3385 cookie
3386 }
3387 #[cfg(feature = "glx")]
3388 fn glx_get_polygon_stipple_immediate(
3389 &mut self,
3390 context_tag: types::ContextTag,
3391 lsb_first: types::Bool,
3392 ) -> Result<types::glx::GetPolygonStippleReply> {
3393 let request = types::glx::GetPolygonStippleRequest {
3394 context_tag,
3395 lsb_first,
3396 };
3397 let cookie = self.send_reply_request(request)?;
3398 self.wait_for_reply(cookie)
3399 }
3400 #[cfg(feature = "glx")]
3401 fn glx_get_string(
3402 &mut self,
3403 context_tag: types::ContextTag,
3404 name: types::Card32,
3405 ) -> Result<Cookie<types::glx::GetStringReply>> {
3406 let span = tracing::info_span!(
3407 "glx_get_string",
3408 context_tag = ?context_tag,
3409 name = ?name,
3410 );
3411 let _enter = span.enter();
3412 let request = types::glx::GetStringRequest { context_tag, name };
3413 let cookie = self.send_reply_request(request);
3414 cookie
3415 }
3416 #[cfg(feature = "glx")]
3417 fn glx_get_string_immediate(
3418 &mut self,
3419 context_tag: types::ContextTag,
3420 name: types::Card32,
3421 ) -> Result<types::glx::GetStringReply> {
3422 let request = types::glx::GetStringRequest { context_tag, name };
3423 let cookie = self.send_reply_request(request)?;
3424 self.wait_for_reply(cookie)
3425 }
3426 #[cfg(feature = "glx")]
3427 fn glx_get_tex_envfv(
3428 &mut self,
3429 context_tag: types::ContextTag,
3430 target: types::Card32,
3431 pname: types::Card32,
3432 ) -> Result<Cookie<types::glx::GetTexEnvfvReply>> {
3433 let span = tracing::info_span!(
3434 "glx_get_tex_envfv",
3435 context_tag = ?context_tag,
3436 target = ?target,
3437 pname = ?pname,
3438 );
3439 let _enter = span.enter();
3440 let request = types::glx::GetTexEnvfvRequest {
3441 context_tag,
3442 target,
3443 pname,
3444 };
3445 let cookie = self.send_reply_request(request);
3446 cookie
3447 }
3448 #[cfg(feature = "glx")]
3449 fn glx_get_tex_envfv_immediate(
3450 &mut self,
3451 context_tag: types::ContextTag,
3452 target: types::Card32,
3453 pname: types::Card32,
3454 ) -> Result<types::glx::GetTexEnvfvReply> {
3455 let request = types::glx::GetTexEnvfvRequest {
3456 context_tag,
3457 target,
3458 pname,
3459 };
3460 let cookie = self.send_reply_request(request)?;
3461 self.wait_for_reply(cookie)
3462 }
3463 #[cfg(feature = "glx")]
3464 fn glx_get_tex_enviv(
3465 &mut self,
3466 context_tag: types::ContextTag,
3467 target: types::Card32,
3468 pname: types::Card32,
3469 ) -> Result<Cookie<types::glx::GetTexEnvivReply>> {
3470 let span = tracing::info_span!(
3471 "glx_get_tex_enviv",
3472 context_tag = ?context_tag,
3473 target = ?target,
3474 pname = ?pname,
3475 );
3476 let _enter = span.enter();
3477 let request = types::glx::GetTexEnvivRequest {
3478 context_tag,
3479 target,
3480 pname,
3481 };
3482 let cookie = self.send_reply_request(request);
3483 cookie
3484 }
3485 #[cfg(feature = "glx")]
3486 fn glx_get_tex_enviv_immediate(
3487 &mut self,
3488 context_tag: types::ContextTag,
3489 target: types::Card32,
3490 pname: types::Card32,
3491 ) -> Result<types::glx::GetTexEnvivReply> {
3492 let request = types::glx::GetTexEnvivRequest {
3493 context_tag,
3494 target,
3495 pname,
3496 };
3497 let cookie = self.send_reply_request(request)?;
3498 self.wait_for_reply(cookie)
3499 }
3500 #[cfg(feature = "glx")]
3501 fn glx_get_tex_gendv(
3502 &mut self,
3503 context_tag: types::ContextTag,
3504 coord: types::Card32,
3505 pname: types::Card32,
3506 ) -> Result<Cookie<types::glx::GetTexGendvReply>> {
3507 let span = tracing::info_span!(
3508 "glx_get_tex_gendv",
3509 context_tag = ?context_tag,
3510 coord = ?coord,
3511 pname = ?pname,
3512 );
3513 let _enter = span.enter();
3514 let request = types::glx::GetTexGendvRequest {
3515 context_tag,
3516 coord,
3517 pname,
3518 };
3519 let cookie = self.send_reply_request(request);
3520 cookie
3521 }
3522 #[cfg(feature = "glx")]
3523 fn glx_get_tex_gendv_immediate(
3524 &mut self,
3525 context_tag: types::ContextTag,
3526 coord: types::Card32,
3527 pname: types::Card32,
3528 ) -> Result<types::glx::GetTexGendvReply> {
3529 let request = types::glx::GetTexGendvRequest {
3530 context_tag,
3531 coord,
3532 pname,
3533 };
3534 let cookie = self.send_reply_request(request)?;
3535 self.wait_for_reply(cookie)
3536 }
3537 #[cfg(feature = "glx")]
3538 fn glx_get_tex_genfv(
3539 &mut self,
3540 context_tag: types::ContextTag,
3541 coord: types::Card32,
3542 pname: types::Card32,
3543 ) -> Result<Cookie<types::glx::GetTexGenfvReply>> {
3544 let span = tracing::info_span!(
3545 "glx_get_tex_genfv",
3546 context_tag = ?context_tag,
3547 coord = ?coord,
3548 pname = ?pname,
3549 );
3550 let _enter = span.enter();
3551 let request = types::glx::GetTexGenfvRequest {
3552 context_tag,
3553 coord,
3554 pname,
3555 };
3556 let cookie = self.send_reply_request(request);
3557 cookie
3558 }
3559 #[cfg(feature = "glx")]
3560 fn glx_get_tex_genfv_immediate(
3561 &mut self,
3562 context_tag: types::ContextTag,
3563 coord: types::Card32,
3564 pname: types::Card32,
3565 ) -> Result<types::glx::GetTexGenfvReply> {
3566 let request = types::glx::GetTexGenfvRequest {
3567 context_tag,
3568 coord,
3569 pname,
3570 };
3571 let cookie = self.send_reply_request(request)?;
3572 self.wait_for_reply(cookie)
3573 }
3574 #[cfg(feature = "glx")]
3575 fn glx_get_tex_geniv(
3576 &mut self,
3577 context_tag: types::ContextTag,
3578 coord: types::Card32,
3579 pname: types::Card32,
3580 ) -> Result<Cookie<types::glx::GetTexGenivReply>> {
3581 let span = tracing::info_span!(
3582 "glx_get_tex_geniv",
3583 context_tag = ?context_tag,
3584 coord = ?coord,
3585 pname = ?pname,
3586 );
3587 let _enter = span.enter();
3588 let request = types::glx::GetTexGenivRequest {
3589 context_tag,
3590 coord,
3591 pname,
3592 };
3593 let cookie = self.send_reply_request(request);
3594 cookie
3595 }
3596 #[cfg(feature = "glx")]
3597 fn glx_get_tex_geniv_immediate(
3598 &mut self,
3599 context_tag: types::ContextTag,
3600 coord: types::Card32,
3601 pname: types::Card32,
3602 ) -> Result<types::glx::GetTexGenivReply> {
3603 let request = types::glx::GetTexGenivRequest {
3604 context_tag,
3605 coord,
3606 pname,
3607 };
3608 let cookie = self.send_reply_request(request)?;
3609 self.wait_for_reply(cookie)
3610 }
3611 #[cfg(feature = "glx")]
3612 fn glx_get_tex_image(
3613 &mut self,
3614 context_tag: types::ContextTag,
3615 target: types::Card32,
3616 level: types::Int32,
3617 format: types::Card32,
3618 type_: types::Card32,
3619 swap_bytes: types::Bool,
3620 ) -> Result<Cookie<types::glx::GetTexImageReply>> {
3621 let span = tracing::info_span!(
3622 "glx_get_tex_image",
3623 context_tag = ?context_tag,
3624 target = ?target,
3625 level = ?level,
3626 format = ?format,
3627 type_ = ?type_,
3628 swap_bytes = ?swap_bytes,
3629 );
3630 let _enter = span.enter();
3631 let request = types::glx::GetTexImageRequest {
3632 context_tag,
3633 target,
3634 level,
3635 format,
3636 type_,
3637 swap_bytes,
3638 };
3639 let cookie = self.send_reply_request(request);
3640 cookie
3641 }
3642 #[cfg(feature = "glx")]
3643 fn glx_get_tex_image_immediate(
3644 &mut self,
3645 context_tag: types::ContextTag,
3646 target: types::Card32,
3647 level: types::Int32,
3648 format: types::Card32,
3649 type_: types::Card32,
3650 swap_bytes: types::Bool,
3651 ) -> Result<types::glx::GetTexImageReply> {
3652 let request = types::glx::GetTexImageRequest {
3653 context_tag,
3654 target,
3655 level,
3656 format,
3657 type_,
3658 swap_bytes,
3659 };
3660 let cookie = self.send_reply_request(request)?;
3661 self.wait_for_reply(cookie)
3662 }
3663 #[cfg(feature = "glx")]
3664 fn glx_get_tex_parameterfv(
3665 &mut self,
3666 context_tag: types::ContextTag,
3667 target: types::Card32,
3668 pname: types::Card32,
3669 ) -> Result<Cookie<types::glx::GetTexParameterfvReply>> {
3670 let span = tracing::info_span!(
3671 "glx_get_tex_parameterfv",
3672 context_tag = ?context_tag,
3673 target = ?target,
3674 pname = ?pname,
3675 );
3676 let _enter = span.enter();
3677 let request = types::glx::GetTexParameterfvRequest {
3678 context_tag,
3679 target,
3680 pname,
3681 };
3682 let cookie = self.send_reply_request(request);
3683 cookie
3684 }
3685 #[cfg(feature = "glx")]
3686 fn glx_get_tex_parameterfv_immediate(
3687 &mut self,
3688 context_tag: types::ContextTag,
3689 target: types::Card32,
3690 pname: types::Card32,
3691 ) -> Result<types::glx::GetTexParameterfvReply> {
3692 let request = types::glx::GetTexParameterfvRequest {
3693 context_tag,
3694 target,
3695 pname,
3696 };
3697 let cookie = self.send_reply_request(request)?;
3698 self.wait_for_reply(cookie)
3699 }
3700 #[cfg(feature = "glx")]
3701 fn glx_get_tex_parameteriv(
3702 &mut self,
3703 context_tag: types::ContextTag,
3704 target: types::Card32,
3705 pname: types::Card32,
3706 ) -> Result<Cookie<types::glx::GetTexParameterivReply>> {
3707 let span = tracing::info_span!(
3708 "glx_get_tex_parameteriv",
3709 context_tag = ?context_tag,
3710 target = ?target,
3711 pname = ?pname,
3712 );
3713 let _enter = span.enter();
3714 let request = types::glx::GetTexParameterivRequest {
3715 context_tag,
3716 target,
3717 pname,
3718 };
3719 let cookie = self.send_reply_request(request);
3720 cookie
3721 }
3722 #[cfg(feature = "glx")]
3723 fn glx_get_tex_parameteriv_immediate(
3724 &mut self,
3725 context_tag: types::ContextTag,
3726 target: types::Card32,
3727 pname: types::Card32,
3728 ) -> Result<types::glx::GetTexParameterivReply> {
3729 let request = types::glx::GetTexParameterivRequest {
3730 context_tag,
3731 target,
3732 pname,
3733 };
3734 let cookie = self.send_reply_request(request)?;
3735 self.wait_for_reply(cookie)
3736 }
3737 #[cfg(feature = "glx")]
3738 fn glx_get_tex_level_parameterfv(
3739 &mut self,
3740 context_tag: types::ContextTag,
3741 target: types::Card32,
3742 level: types::Int32,
3743 pname: types::Card32,
3744 ) -> Result<Cookie<types::glx::GetTexLevelParameterfvReply>> {
3745 let span = tracing::info_span!(
3746 "glx_get_tex_level_parameterfv",
3747 context_tag = ?context_tag,
3748 target = ?target,
3749 level = ?level,
3750 pname = ?pname,
3751 );
3752 let _enter = span.enter();
3753 let request = types::glx::GetTexLevelParameterfvRequest {
3754 context_tag,
3755 target,
3756 level,
3757 pname,
3758 };
3759 let cookie = self.send_reply_request(request);
3760 cookie
3761 }
3762 #[cfg(feature = "glx")]
3763 fn glx_get_tex_level_parameterfv_immediate(
3764 &mut self,
3765 context_tag: types::ContextTag,
3766 target: types::Card32,
3767 level: types::Int32,
3768 pname: types::Card32,
3769 ) -> Result<types::glx::GetTexLevelParameterfvReply> {
3770 let request = types::glx::GetTexLevelParameterfvRequest {
3771 context_tag,
3772 target,
3773 level,
3774 pname,
3775 };
3776 let cookie = self.send_reply_request(request)?;
3777 self.wait_for_reply(cookie)
3778 }
3779 #[cfg(feature = "glx")]
3780 fn glx_get_tex_level_parameteriv(
3781 &mut self,
3782 context_tag: types::ContextTag,
3783 target: types::Card32,
3784 level: types::Int32,
3785 pname: types::Card32,
3786 ) -> Result<Cookie<types::glx::GetTexLevelParameterivReply>> {
3787 let span = tracing::info_span!(
3788 "glx_get_tex_level_parameteriv",
3789 context_tag = ?context_tag,
3790 target = ?target,
3791 level = ?level,
3792 pname = ?pname,
3793 );
3794 let _enter = span.enter();
3795 let request = types::glx::GetTexLevelParameterivRequest {
3796 context_tag,
3797 target,
3798 level,
3799 pname,
3800 };
3801 let cookie = self.send_reply_request(request);
3802 cookie
3803 }
3804 #[cfg(feature = "glx")]
3805 fn glx_get_tex_level_parameteriv_immediate(
3806 &mut self,
3807 context_tag: types::ContextTag,
3808 target: types::Card32,
3809 level: types::Int32,
3810 pname: types::Card32,
3811 ) -> Result<types::glx::GetTexLevelParameterivReply> {
3812 let request = types::glx::GetTexLevelParameterivRequest {
3813 context_tag,
3814 target,
3815 level,
3816 pname,
3817 };
3818 let cookie = self.send_reply_request(request)?;
3819 self.wait_for_reply(cookie)
3820 }
3821 #[cfg(feature = "glx")]
3822 fn glx_is_enabled(
3823 &mut self,
3824 context_tag: types::ContextTag,
3825 capability: types::Card32,
3826 ) -> Result<Cookie<types::glx::IsEnabledReply>> {
3827 let span = tracing::info_span!(
3828 "glx_is_enabled",
3829 context_tag = ?context_tag,
3830 capability = ?capability,
3831 );
3832 let _enter = span.enter();
3833 let request = types::glx::IsEnabledRequest {
3834 context_tag,
3835 capability,
3836 };
3837 let cookie = self.send_reply_request(request);
3838 cookie
3839 }
3840 #[cfg(feature = "glx")]
3841 fn glx_is_enabled_immediate(
3842 &mut self,
3843 context_tag: types::ContextTag,
3844 capability: types::Card32,
3845 ) -> Result<types::glx::IsEnabledReply> {
3846 let request = types::glx::IsEnabledRequest {
3847 context_tag,
3848 capability,
3849 };
3850 let cookie = self.send_reply_request(request)?;
3851 self.wait_for_reply(cookie)
3852 }
3853 #[cfg(feature = "glx")]
3854 fn glx_is_list(
3855 &mut self,
3856 context_tag: types::ContextTag,
3857 list: types::Card32,
3858 ) -> Result<Cookie<types::glx::IsListReply>> {
3859 let span = tracing::info_span!(
3860 "glx_is_list",
3861 context_tag = ?context_tag,
3862 list = ?list,
3863 );
3864 let _enter = span.enter();
3865 let request = types::glx::IsListRequest { context_tag, list };
3866 let cookie = self.send_reply_request(request);
3867 cookie
3868 }
3869 #[cfg(feature = "glx")]
3870 fn glx_is_list_immediate(
3871 &mut self,
3872 context_tag: types::ContextTag,
3873 list: types::Card32,
3874 ) -> Result<types::glx::IsListReply> {
3875 let request = types::glx::IsListRequest { context_tag, list };
3876 let cookie = self.send_reply_request(request)?;
3877 self.wait_for_reply(cookie)
3878 }
3879 #[cfg(feature = "glx")]
3880 fn glx_flush(&mut self, context_tag: types::ContextTag) -> Result<Cookie<()>> {
3881 let span = tracing::info_span!(
3882 "glx_flush",
3883 context_tag = ?context_tag,
3884 );
3885 let _enter = span.enter();
3886 let request = types::glx::FlushRequest { context_tag };
3887 let cookie = self.send_void_request(request, true);
3888 cookie
3889 }
3890 #[cfg(feature = "glx")]
3891 fn glx_flush_checked(&mut self, context_tag: types::ContextTag) -> Result<()> {
3892 let request = types::glx::FlushRequest { context_tag };
3893 let cookie = self.send_void_request(request, false)?;
3894 self.wait_for_reply(cookie)
3895 }
3896 #[cfg(feature = "glx")]
3897 fn glx_are_textures_resident(
3898 &mut self,
3899 context_tag: types::ContextTag,
3900 textures: impl AsRef<[types::Card32]>,
3901 ) -> Result<Cookie<types::glx::AreTexturesResidentReply>> {
3902 let span = tracing::info_span!(
3903 "glx_are_textures_resident",
3904 context_tag = ?context_tag,
3905 );
3906 let _enter = span.enter();
3907 let request = types::glx::AreTexturesResidentRequest {
3908 context_tag,
3909 textures: Cow::Borrowed(textures.as_ref()),
3910 };
3911 let cookie = self.send_reply_request(request);
3912 cookie
3913 }
3914 #[cfg(feature = "glx")]
3915 fn glx_are_textures_resident_immediate(
3916 &mut self,
3917 context_tag: types::ContextTag,
3918 textures: impl AsRef<[types::Card32]>,
3919 ) -> Result<types::glx::AreTexturesResidentReply> {
3920 let request = types::glx::AreTexturesResidentRequest {
3921 context_tag,
3922 textures: Cow::Borrowed(textures.as_ref()),
3923 };
3924 let cookie = self.send_reply_request(request)?;
3925 self.wait_for_reply(cookie)
3926 }
3927 #[cfg(feature = "glx")]
3928 fn glx_delete_textures(
3929 &mut self,
3930 context_tag: types::ContextTag,
3931 textures: impl AsRef<[types::Card32]>,
3932 ) -> Result<Cookie<()>> {
3933 let span = tracing::info_span!(
3934 "glx_delete_textures",
3935 context_tag = ?context_tag,
3936 );
3937 let _enter = span.enter();
3938 let request = types::glx::DeleteTexturesRequest {
3939 context_tag,
3940 textures: Cow::Borrowed(textures.as_ref()),
3941 };
3942 let cookie = self.send_void_request(request, true);
3943 cookie
3944 }
3945 #[cfg(feature = "glx")]
3946 fn glx_delete_textures_checked(
3947 &mut self,
3948 context_tag: types::ContextTag,
3949 textures: impl AsRef<[types::Card32]>,
3950 ) -> Result<()> {
3951 let request = types::glx::DeleteTexturesRequest {
3952 context_tag,
3953 textures: Cow::Borrowed(textures.as_ref()),
3954 };
3955 let cookie = self.send_void_request(request, false)?;
3956 self.wait_for_reply(cookie)
3957 }
3958 #[cfg(feature = "glx")]
3959 fn glx_gen_textures(
3960 &mut self,
3961 context_tag: types::ContextTag,
3962 n: types::Int32,
3963 ) -> Result<Cookie<types::glx::GenTexturesReply>> {
3964 let span = tracing::info_span!(
3965 "glx_gen_textures",
3966 context_tag = ?context_tag,
3967 n = ?n,
3968 );
3969 let _enter = span.enter();
3970 let request = types::glx::GenTexturesRequest { context_tag, n };
3971 let cookie = self.send_reply_request(request);
3972 cookie
3973 }
3974 #[cfg(feature = "glx")]
3975 fn glx_gen_textures_immediate(
3976 &mut self,
3977 context_tag: types::ContextTag,
3978 n: types::Int32,
3979 ) -> Result<types::glx::GenTexturesReply> {
3980 let request = types::glx::GenTexturesRequest { context_tag, n };
3981 let cookie = self.send_reply_request(request)?;
3982 self.wait_for_reply(cookie)
3983 }
3984 #[cfg(feature = "glx")]
3985 fn glx_is_texture(
3986 &mut self,
3987 context_tag: types::ContextTag,
3988 texture: types::Card32,
3989 ) -> Result<Cookie<types::glx::IsTextureReply>> {
3990 let span = tracing::info_span!(
3991 "glx_is_texture",
3992 context_tag = ?context_tag,
3993 texture = ?texture,
3994 );
3995 let _enter = span.enter();
3996 let request = types::glx::IsTextureRequest {
3997 context_tag,
3998 texture,
3999 };
4000 let cookie = self.send_reply_request(request);
4001 cookie
4002 }
4003 #[cfg(feature = "glx")]
4004 fn glx_is_texture_immediate(
4005 &mut self,
4006 context_tag: types::ContextTag,
4007 texture: types::Card32,
4008 ) -> Result<types::glx::IsTextureReply> {
4009 let request = types::glx::IsTextureRequest {
4010 context_tag,
4011 texture,
4012 };
4013 let cookie = self.send_reply_request(request)?;
4014 self.wait_for_reply(cookie)
4015 }
4016 #[cfg(feature = "glx")]
4017 fn glx_get_color_table(
4018 &mut self,
4019 context_tag: types::ContextTag,
4020 target: types::Card32,
4021 format: types::Card32,
4022 type_: types::Card32,
4023 swap_bytes: types::Bool,
4024 ) -> Result<Cookie<types::glx::GetColorTableReply>> {
4025 let span = tracing::info_span!(
4026 "glx_get_color_table",
4027 context_tag = ?context_tag,
4028 target = ?target,
4029 format = ?format,
4030 type_ = ?type_,
4031 swap_bytes = ?swap_bytes,
4032 );
4033 let _enter = span.enter();
4034 let request = types::glx::GetColorTableRequest {
4035 context_tag,
4036 target,
4037 format,
4038 type_,
4039 swap_bytes,
4040 };
4041 let cookie = self.send_reply_request(request);
4042 cookie
4043 }
4044 #[cfg(feature = "glx")]
4045 fn glx_get_color_table_immediate(
4046 &mut self,
4047 context_tag: types::ContextTag,
4048 target: types::Card32,
4049 format: types::Card32,
4050 type_: types::Card32,
4051 swap_bytes: types::Bool,
4052 ) -> Result<types::glx::GetColorTableReply> {
4053 let request = types::glx::GetColorTableRequest {
4054 context_tag,
4055 target,
4056 format,
4057 type_,
4058 swap_bytes,
4059 };
4060 let cookie = self.send_reply_request(request)?;
4061 self.wait_for_reply(cookie)
4062 }
4063 #[cfg(feature = "glx")]
4064 fn glx_get_color_table_parameterfv(
4065 &mut self,
4066 context_tag: types::ContextTag,
4067 target: types::Card32,
4068 pname: types::Card32,
4069 ) -> Result<Cookie<types::glx::GetColorTableParameterfvReply>> {
4070 let span = tracing::info_span!(
4071 "glx_get_color_table_parameterfv",
4072 context_tag = ?context_tag,
4073 target = ?target,
4074 pname = ?pname,
4075 );
4076 let _enter = span.enter();
4077 let request = types::glx::GetColorTableParameterfvRequest {
4078 context_tag,
4079 target,
4080 pname,
4081 };
4082 let cookie = self.send_reply_request(request);
4083 cookie
4084 }
4085 #[cfg(feature = "glx")]
4086 fn glx_get_color_table_parameterfv_immediate(
4087 &mut self,
4088 context_tag: types::ContextTag,
4089 target: types::Card32,
4090 pname: types::Card32,
4091 ) -> Result<types::glx::GetColorTableParameterfvReply> {
4092 let request = types::glx::GetColorTableParameterfvRequest {
4093 context_tag,
4094 target,
4095 pname,
4096 };
4097 let cookie = self.send_reply_request(request)?;
4098 self.wait_for_reply(cookie)
4099 }
4100 #[cfg(feature = "glx")]
4101 fn glx_get_color_table_parameteriv(
4102 &mut self,
4103 context_tag: types::ContextTag,
4104 target: types::Card32,
4105 pname: types::Card32,
4106 ) -> Result<Cookie<types::glx::GetColorTableParameterivReply>> {
4107 let span = tracing::info_span!(
4108 "glx_get_color_table_parameteriv",
4109 context_tag = ?context_tag,
4110 target = ?target,
4111 pname = ?pname,
4112 );
4113 let _enter = span.enter();
4114 let request = types::glx::GetColorTableParameterivRequest {
4115 context_tag,
4116 target,
4117 pname,
4118 };
4119 let cookie = self.send_reply_request(request);
4120 cookie
4121 }
4122 #[cfg(feature = "glx")]
4123 fn glx_get_color_table_parameteriv_immediate(
4124 &mut self,
4125 context_tag: types::ContextTag,
4126 target: types::Card32,
4127 pname: types::Card32,
4128 ) -> Result<types::glx::GetColorTableParameterivReply> {
4129 let request = types::glx::GetColorTableParameterivRequest {
4130 context_tag,
4131 target,
4132 pname,
4133 };
4134 let cookie = self.send_reply_request(request)?;
4135 self.wait_for_reply(cookie)
4136 }
4137 #[cfg(feature = "glx")]
4138 fn glx_get_convolution_filter(
4139 &mut self,
4140 context_tag: types::ContextTag,
4141 target: types::Card32,
4142 format: types::Card32,
4143 type_: types::Card32,
4144 swap_bytes: types::Bool,
4145 ) -> Result<Cookie<types::glx::GetConvolutionFilterReply>> {
4146 let span = tracing::info_span!(
4147 "glx_get_convolution_filter",
4148 context_tag = ?context_tag,
4149 target = ?target,
4150 format = ?format,
4151 type_ = ?type_,
4152 swap_bytes = ?swap_bytes,
4153 );
4154 let _enter = span.enter();
4155 let request = types::glx::GetConvolutionFilterRequest {
4156 context_tag,
4157 target,
4158 format,
4159 type_,
4160 swap_bytes,
4161 };
4162 let cookie = self.send_reply_request(request);
4163 cookie
4164 }
4165 #[cfg(feature = "glx")]
4166 fn glx_get_convolution_filter_immediate(
4167 &mut self,
4168 context_tag: types::ContextTag,
4169 target: types::Card32,
4170 format: types::Card32,
4171 type_: types::Card32,
4172 swap_bytes: types::Bool,
4173 ) -> Result<types::glx::GetConvolutionFilterReply> {
4174 let request = types::glx::GetConvolutionFilterRequest {
4175 context_tag,
4176 target,
4177 format,
4178 type_,
4179 swap_bytes,
4180 };
4181 let cookie = self.send_reply_request(request)?;
4182 self.wait_for_reply(cookie)
4183 }
4184 #[cfg(feature = "glx")]
4185 fn glx_get_convolution_parameterfv(
4186 &mut self,
4187 context_tag: types::ContextTag,
4188 target: types::Card32,
4189 pname: types::Card32,
4190 ) -> Result<Cookie<types::glx::GetConvolutionParameterfvReply>> {
4191 let span = tracing::info_span!(
4192 "glx_get_convolution_parameterfv",
4193 context_tag = ?context_tag,
4194 target = ?target,
4195 pname = ?pname,
4196 );
4197 let _enter = span.enter();
4198 let request = types::glx::GetConvolutionParameterfvRequest {
4199 context_tag,
4200 target,
4201 pname,
4202 };
4203 let cookie = self.send_reply_request(request);
4204 cookie
4205 }
4206 #[cfg(feature = "glx")]
4207 fn glx_get_convolution_parameterfv_immediate(
4208 &mut self,
4209 context_tag: types::ContextTag,
4210 target: types::Card32,
4211 pname: types::Card32,
4212 ) -> Result<types::glx::GetConvolutionParameterfvReply> {
4213 let request = types::glx::GetConvolutionParameterfvRequest {
4214 context_tag,
4215 target,
4216 pname,
4217 };
4218 let cookie = self.send_reply_request(request)?;
4219 self.wait_for_reply(cookie)
4220 }
4221 #[cfg(feature = "glx")]
4222 fn glx_get_convolution_parameteriv(
4223 &mut self,
4224 context_tag: types::ContextTag,
4225 target: types::Card32,
4226 pname: types::Card32,
4227 ) -> Result<Cookie<types::glx::GetConvolutionParameterivReply>> {
4228 let span = tracing::info_span!(
4229 "glx_get_convolution_parameteriv",
4230 context_tag = ?context_tag,
4231 target = ?target,
4232 pname = ?pname,
4233 );
4234 let _enter = span.enter();
4235 let request = types::glx::GetConvolutionParameterivRequest {
4236 context_tag,
4237 target,
4238 pname,
4239 };
4240 let cookie = self.send_reply_request(request);
4241 cookie
4242 }
4243 #[cfg(feature = "glx")]
4244 fn glx_get_convolution_parameteriv_immediate(
4245 &mut self,
4246 context_tag: types::ContextTag,
4247 target: types::Card32,
4248 pname: types::Card32,
4249 ) -> Result<types::glx::GetConvolutionParameterivReply> {
4250 let request = types::glx::GetConvolutionParameterivRequest {
4251 context_tag,
4252 target,
4253 pname,
4254 };
4255 let cookie = self.send_reply_request(request)?;
4256 self.wait_for_reply(cookie)
4257 }
4258 #[cfg(feature = "glx")]
4259 fn glx_get_separable_filter(
4260 &mut self,
4261 context_tag: types::ContextTag,
4262 target: types::Card32,
4263 format: types::Card32,
4264 type_: types::Card32,
4265 swap_bytes: types::Bool,
4266 ) -> Result<Cookie<types::glx::GetSeparableFilterReply>> {
4267 let span = tracing::info_span!(
4268 "glx_get_separable_filter",
4269 context_tag = ?context_tag,
4270 target = ?target,
4271 format = ?format,
4272 type_ = ?type_,
4273 swap_bytes = ?swap_bytes,
4274 );
4275 let _enter = span.enter();
4276 let request = types::glx::GetSeparableFilterRequest {
4277 context_tag,
4278 target,
4279 format,
4280 type_,
4281 swap_bytes,
4282 };
4283 let cookie = self.send_reply_request(request);
4284 cookie
4285 }
4286 #[cfg(feature = "glx")]
4287 fn glx_get_separable_filter_immediate(
4288 &mut self,
4289 context_tag: types::ContextTag,
4290 target: types::Card32,
4291 format: types::Card32,
4292 type_: types::Card32,
4293 swap_bytes: types::Bool,
4294 ) -> Result<types::glx::GetSeparableFilterReply> {
4295 let request = types::glx::GetSeparableFilterRequest {
4296 context_tag,
4297 target,
4298 format,
4299 type_,
4300 swap_bytes,
4301 };
4302 let cookie = self.send_reply_request(request)?;
4303 self.wait_for_reply(cookie)
4304 }
4305 #[cfg(feature = "glx")]
4306 fn glx_get_histogram(
4307 &mut self,
4308 context_tag: types::ContextTag,
4309 target: types::Card32,
4310 format: types::Card32,
4311 type_: types::Card32,
4312 swap_bytes: types::Bool,
4313 reset: types::Bool,
4314 ) -> Result<Cookie<types::glx::GetHistogramReply>> {
4315 let span = tracing::info_span!(
4316 "glx_get_histogram",
4317 context_tag = ?context_tag,
4318 target = ?target,
4319 format = ?format,
4320 type_ = ?type_,
4321 swap_bytes = ?swap_bytes,
4322 reset = ?reset,
4323 );
4324 let _enter = span.enter();
4325 let request = types::glx::GetHistogramRequest {
4326 context_tag,
4327 target,
4328 format,
4329 type_,
4330 swap_bytes,
4331 reset,
4332 };
4333 let cookie = self.send_reply_request(request);
4334 cookie
4335 }
4336 #[cfg(feature = "glx")]
4337 fn glx_get_histogram_immediate(
4338 &mut self,
4339 context_tag: types::ContextTag,
4340 target: types::Card32,
4341 format: types::Card32,
4342 type_: types::Card32,
4343 swap_bytes: types::Bool,
4344 reset: types::Bool,
4345 ) -> Result<types::glx::GetHistogramReply> {
4346 let request = types::glx::GetHistogramRequest {
4347 context_tag,
4348 target,
4349 format,
4350 type_,
4351 swap_bytes,
4352 reset,
4353 };
4354 let cookie = self.send_reply_request(request)?;
4355 self.wait_for_reply(cookie)
4356 }
4357 #[cfg(feature = "glx")]
4358 fn glx_get_histogram_parameterfv(
4359 &mut self,
4360 context_tag: types::ContextTag,
4361 target: types::Card32,
4362 pname: types::Card32,
4363 ) -> Result<Cookie<types::glx::GetHistogramParameterfvReply>> {
4364 let span = tracing::info_span!(
4365 "glx_get_histogram_parameterfv",
4366 context_tag = ?context_tag,
4367 target = ?target,
4368 pname = ?pname,
4369 );
4370 let _enter = span.enter();
4371 let request = types::glx::GetHistogramParameterfvRequest {
4372 context_tag,
4373 target,
4374 pname,
4375 };
4376 let cookie = self.send_reply_request(request);
4377 cookie
4378 }
4379 #[cfg(feature = "glx")]
4380 fn glx_get_histogram_parameterfv_immediate(
4381 &mut self,
4382 context_tag: types::ContextTag,
4383 target: types::Card32,
4384 pname: types::Card32,
4385 ) -> Result<types::glx::GetHistogramParameterfvReply> {
4386 let request = types::glx::GetHistogramParameterfvRequest {
4387 context_tag,
4388 target,
4389 pname,
4390 };
4391 let cookie = self.send_reply_request(request)?;
4392 self.wait_for_reply(cookie)
4393 }
4394 #[cfg(feature = "glx")]
4395 fn glx_get_histogram_parameteriv(
4396 &mut self,
4397 context_tag: types::ContextTag,
4398 target: types::Card32,
4399 pname: types::Card32,
4400 ) -> Result<Cookie<types::glx::GetHistogramParameterivReply>> {
4401 let span = tracing::info_span!(
4402 "glx_get_histogram_parameteriv",
4403 context_tag = ?context_tag,
4404 target = ?target,
4405 pname = ?pname,
4406 );
4407 let _enter = span.enter();
4408 let request = types::glx::GetHistogramParameterivRequest {
4409 context_tag,
4410 target,
4411 pname,
4412 };
4413 let cookie = self.send_reply_request(request);
4414 cookie
4415 }
4416 #[cfg(feature = "glx")]
4417 fn glx_get_histogram_parameteriv_immediate(
4418 &mut self,
4419 context_tag: types::ContextTag,
4420 target: types::Card32,
4421 pname: types::Card32,
4422 ) -> Result<types::glx::GetHistogramParameterivReply> {
4423 let request = types::glx::GetHistogramParameterivRequest {
4424 context_tag,
4425 target,
4426 pname,
4427 };
4428 let cookie = self.send_reply_request(request)?;
4429 self.wait_for_reply(cookie)
4430 }
4431 #[cfg(feature = "glx")]
4432 fn glx_get_minmax(
4433 &mut self,
4434 context_tag: types::ContextTag,
4435 target: types::Card32,
4436 format: types::Card32,
4437 type_: types::Card32,
4438 swap_bytes: types::Bool,
4439 reset: types::Bool,
4440 ) -> Result<Cookie<types::glx::GetMinmaxReply>> {
4441 let span = tracing::info_span!(
4442 "glx_get_minmax",
4443 context_tag = ?context_tag,
4444 target = ?target,
4445 format = ?format,
4446 type_ = ?type_,
4447 swap_bytes = ?swap_bytes,
4448 reset = ?reset,
4449 );
4450 let _enter = span.enter();
4451 let request = types::glx::GetMinmaxRequest {
4452 context_tag,
4453 target,
4454 format,
4455 type_,
4456 swap_bytes,
4457 reset,
4458 };
4459 let cookie = self.send_reply_request(request);
4460 cookie
4461 }
4462 #[cfg(feature = "glx")]
4463 fn glx_get_minmax_immediate(
4464 &mut self,
4465 context_tag: types::ContextTag,
4466 target: types::Card32,
4467 format: types::Card32,
4468 type_: types::Card32,
4469 swap_bytes: types::Bool,
4470 reset: types::Bool,
4471 ) -> Result<types::glx::GetMinmaxReply> {
4472 let request = types::glx::GetMinmaxRequest {
4473 context_tag,
4474 target,
4475 format,
4476 type_,
4477 swap_bytes,
4478 reset,
4479 };
4480 let cookie = self.send_reply_request(request)?;
4481 self.wait_for_reply(cookie)
4482 }
4483 #[cfg(feature = "glx")]
4484 fn glx_get_minmax_parameterfv(
4485 &mut self,
4486 context_tag: types::ContextTag,
4487 target: types::Card32,
4488 pname: types::Card32,
4489 ) -> Result<Cookie<types::glx::GetMinmaxParameterfvReply>> {
4490 let span = tracing::info_span!(
4491 "glx_get_minmax_parameterfv",
4492 context_tag = ?context_tag,
4493 target = ?target,
4494 pname = ?pname,
4495 );
4496 let _enter = span.enter();
4497 let request = types::glx::GetMinmaxParameterfvRequest {
4498 context_tag,
4499 target,
4500 pname,
4501 };
4502 let cookie = self.send_reply_request(request);
4503 cookie
4504 }
4505 #[cfg(feature = "glx")]
4506 fn glx_get_minmax_parameterfv_immediate(
4507 &mut self,
4508 context_tag: types::ContextTag,
4509 target: types::Card32,
4510 pname: types::Card32,
4511 ) -> Result<types::glx::GetMinmaxParameterfvReply> {
4512 let request = types::glx::GetMinmaxParameterfvRequest {
4513 context_tag,
4514 target,
4515 pname,
4516 };
4517 let cookie = self.send_reply_request(request)?;
4518 self.wait_for_reply(cookie)
4519 }
4520 #[cfg(feature = "glx")]
4521 fn glx_get_minmax_parameteriv(
4522 &mut self,
4523 context_tag: types::ContextTag,
4524 target: types::Card32,
4525 pname: types::Card32,
4526 ) -> Result<Cookie<types::glx::GetMinmaxParameterivReply>> {
4527 let span = tracing::info_span!(
4528 "glx_get_minmax_parameteriv",
4529 context_tag = ?context_tag,
4530 target = ?target,
4531 pname = ?pname,
4532 );
4533 let _enter = span.enter();
4534 let request = types::glx::GetMinmaxParameterivRequest {
4535 context_tag,
4536 target,
4537 pname,
4538 };
4539 let cookie = self.send_reply_request(request);
4540 cookie
4541 }
4542 #[cfg(feature = "glx")]
4543 fn glx_get_minmax_parameteriv_immediate(
4544 &mut self,
4545 context_tag: types::ContextTag,
4546 target: types::Card32,
4547 pname: types::Card32,
4548 ) -> Result<types::glx::GetMinmaxParameterivReply> {
4549 let request = types::glx::GetMinmaxParameterivRequest {
4550 context_tag,
4551 target,
4552 pname,
4553 };
4554 let cookie = self.send_reply_request(request)?;
4555 self.wait_for_reply(cookie)
4556 }
4557 #[cfg(feature = "glx")]
4558 fn glx_get_compressed_tex_image_arb(
4559 &mut self,
4560 context_tag: types::ContextTag,
4561 target: types::Card32,
4562 level: types::Int32,
4563 ) -> Result<Cookie<types::glx::GetCompressedTexImageARBReply>> {
4564 let span = tracing::info_span!(
4565 "glx_get_compressed_tex_image_arb",
4566 context_tag = ?context_tag,
4567 target = ?target,
4568 level = ?level,
4569 );
4570 let _enter = span.enter();
4571 let request = types::glx::GetCompressedTexImageARBRequest {
4572 context_tag,
4573 target,
4574 level,
4575 };
4576 let cookie = self.send_reply_request(request);
4577 cookie
4578 }
4579 #[cfg(feature = "glx")]
4580 fn glx_get_compressed_tex_image_arb_immediate(
4581 &mut self,
4582 context_tag: types::ContextTag,
4583 target: types::Card32,
4584 level: types::Int32,
4585 ) -> Result<types::glx::GetCompressedTexImageARBReply> {
4586 let request = types::glx::GetCompressedTexImageARBRequest {
4587 context_tag,
4588 target,
4589 level,
4590 };
4591 let cookie = self.send_reply_request(request)?;
4592 self.wait_for_reply(cookie)
4593 }
4594 #[cfg(feature = "glx")]
4595 fn glx_delete_queries_arb(
4596 &mut self,
4597 context_tag: types::ContextTag,
4598 ids: impl AsRef<[types::Card32]>,
4599 ) -> Result<Cookie<()>> {
4600 let span = tracing::info_span!(
4601 "glx_delete_queries_arb",
4602 context_tag = ?context_tag,
4603 );
4604 let _enter = span.enter();
4605 let request = types::glx::DeleteQueriesARBRequest {
4606 context_tag,
4607 ids: Cow::Borrowed(ids.as_ref()),
4608 };
4609 let cookie = self.send_void_request(request, true);
4610 cookie
4611 }
4612 #[cfg(feature = "glx")]
4613 fn glx_delete_queries_arb_checked(
4614 &mut self,
4615 context_tag: types::ContextTag,
4616 ids: impl AsRef<[types::Card32]>,
4617 ) -> Result<()> {
4618 let request = types::glx::DeleteQueriesARBRequest {
4619 context_tag,
4620 ids: Cow::Borrowed(ids.as_ref()),
4621 };
4622 let cookie = self.send_void_request(request, false)?;
4623 self.wait_for_reply(cookie)
4624 }
4625 #[cfg(feature = "glx")]
4626 fn glx_gen_queries_arb(
4627 &mut self,
4628 context_tag: types::ContextTag,
4629 n: types::Int32,
4630 ) -> Result<Cookie<types::glx::GenQueriesARBReply>> {
4631 let span = tracing::info_span!(
4632 "glx_gen_queries_arb",
4633 context_tag = ?context_tag,
4634 n = ?n,
4635 );
4636 let _enter = span.enter();
4637 let request = types::glx::GenQueriesARBRequest { context_tag, n };
4638 let cookie = self.send_reply_request(request);
4639 cookie
4640 }
4641 #[cfg(feature = "glx")]
4642 fn glx_gen_queries_arb_immediate(
4643 &mut self,
4644 context_tag: types::ContextTag,
4645 n: types::Int32,
4646 ) -> Result<types::glx::GenQueriesARBReply> {
4647 let request = types::glx::GenQueriesARBRequest { context_tag, n };
4648 let cookie = self.send_reply_request(request)?;
4649 self.wait_for_reply(cookie)
4650 }
4651 #[cfg(feature = "glx")]
4652 fn glx_is_query_arb(
4653 &mut self,
4654 context_tag: types::ContextTag,
4655 id: types::Card32,
4656 ) -> Result<Cookie<types::glx::IsQueryARBReply>> {
4657 let span = tracing::info_span!(
4658 "glx_is_query_arb",
4659 context_tag = ?context_tag,
4660 id = ?id,
4661 );
4662 let _enter = span.enter();
4663 let request = types::glx::IsQueryARBRequest { context_tag, id };
4664 let cookie = self.send_reply_request(request);
4665 cookie
4666 }
4667 #[cfg(feature = "glx")]
4668 fn glx_is_query_arb_immediate(
4669 &mut self,
4670 context_tag: types::ContextTag,
4671 id: types::Card32,
4672 ) -> Result<types::glx::IsQueryARBReply> {
4673 let request = types::glx::IsQueryARBRequest { context_tag, id };
4674 let cookie = self.send_reply_request(request)?;
4675 self.wait_for_reply(cookie)
4676 }
4677 #[cfg(feature = "glx")]
4678 fn glx_get_queryiv_arb(
4679 &mut self,
4680 context_tag: types::ContextTag,
4681 target: types::Card32,
4682 pname: types::Card32,
4683 ) -> Result<Cookie<types::glx::GetQueryivARBReply>> {
4684 let span = tracing::info_span!(
4685 "glx_get_queryiv_arb",
4686 context_tag = ?context_tag,
4687 target = ?target,
4688 pname = ?pname,
4689 );
4690 let _enter = span.enter();
4691 let request = types::glx::GetQueryivARBRequest {
4692 context_tag,
4693 target,
4694 pname,
4695 };
4696 let cookie = self.send_reply_request(request);
4697 cookie
4698 }
4699 #[cfg(feature = "glx")]
4700 fn glx_get_queryiv_arb_immediate(
4701 &mut self,
4702 context_tag: types::ContextTag,
4703 target: types::Card32,
4704 pname: types::Card32,
4705 ) -> Result<types::glx::GetQueryivARBReply> {
4706 let request = types::glx::GetQueryivARBRequest {
4707 context_tag,
4708 target,
4709 pname,
4710 };
4711 let cookie = self.send_reply_request(request)?;
4712 self.wait_for_reply(cookie)
4713 }
4714 #[cfg(feature = "glx")]
4715 fn glx_get_query_objectiv_arb(
4716 &mut self,
4717 context_tag: types::ContextTag,
4718 id: types::Card32,
4719 pname: types::Card32,
4720 ) -> Result<Cookie<types::glx::GetQueryObjectivARBReply>> {
4721 let span = tracing::info_span!(
4722 "glx_get_query_objectiv_arb",
4723 context_tag = ?context_tag,
4724 id = ?id,
4725 pname = ?pname,
4726 );
4727 let _enter = span.enter();
4728 let request = types::glx::GetQueryObjectivARBRequest {
4729 context_tag,
4730 id,
4731 pname,
4732 };
4733 let cookie = self.send_reply_request(request);
4734 cookie
4735 }
4736 #[cfg(feature = "glx")]
4737 fn glx_get_query_objectiv_arb_immediate(
4738 &mut self,
4739 context_tag: types::ContextTag,
4740 id: types::Card32,
4741 pname: types::Card32,
4742 ) -> Result<types::glx::GetQueryObjectivARBReply> {
4743 let request = types::glx::GetQueryObjectivARBRequest {
4744 context_tag,
4745 id,
4746 pname,
4747 };
4748 let cookie = self.send_reply_request(request)?;
4749 self.wait_for_reply(cookie)
4750 }
4751 #[cfg(feature = "glx")]
4752 fn glx_get_query_objectuiv_arb(
4753 &mut self,
4754 context_tag: types::ContextTag,
4755 id: types::Card32,
4756 pname: types::Card32,
4757 ) -> Result<Cookie<types::glx::GetQueryObjectuivARBReply>> {
4758 let span = tracing::info_span!(
4759 "glx_get_query_objectuiv_arb",
4760 context_tag = ?context_tag,
4761 id = ?id,
4762 pname = ?pname,
4763 );
4764 let _enter = span.enter();
4765 let request = types::glx::GetQueryObjectuivARBRequest {
4766 context_tag,
4767 id,
4768 pname,
4769 };
4770 let cookie = self.send_reply_request(request);
4771 cookie
4772 }
4773 #[cfg(feature = "glx")]
4774 fn glx_get_query_objectuiv_arb_immediate(
4775 &mut self,
4776 context_tag: types::ContextTag,
4777 id: types::Card32,
4778 pname: types::Card32,
4779 ) -> Result<types::glx::GetQueryObjectuivARBReply> {
4780 let request = types::glx::GetQueryObjectuivARBRequest {
4781 context_tag,
4782 id,
4783 pname,
4784 };
4785 let cookie = self.send_reply_request(request)?;
4786 self.wait_for_reply(cookie)
4787 }
4788
4789 #[cfg(feature = "present")]
4790 fn present_query_version(
4791 &mut self,
4792 major_version: types::Card32,
4793 minor_version: types::Card32,
4794 ) -> Result<Cookie<types::present::QueryVersionReply>> {
4795 let span = tracing::info_span!(
4796 "present_query_version",
4797 major_version = ?major_version,
4798 minor_version = ?minor_version,
4799 );
4800 let _enter = span.enter();
4801 let request = types::present::QueryVersionRequest {
4802 major_version,
4803 minor_version,
4804 };
4805 let cookie = self.send_reply_request(request);
4806 cookie
4807 }
4808 #[cfg(feature = "present")]
4809 fn present_query_version_immediate(
4810 &mut self,
4811 major_version: types::Card32,
4812 minor_version: types::Card32,
4813 ) -> Result<types::present::QueryVersionReply> {
4814 let request = types::present::QueryVersionRequest {
4815 major_version,
4816 minor_version,
4817 };
4818 let cookie = self.send_reply_request(request)?;
4819 self.wait_for_reply(cookie)
4820 }
4821 #[cfg(feature = "present")]
4822 fn present_pixmap(
4823 &mut self,
4824 window: types::xproto::Window,
4825 pixmap: types::xproto::Pixmap,
4826 serial: types::Card32,
4827 valid: types::Region,
4828 update: types::Region,
4829 x_off: types::Int16,
4830 y_off: types::Int16,
4831 target_crtc: types::Crtc,
4832 wait_fence: types::Fence,
4833 idle_fence: types::Fence,
4834 options: types::Card32,
4835 target_msc: types::Card64,
4836 divisor: types::Card64,
4837 remainder: types::Card64,
4838 notifies: impl AsRef<[types::present::Notify]>,
4839 ) -> Result<Cookie<()>> {
4840 let span = tracing::info_span!(
4841 "present_pixmap",
4842 window = ?window,
4843 pixmap = ?pixmap,
4844 serial = ?serial,
4845 valid = ?valid,
4846 update = ?update,
4847 x_off = ?x_off,
4848 y_off = ?y_off,
4849 target_crtc = ?target_crtc,
4850 wait_fence = ?wait_fence,
4851 idle_fence = ?idle_fence,
4852 options = ?options,
4853 target_msc = ?target_msc,
4854 divisor = ?divisor,
4855 remainder = ?remainder,
4856 );
4857 let _enter = span.enter();
4858 let request = types::present::PixmapRequest {
4859 window,
4860 pixmap,
4861 serial,
4862 valid,
4863 update,
4864 x_off,
4865 y_off,
4866 target_crtc,
4867 wait_fence,
4868 idle_fence,
4869 options,
4870 target_msc,
4871 divisor,
4872 remainder,
4873 notifies: Cow::Borrowed(notifies.as_ref()),
4874 };
4875 let cookie = self.send_void_request(request, true);
4876 cookie
4877 }
4878 #[cfg(feature = "present")]
4879 fn present_pixmap_checked(
4880 &mut self,
4881 window: types::xproto::Window,
4882 pixmap: types::xproto::Pixmap,
4883 serial: types::Card32,
4884 valid: types::Region,
4885 update: types::Region,
4886 x_off: types::Int16,
4887 y_off: types::Int16,
4888 target_crtc: types::Crtc,
4889 wait_fence: types::Fence,
4890 idle_fence: types::Fence,
4891 options: types::Card32,
4892 target_msc: types::Card64,
4893 divisor: types::Card64,
4894 remainder: types::Card64,
4895 notifies: impl AsRef<[types::present::Notify]>,
4896 ) -> Result<()> {
4897 let request = types::present::PixmapRequest {
4898 window,
4899 pixmap,
4900 serial,
4901 valid,
4902 update,
4903 x_off,
4904 y_off,
4905 target_crtc,
4906 wait_fence,
4907 idle_fence,
4908 options,
4909 target_msc,
4910 divisor,
4911 remainder,
4912 notifies: Cow::Borrowed(notifies.as_ref()),
4913 };
4914 let cookie = self.send_void_request(request, false)?;
4915 self.wait_for_reply(cookie)
4916 }
4917 #[cfg(feature = "present")]
4918 fn present_notify_msc(
4919 &mut self,
4920 window: types::xproto::Window,
4921 serial: types::Card32,
4922 target_msc: types::Card64,
4923 divisor: types::Card64,
4924 remainder: types::Card64,
4925 ) -> Result<Cookie<()>> {
4926 let span = tracing::info_span!(
4927 "present_notify_msc",
4928 window = ?window,
4929 serial = ?serial,
4930 target_msc = ?target_msc,
4931 divisor = ?divisor,
4932 remainder = ?remainder,
4933 );
4934 let _enter = span.enter();
4935 let request = types::present::NotifyMSCRequest {
4936 window,
4937 serial,
4938 target_msc,
4939 divisor,
4940 remainder,
4941 };
4942 let cookie = self.send_void_request(request, true);
4943 cookie
4944 }
4945 #[cfg(feature = "present")]
4946 fn present_notify_msc_checked(
4947 &mut self,
4948 window: types::xproto::Window,
4949 serial: types::Card32,
4950 target_msc: types::Card64,
4951 divisor: types::Card64,
4952 remainder: types::Card64,
4953 ) -> Result<()> {
4954 let request = types::present::NotifyMSCRequest {
4955 window,
4956 serial,
4957 target_msc,
4958 divisor,
4959 remainder,
4960 };
4961 let cookie = self.send_void_request(request, false)?;
4962 self.wait_for_reply(cookie)
4963 }
4964 #[cfg(feature = "present")]
4965 fn present_select_input(
4966 &mut self,
4967 eid: types::present::Event,
4968 window: types::xproto::Window,
4969 event_mask: impl Into<types::present::EventMask>,
4970 ) -> Result<Cookie<()>> {
4971 let span = tracing::info_span!(
4972 "present_select_input",
4973 eid = ?eid,
4974 window = ?window,
4975 );
4976 let _enter = span.enter();
4977 let request = types::present::SelectInputRequest {
4978 eid,
4979 window,
4980 event_mask: Into::<u32>::into(event_mask.into()) as _,
4981 };
4982 let cookie = self.send_void_request(request, true);
4983 cookie
4984 }
4985 #[cfg(feature = "present")]
4986 fn present_select_input_checked(
4987 &mut self,
4988 eid: types::present::Event,
4989 window: types::xproto::Window,
4990 event_mask: impl Into<types::present::EventMask>,
4991 ) -> Result<()> {
4992 let request = types::present::SelectInputRequest {
4993 eid,
4994 window,
4995 event_mask: Into::<u32>::into(event_mask.into()) as _,
4996 };
4997 let cookie = self.send_void_request(request, false)?;
4998 self.wait_for_reply(cookie)
4999 }
5000 #[cfg(feature = "present")]
5001 fn present_query_capabilities(
5002 &mut self,
5003 target: types::Card32,
5004 ) -> Result<Cookie<types::present::QueryCapabilitiesReply>> {
5005 let span = tracing::info_span!(
5006 "present_query_capabilities",
5007 target = ?target,
5008 );
5009 let _enter = span.enter();
5010 let request = types::present::QueryCapabilitiesRequest { target };
5011 let cookie = self.send_reply_request(request);
5012 cookie
5013 }
5014 #[cfg(feature = "present")]
5015 fn present_query_capabilities_immediate(
5016 &mut self,
5017 target: types::Card32,
5018 ) -> Result<types::present::QueryCapabilitiesReply> {
5019 let request = types::present::QueryCapabilitiesRequest { target };
5020 let cookie = self.send_reply_request(request)?;
5021 self.wait_for_reply(cookie)
5022 }
5023
5024 #[cfg(feature = "randr")]
5025 fn randr_query_version(
5026 &mut self,
5027 major_version: types::Card32,
5028 minor_version: types::Card32,
5029 ) -> Result<Cookie<types::randr::QueryVersionReply>> {
5030 let span = tracing::info_span!(
5031 "randr_query_version",
5032 major_version = ?major_version,
5033 minor_version = ?minor_version,
5034 );
5035 let _enter = span.enter();
5036 let request = types::randr::QueryVersionRequest {
5037 major_version,
5038 minor_version,
5039 };
5040 let cookie = self.send_reply_request(request);
5041 cookie
5042 }
5043 #[cfg(feature = "randr")]
5044 fn randr_query_version_immediate(
5045 &mut self,
5046 major_version: types::Card32,
5047 minor_version: types::Card32,
5048 ) -> Result<types::randr::QueryVersionReply> {
5049 let request = types::randr::QueryVersionRequest {
5050 major_version,
5051 minor_version,
5052 };
5053 let cookie = self.send_reply_request(request)?;
5054 self.wait_for_reply(cookie)
5055 }
5056 #[cfg(feature = "randr")]
5057 fn randr_set_screen_config(
5058 &mut self,
5059 window: types::xproto::Window,
5060 timestamp: types::Timestamp,
5061 config_timestamp: types::Timestamp,
5062 size_id: types::Card16,
5063 rotation: impl Into<types::Rotation>,
5064 rate: types::Card16,
5065 ) -> Result<Cookie<types::randr::SetScreenConfigReply>> {
5066 let span = tracing::info_span!(
5067 "randr_set_screen_config",
5068 window = ?window,
5069 timestamp = ?timestamp,
5070 config_timestamp = ?config_timestamp,
5071 size_id = ?size_id,
5072 rate = ?rate,
5073 );
5074 let _enter = span.enter();
5075 let request = types::randr::SetScreenConfigRequest {
5076 window,
5077 timestamp,
5078 config_timestamp,
5079 size_id,
5080 rotation: Into::<u32>::into(rotation.into()) as _,
5081 rate,
5082 };
5083 let cookie = self.send_reply_request(request);
5084 cookie
5085 }
5086 #[cfg(feature = "randr")]
5087 fn randr_set_screen_config_immediate(
5088 &mut self,
5089 window: types::xproto::Window,
5090 timestamp: types::Timestamp,
5091 config_timestamp: types::Timestamp,
5092 size_id: types::Card16,
5093 rotation: impl Into<types::Rotation>,
5094 rate: types::Card16,
5095 ) -> Result<types::randr::SetScreenConfigReply> {
5096 let request = types::randr::SetScreenConfigRequest {
5097 window,
5098 timestamp,
5099 config_timestamp,
5100 size_id,
5101 rotation: Into::<u32>::into(rotation.into()) as _,
5102 rate,
5103 };
5104 let cookie = self.send_reply_request(request)?;
5105 self.wait_for_reply(cookie)
5106 }
5107 #[cfg(feature = "randr")]
5108 fn randr_select_input(
5109 &mut self,
5110 window: types::xproto::Window,
5111 enable: impl Into<types::NotifyMask>,
5112 ) -> Result<Cookie<()>> {
5113 let span = tracing::info_span!(
5114 "randr_select_input",
5115 window = ?window,
5116 );
5117 let _enter = span.enter();
5118 let request = types::randr::SelectInputRequest {
5119 window,
5120 enable: Into::<u32>::into(enable.into()) as _,
5121 };
5122 let cookie = self.send_void_request(request, true);
5123 cookie
5124 }
5125 #[cfg(feature = "randr")]
5126 fn randr_select_input_checked(
5127 &mut self,
5128 window: types::xproto::Window,
5129 enable: impl Into<types::NotifyMask>,
5130 ) -> Result<()> {
5131 let request = types::randr::SelectInputRequest {
5132 window,
5133 enable: Into::<u32>::into(enable.into()) as _,
5134 };
5135 let cookie = self.send_void_request(request, false)?;
5136 self.wait_for_reply(cookie)
5137 }
5138 #[cfg(feature = "randr")]
5139 fn randr_get_screen_info(
5140 &mut self,
5141 window: types::xproto::Window,
5142 ) -> Result<Cookie<types::randr::GetScreenInfoReply>> {
5143 let span = tracing::info_span!(
5144 "randr_get_screen_info",
5145 window = ?window,
5146 );
5147 let _enter = span.enter();
5148 let request = types::randr::GetScreenInfoRequest { window };
5149 let cookie = self.send_reply_request(request);
5150 cookie
5151 }
5152 #[cfg(feature = "randr")]
5153 fn randr_get_screen_info_immediate(
5154 &mut self,
5155 window: types::xproto::Window,
5156 ) -> Result<types::randr::GetScreenInfoReply> {
5157 let request = types::randr::GetScreenInfoRequest { window };
5158 let cookie = self.send_reply_request(request)?;
5159 self.wait_for_reply(cookie)
5160 }
5161 #[cfg(feature = "randr")]
5162 fn randr_get_screen_size_range(
5163 &mut self,
5164 window: types::xproto::Window,
5165 ) -> Result<Cookie<types::randr::GetScreenSizeRangeReply>> {
5166 let span = tracing::info_span!(
5167 "randr_get_screen_size_range",
5168 window = ?window,
5169 );
5170 let _enter = span.enter();
5171 let request = types::randr::GetScreenSizeRangeRequest { window };
5172 let cookie = self.send_reply_request(request);
5173 cookie
5174 }
5175 #[cfg(feature = "randr")]
5176 fn randr_get_screen_size_range_immediate(
5177 &mut self,
5178 window: types::xproto::Window,
5179 ) -> Result<types::randr::GetScreenSizeRangeReply> {
5180 let request = types::randr::GetScreenSizeRangeRequest { window };
5181 let cookie = self.send_reply_request(request)?;
5182 self.wait_for_reply(cookie)
5183 }
5184 #[cfg(feature = "randr")]
5185 fn randr_set_screen_size(
5186 &mut self,
5187 window: types::xproto::Window,
5188 width: types::Card16,
5189 height: types::Card16,
5190 mm_width: types::Card32,
5191 mm_height: types::Card32,
5192 ) -> Result<Cookie<()>> {
5193 let span = tracing::info_span!(
5194 "randr_set_screen_size",
5195 window = ?window,
5196 width = ?width,
5197 height = ?height,
5198 mm_width = ?mm_width,
5199 mm_height = ?mm_height,
5200 );
5201 let _enter = span.enter();
5202 let request = types::randr::SetScreenSizeRequest {
5203 window,
5204 width,
5205 height,
5206 mm_width,
5207 mm_height,
5208 };
5209 let cookie = self.send_void_request(request, true);
5210 cookie
5211 }
5212 #[cfg(feature = "randr")]
5213 fn randr_set_screen_size_checked(
5214 &mut self,
5215 window: types::xproto::Window,
5216 width: types::Card16,
5217 height: types::Card16,
5218 mm_width: types::Card32,
5219 mm_height: types::Card32,
5220 ) -> Result<()> {
5221 let request = types::randr::SetScreenSizeRequest {
5222 window,
5223 width,
5224 height,
5225 mm_width,
5226 mm_height,
5227 };
5228 let cookie = self.send_void_request(request, false)?;
5229 self.wait_for_reply(cookie)
5230 }
5231 #[cfg(feature = "randr")]
5232 fn randr_get_screen_resources(
5233 &mut self,
5234 window: types::xproto::Window,
5235 ) -> Result<Cookie<types::randr::GetScreenResourcesReply>> {
5236 let span = tracing::info_span!(
5237 "randr_get_screen_resources",
5238 window = ?window,
5239 );
5240 let _enter = span.enter();
5241 let request = types::randr::GetScreenResourcesRequest { window };
5242 let cookie = self.send_reply_request(request);
5243 cookie
5244 }
5245 #[cfg(feature = "randr")]
5246 fn randr_get_screen_resources_immediate(
5247 &mut self,
5248 window: types::xproto::Window,
5249 ) -> Result<types::randr::GetScreenResourcesReply> {
5250 let request = types::randr::GetScreenResourcesRequest { window };
5251 let cookie = self.send_reply_request(request)?;
5252 self.wait_for_reply(cookie)
5253 }
5254 #[cfg(feature = "randr")]
5255 fn randr_get_output_info(
5256 &mut self,
5257 output: types::Output,
5258 config_timestamp: types::Timestamp,
5259 ) -> Result<Cookie<types::randr::GetOutputInfoReply>> {
5260 let span = tracing::info_span!(
5261 "randr_get_output_info",
5262 output = ?output,
5263 config_timestamp = ?config_timestamp,
5264 );
5265 let _enter = span.enter();
5266 let request = types::randr::GetOutputInfoRequest {
5267 output,
5268 config_timestamp,
5269 };
5270 let cookie = self.send_reply_request(request);
5271 cookie
5272 }
5273 #[cfg(feature = "randr")]
5274 fn randr_get_output_info_immediate(
5275 &mut self,
5276 output: types::Output,
5277 config_timestamp: types::Timestamp,
5278 ) -> Result<types::randr::GetOutputInfoReply> {
5279 let request = types::randr::GetOutputInfoRequest {
5280 output,
5281 config_timestamp,
5282 };
5283 let cookie = self.send_reply_request(request)?;
5284 self.wait_for_reply(cookie)
5285 }
5286 #[cfg(feature = "randr")]
5287 fn randr_list_output_properties(
5288 &mut self,
5289 output: types::Output,
5290 ) -> Result<Cookie<types::randr::ListOutputPropertiesReply>> {
5291 let span = tracing::info_span!(
5292 "randr_list_output_properties",
5293 output = ?output,
5294 );
5295 let _enter = span.enter();
5296 let request = types::randr::ListOutputPropertiesRequest { output };
5297 let cookie = self.send_reply_request(request);
5298 cookie
5299 }
5300 #[cfg(feature = "randr")]
5301 fn randr_list_output_properties_immediate(
5302 &mut self,
5303 output: types::Output,
5304 ) -> Result<types::randr::ListOutputPropertiesReply> {
5305 let request = types::randr::ListOutputPropertiesRequest { output };
5306 let cookie = self.send_reply_request(request)?;
5307 self.wait_for_reply(cookie)
5308 }
5309 #[cfg(feature = "randr")]
5310 fn randr_query_output_property(
5311 &mut self,
5312 output: types::Output,
5313 property: types::Atom,
5314 ) -> Result<Cookie<types::randr::QueryOutputPropertyReply>> {
5315 let span = tracing::info_span!(
5316 "randr_query_output_property",
5317 output = ?output,
5318 property = ?property,
5319 );
5320 let _enter = span.enter();
5321 let request = types::randr::QueryOutputPropertyRequest { output, property };
5322 let cookie = self.send_reply_request(request);
5323 cookie
5324 }
5325 #[cfg(feature = "randr")]
5326 fn randr_query_output_property_immediate(
5327 &mut self,
5328 output: types::Output,
5329 property: types::Atom,
5330 ) -> Result<types::randr::QueryOutputPropertyReply> {
5331 let request = types::randr::QueryOutputPropertyRequest { output, property };
5332 let cookie = self.send_reply_request(request)?;
5333 self.wait_for_reply(cookie)
5334 }
5335 #[cfg(feature = "randr")]
5336 fn randr_configure_output_property(
5337 &mut self,
5338 output: types::Output,
5339 property: types::Atom,
5340 pending: types::Bool,
5341 range: types::Bool,
5342 values: impl AsRef<[types::Int32]>,
5343 ) -> Result<Cookie<()>> {
5344 let span = tracing::info_span!(
5345 "randr_configure_output_property",
5346 output = ?output,
5347 property = ?property,
5348 pending = ?pending,
5349 range = ?range,
5350 );
5351 let _enter = span.enter();
5352 let request = types::randr::ConfigureOutputPropertyRequest {
5353 output,
5354 property,
5355 pending,
5356 range,
5357 values: Cow::Borrowed(values.as_ref()),
5358 };
5359 let cookie = self.send_void_request(request, true);
5360 cookie
5361 }
5362 #[cfg(feature = "randr")]
5363 fn randr_configure_output_property_checked(
5364 &mut self,
5365 output: types::Output,
5366 property: types::Atom,
5367 pending: types::Bool,
5368 range: types::Bool,
5369 values: impl AsRef<[types::Int32]>,
5370 ) -> Result<()> {
5371 let request = types::randr::ConfigureOutputPropertyRequest {
5372 output,
5373 property,
5374 pending,
5375 range,
5376 values: Cow::Borrowed(values.as_ref()),
5377 };
5378 let cookie = self.send_void_request(request, false)?;
5379 self.wait_for_reply(cookie)
5380 }
5381 #[cfg(feature = "randr")]
5382 fn randr_change_output_property(
5383 &mut self,
5384 output: types::Output,
5385 property: types::Atom,
5386 type_: types::Atom,
5387 format: types::Card8,
5388 mode: types::PropMode,
5389 num_units: types::Card32,
5390 data: &(impl crate::Void + ?Sized),
5391 ) -> Result<Cookie<()>> {
5392 let span = tracing::info_span!(
5393 "randr_change_output_property",
5394 output = ?output,
5395 property = ?property,
5396 type_ = ?type_,
5397 format = ?format,
5398 mode = ?mode,
5399 num_units = ?num_units,
5400 );
5401 let _enter = span.enter();
5402 let request = types::randr::ChangeOutputPropertyRequest {
5403 output,
5404 property,
5405 type_,
5406 format,
5407 mode,
5408 num_units,
5409 data: Cow::Borrowed(data.bytes()),
5410 };
5411 let cookie = self.send_void_request(request, true);
5412 cookie
5413 }
5414 #[cfg(feature = "randr")]
5415 fn randr_change_output_property_checked(
5416 &mut self,
5417 output: types::Output,
5418 property: types::Atom,
5419 type_: types::Atom,
5420 format: types::Card8,
5421 mode: types::PropMode,
5422 num_units: types::Card32,
5423 data: &(impl crate::Void + ?Sized),
5424 ) -> Result<()> {
5425 let request = types::randr::ChangeOutputPropertyRequest {
5426 output,
5427 property,
5428 type_,
5429 format,
5430 mode,
5431 num_units,
5432 data: Cow::Borrowed(data.bytes()),
5433 };
5434 let cookie = self.send_void_request(request, false)?;
5435 self.wait_for_reply(cookie)
5436 }
5437 #[cfg(feature = "randr")]
5438 fn randr_delete_output_property(
5439 &mut self,
5440 output: types::Output,
5441 property: types::Atom,
5442 ) -> Result<Cookie<()>> {
5443 let span = tracing::info_span!(
5444 "randr_delete_output_property",
5445 output = ?output,
5446 property = ?property,
5447 );
5448 let _enter = span.enter();
5449 let request = types::randr::DeleteOutputPropertyRequest { output, property };
5450 let cookie = self.send_void_request(request, true);
5451 cookie
5452 }
5453 #[cfg(feature = "randr")]
5454 fn randr_delete_output_property_checked(
5455 &mut self,
5456 output: types::Output,
5457 property: types::Atom,
5458 ) -> Result<()> {
5459 let request = types::randr::DeleteOutputPropertyRequest { output, property };
5460 let cookie = self.send_void_request(request, false)?;
5461 self.wait_for_reply(cookie)
5462 }
5463 #[cfg(feature = "randr")]
5464 fn randr_get_output_property(
5465 &mut self,
5466 output: types::Output,
5467 property: types::Atom,
5468 type_: impl Into<types::GetPropertyType>,
5469 long_offset: types::Card32,
5470 long_length: types::Card32,
5471 delete: types::Bool,
5472 pending: types::Bool,
5473 ) -> Result<Cookie<types::randr::GetOutputPropertyReply>> {
5474 let span = tracing::info_span!(
5475 "randr_get_output_property",
5476 output = ?output,
5477 property = ?property,
5478 long_offset = ?long_offset,
5479 long_length = ?long_length,
5480 delete = ?delete,
5481 pending = ?pending,
5482 );
5483 let _enter = span.enter();
5484 let request = types::randr::GetOutputPropertyRequest {
5485 output,
5486 property,
5487 type_: Into::<u32>::into(type_.into()) as _,
5488 long_offset,
5489 long_length,
5490 delete,
5491 pending,
5492 };
5493 let cookie = self.send_reply_request(request);
5494 cookie
5495 }
5496 #[cfg(feature = "randr")]
5497 fn randr_get_output_property_immediate(
5498 &mut self,
5499 output: types::Output,
5500 property: types::Atom,
5501 type_: impl Into<types::GetPropertyType>,
5502 long_offset: types::Card32,
5503 long_length: types::Card32,
5504 delete: types::Bool,
5505 pending: types::Bool,
5506 ) -> Result<types::randr::GetOutputPropertyReply> {
5507 let request = types::randr::GetOutputPropertyRequest {
5508 output,
5509 property,
5510 type_: Into::<u32>::into(type_.into()) as _,
5511 long_offset,
5512 long_length,
5513 delete,
5514 pending,
5515 };
5516 let cookie = self.send_reply_request(request)?;
5517 self.wait_for_reply(cookie)
5518 }
5519 #[cfg(feature = "randr")]
5520 fn randr_create_mode(
5521 &mut self,
5522 window: types::xproto::Window,
5523 mode_info: types::randr::ModeInfo,
5524 name: impl AsRef<[types::Char]>,
5525 ) -> Result<Cookie<types::randr::CreateModeReply>> {
5526 let span = tracing::info_span!(
5527 "randr_create_mode",
5528 window = ?window,
5529 mode_info = ?mode_info,
5530 );
5531 let _enter = span.enter();
5532 let request = types::randr::CreateModeRequest {
5533 window,
5534 mode_info,
5535 name: Cow::Borrowed(name.as_ref()),
5536 };
5537 let cookie = self.send_reply_request(request);
5538 cookie
5539 }
5540 #[cfg(feature = "randr")]
5541 fn randr_create_mode_immediate(
5542 &mut self,
5543 window: types::xproto::Window,
5544 mode_info: types::randr::ModeInfo,
5545 name: impl AsRef<[types::Char]>,
5546 ) -> Result<types::randr::CreateModeReply> {
5547 let request = types::randr::CreateModeRequest {
5548 window,
5549 mode_info,
5550 name: Cow::Borrowed(name.as_ref()),
5551 };
5552 let cookie = self.send_reply_request(request)?;
5553 self.wait_for_reply(cookie)
5554 }
5555 #[cfg(feature = "randr")]
5556 fn randr_destroy_mode(&mut self, mode: types::Mode) -> Result<Cookie<()>> {
5557 let span = tracing::info_span!(
5558 "randr_destroy_mode",
5559 mode = ?mode,
5560 );
5561 let _enter = span.enter();
5562 let request = types::randr::DestroyModeRequest { mode };
5563 let cookie = self.send_void_request(request, true);
5564 cookie
5565 }
5566 #[cfg(feature = "randr")]
5567 fn randr_destroy_mode_checked(&mut self, mode: types::Mode) -> Result<()> {
5568 let request = types::randr::DestroyModeRequest { mode };
5569 let cookie = self.send_void_request(request, false)?;
5570 self.wait_for_reply(cookie)
5571 }
5572 #[cfg(feature = "randr")]
5573 fn randr_add_output_mode(
5574 &mut self,
5575 output: types::Output,
5576 mode: types::Mode,
5577 ) -> Result<Cookie<()>> {
5578 let span = tracing::info_span!(
5579 "randr_add_output_mode",
5580 output = ?output,
5581 mode = ?mode,
5582 );
5583 let _enter = span.enter();
5584 let request = types::randr::AddOutputModeRequest { output, mode };
5585 let cookie = self.send_void_request(request, true);
5586 cookie
5587 }
5588 #[cfg(feature = "randr")]
5589 fn randr_add_output_mode_checked(
5590 &mut self,
5591 output: types::Output,
5592 mode: types::Mode,
5593 ) -> Result<()> {
5594 let request = types::randr::AddOutputModeRequest { output, mode };
5595 let cookie = self.send_void_request(request, false)?;
5596 self.wait_for_reply(cookie)
5597 }
5598 #[cfg(feature = "randr")]
5599 fn randr_delete_output_mode(
5600 &mut self,
5601 output: types::Output,
5602 mode: types::Mode,
5603 ) -> Result<Cookie<()>> {
5604 let span = tracing::info_span!(
5605 "randr_delete_output_mode",
5606 output = ?output,
5607 mode = ?mode,
5608 );
5609 let _enter = span.enter();
5610 let request = types::randr::DeleteOutputModeRequest { output, mode };
5611 let cookie = self.send_void_request(request, true);
5612 cookie
5613 }
5614 #[cfg(feature = "randr")]
5615 fn randr_delete_output_mode_checked(
5616 &mut self,
5617 output: types::Output,
5618 mode: types::Mode,
5619 ) -> Result<()> {
5620 let request = types::randr::DeleteOutputModeRequest { output, mode };
5621 let cookie = self.send_void_request(request, false)?;
5622 self.wait_for_reply(cookie)
5623 }
5624 #[cfg(feature = "randr")]
5625 fn randr_get_crtc_info(
5626 &mut self,
5627 crtc: types::Crtc,
5628 config_timestamp: types::Timestamp,
5629 ) -> Result<Cookie<types::randr::GetCrtcInfoReply>> {
5630 let span = tracing::info_span!(
5631 "randr_get_crtc_info",
5632 crtc = ?crtc,
5633 config_timestamp = ?config_timestamp,
5634 );
5635 let _enter = span.enter();
5636 let request = types::randr::GetCrtcInfoRequest {
5637 crtc,
5638 config_timestamp,
5639 };
5640 let cookie = self.send_reply_request(request);
5641 cookie
5642 }
5643 #[cfg(feature = "randr")]
5644 fn randr_get_crtc_info_immediate(
5645 &mut self,
5646 crtc: types::Crtc,
5647 config_timestamp: types::Timestamp,
5648 ) -> Result<types::randr::GetCrtcInfoReply> {
5649 let request = types::randr::GetCrtcInfoRequest {
5650 crtc,
5651 config_timestamp,
5652 };
5653 let cookie = self.send_reply_request(request)?;
5654 self.wait_for_reply(cookie)
5655 }
5656 #[cfg(feature = "randr")]
5657 fn randr_set_crtc_config(
5658 &mut self,
5659 crtc: types::Crtc,
5660 timestamp: types::Timestamp,
5661 config_timestamp: types::Timestamp,
5662 x: types::Int16,
5663 y: types::Int16,
5664 mode: types::Mode,
5665 rotation: impl Into<types::Rotation>,
5666 outputs: impl AsRef<[types::Output]>,
5667 ) -> Result<Cookie<types::randr::SetCrtcConfigReply>> {
5668 let span = tracing::info_span!(
5669 "randr_set_crtc_config",
5670 crtc = ?crtc,
5671 timestamp = ?timestamp,
5672 config_timestamp = ?config_timestamp,
5673 x = ?x,
5674 y = ?y,
5675 mode = ?mode,
5676 );
5677 let _enter = span.enter();
5678 let request = types::randr::SetCrtcConfigRequest {
5679 crtc,
5680 timestamp,
5681 config_timestamp,
5682 x,
5683 y,
5684 mode,
5685 rotation: Into::<u32>::into(rotation.into()) as _,
5686 outputs: Cow::Borrowed(outputs.as_ref()),
5687 };
5688 let cookie = self.send_reply_request(request);
5689 cookie
5690 }
5691 #[cfg(feature = "randr")]
5692 fn randr_set_crtc_config_immediate(
5693 &mut self,
5694 crtc: types::Crtc,
5695 timestamp: types::Timestamp,
5696 config_timestamp: types::Timestamp,
5697 x: types::Int16,
5698 y: types::Int16,
5699 mode: types::Mode,
5700 rotation: impl Into<types::Rotation>,
5701 outputs: impl AsRef<[types::Output]>,
5702 ) -> Result<types::randr::SetCrtcConfigReply> {
5703 let request = types::randr::SetCrtcConfigRequest {
5704 crtc,
5705 timestamp,
5706 config_timestamp,
5707 x,
5708 y,
5709 mode,
5710 rotation: Into::<u32>::into(rotation.into()) as _,
5711 outputs: Cow::Borrowed(outputs.as_ref()),
5712 };
5713 let cookie = self.send_reply_request(request)?;
5714 self.wait_for_reply(cookie)
5715 }
5716 #[cfg(feature = "randr")]
5717 fn randr_get_crtc_gamma_size(
5718 &mut self,
5719 crtc: types::Crtc,
5720 ) -> Result<Cookie<types::randr::GetCrtcGammaSizeReply>> {
5721 let span = tracing::info_span!(
5722 "randr_get_crtc_gamma_size",
5723 crtc = ?crtc,
5724 );
5725 let _enter = span.enter();
5726 let request = types::randr::GetCrtcGammaSizeRequest { crtc };
5727 let cookie = self.send_reply_request(request);
5728 cookie
5729 }
5730 #[cfg(feature = "randr")]
5731 fn randr_get_crtc_gamma_size_immediate(
5732 &mut self,
5733 crtc: types::Crtc,
5734 ) -> Result<types::randr::GetCrtcGammaSizeReply> {
5735 let request = types::randr::GetCrtcGammaSizeRequest { crtc };
5736 let cookie = self.send_reply_request(request)?;
5737 self.wait_for_reply(cookie)
5738 }
5739 #[cfg(feature = "randr")]
5740 fn randr_get_crtc_gamma(
5741 &mut self,
5742 crtc: types::Crtc,
5743 ) -> Result<Cookie<types::randr::GetCrtcGammaReply>> {
5744 let span = tracing::info_span!(
5745 "randr_get_crtc_gamma",
5746 crtc = ?crtc,
5747 );
5748 let _enter = span.enter();
5749 let request = types::randr::GetCrtcGammaRequest { crtc };
5750 let cookie = self.send_reply_request(request);
5751 cookie
5752 }
5753 #[cfg(feature = "randr")]
5754 fn randr_get_crtc_gamma_immediate(
5755 &mut self,
5756 crtc: types::Crtc,
5757 ) -> Result<types::randr::GetCrtcGammaReply> {
5758 let request = types::randr::GetCrtcGammaRequest { crtc };
5759 let cookie = self.send_reply_request(request)?;
5760 self.wait_for_reply(cookie)
5761 }
5762 #[cfg(feature = "randr")]
5763 fn randr_set_crtc_gamma(
5764 &mut self,
5765 crtc: types::Crtc,
5766 red: impl AsRef<[types::Card16]>,
5767 green: impl AsRef<[types::Card16]>,
5768 blue: impl AsRef<[types::Card16]>,
5769 ) -> Result<Cookie<()>> {
5770 let span = tracing::info_span!(
5771 "randr_set_crtc_gamma",
5772 crtc = ?crtc,
5773 );
5774 let _enter = span.enter();
5775 let request = types::randr::SetCrtcGammaRequest {
5776 crtc,
5777 red: Cow::Borrowed(red.as_ref()),
5778 green: Cow::Borrowed(green.as_ref()),
5779 blue: Cow::Borrowed(blue.as_ref()),
5780 };
5781 let cookie = self.send_void_request(request, true);
5782 cookie
5783 }
5784 #[cfg(feature = "randr")]
5785 fn randr_set_crtc_gamma_checked(
5786 &mut self,
5787 crtc: types::Crtc,
5788 red: impl AsRef<[types::Card16]>,
5789 green: impl AsRef<[types::Card16]>,
5790 blue: impl AsRef<[types::Card16]>,
5791 ) -> Result<()> {
5792 let request = types::randr::SetCrtcGammaRequest {
5793 crtc,
5794 red: Cow::Borrowed(red.as_ref()),
5795 green: Cow::Borrowed(green.as_ref()),
5796 blue: Cow::Borrowed(blue.as_ref()),
5797 };
5798 let cookie = self.send_void_request(request, false)?;
5799 self.wait_for_reply(cookie)
5800 }
5801 #[cfg(feature = "randr")]
5802 fn randr_get_screen_resources_current(
5803 &mut self,
5804 window: types::xproto::Window,
5805 ) -> Result<Cookie<types::randr::GetScreenResourcesCurrentReply>> {
5806 let span = tracing::info_span!(
5807 "randr_get_screen_resources_current",
5808 window = ?window,
5809 );
5810 let _enter = span.enter();
5811 let request = types::randr::GetScreenResourcesCurrentRequest { window };
5812 let cookie = self.send_reply_request(request);
5813 cookie
5814 }
5815 #[cfg(feature = "randr")]
5816 fn randr_get_screen_resources_current_immediate(
5817 &mut self,
5818 window: types::xproto::Window,
5819 ) -> Result<types::randr::GetScreenResourcesCurrentReply> {
5820 let request = types::randr::GetScreenResourcesCurrentRequest { window };
5821 let cookie = self.send_reply_request(request)?;
5822 self.wait_for_reply(cookie)
5823 }
5824 #[cfg(feature = "randr")]
5825 fn randr_set_crtc_transform(
5826 &mut self,
5827 crtc: types::Crtc,
5828 transform: types::render::Transform,
5829 filter_name: impl AsRef<[types::Char]>,
5830 filter_params: impl AsRef<[types::Fixed]>,
5831 ) -> Result<Cookie<()>> {
5832 let span = tracing::info_span!(
5833 "randr_set_crtc_transform",
5834 crtc = ?crtc,
5835 transform = ?transform,
5836 );
5837 let _enter = span.enter();
5838 let request = types::randr::SetCrtcTransformRequest {
5839 crtc,
5840 transform,
5841 filter_name: Cow::Borrowed(filter_name.as_ref()),
5842 filter_params: Cow::Borrowed(filter_params.as_ref()),
5843 };
5844 let cookie = self.send_void_request(request, true);
5845 cookie
5846 }
5847 #[cfg(feature = "randr")]
5848 fn randr_set_crtc_transform_checked(
5849 &mut self,
5850 crtc: types::Crtc,
5851 transform: types::render::Transform,
5852 filter_name: impl AsRef<[types::Char]>,
5853 filter_params: impl AsRef<[types::Fixed]>,
5854 ) -> Result<()> {
5855 let request = types::randr::SetCrtcTransformRequest {
5856 crtc,
5857 transform,
5858 filter_name: Cow::Borrowed(filter_name.as_ref()),
5859 filter_params: Cow::Borrowed(filter_params.as_ref()),
5860 };
5861 let cookie = self.send_void_request(request, false)?;
5862 self.wait_for_reply(cookie)
5863 }
5864 #[cfg(feature = "randr")]
5865 fn randr_get_crtc_transform(
5866 &mut self,
5867 crtc: types::Crtc,
5868 ) -> Result<Cookie<types::randr::GetCrtcTransformReply>> {
5869 let span = tracing::info_span!(
5870 "randr_get_crtc_transform",
5871 crtc = ?crtc,
5872 );
5873 let _enter = span.enter();
5874 let request = types::randr::GetCrtcTransformRequest { crtc };
5875 let cookie = self.send_reply_request(request);
5876 cookie
5877 }
5878 #[cfg(feature = "randr")]
5879 fn randr_get_crtc_transform_immediate(
5880 &mut self,
5881 crtc: types::Crtc,
5882 ) -> Result<types::randr::GetCrtcTransformReply> {
5883 let request = types::randr::GetCrtcTransformRequest { crtc };
5884 let cookie = self.send_reply_request(request)?;
5885 self.wait_for_reply(cookie)
5886 }
5887 #[cfg(feature = "randr")]
5888 fn randr_get_panning(
5889 &mut self,
5890 crtc: types::Crtc,
5891 ) -> Result<Cookie<types::randr::GetPanningReply>> {
5892 let span = tracing::info_span!(
5893 "randr_get_panning",
5894 crtc = ?crtc,
5895 );
5896 let _enter = span.enter();
5897 let request = types::randr::GetPanningRequest { crtc };
5898 let cookie = self.send_reply_request(request);
5899 cookie
5900 }
5901 #[cfg(feature = "randr")]
5902 fn randr_get_panning_immediate(
5903 &mut self,
5904 crtc: types::Crtc,
5905 ) -> Result<types::randr::GetPanningReply> {
5906 let request = types::randr::GetPanningRequest { crtc };
5907 let cookie = self.send_reply_request(request)?;
5908 self.wait_for_reply(cookie)
5909 }
5910 #[cfg(feature = "randr")]
5911 fn randr_set_panning(
5912 &mut self,
5913 crtc: types::Crtc,
5914 timestamp: types::Timestamp,
5915 left: types::Card16,
5916 top: types::Card16,
5917 width: types::Card16,
5918 height: types::Card16,
5919 track_left: types::Card16,
5920 track_top: types::Card16,
5921 track_width: types::Card16,
5922 track_height: types::Card16,
5923 border_left: types::Int16,
5924 border_top: types::Int16,
5925 border_right: types::Int16,
5926 border_bottom: types::Int16,
5927 ) -> Result<Cookie<types::randr::SetPanningReply>> {
5928 let span = tracing::info_span!(
5929 "randr_set_panning",
5930 crtc = ?crtc,
5931 timestamp = ?timestamp,
5932 left = ?left,
5933 top = ?top,
5934 width = ?width,
5935 height = ?height,
5936 track_left = ?track_left,
5937 track_top = ?track_top,
5938 track_width = ?track_width,
5939 track_height = ?track_height,
5940 border_left = ?border_left,
5941 border_top = ?border_top,
5942 border_right = ?border_right,
5943 border_bottom = ?border_bottom,
5944 );
5945 let _enter = span.enter();
5946 let request = types::randr::SetPanningRequest {
5947 crtc,
5948 timestamp,
5949 left,
5950 top,
5951 width,
5952 height,
5953 track_left,
5954 track_top,
5955 track_width,
5956 track_height,
5957 border_left,
5958 border_top,
5959 border_right,
5960 border_bottom,
5961 };
5962 let cookie = self.send_reply_request(request);
5963 cookie
5964 }
5965 #[cfg(feature = "randr")]
5966 fn randr_set_panning_immediate(
5967 &mut self,
5968 crtc: types::Crtc,
5969 timestamp: types::Timestamp,
5970 left: types::Card16,
5971 top: types::Card16,
5972 width: types::Card16,
5973 height: types::Card16,
5974 track_left: types::Card16,
5975 track_top: types::Card16,
5976 track_width: types::Card16,
5977 track_height: types::Card16,
5978 border_left: types::Int16,
5979 border_top: types::Int16,
5980 border_right: types::Int16,
5981 border_bottom: types::Int16,
5982 ) -> Result<types::randr::SetPanningReply> {
5983 let request = types::randr::SetPanningRequest {
5984 crtc,
5985 timestamp,
5986 left,
5987 top,
5988 width,
5989 height,
5990 track_left,
5991 track_top,
5992 track_width,
5993 track_height,
5994 border_left,
5995 border_top,
5996 border_right,
5997 border_bottom,
5998 };
5999 let cookie = self.send_reply_request(request)?;
6000 self.wait_for_reply(cookie)
6001 }
6002 #[cfg(feature = "randr")]
6003 fn randr_set_output_primary(
6004 &mut self,
6005 window: types::xproto::Window,
6006 output: types::Output,
6007 ) -> Result<Cookie<()>> {
6008 let span = tracing::info_span!(
6009 "randr_set_output_primary",
6010 window = ?window,
6011 output = ?output,
6012 );
6013 let _enter = span.enter();
6014 let request = types::randr::SetOutputPrimaryRequest { window, output };
6015 let cookie = self.send_void_request(request, true);
6016 cookie
6017 }
6018 #[cfg(feature = "randr")]
6019 fn randr_set_output_primary_checked(
6020 &mut self,
6021 window: types::xproto::Window,
6022 output: types::Output,
6023 ) -> Result<()> {
6024 let request = types::randr::SetOutputPrimaryRequest { window, output };
6025 let cookie = self.send_void_request(request, false)?;
6026 self.wait_for_reply(cookie)
6027 }
6028 #[cfg(feature = "randr")]
6029 fn randr_get_output_primary(
6030 &mut self,
6031 window: types::xproto::Window,
6032 ) -> Result<Cookie<types::randr::GetOutputPrimaryReply>> {
6033 let span = tracing::info_span!(
6034 "randr_get_output_primary",
6035 window = ?window,
6036 );
6037 let _enter = span.enter();
6038 let request = types::randr::GetOutputPrimaryRequest { window };
6039 let cookie = self.send_reply_request(request);
6040 cookie
6041 }
6042 #[cfg(feature = "randr")]
6043 fn randr_get_output_primary_immediate(
6044 &mut self,
6045 window: types::xproto::Window,
6046 ) -> Result<types::randr::GetOutputPrimaryReply> {
6047 let request = types::randr::GetOutputPrimaryRequest { window };
6048 let cookie = self.send_reply_request(request)?;
6049 self.wait_for_reply(cookie)
6050 }
6051 #[cfg(feature = "randr")]
6052 fn randr_get_providers(
6053 &mut self,
6054 window: types::xproto::Window,
6055 ) -> Result<Cookie<types::randr::GetProvidersReply>> {
6056 let span = tracing::info_span!(
6057 "randr_get_providers",
6058 window = ?window,
6059 );
6060 let _enter = span.enter();
6061 let request = types::randr::GetProvidersRequest { window };
6062 let cookie = self.send_reply_request(request);
6063 cookie
6064 }
6065 #[cfg(feature = "randr")]
6066 fn randr_get_providers_immediate(
6067 &mut self,
6068 window: types::xproto::Window,
6069 ) -> Result<types::randr::GetProvidersReply> {
6070 let request = types::randr::GetProvidersRequest { window };
6071 let cookie = self.send_reply_request(request)?;
6072 self.wait_for_reply(cookie)
6073 }
6074 #[cfg(feature = "randr")]
6075 fn randr_get_provider_info(
6076 &mut self,
6077 provider: types::Provider,
6078 config_timestamp: types::Timestamp,
6079 ) -> Result<Cookie<types::randr::GetProviderInfoReply>> {
6080 let span = tracing::info_span!(
6081 "randr_get_provider_info",
6082 provider = ?provider,
6083 config_timestamp = ?config_timestamp,
6084 );
6085 let _enter = span.enter();
6086 let request = types::randr::GetProviderInfoRequest {
6087 provider,
6088 config_timestamp,
6089 };
6090 let cookie = self.send_reply_request(request);
6091 cookie
6092 }
6093 #[cfg(feature = "randr")]
6094 fn randr_get_provider_info_immediate(
6095 &mut self,
6096 provider: types::Provider,
6097 config_timestamp: types::Timestamp,
6098 ) -> Result<types::randr::GetProviderInfoReply> {
6099 let request = types::randr::GetProviderInfoRequest {
6100 provider,
6101 config_timestamp,
6102 };
6103 let cookie = self.send_reply_request(request)?;
6104 self.wait_for_reply(cookie)
6105 }
6106 #[cfg(feature = "randr")]
6107 fn randr_set_provider_offload_sink(
6108 &mut self,
6109 provider: types::Provider,
6110 sink_provider: types::Provider,
6111 config_timestamp: types::Timestamp,
6112 ) -> Result<Cookie<()>> {
6113 let span = tracing::info_span!(
6114 "randr_set_provider_offload_sink",
6115 provider = ?provider,
6116 sink_provider = ?sink_provider,
6117 config_timestamp = ?config_timestamp,
6118 );
6119 let _enter = span.enter();
6120 let request = types::randr::SetProviderOffloadSinkRequest {
6121 provider,
6122 sink_provider,
6123 config_timestamp,
6124 };
6125 let cookie = self.send_void_request(request, true);
6126 cookie
6127 }
6128 #[cfg(feature = "randr")]
6129 fn randr_set_provider_offload_sink_checked(
6130 &mut self,
6131 provider: types::Provider,
6132 sink_provider: types::Provider,
6133 config_timestamp: types::Timestamp,
6134 ) -> Result<()> {
6135 let request = types::randr::SetProviderOffloadSinkRequest {
6136 provider,
6137 sink_provider,
6138 config_timestamp,
6139 };
6140 let cookie = self.send_void_request(request, false)?;
6141 self.wait_for_reply(cookie)
6142 }
6143 #[cfg(feature = "randr")]
6144 fn randr_set_provider_output_source(
6145 &mut self,
6146 provider: types::Provider,
6147 source_provider: types::Provider,
6148 config_timestamp: types::Timestamp,
6149 ) -> Result<Cookie<()>> {
6150 let span = tracing::info_span!(
6151 "randr_set_provider_output_source",
6152 provider = ?provider,
6153 source_provider = ?source_provider,
6154 config_timestamp = ?config_timestamp,
6155 );
6156 let _enter = span.enter();
6157 let request = types::randr::SetProviderOutputSourceRequest {
6158 provider,
6159 source_provider,
6160 config_timestamp,
6161 };
6162 let cookie = self.send_void_request(request, true);
6163 cookie
6164 }
6165 #[cfg(feature = "randr")]
6166 fn randr_set_provider_output_source_checked(
6167 &mut self,
6168 provider: types::Provider,
6169 source_provider: types::Provider,
6170 config_timestamp: types::Timestamp,
6171 ) -> Result<()> {
6172 let request = types::randr::SetProviderOutputSourceRequest {
6173 provider,
6174 source_provider,
6175 config_timestamp,
6176 };
6177 let cookie = self.send_void_request(request, false)?;
6178 self.wait_for_reply(cookie)
6179 }
6180 #[cfg(feature = "randr")]
6181 fn randr_list_provider_properties(
6182 &mut self,
6183 provider: types::Provider,
6184 ) -> Result<Cookie<types::randr::ListProviderPropertiesReply>> {
6185 let span = tracing::info_span!(
6186 "randr_list_provider_properties",
6187 provider = ?provider,
6188 );
6189 let _enter = span.enter();
6190 let request = types::randr::ListProviderPropertiesRequest { provider };
6191 let cookie = self.send_reply_request(request);
6192 cookie
6193 }
6194 #[cfg(feature = "randr")]
6195 fn randr_list_provider_properties_immediate(
6196 &mut self,
6197 provider: types::Provider,
6198 ) -> Result<types::randr::ListProviderPropertiesReply> {
6199 let request = types::randr::ListProviderPropertiesRequest { provider };
6200 let cookie = self.send_reply_request(request)?;
6201 self.wait_for_reply(cookie)
6202 }
6203 #[cfg(feature = "randr")]
6204 fn randr_query_provider_property(
6205 &mut self,
6206 provider: types::Provider,
6207 property: types::Atom,
6208 ) -> Result<Cookie<types::randr::QueryProviderPropertyReply>> {
6209 let span = tracing::info_span!(
6210 "randr_query_provider_property",
6211 provider = ?provider,
6212 property = ?property,
6213 );
6214 let _enter = span.enter();
6215 let request = types::randr::QueryProviderPropertyRequest { provider, property };
6216 let cookie = self.send_reply_request(request);
6217 cookie
6218 }
6219 #[cfg(feature = "randr")]
6220 fn randr_query_provider_property_immediate(
6221 &mut self,
6222 provider: types::Provider,
6223 property: types::Atom,
6224 ) -> Result<types::randr::QueryProviderPropertyReply> {
6225 let request = types::randr::QueryProviderPropertyRequest { provider, property };
6226 let cookie = self.send_reply_request(request)?;
6227 self.wait_for_reply(cookie)
6228 }
6229 #[cfg(feature = "randr")]
6230 fn randr_configure_provider_property(
6231 &mut self,
6232 provider: types::Provider,
6233 property: types::Atom,
6234 pending: types::Bool,
6235 range: types::Bool,
6236 values: impl AsRef<[types::Int32]>,
6237 ) -> Result<Cookie<()>> {
6238 let span = tracing::info_span!(
6239 "randr_configure_provider_property",
6240 provider = ?provider,
6241 property = ?property,
6242 pending = ?pending,
6243 range = ?range,
6244 );
6245 let _enter = span.enter();
6246 let request = types::randr::ConfigureProviderPropertyRequest {
6247 provider,
6248 property,
6249 pending,
6250 range,
6251 values: Cow::Borrowed(values.as_ref()),
6252 };
6253 let cookie = self.send_void_request(request, true);
6254 cookie
6255 }
6256 #[cfg(feature = "randr")]
6257 fn randr_configure_provider_property_checked(
6258 &mut self,
6259 provider: types::Provider,
6260 property: types::Atom,
6261 pending: types::Bool,
6262 range: types::Bool,
6263 values: impl AsRef<[types::Int32]>,
6264 ) -> Result<()> {
6265 let request = types::randr::ConfigureProviderPropertyRequest {
6266 provider,
6267 property,
6268 pending,
6269 range,
6270 values: Cow::Borrowed(values.as_ref()),
6271 };
6272 let cookie = self.send_void_request(request, false)?;
6273 self.wait_for_reply(cookie)
6274 }
6275 #[cfg(feature = "randr")]
6276 fn randr_change_provider_property(
6277 &mut self,
6278 provider: types::Provider,
6279 property: types::Atom,
6280 type_: types::Atom,
6281 format: types::Card8,
6282 mode: types::Card8,
6283 num_items: types::Card32,
6284 data: &(impl crate::Void + ?Sized),
6285 ) -> Result<Cookie<()>> {
6286 let span = tracing::info_span!(
6287 "randr_change_provider_property",
6288 provider = ?provider,
6289 property = ?property,
6290 type_ = ?type_,
6291 format = ?format,
6292 mode = ?mode,
6293 num_items = ?num_items,
6294 );
6295 let _enter = span.enter();
6296 let request = types::randr::ChangeProviderPropertyRequest {
6297 provider,
6298 property,
6299 type_,
6300 format,
6301 mode,
6302 num_items,
6303 data: Cow::Borrowed(data.bytes()),
6304 };
6305 let cookie = self.send_void_request(request, true);
6306 cookie
6307 }
6308 #[cfg(feature = "randr")]
6309 fn randr_change_provider_property_checked(
6310 &mut self,
6311 provider: types::Provider,
6312 property: types::Atom,
6313 type_: types::Atom,
6314 format: types::Card8,
6315 mode: types::Card8,
6316 num_items: types::Card32,
6317 data: &(impl crate::Void + ?Sized),
6318 ) -> Result<()> {
6319 let request = types::randr::ChangeProviderPropertyRequest {
6320 provider,
6321 property,
6322 type_,
6323 format,
6324 mode,
6325 num_items,
6326 data: Cow::Borrowed(data.bytes()),
6327 };
6328 let cookie = self.send_void_request(request, false)?;
6329 self.wait_for_reply(cookie)
6330 }
6331 #[cfg(feature = "randr")]
6332 fn randr_delete_provider_property(
6333 &mut self,
6334 provider: types::Provider,
6335 property: types::Atom,
6336 ) -> Result<Cookie<()>> {
6337 let span = tracing::info_span!(
6338 "randr_delete_provider_property",
6339 provider = ?provider,
6340 property = ?property,
6341 );
6342 let _enter = span.enter();
6343 let request = types::randr::DeleteProviderPropertyRequest { provider, property };
6344 let cookie = self.send_void_request(request, true);
6345 cookie
6346 }
6347 #[cfg(feature = "randr")]
6348 fn randr_delete_provider_property_checked(
6349 &mut self,
6350 provider: types::Provider,
6351 property: types::Atom,
6352 ) -> Result<()> {
6353 let request = types::randr::DeleteProviderPropertyRequest { provider, property };
6354 let cookie = self.send_void_request(request, false)?;
6355 self.wait_for_reply(cookie)
6356 }
6357 #[cfg(feature = "randr")]
6358 fn randr_get_provider_property(
6359 &mut self,
6360 provider: types::Provider,
6361 property: types::Atom,
6362 type_: types::Atom,
6363 long_offset: types::Card32,
6364 long_length: types::Card32,
6365 delete: types::Bool,
6366 pending: types::Bool,
6367 ) -> Result<Cookie<types::randr::GetProviderPropertyReply>> {
6368 let span = tracing::info_span!(
6369 "randr_get_provider_property",
6370 provider = ?provider,
6371 property = ?property,
6372 type_ = ?type_,
6373 long_offset = ?long_offset,
6374 long_length = ?long_length,
6375 delete = ?delete,
6376 pending = ?pending,
6377 );
6378 let _enter = span.enter();
6379 let request = types::randr::GetProviderPropertyRequest {
6380 provider,
6381 property,
6382 type_,
6383 long_offset,
6384 long_length,
6385 delete,
6386 pending,
6387 };
6388 let cookie = self.send_reply_request(request);
6389 cookie
6390 }
6391 #[cfg(feature = "randr")]
6392 fn randr_get_provider_property_immediate(
6393 &mut self,
6394 provider: types::Provider,
6395 property: types::Atom,
6396 type_: types::Atom,
6397 long_offset: types::Card32,
6398 long_length: types::Card32,
6399 delete: types::Bool,
6400 pending: types::Bool,
6401 ) -> Result<types::randr::GetProviderPropertyReply> {
6402 let request = types::randr::GetProviderPropertyRequest {
6403 provider,
6404 property,
6405 type_,
6406 long_offset,
6407 long_length,
6408 delete,
6409 pending,
6410 };
6411 let cookie = self.send_reply_request(request)?;
6412 self.wait_for_reply(cookie)
6413 }
6414 #[cfg(feature = "randr")]
6415 fn randr_get_monitors(
6416 &mut self,
6417 window: types::xproto::Window,
6418 get_active: types::Bool,
6419 ) -> Result<Cookie<types::randr::GetMonitorsReply>> {
6420 let span = tracing::info_span!(
6421 "randr_get_monitors",
6422 window = ?window,
6423 get_active = ?get_active,
6424 );
6425 let _enter = span.enter();
6426 let request = types::randr::GetMonitorsRequest { window, get_active };
6427 let cookie = self.send_reply_request(request);
6428 cookie
6429 }
6430 #[cfg(feature = "randr")]
6431 fn randr_get_monitors_immediate(
6432 &mut self,
6433 window: types::xproto::Window,
6434 get_active: types::Bool,
6435 ) -> Result<types::randr::GetMonitorsReply> {
6436 let request = types::randr::GetMonitorsRequest { window, get_active };
6437 let cookie = self.send_reply_request(request)?;
6438 self.wait_for_reply(cookie)
6439 }
6440 #[cfg(feature = "randr")]
6441 fn randr_set_monitor(
6442 &mut self,
6443 window: types::xproto::Window,
6444 monitorinfo: types::MonitorInfo,
6445 ) -> Result<Cookie<()>> {
6446 let span = tracing::info_span!(
6447 "randr_set_monitor",
6448 window = ?window,
6449 monitorinfo = ?monitorinfo,
6450 );
6451 let _enter = span.enter();
6452 let request = types::randr::SetMonitorRequest {
6453 window,
6454 monitorinfo,
6455 };
6456 let cookie = self.send_void_request(request, true);
6457 cookie
6458 }
6459 #[cfg(feature = "randr")]
6460 fn randr_set_monitor_checked(
6461 &mut self,
6462 window: types::xproto::Window,
6463 monitorinfo: types::MonitorInfo,
6464 ) -> Result<()> {
6465 let request = types::randr::SetMonitorRequest {
6466 window,
6467 monitorinfo,
6468 };
6469 let cookie = self.send_void_request(request, false)?;
6470 self.wait_for_reply(cookie)
6471 }
6472 #[cfg(feature = "randr")]
6473 fn randr_delete_monitor(
6474 &mut self,
6475 window: types::xproto::Window,
6476 name: types::Atom,
6477 ) -> Result<Cookie<()>> {
6478 let span = tracing::info_span!(
6479 "randr_delete_monitor",
6480 window = ?window,
6481 name = ?name,
6482 );
6483 let _enter = span.enter();
6484 let request = types::randr::DeleteMonitorRequest { window, name };
6485 let cookie = self.send_void_request(request, true);
6486 cookie
6487 }
6488 #[cfg(feature = "randr")]
6489 fn randr_delete_monitor_checked(
6490 &mut self,
6491 window: types::xproto::Window,
6492 name: types::Atom,
6493 ) -> Result<()> {
6494 let request = types::randr::DeleteMonitorRequest { window, name };
6495 let cookie = self.send_void_request(request, false)?;
6496 self.wait_for_reply(cookie)
6497 }
6498 #[cfg(feature = "randr")]
6499 fn randr_create_lease(
6500 &mut self,
6501 window: types::xproto::Window,
6502 lid: types::Lease,
6503 crtcs: impl AsRef<[types::Crtc]>,
6504 outputs: impl AsRef<[types::Output]>,
6505 ) -> Result<Cookie<types::randr::CreateLeaseReply>> {
6506 let span = tracing::info_span!(
6507 "randr_create_lease",
6508 window = ?window,
6509 lid = ?lid,
6510 );
6511 let _enter = span.enter();
6512 let request = types::randr::CreateLeaseRequest {
6513 window,
6514 lid,
6515 crtcs: Cow::Borrowed(crtcs.as_ref()),
6516 outputs: Cow::Borrowed(outputs.as_ref()),
6517 };
6518 let cookie = self.send_reply_fd_request(request);
6519 cookie
6520 }
6521 #[cfg(feature = "randr")]
6522 fn randr_create_lease_immediate(
6523 &mut self,
6524 window: types::xproto::Window,
6525 lid: types::Lease,
6526 crtcs: impl AsRef<[types::Crtc]>,
6527 outputs: impl AsRef<[types::Output]>,
6528 ) -> Result<types::randr::CreateLeaseReply> {
6529 let request = types::randr::CreateLeaseRequest {
6530 window,
6531 lid,
6532 crtcs: Cow::Borrowed(crtcs.as_ref()),
6533 outputs: Cow::Borrowed(outputs.as_ref()),
6534 };
6535 let cookie = self.send_reply_fd_request(request)?;
6536 self.wait_for_reply(cookie)
6537 }
6538 #[cfg(feature = "randr")]
6539 fn randr_free_lease(
6540 &mut self,
6541 lid: types::Lease,
6542 terminate: types::Byte,
6543 ) -> Result<Cookie<()>> {
6544 let span = tracing::info_span!(
6545 "randr_free_lease",
6546 lid = ?lid,
6547 terminate = ?terminate,
6548 );
6549 let _enter = span.enter();
6550 let request = types::randr::FreeLeaseRequest { lid, terminate };
6551 let cookie = self.send_void_request(request, true);
6552 cookie
6553 }
6554 #[cfg(feature = "randr")]
6555 fn randr_free_lease_checked(
6556 &mut self,
6557 lid: types::Lease,
6558 terminate: types::Byte,
6559 ) -> Result<()> {
6560 let request = types::randr::FreeLeaseRequest { lid, terminate };
6561 let cookie = self.send_void_request(request, false)?;
6562 self.wait_for_reply(cookie)
6563 }
6564
6565 #[cfg(feature = "record")]
6566 fn record_query_version(
6567 &mut self,
6568 major_version: types::Card16,
6569 minor_version: types::Card16,
6570 ) -> Result<Cookie<types::record::QueryVersionReply>> {
6571 let span = tracing::info_span!(
6572 "record_query_version",
6573 major_version = ?major_version,
6574 minor_version = ?minor_version,
6575 );
6576 let _enter = span.enter();
6577 let request = types::record::QueryVersionRequest {
6578 major_version,
6579 minor_version,
6580 };
6581 let cookie = self.send_reply_request(request);
6582 cookie
6583 }
6584 #[cfg(feature = "record")]
6585 fn record_query_version_immediate(
6586 &mut self,
6587 major_version: types::Card16,
6588 minor_version: types::Card16,
6589 ) -> Result<types::record::QueryVersionReply> {
6590 let request = types::record::QueryVersionRequest {
6591 major_version,
6592 minor_version,
6593 };
6594 let cookie = self.send_reply_request(request)?;
6595 self.wait_for_reply(cookie)
6596 }
6597 #[cfg(feature = "record")]
6598 fn record_create_context(
6599 &mut self,
6600 context: types::record::Context,
6601 element_header: types::ElementHeader,
6602 client_specs: impl AsRef<[types::ClientSpec]>,
6603 ranges: impl AsRef<[types::Range]>,
6604 ) -> Result<Cookie<()>> {
6605 let span = tracing::info_span!(
6606 "record_create_context",
6607 context = ?context,
6608 element_header = ?element_header,
6609 );
6610 let _enter = span.enter();
6611 let request = types::record::CreateContextRequest {
6612 context,
6613 element_header,
6614 client_specs: Cow::Borrowed(client_specs.as_ref()),
6615 ranges: Cow::Borrowed(ranges.as_ref()),
6616 };
6617 let cookie = self.send_void_request(request, true);
6618 cookie
6619 }
6620 #[cfg(feature = "record")]
6621 fn record_create_context_checked(
6622 &mut self,
6623 context: types::record::Context,
6624 element_header: types::ElementHeader,
6625 client_specs: impl AsRef<[types::ClientSpec]>,
6626 ranges: impl AsRef<[types::Range]>,
6627 ) -> Result<()> {
6628 let request = types::record::CreateContextRequest {
6629 context,
6630 element_header,
6631 client_specs: Cow::Borrowed(client_specs.as_ref()),
6632 ranges: Cow::Borrowed(ranges.as_ref()),
6633 };
6634 let cookie = self.send_void_request(request, false)?;
6635 self.wait_for_reply(cookie)
6636 }
6637 #[cfg(feature = "record")]
6638 fn record_register_clients(
6639 &mut self,
6640 context: types::record::Context,
6641 element_header: types::ElementHeader,
6642 client_specs: impl AsRef<[types::ClientSpec]>,
6643 ranges: impl AsRef<[types::Range]>,
6644 ) -> Result<Cookie<()>> {
6645 let span = tracing::info_span!(
6646 "record_register_clients",
6647 context = ?context,
6648 element_header = ?element_header,
6649 );
6650 let _enter = span.enter();
6651 let request = types::record::RegisterClientsRequest {
6652 context,
6653 element_header,
6654 client_specs: Cow::Borrowed(client_specs.as_ref()),
6655 ranges: Cow::Borrowed(ranges.as_ref()),
6656 };
6657 let cookie = self.send_void_request(request, true);
6658 cookie
6659 }
6660 #[cfg(feature = "record")]
6661 fn record_register_clients_checked(
6662 &mut self,
6663 context: types::record::Context,
6664 element_header: types::ElementHeader,
6665 client_specs: impl AsRef<[types::ClientSpec]>,
6666 ranges: impl AsRef<[types::Range]>,
6667 ) -> Result<()> {
6668 let request = types::record::RegisterClientsRequest {
6669 context,
6670 element_header,
6671 client_specs: Cow::Borrowed(client_specs.as_ref()),
6672 ranges: Cow::Borrowed(ranges.as_ref()),
6673 };
6674 let cookie = self.send_void_request(request, false)?;
6675 self.wait_for_reply(cookie)
6676 }
6677 #[cfg(feature = "record")]
6678 fn record_unregister_clients(
6679 &mut self,
6680 context: types::record::Context,
6681 client_specs: impl AsRef<[types::ClientSpec]>,
6682 ) -> Result<Cookie<()>> {
6683 let span = tracing::info_span!(
6684 "record_unregister_clients",
6685 context = ?context,
6686 );
6687 let _enter = span.enter();
6688 let request = types::record::UnregisterClientsRequest {
6689 context,
6690 client_specs: Cow::Borrowed(client_specs.as_ref()),
6691 };
6692 let cookie = self.send_void_request(request, true);
6693 cookie
6694 }
6695 #[cfg(feature = "record")]
6696 fn record_unregister_clients_checked(
6697 &mut self,
6698 context: types::record::Context,
6699 client_specs: impl AsRef<[types::ClientSpec]>,
6700 ) -> Result<()> {
6701 let request = types::record::UnregisterClientsRequest {
6702 context,
6703 client_specs: Cow::Borrowed(client_specs.as_ref()),
6704 };
6705 let cookie = self.send_void_request(request, false)?;
6706 self.wait_for_reply(cookie)
6707 }
6708 #[cfg(feature = "record")]
6709 fn record_get_context(
6710 &mut self,
6711 context: types::record::Context,
6712 ) -> Result<Cookie<types::record::GetContextReply>> {
6713 let span = tracing::info_span!(
6714 "record_get_context",
6715 context = ?context,
6716 );
6717 let _enter = span.enter();
6718 let request = types::record::GetContextRequest { context };
6719 let cookie = self.send_reply_request(request);
6720 cookie
6721 }
6722 #[cfg(feature = "record")]
6723 fn record_get_context_immediate(
6724 &mut self,
6725 context: types::record::Context,
6726 ) -> Result<types::record::GetContextReply> {
6727 let request = types::record::GetContextRequest { context };
6728 let cookie = self.send_reply_request(request)?;
6729 self.wait_for_reply(cookie)
6730 }
6731 #[cfg(feature = "record")]
6732 fn record_enable_context(
6733 &mut self,
6734 context: types::record::Context,
6735 ) -> Result<Cookie<types::record::EnableContextReply>> {
6736 let span = tracing::info_span!(
6737 "record_enable_context",
6738 context = ?context,
6739 );
6740 let _enter = span.enter();
6741 let request = types::record::EnableContextRequest { context };
6742 let cookie = self.send_reply_request(request);
6743 cookie
6744 }
6745 #[cfg(feature = "record")]
6746 fn record_enable_context_immediate(
6747 &mut self,
6748 context: types::record::Context,
6749 ) -> Result<types::record::EnableContextReply> {
6750 let request = types::record::EnableContextRequest { context };
6751 let cookie = self.send_reply_request(request)?;
6752 self.wait_for_reply(cookie)
6753 }
6754 #[cfg(feature = "record")]
6755 fn record_disable_context(&mut self, context: types::record::Context) -> Result<Cookie<()>> {
6756 let span = tracing::info_span!(
6757 "record_disable_context",
6758 context = ?context,
6759 );
6760 let _enter = span.enter();
6761 let request = types::record::DisableContextRequest { context };
6762 let cookie = self.send_void_request(request, true);
6763 cookie
6764 }
6765 #[cfg(feature = "record")]
6766 fn record_disable_context_checked(&mut self, context: types::record::Context) -> Result<()> {
6767 let request = types::record::DisableContextRequest { context };
6768 let cookie = self.send_void_request(request, false)?;
6769 self.wait_for_reply(cookie)
6770 }
6771 #[cfg(feature = "record")]
6772 fn record_free_context(&mut self, context: types::record::Context) -> Result<Cookie<()>> {
6773 let span = tracing::info_span!(
6774 "record_free_context",
6775 context = ?context,
6776 );
6777 let _enter = span.enter();
6778 let request = types::record::FreeContextRequest { context };
6779 let cookie = self.send_void_request(request, true);
6780 cookie
6781 }
6782 #[cfg(feature = "record")]
6783 fn record_free_context_checked(&mut self, context: types::record::Context) -> Result<()> {
6784 let request = types::record::FreeContextRequest { context };
6785 let cookie = self.send_void_request(request, false)?;
6786 self.wait_for_reply(cookie)
6787 }
6788
6789 #[cfg(feature = "render")]
6790 fn render_query_version(
6791 &mut self,
6792 client_major_version: types::Card32,
6793 client_minor_version: types::Card32,
6794 ) -> Result<Cookie<types::render::QueryVersionReply>> {
6795 let span = tracing::info_span!(
6796 "render_query_version",
6797 client_major_version = ?client_major_version,
6798 client_minor_version = ?client_minor_version,
6799 );
6800 let _enter = span.enter();
6801 let request = types::render::QueryVersionRequest {
6802 client_major_version,
6803 client_minor_version,
6804 };
6805 let cookie = self.send_reply_request(request);
6806 cookie
6807 }
6808 #[cfg(feature = "render")]
6809 fn render_query_version_immediate(
6810 &mut self,
6811 client_major_version: types::Card32,
6812 client_minor_version: types::Card32,
6813 ) -> Result<types::render::QueryVersionReply> {
6814 let request = types::render::QueryVersionRequest {
6815 client_major_version,
6816 client_minor_version,
6817 };
6818 let cookie = self.send_reply_request(request)?;
6819 self.wait_for_reply(cookie)
6820 }
6821 #[cfg(feature = "render")]
6822 fn render_query_pict_formats(
6823 &mut self,
6824 ) -> Result<Cookie<types::render::QueryPictFormatsReply>> {
6825 let span = tracing::info_span!("render_query_pict_formats",);
6826 let _enter = span.enter();
6827 let request = types::render::QueryPictFormatsRequest {};
6828 let cookie = self.send_reply_request(request);
6829 cookie
6830 }
6831 #[cfg(feature = "render")]
6832 fn render_query_pict_formats_immediate(
6833 &mut self,
6834 ) -> Result<types::render::QueryPictFormatsReply> {
6835 let request = types::render::QueryPictFormatsRequest {};
6836 let cookie = self.send_reply_request(request)?;
6837 self.wait_for_reply(cookie)
6838 }
6839 #[cfg(feature = "render")]
6840 fn render_query_pict_index_values(
6841 &mut self,
6842 format: types::Pictformat,
6843 ) -> Result<Cookie<types::render::QueryPictIndexValuesReply>> {
6844 let span = tracing::info_span!(
6845 "render_query_pict_index_values",
6846 format = ?format,
6847 );
6848 let _enter = span.enter();
6849 let request = types::render::QueryPictIndexValuesRequest { format };
6850 let cookie = self.send_reply_request(request);
6851 cookie
6852 }
6853 #[cfg(feature = "render")]
6854 fn render_query_pict_index_values_immediate(
6855 &mut self,
6856 format: types::Pictformat,
6857 ) -> Result<types::render::QueryPictIndexValuesReply> {
6858 let request = types::render::QueryPictIndexValuesRequest { format };
6859 let cookie = self.send_reply_request(request)?;
6860 self.wait_for_reply(cookie)
6861 }
6862 #[cfg(feature = "render")]
6863 fn render_create_picture(
6864 &mut self,
6865 pid: types::Picture,
6866 drawable: types::xproto::Drawable,
6867 format: types::Pictformat,
6868 value_list: impl Borrow<types::render::CreatePictureAux>,
6869 ) -> Result<Cookie<()>> {
6870 let span = tracing::info_span!(
6871 "render_create_picture",
6872 pid = ?pid,
6873 drawable = ?drawable,
6874 format = ?format,
6875 );
6876 let _enter = span.enter();
6877 let request = types::render::CreatePictureRequest {
6878 pid,
6879 drawable,
6880 format,
6881 value_list: Cow::Borrowed(value_list.borrow()),
6882 };
6883 let cookie = self.send_void_request(request, true);
6884 cookie
6885 }
6886 #[cfg(feature = "render")]
6887 fn render_create_picture_checked(
6888 &mut self,
6889 pid: types::Picture,
6890 drawable: types::xproto::Drawable,
6891 format: types::Pictformat,
6892 value_list: impl Borrow<types::render::CreatePictureAux>,
6893 ) -> Result<()> {
6894 let request = types::render::CreatePictureRequest {
6895 pid,
6896 drawable,
6897 format,
6898 value_list: Cow::Borrowed(value_list.borrow()),
6899 };
6900 let cookie = self.send_void_request(request, false)?;
6901 self.wait_for_reply(cookie)
6902 }
6903 #[cfg(feature = "render")]
6904 fn render_change_picture(
6905 &mut self,
6906 picture: types::Picture,
6907 value_list: impl Borrow<types::render::ChangePictureAux>,
6908 ) -> Result<Cookie<()>> {
6909 let span = tracing::info_span!(
6910 "render_change_picture",
6911 picture = ?picture,
6912 );
6913 let _enter = span.enter();
6914 let request = types::render::ChangePictureRequest {
6915 picture,
6916 value_list: Cow::Borrowed(value_list.borrow()),
6917 };
6918 let cookie = self.send_void_request(request, true);
6919 cookie
6920 }
6921 #[cfg(feature = "render")]
6922 fn render_change_picture_checked(
6923 &mut self,
6924 picture: types::Picture,
6925 value_list: impl Borrow<types::render::ChangePictureAux>,
6926 ) -> Result<()> {
6927 let request = types::render::ChangePictureRequest {
6928 picture,
6929 value_list: Cow::Borrowed(value_list.borrow()),
6930 };
6931 let cookie = self.send_void_request(request, false)?;
6932 self.wait_for_reply(cookie)
6933 }
6934 #[cfg(feature = "render")]
6935 fn render_set_picture_clip_rectangles(
6936 &mut self,
6937 picture: types::Picture,
6938 clip_x_origin: types::Int16,
6939 clip_y_origin: types::Int16,
6940 rectangles: impl AsRef<[types::Rectangle]>,
6941 ) -> Result<Cookie<()>> {
6942 let span = tracing::info_span!(
6943 "render_set_picture_clip_rectangles",
6944 picture = ?picture,
6945 clip_x_origin = ?clip_x_origin,
6946 clip_y_origin = ?clip_y_origin,
6947 );
6948 let _enter = span.enter();
6949 let request = types::render::SetPictureClipRectanglesRequest {
6950 picture,
6951 clip_x_origin,
6952 clip_y_origin,
6953 rectangles: Cow::Borrowed(rectangles.as_ref()),
6954 };
6955 let cookie = self.send_void_request(request, true);
6956 cookie
6957 }
6958 #[cfg(feature = "render")]
6959 fn render_set_picture_clip_rectangles_checked(
6960 &mut self,
6961 picture: types::Picture,
6962 clip_x_origin: types::Int16,
6963 clip_y_origin: types::Int16,
6964 rectangles: impl AsRef<[types::Rectangle]>,
6965 ) -> Result<()> {
6966 let request = types::render::SetPictureClipRectanglesRequest {
6967 picture,
6968 clip_x_origin,
6969 clip_y_origin,
6970 rectangles: Cow::Borrowed(rectangles.as_ref()),
6971 };
6972 let cookie = self.send_void_request(request, false)?;
6973 self.wait_for_reply(cookie)
6974 }
6975 #[cfg(feature = "render")]
6976 fn render_free_picture(&mut self, picture: types::Picture) -> Result<Cookie<()>> {
6977 let span = tracing::info_span!(
6978 "render_free_picture",
6979 picture = ?picture,
6980 );
6981 let _enter = span.enter();
6982 let request = types::render::FreePictureRequest { picture };
6983 let cookie = self.send_void_request(request, true);
6984 cookie
6985 }
6986 #[cfg(feature = "render")]
6987 fn render_free_picture_checked(&mut self, picture: types::Picture) -> Result<()> {
6988 let request = types::render::FreePictureRequest { picture };
6989 let cookie = self.send_void_request(request, false)?;
6990 self.wait_for_reply(cookie)
6991 }
6992 #[cfg(feature = "render")]
6993 fn render_composite(
6994 &mut self,
6995 op: types::PictOp,
6996 src: types::Picture,
6997 mask: impl Into<types::Picture>,
6998 dst: types::Picture,
6999 src_x: types::Int16,
7000 src_y: types::Int16,
7001 mask_x: types::Int16,
7002 mask_y: types::Int16,
7003 dst_x: types::Int16,
7004 dst_y: types::Int16,
7005 width: types::Card16,
7006 height: types::Card16,
7007 ) -> Result<Cookie<()>> {
7008 let span = tracing::info_span!(
7009 "render_composite",
7010 op = ?op,
7011 src = ?src,
7012 dst = ?dst,
7013 src_x = ?src_x,
7014 src_y = ?src_y,
7015 mask_x = ?mask_x,
7016 mask_y = ?mask_y,
7017 dst_x = ?dst_x,
7018 dst_y = ?dst_y,
7019 width = ?width,
7020 height = ?height,
7021 );
7022 let _enter = span.enter();
7023 let request = types::render::CompositeRequest {
7024 op,
7025 src,
7026 mask: Into::<u32>::into(mask.into()) as _,
7027 dst,
7028 src_x,
7029 src_y,
7030 mask_x,
7031 mask_y,
7032 dst_x,
7033 dst_y,
7034 width,
7035 height,
7036 };
7037 let cookie = self.send_void_request(request, true);
7038 cookie
7039 }
7040 #[cfg(feature = "render")]
7041 fn render_composite_checked(
7042 &mut self,
7043 op: types::PictOp,
7044 src: types::Picture,
7045 mask: impl Into<types::Picture>,
7046 dst: types::Picture,
7047 src_x: types::Int16,
7048 src_y: types::Int16,
7049 mask_x: types::Int16,
7050 mask_y: types::Int16,
7051 dst_x: types::Int16,
7052 dst_y: types::Int16,
7053 width: types::Card16,
7054 height: types::Card16,
7055 ) -> Result<()> {
7056 let request = types::render::CompositeRequest {
7057 op,
7058 src,
7059 mask: Into::<u32>::into(mask.into()) as _,
7060 dst,
7061 src_x,
7062 src_y,
7063 mask_x,
7064 mask_y,
7065 dst_x,
7066 dst_y,
7067 width,
7068 height,
7069 };
7070 let cookie = self.send_void_request(request, false)?;
7071 self.wait_for_reply(cookie)
7072 }
7073 #[cfg(feature = "render")]
7074 fn render_trapezoids(
7075 &mut self,
7076 op: types::PictOp,
7077 src: types::Picture,
7078 dst: types::Picture,
7079 mask_format: types::Pictformat,
7080 src_x: types::Int16,
7081 src_y: types::Int16,
7082 traps: impl AsRef<[types::Trapezoid]>,
7083 ) -> Result<Cookie<()>> {
7084 let span = tracing::info_span!(
7085 "render_trapezoids",
7086 op = ?op,
7087 src = ?src,
7088 dst = ?dst,
7089 mask_format = ?mask_format,
7090 src_x = ?src_x,
7091 src_y = ?src_y,
7092 );
7093 let _enter = span.enter();
7094 let request = types::render::TrapezoidsRequest {
7095 op,
7096 src,
7097 dst,
7098 mask_format,
7099 src_x,
7100 src_y,
7101 traps: Cow::Borrowed(traps.as_ref()),
7102 };
7103 let cookie = self.send_void_request(request, true);
7104 cookie
7105 }
7106 #[cfg(feature = "render")]
7107 fn render_trapezoids_checked(
7108 &mut self,
7109 op: types::PictOp,
7110 src: types::Picture,
7111 dst: types::Picture,
7112 mask_format: types::Pictformat,
7113 src_x: types::Int16,
7114 src_y: types::Int16,
7115 traps: impl AsRef<[types::Trapezoid]>,
7116 ) -> Result<()> {
7117 let request = types::render::TrapezoidsRequest {
7118 op,
7119 src,
7120 dst,
7121 mask_format,
7122 src_x,
7123 src_y,
7124 traps: Cow::Borrowed(traps.as_ref()),
7125 };
7126 let cookie = self.send_void_request(request, false)?;
7127 self.wait_for_reply(cookie)
7128 }
7129 #[cfg(feature = "render")]
7130 fn render_triangles(
7131 &mut self,
7132 op: types::PictOp,
7133 src: types::Picture,
7134 dst: types::Picture,
7135 mask_format: types::Pictformat,
7136 src_x: types::Int16,
7137 src_y: types::Int16,
7138 triangles: impl AsRef<[types::Triangle]>,
7139 ) -> Result<Cookie<()>> {
7140 let span = tracing::info_span!(
7141 "render_triangles",
7142 op = ?op,
7143 src = ?src,
7144 dst = ?dst,
7145 mask_format = ?mask_format,
7146 src_x = ?src_x,
7147 src_y = ?src_y,
7148 );
7149 let _enter = span.enter();
7150 let request = types::render::TrianglesRequest {
7151 op,
7152 src,
7153 dst,
7154 mask_format,
7155 src_x,
7156 src_y,
7157 triangles: Cow::Borrowed(triangles.as_ref()),
7158 };
7159 let cookie = self.send_void_request(request, true);
7160 cookie
7161 }
7162 #[cfg(feature = "render")]
7163 fn render_triangles_checked(
7164 &mut self,
7165 op: types::PictOp,
7166 src: types::Picture,
7167 dst: types::Picture,
7168 mask_format: types::Pictformat,
7169 src_x: types::Int16,
7170 src_y: types::Int16,
7171 triangles: impl AsRef<[types::Triangle]>,
7172 ) -> Result<()> {
7173 let request = types::render::TrianglesRequest {
7174 op,
7175 src,
7176 dst,
7177 mask_format,
7178 src_x,
7179 src_y,
7180 triangles: Cow::Borrowed(triangles.as_ref()),
7181 };
7182 let cookie = self.send_void_request(request, false)?;
7183 self.wait_for_reply(cookie)
7184 }
7185 #[cfg(feature = "render")]
7186 fn render_tri_strip(
7187 &mut self,
7188 op: types::PictOp,
7189 src: types::Picture,
7190 dst: types::Picture,
7191 mask_format: types::Pictformat,
7192 src_x: types::Int16,
7193 src_y: types::Int16,
7194 points: impl AsRef<[types::Pointfix]>,
7195 ) -> Result<Cookie<()>> {
7196 let span = tracing::info_span!(
7197 "render_tri_strip",
7198 op = ?op,
7199 src = ?src,
7200 dst = ?dst,
7201 mask_format = ?mask_format,
7202 src_x = ?src_x,
7203 src_y = ?src_y,
7204 );
7205 let _enter = span.enter();
7206 let request = types::render::TriStripRequest {
7207 op,
7208 src,
7209 dst,
7210 mask_format,
7211 src_x,
7212 src_y,
7213 points: Cow::Borrowed(points.as_ref()),
7214 };
7215 let cookie = self.send_void_request(request, true);
7216 cookie
7217 }
7218 #[cfg(feature = "render")]
7219 fn render_tri_strip_checked(
7220 &mut self,
7221 op: types::PictOp,
7222 src: types::Picture,
7223 dst: types::Picture,
7224 mask_format: types::Pictformat,
7225 src_x: types::Int16,
7226 src_y: types::Int16,
7227 points: impl AsRef<[types::Pointfix]>,
7228 ) -> Result<()> {
7229 let request = types::render::TriStripRequest {
7230 op,
7231 src,
7232 dst,
7233 mask_format,
7234 src_x,
7235 src_y,
7236 points: Cow::Borrowed(points.as_ref()),
7237 };
7238 let cookie = self.send_void_request(request, false)?;
7239 self.wait_for_reply(cookie)
7240 }
7241 #[cfg(feature = "render")]
7242 fn render_tri_fan(
7243 &mut self,
7244 op: types::PictOp,
7245 src: types::Picture,
7246 dst: types::Picture,
7247 mask_format: types::Pictformat,
7248 src_x: types::Int16,
7249 src_y: types::Int16,
7250 points: impl AsRef<[types::Pointfix]>,
7251 ) -> Result<Cookie<()>> {
7252 let span = tracing::info_span!(
7253 "render_tri_fan",
7254 op = ?op,
7255 src = ?src,
7256 dst = ?dst,
7257 mask_format = ?mask_format,
7258 src_x = ?src_x,
7259 src_y = ?src_y,
7260 );
7261 let _enter = span.enter();
7262 let request = types::render::TriFanRequest {
7263 op,
7264 src,
7265 dst,
7266 mask_format,
7267 src_x,
7268 src_y,
7269 points: Cow::Borrowed(points.as_ref()),
7270 };
7271 let cookie = self.send_void_request(request, true);
7272 cookie
7273 }
7274 #[cfg(feature = "render")]
7275 fn render_tri_fan_checked(
7276 &mut self,
7277 op: types::PictOp,
7278 src: types::Picture,
7279 dst: types::Picture,
7280 mask_format: types::Pictformat,
7281 src_x: types::Int16,
7282 src_y: types::Int16,
7283 points: impl AsRef<[types::Pointfix]>,
7284 ) -> Result<()> {
7285 let request = types::render::TriFanRequest {
7286 op,
7287 src,
7288 dst,
7289 mask_format,
7290 src_x,
7291 src_y,
7292 points: Cow::Borrowed(points.as_ref()),
7293 };
7294 let cookie = self.send_void_request(request, false)?;
7295 self.wait_for_reply(cookie)
7296 }
7297 #[cfg(feature = "render")]
7298 fn render_create_glyph_set(
7299 &mut self,
7300 gsid: types::Glyphset,
7301 format: types::Pictformat,
7302 ) -> Result<Cookie<()>> {
7303 let span = tracing::info_span!(
7304 "render_create_glyph_set",
7305 gsid = ?gsid,
7306 format = ?format,
7307 );
7308 let _enter = span.enter();
7309 let request = types::render::CreateGlyphSetRequest { gsid, format };
7310 let cookie = self.send_void_request(request, true);
7311 cookie
7312 }
7313 #[cfg(feature = "render")]
7314 fn render_create_glyph_set_checked(
7315 &mut self,
7316 gsid: types::Glyphset,
7317 format: types::Pictformat,
7318 ) -> Result<()> {
7319 let request = types::render::CreateGlyphSetRequest { gsid, format };
7320 let cookie = self.send_void_request(request, false)?;
7321 self.wait_for_reply(cookie)
7322 }
7323 #[cfg(feature = "render")]
7324 fn render_reference_glyph_set(
7325 &mut self,
7326 gsid: types::Glyphset,
7327 existing: types::Glyphset,
7328 ) -> Result<Cookie<()>> {
7329 let span = tracing::info_span!(
7330 "render_reference_glyph_set",
7331 gsid = ?gsid,
7332 existing = ?existing,
7333 );
7334 let _enter = span.enter();
7335 let request = types::render::ReferenceGlyphSetRequest { gsid, existing };
7336 let cookie = self.send_void_request(request, true);
7337 cookie
7338 }
7339 #[cfg(feature = "render")]
7340 fn render_reference_glyph_set_checked(
7341 &mut self,
7342 gsid: types::Glyphset,
7343 existing: types::Glyphset,
7344 ) -> Result<()> {
7345 let request = types::render::ReferenceGlyphSetRequest { gsid, existing };
7346 let cookie = self.send_void_request(request, false)?;
7347 self.wait_for_reply(cookie)
7348 }
7349 #[cfg(feature = "render")]
7350 fn render_free_glyph_set(&mut self, glyphset: types::Glyphset) -> Result<Cookie<()>> {
7351 let span = tracing::info_span!(
7352 "render_free_glyph_set",
7353 glyphset = ?glyphset,
7354 );
7355 let _enter = span.enter();
7356 let request = types::render::FreeGlyphSetRequest { glyphset };
7357 let cookie = self.send_void_request(request, true);
7358 cookie
7359 }
7360 #[cfg(feature = "render")]
7361 fn render_free_glyph_set_checked(&mut self, glyphset: types::Glyphset) -> Result<()> {
7362 let request = types::render::FreeGlyphSetRequest { glyphset };
7363 let cookie = self.send_void_request(request, false)?;
7364 self.wait_for_reply(cookie)
7365 }
7366 #[cfg(feature = "render")]
7367 fn render_add_glyphs(
7368 &mut self,
7369 glyphset: types::Glyphset,
7370 glyphids: impl AsRef<[types::Card32]>,
7371 glyphs: impl AsRef<[types::Glyphinfo]>,
7372 data: impl AsRef<[types::Byte]>,
7373 ) -> Result<Cookie<()>> {
7374 let span = tracing::info_span!(
7375 "render_add_glyphs",
7376 glyphset = ?glyphset,
7377 );
7378 let _enter = span.enter();
7379 let request = types::render::AddGlyphsRequest {
7380 glyphset,
7381 glyphids: Cow::Borrowed(glyphids.as_ref()),
7382 glyphs: Cow::Borrowed(glyphs.as_ref()),
7383 data: Cow::Borrowed(data.as_ref()),
7384 };
7385 let cookie = self.send_void_request(request, true);
7386 cookie
7387 }
7388 #[cfg(feature = "render")]
7389 fn render_add_glyphs_checked(
7390 &mut self,
7391 glyphset: types::Glyphset,
7392 glyphids: impl AsRef<[types::Card32]>,
7393 glyphs: impl AsRef<[types::Glyphinfo]>,
7394 data: impl AsRef<[types::Byte]>,
7395 ) -> Result<()> {
7396 let request = types::render::AddGlyphsRequest {
7397 glyphset,
7398 glyphids: Cow::Borrowed(glyphids.as_ref()),
7399 glyphs: Cow::Borrowed(glyphs.as_ref()),
7400 data: Cow::Borrowed(data.as_ref()),
7401 };
7402 let cookie = self.send_void_request(request, false)?;
7403 self.wait_for_reply(cookie)
7404 }
7405 #[cfg(feature = "render")]
7406 fn render_free_glyphs(
7407 &mut self,
7408 glyphset: types::Glyphset,
7409 glyphs: impl AsRef<[types::Glyph]>,
7410 ) -> Result<Cookie<()>> {
7411 let span = tracing::info_span!(
7412 "render_free_glyphs",
7413 glyphset = ?glyphset,
7414 );
7415 let _enter = span.enter();
7416 let request = types::render::FreeGlyphsRequest {
7417 glyphset,
7418 glyphs: Cow::Borrowed(glyphs.as_ref()),
7419 };
7420 let cookie = self.send_void_request(request, true);
7421 cookie
7422 }
7423 #[cfg(feature = "render")]
7424 fn render_free_glyphs_checked(
7425 &mut self,
7426 glyphset: types::Glyphset,
7427 glyphs: impl AsRef<[types::Glyph]>,
7428 ) -> Result<()> {
7429 let request = types::render::FreeGlyphsRequest {
7430 glyphset,
7431 glyphs: Cow::Borrowed(glyphs.as_ref()),
7432 };
7433 let cookie = self.send_void_request(request, false)?;
7434 self.wait_for_reply(cookie)
7435 }
7436 #[cfg(feature = "render")]
7437 fn render_composite_glyphs8(
7438 &mut self,
7439 op: types::PictOp,
7440 src: types::Picture,
7441 dst: types::Picture,
7442 mask_format: types::Pictformat,
7443 glyphset: types::Glyphset,
7444 src_x: types::Int16,
7445 src_y: types::Int16,
7446 glyphcmds: impl AsRef<[types::Byte]>,
7447 ) -> Result<Cookie<()>> {
7448 let span = tracing::info_span!(
7449 "render_composite_glyphs8",
7450 op = ?op,
7451 src = ?src,
7452 dst = ?dst,
7453 mask_format = ?mask_format,
7454 glyphset = ?glyphset,
7455 src_x = ?src_x,
7456 src_y = ?src_y,
7457 );
7458 let _enter = span.enter();
7459 let request = types::render::CompositeGlyphs8Request {
7460 op,
7461 src,
7462 dst,
7463 mask_format,
7464 glyphset,
7465 src_x,
7466 src_y,
7467 glyphcmds: Cow::Borrowed(glyphcmds.as_ref()),
7468 };
7469 let cookie = self.send_void_request(request, true);
7470 cookie
7471 }
7472 #[cfg(feature = "render")]
7473 fn render_composite_glyphs8_checked(
7474 &mut self,
7475 op: types::PictOp,
7476 src: types::Picture,
7477 dst: types::Picture,
7478 mask_format: types::Pictformat,
7479 glyphset: types::Glyphset,
7480 src_x: types::Int16,
7481 src_y: types::Int16,
7482 glyphcmds: impl AsRef<[types::Byte]>,
7483 ) -> Result<()> {
7484 let request = types::render::CompositeGlyphs8Request {
7485 op,
7486 src,
7487 dst,
7488 mask_format,
7489 glyphset,
7490 src_x,
7491 src_y,
7492 glyphcmds: Cow::Borrowed(glyphcmds.as_ref()),
7493 };
7494 let cookie = self.send_void_request(request, false)?;
7495 self.wait_for_reply(cookie)
7496 }
7497 #[cfg(feature = "render")]
7498 fn render_composite_glyphs16(
7499 &mut self,
7500 op: types::PictOp,
7501 src: types::Picture,
7502 dst: types::Picture,
7503 mask_format: types::Pictformat,
7504 glyphset: types::Glyphset,
7505 src_x: types::Int16,
7506 src_y: types::Int16,
7507 glyphcmds: impl AsRef<[types::Byte]>,
7508 ) -> Result<Cookie<()>> {
7509 let span = tracing::info_span!(
7510 "render_composite_glyphs16",
7511 op = ?op,
7512 src = ?src,
7513 dst = ?dst,
7514 mask_format = ?mask_format,
7515 glyphset = ?glyphset,
7516 src_x = ?src_x,
7517 src_y = ?src_y,
7518 );
7519 let _enter = span.enter();
7520 let request = types::render::CompositeGlyphs16Request {
7521 op,
7522 src,
7523 dst,
7524 mask_format,
7525 glyphset,
7526 src_x,
7527 src_y,
7528 glyphcmds: Cow::Borrowed(glyphcmds.as_ref()),
7529 };
7530 let cookie = self.send_void_request(request, true);
7531 cookie
7532 }
7533 #[cfg(feature = "render")]
7534 fn render_composite_glyphs16_checked(
7535 &mut self,
7536 op: types::PictOp,
7537 src: types::Picture,
7538 dst: types::Picture,
7539 mask_format: types::Pictformat,
7540 glyphset: types::Glyphset,
7541 src_x: types::Int16,
7542 src_y: types::Int16,
7543 glyphcmds: impl AsRef<[types::Byte]>,
7544 ) -> Result<()> {
7545 let request = types::render::CompositeGlyphs16Request {
7546 op,
7547 src,
7548 dst,
7549 mask_format,
7550 glyphset,
7551 src_x,
7552 src_y,
7553 glyphcmds: Cow::Borrowed(glyphcmds.as_ref()),
7554 };
7555 let cookie = self.send_void_request(request, false)?;
7556 self.wait_for_reply(cookie)
7557 }
7558 #[cfg(feature = "render")]
7559 fn render_composite_glyphs32(
7560 &mut self,
7561 op: types::PictOp,
7562 src: types::Picture,
7563 dst: types::Picture,
7564 mask_format: types::Pictformat,
7565 glyphset: types::Glyphset,
7566 src_x: types::Int16,
7567 src_y: types::Int16,
7568 glyphcmds: impl AsRef<[types::Byte]>,
7569 ) -> Result<Cookie<()>> {
7570 let span = tracing::info_span!(
7571 "render_composite_glyphs32",
7572 op = ?op,
7573 src = ?src,
7574 dst = ?dst,
7575 mask_format = ?mask_format,
7576 glyphset = ?glyphset,
7577 src_x = ?src_x,
7578 src_y = ?src_y,
7579 );
7580 let _enter = span.enter();
7581 let request = types::render::CompositeGlyphs32Request {
7582 op,
7583 src,
7584 dst,
7585 mask_format,
7586 glyphset,
7587 src_x,
7588 src_y,
7589 glyphcmds: Cow::Borrowed(glyphcmds.as_ref()),
7590 };
7591 let cookie = self.send_void_request(request, true);
7592 cookie
7593 }
7594 #[cfg(feature = "render")]
7595 fn render_composite_glyphs32_checked(
7596 &mut self,
7597 op: types::PictOp,
7598 src: types::Picture,
7599 dst: types::Picture,
7600 mask_format: types::Pictformat,
7601 glyphset: types::Glyphset,
7602 src_x: types::Int16,
7603 src_y: types::Int16,
7604 glyphcmds: impl AsRef<[types::Byte]>,
7605 ) -> Result<()> {
7606 let request = types::render::CompositeGlyphs32Request {
7607 op,
7608 src,
7609 dst,
7610 mask_format,
7611 glyphset,
7612 src_x,
7613 src_y,
7614 glyphcmds: Cow::Borrowed(glyphcmds.as_ref()),
7615 };
7616 let cookie = self.send_void_request(request, false)?;
7617 self.wait_for_reply(cookie)
7618 }
7619 #[cfg(feature = "render")]
7620 fn render_fill_rectangles(
7621 &mut self,
7622 op: types::PictOp,
7623 dst: types::Picture,
7624 color: types::Color,
7625 rects: impl AsRef<[types::Rectangle]>,
7626 ) -> Result<Cookie<()>> {
7627 let span = tracing::info_span!(
7628 "render_fill_rectangles",
7629 op = ?op,
7630 dst = ?dst,
7631 color = ?color,
7632 );
7633 let _enter = span.enter();
7634 let request = types::render::FillRectanglesRequest {
7635 op,
7636 dst,
7637 color,
7638 rects: Cow::Borrowed(rects.as_ref()),
7639 };
7640 let cookie = self.send_void_request(request, true);
7641 cookie
7642 }
7643 #[cfg(feature = "render")]
7644 fn render_fill_rectangles_checked(
7645 &mut self,
7646 op: types::PictOp,
7647 dst: types::Picture,
7648 color: types::Color,
7649 rects: impl AsRef<[types::Rectangle]>,
7650 ) -> Result<()> {
7651 let request = types::render::FillRectanglesRequest {
7652 op,
7653 dst,
7654 color,
7655 rects: Cow::Borrowed(rects.as_ref()),
7656 };
7657 let cookie = self.send_void_request(request, false)?;
7658 self.wait_for_reply(cookie)
7659 }
7660 #[cfg(feature = "render")]
7661 fn render_create_cursor(
7662 &mut self,
7663 cid: types::xproto::Cursor,
7664 source: types::Picture,
7665 x: types::Card16,
7666 y: types::Card16,
7667 ) -> Result<Cookie<()>> {
7668 let span = tracing::info_span!(
7669 "render_create_cursor",
7670 cid = ?cid,
7671 source = ?source,
7672 x = ?x,
7673 y = ?y,
7674 );
7675 let _enter = span.enter();
7676 let request = types::render::CreateCursorRequest { cid, source, x, y };
7677 let cookie = self.send_void_request(request, true);
7678 cookie
7679 }
7680 #[cfg(feature = "render")]
7681 fn render_create_cursor_checked(
7682 &mut self,
7683 cid: types::xproto::Cursor,
7684 source: types::Picture,
7685 x: types::Card16,
7686 y: types::Card16,
7687 ) -> Result<()> {
7688 let request = types::render::CreateCursorRequest { cid, source, x, y };
7689 let cookie = self.send_void_request(request, false)?;
7690 self.wait_for_reply(cookie)
7691 }
7692 #[cfg(feature = "render")]
7693 fn render_set_picture_transform(
7694 &mut self,
7695 picture: types::Picture,
7696 transform: types::render::Transform,
7697 ) -> Result<Cookie<()>> {
7698 let span = tracing::info_span!(
7699 "render_set_picture_transform",
7700 picture = ?picture,
7701 transform = ?transform,
7702 );
7703 let _enter = span.enter();
7704 let request = types::render::SetPictureTransformRequest { picture, transform };
7705 let cookie = self.send_void_request(request, true);
7706 cookie
7707 }
7708 #[cfg(feature = "render")]
7709 fn render_set_picture_transform_checked(
7710 &mut self,
7711 picture: types::Picture,
7712 transform: types::render::Transform,
7713 ) -> Result<()> {
7714 let request = types::render::SetPictureTransformRequest { picture, transform };
7715 let cookie = self.send_void_request(request, false)?;
7716 self.wait_for_reply(cookie)
7717 }
7718 #[cfg(feature = "render")]
7719 fn render_query_filters(
7720 &mut self,
7721 drawable: types::xproto::Drawable,
7722 ) -> Result<Cookie<types::render::QueryFiltersReply>> {
7723 let span = tracing::info_span!(
7724 "render_query_filters",
7725 drawable = ?drawable,
7726 );
7727 let _enter = span.enter();
7728 let request = types::render::QueryFiltersRequest { drawable };
7729 let cookie = self.send_reply_request(request);
7730 cookie
7731 }
7732 #[cfg(feature = "render")]
7733 fn render_query_filters_immediate(
7734 &mut self,
7735 drawable: types::xproto::Drawable,
7736 ) -> Result<types::render::QueryFiltersReply> {
7737 let request = types::render::QueryFiltersRequest { drawable };
7738 let cookie = self.send_reply_request(request)?;
7739 self.wait_for_reply(cookie)
7740 }
7741 #[cfg(feature = "render")]
7742 fn render_set_picture_filter(
7743 &mut self,
7744 picture: types::Picture,
7745 filter: impl AsRef<[types::Char]>,
7746 values: impl AsRef<[types::Fixed]>,
7747 ) -> Result<Cookie<()>> {
7748 let span = tracing::info_span!(
7749 "render_set_picture_filter",
7750 picture = ?picture,
7751 );
7752 let _enter = span.enter();
7753 let request = types::render::SetPictureFilterRequest {
7754 picture,
7755 filter: Cow::Borrowed(filter.as_ref()),
7756 values: Cow::Borrowed(values.as_ref()),
7757 };
7758 let cookie = self.send_void_request(request, true);
7759 cookie
7760 }
7761 #[cfg(feature = "render")]
7762 fn render_set_picture_filter_checked(
7763 &mut self,
7764 picture: types::Picture,
7765 filter: impl AsRef<[types::Char]>,
7766 values: impl AsRef<[types::Fixed]>,
7767 ) -> Result<()> {
7768 let request = types::render::SetPictureFilterRequest {
7769 picture,
7770 filter: Cow::Borrowed(filter.as_ref()),
7771 values: Cow::Borrowed(values.as_ref()),
7772 };
7773 let cookie = self.send_void_request(request, false)?;
7774 self.wait_for_reply(cookie)
7775 }
7776 #[cfg(feature = "render")]
7777 fn render_create_anim_cursor(
7778 &mut self,
7779 cid: types::xproto::Cursor,
7780 cursors: impl AsRef<[types::Animcursorelt]>,
7781 ) -> Result<Cookie<()>> {
7782 let span = tracing::info_span!(
7783 "render_create_anim_cursor",
7784 cid = ?cid,
7785 );
7786 let _enter = span.enter();
7787 let request = types::render::CreateAnimCursorRequest {
7788 cid,
7789 cursors: Cow::Borrowed(cursors.as_ref()),
7790 };
7791 let cookie = self.send_void_request(request, true);
7792 cookie
7793 }
7794 #[cfg(feature = "render")]
7795 fn render_create_anim_cursor_checked(
7796 &mut self,
7797 cid: types::xproto::Cursor,
7798 cursors: impl AsRef<[types::Animcursorelt]>,
7799 ) -> Result<()> {
7800 let request = types::render::CreateAnimCursorRequest {
7801 cid,
7802 cursors: Cow::Borrowed(cursors.as_ref()),
7803 };
7804 let cookie = self.send_void_request(request, false)?;
7805 self.wait_for_reply(cookie)
7806 }
7807 #[cfg(feature = "render")]
7808 fn render_add_traps(
7809 &mut self,
7810 picture: types::Picture,
7811 x_off: types::Int16,
7812 y_off: types::Int16,
7813 traps: impl AsRef<[types::Trap]>,
7814 ) -> Result<Cookie<()>> {
7815 let span = tracing::info_span!(
7816 "render_add_traps",
7817 picture = ?picture,
7818 x_off = ?x_off,
7819 y_off = ?y_off,
7820 );
7821 let _enter = span.enter();
7822 let request = types::render::AddTrapsRequest {
7823 picture,
7824 x_off,
7825 y_off,
7826 traps: Cow::Borrowed(traps.as_ref()),
7827 };
7828 let cookie = self.send_void_request(request, true);
7829 cookie
7830 }
7831 #[cfg(feature = "render")]
7832 fn render_add_traps_checked(
7833 &mut self,
7834 picture: types::Picture,
7835 x_off: types::Int16,
7836 y_off: types::Int16,
7837 traps: impl AsRef<[types::Trap]>,
7838 ) -> Result<()> {
7839 let request = types::render::AddTrapsRequest {
7840 picture,
7841 x_off,
7842 y_off,
7843 traps: Cow::Borrowed(traps.as_ref()),
7844 };
7845 let cookie = self.send_void_request(request, false)?;
7846 self.wait_for_reply(cookie)
7847 }
7848 #[cfg(feature = "render")]
7849 fn render_create_solid_fill(
7850 &mut self,
7851 picture: types::Picture,
7852 color: types::Color,
7853 ) -> Result<Cookie<()>> {
7854 let span = tracing::info_span!(
7855 "render_create_solid_fill",
7856 picture = ?picture,
7857 color = ?color,
7858 );
7859 let _enter = span.enter();
7860 let request = types::render::CreateSolidFillRequest { picture, color };
7861 let cookie = self.send_void_request(request, true);
7862 cookie
7863 }
7864 #[cfg(feature = "render")]
7865 fn render_create_solid_fill_checked(
7866 &mut self,
7867 picture: types::Picture,
7868 color: types::Color,
7869 ) -> Result<()> {
7870 let request = types::render::CreateSolidFillRequest { picture, color };
7871 let cookie = self.send_void_request(request, false)?;
7872 self.wait_for_reply(cookie)
7873 }
7874 #[cfg(feature = "render")]
7875 fn render_create_linear_gradient(
7876 &mut self,
7877 picture: types::Picture,
7878 p1: types::Pointfix,
7879 p2: types::Pointfix,
7880 stops: impl AsRef<[types::Fixed]>,
7881 colors: impl AsRef<[types::Color]>,
7882 ) -> Result<Cookie<()>> {
7883 let span = tracing::info_span!(
7884 "render_create_linear_gradient",
7885 picture = ?picture,
7886 p1 = ?p1,
7887 p2 = ?p2,
7888 );
7889 let _enter = span.enter();
7890 let request = types::render::CreateLinearGradientRequest {
7891 picture,
7892 p1,
7893 p2,
7894 stops: Cow::Borrowed(stops.as_ref()),
7895 colors: Cow::Borrowed(colors.as_ref()),
7896 };
7897 let cookie = self.send_void_request(request, true);
7898 cookie
7899 }
7900 #[cfg(feature = "render")]
7901 fn render_create_linear_gradient_checked(
7902 &mut self,
7903 picture: types::Picture,
7904 p1: types::Pointfix,
7905 p2: types::Pointfix,
7906 stops: impl AsRef<[types::Fixed]>,
7907 colors: impl AsRef<[types::Color]>,
7908 ) -> Result<()> {
7909 let request = types::render::CreateLinearGradientRequest {
7910 picture,
7911 p1,
7912 p2,
7913 stops: Cow::Borrowed(stops.as_ref()),
7914 colors: Cow::Borrowed(colors.as_ref()),
7915 };
7916 let cookie = self.send_void_request(request, false)?;
7917 self.wait_for_reply(cookie)
7918 }
7919 #[cfg(feature = "render")]
7920 fn render_create_radial_gradient(
7921 &mut self,
7922 picture: types::Picture,
7923 inner: types::Pointfix,
7924 outer: types::Pointfix,
7925 inner_radius: types::Fixed,
7926 outer_radius: types::Fixed,
7927 stops: impl AsRef<[types::Fixed]>,
7928 colors: impl AsRef<[types::Color]>,
7929 ) -> Result<Cookie<()>> {
7930 let span = tracing::info_span!(
7931 "render_create_radial_gradient",
7932 picture = ?picture,
7933 inner = ?inner,
7934 outer = ?outer,
7935 inner_radius = ?inner_radius,
7936 outer_radius = ?outer_radius,
7937 );
7938 let _enter = span.enter();
7939 let request = types::render::CreateRadialGradientRequest {
7940 picture,
7941 inner,
7942 outer,
7943 inner_radius,
7944 outer_radius,
7945 stops: Cow::Borrowed(stops.as_ref()),
7946 colors: Cow::Borrowed(colors.as_ref()),
7947 };
7948 let cookie = self.send_void_request(request, true);
7949 cookie
7950 }
7951 #[cfg(feature = "render")]
7952 fn render_create_radial_gradient_checked(
7953 &mut self,
7954 picture: types::Picture,
7955 inner: types::Pointfix,
7956 outer: types::Pointfix,
7957 inner_radius: types::Fixed,
7958 outer_radius: types::Fixed,
7959 stops: impl AsRef<[types::Fixed]>,
7960 colors: impl AsRef<[types::Color]>,
7961 ) -> Result<()> {
7962 let request = types::render::CreateRadialGradientRequest {
7963 picture,
7964 inner,
7965 outer,
7966 inner_radius,
7967 outer_radius,
7968 stops: Cow::Borrowed(stops.as_ref()),
7969 colors: Cow::Borrowed(colors.as_ref()),
7970 };
7971 let cookie = self.send_void_request(request, false)?;
7972 self.wait_for_reply(cookie)
7973 }
7974 #[cfg(feature = "render")]
7975 fn render_create_conical_gradient(
7976 &mut self,
7977 picture: types::Picture,
7978 center: types::Pointfix,
7979 angle: types::Fixed,
7980 stops: impl AsRef<[types::Fixed]>,
7981 colors: impl AsRef<[types::Color]>,
7982 ) -> Result<Cookie<()>> {
7983 let span = tracing::info_span!(
7984 "render_create_conical_gradient",
7985 picture = ?picture,
7986 center = ?center,
7987 angle = ?angle,
7988 );
7989 let _enter = span.enter();
7990 let request = types::render::CreateConicalGradientRequest {
7991 picture,
7992 center,
7993 angle,
7994 stops: Cow::Borrowed(stops.as_ref()),
7995 colors: Cow::Borrowed(colors.as_ref()),
7996 };
7997 let cookie = self.send_void_request(request, true);
7998 cookie
7999 }
8000 #[cfg(feature = "render")]
8001 fn render_create_conical_gradient_checked(
8002 &mut self,
8003 picture: types::Picture,
8004 center: types::Pointfix,
8005 angle: types::Fixed,
8006 stops: impl AsRef<[types::Fixed]>,
8007 colors: impl AsRef<[types::Color]>,
8008 ) -> Result<()> {
8009 let request = types::render::CreateConicalGradientRequest {
8010 picture,
8011 center,
8012 angle,
8013 stops: Cow::Borrowed(stops.as_ref()),
8014 colors: Cow::Borrowed(colors.as_ref()),
8015 };
8016 let cookie = self.send_void_request(request, false)?;
8017 self.wait_for_reply(cookie)
8018 }
8019
8020 #[cfg(feature = "res")]
8021 fn res_query_version(
8022 &mut self,
8023 client_major: types::Card8,
8024 client_minor: types::Card8,
8025 ) -> Result<Cookie<types::res::QueryVersionReply>> {
8026 let span = tracing::info_span!(
8027 "res_query_version",
8028 client_major = ?client_major,
8029 client_minor = ?client_minor,
8030 );
8031 let _enter = span.enter();
8032 let request = types::res::QueryVersionRequest {
8033 client_major,
8034 client_minor,
8035 };
8036 let cookie = self.send_reply_request(request);
8037 cookie
8038 }
8039 #[cfg(feature = "res")]
8040 fn res_query_version_immediate(
8041 &mut self,
8042 client_major: types::Card8,
8043 client_minor: types::Card8,
8044 ) -> Result<types::res::QueryVersionReply> {
8045 let request = types::res::QueryVersionRequest {
8046 client_major,
8047 client_minor,
8048 };
8049 let cookie = self.send_reply_request(request)?;
8050 self.wait_for_reply(cookie)
8051 }
8052 #[cfg(feature = "res")]
8053 fn res_query_clients(&mut self) -> Result<Cookie<types::res::QueryClientsReply>> {
8054 let span = tracing::info_span!("res_query_clients",);
8055 let _enter = span.enter();
8056 let request = types::res::QueryClientsRequest {};
8057 let cookie = self.send_reply_request(request);
8058 cookie
8059 }
8060 #[cfg(feature = "res")]
8061 fn res_query_clients_immediate(&mut self) -> Result<types::res::QueryClientsReply> {
8062 let request = types::res::QueryClientsRequest {};
8063 let cookie = self.send_reply_request(request)?;
8064 self.wait_for_reply(cookie)
8065 }
8066 #[cfg(feature = "res")]
8067 fn res_query_client_resources(
8068 &mut self,
8069 xid: types::Card32,
8070 ) -> Result<Cookie<types::res::QueryClientResourcesReply>> {
8071 let span = tracing::info_span!(
8072 "res_query_client_resources",
8073 xid = ?xid,
8074 );
8075 let _enter = span.enter();
8076 let request = types::res::QueryClientResourcesRequest { xid };
8077 let cookie = self.send_reply_request(request);
8078 cookie
8079 }
8080 #[cfg(feature = "res")]
8081 fn res_query_client_resources_immediate(
8082 &mut self,
8083 xid: types::Card32,
8084 ) -> Result<types::res::QueryClientResourcesReply> {
8085 let request = types::res::QueryClientResourcesRequest { xid };
8086 let cookie = self.send_reply_request(request)?;
8087 self.wait_for_reply(cookie)
8088 }
8089 #[cfg(feature = "res")]
8090 fn res_query_client_pixmap_bytes(
8091 &mut self,
8092 xid: types::Card32,
8093 ) -> Result<Cookie<types::res::QueryClientPixmapBytesReply>> {
8094 let span = tracing::info_span!(
8095 "res_query_client_pixmap_bytes",
8096 xid = ?xid,
8097 );
8098 let _enter = span.enter();
8099 let request = types::res::QueryClientPixmapBytesRequest { xid };
8100 let cookie = self.send_reply_request(request);
8101 cookie
8102 }
8103 #[cfg(feature = "res")]
8104 fn res_query_client_pixmap_bytes_immediate(
8105 &mut self,
8106 xid: types::Card32,
8107 ) -> Result<types::res::QueryClientPixmapBytesReply> {
8108 let request = types::res::QueryClientPixmapBytesRequest { xid };
8109 let cookie = self.send_reply_request(request)?;
8110 self.wait_for_reply(cookie)
8111 }
8112 #[cfg(feature = "res")]
8113 fn res_query_client_ids(
8114 &mut self,
8115 specs: impl AsRef<[types::ClientIdSpec]>,
8116 ) -> Result<Cookie<types::res::QueryClientIdsReply>> {
8117 let span = tracing::info_span!("res_query_client_ids",);
8118 let _enter = span.enter();
8119 let request = types::res::QueryClientIdsRequest {
8120 specs: Cow::Borrowed(specs.as_ref()),
8121 };
8122 let cookie = self.send_reply_request(request);
8123 cookie
8124 }
8125 #[cfg(feature = "res")]
8126 fn res_query_client_ids_immediate(
8127 &mut self,
8128 specs: impl AsRef<[types::ClientIdSpec]>,
8129 ) -> Result<types::res::QueryClientIdsReply> {
8130 let request = types::res::QueryClientIdsRequest {
8131 specs: Cow::Borrowed(specs.as_ref()),
8132 };
8133 let cookie = self.send_reply_request(request)?;
8134 self.wait_for_reply(cookie)
8135 }
8136 #[cfg(feature = "res")]
8137 fn res_query_resource_bytes(
8138 &mut self,
8139 client: types::Card32,
8140 specs: impl AsRef<[types::ResourceIdSpec]>,
8141 ) -> Result<Cookie<types::res::QueryResourceBytesReply>> {
8142 let span = tracing::info_span!(
8143 "res_query_resource_bytes",
8144 client = ?client,
8145 );
8146 let _enter = span.enter();
8147 let request = types::res::QueryResourceBytesRequest {
8148 client,
8149 specs: Cow::Borrowed(specs.as_ref()),
8150 };
8151 let cookie = self.send_reply_request(request);
8152 cookie
8153 }
8154 #[cfg(feature = "res")]
8155 fn res_query_resource_bytes_immediate(
8156 &mut self,
8157 client: types::Card32,
8158 specs: impl AsRef<[types::ResourceIdSpec]>,
8159 ) -> Result<types::res::QueryResourceBytesReply> {
8160 let request = types::res::QueryResourceBytesRequest {
8161 client,
8162 specs: Cow::Borrowed(specs.as_ref()),
8163 };
8164 let cookie = self.send_reply_request(request)?;
8165 self.wait_for_reply(cookie)
8166 }
8167
8168 #[cfg(feature = "screensaver")]
8169 fn screensaver_query_version(
8170 &mut self,
8171 client_major_version: types::Card8,
8172 client_minor_version: types::Card8,
8173 ) -> Result<Cookie<types::screensaver::QueryVersionReply>> {
8174 let span = tracing::info_span!(
8175 "screensaver_query_version",
8176 client_major_version = ?client_major_version,
8177 client_minor_version = ?client_minor_version,
8178 );
8179 let _enter = span.enter();
8180 let request = types::screensaver::QueryVersionRequest {
8181 client_major_version,
8182 client_minor_version,
8183 };
8184 let cookie = self.send_reply_request(request);
8185 cookie
8186 }
8187 #[cfg(feature = "screensaver")]
8188 fn screensaver_query_version_immediate(
8189 &mut self,
8190 client_major_version: types::Card8,
8191 client_minor_version: types::Card8,
8192 ) -> Result<types::screensaver::QueryVersionReply> {
8193 let request = types::screensaver::QueryVersionRequest {
8194 client_major_version,
8195 client_minor_version,
8196 };
8197 let cookie = self.send_reply_request(request)?;
8198 self.wait_for_reply(cookie)
8199 }
8200 #[cfg(feature = "screensaver")]
8201 fn screensaver_query_info(
8202 &mut self,
8203 drawable: types::xproto::Drawable,
8204 ) -> Result<Cookie<types::screensaver::QueryInfoReply>> {
8205 let span = tracing::info_span!(
8206 "screensaver_query_info",
8207 drawable = ?drawable,
8208 );
8209 let _enter = span.enter();
8210 let request = types::screensaver::QueryInfoRequest { drawable };
8211 let cookie = self.send_reply_request(request);
8212 cookie
8213 }
8214 #[cfg(feature = "screensaver")]
8215 fn screensaver_query_info_immediate(
8216 &mut self,
8217 drawable: types::xproto::Drawable,
8218 ) -> Result<types::screensaver::QueryInfoReply> {
8219 let request = types::screensaver::QueryInfoRequest { drawable };
8220 let cookie = self.send_reply_request(request)?;
8221 self.wait_for_reply(cookie)
8222 }
8223 #[cfg(feature = "screensaver")]
8224 fn screensaver_select_input(
8225 &mut self,
8226 drawable: types::xproto::Drawable,
8227 event_mask: impl Into<types::screensaver::Event>,
8228 ) -> Result<Cookie<()>> {
8229 let span = tracing::info_span!(
8230 "screensaver_select_input",
8231 drawable = ?drawable,
8232 );
8233 let _enter = span.enter();
8234 let request = types::screensaver::SelectInputRequest {
8235 drawable,
8236 event_mask: Into::<u32>::into(event_mask.into()) as _,
8237 };
8238 let cookie = self.send_void_request(request, true);
8239 cookie
8240 }
8241 #[cfg(feature = "screensaver")]
8242 fn screensaver_select_input_checked(
8243 &mut self,
8244 drawable: types::xproto::Drawable,
8245 event_mask: impl Into<types::screensaver::Event>,
8246 ) -> Result<()> {
8247 let request = types::screensaver::SelectInputRequest {
8248 drawable,
8249 event_mask: Into::<u32>::into(event_mask.into()) as _,
8250 };
8251 let cookie = self.send_void_request(request, false)?;
8252 self.wait_for_reply(cookie)
8253 }
8254 #[cfg(feature = "screensaver")]
8255 fn screensaver_set_attributes(
8256 &mut self,
8257 drawable: types::xproto::Drawable,
8258 x: types::Int16,
8259 y: types::Int16,
8260 width: types::Card16,
8261 height: types::Card16,
8262 border_width: types::Card16,
8263 class: types::WindowClass,
8264 depth: types::Card8,
8265 visual: types::Visualid,
8266 value_list: impl Borrow<types::screensaver::SetAttributesAux>,
8267 ) -> Result<Cookie<()>> {
8268 let span = tracing::info_span!(
8269 "screensaver_set_attributes",
8270 drawable = ?drawable,
8271 x = ?x,
8272 y = ?y,
8273 width = ?width,
8274 height = ?height,
8275 border_width = ?border_width,
8276 class = ?class,
8277 depth = ?depth,
8278 visual = ?visual,
8279 );
8280 let _enter = span.enter();
8281 let request = types::screensaver::SetAttributesRequest {
8282 drawable,
8283 x,
8284 y,
8285 width,
8286 height,
8287 border_width,
8288 class,
8289 depth,
8290 visual,
8291 value_list: Cow::Borrowed(value_list.borrow()),
8292 };
8293 let cookie = self.send_void_request(request, true);
8294 cookie
8295 }
8296 #[cfg(feature = "screensaver")]
8297 fn screensaver_set_attributes_checked(
8298 &mut self,
8299 drawable: types::xproto::Drawable,
8300 x: types::Int16,
8301 y: types::Int16,
8302 width: types::Card16,
8303 height: types::Card16,
8304 border_width: types::Card16,
8305 class: types::WindowClass,
8306 depth: types::Card8,
8307 visual: types::Visualid,
8308 value_list: impl Borrow<types::screensaver::SetAttributesAux>,
8309 ) -> Result<()> {
8310 let request = types::screensaver::SetAttributesRequest {
8311 drawable,
8312 x,
8313 y,
8314 width,
8315 height,
8316 border_width,
8317 class,
8318 depth,
8319 visual,
8320 value_list: Cow::Borrowed(value_list.borrow()),
8321 };
8322 let cookie = self.send_void_request(request, false)?;
8323 self.wait_for_reply(cookie)
8324 }
8325 #[cfg(feature = "screensaver")]
8326 fn screensaver_unset_attributes(
8327 &mut self,
8328 drawable: types::xproto::Drawable,
8329 ) -> Result<Cookie<()>> {
8330 let span = tracing::info_span!(
8331 "screensaver_unset_attributes",
8332 drawable = ?drawable,
8333 );
8334 let _enter = span.enter();
8335 let request = types::screensaver::UnsetAttributesRequest { drawable };
8336 let cookie = self.send_void_request(request, true);
8337 cookie
8338 }
8339 #[cfg(feature = "screensaver")]
8340 fn screensaver_unset_attributes_checked(
8341 &mut self,
8342 drawable: types::xproto::Drawable,
8343 ) -> Result<()> {
8344 let request = types::screensaver::UnsetAttributesRequest { drawable };
8345 let cookie = self.send_void_request(request, false)?;
8346 self.wait_for_reply(cookie)
8347 }
8348 #[cfg(feature = "screensaver")]
8349 fn screensaver_suspend(&mut self, suspend: types::Card32) -> Result<Cookie<()>> {
8350 let span = tracing::info_span!(
8351 "screensaver_suspend",
8352 suspend = ?suspend,
8353 );
8354 let _enter = span.enter();
8355 let request = types::screensaver::SuspendRequest { suspend };
8356 let cookie = self.send_void_request(request, true);
8357 cookie
8358 }
8359 #[cfg(feature = "screensaver")]
8360 fn screensaver_suspend_checked(&mut self, suspend: types::Card32) -> Result<()> {
8361 let request = types::screensaver::SuspendRequest { suspend };
8362 let cookie = self.send_void_request(request, false)?;
8363 self.wait_for_reply(cookie)
8364 }
8365
8366 #[cfg(feature = "shape")]
8367 fn shape_query_version(&mut self) -> Result<Cookie<types::shape::QueryVersionReply>> {
8368 let span = tracing::info_span!("shape_query_version",);
8369 let _enter = span.enter();
8370 let request = types::shape::QueryVersionRequest {};
8371 let cookie = self.send_reply_request(request);
8372 cookie
8373 }
8374 #[cfg(feature = "shape")]
8375 fn shape_query_version_immediate(&mut self) -> Result<types::shape::QueryVersionReply> {
8376 let request = types::shape::QueryVersionRequest {};
8377 let cookie = self.send_reply_request(request)?;
8378 self.wait_for_reply(cookie)
8379 }
8380 #[cfg(feature = "shape")]
8381 fn shape_rectangles(
8382 &mut self,
8383 operation: types::SO,
8384 destination_kind: types::SK,
8385 ordering: types::ClipOrdering,
8386 destination_window: types::xproto::Window,
8387 x_offset: types::Int16,
8388 y_offset: types::Int16,
8389 rectangles: impl AsRef<[types::Rectangle]>,
8390 ) -> Result<Cookie<()>> {
8391 let span = tracing::info_span!(
8392 "shape_rectangles",
8393 operation = ?operation,
8394 destination_kind = ?destination_kind,
8395 ordering = ?ordering,
8396 destination_window = ?destination_window,
8397 x_offset = ?x_offset,
8398 y_offset = ?y_offset,
8399 );
8400 let _enter = span.enter();
8401 let request = types::shape::RectanglesRequest {
8402 operation,
8403 destination_kind,
8404 ordering,
8405 destination_window,
8406 x_offset,
8407 y_offset,
8408 rectangles: Cow::Borrowed(rectangles.as_ref()),
8409 };
8410 let cookie = self.send_void_request(request, true);
8411 cookie
8412 }
8413 #[cfg(feature = "shape")]
8414 fn shape_rectangles_checked(
8415 &mut self,
8416 operation: types::SO,
8417 destination_kind: types::SK,
8418 ordering: types::ClipOrdering,
8419 destination_window: types::xproto::Window,
8420 x_offset: types::Int16,
8421 y_offset: types::Int16,
8422 rectangles: impl AsRef<[types::Rectangle]>,
8423 ) -> Result<()> {
8424 let request = types::shape::RectanglesRequest {
8425 operation,
8426 destination_kind,
8427 ordering,
8428 destination_window,
8429 x_offset,
8430 y_offset,
8431 rectangles: Cow::Borrowed(rectangles.as_ref()),
8432 };
8433 let cookie = self.send_void_request(request, false)?;
8434 self.wait_for_reply(cookie)
8435 }
8436 #[cfg(feature = "shape")]
8437 fn shape_mask(
8438 &mut self,
8439 operation: types::SO,
8440 destination_kind: types::SK,
8441 destination_window: types::xproto::Window,
8442 x_offset: types::Int16,
8443 y_offset: types::Int16,
8444 source_bitmap: impl Into<types::xproto::Pixmap>,
8445 ) -> Result<Cookie<()>> {
8446 let span = tracing::info_span!(
8447 "shape_mask",
8448 operation = ?operation,
8449 destination_kind = ?destination_kind,
8450 destination_window = ?destination_window,
8451 x_offset = ?x_offset,
8452 y_offset = ?y_offset,
8453 );
8454 let _enter = span.enter();
8455 let request = types::shape::MaskRequest {
8456 operation,
8457 destination_kind,
8458 destination_window,
8459 x_offset,
8460 y_offset,
8461 source_bitmap: Into::<u32>::into(source_bitmap.into()) as _,
8462 };
8463 let cookie = self.send_void_request(request, true);
8464 cookie
8465 }
8466 #[cfg(feature = "shape")]
8467 fn shape_mask_checked(
8468 &mut self,
8469 operation: types::SO,
8470 destination_kind: types::SK,
8471 destination_window: types::xproto::Window,
8472 x_offset: types::Int16,
8473 y_offset: types::Int16,
8474 source_bitmap: impl Into<types::xproto::Pixmap>,
8475 ) -> Result<()> {
8476 let request = types::shape::MaskRequest {
8477 operation,
8478 destination_kind,
8479 destination_window,
8480 x_offset,
8481 y_offset,
8482 source_bitmap: Into::<u32>::into(source_bitmap.into()) as _,
8483 };
8484 let cookie = self.send_void_request(request, false)?;
8485 self.wait_for_reply(cookie)
8486 }
8487 #[cfg(feature = "shape")]
8488 fn shape_combine(
8489 &mut self,
8490 operation: types::SO,
8491 destination_kind: types::SK,
8492 source_kind: types::SK,
8493 destination_window: types::xproto::Window,
8494 x_offset: types::Int16,
8495 y_offset: types::Int16,
8496 source_window: types::xproto::Window,
8497 ) -> Result<Cookie<()>> {
8498 let span = tracing::info_span!(
8499 "shape_combine",
8500 operation = ?operation,
8501 destination_kind = ?destination_kind,
8502 source_kind = ?source_kind,
8503 destination_window = ?destination_window,
8504 x_offset = ?x_offset,
8505 y_offset = ?y_offset,
8506 source_window = ?source_window,
8507 );
8508 let _enter = span.enter();
8509 let request = types::shape::CombineRequest {
8510 operation,
8511 destination_kind,
8512 source_kind,
8513 destination_window,
8514 x_offset,
8515 y_offset,
8516 source_window,
8517 };
8518 let cookie = self.send_void_request(request, true);
8519 cookie
8520 }
8521 #[cfg(feature = "shape")]
8522 fn shape_combine_checked(
8523 &mut self,
8524 operation: types::SO,
8525 destination_kind: types::SK,
8526 source_kind: types::SK,
8527 destination_window: types::xproto::Window,
8528 x_offset: types::Int16,
8529 y_offset: types::Int16,
8530 source_window: types::xproto::Window,
8531 ) -> Result<()> {
8532 let request = types::shape::CombineRequest {
8533 operation,
8534 destination_kind,
8535 source_kind,
8536 destination_window,
8537 x_offset,
8538 y_offset,
8539 source_window,
8540 };
8541 let cookie = self.send_void_request(request, false)?;
8542 self.wait_for_reply(cookie)
8543 }
8544 #[cfg(feature = "shape")]
8545 fn shape_offset(
8546 &mut self,
8547 destination_kind: types::SK,
8548 destination_window: types::xproto::Window,
8549 x_offset: types::Int16,
8550 y_offset: types::Int16,
8551 ) -> Result<Cookie<()>> {
8552 let span = tracing::info_span!(
8553 "shape_offset",
8554 destination_kind = ?destination_kind,
8555 destination_window = ?destination_window,
8556 x_offset = ?x_offset,
8557 y_offset = ?y_offset,
8558 );
8559 let _enter = span.enter();
8560 let request = types::shape::OffsetRequest {
8561 destination_kind,
8562 destination_window,
8563 x_offset,
8564 y_offset,
8565 };
8566 let cookie = self.send_void_request(request, true);
8567 cookie
8568 }
8569 #[cfg(feature = "shape")]
8570 fn shape_offset_checked(
8571 &mut self,
8572 destination_kind: types::SK,
8573 destination_window: types::xproto::Window,
8574 x_offset: types::Int16,
8575 y_offset: types::Int16,
8576 ) -> Result<()> {
8577 let request = types::shape::OffsetRequest {
8578 destination_kind,
8579 destination_window,
8580 x_offset,
8581 y_offset,
8582 };
8583 let cookie = self.send_void_request(request, false)?;
8584 self.wait_for_reply(cookie)
8585 }
8586 #[cfg(feature = "shape")]
8587 fn shape_query_extents(
8588 &mut self,
8589 destination_window: types::xproto::Window,
8590 ) -> Result<Cookie<types::shape::QueryExtentsReply>> {
8591 let span = tracing::info_span!(
8592 "shape_query_extents",
8593 destination_window = ?destination_window,
8594 );
8595 let _enter = span.enter();
8596 let request = types::shape::QueryExtentsRequest { destination_window };
8597 let cookie = self.send_reply_request(request);
8598 cookie
8599 }
8600 #[cfg(feature = "shape")]
8601 fn shape_query_extents_immediate(
8602 &mut self,
8603 destination_window: types::xproto::Window,
8604 ) -> Result<types::shape::QueryExtentsReply> {
8605 let request = types::shape::QueryExtentsRequest { destination_window };
8606 let cookie = self.send_reply_request(request)?;
8607 self.wait_for_reply(cookie)
8608 }
8609 #[cfg(feature = "shape")]
8610 fn shape_select_input(
8611 &mut self,
8612 destination_window: types::xproto::Window,
8613 enable: types::Bool,
8614 ) -> Result<Cookie<()>> {
8615 let span = tracing::info_span!(
8616 "shape_select_input",
8617 destination_window = ?destination_window,
8618 enable = ?enable,
8619 );
8620 let _enter = span.enter();
8621 let request = types::shape::SelectInputRequest {
8622 destination_window,
8623 enable,
8624 };
8625 let cookie = self.send_void_request(request, true);
8626 cookie
8627 }
8628 #[cfg(feature = "shape")]
8629 fn shape_select_input_checked(
8630 &mut self,
8631 destination_window: types::xproto::Window,
8632 enable: types::Bool,
8633 ) -> Result<()> {
8634 let request = types::shape::SelectInputRequest {
8635 destination_window,
8636 enable,
8637 };
8638 let cookie = self.send_void_request(request, false)?;
8639 self.wait_for_reply(cookie)
8640 }
8641 #[cfg(feature = "shape")]
8642 fn shape_input_selected(
8643 &mut self,
8644 destination_window: types::xproto::Window,
8645 ) -> Result<Cookie<types::shape::InputSelectedReply>> {
8646 let span = tracing::info_span!(
8647 "shape_input_selected",
8648 destination_window = ?destination_window,
8649 );
8650 let _enter = span.enter();
8651 let request = types::shape::InputSelectedRequest { destination_window };
8652 let cookie = self.send_reply_request(request);
8653 cookie
8654 }
8655 #[cfg(feature = "shape")]
8656 fn shape_input_selected_immediate(
8657 &mut self,
8658 destination_window: types::xproto::Window,
8659 ) -> Result<types::shape::InputSelectedReply> {
8660 let request = types::shape::InputSelectedRequest { destination_window };
8661 let cookie = self.send_reply_request(request)?;
8662 self.wait_for_reply(cookie)
8663 }
8664 #[cfg(feature = "shape")]
8665 fn shape_get_rectangles(
8666 &mut self,
8667 window: types::xproto::Window,
8668 source_kind: types::SK,
8669 ) -> Result<Cookie<types::shape::GetRectanglesReply>> {
8670 let span = tracing::info_span!(
8671 "shape_get_rectangles",
8672 window = ?window,
8673 source_kind = ?source_kind,
8674 );
8675 let _enter = span.enter();
8676 let request = types::shape::GetRectanglesRequest {
8677 window,
8678 source_kind,
8679 };
8680 let cookie = self.send_reply_request(request);
8681 cookie
8682 }
8683 #[cfg(feature = "shape")]
8684 fn shape_get_rectangles_immediate(
8685 &mut self,
8686 window: types::xproto::Window,
8687 source_kind: types::SK,
8688 ) -> Result<types::shape::GetRectanglesReply> {
8689 let request = types::shape::GetRectanglesRequest {
8690 window,
8691 source_kind,
8692 };
8693 let cookie = self.send_reply_request(request)?;
8694 self.wait_for_reply(cookie)
8695 }
8696
8697 #[cfg(feature = "shm")]
8698 fn shm_query_version(&mut self) -> Result<Cookie<types::shm::QueryVersionReply>> {
8699 let span = tracing::info_span!("shm_query_version",);
8700 let _enter = span.enter();
8701 let request = types::shm::QueryVersionRequest {};
8702 let cookie = self.send_reply_request(request);
8703 cookie
8704 }
8705 #[cfg(feature = "shm")]
8706 fn shm_query_version_immediate(&mut self) -> Result<types::shm::QueryVersionReply> {
8707 let request = types::shm::QueryVersionRequest {};
8708 let cookie = self.send_reply_request(request)?;
8709 self.wait_for_reply(cookie)
8710 }
8711 #[cfg(feature = "shm")]
8712 fn shm_attach(
8713 &mut self,
8714 shmseg: types::Seg,
8715 shmid: types::Card32,
8716 read_only: types::Bool,
8717 ) -> Result<Cookie<()>> {
8718 let span = tracing::info_span!(
8719 "shm_attach",
8720 shmseg = ?shmseg,
8721 shmid = ?shmid,
8722 read_only = ?read_only,
8723 );
8724 let _enter = span.enter();
8725 let request = types::shm::AttachRequest {
8726 shmseg,
8727 shmid,
8728 read_only,
8729 };
8730 let cookie = self.send_void_request(request, true);
8731 cookie
8732 }
8733 #[cfg(feature = "shm")]
8734 fn shm_attach_checked(
8735 &mut self,
8736 shmseg: types::Seg,
8737 shmid: types::Card32,
8738 read_only: types::Bool,
8739 ) -> Result<()> {
8740 let request = types::shm::AttachRequest {
8741 shmseg,
8742 shmid,
8743 read_only,
8744 };
8745 let cookie = self.send_void_request(request, false)?;
8746 self.wait_for_reply(cookie)
8747 }
8748 #[cfg(feature = "shm")]
8749 fn shm_detach(&mut self, shmseg: types::Seg) -> Result<Cookie<()>> {
8750 let span = tracing::info_span!(
8751 "shm_detach",
8752 shmseg = ?shmseg,
8753 );
8754 let _enter = span.enter();
8755 let request = types::shm::DetachRequest { shmseg };
8756 let cookie = self.send_void_request(request, true);
8757 cookie
8758 }
8759 #[cfg(feature = "shm")]
8760 fn shm_detach_checked(&mut self, shmseg: types::Seg) -> Result<()> {
8761 let request = types::shm::DetachRequest { shmseg };
8762 let cookie = self.send_void_request(request, false)?;
8763 self.wait_for_reply(cookie)
8764 }
8765 #[cfg(feature = "shm")]
8766 fn shm_put_image(
8767 &mut self,
8768 drawable: types::xproto::Drawable,
8769 gc: types::Gcontext,
8770 total_width: types::Card16,
8771 total_height: types::Card16,
8772 src_x: types::Card16,
8773 src_y: types::Card16,
8774 src_width: types::Card16,
8775 src_height: types::Card16,
8776 dst_x: types::Int16,
8777 dst_y: types::Int16,
8778 depth: types::Card8,
8779 format: types::Card8,
8780 send_event: types::Bool,
8781 shmseg: types::Seg,
8782 offset: types::Card32,
8783 ) -> Result<Cookie<()>> {
8784 let span = tracing::info_span!(
8785 "shm_put_image",
8786 drawable = ?drawable,
8787 gc = ?gc,
8788 total_width = ?total_width,
8789 total_height = ?total_height,
8790 src_x = ?src_x,
8791 src_y = ?src_y,
8792 src_width = ?src_width,
8793 src_height = ?src_height,
8794 dst_x = ?dst_x,
8795 dst_y = ?dst_y,
8796 depth = ?depth,
8797 format = ?format,
8798 send_event = ?send_event,
8799 shmseg = ?shmseg,
8800 offset = ?offset,
8801 );
8802 let _enter = span.enter();
8803 let request = types::shm::PutImageRequest {
8804 drawable,
8805 gc,
8806 total_width,
8807 total_height,
8808 src_x,
8809 src_y,
8810 src_width,
8811 src_height,
8812 dst_x,
8813 dst_y,
8814 depth,
8815 format,
8816 send_event,
8817 shmseg,
8818 offset,
8819 };
8820 let cookie = self.send_void_request(request, true);
8821 cookie
8822 }
8823 #[cfg(feature = "shm")]
8824 fn shm_put_image_checked(
8825 &mut self,
8826 drawable: types::xproto::Drawable,
8827 gc: types::Gcontext,
8828 total_width: types::Card16,
8829 total_height: types::Card16,
8830 src_x: types::Card16,
8831 src_y: types::Card16,
8832 src_width: types::Card16,
8833 src_height: types::Card16,
8834 dst_x: types::Int16,
8835 dst_y: types::Int16,
8836 depth: types::Card8,
8837 format: types::Card8,
8838 send_event: types::Bool,
8839 shmseg: types::Seg,
8840 offset: types::Card32,
8841 ) -> Result<()> {
8842 let request = types::shm::PutImageRequest {
8843 drawable,
8844 gc,
8845 total_width,
8846 total_height,
8847 src_x,
8848 src_y,
8849 src_width,
8850 src_height,
8851 dst_x,
8852 dst_y,
8853 depth,
8854 format,
8855 send_event,
8856 shmseg,
8857 offset,
8858 };
8859 let cookie = self.send_void_request(request, false)?;
8860 self.wait_for_reply(cookie)
8861 }
8862 #[cfg(feature = "shm")]
8863 fn shm_get_image(
8864 &mut self,
8865 drawable: types::xproto::Drawable,
8866 x: types::Int16,
8867 y: types::Int16,
8868 width: types::Card16,
8869 height: types::Card16,
8870 plane_mask: types::Card32,
8871 format: types::Card8,
8872 shmseg: types::Seg,
8873 offset: types::Card32,
8874 ) -> Result<Cookie<types::shm::GetImageReply>> {
8875 let span = tracing::info_span!(
8876 "shm_get_image",
8877 drawable = ?drawable,
8878 x = ?x,
8879 y = ?y,
8880 width = ?width,
8881 height = ?height,
8882 plane_mask = ?plane_mask,
8883 format = ?format,
8884 shmseg = ?shmseg,
8885 offset = ?offset,
8886 );
8887 let _enter = span.enter();
8888 let request = types::shm::GetImageRequest {
8889 drawable,
8890 x,
8891 y,
8892 width,
8893 height,
8894 plane_mask,
8895 format,
8896 shmseg,
8897 offset,
8898 };
8899 let cookie = self.send_reply_request(request);
8900 cookie
8901 }
8902 #[cfg(feature = "shm")]
8903 fn shm_get_image_immediate(
8904 &mut self,
8905 drawable: types::xproto::Drawable,
8906 x: types::Int16,
8907 y: types::Int16,
8908 width: types::Card16,
8909 height: types::Card16,
8910 plane_mask: types::Card32,
8911 format: types::Card8,
8912 shmseg: types::Seg,
8913 offset: types::Card32,
8914 ) -> Result<types::shm::GetImageReply> {
8915 let request = types::shm::GetImageRequest {
8916 drawable,
8917 x,
8918 y,
8919 width,
8920 height,
8921 plane_mask,
8922 format,
8923 shmseg,
8924 offset,
8925 };
8926 let cookie = self.send_reply_request(request)?;
8927 self.wait_for_reply(cookie)
8928 }
8929 #[cfg(feature = "shm")]
8930 fn shm_create_pixmap(
8931 &mut self,
8932 pid: types::xproto::Pixmap,
8933 drawable: types::xproto::Drawable,
8934 width: types::Card16,
8935 height: types::Card16,
8936 depth: types::Card8,
8937 shmseg: types::Seg,
8938 offset: types::Card32,
8939 ) -> Result<Cookie<()>> {
8940 let span = tracing::info_span!(
8941 "shm_create_pixmap",
8942 pid = ?pid,
8943 drawable = ?drawable,
8944 width = ?width,
8945 height = ?height,
8946 depth = ?depth,
8947 shmseg = ?shmseg,
8948 offset = ?offset,
8949 );
8950 let _enter = span.enter();
8951 let request = types::shm::CreatePixmapRequest {
8952 pid,
8953 drawable,
8954 width,
8955 height,
8956 depth,
8957 shmseg,
8958 offset,
8959 };
8960 let cookie = self.send_void_request(request, true);
8961 cookie
8962 }
8963 #[cfg(feature = "shm")]
8964 fn shm_create_pixmap_checked(
8965 &mut self,
8966 pid: types::xproto::Pixmap,
8967 drawable: types::xproto::Drawable,
8968 width: types::Card16,
8969 height: types::Card16,
8970 depth: types::Card8,
8971 shmseg: types::Seg,
8972 offset: types::Card32,
8973 ) -> Result<()> {
8974 let request = types::shm::CreatePixmapRequest {
8975 pid,
8976 drawable,
8977 width,
8978 height,
8979 depth,
8980 shmseg,
8981 offset,
8982 };
8983 let cookie = self.send_void_request(request, false)?;
8984 self.wait_for_reply(cookie)
8985 }
8986 #[cfg(feature = "shm")]
8987 fn shm_attach_fd(
8988 &mut self,
8989 shmseg: types::Seg,
8990 shm_fd: types::Fd,
8991 read_only: types::Bool,
8992 ) -> Result<Cookie<()>> {
8993 let span = tracing::info_span!(
8994 "shm_attach_fd",
8995 shmseg = ?shmseg,
8996 shm_fd = ?shm_fd,
8997 read_only = ?read_only,
8998 );
8999 let _enter = span.enter();
9000 let request = types::shm::AttachFdRequest {
9001 shmseg,
9002 shm_fd,
9003 read_only,
9004 };
9005 let cookie = self.send_void_request(request, true);
9006 cookie
9007 }
9008 #[cfg(feature = "shm")]
9009 fn shm_attach_fd_checked(
9010 &mut self,
9011 shmseg: types::Seg,
9012 shm_fd: types::Fd,
9013 read_only: types::Bool,
9014 ) -> Result<()> {
9015 let request = types::shm::AttachFdRequest {
9016 shmseg,
9017 shm_fd,
9018 read_only,
9019 };
9020 let cookie = self.send_void_request(request, false)?;
9021 self.wait_for_reply(cookie)
9022 }
9023 #[cfg(feature = "shm")]
9024 fn shm_create_segment(
9025 &mut self,
9026 shmseg: types::Seg,
9027 size: types::Card32,
9028 read_only: types::Bool,
9029 ) -> Result<Cookie<types::shm::CreateSegmentReply>> {
9030 let span = tracing::info_span!(
9031 "shm_create_segment",
9032 shmseg = ?shmseg,
9033 size = ?size,
9034 read_only = ?read_only,
9035 );
9036 let _enter = span.enter();
9037 let request = types::shm::CreateSegmentRequest {
9038 shmseg,
9039 size,
9040 read_only,
9041 };
9042 let cookie = self.send_reply_fd_request(request);
9043 cookie
9044 }
9045 #[cfg(feature = "shm")]
9046 fn shm_create_segment_immediate(
9047 &mut self,
9048 shmseg: types::Seg,
9049 size: types::Card32,
9050 read_only: types::Bool,
9051 ) -> Result<types::shm::CreateSegmentReply> {
9052 let request = types::shm::CreateSegmentRequest {
9053 shmseg,
9054 size,
9055 read_only,
9056 };
9057 let cookie = self.send_reply_fd_request(request)?;
9058 self.wait_for_reply(cookie)
9059 }
9060
9061 #[cfg(feature = "sync")]
9062 fn sync_initialize(
9063 &mut self,
9064 desired_major_version: types::Card8,
9065 desired_minor_version: types::Card8,
9066 ) -> Result<Cookie<types::sync::InitializeReply>> {
9067 let span = tracing::info_span!(
9068 "sync_initialize",
9069 desired_major_version = ?desired_major_version,
9070 desired_minor_version = ?desired_minor_version,
9071 );
9072 let _enter = span.enter();
9073 let request = types::sync::InitializeRequest {
9074 desired_major_version,
9075 desired_minor_version,
9076 };
9077 let cookie = self.send_reply_request(request);
9078 cookie
9079 }
9080 #[cfg(feature = "sync")]
9081 fn sync_initialize_immediate(
9082 &mut self,
9083 desired_major_version: types::Card8,
9084 desired_minor_version: types::Card8,
9085 ) -> Result<types::sync::InitializeReply> {
9086 let request = types::sync::InitializeRequest {
9087 desired_major_version,
9088 desired_minor_version,
9089 };
9090 let cookie = self.send_reply_request(request)?;
9091 self.wait_for_reply(cookie)
9092 }
9093 #[cfg(feature = "sync")]
9094 fn sync_list_system_counters(
9095 &mut self,
9096 ) -> Result<Cookie<types::sync::ListSystemCountersReply>> {
9097 let span = tracing::info_span!("sync_list_system_counters",);
9098 let _enter = span.enter();
9099 let request = types::sync::ListSystemCountersRequest {};
9100 let cookie = self.send_reply_request(request);
9101 cookie
9102 }
9103 #[cfg(feature = "sync")]
9104 fn sync_list_system_counters_immediate(
9105 &mut self,
9106 ) -> Result<types::sync::ListSystemCountersReply> {
9107 let request = types::sync::ListSystemCountersRequest {};
9108 let cookie = self.send_reply_request(request)?;
9109 self.wait_for_reply(cookie)
9110 }
9111 #[cfg(feature = "sync")]
9112 fn sync_create_counter(
9113 &mut self,
9114 id: types::Counter,
9115 initial_value: types::sync::Int64,
9116 ) -> Result<Cookie<()>> {
9117 let span = tracing::info_span!(
9118 "sync_create_counter",
9119 id = ?id,
9120 initial_value = ?initial_value,
9121 );
9122 let _enter = span.enter();
9123 let request = types::sync::CreateCounterRequest { id, initial_value };
9124 let cookie = self.send_void_request(request, true);
9125 cookie
9126 }
9127 #[cfg(feature = "sync")]
9128 fn sync_create_counter_checked(
9129 &mut self,
9130 id: types::Counter,
9131 initial_value: types::sync::Int64,
9132 ) -> Result<()> {
9133 let request = types::sync::CreateCounterRequest { id, initial_value };
9134 let cookie = self.send_void_request(request, false)?;
9135 self.wait_for_reply(cookie)
9136 }
9137 #[cfg(feature = "sync")]
9138 fn sync_destroy_counter(&mut self, counter: types::Counter) -> Result<Cookie<()>> {
9139 let span = tracing::info_span!(
9140 "sync_destroy_counter",
9141 counter = ?counter,
9142 );
9143 let _enter = span.enter();
9144 let request = types::sync::DestroyCounterRequest { counter };
9145 let cookie = self.send_void_request(request, true);
9146 cookie
9147 }
9148 #[cfg(feature = "sync")]
9149 fn sync_destroy_counter_checked(&mut self, counter: types::Counter) -> Result<()> {
9150 let request = types::sync::DestroyCounterRequest { counter };
9151 let cookie = self.send_void_request(request, false)?;
9152 self.wait_for_reply(cookie)
9153 }
9154 #[cfg(feature = "sync")]
9155 fn sync_query_counter(
9156 &mut self,
9157 counter: types::Counter,
9158 ) -> Result<Cookie<types::sync::QueryCounterReply>> {
9159 let span = tracing::info_span!(
9160 "sync_query_counter",
9161 counter = ?counter,
9162 );
9163 let _enter = span.enter();
9164 let request = types::sync::QueryCounterRequest { counter };
9165 let cookie = self.send_reply_request(request);
9166 cookie
9167 }
9168 #[cfg(feature = "sync")]
9169 fn sync_query_counter_immediate(
9170 &mut self,
9171 counter: types::Counter,
9172 ) -> Result<types::sync::QueryCounterReply> {
9173 let request = types::sync::QueryCounterRequest { counter };
9174 let cookie = self.send_reply_request(request)?;
9175 self.wait_for_reply(cookie)
9176 }
9177 #[cfg(feature = "sync")]
9178 fn sync_await(&mut self, wait_list: impl AsRef<[types::Waitcondition]>) -> Result<Cookie<()>> {
9179 let span = tracing::info_span!("sync_await",);
9180 let _enter = span.enter();
9181 let request = types::sync::AwaitRequest {
9182 wait_list: Cow::Borrowed(wait_list.as_ref()),
9183 };
9184 let cookie = self.send_void_request(request, true);
9185 cookie
9186 }
9187 #[cfg(feature = "sync")]
9188 fn sync_await_checked(&mut self, wait_list: impl AsRef<[types::Waitcondition]>) -> Result<()> {
9189 let request = types::sync::AwaitRequest {
9190 wait_list: Cow::Borrowed(wait_list.as_ref()),
9191 };
9192 let cookie = self.send_void_request(request, false)?;
9193 self.wait_for_reply(cookie)
9194 }
9195 #[cfg(feature = "sync")]
9196 fn sync_change_counter(
9197 &mut self,
9198 counter: types::Counter,
9199 amount: types::sync::Int64,
9200 ) -> Result<Cookie<()>> {
9201 let span = tracing::info_span!(
9202 "sync_change_counter",
9203 counter = ?counter,
9204 amount = ?amount,
9205 );
9206 let _enter = span.enter();
9207 let request = types::sync::ChangeCounterRequest { counter, amount };
9208 let cookie = self.send_void_request(request, true);
9209 cookie
9210 }
9211 #[cfg(feature = "sync")]
9212 fn sync_change_counter_checked(
9213 &mut self,
9214 counter: types::Counter,
9215 amount: types::sync::Int64,
9216 ) -> Result<()> {
9217 let request = types::sync::ChangeCounterRequest { counter, amount };
9218 let cookie = self.send_void_request(request, false)?;
9219 self.wait_for_reply(cookie)
9220 }
9221 #[cfg(feature = "sync")]
9222 fn sync_set_counter(
9223 &mut self,
9224 counter: types::Counter,
9225 value: types::sync::Int64,
9226 ) -> Result<Cookie<()>> {
9227 let span = tracing::info_span!(
9228 "sync_set_counter",
9229 counter = ?counter,
9230 value = ?value,
9231 );
9232 let _enter = span.enter();
9233 let request = types::sync::SetCounterRequest { counter, value };
9234 let cookie = self.send_void_request(request, true);
9235 cookie
9236 }
9237 #[cfg(feature = "sync")]
9238 fn sync_set_counter_checked(
9239 &mut self,
9240 counter: types::Counter,
9241 value: types::sync::Int64,
9242 ) -> Result<()> {
9243 let request = types::sync::SetCounterRequest { counter, value };
9244 let cookie = self.send_void_request(request, false)?;
9245 self.wait_for_reply(cookie)
9246 }
9247 #[cfg(feature = "sync")]
9248 fn sync_create_alarm(
9249 &mut self,
9250 id: types::Alarm,
9251 value_list: impl Borrow<types::sync::CreateAlarmAux>,
9252 ) -> Result<Cookie<()>> {
9253 let span = tracing::info_span!(
9254 "sync_create_alarm",
9255 id = ?id,
9256 );
9257 let _enter = span.enter();
9258 let request = types::sync::CreateAlarmRequest {
9259 id,
9260 value_list: Cow::Borrowed(value_list.borrow()),
9261 };
9262 let cookie = self.send_void_request(request, true);
9263 cookie
9264 }
9265 #[cfg(feature = "sync")]
9266 fn sync_create_alarm_checked(
9267 &mut self,
9268 id: types::Alarm,
9269 value_list: impl Borrow<types::sync::CreateAlarmAux>,
9270 ) -> Result<()> {
9271 let request = types::sync::CreateAlarmRequest {
9272 id,
9273 value_list: Cow::Borrowed(value_list.borrow()),
9274 };
9275 let cookie = self.send_void_request(request, false)?;
9276 self.wait_for_reply(cookie)
9277 }
9278 #[cfg(feature = "sync")]
9279 fn sync_change_alarm(
9280 &mut self,
9281 id: types::Alarm,
9282 value_list: impl Borrow<types::sync::ChangeAlarmAux>,
9283 ) -> Result<Cookie<()>> {
9284 let span = tracing::info_span!(
9285 "sync_change_alarm",
9286 id = ?id,
9287 );
9288 let _enter = span.enter();
9289 let request = types::sync::ChangeAlarmRequest {
9290 id,
9291 value_list: Cow::Borrowed(value_list.borrow()),
9292 };
9293 let cookie = self.send_void_request(request, true);
9294 cookie
9295 }
9296 #[cfg(feature = "sync")]
9297 fn sync_change_alarm_checked(
9298 &mut self,
9299 id: types::Alarm,
9300 value_list: impl Borrow<types::sync::ChangeAlarmAux>,
9301 ) -> Result<()> {
9302 let request = types::sync::ChangeAlarmRequest {
9303 id,
9304 value_list: Cow::Borrowed(value_list.borrow()),
9305 };
9306 let cookie = self.send_void_request(request, false)?;
9307 self.wait_for_reply(cookie)
9308 }
9309 #[cfg(feature = "sync")]
9310 fn sync_destroy_alarm(&mut self, alarm: types::Alarm) -> Result<Cookie<()>> {
9311 let span = tracing::info_span!(
9312 "sync_destroy_alarm",
9313 alarm = ?alarm,
9314 );
9315 let _enter = span.enter();
9316 let request = types::sync::DestroyAlarmRequest { alarm };
9317 let cookie = self.send_void_request(request, true);
9318 cookie
9319 }
9320 #[cfg(feature = "sync")]
9321 fn sync_destroy_alarm_checked(&mut self, alarm: types::Alarm) -> Result<()> {
9322 let request = types::sync::DestroyAlarmRequest { alarm };
9323 let cookie = self.send_void_request(request, false)?;
9324 self.wait_for_reply(cookie)
9325 }
9326 #[cfg(feature = "sync")]
9327 fn sync_query_alarm(
9328 &mut self,
9329 alarm: types::Alarm,
9330 ) -> Result<Cookie<types::sync::QueryAlarmReply>> {
9331 let span = tracing::info_span!(
9332 "sync_query_alarm",
9333 alarm = ?alarm,
9334 );
9335 let _enter = span.enter();
9336 let request = types::sync::QueryAlarmRequest { alarm };
9337 let cookie = self.send_reply_request(request);
9338 cookie
9339 }
9340 #[cfg(feature = "sync")]
9341 fn sync_query_alarm_immediate(
9342 &mut self,
9343 alarm: types::Alarm,
9344 ) -> Result<types::sync::QueryAlarmReply> {
9345 let request = types::sync::QueryAlarmRequest { alarm };
9346 let cookie = self.send_reply_request(request)?;
9347 self.wait_for_reply(cookie)
9348 }
9349 #[cfg(feature = "sync")]
9350 fn sync_set_priority(
9351 &mut self,
9352 id: types::Card32,
9353 priority: types::Int32,
9354 ) -> Result<Cookie<()>> {
9355 let span = tracing::info_span!(
9356 "sync_set_priority",
9357 id = ?id,
9358 priority = ?priority,
9359 );
9360 let _enter = span.enter();
9361 let request = types::sync::SetPriorityRequest { id, priority };
9362 let cookie = self.send_void_request(request, true);
9363 cookie
9364 }
9365 #[cfg(feature = "sync")]
9366 fn sync_set_priority_checked(
9367 &mut self,
9368 id: types::Card32,
9369 priority: types::Int32,
9370 ) -> Result<()> {
9371 let request = types::sync::SetPriorityRequest { id, priority };
9372 let cookie = self.send_void_request(request, false)?;
9373 self.wait_for_reply(cookie)
9374 }
9375 #[cfg(feature = "sync")]
9376 fn sync_get_priority(
9377 &mut self,
9378 id: types::Card32,
9379 ) -> Result<Cookie<types::sync::GetPriorityReply>> {
9380 let span = tracing::info_span!(
9381 "sync_get_priority",
9382 id = ?id,
9383 );
9384 let _enter = span.enter();
9385 let request = types::sync::GetPriorityRequest { id };
9386 let cookie = self.send_reply_request(request);
9387 cookie
9388 }
9389 #[cfg(feature = "sync")]
9390 fn sync_get_priority_immediate(
9391 &mut self,
9392 id: types::Card32,
9393 ) -> Result<types::sync::GetPriorityReply> {
9394 let request = types::sync::GetPriorityRequest { id };
9395 let cookie = self.send_reply_request(request)?;
9396 self.wait_for_reply(cookie)
9397 }
9398 #[cfg(feature = "sync")]
9399 fn sync_create_fence(
9400 &mut self,
9401 drawable: types::xproto::Drawable,
9402 fence: types::Fence,
9403 initially_triggered: types::Bool,
9404 ) -> Result<Cookie<()>> {
9405 let span = tracing::info_span!(
9406 "sync_create_fence",
9407 drawable = ?drawable,
9408 fence = ?fence,
9409 initially_triggered = ?initially_triggered,
9410 );
9411 let _enter = span.enter();
9412 let request = types::sync::CreateFenceRequest {
9413 drawable,
9414 fence,
9415 initially_triggered,
9416 };
9417 let cookie = self.send_void_request(request, true);
9418 cookie
9419 }
9420 #[cfg(feature = "sync")]
9421 fn sync_create_fence_checked(
9422 &mut self,
9423 drawable: types::xproto::Drawable,
9424 fence: types::Fence,
9425 initially_triggered: types::Bool,
9426 ) -> Result<()> {
9427 let request = types::sync::CreateFenceRequest {
9428 drawable,
9429 fence,
9430 initially_triggered,
9431 };
9432 let cookie = self.send_void_request(request, false)?;
9433 self.wait_for_reply(cookie)
9434 }
9435 #[cfg(feature = "sync")]
9436 fn sync_trigger_fence(&mut self, fence: types::Fence) -> Result<Cookie<()>> {
9437 let span = tracing::info_span!(
9438 "sync_trigger_fence",
9439 fence = ?fence,
9440 );
9441 let _enter = span.enter();
9442 let request = types::sync::TriggerFenceRequest { fence };
9443 let cookie = self.send_void_request(request, true);
9444 cookie
9445 }
9446 #[cfg(feature = "sync")]
9447 fn sync_trigger_fence_checked(&mut self, fence: types::Fence) -> Result<()> {
9448 let request = types::sync::TriggerFenceRequest { fence };
9449 let cookie = self.send_void_request(request, false)?;
9450 self.wait_for_reply(cookie)
9451 }
9452 #[cfg(feature = "sync")]
9453 fn sync_reset_fence(&mut self, fence: types::Fence) -> Result<Cookie<()>> {
9454 let span = tracing::info_span!(
9455 "sync_reset_fence",
9456 fence = ?fence,
9457 );
9458 let _enter = span.enter();
9459 let request = types::sync::ResetFenceRequest { fence };
9460 let cookie = self.send_void_request(request, true);
9461 cookie
9462 }
9463 #[cfg(feature = "sync")]
9464 fn sync_reset_fence_checked(&mut self, fence: types::Fence) -> Result<()> {
9465 let request = types::sync::ResetFenceRequest { fence };
9466 let cookie = self.send_void_request(request, false)?;
9467 self.wait_for_reply(cookie)
9468 }
9469 #[cfg(feature = "sync")]
9470 fn sync_destroy_fence(&mut self, fence: types::Fence) -> Result<Cookie<()>> {
9471 let span = tracing::info_span!(
9472 "sync_destroy_fence",
9473 fence = ?fence,
9474 );
9475 let _enter = span.enter();
9476 let request = types::sync::DestroyFenceRequest { fence };
9477 let cookie = self.send_void_request(request, true);
9478 cookie
9479 }
9480 #[cfg(feature = "sync")]
9481 fn sync_destroy_fence_checked(&mut self, fence: types::Fence) -> Result<()> {
9482 let request = types::sync::DestroyFenceRequest { fence };
9483 let cookie = self.send_void_request(request, false)?;
9484 self.wait_for_reply(cookie)
9485 }
9486 #[cfg(feature = "sync")]
9487 fn sync_query_fence(
9488 &mut self,
9489 fence: types::Fence,
9490 ) -> Result<Cookie<types::sync::QueryFenceReply>> {
9491 let span = tracing::info_span!(
9492 "sync_query_fence",
9493 fence = ?fence,
9494 );
9495 let _enter = span.enter();
9496 let request = types::sync::QueryFenceRequest { fence };
9497 let cookie = self.send_reply_request(request);
9498 cookie
9499 }
9500 #[cfg(feature = "sync")]
9501 fn sync_query_fence_immediate(
9502 &mut self,
9503 fence: types::Fence,
9504 ) -> Result<types::sync::QueryFenceReply> {
9505 let request = types::sync::QueryFenceRequest { fence };
9506 let cookie = self.send_reply_request(request)?;
9507 self.wait_for_reply(cookie)
9508 }
9509 #[cfg(feature = "sync")]
9510 fn sync_await_fence(&mut self, fence_list: impl AsRef<[types::Fence]>) -> Result<Cookie<()>> {
9511 let span = tracing::info_span!("sync_await_fence",);
9512 let _enter = span.enter();
9513 let request = types::sync::AwaitFenceRequest {
9514 fence_list: Cow::Borrowed(fence_list.as_ref()),
9515 };
9516 let cookie = self.send_void_request(request, true);
9517 cookie
9518 }
9519 #[cfg(feature = "sync")]
9520 fn sync_await_fence_checked(&mut self, fence_list: impl AsRef<[types::Fence]>) -> Result<()> {
9521 let request = types::sync::AwaitFenceRequest {
9522 fence_list: Cow::Borrowed(fence_list.as_ref()),
9523 };
9524 let cookie = self.send_void_request(request, false)?;
9525 self.wait_for_reply(cookie)
9526 }
9527
9528 fn xc_misc_get_version(
9529 &mut self,
9530 client_major_version: types::Card16,
9531 client_minor_version: types::Card16,
9532 ) -> Result<Cookie<types::xc_misc::GetVersionReply>> {
9533 let span = tracing::info_span!(
9534 "xc_misc_get_version",
9535 client_major_version = ?client_major_version,
9536 client_minor_version = ?client_minor_version,
9537 );
9538 let _enter = span.enter();
9539 let request = types::xc_misc::GetVersionRequest {
9540 client_major_version,
9541 client_minor_version,
9542 };
9543 let cookie = self.send_reply_request(request);
9544 cookie
9545 }
9546 fn xc_misc_get_version_immediate(
9547 &mut self,
9548 client_major_version: types::Card16,
9549 client_minor_version: types::Card16,
9550 ) -> Result<types::xc_misc::GetVersionReply> {
9551 let request = types::xc_misc::GetVersionRequest {
9552 client_major_version,
9553 client_minor_version,
9554 };
9555 let cookie = self.send_reply_request(request)?;
9556 self.wait_for_reply(cookie)
9557 }
9558 fn xc_misc_get_xid_range(&mut self) -> Result<Cookie<types::xc_misc::GetXIDRangeReply>> {
9559 let span = tracing::info_span!("xc_misc_get_xid_range",);
9560 let _enter = span.enter();
9561 let request = types::xc_misc::GetXIDRangeRequest {};
9562 let cookie = self.send_reply_request(request);
9563 cookie
9564 }
9565 fn xc_misc_get_xid_range_immediate(&mut self) -> Result<types::xc_misc::GetXIDRangeReply> {
9566 let request = types::xc_misc::GetXIDRangeRequest {};
9567 let cookie = self.send_reply_request(request)?;
9568 self.wait_for_reply(cookie)
9569 }
9570 fn xc_misc_get_xid_list(
9571 &mut self,
9572 count: types::Card32,
9573 ) -> Result<Cookie<types::xc_misc::GetXIDListReply>> {
9574 let span = tracing::info_span!(
9575 "xc_misc_get_xid_list",
9576 count = ?count,
9577 );
9578 let _enter = span.enter();
9579 let request = types::xc_misc::GetXIDListRequest { count };
9580 let cookie = self.send_reply_request(request);
9581 cookie
9582 }
9583 fn xc_misc_get_xid_list_immediate(
9584 &mut self,
9585 count: types::Card32,
9586 ) -> Result<types::xc_misc::GetXIDListReply> {
9587 let request = types::xc_misc::GetXIDListRequest { count };
9588 let cookie = self.send_reply_request(request)?;
9589 self.wait_for_reply(cookie)
9590 }
9591
9592 #[cfg(feature = "xevie")]
9593 fn xevie_query_version(
9594 &mut self,
9595 client_major_version: types::Card16,
9596 client_minor_version: types::Card16,
9597 ) -> Result<Cookie<types::xevie::QueryVersionReply>> {
9598 let span = tracing::info_span!(
9599 "xevie_query_version",
9600 client_major_version = ?client_major_version,
9601 client_minor_version = ?client_minor_version,
9602 );
9603 let _enter = span.enter();
9604 let request = types::xevie::QueryVersionRequest {
9605 client_major_version,
9606 client_minor_version,
9607 };
9608 let cookie = self.send_reply_request(request);
9609 cookie
9610 }
9611 #[cfg(feature = "xevie")]
9612 fn xevie_query_version_immediate(
9613 &mut self,
9614 client_major_version: types::Card16,
9615 client_minor_version: types::Card16,
9616 ) -> Result<types::xevie::QueryVersionReply> {
9617 let request = types::xevie::QueryVersionRequest {
9618 client_major_version,
9619 client_minor_version,
9620 };
9621 let cookie = self.send_reply_request(request)?;
9622 self.wait_for_reply(cookie)
9623 }
9624 #[cfg(feature = "xevie")]
9625 fn xevie_start(&mut self, screen: types::Card32) -> Result<Cookie<types::xevie::StartReply>> {
9626 let span = tracing::info_span!(
9627 "xevie_start",
9628 screen = ?screen,
9629 );
9630 let _enter = span.enter();
9631 let request = types::xevie::StartRequest { screen };
9632 let cookie = self.send_reply_request(request);
9633 cookie
9634 }
9635 #[cfg(feature = "xevie")]
9636 fn xevie_start_immediate(&mut self, screen: types::Card32) -> Result<types::xevie::StartReply> {
9637 let request = types::xevie::StartRequest { screen };
9638 let cookie = self.send_reply_request(request)?;
9639 self.wait_for_reply(cookie)
9640 }
9641 #[cfg(feature = "xevie")]
9642 fn xevie_end(&mut self, cmap: types::Card32) -> Result<Cookie<types::xevie::EndReply>> {
9643 let span = tracing::info_span!(
9644 "xevie_end",
9645 cmap = ?cmap,
9646 );
9647 let _enter = span.enter();
9648 let request = types::xevie::EndRequest { cmap };
9649 let cookie = self.send_reply_request(request);
9650 cookie
9651 }
9652 #[cfg(feature = "xevie")]
9653 fn xevie_end_immediate(&mut self, cmap: types::Card32) -> Result<types::xevie::EndReply> {
9654 let request = types::xevie::EndRequest { cmap };
9655 let cookie = self.send_reply_request(request)?;
9656 self.wait_for_reply(cookie)
9657 }
9658 #[cfg(feature = "xevie")]
9659 fn xevie_send(
9660 &mut self,
9661 event: types::xevie::Event,
9662 data_type: types::Card32,
9663 ) -> Result<Cookie<types::xevie::SendReply>> {
9664 let span = tracing::info_span!(
9665 "xevie_send",
9666 event = ?event,
9667 data_type = ?data_type,
9668 );
9669 let _enter = span.enter();
9670 let request = types::xevie::SendRequest { event, data_type };
9671 let cookie = self.send_reply_request(request);
9672 cookie
9673 }
9674 #[cfg(feature = "xevie")]
9675 fn xevie_send_immediate(
9676 &mut self,
9677 event: types::xevie::Event,
9678 data_type: types::Card32,
9679 ) -> Result<types::xevie::SendReply> {
9680 let request = types::xevie::SendRequest { event, data_type };
9681 let cookie = self.send_reply_request(request)?;
9682 self.wait_for_reply(cookie)
9683 }
9684 #[cfg(feature = "xevie")]
9685 fn xevie_select_input(
9686 &mut self,
9687 event_mask: types::Card32,
9688 ) -> Result<Cookie<types::xevie::SelectInputReply>> {
9689 let span = tracing::info_span!(
9690 "xevie_select_input",
9691 event_mask = ?event_mask,
9692 );
9693 let _enter = span.enter();
9694 let request = types::xevie::SelectInputRequest { event_mask };
9695 let cookie = self.send_reply_request(request);
9696 cookie
9697 }
9698 #[cfg(feature = "xevie")]
9699 fn xevie_select_input_immediate(
9700 &mut self,
9701 event_mask: types::Card32,
9702 ) -> Result<types::xevie::SelectInputReply> {
9703 let request = types::xevie::SelectInputRequest { event_mask };
9704 let cookie = self.send_reply_request(request)?;
9705 self.wait_for_reply(cookie)
9706 }
9707
9708 #[cfg(feature = "xf86dri")]
9709 fn xf86dri_query_version(&mut self) -> Result<Cookie<types::xf86dri::QueryVersionReply>> {
9710 let span = tracing::info_span!("xf86dri_query_version",);
9711 let _enter = span.enter();
9712 let request = types::xf86dri::QueryVersionRequest {};
9713 let cookie = self.send_reply_request(request);
9714 cookie
9715 }
9716 #[cfg(feature = "xf86dri")]
9717 fn xf86dri_query_version_immediate(&mut self) -> Result<types::xf86dri::QueryVersionReply> {
9718 let request = types::xf86dri::QueryVersionRequest {};
9719 let cookie = self.send_reply_request(request)?;
9720 self.wait_for_reply(cookie)
9721 }
9722 #[cfg(feature = "xf86dri")]
9723 fn xf86dri_query_direct_rendering_capable(
9724 &mut self,
9725 screen: types::Card32,
9726 ) -> Result<Cookie<types::xf86dri::QueryDirectRenderingCapableReply>> {
9727 let span = tracing::info_span!(
9728 "xf86dri_query_direct_rendering_capable",
9729 screen = ?screen,
9730 );
9731 let _enter = span.enter();
9732 let request = types::xf86dri::QueryDirectRenderingCapableRequest { screen };
9733 let cookie = self.send_reply_request(request);
9734 cookie
9735 }
9736 #[cfg(feature = "xf86dri")]
9737 fn xf86dri_query_direct_rendering_capable_immediate(
9738 &mut self,
9739 screen: types::Card32,
9740 ) -> Result<types::xf86dri::QueryDirectRenderingCapableReply> {
9741 let request = types::xf86dri::QueryDirectRenderingCapableRequest { screen };
9742 let cookie = self.send_reply_request(request)?;
9743 self.wait_for_reply(cookie)
9744 }
9745 #[cfg(feature = "xf86dri")]
9746 fn xf86dri_open_connection(
9747 &mut self,
9748 screen: types::Card32,
9749 ) -> Result<Cookie<types::xf86dri::OpenConnectionReply>> {
9750 let span = tracing::info_span!(
9751 "xf86dri_open_connection",
9752 screen = ?screen,
9753 );
9754 let _enter = span.enter();
9755 let request = types::xf86dri::OpenConnectionRequest { screen };
9756 let cookie = self.send_reply_request(request);
9757 cookie
9758 }
9759 #[cfg(feature = "xf86dri")]
9760 fn xf86dri_open_connection_immediate(
9761 &mut self,
9762 screen: types::Card32,
9763 ) -> Result<types::xf86dri::OpenConnectionReply> {
9764 let request = types::xf86dri::OpenConnectionRequest { screen };
9765 let cookie = self.send_reply_request(request)?;
9766 self.wait_for_reply(cookie)
9767 }
9768 #[cfg(feature = "xf86dri")]
9769 fn xf86dri_close_connection(&mut self, screen: types::Card32) -> Result<Cookie<()>> {
9770 let span = tracing::info_span!(
9771 "xf86dri_close_connection",
9772 screen = ?screen,
9773 );
9774 let _enter = span.enter();
9775 let request = types::xf86dri::CloseConnectionRequest { screen };
9776 let cookie = self.send_void_request(request, true);
9777 cookie
9778 }
9779 #[cfg(feature = "xf86dri")]
9780 fn xf86dri_close_connection_checked(&mut self, screen: types::Card32) -> Result<()> {
9781 let request = types::xf86dri::CloseConnectionRequest { screen };
9782 let cookie = self.send_void_request(request, false)?;
9783 self.wait_for_reply(cookie)
9784 }
9785 #[cfg(feature = "xf86dri")]
9786 fn xf86dri_get_client_driver_name(
9787 &mut self,
9788 screen: types::Card32,
9789 ) -> Result<Cookie<types::xf86dri::GetClientDriverNameReply>> {
9790 let span = tracing::info_span!(
9791 "xf86dri_get_client_driver_name",
9792 screen = ?screen,
9793 );
9794 let _enter = span.enter();
9795 let request = types::xf86dri::GetClientDriverNameRequest { screen };
9796 let cookie = self.send_reply_request(request);
9797 cookie
9798 }
9799 #[cfg(feature = "xf86dri")]
9800 fn xf86dri_get_client_driver_name_immediate(
9801 &mut self,
9802 screen: types::Card32,
9803 ) -> Result<types::xf86dri::GetClientDriverNameReply> {
9804 let request = types::xf86dri::GetClientDriverNameRequest { screen };
9805 let cookie = self.send_reply_request(request)?;
9806 self.wait_for_reply(cookie)
9807 }
9808 #[cfg(feature = "xf86dri")]
9809 fn xf86dri_create_context(
9810 &mut self,
9811 screen: types::Card32,
9812 visual: types::Card32,
9813 context: types::Card32,
9814 ) -> Result<Cookie<types::xf86dri::CreateContextReply>> {
9815 let span = tracing::info_span!(
9816 "xf86dri_create_context",
9817 screen = ?screen,
9818 visual = ?visual,
9819 context = ?context,
9820 );
9821 let _enter = span.enter();
9822 let request = types::xf86dri::CreateContextRequest {
9823 screen,
9824 visual,
9825 context,
9826 };
9827 let cookie = self.send_reply_request(request);
9828 cookie
9829 }
9830 #[cfg(feature = "xf86dri")]
9831 fn xf86dri_create_context_immediate(
9832 &mut self,
9833 screen: types::Card32,
9834 visual: types::Card32,
9835 context: types::Card32,
9836 ) -> Result<types::xf86dri::CreateContextReply> {
9837 let request = types::xf86dri::CreateContextRequest {
9838 screen,
9839 visual,
9840 context,
9841 };
9842 let cookie = self.send_reply_request(request)?;
9843 self.wait_for_reply(cookie)
9844 }
9845 #[cfg(feature = "xf86dri")]
9846 fn xf86dri_destroy_context(
9847 &mut self,
9848 screen: types::Card32,
9849 context: types::Card32,
9850 ) -> Result<Cookie<()>> {
9851 let span = tracing::info_span!(
9852 "xf86dri_destroy_context",
9853 screen = ?screen,
9854 context = ?context,
9855 );
9856 let _enter = span.enter();
9857 let request = types::xf86dri::DestroyContextRequest { screen, context };
9858 let cookie = self.send_void_request(request, true);
9859 cookie
9860 }
9861 #[cfg(feature = "xf86dri")]
9862 fn xf86dri_destroy_context_checked(
9863 &mut self,
9864 screen: types::Card32,
9865 context: types::Card32,
9866 ) -> Result<()> {
9867 let request = types::xf86dri::DestroyContextRequest { screen, context };
9868 let cookie = self.send_void_request(request, false)?;
9869 self.wait_for_reply(cookie)
9870 }
9871 #[cfg(feature = "xf86dri")]
9872 fn xf86dri_create_drawable(
9873 &mut self,
9874 screen: types::Card32,
9875 drawable: types::Card32,
9876 ) -> Result<Cookie<types::xf86dri::CreateDrawableReply>> {
9877 let span = tracing::info_span!(
9878 "xf86dri_create_drawable",
9879 screen = ?screen,
9880 drawable = ?drawable,
9881 );
9882 let _enter = span.enter();
9883 let request = types::xf86dri::CreateDrawableRequest { screen, drawable };
9884 let cookie = self.send_reply_request(request);
9885 cookie
9886 }
9887 #[cfg(feature = "xf86dri")]
9888 fn xf86dri_create_drawable_immediate(
9889 &mut self,
9890 screen: types::Card32,
9891 drawable: types::Card32,
9892 ) -> Result<types::xf86dri::CreateDrawableReply> {
9893 let request = types::xf86dri::CreateDrawableRequest { screen, drawable };
9894 let cookie = self.send_reply_request(request)?;
9895 self.wait_for_reply(cookie)
9896 }
9897 #[cfg(feature = "xf86dri")]
9898 fn xf86dri_destroy_drawable(
9899 &mut self,
9900 screen: types::Card32,
9901 drawable: types::Card32,
9902 ) -> Result<Cookie<()>> {
9903 let span = tracing::info_span!(
9904 "xf86dri_destroy_drawable",
9905 screen = ?screen,
9906 drawable = ?drawable,
9907 );
9908 let _enter = span.enter();
9909 let request = types::xf86dri::DestroyDrawableRequest { screen, drawable };
9910 let cookie = self.send_void_request(request, true);
9911 cookie
9912 }
9913 #[cfg(feature = "xf86dri")]
9914 fn xf86dri_destroy_drawable_checked(
9915 &mut self,
9916 screen: types::Card32,
9917 drawable: types::Card32,
9918 ) -> Result<()> {
9919 let request = types::xf86dri::DestroyDrawableRequest { screen, drawable };
9920 let cookie = self.send_void_request(request, false)?;
9921 self.wait_for_reply(cookie)
9922 }
9923 #[cfg(feature = "xf86dri")]
9924 fn xf86dri_get_drawable_info(
9925 &mut self,
9926 screen: types::Card32,
9927 drawable: types::Card32,
9928 ) -> Result<Cookie<types::xf86dri::GetDrawableInfoReply>> {
9929 let span = tracing::info_span!(
9930 "xf86dri_get_drawable_info",
9931 screen = ?screen,
9932 drawable = ?drawable,
9933 );
9934 let _enter = span.enter();
9935 let request = types::xf86dri::GetDrawableInfoRequest { screen, drawable };
9936 let cookie = self.send_reply_request(request);
9937 cookie
9938 }
9939 #[cfg(feature = "xf86dri")]
9940 fn xf86dri_get_drawable_info_immediate(
9941 &mut self,
9942 screen: types::Card32,
9943 drawable: types::Card32,
9944 ) -> Result<types::xf86dri::GetDrawableInfoReply> {
9945 let request = types::xf86dri::GetDrawableInfoRequest { screen, drawable };
9946 let cookie = self.send_reply_request(request)?;
9947 self.wait_for_reply(cookie)
9948 }
9949 #[cfg(feature = "xf86dri")]
9950 fn xf86dri_get_device_info(
9951 &mut self,
9952 screen: types::Card32,
9953 ) -> Result<Cookie<types::xf86dri::GetDeviceInfoReply>> {
9954 let span = tracing::info_span!(
9955 "xf86dri_get_device_info",
9956 screen = ?screen,
9957 );
9958 let _enter = span.enter();
9959 let request = types::xf86dri::GetDeviceInfoRequest { screen };
9960 let cookie = self.send_reply_request(request);
9961 cookie
9962 }
9963 #[cfg(feature = "xf86dri")]
9964 fn xf86dri_get_device_info_immediate(
9965 &mut self,
9966 screen: types::Card32,
9967 ) -> Result<types::xf86dri::GetDeviceInfoReply> {
9968 let request = types::xf86dri::GetDeviceInfoRequest { screen };
9969 let cookie = self.send_reply_request(request)?;
9970 self.wait_for_reply(cookie)
9971 }
9972 #[cfg(feature = "xf86dri")]
9973 fn xf86dri_auth_connection(
9974 &mut self,
9975 screen: types::Card32,
9976 magic: types::Card32,
9977 ) -> Result<Cookie<types::xf86dri::AuthConnectionReply>> {
9978 let span = tracing::info_span!(
9979 "xf86dri_auth_connection",
9980 screen = ?screen,
9981 magic = ?magic,
9982 );
9983 let _enter = span.enter();
9984 let request = types::xf86dri::AuthConnectionRequest { screen, magic };
9985 let cookie = self.send_reply_request(request);
9986 cookie
9987 }
9988 #[cfg(feature = "xf86dri")]
9989 fn xf86dri_auth_connection_immediate(
9990 &mut self,
9991 screen: types::Card32,
9992 magic: types::Card32,
9993 ) -> Result<types::xf86dri::AuthConnectionReply> {
9994 let request = types::xf86dri::AuthConnectionRequest { screen, magic };
9995 let cookie = self.send_reply_request(request)?;
9996 self.wait_for_reply(cookie)
9997 }
9998
9999 #[cfg(feature = "xf86vidmode")]
10000 fn xf86vidmode_query_version(
10001 &mut self,
10002 ) -> Result<Cookie<types::xf86vidmode::QueryVersionReply>> {
10003 let span = tracing::info_span!("xf86vidmode_query_version",);
10004 let _enter = span.enter();
10005 let request = types::xf86vidmode::QueryVersionRequest {};
10006 let cookie = self.send_reply_request(request);
10007 cookie
10008 }
10009 #[cfg(feature = "xf86vidmode")]
10010 fn xf86vidmode_query_version_immediate(
10011 &mut self,
10012 ) -> Result<types::xf86vidmode::QueryVersionReply> {
10013 let request = types::xf86vidmode::QueryVersionRequest {};
10014 let cookie = self.send_reply_request(request)?;
10015 self.wait_for_reply(cookie)
10016 }
10017 #[cfg(feature = "xf86vidmode")]
10018 fn xf86vidmode_get_mode_line(
10019 &mut self,
10020 screen: types::Card16,
10021 ) -> Result<Cookie<types::xf86vidmode::GetModeLineReply>> {
10022 let span = tracing::info_span!(
10023 "xf86vidmode_get_mode_line",
10024 screen = ?screen,
10025 );
10026 let _enter = span.enter();
10027 let request = types::xf86vidmode::GetModeLineRequest { screen };
10028 let cookie = self.send_reply_request(request);
10029 cookie
10030 }
10031 #[cfg(feature = "xf86vidmode")]
10032 fn xf86vidmode_get_mode_line_immediate(
10033 &mut self,
10034 screen: types::Card16,
10035 ) -> Result<types::xf86vidmode::GetModeLineReply> {
10036 let request = types::xf86vidmode::GetModeLineRequest { screen };
10037 let cookie = self.send_reply_request(request)?;
10038 self.wait_for_reply(cookie)
10039 }
10040 #[cfg(feature = "xf86vidmode")]
10041 fn xf86vidmode_mod_mode_line(
10042 &mut self,
10043 screen: types::Card32,
10044 hdisplay: types::Card16,
10045 hsyncstart: types::Card16,
10046 hsyncend: types::Card16,
10047 htotal: types::Card16,
10048 hskew: types::Card16,
10049 vdisplay: types::Card16,
10050 vsyncstart: types::Card16,
10051 vsyncend: types::Card16,
10052 vtotal: types::Card16,
10053 flags: impl Into<types::xf86vidmode::ModeFlag>,
10054 private: impl AsRef<[types::Card8]>,
10055 ) -> Result<Cookie<()>> {
10056 let span = tracing::info_span!(
10057 "xf86vidmode_mod_mode_line",
10058 screen = ?screen,
10059 hdisplay = ?hdisplay,
10060 hsyncstart = ?hsyncstart,
10061 hsyncend = ?hsyncend,
10062 htotal = ?htotal,
10063 hskew = ?hskew,
10064 vdisplay = ?vdisplay,
10065 vsyncstart = ?vsyncstart,
10066 vsyncend = ?vsyncend,
10067 vtotal = ?vtotal,
10068 );
10069 let _enter = span.enter();
10070 let request = types::xf86vidmode::ModModeLineRequest {
10071 screen,
10072 hdisplay,
10073 hsyncstart,
10074 hsyncend,
10075 htotal,
10076 hskew,
10077 vdisplay,
10078 vsyncstart,
10079 vsyncend,
10080 vtotal,
10081 flags: Into::<u32>::into(flags.into()) as _,
10082 private: Cow::Borrowed(private.as_ref()),
10083 };
10084 let cookie = self.send_void_request(request, true);
10085 cookie
10086 }
10087 #[cfg(feature = "xf86vidmode")]
10088 fn xf86vidmode_mod_mode_line_checked(
10089 &mut self,
10090 screen: types::Card32,
10091 hdisplay: types::Card16,
10092 hsyncstart: types::Card16,
10093 hsyncend: types::Card16,
10094 htotal: types::Card16,
10095 hskew: types::Card16,
10096 vdisplay: types::Card16,
10097 vsyncstart: types::Card16,
10098 vsyncend: types::Card16,
10099 vtotal: types::Card16,
10100 flags: impl Into<types::xf86vidmode::ModeFlag>,
10101 private: impl AsRef<[types::Card8]>,
10102 ) -> Result<()> {
10103 let request = types::xf86vidmode::ModModeLineRequest {
10104 screen,
10105 hdisplay,
10106 hsyncstart,
10107 hsyncend,
10108 htotal,
10109 hskew,
10110 vdisplay,
10111 vsyncstart,
10112 vsyncend,
10113 vtotal,
10114 flags: Into::<u32>::into(flags.into()) as _,
10115 private: Cow::Borrowed(private.as_ref()),
10116 };
10117 let cookie = self.send_void_request(request, false)?;
10118 self.wait_for_reply(cookie)
10119 }
10120 #[cfg(feature = "xf86vidmode")]
10121 fn xf86vidmode_switch_mode(
10122 &mut self,
10123 screen: types::Card16,
10124 zoom: types::Card16,
10125 ) -> Result<Cookie<()>> {
10126 let span = tracing::info_span!(
10127 "xf86vidmode_switch_mode",
10128 screen = ?screen,
10129 zoom = ?zoom,
10130 );
10131 let _enter = span.enter();
10132 let request = types::xf86vidmode::SwitchModeRequest { screen, zoom };
10133 let cookie = self.send_void_request(request, true);
10134 cookie
10135 }
10136 #[cfg(feature = "xf86vidmode")]
10137 fn xf86vidmode_switch_mode_checked(
10138 &mut self,
10139 screen: types::Card16,
10140 zoom: types::Card16,
10141 ) -> Result<()> {
10142 let request = types::xf86vidmode::SwitchModeRequest { screen, zoom };
10143 let cookie = self.send_void_request(request, false)?;
10144 self.wait_for_reply(cookie)
10145 }
10146 #[cfg(feature = "xf86vidmode")]
10147 fn xf86vidmode_get_monitor(
10148 &mut self,
10149 screen: types::Card16,
10150 ) -> Result<Cookie<types::xf86vidmode::GetMonitorReply>> {
10151 let span = tracing::info_span!(
10152 "xf86vidmode_get_monitor",
10153 screen = ?screen,
10154 );
10155 let _enter = span.enter();
10156 let request = types::xf86vidmode::GetMonitorRequest { screen };
10157 let cookie = self.send_reply_request(request);
10158 cookie
10159 }
10160 #[cfg(feature = "xf86vidmode")]
10161 fn xf86vidmode_get_monitor_immediate(
10162 &mut self,
10163 screen: types::Card16,
10164 ) -> Result<types::xf86vidmode::GetMonitorReply> {
10165 let request = types::xf86vidmode::GetMonitorRequest { screen };
10166 let cookie = self.send_reply_request(request)?;
10167 self.wait_for_reply(cookie)
10168 }
10169 #[cfg(feature = "xf86vidmode")]
10170 fn xf86vidmode_lock_mode_switch(
10171 &mut self,
10172 screen: types::Card16,
10173 lock: types::Card16,
10174 ) -> Result<Cookie<()>> {
10175 let span = tracing::info_span!(
10176 "xf86vidmode_lock_mode_switch",
10177 screen = ?screen,
10178 lock = ?lock,
10179 );
10180 let _enter = span.enter();
10181 let request = types::xf86vidmode::LockModeSwitchRequest { screen, lock };
10182 let cookie = self.send_void_request(request, true);
10183 cookie
10184 }
10185 #[cfg(feature = "xf86vidmode")]
10186 fn xf86vidmode_lock_mode_switch_checked(
10187 &mut self,
10188 screen: types::Card16,
10189 lock: types::Card16,
10190 ) -> Result<()> {
10191 let request = types::xf86vidmode::LockModeSwitchRequest { screen, lock };
10192 let cookie = self.send_void_request(request, false)?;
10193 self.wait_for_reply(cookie)
10194 }
10195 #[cfg(feature = "xf86vidmode")]
10196 fn xf86vidmode_get_all_mode_lines(
10197 &mut self,
10198 screen: types::Card16,
10199 ) -> Result<Cookie<types::xf86vidmode::GetAllModeLinesReply>> {
10200 let span = tracing::info_span!(
10201 "xf86vidmode_get_all_mode_lines",
10202 screen = ?screen,
10203 );
10204 let _enter = span.enter();
10205 let request = types::xf86vidmode::GetAllModeLinesRequest { screen };
10206 let cookie = self.send_reply_request(request);
10207 cookie
10208 }
10209 #[cfg(feature = "xf86vidmode")]
10210 fn xf86vidmode_get_all_mode_lines_immediate(
10211 &mut self,
10212 screen: types::Card16,
10213 ) -> Result<types::xf86vidmode::GetAllModeLinesReply> {
10214 let request = types::xf86vidmode::GetAllModeLinesRequest { screen };
10215 let cookie = self.send_reply_request(request)?;
10216 self.wait_for_reply(cookie)
10217 }
10218 #[cfg(feature = "xf86vidmode")]
10219 fn xf86vidmode_add_mode_line(
10220 &mut self,
10221 screen: types::Card32,
10222 dotclock: types::Dotclock,
10223 hdisplay: types::Card16,
10224 hsyncstart: types::Card16,
10225 hsyncend: types::Card16,
10226 htotal: types::Card16,
10227 hskew: types::Card16,
10228 vdisplay: types::Card16,
10229 vsyncstart: types::Card16,
10230 vsyncend: types::Card16,
10231 vtotal: types::Card16,
10232 flags: impl Into<types::xf86vidmode::ModeFlag>,
10233 after_dotclock: types::Dotclock,
10234 after_hdisplay: types::Card16,
10235 after_hsyncstart: types::Card16,
10236 after_hsyncend: types::Card16,
10237 after_htotal: types::Card16,
10238 after_hskew: types::Card16,
10239 after_vdisplay: types::Card16,
10240 after_vsyncstart: types::Card16,
10241 after_vsyncend: types::Card16,
10242 after_vtotal: types::Card16,
10243 after_flags: impl Into<types::xf86vidmode::ModeFlag>,
10244 private: impl AsRef<[types::Card8]>,
10245 ) -> Result<Cookie<()>> {
10246 let span = tracing::info_span!(
10247 "xf86vidmode_add_mode_line",
10248 screen = ?screen,
10249 dotclock = ?dotclock,
10250 hdisplay = ?hdisplay,
10251 hsyncstart = ?hsyncstart,
10252 hsyncend = ?hsyncend,
10253 htotal = ?htotal,
10254 hskew = ?hskew,
10255 vdisplay = ?vdisplay,
10256 vsyncstart = ?vsyncstart,
10257 vsyncend = ?vsyncend,
10258 vtotal = ?vtotal,
10259 after_dotclock = ?after_dotclock,
10260 after_hdisplay = ?after_hdisplay,
10261 after_hsyncstart = ?after_hsyncstart,
10262 after_hsyncend = ?after_hsyncend,
10263 after_htotal = ?after_htotal,
10264 after_hskew = ?after_hskew,
10265 after_vdisplay = ?after_vdisplay,
10266 after_vsyncstart = ?after_vsyncstart,
10267 after_vsyncend = ?after_vsyncend,
10268 after_vtotal = ?after_vtotal,
10269 );
10270 let _enter = span.enter();
10271 let request = types::xf86vidmode::AddModeLineRequest {
10272 screen,
10273 dotclock,
10274 hdisplay,
10275 hsyncstart,
10276 hsyncend,
10277 htotal,
10278 hskew,
10279 vdisplay,
10280 vsyncstart,
10281 vsyncend,
10282 vtotal,
10283 flags: Into::<u32>::into(flags.into()) as _,
10284 after_dotclock,
10285 after_hdisplay,
10286 after_hsyncstart,
10287 after_hsyncend,
10288 after_htotal,
10289 after_hskew,
10290 after_vdisplay,
10291 after_vsyncstart,
10292 after_vsyncend,
10293 after_vtotal,
10294 after_flags: Into::<u32>::into(after_flags.into()) as _,
10295 private: Cow::Borrowed(private.as_ref()),
10296 };
10297 let cookie = self.send_void_request(request, true);
10298 cookie
10299 }
10300 #[cfg(feature = "xf86vidmode")]
10301 fn xf86vidmode_add_mode_line_checked(
10302 &mut self,
10303 screen: types::Card32,
10304 dotclock: types::Dotclock,
10305 hdisplay: types::Card16,
10306 hsyncstart: types::Card16,
10307 hsyncend: types::Card16,
10308 htotal: types::Card16,
10309 hskew: types::Card16,
10310 vdisplay: types::Card16,
10311 vsyncstart: types::Card16,
10312 vsyncend: types::Card16,
10313 vtotal: types::Card16,
10314 flags: impl Into<types::xf86vidmode::ModeFlag>,
10315 after_dotclock: types::Dotclock,
10316 after_hdisplay: types::Card16,
10317 after_hsyncstart: types::Card16,
10318 after_hsyncend: types::Card16,
10319 after_htotal: types::Card16,
10320 after_hskew: types::Card16,
10321 after_vdisplay: types::Card16,
10322 after_vsyncstart: types::Card16,
10323 after_vsyncend: types::Card16,
10324 after_vtotal: types::Card16,
10325 after_flags: impl Into<types::xf86vidmode::ModeFlag>,
10326 private: impl AsRef<[types::Card8]>,
10327 ) -> Result<()> {
10328 let request = types::xf86vidmode::AddModeLineRequest {
10329 screen,
10330 dotclock,
10331 hdisplay,
10332 hsyncstart,
10333 hsyncend,
10334 htotal,
10335 hskew,
10336 vdisplay,
10337 vsyncstart,
10338 vsyncend,
10339 vtotal,
10340 flags: Into::<u32>::into(flags.into()) as _,
10341 after_dotclock,
10342 after_hdisplay,
10343 after_hsyncstart,
10344 after_hsyncend,
10345 after_htotal,
10346 after_hskew,
10347 after_vdisplay,
10348 after_vsyncstart,
10349 after_vsyncend,
10350 after_vtotal,
10351 after_flags: Into::<u32>::into(after_flags.into()) as _,
10352 private: Cow::Borrowed(private.as_ref()),
10353 };
10354 let cookie = self.send_void_request(request, false)?;
10355 self.wait_for_reply(cookie)
10356 }
10357 #[cfg(feature = "xf86vidmode")]
10358 fn xf86vidmode_delete_mode_line(
10359 &mut self,
10360 screen: types::Card32,
10361 dotclock: types::Dotclock,
10362 hdisplay: types::Card16,
10363 hsyncstart: types::Card16,
10364 hsyncend: types::Card16,
10365 htotal: types::Card16,
10366 hskew: types::Card16,
10367 vdisplay: types::Card16,
10368 vsyncstart: types::Card16,
10369 vsyncend: types::Card16,
10370 vtotal: types::Card16,
10371 flags: impl Into<types::xf86vidmode::ModeFlag>,
10372 private: impl AsRef<[types::Card8]>,
10373 ) -> Result<Cookie<()>> {
10374 let span = tracing::info_span!(
10375 "xf86vidmode_delete_mode_line",
10376 screen = ?screen,
10377 dotclock = ?dotclock,
10378 hdisplay = ?hdisplay,
10379 hsyncstart = ?hsyncstart,
10380 hsyncend = ?hsyncend,
10381 htotal = ?htotal,
10382 hskew = ?hskew,
10383 vdisplay = ?vdisplay,
10384 vsyncstart = ?vsyncstart,
10385 vsyncend = ?vsyncend,
10386 vtotal = ?vtotal,
10387 );
10388 let _enter = span.enter();
10389 let request = types::xf86vidmode::DeleteModeLineRequest {
10390 screen,
10391 dotclock,
10392 hdisplay,
10393 hsyncstart,
10394 hsyncend,
10395 htotal,
10396 hskew,
10397 vdisplay,
10398 vsyncstart,
10399 vsyncend,
10400 vtotal,
10401 flags: Into::<u32>::into(flags.into()) as _,
10402 private: Cow::Borrowed(private.as_ref()),
10403 };
10404 let cookie = self.send_void_request(request, true);
10405 cookie
10406 }
10407 #[cfg(feature = "xf86vidmode")]
10408 fn xf86vidmode_delete_mode_line_checked(
10409 &mut self,
10410 screen: types::Card32,
10411 dotclock: types::Dotclock,
10412 hdisplay: types::Card16,
10413 hsyncstart: types::Card16,
10414 hsyncend: types::Card16,
10415 htotal: types::Card16,
10416 hskew: types::Card16,
10417 vdisplay: types::Card16,
10418 vsyncstart: types::Card16,
10419 vsyncend: types::Card16,
10420 vtotal: types::Card16,
10421 flags: impl Into<types::xf86vidmode::ModeFlag>,
10422 private: impl AsRef<[types::Card8]>,
10423 ) -> Result<()> {
10424 let request = types::xf86vidmode::DeleteModeLineRequest {
10425 screen,
10426 dotclock,
10427 hdisplay,
10428 hsyncstart,
10429 hsyncend,
10430 htotal,
10431 hskew,
10432 vdisplay,
10433 vsyncstart,
10434 vsyncend,
10435 vtotal,
10436 flags: Into::<u32>::into(flags.into()) as _,
10437 private: Cow::Borrowed(private.as_ref()),
10438 };
10439 let cookie = self.send_void_request(request, false)?;
10440 self.wait_for_reply(cookie)
10441 }
10442 #[cfg(feature = "xf86vidmode")]
10443 fn xf86vidmode_validate_mode_line(
10444 &mut self,
10445 screen: types::Card32,
10446 dotclock: types::Dotclock,
10447 hdisplay: types::Card16,
10448 hsyncstart: types::Card16,
10449 hsyncend: types::Card16,
10450 htotal: types::Card16,
10451 hskew: types::Card16,
10452 vdisplay: types::Card16,
10453 vsyncstart: types::Card16,
10454 vsyncend: types::Card16,
10455 vtotal: types::Card16,
10456 flags: impl Into<types::xf86vidmode::ModeFlag>,
10457 private: impl AsRef<[types::Card8]>,
10458 ) -> Result<Cookie<types::xf86vidmode::ValidateModeLineReply>> {
10459 let span = tracing::info_span!(
10460 "xf86vidmode_validate_mode_line",
10461 screen = ?screen,
10462 dotclock = ?dotclock,
10463 hdisplay = ?hdisplay,
10464 hsyncstart = ?hsyncstart,
10465 hsyncend = ?hsyncend,
10466 htotal = ?htotal,
10467 hskew = ?hskew,
10468 vdisplay = ?vdisplay,
10469 vsyncstart = ?vsyncstart,
10470 vsyncend = ?vsyncend,
10471 vtotal = ?vtotal,
10472 );
10473 let _enter = span.enter();
10474 let request = types::xf86vidmode::ValidateModeLineRequest {
10475 screen,
10476 dotclock,
10477 hdisplay,
10478 hsyncstart,
10479 hsyncend,
10480 htotal,
10481 hskew,
10482 vdisplay,
10483 vsyncstart,
10484 vsyncend,
10485 vtotal,
10486 flags: Into::<u32>::into(flags.into()) as _,
10487 private: Cow::Borrowed(private.as_ref()),
10488 };
10489 let cookie = self.send_reply_request(request);
10490 cookie
10491 }
10492 #[cfg(feature = "xf86vidmode")]
10493 fn xf86vidmode_validate_mode_line_immediate(
10494 &mut self,
10495 screen: types::Card32,
10496 dotclock: types::Dotclock,
10497 hdisplay: types::Card16,
10498 hsyncstart: types::Card16,
10499 hsyncend: types::Card16,
10500 htotal: types::Card16,
10501 hskew: types::Card16,
10502 vdisplay: types::Card16,
10503 vsyncstart: types::Card16,
10504 vsyncend: types::Card16,
10505 vtotal: types::Card16,
10506 flags: impl Into<types::xf86vidmode::ModeFlag>,
10507 private: impl AsRef<[types::Card8]>,
10508 ) -> Result<types::xf86vidmode::ValidateModeLineReply> {
10509 let request = types::xf86vidmode::ValidateModeLineRequest {
10510 screen,
10511 dotclock,
10512 hdisplay,
10513 hsyncstart,
10514 hsyncend,
10515 htotal,
10516 hskew,
10517 vdisplay,
10518 vsyncstart,
10519 vsyncend,
10520 vtotal,
10521 flags: Into::<u32>::into(flags.into()) as _,
10522 private: Cow::Borrowed(private.as_ref()),
10523 };
10524 let cookie = self.send_reply_request(request)?;
10525 self.wait_for_reply(cookie)
10526 }
10527 #[cfg(feature = "xf86vidmode")]
10528 fn xf86vidmode_switch_to_mode(
10529 &mut self,
10530 screen: types::Card32,
10531 dotclock: types::Dotclock,
10532 hdisplay: types::Card16,
10533 hsyncstart: types::Card16,
10534 hsyncend: types::Card16,
10535 htotal: types::Card16,
10536 hskew: types::Card16,
10537 vdisplay: types::Card16,
10538 vsyncstart: types::Card16,
10539 vsyncend: types::Card16,
10540 vtotal: types::Card16,
10541 flags: impl Into<types::xf86vidmode::ModeFlag>,
10542 private: impl AsRef<[types::Card8]>,
10543 ) -> Result<Cookie<()>> {
10544 let span = tracing::info_span!(
10545 "xf86vidmode_switch_to_mode",
10546 screen = ?screen,
10547 dotclock = ?dotclock,
10548 hdisplay = ?hdisplay,
10549 hsyncstart = ?hsyncstart,
10550 hsyncend = ?hsyncend,
10551 htotal = ?htotal,
10552 hskew = ?hskew,
10553 vdisplay = ?vdisplay,
10554 vsyncstart = ?vsyncstart,
10555 vsyncend = ?vsyncend,
10556 vtotal = ?vtotal,
10557 );
10558 let _enter = span.enter();
10559 let request = types::xf86vidmode::SwitchToModeRequest {
10560 screen,
10561 dotclock,
10562 hdisplay,
10563 hsyncstart,
10564 hsyncend,
10565 htotal,
10566 hskew,
10567 vdisplay,
10568 vsyncstart,
10569 vsyncend,
10570 vtotal,
10571 flags: Into::<u32>::into(flags.into()) as _,
10572 private: Cow::Borrowed(private.as_ref()),
10573 };
10574 let cookie = self.send_void_request(request, true);
10575 cookie
10576 }
10577 #[cfg(feature = "xf86vidmode")]
10578 fn xf86vidmode_switch_to_mode_checked(
10579 &mut self,
10580 screen: types::Card32,
10581 dotclock: types::Dotclock,
10582 hdisplay: types::Card16,
10583 hsyncstart: types::Card16,
10584 hsyncend: types::Card16,
10585 htotal: types::Card16,
10586 hskew: types::Card16,
10587 vdisplay: types::Card16,
10588 vsyncstart: types::Card16,
10589 vsyncend: types::Card16,
10590 vtotal: types::Card16,
10591 flags: impl Into<types::xf86vidmode::ModeFlag>,
10592 private: impl AsRef<[types::Card8]>,
10593 ) -> Result<()> {
10594 let request = types::xf86vidmode::SwitchToModeRequest {
10595 screen,
10596 dotclock,
10597 hdisplay,
10598 hsyncstart,
10599 hsyncend,
10600 htotal,
10601 hskew,
10602 vdisplay,
10603 vsyncstart,
10604 vsyncend,
10605 vtotal,
10606 flags: Into::<u32>::into(flags.into()) as _,
10607 private: Cow::Borrowed(private.as_ref()),
10608 };
10609 let cookie = self.send_void_request(request, false)?;
10610 self.wait_for_reply(cookie)
10611 }
10612 #[cfg(feature = "xf86vidmode")]
10613 fn xf86vidmode_get_view_port(
10614 &mut self,
10615 screen: types::Card16,
10616 ) -> Result<Cookie<types::xf86vidmode::GetViewPortReply>> {
10617 let span = tracing::info_span!(
10618 "xf86vidmode_get_view_port",
10619 screen = ?screen,
10620 );
10621 let _enter = span.enter();
10622 let request = types::xf86vidmode::GetViewPortRequest { screen };
10623 let cookie = self.send_reply_request(request);
10624 cookie
10625 }
10626 #[cfg(feature = "xf86vidmode")]
10627 fn xf86vidmode_get_view_port_immediate(
10628 &mut self,
10629 screen: types::Card16,
10630 ) -> Result<types::xf86vidmode::GetViewPortReply> {
10631 let request = types::xf86vidmode::GetViewPortRequest { screen };
10632 let cookie = self.send_reply_request(request)?;
10633 self.wait_for_reply(cookie)
10634 }
10635 #[cfg(feature = "xf86vidmode")]
10636 fn xf86vidmode_set_view_port(
10637 &mut self,
10638 screen: types::Card16,
10639 x: types::Card32,
10640 y: types::Card32,
10641 ) -> Result<Cookie<()>> {
10642 let span = tracing::info_span!(
10643 "xf86vidmode_set_view_port",
10644 screen = ?screen,
10645 x = ?x,
10646 y = ?y,
10647 );
10648 let _enter = span.enter();
10649 let request = types::xf86vidmode::SetViewPortRequest { screen, x, y };
10650 let cookie = self.send_void_request(request, true);
10651 cookie
10652 }
10653 #[cfg(feature = "xf86vidmode")]
10654 fn xf86vidmode_set_view_port_checked(
10655 &mut self,
10656 screen: types::Card16,
10657 x: types::Card32,
10658 y: types::Card32,
10659 ) -> Result<()> {
10660 let request = types::xf86vidmode::SetViewPortRequest { screen, x, y };
10661 let cookie = self.send_void_request(request, false)?;
10662 self.wait_for_reply(cookie)
10663 }
10664 #[cfg(feature = "xf86vidmode")]
10665 fn xf86vidmode_get_dot_clocks(
10666 &mut self,
10667 screen: types::Card16,
10668 ) -> Result<Cookie<types::xf86vidmode::GetDotClocksReply>> {
10669 let span = tracing::info_span!(
10670 "xf86vidmode_get_dot_clocks",
10671 screen = ?screen,
10672 );
10673 let _enter = span.enter();
10674 let request = types::xf86vidmode::GetDotClocksRequest { screen };
10675 let cookie = self.send_reply_request(request);
10676 cookie
10677 }
10678 #[cfg(feature = "xf86vidmode")]
10679 fn xf86vidmode_get_dot_clocks_immediate(
10680 &mut self,
10681 screen: types::Card16,
10682 ) -> Result<types::xf86vidmode::GetDotClocksReply> {
10683 let request = types::xf86vidmode::GetDotClocksRequest { screen };
10684 let cookie = self.send_reply_request(request)?;
10685 self.wait_for_reply(cookie)
10686 }
10687 #[cfg(feature = "xf86vidmode")]
10688 fn xf86vidmode_set_client_version(
10689 &mut self,
10690 major: types::Card16,
10691 minor: types::Card16,
10692 ) -> Result<Cookie<()>> {
10693 let span = tracing::info_span!(
10694 "xf86vidmode_set_client_version",
10695 major = ?major,
10696 minor = ?minor,
10697 );
10698 let _enter = span.enter();
10699 let request = types::xf86vidmode::SetClientVersionRequest { major, minor };
10700 let cookie = self.send_void_request(request, true);
10701 cookie
10702 }
10703 #[cfg(feature = "xf86vidmode")]
10704 fn xf86vidmode_set_client_version_checked(
10705 &mut self,
10706 major: types::Card16,
10707 minor: types::Card16,
10708 ) -> Result<()> {
10709 let request = types::xf86vidmode::SetClientVersionRequest { major, minor };
10710 let cookie = self.send_void_request(request, false)?;
10711 self.wait_for_reply(cookie)
10712 }
10713 #[cfg(feature = "xf86vidmode")]
10714 fn xf86vidmode_set_gamma(
10715 &mut self,
10716 screen: types::Card16,
10717 red: types::Card32,
10718 green: types::Card32,
10719 blue: types::Card32,
10720 ) -> Result<Cookie<()>> {
10721 let span = tracing::info_span!(
10722 "xf86vidmode_set_gamma",
10723 screen = ?screen,
10724 red = ?red,
10725 green = ?green,
10726 blue = ?blue,
10727 );
10728 let _enter = span.enter();
10729 let request = types::xf86vidmode::SetGammaRequest {
10730 screen,
10731 red,
10732 green,
10733 blue,
10734 };
10735 let cookie = self.send_void_request(request, true);
10736 cookie
10737 }
10738 #[cfg(feature = "xf86vidmode")]
10739 fn xf86vidmode_set_gamma_checked(
10740 &mut self,
10741 screen: types::Card16,
10742 red: types::Card32,
10743 green: types::Card32,
10744 blue: types::Card32,
10745 ) -> Result<()> {
10746 let request = types::xf86vidmode::SetGammaRequest {
10747 screen,
10748 red,
10749 green,
10750 blue,
10751 };
10752 let cookie = self.send_void_request(request, false)?;
10753 self.wait_for_reply(cookie)
10754 }
10755 #[cfg(feature = "xf86vidmode")]
10756 fn xf86vidmode_get_gamma(
10757 &mut self,
10758 screen: types::Card16,
10759 ) -> Result<Cookie<types::xf86vidmode::GetGammaReply>> {
10760 let span = tracing::info_span!(
10761 "xf86vidmode_get_gamma",
10762 screen = ?screen,
10763 );
10764 let _enter = span.enter();
10765 let request = types::xf86vidmode::GetGammaRequest { screen };
10766 let cookie = self.send_reply_request(request);
10767 cookie
10768 }
10769 #[cfg(feature = "xf86vidmode")]
10770 fn xf86vidmode_get_gamma_immediate(
10771 &mut self,
10772 screen: types::Card16,
10773 ) -> Result<types::xf86vidmode::GetGammaReply> {
10774 let request = types::xf86vidmode::GetGammaRequest { screen };
10775 let cookie = self.send_reply_request(request)?;
10776 self.wait_for_reply(cookie)
10777 }
10778 #[cfg(feature = "xf86vidmode")]
10779 fn xf86vidmode_get_gamma_ramp(
10780 &mut self,
10781 screen: types::Card16,
10782 size: types::Card16,
10783 ) -> Result<Cookie<types::xf86vidmode::GetGammaRampReply>> {
10784 let span = tracing::info_span!(
10785 "xf86vidmode_get_gamma_ramp",
10786 screen = ?screen,
10787 size = ?size,
10788 );
10789 let _enter = span.enter();
10790 let request = types::xf86vidmode::GetGammaRampRequest { screen, size };
10791 let cookie = self.send_reply_request(request);
10792 cookie
10793 }
10794 #[cfg(feature = "xf86vidmode")]
10795 fn xf86vidmode_get_gamma_ramp_immediate(
10796 &mut self,
10797 screen: types::Card16,
10798 size: types::Card16,
10799 ) -> Result<types::xf86vidmode::GetGammaRampReply> {
10800 let request = types::xf86vidmode::GetGammaRampRequest { screen, size };
10801 let cookie = self.send_reply_request(request)?;
10802 self.wait_for_reply(cookie)
10803 }
10804 #[cfg(feature = "xf86vidmode")]
10805 fn xf86vidmode_set_gamma_ramp(
10806 &mut self,
10807 screen: types::Card16,
10808 size: types::Card16,
10809 red: impl AsRef<[types::Card16]>,
10810 green: impl AsRef<[types::Card16]>,
10811 blue: impl AsRef<[types::Card16]>,
10812 ) -> Result<Cookie<()>> {
10813 let span = tracing::info_span!(
10814 "xf86vidmode_set_gamma_ramp",
10815 screen = ?screen,
10816 size = ?size,
10817 );
10818 let _enter = span.enter();
10819 let request = types::xf86vidmode::SetGammaRampRequest {
10820 screen,
10821 size,
10822 red: Cow::Borrowed(red.as_ref()),
10823 green: Cow::Borrowed(green.as_ref()),
10824 blue: Cow::Borrowed(blue.as_ref()),
10825 };
10826 let cookie = self.send_void_request(request, true);
10827 cookie
10828 }
10829 #[cfg(feature = "xf86vidmode")]
10830 fn xf86vidmode_set_gamma_ramp_checked(
10831 &mut self,
10832 screen: types::Card16,
10833 size: types::Card16,
10834 red: impl AsRef<[types::Card16]>,
10835 green: impl AsRef<[types::Card16]>,
10836 blue: impl AsRef<[types::Card16]>,
10837 ) -> Result<()> {
10838 let request = types::xf86vidmode::SetGammaRampRequest {
10839 screen,
10840 size,
10841 red: Cow::Borrowed(red.as_ref()),
10842 green: Cow::Borrowed(green.as_ref()),
10843 blue: Cow::Borrowed(blue.as_ref()),
10844 };
10845 let cookie = self.send_void_request(request, false)?;
10846 self.wait_for_reply(cookie)
10847 }
10848 #[cfg(feature = "xf86vidmode")]
10849 fn xf86vidmode_get_gamma_ramp_size(
10850 &mut self,
10851 screen: types::Card16,
10852 ) -> Result<Cookie<types::xf86vidmode::GetGammaRampSizeReply>> {
10853 let span = tracing::info_span!(
10854 "xf86vidmode_get_gamma_ramp_size",
10855 screen = ?screen,
10856 );
10857 let _enter = span.enter();
10858 let request = types::xf86vidmode::GetGammaRampSizeRequest { screen };
10859 let cookie = self.send_reply_request(request);
10860 cookie
10861 }
10862 #[cfg(feature = "xf86vidmode")]
10863 fn xf86vidmode_get_gamma_ramp_size_immediate(
10864 &mut self,
10865 screen: types::Card16,
10866 ) -> Result<types::xf86vidmode::GetGammaRampSizeReply> {
10867 let request = types::xf86vidmode::GetGammaRampSizeRequest { screen };
10868 let cookie = self.send_reply_request(request)?;
10869 self.wait_for_reply(cookie)
10870 }
10871 #[cfg(feature = "xf86vidmode")]
10872 fn xf86vidmode_get_permissions(
10873 &mut self,
10874 screen: types::Card16,
10875 ) -> Result<Cookie<types::xf86vidmode::GetPermissionsReply>> {
10876 let span = tracing::info_span!(
10877 "xf86vidmode_get_permissions",
10878 screen = ?screen,
10879 );
10880 let _enter = span.enter();
10881 let request = types::xf86vidmode::GetPermissionsRequest { screen };
10882 let cookie = self.send_reply_request(request);
10883 cookie
10884 }
10885 #[cfg(feature = "xf86vidmode")]
10886 fn xf86vidmode_get_permissions_immediate(
10887 &mut self,
10888 screen: types::Card16,
10889 ) -> Result<types::xf86vidmode::GetPermissionsReply> {
10890 let request = types::xf86vidmode::GetPermissionsRequest { screen };
10891 let cookie = self.send_reply_request(request)?;
10892 self.wait_for_reply(cookie)
10893 }
10894
10895 #[cfg(feature = "xfixes")]
10896 fn xfixes_query_version(
10897 &mut self,
10898 client_major_version: types::Card32,
10899 client_minor_version: types::Card32,
10900 ) -> Result<Cookie<types::xfixes::QueryVersionReply>> {
10901 let span = tracing::info_span!(
10902 "xfixes_query_version",
10903 client_major_version = ?client_major_version,
10904 client_minor_version = ?client_minor_version,
10905 );
10906 let _enter = span.enter();
10907 let request = types::xfixes::QueryVersionRequest {
10908 client_major_version,
10909 client_minor_version,
10910 };
10911 let cookie = self.send_reply_request(request);
10912 cookie
10913 }
10914 #[cfg(feature = "xfixes")]
10915 fn xfixes_query_version_immediate(
10916 &mut self,
10917 client_major_version: types::Card32,
10918 client_minor_version: types::Card32,
10919 ) -> Result<types::xfixes::QueryVersionReply> {
10920 let request = types::xfixes::QueryVersionRequest {
10921 client_major_version,
10922 client_minor_version,
10923 };
10924 let cookie = self.send_reply_request(request)?;
10925 self.wait_for_reply(cookie)
10926 }
10927 #[cfg(feature = "xfixes")]
10928 fn xfixes_change_save_set(
10929 &mut self,
10930 mode: types::SaveSetMode,
10931 target: types::SaveSetTarget,
10932 map: types::SaveSetMapping,
10933 window: types::xproto::Window,
10934 ) -> Result<Cookie<()>> {
10935 let span = tracing::info_span!(
10936 "xfixes_change_save_set",
10937 mode = ?mode,
10938 target = ?target,
10939 map = ?map,
10940 window = ?window,
10941 );
10942 let _enter = span.enter();
10943 let request = types::xfixes::ChangeSaveSetRequest {
10944 mode,
10945 target,
10946 map,
10947 window,
10948 };
10949 let cookie = self.send_void_request(request, true);
10950 cookie
10951 }
10952 #[cfg(feature = "xfixes")]
10953 fn xfixes_change_save_set_checked(
10954 &mut self,
10955 mode: types::SaveSetMode,
10956 target: types::SaveSetTarget,
10957 map: types::SaveSetMapping,
10958 window: types::xproto::Window,
10959 ) -> Result<()> {
10960 let request = types::xfixes::ChangeSaveSetRequest {
10961 mode,
10962 target,
10963 map,
10964 window,
10965 };
10966 let cookie = self.send_void_request(request, false)?;
10967 self.wait_for_reply(cookie)
10968 }
10969 #[cfg(feature = "xfixes")]
10970 fn xfixes_select_selection_input(
10971 &mut self,
10972 window: types::xproto::Window,
10973 selection: types::Atom,
10974 event_mask: impl Into<types::SelectionEventMask>,
10975 ) -> Result<Cookie<()>> {
10976 let span = tracing::info_span!(
10977 "xfixes_select_selection_input",
10978 window = ?window,
10979 selection = ?selection,
10980 );
10981 let _enter = span.enter();
10982 let request = types::xfixes::SelectSelectionInputRequest {
10983 window,
10984 selection,
10985 event_mask: Into::<u32>::into(event_mask.into()) as _,
10986 };
10987 let cookie = self.send_void_request(request, true);
10988 cookie
10989 }
10990 #[cfg(feature = "xfixes")]
10991 fn xfixes_select_selection_input_checked(
10992 &mut self,
10993 window: types::xproto::Window,
10994 selection: types::Atom,
10995 event_mask: impl Into<types::SelectionEventMask>,
10996 ) -> Result<()> {
10997 let request = types::xfixes::SelectSelectionInputRequest {
10998 window,
10999 selection,
11000 event_mask: Into::<u32>::into(event_mask.into()) as _,
11001 };
11002 let cookie = self.send_void_request(request, false)?;
11003 self.wait_for_reply(cookie)
11004 }
11005 #[cfg(feature = "xfixes")]
11006 fn xfixes_select_cursor_input(
11007 &mut self,
11008 window: types::xproto::Window,
11009 event_mask: impl Into<types::CursorNotifyMask>,
11010 ) -> Result<Cookie<()>> {
11011 let span = tracing::info_span!(
11012 "xfixes_select_cursor_input",
11013 window = ?window,
11014 );
11015 let _enter = span.enter();
11016 let request = types::xfixes::SelectCursorInputRequest {
11017 window,
11018 event_mask: Into::<u32>::into(event_mask.into()) as _,
11019 };
11020 let cookie = self.send_void_request(request, true);
11021 cookie
11022 }
11023 #[cfg(feature = "xfixes")]
11024 fn xfixes_select_cursor_input_checked(
11025 &mut self,
11026 window: types::xproto::Window,
11027 event_mask: impl Into<types::CursorNotifyMask>,
11028 ) -> Result<()> {
11029 let request = types::xfixes::SelectCursorInputRequest {
11030 window,
11031 event_mask: Into::<u32>::into(event_mask.into()) as _,
11032 };
11033 let cookie = self.send_void_request(request, false)?;
11034 self.wait_for_reply(cookie)
11035 }
11036 #[cfg(feature = "xfixes")]
11037 fn xfixes_get_cursor_image(&mut self) -> Result<Cookie<types::xfixes::GetCursorImageReply>> {
11038 let span = tracing::info_span!("xfixes_get_cursor_image",);
11039 let _enter = span.enter();
11040 let request = types::xfixes::GetCursorImageRequest {};
11041 let cookie = self.send_reply_request(request);
11042 cookie
11043 }
11044 #[cfg(feature = "xfixes")]
11045 fn xfixes_get_cursor_image_immediate(&mut self) -> Result<types::xfixes::GetCursorImageReply> {
11046 let request = types::xfixes::GetCursorImageRequest {};
11047 let cookie = self.send_reply_request(request)?;
11048 self.wait_for_reply(cookie)
11049 }
11050 #[cfg(feature = "xfixes")]
11051 fn xfixes_create_region(
11052 &mut self,
11053 region: types::Region,
11054 rectangles: impl AsRef<[types::Rectangle]>,
11055 ) -> Result<Cookie<()>> {
11056 let span = tracing::info_span!(
11057 "xfixes_create_region",
11058 region = ?region,
11059 );
11060 let _enter = span.enter();
11061 let request = types::xfixes::CreateRegionRequest {
11062 region,
11063 rectangles: Cow::Borrowed(rectangles.as_ref()),
11064 };
11065 let cookie = self.send_void_request(request, true);
11066 cookie
11067 }
11068 #[cfg(feature = "xfixes")]
11069 fn xfixes_create_region_checked(
11070 &mut self,
11071 region: types::Region,
11072 rectangles: impl AsRef<[types::Rectangle]>,
11073 ) -> Result<()> {
11074 let request = types::xfixes::CreateRegionRequest {
11075 region,
11076 rectangles: Cow::Borrowed(rectangles.as_ref()),
11077 };
11078 let cookie = self.send_void_request(request, false)?;
11079 self.wait_for_reply(cookie)
11080 }
11081 #[cfg(feature = "xfixes")]
11082 fn xfixes_create_region_from_bitmap(
11083 &mut self,
11084 region: types::Region,
11085 bitmap: types::xproto::Pixmap,
11086 ) -> Result<Cookie<()>> {
11087 let span = tracing::info_span!(
11088 "xfixes_create_region_from_bitmap",
11089 region = ?region,
11090 bitmap = ?bitmap,
11091 );
11092 let _enter = span.enter();
11093 let request = types::xfixes::CreateRegionFromBitmapRequest { region, bitmap };
11094 let cookie = self.send_void_request(request, true);
11095 cookie
11096 }
11097 #[cfg(feature = "xfixes")]
11098 fn xfixes_create_region_from_bitmap_checked(
11099 &mut self,
11100 region: types::Region,
11101 bitmap: types::xproto::Pixmap,
11102 ) -> Result<()> {
11103 let request = types::xfixes::CreateRegionFromBitmapRequest { region, bitmap };
11104 let cookie = self.send_void_request(request, false)?;
11105 self.wait_for_reply(cookie)
11106 }
11107 #[cfg(feature = "xfixes")]
11108 fn xfixes_create_region_from_window(
11109 &mut self,
11110 region: types::Region,
11111 window: types::xproto::Window,
11112 kind: types::SK,
11113 ) -> Result<Cookie<()>> {
11114 let span = tracing::info_span!(
11115 "xfixes_create_region_from_window",
11116 region = ?region,
11117 window = ?window,
11118 kind = ?kind,
11119 );
11120 let _enter = span.enter();
11121 let request = types::xfixes::CreateRegionFromWindowRequest {
11122 region,
11123 window,
11124 kind,
11125 };
11126 let cookie = self.send_void_request(request, true);
11127 cookie
11128 }
11129 #[cfg(feature = "xfixes")]
11130 fn xfixes_create_region_from_window_checked(
11131 &mut self,
11132 region: types::Region,
11133 window: types::xproto::Window,
11134 kind: types::SK,
11135 ) -> Result<()> {
11136 let request = types::xfixes::CreateRegionFromWindowRequest {
11137 region,
11138 window,
11139 kind,
11140 };
11141 let cookie = self.send_void_request(request, false)?;
11142 self.wait_for_reply(cookie)
11143 }
11144 #[cfg(feature = "xfixes")]
11145 fn xfixes_create_region_from_gc(
11146 &mut self,
11147 region: types::Region,
11148 gc: types::Gcontext,
11149 ) -> Result<Cookie<()>> {
11150 let span = tracing::info_span!(
11151 "xfixes_create_region_from_gc",
11152 region = ?region,
11153 gc = ?gc,
11154 );
11155 let _enter = span.enter();
11156 let request = types::xfixes::CreateRegionFromGCRequest { region, gc };
11157 let cookie = self.send_void_request(request, true);
11158 cookie
11159 }
11160 #[cfg(feature = "xfixes")]
11161 fn xfixes_create_region_from_gc_checked(
11162 &mut self,
11163 region: types::Region,
11164 gc: types::Gcontext,
11165 ) -> Result<()> {
11166 let request = types::xfixes::CreateRegionFromGCRequest { region, gc };
11167 let cookie = self.send_void_request(request, false)?;
11168 self.wait_for_reply(cookie)
11169 }
11170 #[cfg(feature = "xfixes")]
11171 fn xfixes_create_region_from_picture(
11172 &mut self,
11173 region: types::Region,
11174 picture: types::Picture,
11175 ) -> Result<Cookie<()>> {
11176 let span = tracing::info_span!(
11177 "xfixes_create_region_from_picture",
11178 region = ?region,
11179 picture = ?picture,
11180 );
11181 let _enter = span.enter();
11182 let request = types::xfixes::CreateRegionFromPictureRequest { region, picture };
11183 let cookie = self.send_void_request(request, true);
11184 cookie
11185 }
11186 #[cfg(feature = "xfixes")]
11187 fn xfixes_create_region_from_picture_checked(
11188 &mut self,
11189 region: types::Region,
11190 picture: types::Picture,
11191 ) -> Result<()> {
11192 let request = types::xfixes::CreateRegionFromPictureRequest { region, picture };
11193 let cookie = self.send_void_request(request, false)?;
11194 self.wait_for_reply(cookie)
11195 }
11196 #[cfg(feature = "xfixes")]
11197 fn xfixes_destroy_region(&mut self, region: types::Region) -> Result<Cookie<()>> {
11198 let span = tracing::info_span!(
11199 "xfixes_destroy_region",
11200 region = ?region,
11201 );
11202 let _enter = span.enter();
11203 let request = types::xfixes::DestroyRegionRequest { region };
11204 let cookie = self.send_void_request(request, true);
11205 cookie
11206 }
11207 #[cfg(feature = "xfixes")]
11208 fn xfixes_destroy_region_checked(&mut self, region: types::Region) -> Result<()> {
11209 let request = types::xfixes::DestroyRegionRequest { region };
11210 let cookie = self.send_void_request(request, false)?;
11211 self.wait_for_reply(cookie)
11212 }
11213 #[cfg(feature = "xfixes")]
11214 fn xfixes_set_region(
11215 &mut self,
11216 region: types::Region,
11217 rectangles: impl AsRef<[types::Rectangle]>,
11218 ) -> Result<Cookie<()>> {
11219 let span = tracing::info_span!(
11220 "xfixes_set_region",
11221 region = ?region,
11222 );
11223 let _enter = span.enter();
11224 let request = types::xfixes::SetRegionRequest {
11225 region,
11226 rectangles: Cow::Borrowed(rectangles.as_ref()),
11227 };
11228 let cookie = self.send_void_request(request, true);
11229 cookie
11230 }
11231 #[cfg(feature = "xfixes")]
11232 fn xfixes_set_region_checked(
11233 &mut self,
11234 region: types::Region,
11235 rectangles: impl AsRef<[types::Rectangle]>,
11236 ) -> Result<()> {
11237 let request = types::xfixes::SetRegionRequest {
11238 region,
11239 rectangles: Cow::Borrowed(rectangles.as_ref()),
11240 };
11241 let cookie = self.send_void_request(request, false)?;
11242 self.wait_for_reply(cookie)
11243 }
11244 #[cfg(feature = "xfixes")]
11245 fn xfixes_copy_region(
11246 &mut self,
11247 source: types::Region,
11248 destination: types::Region,
11249 ) -> Result<Cookie<()>> {
11250 let span = tracing::info_span!(
11251 "xfixes_copy_region",
11252 source = ?source,
11253 destination = ?destination,
11254 );
11255 let _enter = span.enter();
11256 let request = types::xfixes::CopyRegionRequest {
11257 source,
11258 destination,
11259 };
11260 let cookie = self.send_void_request(request, true);
11261 cookie
11262 }
11263 #[cfg(feature = "xfixes")]
11264 fn xfixes_copy_region_checked(
11265 &mut self,
11266 source: types::Region,
11267 destination: types::Region,
11268 ) -> Result<()> {
11269 let request = types::xfixes::CopyRegionRequest {
11270 source,
11271 destination,
11272 };
11273 let cookie = self.send_void_request(request, false)?;
11274 self.wait_for_reply(cookie)
11275 }
11276 #[cfg(feature = "xfixes")]
11277 fn xfixes_union_region(
11278 &mut self,
11279 source1: types::Region,
11280 source2: types::Region,
11281 destination: types::Region,
11282 ) -> Result<Cookie<()>> {
11283 let span = tracing::info_span!(
11284 "xfixes_union_region",
11285 source1 = ?source1,
11286 source2 = ?source2,
11287 destination = ?destination,
11288 );
11289 let _enter = span.enter();
11290 let request = types::xfixes::UnionRegionRequest {
11291 source1,
11292 source2,
11293 destination,
11294 };
11295 let cookie = self.send_void_request(request, true);
11296 cookie
11297 }
11298 #[cfg(feature = "xfixes")]
11299 fn xfixes_union_region_checked(
11300 &mut self,
11301 source1: types::Region,
11302 source2: types::Region,
11303 destination: types::Region,
11304 ) -> Result<()> {
11305 let request = types::xfixes::UnionRegionRequest {
11306 source1,
11307 source2,
11308 destination,
11309 };
11310 let cookie = self.send_void_request(request, false)?;
11311 self.wait_for_reply(cookie)
11312 }
11313 #[cfg(feature = "xfixes")]
11314 fn xfixes_intersect_region(
11315 &mut self,
11316 source1: types::Region,
11317 source2: types::Region,
11318 destination: types::Region,
11319 ) -> Result<Cookie<()>> {
11320 let span = tracing::info_span!(
11321 "xfixes_intersect_region",
11322 source1 = ?source1,
11323 source2 = ?source2,
11324 destination = ?destination,
11325 );
11326 let _enter = span.enter();
11327 let request = types::xfixes::IntersectRegionRequest {
11328 source1,
11329 source2,
11330 destination,
11331 };
11332 let cookie = self.send_void_request(request, true);
11333 cookie
11334 }
11335 #[cfg(feature = "xfixes")]
11336 fn xfixes_intersect_region_checked(
11337 &mut self,
11338 source1: types::Region,
11339 source2: types::Region,
11340 destination: types::Region,
11341 ) -> Result<()> {
11342 let request = types::xfixes::IntersectRegionRequest {
11343 source1,
11344 source2,
11345 destination,
11346 };
11347 let cookie = self.send_void_request(request, false)?;
11348 self.wait_for_reply(cookie)
11349 }
11350 #[cfg(feature = "xfixes")]
11351 fn xfixes_subtract_region(
11352 &mut self,
11353 source1: types::Region,
11354 source2: types::Region,
11355 destination: types::Region,
11356 ) -> Result<Cookie<()>> {
11357 let span = tracing::info_span!(
11358 "xfixes_subtract_region",
11359 source1 = ?source1,
11360 source2 = ?source2,
11361 destination = ?destination,
11362 );
11363 let _enter = span.enter();
11364 let request = types::xfixes::SubtractRegionRequest {
11365 source1,
11366 source2,
11367 destination,
11368 };
11369 let cookie = self.send_void_request(request, true);
11370 cookie
11371 }
11372 #[cfg(feature = "xfixes")]
11373 fn xfixes_subtract_region_checked(
11374 &mut self,
11375 source1: types::Region,
11376 source2: types::Region,
11377 destination: types::Region,
11378 ) -> Result<()> {
11379 let request = types::xfixes::SubtractRegionRequest {
11380 source1,
11381 source2,
11382 destination,
11383 };
11384 let cookie = self.send_void_request(request, false)?;
11385 self.wait_for_reply(cookie)
11386 }
11387 #[cfg(feature = "xfixes")]
11388 fn xfixes_invert_region(
11389 &mut self,
11390 source: types::Region,
11391 bounds: types::Rectangle,
11392 destination: types::Region,
11393 ) -> Result<Cookie<()>> {
11394 let span = tracing::info_span!(
11395 "xfixes_invert_region",
11396 source = ?source,
11397 bounds = ?bounds,
11398 destination = ?destination,
11399 );
11400 let _enter = span.enter();
11401 let request = types::xfixes::InvertRegionRequest {
11402 source,
11403 bounds,
11404 destination,
11405 };
11406 let cookie = self.send_void_request(request, true);
11407 cookie
11408 }
11409 #[cfg(feature = "xfixes")]
11410 fn xfixes_invert_region_checked(
11411 &mut self,
11412 source: types::Region,
11413 bounds: types::Rectangle,
11414 destination: types::Region,
11415 ) -> Result<()> {
11416 let request = types::xfixes::InvertRegionRequest {
11417 source,
11418 bounds,
11419 destination,
11420 };
11421 let cookie = self.send_void_request(request, false)?;
11422 self.wait_for_reply(cookie)
11423 }
11424 #[cfg(feature = "xfixes")]
11425 fn xfixes_translate_region(
11426 &mut self,
11427 region: types::Region,
11428 dx: types::Int16,
11429 dy: types::Int16,
11430 ) -> Result<Cookie<()>> {
11431 let span = tracing::info_span!(
11432 "xfixes_translate_region",
11433 region = ?region,
11434 dx = ?dx,
11435 dy = ?dy,
11436 );
11437 let _enter = span.enter();
11438 let request = types::xfixes::TranslateRegionRequest { region, dx, dy };
11439 let cookie = self.send_void_request(request, true);
11440 cookie
11441 }
11442 #[cfg(feature = "xfixes")]
11443 fn xfixes_translate_region_checked(
11444 &mut self,
11445 region: types::Region,
11446 dx: types::Int16,
11447 dy: types::Int16,
11448 ) -> Result<()> {
11449 let request = types::xfixes::TranslateRegionRequest { region, dx, dy };
11450 let cookie = self.send_void_request(request, false)?;
11451 self.wait_for_reply(cookie)
11452 }
11453 #[cfg(feature = "xfixes")]
11454 fn xfixes_region_extents(
11455 &mut self,
11456 source: types::Region,
11457 destination: types::Region,
11458 ) -> Result<Cookie<()>> {
11459 let span = tracing::info_span!(
11460 "xfixes_region_extents",
11461 source = ?source,
11462 destination = ?destination,
11463 );
11464 let _enter = span.enter();
11465 let request = types::xfixes::RegionExtentsRequest {
11466 source,
11467 destination,
11468 };
11469 let cookie = self.send_void_request(request, true);
11470 cookie
11471 }
11472 #[cfg(feature = "xfixes")]
11473 fn xfixes_region_extents_checked(
11474 &mut self,
11475 source: types::Region,
11476 destination: types::Region,
11477 ) -> Result<()> {
11478 let request = types::xfixes::RegionExtentsRequest {
11479 source,
11480 destination,
11481 };
11482 let cookie = self.send_void_request(request, false)?;
11483 self.wait_for_reply(cookie)
11484 }
11485 #[cfg(feature = "xfixes")]
11486 fn xfixes_fetch_region(
11487 &mut self,
11488 region: types::Region,
11489 ) -> Result<Cookie<types::xfixes::FetchRegionReply>> {
11490 let span = tracing::info_span!(
11491 "xfixes_fetch_region",
11492 region = ?region,
11493 );
11494 let _enter = span.enter();
11495 let request = types::xfixes::FetchRegionRequest { region };
11496 let cookie = self.send_reply_request(request);
11497 cookie
11498 }
11499 #[cfg(feature = "xfixes")]
11500 fn xfixes_fetch_region_immediate(
11501 &mut self,
11502 region: types::Region,
11503 ) -> Result<types::xfixes::FetchRegionReply> {
11504 let request = types::xfixes::FetchRegionRequest { region };
11505 let cookie = self.send_reply_request(request)?;
11506 self.wait_for_reply(cookie)
11507 }
11508 #[cfg(feature = "xfixes")]
11509 fn xfixes_set_gc_clip_region(
11510 &mut self,
11511 gc: types::Gcontext,
11512 region: impl Into<types::Region>,
11513 x_origin: types::Int16,
11514 y_origin: types::Int16,
11515 ) -> Result<Cookie<()>> {
11516 let span = tracing::info_span!(
11517 "xfixes_set_gc_clip_region",
11518 gc = ?gc,
11519 x_origin = ?x_origin,
11520 y_origin = ?y_origin,
11521 );
11522 let _enter = span.enter();
11523 let request = types::xfixes::SetGCClipRegionRequest {
11524 gc,
11525 region: Into::<u32>::into(region.into()) as _,
11526 x_origin,
11527 y_origin,
11528 };
11529 let cookie = self.send_void_request(request, true);
11530 cookie
11531 }
11532 #[cfg(feature = "xfixes")]
11533 fn xfixes_set_gc_clip_region_checked(
11534 &mut self,
11535 gc: types::Gcontext,
11536 region: impl Into<types::Region>,
11537 x_origin: types::Int16,
11538 y_origin: types::Int16,
11539 ) -> Result<()> {
11540 let request = types::xfixes::SetGCClipRegionRequest {
11541 gc,
11542 region: Into::<u32>::into(region.into()) as _,
11543 x_origin,
11544 y_origin,
11545 };
11546 let cookie = self.send_void_request(request, false)?;
11547 self.wait_for_reply(cookie)
11548 }
11549 #[cfg(feature = "xfixes")]
11550 fn xfixes_set_window_shape_region(
11551 &mut self,
11552 dest: types::xproto::Window,
11553 dest_kind: types::SK,
11554 x_offset: types::Int16,
11555 y_offset: types::Int16,
11556 region: impl Into<types::Region>,
11557 ) -> Result<Cookie<()>> {
11558 let span = tracing::info_span!(
11559 "xfixes_set_window_shape_region",
11560 dest = ?dest,
11561 dest_kind = ?dest_kind,
11562 x_offset = ?x_offset,
11563 y_offset = ?y_offset,
11564 );
11565 let _enter = span.enter();
11566 let request = types::xfixes::SetWindowShapeRegionRequest {
11567 dest,
11568 dest_kind,
11569 x_offset,
11570 y_offset,
11571 region: Into::<u32>::into(region.into()) as _,
11572 };
11573 let cookie = self.send_void_request(request, true);
11574 cookie
11575 }
11576 #[cfg(feature = "xfixes")]
11577 fn xfixes_set_window_shape_region_checked(
11578 &mut self,
11579 dest: types::xproto::Window,
11580 dest_kind: types::SK,
11581 x_offset: types::Int16,
11582 y_offset: types::Int16,
11583 region: impl Into<types::Region>,
11584 ) -> Result<()> {
11585 let request = types::xfixes::SetWindowShapeRegionRequest {
11586 dest,
11587 dest_kind,
11588 x_offset,
11589 y_offset,
11590 region: Into::<u32>::into(region.into()) as _,
11591 };
11592 let cookie = self.send_void_request(request, false)?;
11593 self.wait_for_reply(cookie)
11594 }
11595 #[cfg(feature = "xfixes")]
11596 fn xfixes_set_picture_clip_region(
11597 &mut self,
11598 picture: types::Picture,
11599 region: impl Into<types::Region>,
11600 x_origin: types::Int16,
11601 y_origin: types::Int16,
11602 ) -> Result<Cookie<()>> {
11603 let span = tracing::info_span!(
11604 "xfixes_set_picture_clip_region",
11605 picture = ?picture,
11606 x_origin = ?x_origin,
11607 y_origin = ?y_origin,
11608 );
11609 let _enter = span.enter();
11610 let request = types::xfixes::SetPictureClipRegionRequest {
11611 picture,
11612 region: Into::<u32>::into(region.into()) as _,
11613 x_origin,
11614 y_origin,
11615 };
11616 let cookie = self.send_void_request(request, true);
11617 cookie
11618 }
11619 #[cfg(feature = "xfixes")]
11620 fn xfixes_set_picture_clip_region_checked(
11621 &mut self,
11622 picture: types::Picture,
11623 region: impl Into<types::Region>,
11624 x_origin: types::Int16,
11625 y_origin: types::Int16,
11626 ) -> Result<()> {
11627 let request = types::xfixes::SetPictureClipRegionRequest {
11628 picture,
11629 region: Into::<u32>::into(region.into()) as _,
11630 x_origin,
11631 y_origin,
11632 };
11633 let cookie = self.send_void_request(request, false)?;
11634 self.wait_for_reply(cookie)
11635 }
11636 #[cfg(feature = "xfixes")]
11637 fn xfixes_set_cursor_name(
11638 &mut self,
11639 cursor: types::xproto::Cursor,
11640 name: impl AsRef<[types::Char]>,
11641 ) -> Result<Cookie<()>> {
11642 let span = tracing::info_span!(
11643 "xfixes_set_cursor_name",
11644 cursor = ?cursor,
11645 );
11646 let _enter = span.enter();
11647 let request = types::xfixes::SetCursorNameRequest {
11648 cursor,
11649 name: Cow::Borrowed(name.as_ref()),
11650 };
11651 let cookie = self.send_void_request(request, true);
11652 cookie
11653 }
11654 #[cfg(feature = "xfixes")]
11655 fn xfixes_set_cursor_name_checked(
11656 &mut self,
11657 cursor: types::xproto::Cursor,
11658 name: impl AsRef<[types::Char]>,
11659 ) -> Result<()> {
11660 let request = types::xfixes::SetCursorNameRequest {
11661 cursor,
11662 name: Cow::Borrowed(name.as_ref()),
11663 };
11664 let cookie = self.send_void_request(request, false)?;
11665 self.wait_for_reply(cookie)
11666 }
11667 #[cfg(feature = "xfixes")]
11668 fn xfixes_get_cursor_name(
11669 &mut self,
11670 cursor: types::xproto::Cursor,
11671 ) -> Result<Cookie<types::xfixes::GetCursorNameReply>> {
11672 let span = tracing::info_span!(
11673 "xfixes_get_cursor_name",
11674 cursor = ?cursor,
11675 );
11676 let _enter = span.enter();
11677 let request = types::xfixes::GetCursorNameRequest { cursor };
11678 let cookie = self.send_reply_request(request);
11679 cookie
11680 }
11681 #[cfg(feature = "xfixes")]
11682 fn xfixes_get_cursor_name_immediate(
11683 &mut self,
11684 cursor: types::xproto::Cursor,
11685 ) -> Result<types::xfixes::GetCursorNameReply> {
11686 let request = types::xfixes::GetCursorNameRequest { cursor };
11687 let cookie = self.send_reply_request(request)?;
11688 self.wait_for_reply(cookie)
11689 }
11690 #[cfg(feature = "xfixes")]
11691 fn xfixes_get_cursor_image_and_name(
11692 &mut self,
11693 ) -> Result<Cookie<types::xfixes::GetCursorImageAndNameReply>> {
11694 let span = tracing::info_span!("xfixes_get_cursor_image_and_name",);
11695 let _enter = span.enter();
11696 let request = types::xfixes::GetCursorImageAndNameRequest {};
11697 let cookie = self.send_reply_request(request);
11698 cookie
11699 }
11700 #[cfg(feature = "xfixes")]
11701 fn xfixes_get_cursor_image_and_name_immediate(
11702 &mut self,
11703 ) -> Result<types::xfixes::GetCursorImageAndNameReply> {
11704 let request = types::xfixes::GetCursorImageAndNameRequest {};
11705 let cookie = self.send_reply_request(request)?;
11706 self.wait_for_reply(cookie)
11707 }
11708 #[cfg(feature = "xfixes")]
11709 fn xfixes_change_cursor(
11710 &mut self,
11711 source: types::xproto::Cursor,
11712 destination: types::xproto::Cursor,
11713 ) -> Result<Cookie<()>> {
11714 let span = tracing::info_span!(
11715 "xfixes_change_cursor",
11716 source = ?source,
11717 destination = ?destination,
11718 );
11719 let _enter = span.enter();
11720 let request = types::xfixes::ChangeCursorRequest {
11721 source,
11722 destination,
11723 };
11724 let cookie = self.send_void_request(request, true);
11725 cookie
11726 }
11727 #[cfg(feature = "xfixes")]
11728 fn xfixes_change_cursor_checked(
11729 &mut self,
11730 source: types::xproto::Cursor,
11731 destination: types::xproto::Cursor,
11732 ) -> Result<()> {
11733 let request = types::xfixes::ChangeCursorRequest {
11734 source,
11735 destination,
11736 };
11737 let cookie = self.send_void_request(request, false)?;
11738 self.wait_for_reply(cookie)
11739 }
11740 #[cfg(feature = "xfixes")]
11741 fn xfixes_change_cursor_by_name(
11742 &mut self,
11743 src: types::xproto::Cursor,
11744 name: impl AsRef<[types::Char]>,
11745 ) -> Result<Cookie<()>> {
11746 let span = tracing::info_span!(
11747 "xfixes_change_cursor_by_name",
11748 src = ?src,
11749 );
11750 let _enter = span.enter();
11751 let request = types::xfixes::ChangeCursorByNameRequest {
11752 src,
11753 name: Cow::Borrowed(name.as_ref()),
11754 };
11755 let cookie = self.send_void_request(request, true);
11756 cookie
11757 }
11758 #[cfg(feature = "xfixes")]
11759 fn xfixes_change_cursor_by_name_checked(
11760 &mut self,
11761 src: types::xproto::Cursor,
11762 name: impl AsRef<[types::Char]>,
11763 ) -> Result<()> {
11764 let request = types::xfixes::ChangeCursorByNameRequest {
11765 src,
11766 name: Cow::Borrowed(name.as_ref()),
11767 };
11768 let cookie = self.send_void_request(request, false)?;
11769 self.wait_for_reply(cookie)
11770 }
11771 #[cfg(feature = "xfixes")]
11772 fn xfixes_expand_region(
11773 &mut self,
11774 source: types::Region,
11775 destination: types::Region,
11776 left: types::Card16,
11777 right: types::Card16,
11778 top: types::Card16,
11779 bottom: types::Card16,
11780 ) -> Result<Cookie<()>> {
11781 let span = tracing::info_span!(
11782 "xfixes_expand_region",
11783 source = ?source,
11784 destination = ?destination,
11785 left = ?left,
11786 right = ?right,
11787 top = ?top,
11788 bottom = ?bottom,
11789 );
11790 let _enter = span.enter();
11791 let request = types::xfixes::ExpandRegionRequest {
11792 source,
11793 destination,
11794 left,
11795 right,
11796 top,
11797 bottom,
11798 };
11799 let cookie = self.send_void_request(request, true);
11800 cookie
11801 }
11802 #[cfg(feature = "xfixes")]
11803 fn xfixes_expand_region_checked(
11804 &mut self,
11805 source: types::Region,
11806 destination: types::Region,
11807 left: types::Card16,
11808 right: types::Card16,
11809 top: types::Card16,
11810 bottom: types::Card16,
11811 ) -> Result<()> {
11812 let request = types::xfixes::ExpandRegionRequest {
11813 source,
11814 destination,
11815 left,
11816 right,
11817 top,
11818 bottom,
11819 };
11820 let cookie = self.send_void_request(request, false)?;
11821 self.wait_for_reply(cookie)
11822 }
11823 #[cfg(feature = "xfixes")]
11824 fn xfixes_hide_cursor(&mut self, window: types::xproto::Window) -> Result<Cookie<()>> {
11825 let span = tracing::info_span!(
11826 "xfixes_hide_cursor",
11827 window = ?window,
11828 );
11829 let _enter = span.enter();
11830 let request = types::xfixes::HideCursorRequest { window };
11831 let cookie = self.send_void_request(request, true);
11832 cookie
11833 }
11834 #[cfg(feature = "xfixes")]
11835 fn xfixes_hide_cursor_checked(&mut self, window: types::xproto::Window) -> Result<()> {
11836 let request = types::xfixes::HideCursorRequest { window };
11837 let cookie = self.send_void_request(request, false)?;
11838 self.wait_for_reply(cookie)
11839 }
11840 #[cfg(feature = "xfixes")]
11841 fn xfixes_show_cursor(&mut self, window: types::xproto::Window) -> Result<Cookie<()>> {
11842 let span = tracing::info_span!(
11843 "xfixes_show_cursor",
11844 window = ?window,
11845 );
11846 let _enter = span.enter();
11847 let request = types::xfixes::ShowCursorRequest { window };
11848 let cookie = self.send_void_request(request, true);
11849 cookie
11850 }
11851 #[cfg(feature = "xfixes")]
11852 fn xfixes_show_cursor_checked(&mut self, window: types::xproto::Window) -> Result<()> {
11853 let request = types::xfixes::ShowCursorRequest { window };
11854 let cookie = self.send_void_request(request, false)?;
11855 self.wait_for_reply(cookie)
11856 }
11857 #[cfg(feature = "xfixes")]
11858 fn xfixes_create_pointer_barrier(
11859 &mut self,
11860 barrier: types::Barrier,
11861 window: types::xproto::Window,
11862 x1: types::Card16,
11863 y1: types::Card16,
11864 x2: types::Card16,
11865 y2: types::Card16,
11866 directions: impl Into<types::BarrierDirections>,
11867 devices: impl AsRef<[types::Card16]>,
11868 ) -> Result<Cookie<()>> {
11869 let span = tracing::info_span!(
11870 "xfixes_create_pointer_barrier",
11871 barrier = ?barrier,
11872 window = ?window,
11873 x1 = ?x1,
11874 y1 = ?y1,
11875 x2 = ?x2,
11876 y2 = ?y2,
11877 );
11878 let _enter = span.enter();
11879 let request = types::xfixes::CreatePointerBarrierRequest {
11880 barrier,
11881 window,
11882 x1,
11883 y1,
11884 x2,
11885 y2,
11886 directions: Into::<u32>::into(directions.into()) as _,
11887 devices: Cow::Borrowed(devices.as_ref()),
11888 };
11889 let cookie = self.send_void_request(request, true);
11890 cookie
11891 }
11892 #[cfg(feature = "xfixes")]
11893 fn xfixes_create_pointer_barrier_checked(
11894 &mut self,
11895 barrier: types::Barrier,
11896 window: types::xproto::Window,
11897 x1: types::Card16,
11898 y1: types::Card16,
11899 x2: types::Card16,
11900 y2: types::Card16,
11901 directions: impl Into<types::BarrierDirections>,
11902 devices: impl AsRef<[types::Card16]>,
11903 ) -> Result<()> {
11904 let request = types::xfixes::CreatePointerBarrierRequest {
11905 barrier,
11906 window,
11907 x1,
11908 y1,
11909 x2,
11910 y2,
11911 directions: Into::<u32>::into(directions.into()) as _,
11912 devices: Cow::Borrowed(devices.as_ref()),
11913 };
11914 let cookie = self.send_void_request(request, false)?;
11915 self.wait_for_reply(cookie)
11916 }
11917 #[cfg(feature = "xfixes")]
11918 fn xfixes_delete_pointer_barrier(&mut self, barrier: types::Barrier) -> Result<Cookie<()>> {
11919 let span = tracing::info_span!(
11920 "xfixes_delete_pointer_barrier",
11921 barrier = ?barrier,
11922 );
11923 let _enter = span.enter();
11924 let request = types::xfixes::DeletePointerBarrierRequest { barrier };
11925 let cookie = self.send_void_request(request, true);
11926 cookie
11927 }
11928 #[cfg(feature = "xfixes")]
11929 fn xfixes_delete_pointer_barrier_checked(&mut self, barrier: types::Barrier) -> Result<()> {
11930 let request = types::xfixes::DeletePointerBarrierRequest { barrier };
11931 let cookie = self.send_void_request(request, false)?;
11932 self.wait_for_reply(cookie)
11933 }
11934
11935 #[cfg(feature = "xinerama")]
11936 fn xinerama_query_version(
11937 &mut self,
11938 major: types::Card8,
11939 minor: types::Card8,
11940 ) -> Result<Cookie<types::xinerama::QueryVersionReply>> {
11941 let span = tracing::info_span!(
11942 "xinerama_query_version",
11943 major = ?major,
11944 minor = ?minor,
11945 );
11946 let _enter = span.enter();
11947 let request = types::xinerama::QueryVersionRequest { major, minor };
11948 let cookie = self.send_reply_request(request);
11949 cookie
11950 }
11951 #[cfg(feature = "xinerama")]
11952 fn xinerama_query_version_immediate(
11953 &mut self,
11954 major: types::Card8,
11955 minor: types::Card8,
11956 ) -> Result<types::xinerama::QueryVersionReply> {
11957 let request = types::xinerama::QueryVersionRequest { major, minor };
11958 let cookie = self.send_reply_request(request)?;
11959 self.wait_for_reply(cookie)
11960 }
11961 #[cfg(feature = "xinerama")]
11962 fn xinerama_get_state(
11963 &mut self,
11964 window: types::xproto::Window,
11965 ) -> Result<Cookie<types::xinerama::GetStateReply>> {
11966 let span = tracing::info_span!(
11967 "xinerama_get_state",
11968 window = ?window,
11969 );
11970 let _enter = span.enter();
11971 let request = types::xinerama::GetStateRequest { window };
11972 let cookie = self.send_reply_request(request);
11973 cookie
11974 }
11975 #[cfg(feature = "xinerama")]
11976 fn xinerama_get_state_immediate(
11977 &mut self,
11978 window: types::xproto::Window,
11979 ) -> Result<types::xinerama::GetStateReply> {
11980 let request = types::xinerama::GetStateRequest { window };
11981 let cookie = self.send_reply_request(request)?;
11982 self.wait_for_reply(cookie)
11983 }
11984 #[cfg(feature = "xinerama")]
11985 fn xinerama_get_screen_count(
11986 &mut self,
11987 window: types::xproto::Window,
11988 ) -> Result<Cookie<types::xinerama::GetScreenCountReply>> {
11989 let span = tracing::info_span!(
11990 "xinerama_get_screen_count",
11991 window = ?window,
11992 );
11993 let _enter = span.enter();
11994 let request = types::xinerama::GetScreenCountRequest { window };
11995 let cookie = self.send_reply_request(request);
11996 cookie
11997 }
11998 #[cfg(feature = "xinerama")]
11999 fn xinerama_get_screen_count_immediate(
12000 &mut self,
12001 window: types::xproto::Window,
12002 ) -> Result<types::xinerama::GetScreenCountReply> {
12003 let request = types::xinerama::GetScreenCountRequest { window };
12004 let cookie = self.send_reply_request(request)?;
12005 self.wait_for_reply(cookie)
12006 }
12007 #[cfg(feature = "xinerama")]
12008 fn xinerama_get_screen_size(
12009 &mut self,
12010 window: types::xproto::Window,
12011 screen: types::Card32,
12012 ) -> Result<Cookie<types::xinerama::GetScreenSizeReply>> {
12013 let span = tracing::info_span!(
12014 "xinerama_get_screen_size",
12015 window = ?window,
12016 screen = ?screen,
12017 );
12018 let _enter = span.enter();
12019 let request = types::xinerama::GetScreenSizeRequest { window, screen };
12020 let cookie = self.send_reply_request(request);
12021 cookie
12022 }
12023 #[cfg(feature = "xinerama")]
12024 fn xinerama_get_screen_size_immediate(
12025 &mut self,
12026 window: types::xproto::Window,
12027 screen: types::Card32,
12028 ) -> Result<types::xinerama::GetScreenSizeReply> {
12029 let request = types::xinerama::GetScreenSizeRequest { window, screen };
12030 let cookie = self.send_reply_request(request)?;
12031 self.wait_for_reply(cookie)
12032 }
12033 #[cfg(feature = "xinerama")]
12034 fn xinerama_is_active(&mut self) -> Result<Cookie<types::xinerama::IsActiveReply>> {
12035 let span = tracing::info_span!("xinerama_is_active",);
12036 let _enter = span.enter();
12037 let request = types::xinerama::IsActiveRequest {};
12038 let cookie = self.send_reply_request(request);
12039 cookie
12040 }
12041 #[cfg(feature = "xinerama")]
12042 fn xinerama_is_active_immediate(&mut self) -> Result<types::xinerama::IsActiveReply> {
12043 let request = types::xinerama::IsActiveRequest {};
12044 let cookie = self.send_reply_request(request)?;
12045 self.wait_for_reply(cookie)
12046 }
12047 #[cfg(feature = "xinerama")]
12048 fn xinerama_query_screens(&mut self) -> Result<Cookie<types::xinerama::QueryScreensReply>> {
12049 let span = tracing::info_span!("xinerama_query_screens",);
12050 let _enter = span.enter();
12051 let request = types::xinerama::QueryScreensRequest {};
12052 let cookie = self.send_reply_request(request);
12053 cookie
12054 }
12055 #[cfg(feature = "xinerama")]
12056 fn xinerama_query_screens_immediate(&mut self) -> Result<types::xinerama::QueryScreensReply> {
12057 let request = types::xinerama::QueryScreensRequest {};
12058 let cookie = self.send_reply_request(request)?;
12059 self.wait_for_reply(cookie)
12060 }
12061
12062 #[cfg(feature = "xinput")]
12063 fn xinput_get_extension_version(
12064 &mut self,
12065 name: impl AsRef<[types::Char]>,
12066 ) -> Result<Cookie<types::xinput::GetExtensionVersionReply>> {
12067 let span = tracing::info_span!("xinput_get_extension_version",);
12068 let _enter = span.enter();
12069 let request = types::xinput::GetExtensionVersionRequest {
12070 name: Cow::Borrowed(name.as_ref()),
12071 };
12072 let cookie = self.send_reply_request(request);
12073 cookie
12074 }
12075 #[cfg(feature = "xinput")]
12076 fn xinput_get_extension_version_immediate(
12077 &mut self,
12078 name: impl AsRef<[types::Char]>,
12079 ) -> Result<types::xinput::GetExtensionVersionReply> {
12080 let request = types::xinput::GetExtensionVersionRequest {
12081 name: Cow::Borrowed(name.as_ref()),
12082 };
12083 let cookie = self.send_reply_request(request)?;
12084 self.wait_for_reply(cookie)
12085 }
12086 #[cfg(feature = "xinput")]
12087 fn xinput_list_input_devices(
12088 &mut self,
12089 ) -> Result<Cookie<types::xinput::ListInputDevicesReply>> {
12090 let span = tracing::info_span!("xinput_list_input_devices",);
12091 let _enter = span.enter();
12092 let request = types::xinput::ListInputDevicesRequest {};
12093 let cookie = self.send_reply_request(request);
12094 cookie
12095 }
12096 #[cfg(feature = "xinput")]
12097 fn xinput_list_input_devices_immediate(
12098 &mut self,
12099 ) -> Result<types::xinput::ListInputDevicesReply> {
12100 let request = types::xinput::ListInputDevicesRequest {};
12101 let cookie = self.send_reply_request(request)?;
12102 self.wait_for_reply(cookie)
12103 }
12104 #[cfg(feature = "xinput")]
12105 fn xinput_open_device(
12106 &mut self,
12107 device_id: types::Card8,
12108 ) -> Result<Cookie<types::xinput::OpenDeviceReply>> {
12109 let span = tracing::info_span!(
12110 "xinput_open_device",
12111 device_id = ?device_id,
12112 );
12113 let _enter = span.enter();
12114 let request = types::xinput::OpenDeviceRequest { device_id };
12115 let cookie = self.send_reply_request(request);
12116 cookie
12117 }
12118 #[cfg(feature = "xinput")]
12119 fn xinput_open_device_immediate(
12120 &mut self,
12121 device_id: types::Card8,
12122 ) -> Result<types::xinput::OpenDeviceReply> {
12123 let request = types::xinput::OpenDeviceRequest { device_id };
12124 let cookie = self.send_reply_request(request)?;
12125 self.wait_for_reply(cookie)
12126 }
12127 #[cfg(feature = "xinput")]
12128 fn xinput_close_device(&mut self, device_id: types::Card8) -> Result<Cookie<()>> {
12129 let span = tracing::info_span!(
12130 "xinput_close_device",
12131 device_id = ?device_id,
12132 );
12133 let _enter = span.enter();
12134 let request = types::xinput::CloseDeviceRequest { device_id };
12135 let cookie = self.send_void_request(request, true);
12136 cookie
12137 }
12138 #[cfg(feature = "xinput")]
12139 fn xinput_close_device_checked(&mut self, device_id: types::Card8) -> Result<()> {
12140 let request = types::xinput::CloseDeviceRequest { device_id };
12141 let cookie = self.send_void_request(request, false)?;
12142 self.wait_for_reply(cookie)
12143 }
12144 #[cfg(feature = "xinput")]
12145 fn xinput_set_device_mode(
12146 &mut self,
12147 device_id: types::Card8,
12148 mode: types::ValuatorMode,
12149 ) -> Result<Cookie<types::xinput::SetDeviceModeReply>> {
12150 let span = tracing::info_span!(
12151 "xinput_set_device_mode",
12152 device_id = ?device_id,
12153 mode = ?mode,
12154 );
12155 let _enter = span.enter();
12156 let request = types::xinput::SetDeviceModeRequest { device_id, mode };
12157 let cookie = self.send_reply_request(request);
12158 cookie
12159 }
12160 #[cfg(feature = "xinput")]
12161 fn xinput_set_device_mode_immediate(
12162 &mut self,
12163 device_id: types::Card8,
12164 mode: types::ValuatorMode,
12165 ) -> Result<types::xinput::SetDeviceModeReply> {
12166 let request = types::xinput::SetDeviceModeRequest { device_id, mode };
12167 let cookie = self.send_reply_request(request)?;
12168 self.wait_for_reply(cookie)
12169 }
12170 #[cfg(feature = "xinput")]
12171 fn xinput_select_extension_event(
12172 &mut self,
12173 window: types::xproto::Window,
12174 classes: impl AsRef<[types::EventClass]>,
12175 ) -> Result<Cookie<()>> {
12176 let span = tracing::info_span!(
12177 "xinput_select_extension_event",
12178 window = ?window,
12179 );
12180 let _enter = span.enter();
12181 let request = types::xinput::SelectExtensionEventRequest {
12182 window,
12183 classes: Cow::Borrowed(classes.as_ref()),
12184 };
12185 let cookie = self.send_void_request(request, true);
12186 cookie
12187 }
12188 #[cfg(feature = "xinput")]
12189 fn xinput_select_extension_event_checked(
12190 &mut self,
12191 window: types::xproto::Window,
12192 classes: impl AsRef<[types::EventClass]>,
12193 ) -> Result<()> {
12194 let request = types::xinput::SelectExtensionEventRequest {
12195 window,
12196 classes: Cow::Borrowed(classes.as_ref()),
12197 };
12198 let cookie = self.send_void_request(request, false)?;
12199 self.wait_for_reply(cookie)
12200 }
12201 #[cfg(feature = "xinput")]
12202 fn xinput_get_selected_extension_events(
12203 &mut self,
12204 window: types::xproto::Window,
12205 ) -> Result<Cookie<types::xinput::GetSelectedExtensionEventsReply>> {
12206 let span = tracing::info_span!(
12207 "xinput_get_selected_extension_events",
12208 window = ?window,
12209 );
12210 let _enter = span.enter();
12211 let request = types::xinput::GetSelectedExtensionEventsRequest { window };
12212 let cookie = self.send_reply_request(request);
12213 cookie
12214 }
12215 #[cfg(feature = "xinput")]
12216 fn xinput_get_selected_extension_events_immediate(
12217 &mut self,
12218 window: types::xproto::Window,
12219 ) -> Result<types::xinput::GetSelectedExtensionEventsReply> {
12220 let request = types::xinput::GetSelectedExtensionEventsRequest { window };
12221 let cookie = self.send_reply_request(request)?;
12222 self.wait_for_reply(cookie)
12223 }
12224 #[cfg(feature = "xinput")]
12225 fn xinput_change_device_dont_propagate_list(
12226 &mut self,
12227 window: types::xproto::Window,
12228 mode: types::PropagateMode,
12229 classes: impl AsRef<[types::EventClass]>,
12230 ) -> Result<Cookie<()>> {
12231 let span = tracing::info_span!(
12232 "xinput_change_device_dont_propagate_list",
12233 window = ?window,
12234 mode = ?mode,
12235 );
12236 let _enter = span.enter();
12237 let request = types::xinput::ChangeDeviceDontPropagateListRequest {
12238 window,
12239 mode,
12240 classes: Cow::Borrowed(classes.as_ref()),
12241 };
12242 let cookie = self.send_void_request(request, true);
12243 cookie
12244 }
12245 #[cfg(feature = "xinput")]
12246 fn xinput_change_device_dont_propagate_list_checked(
12247 &mut self,
12248 window: types::xproto::Window,
12249 mode: types::PropagateMode,
12250 classes: impl AsRef<[types::EventClass]>,
12251 ) -> Result<()> {
12252 let request = types::xinput::ChangeDeviceDontPropagateListRequest {
12253 window,
12254 mode,
12255 classes: Cow::Borrowed(classes.as_ref()),
12256 };
12257 let cookie = self.send_void_request(request, false)?;
12258 self.wait_for_reply(cookie)
12259 }
12260 #[cfg(feature = "xinput")]
12261 fn xinput_get_device_dont_propagate_list(
12262 &mut self,
12263 window: types::xproto::Window,
12264 ) -> Result<Cookie<types::xinput::GetDeviceDontPropagateListReply>> {
12265 let span = tracing::info_span!(
12266 "xinput_get_device_dont_propagate_list",
12267 window = ?window,
12268 );
12269 let _enter = span.enter();
12270 let request = types::xinput::GetDeviceDontPropagateListRequest { window };
12271 let cookie = self.send_reply_request(request);
12272 cookie
12273 }
12274 #[cfg(feature = "xinput")]
12275 fn xinput_get_device_dont_propagate_list_immediate(
12276 &mut self,
12277 window: types::xproto::Window,
12278 ) -> Result<types::xinput::GetDeviceDontPropagateListReply> {
12279 let request = types::xinput::GetDeviceDontPropagateListRequest { window };
12280 let cookie = self.send_reply_request(request)?;
12281 self.wait_for_reply(cookie)
12282 }
12283 #[cfg(feature = "xinput")]
12284 fn xinput_get_device_motion_events(
12285 &mut self,
12286 start: types::Timestamp,
12287 stop: impl Into<types::Time>,
12288 device_id: types::Card8,
12289 ) -> Result<Cookie<types::xinput::GetDeviceMotionEventsReply>> {
12290 let span = tracing::info_span!(
12291 "xinput_get_device_motion_events",
12292 start = ?start,
12293 device_id = ?device_id,
12294 );
12295 let _enter = span.enter();
12296 let request = types::xinput::GetDeviceMotionEventsRequest {
12297 start,
12298 stop: Into::<u32>::into(stop.into()) as _,
12299 device_id,
12300 };
12301 let cookie = self.send_reply_request(request);
12302 cookie
12303 }
12304 #[cfg(feature = "xinput")]
12305 fn xinput_get_device_motion_events_immediate(
12306 &mut self,
12307 start: types::Timestamp,
12308 stop: impl Into<types::Time>,
12309 device_id: types::Card8,
12310 ) -> Result<types::xinput::GetDeviceMotionEventsReply> {
12311 let request = types::xinput::GetDeviceMotionEventsRequest {
12312 start,
12313 stop: Into::<u32>::into(stop.into()) as _,
12314 device_id,
12315 };
12316 let cookie = self.send_reply_request(request)?;
12317 self.wait_for_reply(cookie)
12318 }
12319 #[cfg(feature = "xinput")]
12320 fn xinput_change_keyboard_device(
12321 &mut self,
12322 device_id: types::Card8,
12323 ) -> Result<Cookie<types::xinput::ChangeKeyboardDeviceReply>> {
12324 let span = tracing::info_span!(
12325 "xinput_change_keyboard_device",
12326 device_id = ?device_id,
12327 );
12328 let _enter = span.enter();
12329 let request = types::xinput::ChangeKeyboardDeviceRequest { device_id };
12330 let cookie = self.send_reply_request(request);
12331 cookie
12332 }
12333 #[cfg(feature = "xinput")]
12334 fn xinput_change_keyboard_device_immediate(
12335 &mut self,
12336 device_id: types::Card8,
12337 ) -> Result<types::xinput::ChangeKeyboardDeviceReply> {
12338 let request = types::xinput::ChangeKeyboardDeviceRequest { device_id };
12339 let cookie = self.send_reply_request(request)?;
12340 self.wait_for_reply(cookie)
12341 }
12342 #[cfg(feature = "xinput")]
12343 fn xinput_change_pointer_device(
12344 &mut self,
12345 x_axis: types::Card8,
12346 y_axis: types::Card8,
12347 device_id: types::Card8,
12348 ) -> Result<Cookie<types::xinput::ChangePointerDeviceReply>> {
12349 let span = tracing::info_span!(
12350 "xinput_change_pointer_device",
12351 x_axis = ?x_axis,
12352 y_axis = ?y_axis,
12353 device_id = ?device_id,
12354 );
12355 let _enter = span.enter();
12356 let request = types::xinput::ChangePointerDeviceRequest {
12357 x_axis,
12358 y_axis,
12359 device_id,
12360 };
12361 let cookie = self.send_reply_request(request);
12362 cookie
12363 }
12364 #[cfg(feature = "xinput")]
12365 fn xinput_change_pointer_device_immediate(
12366 &mut self,
12367 x_axis: types::Card8,
12368 y_axis: types::Card8,
12369 device_id: types::Card8,
12370 ) -> Result<types::xinput::ChangePointerDeviceReply> {
12371 let request = types::xinput::ChangePointerDeviceRequest {
12372 x_axis,
12373 y_axis,
12374 device_id,
12375 };
12376 let cookie = self.send_reply_request(request)?;
12377 self.wait_for_reply(cookie)
12378 }
12379 #[cfg(feature = "xinput")]
12380 fn xinput_grab_device(
12381 &mut self,
12382 grab_window: types::xproto::Window,
12383 time: impl Into<types::Time>,
12384 this_device_mode: types::GrabMode,
12385 other_device_mode: types::GrabMode,
12386 owner_events: types::Bool,
12387 device_id: types::Card8,
12388 classes: impl AsRef<[types::EventClass]>,
12389 ) -> Result<Cookie<types::xinput::GrabDeviceReply>> {
12390 let span = tracing::info_span!(
12391 "xinput_grab_device",
12392 grab_window = ?grab_window,
12393 this_device_mode = ?this_device_mode,
12394 other_device_mode = ?other_device_mode,
12395 owner_events = ?owner_events,
12396 device_id = ?device_id,
12397 );
12398 let _enter = span.enter();
12399 let request = types::xinput::GrabDeviceRequest {
12400 grab_window,
12401 time: Into::<u32>::into(time.into()) as _,
12402 this_device_mode,
12403 other_device_mode,
12404 owner_events,
12405 device_id,
12406 classes: Cow::Borrowed(classes.as_ref()),
12407 };
12408 let cookie = self.send_reply_request(request);
12409 cookie
12410 }
12411 #[cfg(feature = "xinput")]
12412 fn xinput_grab_device_immediate(
12413 &mut self,
12414 grab_window: types::xproto::Window,
12415 time: impl Into<types::Time>,
12416 this_device_mode: types::GrabMode,
12417 other_device_mode: types::GrabMode,
12418 owner_events: types::Bool,
12419 device_id: types::Card8,
12420 classes: impl AsRef<[types::EventClass]>,
12421 ) -> Result<types::xinput::GrabDeviceReply> {
12422 let request = types::xinput::GrabDeviceRequest {
12423 grab_window,
12424 time: Into::<u32>::into(time.into()) as _,
12425 this_device_mode,
12426 other_device_mode,
12427 owner_events,
12428 device_id,
12429 classes: Cow::Borrowed(classes.as_ref()),
12430 };
12431 let cookie = self.send_reply_request(request)?;
12432 self.wait_for_reply(cookie)
12433 }
12434 #[cfg(feature = "xinput")]
12435 fn xinput_ungrab_device(
12436 &mut self,
12437 time: impl Into<types::Time>,
12438 device_id: types::Card8,
12439 ) -> Result<Cookie<()>> {
12440 let span = tracing::info_span!(
12441 "xinput_ungrab_device",
12442 device_id = ?device_id,
12443 );
12444 let _enter = span.enter();
12445 let request = types::xinput::UngrabDeviceRequest {
12446 time: Into::<u32>::into(time.into()) as _,
12447 device_id,
12448 };
12449 let cookie = self.send_void_request(request, true);
12450 cookie
12451 }
12452 #[cfg(feature = "xinput")]
12453 fn xinput_ungrab_device_checked(
12454 &mut self,
12455 time: impl Into<types::Time>,
12456 device_id: types::Card8,
12457 ) -> Result<()> {
12458 let request = types::xinput::UngrabDeviceRequest {
12459 time: Into::<u32>::into(time.into()) as _,
12460 device_id,
12461 };
12462 let cookie = self.send_void_request(request, false)?;
12463 self.wait_for_reply(cookie)
12464 }
12465 #[cfg(feature = "xinput")]
12466 fn xinput_grab_device_key(
12467 &mut self,
12468 grab_window: types::xproto::Window,
12469 modifiers: impl Into<types::ModMask>,
12470 modifier_device: impl Into<types::ModifierDevice>,
12471 grabbed_device: types::Card8,
12472 key: impl Into<types::Grab>,
12473 this_device_mode: types::GrabMode,
12474 other_device_mode: types::GrabMode,
12475 owner_events: types::Bool,
12476 classes: impl AsRef<[types::EventClass]>,
12477 ) -> Result<Cookie<()>> {
12478 let span = tracing::info_span!(
12479 "xinput_grab_device_key",
12480 grab_window = ?grab_window,
12481 grabbed_device = ?grabbed_device,
12482 this_device_mode = ?this_device_mode,
12483 other_device_mode = ?other_device_mode,
12484 owner_events = ?owner_events,
12485 );
12486 let _enter = span.enter();
12487 let request = types::xinput::GrabDeviceKeyRequest {
12488 grab_window,
12489 modifiers: Into::<u32>::into(modifiers.into()) as _,
12490 modifier_device: Into::<u32>::into(modifier_device.into()) as _,
12491 grabbed_device,
12492 key: Into::<u32>::into(key.into()) as _,
12493 this_device_mode,
12494 other_device_mode,
12495 owner_events,
12496 classes: Cow::Borrowed(classes.as_ref()),
12497 };
12498 let cookie = self.send_void_request(request, true);
12499 cookie
12500 }
12501 #[cfg(feature = "xinput")]
12502 fn xinput_grab_device_key_checked(
12503 &mut self,
12504 grab_window: types::xproto::Window,
12505 modifiers: impl Into<types::ModMask>,
12506 modifier_device: impl Into<types::ModifierDevice>,
12507 grabbed_device: types::Card8,
12508 key: impl Into<types::Grab>,
12509 this_device_mode: types::GrabMode,
12510 other_device_mode: types::GrabMode,
12511 owner_events: types::Bool,
12512 classes: impl AsRef<[types::EventClass]>,
12513 ) -> Result<()> {
12514 let request = types::xinput::GrabDeviceKeyRequest {
12515 grab_window,
12516 modifiers: Into::<u32>::into(modifiers.into()) as _,
12517 modifier_device: Into::<u32>::into(modifier_device.into()) as _,
12518 grabbed_device,
12519 key: Into::<u32>::into(key.into()) as _,
12520 this_device_mode,
12521 other_device_mode,
12522 owner_events,
12523 classes: Cow::Borrowed(classes.as_ref()),
12524 };
12525 let cookie = self.send_void_request(request, false)?;
12526 self.wait_for_reply(cookie)
12527 }
12528 #[cfg(feature = "xinput")]
12529 fn xinput_ungrab_device_key(
12530 &mut self,
12531 grab_window: types::xproto::Window,
12532 modifiers: impl Into<types::ModMask>,
12533 modifier_device: impl Into<types::ModifierDevice>,
12534 key: impl Into<types::Grab>,
12535 grabbed_device: types::Card8,
12536 ) -> Result<Cookie<()>> {
12537 let span = tracing::info_span!(
12538 "xinput_ungrab_device_key",
12539 grab_window = ?grab_window,
12540 grabbed_device = ?grabbed_device,
12541 );
12542 let _enter = span.enter();
12543 let request = types::xinput::UngrabDeviceKeyRequest {
12544 grab_window,
12545 modifiers: Into::<u32>::into(modifiers.into()) as _,
12546 modifier_device: Into::<u32>::into(modifier_device.into()) as _,
12547 key: Into::<u32>::into(key.into()) as _,
12548 grabbed_device,
12549 };
12550 let cookie = self.send_void_request(request, true);
12551 cookie
12552 }
12553 #[cfg(feature = "xinput")]
12554 fn xinput_ungrab_device_key_checked(
12555 &mut self,
12556 grab_window: types::xproto::Window,
12557 modifiers: impl Into<types::ModMask>,
12558 modifier_device: impl Into<types::ModifierDevice>,
12559 key: impl Into<types::Grab>,
12560 grabbed_device: types::Card8,
12561 ) -> Result<()> {
12562 let request = types::xinput::UngrabDeviceKeyRequest {
12563 grab_window,
12564 modifiers: Into::<u32>::into(modifiers.into()) as _,
12565 modifier_device: Into::<u32>::into(modifier_device.into()) as _,
12566 key: Into::<u32>::into(key.into()) as _,
12567 grabbed_device,
12568 };
12569 let cookie = self.send_void_request(request, false)?;
12570 self.wait_for_reply(cookie)
12571 }
12572 #[cfg(feature = "xinput")]
12573 fn xinput_grab_device_button(
12574 &mut self,
12575 grab_window: types::xproto::Window,
12576 grabbed_device: types::Card8,
12577 modifier_device: impl Into<types::ModifierDevice>,
12578 modifiers: impl Into<types::ModMask>,
12579 this_device_mode: types::GrabMode,
12580 other_device_mode: types::GrabMode,
12581 button: impl Into<types::Grab>,
12582 owner_events: types::Bool,
12583 classes: impl AsRef<[types::EventClass]>,
12584 ) -> Result<Cookie<()>> {
12585 let span = tracing::info_span!(
12586 "xinput_grab_device_button",
12587 grab_window = ?grab_window,
12588 grabbed_device = ?grabbed_device,
12589 this_device_mode = ?this_device_mode,
12590 other_device_mode = ?other_device_mode,
12591 owner_events = ?owner_events,
12592 );
12593 let _enter = span.enter();
12594 let request = types::xinput::GrabDeviceButtonRequest {
12595 grab_window,
12596 grabbed_device,
12597 modifier_device: Into::<u32>::into(modifier_device.into()) as _,
12598 modifiers: Into::<u32>::into(modifiers.into()) as _,
12599 this_device_mode,
12600 other_device_mode,
12601 button: Into::<u32>::into(button.into()) as _,
12602 owner_events,
12603 classes: Cow::Borrowed(classes.as_ref()),
12604 };
12605 let cookie = self.send_void_request(request, true);
12606 cookie
12607 }
12608 #[cfg(feature = "xinput")]
12609 fn xinput_grab_device_button_checked(
12610 &mut self,
12611 grab_window: types::xproto::Window,
12612 grabbed_device: types::Card8,
12613 modifier_device: impl Into<types::ModifierDevice>,
12614 modifiers: impl Into<types::ModMask>,
12615 this_device_mode: types::GrabMode,
12616 other_device_mode: types::GrabMode,
12617 button: impl Into<types::Grab>,
12618 owner_events: types::Bool,
12619 classes: impl AsRef<[types::EventClass]>,
12620 ) -> Result<()> {
12621 let request = types::xinput::GrabDeviceButtonRequest {
12622 grab_window,
12623 grabbed_device,
12624 modifier_device: Into::<u32>::into(modifier_device.into()) as _,
12625 modifiers: Into::<u32>::into(modifiers.into()) as _,
12626 this_device_mode,
12627 other_device_mode,
12628 button: Into::<u32>::into(button.into()) as _,
12629 owner_events,
12630 classes: Cow::Borrowed(classes.as_ref()),
12631 };
12632 let cookie = self.send_void_request(request, false)?;
12633 self.wait_for_reply(cookie)
12634 }
12635 #[cfg(feature = "xinput")]
12636 fn xinput_ungrab_device_button(
12637 &mut self,
12638 grab_window: types::xproto::Window,
12639 modifiers: impl Into<types::ModMask>,
12640 modifier_device: impl Into<types::ModifierDevice>,
12641 button: impl Into<types::Grab>,
12642 grabbed_device: types::Card8,
12643 ) -> Result<Cookie<()>> {
12644 let span = tracing::info_span!(
12645 "xinput_ungrab_device_button",
12646 grab_window = ?grab_window,
12647 grabbed_device = ?grabbed_device,
12648 );
12649 let _enter = span.enter();
12650 let request = types::xinput::UngrabDeviceButtonRequest {
12651 grab_window,
12652 modifiers: Into::<u32>::into(modifiers.into()) as _,
12653 modifier_device: Into::<u32>::into(modifier_device.into()) as _,
12654 button: Into::<u32>::into(button.into()) as _,
12655 grabbed_device,
12656 };
12657 let cookie = self.send_void_request(request, true);
12658 cookie
12659 }
12660 #[cfg(feature = "xinput")]
12661 fn xinput_ungrab_device_button_checked(
12662 &mut self,
12663 grab_window: types::xproto::Window,
12664 modifiers: impl Into<types::ModMask>,
12665 modifier_device: impl Into<types::ModifierDevice>,
12666 button: impl Into<types::Grab>,
12667 grabbed_device: types::Card8,
12668 ) -> Result<()> {
12669 let request = types::xinput::UngrabDeviceButtonRequest {
12670 grab_window,
12671 modifiers: Into::<u32>::into(modifiers.into()) as _,
12672 modifier_device: Into::<u32>::into(modifier_device.into()) as _,
12673 button: Into::<u32>::into(button.into()) as _,
12674 grabbed_device,
12675 };
12676 let cookie = self.send_void_request(request, false)?;
12677 self.wait_for_reply(cookie)
12678 }
12679 #[cfg(feature = "xinput")]
12680 fn xinput_allow_device_events(
12681 &mut self,
12682 time: impl Into<types::Time>,
12683 mode: types::DeviceInputMode,
12684 device_id: types::Card8,
12685 ) -> Result<Cookie<()>> {
12686 let span = tracing::info_span!(
12687 "xinput_allow_device_events",
12688 mode = ?mode,
12689 device_id = ?device_id,
12690 );
12691 let _enter = span.enter();
12692 let request = types::xinput::AllowDeviceEventsRequest {
12693 time: Into::<u32>::into(time.into()) as _,
12694 mode,
12695 device_id,
12696 };
12697 let cookie = self.send_void_request(request, true);
12698 cookie
12699 }
12700 #[cfg(feature = "xinput")]
12701 fn xinput_allow_device_events_checked(
12702 &mut self,
12703 time: impl Into<types::Time>,
12704 mode: types::DeviceInputMode,
12705 device_id: types::Card8,
12706 ) -> Result<()> {
12707 let request = types::xinput::AllowDeviceEventsRequest {
12708 time: Into::<u32>::into(time.into()) as _,
12709 mode,
12710 device_id,
12711 };
12712 let cookie = self.send_void_request(request, false)?;
12713 self.wait_for_reply(cookie)
12714 }
12715 #[cfg(feature = "xinput")]
12716 fn xinput_get_device_focus(
12717 &mut self,
12718 device_id: types::Card8,
12719 ) -> Result<Cookie<types::xinput::GetDeviceFocusReply>> {
12720 let span = tracing::info_span!(
12721 "xinput_get_device_focus",
12722 device_id = ?device_id,
12723 );
12724 let _enter = span.enter();
12725 let request = types::xinput::GetDeviceFocusRequest { device_id };
12726 let cookie = self.send_reply_request(request);
12727 cookie
12728 }
12729 #[cfg(feature = "xinput")]
12730 fn xinput_get_device_focus_immediate(
12731 &mut self,
12732 device_id: types::Card8,
12733 ) -> Result<types::xinput::GetDeviceFocusReply> {
12734 let request = types::xinput::GetDeviceFocusRequest { device_id };
12735 let cookie = self.send_reply_request(request)?;
12736 self.wait_for_reply(cookie)
12737 }
12738 #[cfg(feature = "xinput")]
12739 fn xinput_set_device_focus(
12740 &mut self,
12741 focus: impl Into<types::InputFocus>,
12742 time: impl Into<types::Time>,
12743 revert_to: types::InputFocus,
12744 device_id: types::Card8,
12745 ) -> Result<Cookie<()>> {
12746 let span = tracing::info_span!(
12747 "xinput_set_device_focus",
12748 revert_to = ?revert_to,
12749 device_id = ?device_id,
12750 );
12751 let _enter = span.enter();
12752 let request = types::xinput::SetDeviceFocusRequest {
12753 focus: Into::<u32>::into(focus.into()) as _,
12754 time: Into::<u32>::into(time.into()) as _,
12755 revert_to,
12756 device_id,
12757 };
12758 let cookie = self.send_void_request(request, true);
12759 cookie
12760 }
12761 #[cfg(feature = "xinput")]
12762 fn xinput_set_device_focus_checked(
12763 &mut self,
12764 focus: impl Into<types::InputFocus>,
12765 time: impl Into<types::Time>,
12766 revert_to: types::InputFocus,
12767 device_id: types::Card8,
12768 ) -> Result<()> {
12769 let request = types::xinput::SetDeviceFocusRequest {
12770 focus: Into::<u32>::into(focus.into()) as _,
12771 time: Into::<u32>::into(time.into()) as _,
12772 revert_to,
12773 device_id,
12774 };
12775 let cookie = self.send_void_request(request, false)?;
12776 self.wait_for_reply(cookie)
12777 }
12778 #[cfg(feature = "xinput")]
12779 fn xinput_get_feedback_control(
12780 &mut self,
12781 device_id: types::Card8,
12782 ) -> Result<Cookie<types::xinput::GetFeedbackControlReply>> {
12783 let span = tracing::info_span!(
12784 "xinput_get_feedback_control",
12785 device_id = ?device_id,
12786 );
12787 let _enter = span.enter();
12788 let request = types::xinput::GetFeedbackControlRequest { device_id };
12789 let cookie = self.send_reply_request(request);
12790 cookie
12791 }
12792 #[cfg(feature = "xinput")]
12793 fn xinput_get_feedback_control_immediate(
12794 &mut self,
12795 device_id: types::Card8,
12796 ) -> Result<types::xinput::GetFeedbackControlReply> {
12797 let request = types::xinput::GetFeedbackControlRequest { device_id };
12798 let cookie = self.send_reply_request(request)?;
12799 self.wait_for_reply(cookie)
12800 }
12801 #[cfg(feature = "xinput")]
12802 fn xinput_change_feedback_control(
12803 &mut self,
12804 mask: impl Into<types::ChangeFeedbackControlMask>,
12805 device_id: types::Card8,
12806 feedback_id: types::Card8,
12807 feedback: types::FeedbackCtl,
12808 ) -> Result<Cookie<()>> {
12809 let span = tracing::info_span!(
12810 "xinput_change_feedback_control",
12811 device_id = ?device_id,
12812 feedback_id = ?feedback_id,
12813 feedback = ?feedback,
12814 );
12815 let _enter = span.enter();
12816 let request = types::xinput::ChangeFeedbackControlRequest {
12817 mask: Into::<u32>::into(mask.into()) as _,
12818 device_id,
12819 feedback_id,
12820 feedback,
12821 };
12822 let cookie = self.send_void_request(request, true);
12823 cookie
12824 }
12825 #[cfg(feature = "xinput")]
12826 fn xinput_change_feedback_control_checked(
12827 &mut self,
12828 mask: impl Into<types::ChangeFeedbackControlMask>,
12829 device_id: types::Card8,
12830 feedback_id: types::Card8,
12831 feedback: types::FeedbackCtl,
12832 ) -> Result<()> {
12833 let request = types::xinput::ChangeFeedbackControlRequest {
12834 mask: Into::<u32>::into(mask.into()) as _,
12835 device_id,
12836 feedback_id,
12837 feedback,
12838 };
12839 let cookie = self.send_void_request(request, false)?;
12840 self.wait_for_reply(cookie)
12841 }
12842 #[cfg(feature = "xinput")]
12843 fn xinput_get_device_key_mapping(
12844 &mut self,
12845 device_id: types::Card8,
12846 first_keycode: types::KeyCode,
12847 count: types::Card8,
12848 ) -> Result<Cookie<types::xinput::GetDeviceKeyMappingReply>> {
12849 let span = tracing::info_span!(
12850 "xinput_get_device_key_mapping",
12851 device_id = ?device_id,
12852 first_keycode = ?first_keycode,
12853 count = ?count,
12854 );
12855 let _enter = span.enter();
12856 let request = types::xinput::GetDeviceKeyMappingRequest {
12857 device_id,
12858 first_keycode,
12859 count,
12860 };
12861 let cookie = self.send_reply_request(request);
12862 cookie
12863 }
12864 #[cfg(feature = "xinput")]
12865 fn xinput_get_device_key_mapping_immediate(
12866 &mut self,
12867 device_id: types::Card8,
12868 first_keycode: types::KeyCode,
12869 count: types::Card8,
12870 ) -> Result<types::xinput::GetDeviceKeyMappingReply> {
12871 let request = types::xinput::GetDeviceKeyMappingRequest {
12872 device_id,
12873 first_keycode,
12874 count,
12875 };
12876 let cookie = self.send_reply_request(request)?;
12877 self.wait_for_reply(cookie)
12878 }
12879 #[cfg(feature = "xinput")]
12880 fn xinput_change_device_key_mapping(
12881 &mut self,
12882 device_id: types::Card8,
12883 first_keycode: types::KeyCode,
12884 keysyms_per_keycode: types::Card8,
12885 keycode_count: types::Card8,
12886 keysyms: impl AsRef<[types::Keysym]>,
12887 ) -> Result<Cookie<()>> {
12888 let span = tracing::info_span!(
12889 "xinput_change_device_key_mapping",
12890 device_id = ?device_id,
12891 first_keycode = ?first_keycode,
12892 keysyms_per_keycode = ?keysyms_per_keycode,
12893 keycode_count = ?keycode_count,
12894 );
12895 let _enter = span.enter();
12896 let request = types::xinput::ChangeDeviceKeyMappingRequest {
12897 device_id,
12898 first_keycode,
12899 keysyms_per_keycode,
12900 keycode_count,
12901 keysyms: Cow::Borrowed(keysyms.as_ref()),
12902 };
12903 let cookie = self.send_void_request(request, true);
12904 cookie
12905 }
12906 #[cfg(feature = "xinput")]
12907 fn xinput_change_device_key_mapping_checked(
12908 &mut self,
12909 device_id: types::Card8,
12910 first_keycode: types::KeyCode,
12911 keysyms_per_keycode: types::Card8,
12912 keycode_count: types::Card8,
12913 keysyms: impl AsRef<[types::Keysym]>,
12914 ) -> Result<()> {
12915 let request = types::xinput::ChangeDeviceKeyMappingRequest {
12916 device_id,
12917 first_keycode,
12918 keysyms_per_keycode,
12919 keycode_count,
12920 keysyms: Cow::Borrowed(keysyms.as_ref()),
12921 };
12922 let cookie = self.send_void_request(request, false)?;
12923 self.wait_for_reply(cookie)
12924 }
12925 #[cfg(feature = "xinput")]
12926 fn xinput_get_device_modifier_mapping(
12927 &mut self,
12928 device_id: types::Card8,
12929 ) -> Result<Cookie<types::xinput::GetDeviceModifierMappingReply>> {
12930 let span = tracing::info_span!(
12931 "xinput_get_device_modifier_mapping",
12932 device_id = ?device_id,
12933 );
12934 let _enter = span.enter();
12935 let request = types::xinput::GetDeviceModifierMappingRequest { device_id };
12936 let cookie = self.send_reply_request(request);
12937 cookie
12938 }
12939 #[cfg(feature = "xinput")]
12940 fn xinput_get_device_modifier_mapping_immediate(
12941 &mut self,
12942 device_id: types::Card8,
12943 ) -> Result<types::xinput::GetDeviceModifierMappingReply> {
12944 let request = types::xinput::GetDeviceModifierMappingRequest { device_id };
12945 let cookie = self.send_reply_request(request)?;
12946 self.wait_for_reply(cookie)
12947 }
12948 #[cfg(feature = "xinput")]
12949 fn xinput_set_device_modifier_mapping(
12950 &mut self,
12951 device_id: types::Card8,
12952 keymaps: impl AsRef<[types::Card8]>,
12953 ) -> Result<Cookie<types::xinput::SetDeviceModifierMappingReply>> {
12954 let span = tracing::info_span!(
12955 "xinput_set_device_modifier_mapping",
12956 device_id = ?device_id,
12957 );
12958 let _enter = span.enter();
12959 let request = types::xinput::SetDeviceModifierMappingRequest {
12960 device_id,
12961 keymaps: Cow::Borrowed(keymaps.as_ref()),
12962 };
12963 let cookie = self.send_reply_request(request);
12964 cookie
12965 }
12966 #[cfg(feature = "xinput")]
12967 fn xinput_set_device_modifier_mapping_immediate(
12968 &mut self,
12969 device_id: types::Card8,
12970 keymaps: impl AsRef<[types::Card8]>,
12971 ) -> Result<types::xinput::SetDeviceModifierMappingReply> {
12972 let request = types::xinput::SetDeviceModifierMappingRequest {
12973 device_id,
12974 keymaps: Cow::Borrowed(keymaps.as_ref()),
12975 };
12976 let cookie = self.send_reply_request(request)?;
12977 self.wait_for_reply(cookie)
12978 }
12979 #[cfg(feature = "xinput")]
12980 fn xinput_get_device_button_mapping(
12981 &mut self,
12982 device_id: types::Card8,
12983 ) -> Result<Cookie<types::xinput::GetDeviceButtonMappingReply>> {
12984 let span = tracing::info_span!(
12985 "xinput_get_device_button_mapping",
12986 device_id = ?device_id,
12987 );
12988 let _enter = span.enter();
12989 let request = types::xinput::GetDeviceButtonMappingRequest { device_id };
12990 let cookie = self.send_reply_request(request);
12991 cookie
12992 }
12993 #[cfg(feature = "xinput")]
12994 fn xinput_get_device_button_mapping_immediate(
12995 &mut self,
12996 device_id: types::Card8,
12997 ) -> Result<types::xinput::GetDeviceButtonMappingReply> {
12998 let request = types::xinput::GetDeviceButtonMappingRequest { device_id };
12999 let cookie = self.send_reply_request(request)?;
13000 self.wait_for_reply(cookie)
13001 }
13002 #[cfg(feature = "xinput")]
13003 fn xinput_set_device_button_mapping(
13004 &mut self,
13005 device_id: types::Card8,
13006 map: impl AsRef<[types::Card8]>,
13007 ) -> Result<Cookie<types::xinput::SetDeviceButtonMappingReply>> {
13008 let span = tracing::info_span!(
13009 "xinput_set_device_button_mapping",
13010 device_id = ?device_id,
13011 );
13012 let _enter = span.enter();
13013 let request = types::xinput::SetDeviceButtonMappingRequest {
13014 device_id,
13015 map: Cow::Borrowed(map.as_ref()),
13016 };
13017 let cookie = self.send_reply_request(request);
13018 cookie
13019 }
13020 #[cfg(feature = "xinput")]
13021 fn xinput_set_device_button_mapping_immediate(
13022 &mut self,
13023 device_id: types::Card8,
13024 map: impl AsRef<[types::Card8]>,
13025 ) -> Result<types::xinput::SetDeviceButtonMappingReply> {
13026 let request = types::xinput::SetDeviceButtonMappingRequest {
13027 device_id,
13028 map: Cow::Borrowed(map.as_ref()),
13029 };
13030 let cookie = self.send_reply_request(request)?;
13031 self.wait_for_reply(cookie)
13032 }
13033 #[cfg(feature = "xinput")]
13034 fn xinput_query_device_state(
13035 &mut self,
13036 device_id: types::Card8,
13037 ) -> Result<Cookie<types::xinput::QueryDeviceStateReply>> {
13038 let span = tracing::info_span!(
13039 "xinput_query_device_state",
13040 device_id = ?device_id,
13041 );
13042 let _enter = span.enter();
13043 let request = types::xinput::QueryDeviceStateRequest { device_id };
13044 let cookie = self.send_reply_request(request);
13045 cookie
13046 }
13047 #[cfg(feature = "xinput")]
13048 fn xinput_query_device_state_immediate(
13049 &mut self,
13050 device_id: types::Card8,
13051 ) -> Result<types::xinput::QueryDeviceStateReply> {
13052 let request = types::xinput::QueryDeviceStateRequest { device_id };
13053 let cookie = self.send_reply_request(request)?;
13054 self.wait_for_reply(cookie)
13055 }
13056 #[cfg(feature = "xinput")]
13057 fn xinput_device_bell(
13058 &mut self,
13059 device_id: types::Card8,
13060 feedback_id: types::Card8,
13061 feedback_class: types::Card8,
13062 percent: types::Int8,
13063 ) -> Result<Cookie<()>> {
13064 let span = tracing::info_span!(
13065 "xinput_device_bell",
13066 device_id = ?device_id,
13067 feedback_id = ?feedback_id,
13068 feedback_class = ?feedback_class,
13069 percent = ?percent,
13070 );
13071 let _enter = span.enter();
13072 let request = types::xinput::DeviceBellRequest {
13073 device_id,
13074 feedback_id,
13075 feedback_class,
13076 percent,
13077 };
13078 let cookie = self.send_void_request(request, true);
13079 cookie
13080 }
13081 #[cfg(feature = "xinput")]
13082 fn xinput_device_bell_checked(
13083 &mut self,
13084 device_id: types::Card8,
13085 feedback_id: types::Card8,
13086 feedback_class: types::Card8,
13087 percent: types::Int8,
13088 ) -> Result<()> {
13089 let request = types::xinput::DeviceBellRequest {
13090 device_id,
13091 feedback_id,
13092 feedback_class,
13093 percent,
13094 };
13095 let cookie = self.send_void_request(request, false)?;
13096 self.wait_for_reply(cookie)
13097 }
13098 #[cfg(feature = "xinput")]
13099 fn xinput_set_device_valuators(
13100 &mut self,
13101 device_id: types::Card8,
13102 first_valuator: types::Card8,
13103 valuators: impl AsRef<[types::Int32]>,
13104 ) -> Result<Cookie<types::xinput::SetDeviceValuatorsReply>> {
13105 let span = tracing::info_span!(
13106 "xinput_set_device_valuators",
13107 device_id = ?device_id,
13108 first_valuator = ?first_valuator,
13109 );
13110 let _enter = span.enter();
13111 let request = types::xinput::SetDeviceValuatorsRequest {
13112 device_id,
13113 first_valuator,
13114 valuators: Cow::Borrowed(valuators.as_ref()),
13115 };
13116 let cookie = self.send_reply_request(request);
13117 cookie
13118 }
13119 #[cfg(feature = "xinput")]
13120 fn xinput_set_device_valuators_immediate(
13121 &mut self,
13122 device_id: types::Card8,
13123 first_valuator: types::Card8,
13124 valuators: impl AsRef<[types::Int32]>,
13125 ) -> Result<types::xinput::SetDeviceValuatorsReply> {
13126 let request = types::xinput::SetDeviceValuatorsRequest {
13127 device_id,
13128 first_valuator,
13129 valuators: Cow::Borrowed(valuators.as_ref()),
13130 };
13131 let cookie = self.send_reply_request(request)?;
13132 self.wait_for_reply(cookie)
13133 }
13134 #[cfg(feature = "xinput")]
13135 fn xinput_get_device_control(
13136 &mut self,
13137 control_id: types::DeviceControl,
13138 device_id: types::Card8,
13139 ) -> Result<Cookie<types::xinput::GetDeviceControlReply>> {
13140 let span = tracing::info_span!(
13141 "xinput_get_device_control",
13142 control_id = ?control_id,
13143 device_id = ?device_id,
13144 );
13145 let _enter = span.enter();
13146 let request = types::xinput::GetDeviceControlRequest {
13147 control_id,
13148 device_id,
13149 };
13150 let cookie = self.send_reply_request(request);
13151 cookie
13152 }
13153 #[cfg(feature = "xinput")]
13154 fn xinput_get_device_control_immediate(
13155 &mut self,
13156 control_id: types::DeviceControl,
13157 device_id: types::Card8,
13158 ) -> Result<types::xinput::GetDeviceControlReply> {
13159 let request = types::xinput::GetDeviceControlRequest {
13160 control_id,
13161 device_id,
13162 };
13163 let cookie = self.send_reply_request(request)?;
13164 self.wait_for_reply(cookie)
13165 }
13166 #[cfg(feature = "xinput")]
13167 fn xinput_change_device_control(
13168 &mut self,
13169 control_id: types::DeviceControl,
13170 device_id: types::Card8,
13171 control: types::DeviceCtl,
13172 ) -> Result<Cookie<types::xinput::ChangeDeviceControlReply>> {
13173 let span = tracing::info_span!(
13174 "xinput_change_device_control",
13175 control_id = ?control_id,
13176 device_id = ?device_id,
13177 control = ?control,
13178 );
13179 let _enter = span.enter();
13180 let request = types::xinput::ChangeDeviceControlRequest {
13181 control_id,
13182 device_id,
13183 control,
13184 };
13185 let cookie = self.send_reply_request(request);
13186 cookie
13187 }
13188 #[cfg(feature = "xinput")]
13189 fn xinput_change_device_control_immediate(
13190 &mut self,
13191 control_id: types::DeviceControl,
13192 device_id: types::Card8,
13193 control: types::DeviceCtl,
13194 ) -> Result<types::xinput::ChangeDeviceControlReply> {
13195 let request = types::xinput::ChangeDeviceControlRequest {
13196 control_id,
13197 device_id,
13198 control,
13199 };
13200 let cookie = self.send_reply_request(request)?;
13201 self.wait_for_reply(cookie)
13202 }
13203 #[cfg(feature = "xinput")]
13204 fn xinput_list_device_properties(
13205 &mut self,
13206 device_id: types::Card8,
13207 ) -> Result<Cookie<types::xinput::ListDevicePropertiesReply>> {
13208 let span = tracing::info_span!(
13209 "xinput_list_device_properties",
13210 device_id = ?device_id,
13211 );
13212 let _enter = span.enter();
13213 let request = types::xinput::ListDevicePropertiesRequest { device_id };
13214 let cookie = self.send_reply_request(request);
13215 cookie
13216 }
13217 #[cfg(feature = "xinput")]
13218 fn xinput_list_device_properties_immediate(
13219 &mut self,
13220 device_id: types::Card8,
13221 ) -> Result<types::xinput::ListDevicePropertiesReply> {
13222 let request = types::xinput::ListDevicePropertiesRequest { device_id };
13223 let cookie = self.send_reply_request(request)?;
13224 self.wait_for_reply(cookie)
13225 }
13226 #[cfg(feature = "xinput")]
13227 fn xinput_change_device_property(
13228 &mut self,
13229 property: types::Atom,
13230 type_: types::Atom,
13231 device_id: types::Card8,
13232 mode: types::PropMode,
13233 num_items: types::Card32,
13234 items: impl Borrow<types::xinput::ChangeDevicePropertyAux>,
13235 ) -> Result<Cookie<()>> {
13236 let span = tracing::info_span!(
13237 "xinput_change_device_property",
13238 property = ?property,
13239 type_ = ?type_,
13240 device_id = ?device_id,
13241 mode = ?mode,
13242 num_items = ?num_items,
13243 );
13244 let _enter = span.enter();
13245 let request = types::xinput::ChangeDevicePropertyRequest {
13246 property,
13247 type_,
13248 device_id,
13249 mode,
13250 num_items,
13251 items: Cow::Borrowed(items.borrow()),
13252 };
13253 let cookie = self.send_void_request(request, true);
13254 cookie
13255 }
13256 #[cfg(feature = "xinput")]
13257 fn xinput_change_device_property_checked(
13258 &mut self,
13259 property: types::Atom,
13260 type_: types::Atom,
13261 device_id: types::Card8,
13262 mode: types::PropMode,
13263 num_items: types::Card32,
13264 items: impl Borrow<types::xinput::ChangeDevicePropertyAux>,
13265 ) -> Result<()> {
13266 let request = types::xinput::ChangeDevicePropertyRequest {
13267 property,
13268 type_,
13269 device_id,
13270 mode,
13271 num_items,
13272 items: Cow::Borrowed(items.borrow()),
13273 };
13274 let cookie = self.send_void_request(request, false)?;
13275 self.wait_for_reply(cookie)
13276 }
13277 #[cfg(feature = "xinput")]
13278 fn xinput_delete_device_property(
13279 &mut self,
13280 property: types::Atom,
13281 device_id: types::Card8,
13282 ) -> Result<Cookie<()>> {
13283 let span = tracing::info_span!(
13284 "xinput_delete_device_property",
13285 property = ?property,
13286 device_id = ?device_id,
13287 );
13288 let _enter = span.enter();
13289 let request = types::xinput::DeleteDevicePropertyRequest {
13290 property,
13291 device_id,
13292 };
13293 let cookie = self.send_void_request(request, true);
13294 cookie
13295 }
13296 #[cfg(feature = "xinput")]
13297 fn xinput_delete_device_property_checked(
13298 &mut self,
13299 property: types::Atom,
13300 device_id: types::Card8,
13301 ) -> Result<()> {
13302 let request = types::xinput::DeleteDevicePropertyRequest {
13303 property,
13304 device_id,
13305 };
13306 let cookie = self.send_void_request(request, false)?;
13307 self.wait_for_reply(cookie)
13308 }
13309 #[cfg(feature = "xinput")]
13310 fn xinput_get_device_property(
13311 &mut self,
13312 property: types::Atom,
13313 type_: types::Atom,
13314 offset: types::Card32,
13315 len: types::Card32,
13316 device_id: types::Card8,
13317 delete: types::Bool,
13318 ) -> Result<Cookie<types::xinput::GetDevicePropertyReply>> {
13319 let span = tracing::info_span!(
13320 "xinput_get_device_property",
13321 property = ?property,
13322 type_ = ?type_,
13323 offset = ?offset,
13324 len = ?len,
13325 device_id = ?device_id,
13326 delete = ?delete,
13327 );
13328 let _enter = span.enter();
13329 let request = types::xinput::GetDevicePropertyRequest {
13330 property,
13331 type_,
13332 offset,
13333 len,
13334 device_id,
13335 delete,
13336 };
13337 let cookie = self.send_reply_request(request);
13338 cookie
13339 }
13340 #[cfg(feature = "xinput")]
13341 fn xinput_get_device_property_immediate(
13342 &mut self,
13343 property: types::Atom,
13344 type_: types::Atom,
13345 offset: types::Card32,
13346 len: types::Card32,
13347 device_id: types::Card8,
13348 delete: types::Bool,
13349 ) -> Result<types::xinput::GetDevicePropertyReply> {
13350 let request = types::xinput::GetDevicePropertyRequest {
13351 property,
13352 type_,
13353 offset,
13354 len,
13355 device_id,
13356 delete,
13357 };
13358 let cookie = self.send_reply_request(request)?;
13359 self.wait_for_reply(cookie)
13360 }
13361 #[cfg(feature = "xinput")]
13362 fn xinput_xi_query_pointer(
13363 &mut self,
13364 window: types::xproto::Window,
13365 deviceid: impl Into<types::Device>,
13366 ) -> Result<Cookie<types::xinput::XIQueryPointerReply>> {
13367 let span = tracing::info_span!(
13368 "xinput_xi_query_pointer",
13369 window = ?window,
13370 );
13371 let _enter = span.enter();
13372 let request = types::xinput::XIQueryPointerRequest {
13373 window,
13374 deviceid: Into::<u32>::into(deviceid.into()) as _,
13375 };
13376 let cookie = self.send_reply_request(request);
13377 cookie
13378 }
13379 #[cfg(feature = "xinput")]
13380 fn xinput_xi_query_pointer_immediate(
13381 &mut self,
13382 window: types::xproto::Window,
13383 deviceid: impl Into<types::Device>,
13384 ) -> Result<types::xinput::XIQueryPointerReply> {
13385 let request = types::xinput::XIQueryPointerRequest {
13386 window,
13387 deviceid: Into::<u32>::into(deviceid.into()) as _,
13388 };
13389 let cookie = self.send_reply_request(request)?;
13390 self.wait_for_reply(cookie)
13391 }
13392 #[cfg(feature = "xinput")]
13393 fn xinput_xi_warp_pointer(
13394 &mut self,
13395 src_win: types::xproto::Window,
13396 dst_win: types::xproto::Window,
13397 src_x: types::Fp1616,
13398 src_y: types::Fp1616,
13399 src_width: types::Card16,
13400 src_height: types::Card16,
13401 dst_x: types::Fp1616,
13402 dst_y: types::Fp1616,
13403 deviceid: impl Into<types::Device>,
13404 ) -> Result<Cookie<()>> {
13405 let span = tracing::info_span!(
13406 "xinput_xi_warp_pointer",
13407 src_win = ?src_win,
13408 dst_win = ?dst_win,
13409 src_x = ?src_x,
13410 src_y = ?src_y,
13411 src_width = ?src_width,
13412 src_height = ?src_height,
13413 dst_x = ?dst_x,
13414 dst_y = ?dst_y,
13415 );
13416 let _enter = span.enter();
13417 let request = types::xinput::XIWarpPointerRequest {
13418 src_win,
13419 dst_win,
13420 src_x,
13421 src_y,
13422 src_width,
13423 src_height,
13424 dst_x,
13425 dst_y,
13426 deviceid: Into::<u32>::into(deviceid.into()) as _,
13427 };
13428 let cookie = self.send_void_request(request, true);
13429 cookie
13430 }
13431 #[cfg(feature = "xinput")]
13432 fn xinput_xi_warp_pointer_checked(
13433 &mut self,
13434 src_win: types::xproto::Window,
13435 dst_win: types::xproto::Window,
13436 src_x: types::Fp1616,
13437 src_y: types::Fp1616,
13438 src_width: types::Card16,
13439 src_height: types::Card16,
13440 dst_x: types::Fp1616,
13441 dst_y: types::Fp1616,
13442 deviceid: impl Into<types::Device>,
13443 ) -> Result<()> {
13444 let request = types::xinput::XIWarpPointerRequest {
13445 src_win,
13446 dst_win,
13447 src_x,
13448 src_y,
13449 src_width,
13450 src_height,
13451 dst_x,
13452 dst_y,
13453 deviceid: Into::<u32>::into(deviceid.into()) as _,
13454 };
13455 let cookie = self.send_void_request(request, false)?;
13456 self.wait_for_reply(cookie)
13457 }
13458 #[cfg(feature = "xinput")]
13459 fn xinput_xi_change_cursor(
13460 &mut self,
13461 window: types::xproto::Window,
13462 cursor: types::xproto::Cursor,
13463 deviceid: impl Into<types::Device>,
13464 ) -> Result<Cookie<()>> {
13465 let span = tracing::info_span!(
13466 "xinput_xi_change_cursor",
13467 window = ?window,
13468 cursor = ?cursor,
13469 );
13470 let _enter = span.enter();
13471 let request = types::xinput::XIChangeCursorRequest {
13472 window,
13473 cursor,
13474 deviceid: Into::<u32>::into(deviceid.into()) as _,
13475 };
13476 let cookie = self.send_void_request(request, true);
13477 cookie
13478 }
13479 #[cfg(feature = "xinput")]
13480 fn xinput_xi_change_cursor_checked(
13481 &mut self,
13482 window: types::xproto::Window,
13483 cursor: types::xproto::Cursor,
13484 deviceid: impl Into<types::Device>,
13485 ) -> Result<()> {
13486 let request = types::xinput::XIChangeCursorRequest {
13487 window,
13488 cursor,
13489 deviceid: Into::<u32>::into(deviceid.into()) as _,
13490 };
13491 let cookie = self.send_void_request(request, false)?;
13492 self.wait_for_reply(cookie)
13493 }
13494 #[cfg(feature = "xinput")]
13495 fn xinput_xi_change_hierarchy(
13496 &mut self,
13497 changes: impl AsRef<[types::HierarchyChange]>,
13498 ) -> Result<Cookie<()>> {
13499 let span = tracing::info_span!("xinput_xi_change_hierarchy",);
13500 let _enter = span.enter();
13501 let request = types::xinput::XIChangeHierarchyRequest {
13502 changes: Cow::Borrowed(changes.as_ref()),
13503 };
13504 let cookie = self.send_void_request(request, true);
13505 cookie
13506 }
13507 #[cfg(feature = "xinput")]
13508 fn xinput_xi_change_hierarchy_checked(
13509 &mut self,
13510 changes: impl AsRef<[types::HierarchyChange]>,
13511 ) -> Result<()> {
13512 let request = types::xinput::XIChangeHierarchyRequest {
13513 changes: Cow::Borrowed(changes.as_ref()),
13514 };
13515 let cookie = self.send_void_request(request, false)?;
13516 self.wait_for_reply(cookie)
13517 }
13518 #[cfg(feature = "xinput")]
13519 fn xinput_xi_set_client_pointer(
13520 &mut self,
13521 window: types::xproto::Window,
13522 deviceid: impl Into<types::Device>,
13523 ) -> Result<Cookie<()>> {
13524 let span = tracing::info_span!(
13525 "xinput_xi_set_client_pointer",
13526 window = ?window,
13527 );
13528 let _enter = span.enter();
13529 let request = types::xinput::XISetClientPointerRequest {
13530 window,
13531 deviceid: Into::<u32>::into(deviceid.into()) as _,
13532 };
13533 let cookie = self.send_void_request(request, true);
13534 cookie
13535 }
13536 #[cfg(feature = "xinput")]
13537 fn xinput_xi_set_client_pointer_checked(
13538 &mut self,
13539 window: types::xproto::Window,
13540 deviceid: impl Into<types::Device>,
13541 ) -> Result<()> {
13542 let request = types::xinput::XISetClientPointerRequest {
13543 window,
13544 deviceid: Into::<u32>::into(deviceid.into()) as _,
13545 };
13546 let cookie = self.send_void_request(request, false)?;
13547 self.wait_for_reply(cookie)
13548 }
13549 #[cfg(feature = "xinput")]
13550 fn xinput_xi_get_client_pointer(
13551 &mut self,
13552 window: types::xproto::Window,
13553 ) -> Result<Cookie<types::xinput::XIGetClientPointerReply>> {
13554 let span = tracing::info_span!(
13555 "xinput_xi_get_client_pointer",
13556 window = ?window,
13557 );
13558 let _enter = span.enter();
13559 let request = types::xinput::XIGetClientPointerRequest { window };
13560 let cookie = self.send_reply_request(request);
13561 cookie
13562 }
13563 #[cfg(feature = "xinput")]
13564 fn xinput_xi_get_client_pointer_immediate(
13565 &mut self,
13566 window: types::xproto::Window,
13567 ) -> Result<types::xinput::XIGetClientPointerReply> {
13568 let request = types::xinput::XIGetClientPointerRequest { window };
13569 let cookie = self.send_reply_request(request)?;
13570 self.wait_for_reply(cookie)
13571 }
13572 #[cfg(feature = "xinput")]
13573 fn xinput_xi_select_events(
13574 &mut self,
13575 window: types::xproto::Window,
13576 masks: impl AsRef<[types::xinput::EventMask]>,
13577 ) -> Result<Cookie<()>> {
13578 let span = tracing::info_span!(
13579 "xinput_xi_select_events",
13580 window = ?window,
13581 );
13582 let _enter = span.enter();
13583 let request = types::xinput::XISelectEventsRequest {
13584 window,
13585 masks: Cow::Borrowed(masks.as_ref()),
13586 };
13587 let cookie = self.send_void_request(request, true);
13588 cookie
13589 }
13590 #[cfg(feature = "xinput")]
13591 fn xinput_xi_select_events_checked(
13592 &mut self,
13593 window: types::xproto::Window,
13594 masks: impl AsRef<[types::xinput::EventMask]>,
13595 ) -> Result<()> {
13596 let request = types::xinput::XISelectEventsRequest {
13597 window,
13598 masks: Cow::Borrowed(masks.as_ref()),
13599 };
13600 let cookie = self.send_void_request(request, false)?;
13601 self.wait_for_reply(cookie)
13602 }
13603 #[cfg(feature = "xinput")]
13604 fn xinput_xi_query_version(
13605 &mut self,
13606 major_version: types::Card16,
13607 minor_version: types::Card16,
13608 ) -> Result<Cookie<types::xinput::XIQueryVersionReply>> {
13609 let span = tracing::info_span!(
13610 "xinput_xi_query_version",
13611 major_version = ?major_version,
13612 minor_version = ?minor_version,
13613 );
13614 let _enter = span.enter();
13615 let request = types::xinput::XIQueryVersionRequest {
13616 major_version,
13617 minor_version,
13618 };
13619 let cookie = self.send_reply_request(request);
13620 cookie
13621 }
13622 #[cfg(feature = "xinput")]
13623 fn xinput_xi_query_version_immediate(
13624 &mut self,
13625 major_version: types::Card16,
13626 minor_version: types::Card16,
13627 ) -> Result<types::xinput::XIQueryVersionReply> {
13628 let request = types::xinput::XIQueryVersionRequest {
13629 major_version,
13630 minor_version,
13631 };
13632 let cookie = self.send_reply_request(request)?;
13633 self.wait_for_reply(cookie)
13634 }
13635 #[cfg(feature = "xinput")]
13636 fn xinput_xi_query_device(
13637 &mut self,
13638 deviceid: impl Into<types::Device>,
13639 ) -> Result<Cookie<types::xinput::XIQueryDeviceReply>> {
13640 let span = tracing::info_span!("xinput_xi_query_device",);
13641 let _enter = span.enter();
13642 let request = types::xinput::XIQueryDeviceRequest {
13643 deviceid: Into::<u32>::into(deviceid.into()) as _,
13644 };
13645 let cookie = self.send_reply_request(request);
13646 cookie
13647 }
13648 #[cfg(feature = "xinput")]
13649 fn xinput_xi_query_device_immediate(
13650 &mut self,
13651 deviceid: impl Into<types::Device>,
13652 ) -> Result<types::xinput::XIQueryDeviceReply> {
13653 let request = types::xinput::XIQueryDeviceRequest {
13654 deviceid: Into::<u32>::into(deviceid.into()) as _,
13655 };
13656 let cookie = self.send_reply_request(request)?;
13657 self.wait_for_reply(cookie)
13658 }
13659 #[cfg(feature = "xinput")]
13660 fn xinput_xi_set_focus(
13661 &mut self,
13662 window: types::xproto::Window,
13663 time: impl Into<types::Time>,
13664 deviceid: impl Into<types::Device>,
13665 ) -> Result<Cookie<()>> {
13666 let span = tracing::info_span!(
13667 "xinput_xi_set_focus",
13668 window = ?window,
13669 );
13670 let _enter = span.enter();
13671 let request = types::xinput::XISetFocusRequest {
13672 window,
13673 time: Into::<u32>::into(time.into()) as _,
13674 deviceid: Into::<u32>::into(deviceid.into()) as _,
13675 };
13676 let cookie = self.send_void_request(request, true);
13677 cookie
13678 }
13679 #[cfg(feature = "xinput")]
13680 fn xinput_xi_set_focus_checked(
13681 &mut self,
13682 window: types::xproto::Window,
13683 time: impl Into<types::Time>,
13684 deviceid: impl Into<types::Device>,
13685 ) -> Result<()> {
13686 let request = types::xinput::XISetFocusRequest {
13687 window,
13688 time: Into::<u32>::into(time.into()) as _,
13689 deviceid: Into::<u32>::into(deviceid.into()) as _,
13690 };
13691 let cookie = self.send_void_request(request, false)?;
13692 self.wait_for_reply(cookie)
13693 }
13694 #[cfg(feature = "xinput")]
13695 fn xinput_xi_get_focus(
13696 &mut self,
13697 deviceid: impl Into<types::Device>,
13698 ) -> Result<Cookie<types::xinput::XIGetFocusReply>> {
13699 let span = tracing::info_span!("xinput_xi_get_focus",);
13700 let _enter = span.enter();
13701 let request = types::xinput::XIGetFocusRequest {
13702 deviceid: Into::<u32>::into(deviceid.into()) as _,
13703 };
13704 let cookie = self.send_reply_request(request);
13705 cookie
13706 }
13707 #[cfg(feature = "xinput")]
13708 fn xinput_xi_get_focus_immediate(
13709 &mut self,
13710 deviceid: impl Into<types::Device>,
13711 ) -> Result<types::xinput::XIGetFocusReply> {
13712 let request = types::xinput::XIGetFocusRequest {
13713 deviceid: Into::<u32>::into(deviceid.into()) as _,
13714 };
13715 let cookie = self.send_reply_request(request)?;
13716 self.wait_for_reply(cookie)
13717 }
13718 #[cfg(feature = "xinput")]
13719 fn xinput_xi_grab_device(
13720 &mut self,
13721 window: types::xproto::Window,
13722 time: impl Into<types::Time>,
13723 cursor: types::xproto::Cursor,
13724 deviceid: impl Into<types::Device>,
13725 mode: types::GrabMode,
13726 paired_device_mode: types::GrabMode,
13727 owner_events: types::GrabOwner,
13728 mask: impl AsRef<[types::Card32]>,
13729 ) -> Result<Cookie<types::xinput::XIGrabDeviceReply>> {
13730 let span = tracing::info_span!(
13731 "xinput_xi_grab_device",
13732 window = ?window,
13733 cursor = ?cursor,
13734 mode = ?mode,
13735 paired_device_mode = ?paired_device_mode,
13736 owner_events = ?owner_events,
13737 );
13738 let _enter = span.enter();
13739 let request = types::xinput::XIGrabDeviceRequest {
13740 window,
13741 time: Into::<u32>::into(time.into()) as _,
13742 cursor,
13743 deviceid: Into::<u32>::into(deviceid.into()) as _,
13744 mode,
13745 paired_device_mode,
13746 owner_events,
13747 mask: Cow::Borrowed(mask.as_ref()),
13748 };
13749 let cookie = self.send_reply_request(request);
13750 cookie
13751 }
13752 #[cfg(feature = "xinput")]
13753 fn xinput_xi_grab_device_immediate(
13754 &mut self,
13755 window: types::xproto::Window,
13756 time: impl Into<types::Time>,
13757 cursor: types::xproto::Cursor,
13758 deviceid: impl Into<types::Device>,
13759 mode: types::GrabMode,
13760 paired_device_mode: types::GrabMode,
13761 owner_events: types::GrabOwner,
13762 mask: impl AsRef<[types::Card32]>,
13763 ) -> Result<types::xinput::XIGrabDeviceReply> {
13764 let request = types::xinput::XIGrabDeviceRequest {
13765 window,
13766 time: Into::<u32>::into(time.into()) as _,
13767 cursor,
13768 deviceid: Into::<u32>::into(deviceid.into()) as _,
13769 mode,
13770 paired_device_mode,
13771 owner_events,
13772 mask: Cow::Borrowed(mask.as_ref()),
13773 };
13774 let cookie = self.send_reply_request(request)?;
13775 self.wait_for_reply(cookie)
13776 }
13777 #[cfg(feature = "xinput")]
13778 fn xinput_xi_ungrab_device(
13779 &mut self,
13780 time: impl Into<types::Time>,
13781 deviceid: impl Into<types::Device>,
13782 ) -> Result<Cookie<()>> {
13783 let span = tracing::info_span!("xinput_xi_ungrab_device",);
13784 let _enter = span.enter();
13785 let request = types::xinput::XIUngrabDeviceRequest {
13786 time: Into::<u32>::into(time.into()) as _,
13787 deviceid: Into::<u32>::into(deviceid.into()) as _,
13788 };
13789 let cookie = self.send_void_request(request, true);
13790 cookie
13791 }
13792 #[cfg(feature = "xinput")]
13793 fn xinput_xi_ungrab_device_checked(
13794 &mut self,
13795 time: impl Into<types::Time>,
13796 deviceid: impl Into<types::Device>,
13797 ) -> Result<()> {
13798 let request = types::xinput::XIUngrabDeviceRequest {
13799 time: Into::<u32>::into(time.into()) as _,
13800 deviceid: Into::<u32>::into(deviceid.into()) as _,
13801 };
13802 let cookie = self.send_void_request(request, false)?;
13803 self.wait_for_reply(cookie)
13804 }
13805 #[cfg(feature = "xinput")]
13806 fn xinput_xi_allow_events(
13807 &mut self,
13808 time: impl Into<types::Time>,
13809 deviceid: impl Into<types::Device>,
13810 event_mode: types::EventMode,
13811 touchid: types::Card32,
13812 grab_window: types::xproto::Window,
13813 ) -> Result<Cookie<()>> {
13814 let span = tracing::info_span!(
13815 "xinput_xi_allow_events",
13816 event_mode = ?event_mode,
13817 touchid = ?touchid,
13818 grab_window = ?grab_window,
13819 );
13820 let _enter = span.enter();
13821 let request = types::xinput::XIAllowEventsRequest {
13822 time: Into::<u32>::into(time.into()) as _,
13823 deviceid: Into::<u32>::into(deviceid.into()) as _,
13824 event_mode,
13825 touchid,
13826 grab_window,
13827 };
13828 let cookie = self.send_void_request(request, true);
13829 cookie
13830 }
13831 #[cfg(feature = "xinput")]
13832 fn xinput_xi_allow_events_checked(
13833 &mut self,
13834 time: impl Into<types::Time>,
13835 deviceid: impl Into<types::Device>,
13836 event_mode: types::EventMode,
13837 touchid: types::Card32,
13838 grab_window: types::xproto::Window,
13839 ) -> Result<()> {
13840 let request = types::xinput::XIAllowEventsRequest {
13841 time: Into::<u32>::into(time.into()) as _,
13842 deviceid: Into::<u32>::into(deviceid.into()) as _,
13843 event_mode,
13844 touchid,
13845 grab_window,
13846 };
13847 let cookie = self.send_void_request(request, false)?;
13848 self.wait_for_reply(cookie)
13849 }
13850 #[cfg(feature = "xinput")]
13851 fn xinput_xi_passive_grab_device(
13852 &mut self,
13853 time: impl Into<types::Time>,
13854 grab_window: types::xproto::Window,
13855 cursor: types::xproto::Cursor,
13856 detail: types::Card32,
13857 deviceid: impl Into<types::Device>,
13858 grab_type: types::GrabType,
13859 grab_mode: types::GrabMode22,
13860 paired_device_mode: types::GrabMode,
13861 owner_events: types::GrabOwner,
13862 mask: impl AsRef<[types::Card32]>,
13863 modifiers: impl AsRef<[types::Card32]>,
13864 ) -> Result<Cookie<types::xinput::XIPassiveGrabDeviceReply>> {
13865 let span = tracing::info_span!(
13866 "xinput_xi_passive_grab_device",
13867 grab_window = ?grab_window,
13868 cursor = ?cursor,
13869 detail = ?detail,
13870 grab_type = ?grab_type,
13871 grab_mode = ?grab_mode,
13872 paired_device_mode = ?paired_device_mode,
13873 owner_events = ?owner_events,
13874 );
13875 let _enter = span.enter();
13876 let request = types::xinput::XIPassiveGrabDeviceRequest {
13877 time: Into::<u32>::into(time.into()) as _,
13878 grab_window,
13879 cursor,
13880 detail,
13881 deviceid: Into::<u32>::into(deviceid.into()) as _,
13882 grab_type,
13883 grab_mode,
13884 paired_device_mode,
13885 owner_events,
13886 mask: Cow::Borrowed(mask.as_ref()),
13887 modifiers: Cow::Borrowed(modifiers.as_ref()),
13888 };
13889 let cookie = self.send_reply_request(request);
13890 cookie
13891 }
13892 #[cfg(feature = "xinput")]
13893 fn xinput_xi_passive_grab_device_immediate(
13894 &mut self,
13895 time: impl Into<types::Time>,
13896 grab_window: types::xproto::Window,
13897 cursor: types::xproto::Cursor,
13898 detail: types::Card32,
13899 deviceid: impl Into<types::Device>,
13900 grab_type: types::GrabType,
13901 grab_mode: types::GrabMode22,
13902 paired_device_mode: types::GrabMode,
13903 owner_events: types::GrabOwner,
13904 mask: impl AsRef<[types::Card32]>,
13905 modifiers: impl AsRef<[types::Card32]>,
13906 ) -> Result<types::xinput::XIPassiveGrabDeviceReply> {
13907 let request = types::xinput::XIPassiveGrabDeviceRequest {
13908 time: Into::<u32>::into(time.into()) as _,
13909 grab_window,
13910 cursor,
13911 detail,
13912 deviceid: Into::<u32>::into(deviceid.into()) as _,
13913 grab_type,
13914 grab_mode,
13915 paired_device_mode,
13916 owner_events,
13917 mask: Cow::Borrowed(mask.as_ref()),
13918 modifiers: Cow::Borrowed(modifiers.as_ref()),
13919 };
13920 let cookie = self.send_reply_request(request)?;
13921 self.wait_for_reply(cookie)
13922 }
13923 #[cfg(feature = "xinput")]
13924 fn xinput_xi_passive_ungrab_device(
13925 &mut self,
13926 grab_window: types::xproto::Window,
13927 detail: types::Card32,
13928 deviceid: impl Into<types::Device>,
13929 grab_type: types::GrabType,
13930 modifiers: impl AsRef<[types::Card32]>,
13931 ) -> Result<Cookie<()>> {
13932 let span = tracing::info_span!(
13933 "xinput_xi_passive_ungrab_device",
13934 grab_window = ?grab_window,
13935 detail = ?detail,
13936 grab_type = ?grab_type,
13937 );
13938 let _enter = span.enter();
13939 let request = types::xinput::XIPassiveUngrabDeviceRequest {
13940 grab_window,
13941 detail,
13942 deviceid: Into::<u32>::into(deviceid.into()) as _,
13943 grab_type,
13944 modifiers: Cow::Borrowed(modifiers.as_ref()),
13945 };
13946 let cookie = self.send_void_request(request, true);
13947 cookie
13948 }
13949 #[cfg(feature = "xinput")]
13950 fn xinput_xi_passive_ungrab_device_checked(
13951 &mut self,
13952 grab_window: types::xproto::Window,
13953 detail: types::Card32,
13954 deviceid: impl Into<types::Device>,
13955 grab_type: types::GrabType,
13956 modifiers: impl AsRef<[types::Card32]>,
13957 ) -> Result<()> {
13958 let request = types::xinput::XIPassiveUngrabDeviceRequest {
13959 grab_window,
13960 detail,
13961 deviceid: Into::<u32>::into(deviceid.into()) as _,
13962 grab_type,
13963 modifiers: Cow::Borrowed(modifiers.as_ref()),
13964 };
13965 let cookie = self.send_void_request(request, false)?;
13966 self.wait_for_reply(cookie)
13967 }
13968 #[cfg(feature = "xinput")]
13969 fn xinput_xi_list_properties(
13970 &mut self,
13971 deviceid: impl Into<types::Device>,
13972 ) -> Result<Cookie<types::xinput::XIListPropertiesReply>> {
13973 let span = tracing::info_span!("xinput_xi_list_properties",);
13974 let _enter = span.enter();
13975 let request = types::xinput::XIListPropertiesRequest {
13976 deviceid: Into::<u32>::into(deviceid.into()) as _,
13977 };
13978 let cookie = self.send_reply_request(request);
13979 cookie
13980 }
13981 #[cfg(feature = "xinput")]
13982 fn xinput_xi_list_properties_immediate(
13983 &mut self,
13984 deviceid: impl Into<types::Device>,
13985 ) -> Result<types::xinput::XIListPropertiesReply> {
13986 let request = types::xinput::XIListPropertiesRequest {
13987 deviceid: Into::<u32>::into(deviceid.into()) as _,
13988 };
13989 let cookie = self.send_reply_request(request)?;
13990 self.wait_for_reply(cookie)
13991 }
13992 #[cfg(feature = "xinput")]
13993 fn xinput_xi_change_property(
13994 &mut self,
13995 deviceid: impl Into<types::Device>,
13996 mode: types::PropMode,
13997 property: types::Atom,
13998 type_: types::Atom,
13999 num_items: types::Card32,
14000 items: impl Borrow<types::xinput::XIChangePropertyAux>,
14001 ) -> Result<Cookie<()>> {
14002 let span = tracing::info_span!(
14003 "xinput_xi_change_property",
14004 mode = ?mode,
14005 property = ?property,
14006 type_ = ?type_,
14007 num_items = ?num_items,
14008 );
14009 let _enter = span.enter();
14010 let request = types::xinput::XIChangePropertyRequest {
14011 deviceid: Into::<u32>::into(deviceid.into()) as _,
14012 mode,
14013 property,
14014 type_,
14015 num_items,
14016 items: Cow::Borrowed(items.borrow()),
14017 };
14018 let cookie = self.send_void_request(request, true);
14019 cookie
14020 }
14021 #[cfg(feature = "xinput")]
14022 fn xinput_xi_change_property_checked(
14023 &mut self,
14024 deviceid: impl Into<types::Device>,
14025 mode: types::PropMode,
14026 property: types::Atom,
14027 type_: types::Atom,
14028 num_items: types::Card32,
14029 items: impl Borrow<types::xinput::XIChangePropertyAux>,
14030 ) -> Result<()> {
14031 let request = types::xinput::XIChangePropertyRequest {
14032 deviceid: Into::<u32>::into(deviceid.into()) as _,
14033 mode,
14034 property,
14035 type_,
14036 num_items,
14037 items: Cow::Borrowed(items.borrow()),
14038 };
14039 let cookie = self.send_void_request(request, false)?;
14040 self.wait_for_reply(cookie)
14041 }
14042 #[cfg(feature = "xinput")]
14043 fn xinput_xi_delete_property(
14044 &mut self,
14045 deviceid: impl Into<types::Device>,
14046 property: types::Atom,
14047 ) -> Result<Cookie<()>> {
14048 let span = tracing::info_span!(
14049 "xinput_xi_delete_property",
14050 property = ?property,
14051 );
14052 let _enter = span.enter();
14053 let request = types::xinput::XIDeletePropertyRequest {
14054 deviceid: Into::<u32>::into(deviceid.into()) as _,
14055 property,
14056 };
14057 let cookie = self.send_void_request(request, true);
14058 cookie
14059 }
14060 #[cfg(feature = "xinput")]
14061 fn xinput_xi_delete_property_checked(
14062 &mut self,
14063 deviceid: impl Into<types::Device>,
14064 property: types::Atom,
14065 ) -> Result<()> {
14066 let request = types::xinput::XIDeletePropertyRequest {
14067 deviceid: Into::<u32>::into(deviceid.into()) as _,
14068 property,
14069 };
14070 let cookie = self.send_void_request(request, false)?;
14071 self.wait_for_reply(cookie)
14072 }
14073 #[cfg(feature = "xinput")]
14074 fn xinput_xi_get_property(
14075 &mut self,
14076 deviceid: impl Into<types::Device>,
14077 delete: types::Bool,
14078 property: types::Atom,
14079 type_: types::Atom,
14080 offset: types::Card32,
14081 len: types::Card32,
14082 ) -> Result<Cookie<types::xinput::XIGetPropertyReply>> {
14083 let span = tracing::info_span!(
14084 "xinput_xi_get_property",
14085 delete = ?delete,
14086 property = ?property,
14087 type_ = ?type_,
14088 offset = ?offset,
14089 len = ?len,
14090 );
14091 let _enter = span.enter();
14092 let request = types::xinput::XIGetPropertyRequest {
14093 deviceid: Into::<u32>::into(deviceid.into()) as _,
14094 delete,
14095 property,
14096 type_,
14097 offset,
14098 len,
14099 };
14100 let cookie = self.send_reply_request(request);
14101 cookie
14102 }
14103 #[cfg(feature = "xinput")]
14104 fn xinput_xi_get_property_immediate(
14105 &mut self,
14106 deviceid: impl Into<types::Device>,
14107 delete: types::Bool,
14108 property: types::Atom,
14109 type_: types::Atom,
14110 offset: types::Card32,
14111 len: types::Card32,
14112 ) -> Result<types::xinput::XIGetPropertyReply> {
14113 let request = types::xinput::XIGetPropertyRequest {
14114 deviceid: Into::<u32>::into(deviceid.into()) as _,
14115 delete,
14116 property,
14117 type_,
14118 offset,
14119 len,
14120 };
14121 let cookie = self.send_reply_request(request)?;
14122 self.wait_for_reply(cookie)
14123 }
14124 #[cfg(feature = "xinput")]
14125 fn xinput_xi_get_selected_events(
14126 &mut self,
14127 window: types::xproto::Window,
14128 ) -> Result<Cookie<types::xinput::XIGetSelectedEventsReply>> {
14129 let span = tracing::info_span!(
14130 "xinput_xi_get_selected_events",
14131 window = ?window,
14132 );
14133 let _enter = span.enter();
14134 let request = types::xinput::XIGetSelectedEventsRequest { window };
14135 let cookie = self.send_reply_request(request);
14136 cookie
14137 }
14138 #[cfg(feature = "xinput")]
14139 fn xinput_xi_get_selected_events_immediate(
14140 &mut self,
14141 window: types::xproto::Window,
14142 ) -> Result<types::xinput::XIGetSelectedEventsReply> {
14143 let request = types::xinput::XIGetSelectedEventsRequest { window };
14144 let cookie = self.send_reply_request(request)?;
14145 self.wait_for_reply(cookie)
14146 }
14147 #[cfg(feature = "xinput")]
14148 fn xinput_xi_barrier_release_pointer(
14149 &mut self,
14150 barriers: impl AsRef<[types::BarrierReleasePointerInfo]>,
14151 ) -> Result<Cookie<()>> {
14152 let span = tracing::info_span!("xinput_xi_barrier_release_pointer",);
14153 let _enter = span.enter();
14154 let request = types::xinput::XIBarrierReleasePointerRequest {
14155 barriers: Cow::Borrowed(barriers.as_ref()),
14156 };
14157 let cookie = self.send_void_request(request, true);
14158 cookie
14159 }
14160 #[cfg(feature = "xinput")]
14161 fn xinput_xi_barrier_release_pointer_checked(
14162 &mut self,
14163 barriers: impl AsRef<[types::BarrierReleasePointerInfo]>,
14164 ) -> Result<()> {
14165 let request = types::xinput::XIBarrierReleasePointerRequest {
14166 barriers: Cow::Borrowed(barriers.as_ref()),
14167 };
14168 let cookie = self.send_void_request(request, false)?;
14169 self.wait_for_reply(cookie)
14170 }
14171 #[cfg(feature = "xinput")]
14172 fn xinput_send_extension_event(
14173 &mut self,
14174 destination: types::xproto::Window,
14175 device_id: types::Card8,
14176 propagate: types::Bool,
14177 events: impl AsRef<[types::EventForSend]>,
14178 classes: impl AsRef<[types::EventClass]>,
14179 ) -> Result<Cookie<()>> {
14180 let span = tracing::info_span!(
14181 "xinput_send_extension_event",
14182 destination = ?destination,
14183 device_id = ?device_id,
14184 propagate = ?propagate,
14185 );
14186 let _enter = span.enter();
14187 let request = types::xinput::SendExtensionEventRequest {
14188 destination,
14189 device_id,
14190 propagate,
14191 events: Cow::Borrowed(events.as_ref()),
14192 classes: Cow::Borrowed(classes.as_ref()),
14193 };
14194 let cookie = self.send_void_request(request, true);
14195 cookie
14196 }
14197 #[cfg(feature = "xinput")]
14198 fn xinput_send_extension_event_checked(
14199 &mut self,
14200 destination: types::xproto::Window,
14201 device_id: types::Card8,
14202 propagate: types::Bool,
14203 events: impl AsRef<[types::EventForSend]>,
14204 classes: impl AsRef<[types::EventClass]>,
14205 ) -> Result<()> {
14206 let request = types::xinput::SendExtensionEventRequest {
14207 destination,
14208 device_id,
14209 propagate,
14210 events: Cow::Borrowed(events.as_ref()),
14211 classes: Cow::Borrowed(classes.as_ref()),
14212 };
14213 let cookie = self.send_void_request(request, false)?;
14214 self.wait_for_reply(cookie)
14215 }
14216
14217 #[cfg(feature = "xkb")]
14218 fn xkb_use_extension(
14219 &mut self,
14220 wanted_major: types::Card16,
14221 wanted_minor: types::Card16,
14222 ) -> Result<Cookie<types::xkb::UseExtensionReply>> {
14223 let span = tracing::info_span!(
14224 "xkb_use_extension",
14225 wanted_major = ?wanted_major,
14226 wanted_minor = ?wanted_minor,
14227 );
14228 let _enter = span.enter();
14229 let request = types::xkb::UseExtensionRequest {
14230 wanted_major,
14231 wanted_minor,
14232 };
14233 let cookie = self.send_reply_request(request);
14234 cookie
14235 }
14236 #[cfg(feature = "xkb")]
14237 fn xkb_use_extension_immediate(
14238 &mut self,
14239 wanted_major: types::Card16,
14240 wanted_minor: types::Card16,
14241 ) -> Result<types::xkb::UseExtensionReply> {
14242 let request = types::xkb::UseExtensionRequest {
14243 wanted_major,
14244 wanted_minor,
14245 };
14246 let cookie = self.send_reply_request(request)?;
14247 self.wait_for_reply(cookie)
14248 }
14249 #[cfg(feature = "xkb")]
14250 fn xkb_select_events(
14251 &mut self,
14252 device_spec: types::DeviceSpec,
14253 clear: impl Into<types::xkb::EventType>,
14254 select_all: impl Into<types::xkb::EventType>,
14255 affect_map: impl Into<types::MapPart>,
14256 map: impl Into<types::MapPart>,
14257 details: impl Borrow<types::xkb::SelectEventsAux>,
14258 ) -> Result<Cookie<()>> {
14259 let span = tracing::info_span!(
14260 "xkb_select_events",
14261 device_spec = ?device_spec,
14262 );
14263 let _enter = span.enter();
14264 let request = types::xkb::SelectEventsRequest {
14265 device_spec,
14266 clear: Into::<u32>::into(clear.into()) as _,
14267 select_all: Into::<u32>::into(select_all.into()) as _,
14268 affect_map: Into::<u32>::into(affect_map.into()) as _,
14269 map: Into::<u32>::into(map.into()) as _,
14270 details: Cow::Borrowed(details.borrow()),
14271 };
14272 let cookie = self.send_void_request(request, true);
14273 cookie
14274 }
14275 #[cfg(feature = "xkb")]
14276 fn xkb_select_events_checked(
14277 &mut self,
14278 device_spec: types::DeviceSpec,
14279 clear: impl Into<types::xkb::EventType>,
14280 select_all: impl Into<types::xkb::EventType>,
14281 affect_map: impl Into<types::MapPart>,
14282 map: impl Into<types::MapPart>,
14283 details: impl Borrow<types::xkb::SelectEventsAux>,
14284 ) -> Result<()> {
14285 let request = types::xkb::SelectEventsRequest {
14286 device_spec,
14287 clear: Into::<u32>::into(clear.into()) as _,
14288 select_all: Into::<u32>::into(select_all.into()) as _,
14289 affect_map: Into::<u32>::into(affect_map.into()) as _,
14290 map: Into::<u32>::into(map.into()) as _,
14291 details: Cow::Borrowed(details.borrow()),
14292 };
14293 let cookie = self.send_void_request(request, false)?;
14294 self.wait_for_reply(cookie)
14295 }
14296 #[cfg(feature = "xkb")]
14297 fn xkb_bell(
14298 &mut self,
14299 device_spec: types::DeviceSpec,
14300 bell_class: types::BellClassSpec,
14301 bell_id: types::IDSpec,
14302 percent: types::Int8,
14303 force_sound: types::Bool,
14304 event_only: types::Bool,
14305 pitch: types::Int16,
14306 duration: types::Int16,
14307 name: types::Atom,
14308 window: types::xproto::Window,
14309 ) -> Result<Cookie<()>> {
14310 let span = tracing::info_span!(
14311 "xkb_bell",
14312 device_spec = ?device_spec,
14313 bell_class = ?bell_class,
14314 bell_id = ?bell_id,
14315 percent = ?percent,
14316 force_sound = ?force_sound,
14317 event_only = ?event_only,
14318 pitch = ?pitch,
14319 duration = ?duration,
14320 name = ?name,
14321 window = ?window,
14322 );
14323 let _enter = span.enter();
14324 let request = types::xkb::BellRequest {
14325 device_spec,
14326 bell_class,
14327 bell_id,
14328 percent,
14329 force_sound,
14330 event_only,
14331 pitch,
14332 duration,
14333 name,
14334 window,
14335 };
14336 let cookie = self.send_void_request(request, true);
14337 cookie
14338 }
14339 #[cfg(feature = "xkb")]
14340 fn xkb_bell_checked(
14341 &mut self,
14342 device_spec: types::DeviceSpec,
14343 bell_class: types::BellClassSpec,
14344 bell_id: types::IDSpec,
14345 percent: types::Int8,
14346 force_sound: types::Bool,
14347 event_only: types::Bool,
14348 pitch: types::Int16,
14349 duration: types::Int16,
14350 name: types::Atom,
14351 window: types::xproto::Window,
14352 ) -> Result<()> {
14353 let request = types::xkb::BellRequest {
14354 device_spec,
14355 bell_class,
14356 bell_id,
14357 percent,
14358 force_sound,
14359 event_only,
14360 pitch,
14361 duration,
14362 name,
14363 window,
14364 };
14365 let cookie = self.send_void_request(request, false)?;
14366 self.wait_for_reply(cookie)
14367 }
14368 #[cfg(feature = "xkb")]
14369 fn xkb_get_state(
14370 &mut self,
14371 device_spec: types::DeviceSpec,
14372 ) -> Result<Cookie<types::xkb::GetStateReply>> {
14373 let span = tracing::info_span!(
14374 "xkb_get_state",
14375 device_spec = ?device_spec,
14376 );
14377 let _enter = span.enter();
14378 let request = types::xkb::GetStateRequest { device_spec };
14379 let cookie = self.send_reply_request(request);
14380 cookie
14381 }
14382 #[cfg(feature = "xkb")]
14383 fn xkb_get_state_immediate(
14384 &mut self,
14385 device_spec: types::DeviceSpec,
14386 ) -> Result<types::xkb::GetStateReply> {
14387 let request = types::xkb::GetStateRequest { device_spec };
14388 let cookie = self.send_reply_request(request)?;
14389 self.wait_for_reply(cookie)
14390 }
14391 #[cfg(feature = "xkb")]
14392 fn xkb_latch_lock_state(
14393 &mut self,
14394 device_spec: types::DeviceSpec,
14395 affect_mod_locks: impl Into<types::ModMask>,
14396 mod_locks: impl Into<types::ModMask>,
14397 lock_group: types::Bool,
14398 group_lock: types::Group,
14399 affect_mod_latches: impl Into<types::ModMask>,
14400 latch_group: types::Bool,
14401 group_latch: types::Card16,
14402 ) -> Result<Cookie<()>> {
14403 let span = tracing::info_span!(
14404 "xkb_latch_lock_state",
14405 device_spec = ?device_spec,
14406 lock_group = ?lock_group,
14407 group_lock = ?group_lock,
14408 latch_group = ?latch_group,
14409 group_latch = ?group_latch,
14410 );
14411 let _enter = span.enter();
14412 let request = types::xkb::LatchLockStateRequest {
14413 device_spec,
14414 affect_mod_locks: Into::<u32>::into(affect_mod_locks.into()) as _,
14415 mod_locks: Into::<u32>::into(mod_locks.into()) as _,
14416 lock_group,
14417 group_lock,
14418 affect_mod_latches: Into::<u32>::into(affect_mod_latches.into()) as _,
14419 latch_group,
14420 group_latch,
14421 };
14422 let cookie = self.send_void_request(request, true);
14423 cookie
14424 }
14425 #[cfg(feature = "xkb")]
14426 fn xkb_latch_lock_state_checked(
14427 &mut self,
14428 device_spec: types::DeviceSpec,
14429 affect_mod_locks: impl Into<types::ModMask>,
14430 mod_locks: impl Into<types::ModMask>,
14431 lock_group: types::Bool,
14432 group_lock: types::Group,
14433 affect_mod_latches: impl Into<types::ModMask>,
14434 latch_group: types::Bool,
14435 group_latch: types::Card16,
14436 ) -> Result<()> {
14437 let request = types::xkb::LatchLockStateRequest {
14438 device_spec,
14439 affect_mod_locks: Into::<u32>::into(affect_mod_locks.into()) as _,
14440 mod_locks: Into::<u32>::into(mod_locks.into()) as _,
14441 lock_group,
14442 group_lock,
14443 affect_mod_latches: Into::<u32>::into(affect_mod_latches.into()) as _,
14444 latch_group,
14445 group_latch,
14446 };
14447 let cookie = self.send_void_request(request, false)?;
14448 self.wait_for_reply(cookie)
14449 }
14450 #[cfg(feature = "xkb")]
14451 fn xkb_get_controls(
14452 &mut self,
14453 device_spec: types::DeviceSpec,
14454 ) -> Result<Cookie<types::xkb::GetControlsReply>> {
14455 let span = tracing::info_span!(
14456 "xkb_get_controls",
14457 device_spec = ?device_spec,
14458 );
14459 let _enter = span.enter();
14460 let request = types::xkb::GetControlsRequest { device_spec };
14461 let cookie = self.send_reply_request(request);
14462 cookie
14463 }
14464 #[cfg(feature = "xkb")]
14465 fn xkb_get_controls_immediate(
14466 &mut self,
14467 device_spec: types::DeviceSpec,
14468 ) -> Result<types::xkb::GetControlsReply> {
14469 let request = types::xkb::GetControlsRequest { device_spec };
14470 let cookie = self.send_reply_request(request)?;
14471 self.wait_for_reply(cookie)
14472 }
14473 #[cfg(feature = "xkb")]
14474 fn xkb_set_controls(
14475 &mut self,
14476 device_spec: types::DeviceSpec,
14477 affect_internal_real_mods: impl Into<types::ModMask>,
14478 internal_real_mods: impl Into<types::ModMask>,
14479 affect_ignore_lock_real_mods: impl Into<types::ModMask>,
14480 ignore_lock_real_mods: impl Into<types::ModMask>,
14481 affect_internal_virtual_mods: impl Into<types::VMod>,
14482 internal_virtual_mods: impl Into<types::VMod>,
14483 affect_ignore_lock_virtual_mods: impl Into<types::VMod>,
14484 ignore_lock_virtual_mods: impl Into<types::VMod>,
14485 mouse_keys_dflt_btn: types::Card8,
14486 groups_wrap: types::Card8,
14487 access_x_options: impl Into<types::AXOption>,
14488 affect_enabled_controls: impl Into<types::BoolCtrl>,
14489 enabled_controls: impl Into<types::BoolCtrl>,
14490 change_controls: impl Into<types::Control>,
14491 repeat_delay: types::Card16,
14492 repeat_interval: types::Card16,
14493 slow_keys_delay: types::Card16,
14494 debounce_delay: types::Card16,
14495 mouse_keys_delay: types::Card16,
14496 mouse_keys_interval: types::Card16,
14497 mouse_keys_time_to_max: types::Card16,
14498 mouse_keys_max_speed: types::Card16,
14499 mouse_keys_curve: types::Int16,
14500 access_x_timeout: types::Card16,
14501 access_x_timeout_mask: impl Into<types::BoolCtrl>,
14502 access_x_timeout_values: impl Into<types::BoolCtrl>,
14503 access_x_timeout_options_mask: impl Into<types::AXOption>,
14504 access_x_timeout_options_values: impl Into<types::AXOption>,
14505 per_key_repeat: impl Borrow<[types::Card8; 32]>,
14506 ) -> Result<Cookie<()>> {
14507 let span = tracing::info_span!(
14508 "xkb_set_controls",
14509 device_spec = ?device_spec,
14510 mouse_keys_dflt_btn = ?mouse_keys_dflt_btn,
14511 groups_wrap = ?groups_wrap,
14512 repeat_delay = ?repeat_delay,
14513 repeat_interval = ?repeat_interval,
14514 slow_keys_delay = ?slow_keys_delay,
14515 debounce_delay = ?debounce_delay,
14516 mouse_keys_delay = ?mouse_keys_delay,
14517 mouse_keys_interval = ?mouse_keys_interval,
14518 mouse_keys_time_to_max = ?mouse_keys_time_to_max,
14519 mouse_keys_max_speed = ?mouse_keys_max_speed,
14520 mouse_keys_curve = ?mouse_keys_curve,
14521 access_x_timeout = ?access_x_timeout,
14522 );
14523 let _enter = span.enter();
14524 let request = types::xkb::SetControlsRequest {
14525 device_spec,
14526 affect_internal_real_mods: Into::<u32>::into(affect_internal_real_mods.into()) as _,
14527 internal_real_mods: Into::<u32>::into(internal_real_mods.into()) as _,
14528 affect_ignore_lock_real_mods: Into::<u32>::into(affect_ignore_lock_real_mods.into())
14529 as _,
14530 ignore_lock_real_mods: Into::<u32>::into(ignore_lock_real_mods.into()) as _,
14531 affect_internal_virtual_mods: Into::<u32>::into(affect_internal_virtual_mods.into())
14532 as _,
14533 internal_virtual_mods: Into::<u32>::into(internal_virtual_mods.into()) as _,
14534 affect_ignore_lock_virtual_mods: Into::<u32>::into(
14535 affect_ignore_lock_virtual_mods.into(),
14536 ) as _,
14537 ignore_lock_virtual_mods: Into::<u32>::into(ignore_lock_virtual_mods.into()) as _,
14538 mouse_keys_dflt_btn,
14539 groups_wrap,
14540 access_x_options: Into::<u32>::into(access_x_options.into()) as _,
14541 affect_enabled_controls: Into::<u32>::into(affect_enabled_controls.into()) as _,
14542 enabled_controls: Into::<u32>::into(enabled_controls.into()) as _,
14543 change_controls: Into::<u32>::into(change_controls.into()) as _,
14544 repeat_delay,
14545 repeat_interval,
14546 slow_keys_delay,
14547 debounce_delay,
14548 mouse_keys_delay,
14549 mouse_keys_interval,
14550 mouse_keys_time_to_max,
14551 mouse_keys_max_speed,
14552 mouse_keys_curve,
14553 access_x_timeout,
14554 access_x_timeout_mask: Into::<u32>::into(access_x_timeout_mask.into()) as _,
14555 access_x_timeout_values: Into::<u32>::into(access_x_timeout_values.into()) as _,
14556 access_x_timeout_options_mask: Into::<u32>::into(access_x_timeout_options_mask.into())
14557 as _,
14558 access_x_timeout_options_values: Into::<u32>::into(
14559 access_x_timeout_options_values.into(),
14560 ) as _,
14561 per_key_repeat: Cow::Borrowed(per_key_repeat.borrow()),
14562 };
14563 let cookie = self.send_void_request(request, true);
14564 cookie
14565 }
14566 #[cfg(feature = "xkb")]
14567 fn xkb_set_controls_checked(
14568 &mut self,
14569 device_spec: types::DeviceSpec,
14570 affect_internal_real_mods: impl Into<types::ModMask>,
14571 internal_real_mods: impl Into<types::ModMask>,
14572 affect_ignore_lock_real_mods: impl Into<types::ModMask>,
14573 ignore_lock_real_mods: impl Into<types::ModMask>,
14574 affect_internal_virtual_mods: impl Into<types::VMod>,
14575 internal_virtual_mods: impl Into<types::VMod>,
14576 affect_ignore_lock_virtual_mods: impl Into<types::VMod>,
14577 ignore_lock_virtual_mods: impl Into<types::VMod>,
14578 mouse_keys_dflt_btn: types::Card8,
14579 groups_wrap: types::Card8,
14580 access_x_options: impl Into<types::AXOption>,
14581 affect_enabled_controls: impl Into<types::BoolCtrl>,
14582 enabled_controls: impl Into<types::BoolCtrl>,
14583 change_controls: impl Into<types::Control>,
14584 repeat_delay: types::Card16,
14585 repeat_interval: types::Card16,
14586 slow_keys_delay: types::Card16,
14587 debounce_delay: types::Card16,
14588 mouse_keys_delay: types::Card16,
14589 mouse_keys_interval: types::Card16,
14590 mouse_keys_time_to_max: types::Card16,
14591 mouse_keys_max_speed: types::Card16,
14592 mouse_keys_curve: types::Int16,
14593 access_x_timeout: types::Card16,
14594 access_x_timeout_mask: impl Into<types::BoolCtrl>,
14595 access_x_timeout_values: impl Into<types::BoolCtrl>,
14596 access_x_timeout_options_mask: impl Into<types::AXOption>,
14597 access_x_timeout_options_values: impl Into<types::AXOption>,
14598 per_key_repeat: impl Borrow<[types::Card8; 32]>,
14599 ) -> Result<()> {
14600 let request = types::xkb::SetControlsRequest {
14601 device_spec,
14602 affect_internal_real_mods: Into::<u32>::into(affect_internal_real_mods.into()) as _,
14603 internal_real_mods: Into::<u32>::into(internal_real_mods.into()) as _,
14604 affect_ignore_lock_real_mods: Into::<u32>::into(affect_ignore_lock_real_mods.into())
14605 as _,
14606 ignore_lock_real_mods: Into::<u32>::into(ignore_lock_real_mods.into()) as _,
14607 affect_internal_virtual_mods: Into::<u32>::into(affect_internal_virtual_mods.into())
14608 as _,
14609 internal_virtual_mods: Into::<u32>::into(internal_virtual_mods.into()) as _,
14610 affect_ignore_lock_virtual_mods: Into::<u32>::into(
14611 affect_ignore_lock_virtual_mods.into(),
14612 ) as _,
14613 ignore_lock_virtual_mods: Into::<u32>::into(ignore_lock_virtual_mods.into()) as _,
14614 mouse_keys_dflt_btn,
14615 groups_wrap,
14616 access_x_options: Into::<u32>::into(access_x_options.into()) as _,
14617 affect_enabled_controls: Into::<u32>::into(affect_enabled_controls.into()) as _,
14618 enabled_controls: Into::<u32>::into(enabled_controls.into()) as _,
14619 change_controls: Into::<u32>::into(change_controls.into()) as _,
14620 repeat_delay,
14621 repeat_interval,
14622 slow_keys_delay,
14623 debounce_delay,
14624 mouse_keys_delay,
14625 mouse_keys_interval,
14626 mouse_keys_time_to_max,
14627 mouse_keys_max_speed,
14628 mouse_keys_curve,
14629 access_x_timeout,
14630 access_x_timeout_mask: Into::<u32>::into(access_x_timeout_mask.into()) as _,
14631 access_x_timeout_values: Into::<u32>::into(access_x_timeout_values.into()) as _,
14632 access_x_timeout_options_mask: Into::<u32>::into(access_x_timeout_options_mask.into())
14633 as _,
14634 access_x_timeout_options_values: Into::<u32>::into(
14635 access_x_timeout_options_values.into(),
14636 ) as _,
14637 per_key_repeat: Cow::Borrowed(per_key_repeat.borrow()),
14638 };
14639 let cookie = self.send_void_request(request, false)?;
14640 self.wait_for_reply(cookie)
14641 }
14642 #[cfg(feature = "xkb")]
14643 fn xkb_get_map(
14644 &mut self,
14645 device_spec: types::DeviceSpec,
14646 full: impl Into<types::MapPart>,
14647 partial: impl Into<types::MapPart>,
14648 first_type: types::Card8,
14649 n_types: types::Card8,
14650 first_key_sym: types::Keycode,
14651 n_key_syms: types::Card8,
14652 first_key_action: types::Keycode,
14653 n_key_actions: types::Card8,
14654 first_key_behavior: types::Keycode,
14655 n_key_behaviors: types::Card8,
14656 virtual_mods: impl Into<types::VMod>,
14657 first_key_explicit: types::Keycode,
14658 n_key_explicit: types::Card8,
14659 first_mod_map_key: types::Keycode,
14660 n_mod_map_keys: types::Card8,
14661 first_v_mod_map_key: types::Keycode,
14662 n_v_mod_map_keys: types::Card8,
14663 ) -> Result<Cookie<types::xkb::GetMapReply>> {
14664 let span = tracing::info_span!(
14665 "xkb_get_map",
14666 device_spec = ?device_spec,
14667 first_type = ?first_type,
14668 n_types = ?n_types,
14669 first_key_sym = ?first_key_sym,
14670 n_key_syms = ?n_key_syms,
14671 first_key_action = ?first_key_action,
14672 n_key_actions = ?n_key_actions,
14673 first_key_behavior = ?first_key_behavior,
14674 n_key_behaviors = ?n_key_behaviors,
14675 first_key_explicit = ?first_key_explicit,
14676 n_key_explicit = ?n_key_explicit,
14677 first_mod_map_key = ?first_mod_map_key,
14678 n_mod_map_keys = ?n_mod_map_keys,
14679 first_v_mod_map_key = ?first_v_mod_map_key,
14680 n_v_mod_map_keys = ?n_v_mod_map_keys,
14681 );
14682 let _enter = span.enter();
14683 let request = types::xkb::GetMapRequest {
14684 device_spec,
14685 full: Into::<u32>::into(full.into()) as _,
14686 partial: Into::<u32>::into(partial.into()) as _,
14687 first_type,
14688 n_types,
14689 first_key_sym,
14690 n_key_syms,
14691 first_key_action,
14692 n_key_actions,
14693 first_key_behavior,
14694 n_key_behaviors,
14695 virtual_mods: Into::<u32>::into(virtual_mods.into()) as _,
14696 first_key_explicit,
14697 n_key_explicit,
14698 first_mod_map_key,
14699 n_mod_map_keys,
14700 first_v_mod_map_key,
14701 n_v_mod_map_keys,
14702 };
14703 let cookie = self.send_reply_request(request);
14704 cookie
14705 }
14706 #[cfg(feature = "xkb")]
14707 fn xkb_get_map_immediate(
14708 &mut self,
14709 device_spec: types::DeviceSpec,
14710 full: impl Into<types::MapPart>,
14711 partial: impl Into<types::MapPart>,
14712 first_type: types::Card8,
14713 n_types: types::Card8,
14714 first_key_sym: types::Keycode,
14715 n_key_syms: types::Card8,
14716 first_key_action: types::Keycode,
14717 n_key_actions: types::Card8,
14718 first_key_behavior: types::Keycode,
14719 n_key_behaviors: types::Card8,
14720 virtual_mods: impl Into<types::VMod>,
14721 first_key_explicit: types::Keycode,
14722 n_key_explicit: types::Card8,
14723 first_mod_map_key: types::Keycode,
14724 n_mod_map_keys: types::Card8,
14725 first_v_mod_map_key: types::Keycode,
14726 n_v_mod_map_keys: types::Card8,
14727 ) -> Result<types::xkb::GetMapReply> {
14728 let request = types::xkb::GetMapRequest {
14729 device_spec,
14730 full: Into::<u32>::into(full.into()) as _,
14731 partial: Into::<u32>::into(partial.into()) as _,
14732 first_type,
14733 n_types,
14734 first_key_sym,
14735 n_key_syms,
14736 first_key_action,
14737 n_key_actions,
14738 first_key_behavior,
14739 n_key_behaviors,
14740 virtual_mods: Into::<u32>::into(virtual_mods.into()) as _,
14741 first_key_explicit,
14742 n_key_explicit,
14743 first_mod_map_key,
14744 n_mod_map_keys,
14745 first_v_mod_map_key,
14746 n_v_mod_map_keys,
14747 };
14748 let cookie = self.send_reply_request(request)?;
14749 self.wait_for_reply(cookie)
14750 }
14751 #[cfg(feature = "xkb")]
14752 fn xkb_set_map(
14753 &mut self,
14754 device_spec: types::DeviceSpec,
14755 flags: impl Into<types::SetMapFlags>,
14756 min_key_code: types::Keycode,
14757 max_key_code: types::Keycode,
14758 first_type: types::Card8,
14759 n_types: types::Card8,
14760 first_key_sym: types::Keycode,
14761 n_key_syms: types::Card8,
14762 total_syms: types::Card16,
14763 first_key_action: types::Keycode,
14764 n_key_actions: types::Card8,
14765 total_actions: types::Card16,
14766 first_key_behavior: types::Keycode,
14767 n_key_behaviors: types::Card8,
14768 total_key_behaviors: types::Card8,
14769 first_key_explicit: types::Keycode,
14770 n_key_explicit: types::Card8,
14771 total_key_explicit: types::Card8,
14772 first_mod_map_key: types::Keycode,
14773 n_mod_map_keys: types::Card8,
14774 total_mod_map_keys: types::Card8,
14775 first_v_mod_map_key: types::Keycode,
14776 n_v_mod_map_keys: types::Card8,
14777 total_v_mod_map_keys: types::Card8,
14778 virtual_mods: impl Into<types::VMod>,
14779 values: impl Borrow<types::xkb::SetMapAux>,
14780 ) -> Result<Cookie<()>> {
14781 let span = tracing::info_span!(
14782 "xkb_set_map",
14783 device_spec = ?device_spec,
14784 min_key_code = ?min_key_code,
14785 max_key_code = ?max_key_code,
14786 first_type = ?first_type,
14787 n_types = ?n_types,
14788 first_key_sym = ?first_key_sym,
14789 n_key_syms = ?n_key_syms,
14790 total_syms = ?total_syms,
14791 first_key_action = ?first_key_action,
14792 n_key_actions = ?n_key_actions,
14793 total_actions = ?total_actions,
14794 first_key_behavior = ?first_key_behavior,
14795 n_key_behaviors = ?n_key_behaviors,
14796 total_key_behaviors = ?total_key_behaviors,
14797 first_key_explicit = ?first_key_explicit,
14798 n_key_explicit = ?n_key_explicit,
14799 total_key_explicit = ?total_key_explicit,
14800 first_mod_map_key = ?first_mod_map_key,
14801 n_mod_map_keys = ?n_mod_map_keys,
14802 total_mod_map_keys = ?total_mod_map_keys,
14803 first_v_mod_map_key = ?first_v_mod_map_key,
14804 n_v_mod_map_keys = ?n_v_mod_map_keys,
14805 total_v_mod_map_keys = ?total_v_mod_map_keys,
14806 );
14807 let _enter = span.enter();
14808 let request = types::xkb::SetMapRequest {
14809 device_spec,
14810 flags: Into::<u32>::into(flags.into()) as _,
14811 min_key_code,
14812 max_key_code,
14813 first_type,
14814 n_types,
14815 first_key_sym,
14816 n_key_syms,
14817 total_syms,
14818 first_key_action,
14819 n_key_actions,
14820 total_actions,
14821 first_key_behavior,
14822 n_key_behaviors,
14823 total_key_behaviors,
14824 first_key_explicit,
14825 n_key_explicit,
14826 total_key_explicit,
14827 first_mod_map_key,
14828 n_mod_map_keys,
14829 total_mod_map_keys,
14830 first_v_mod_map_key,
14831 n_v_mod_map_keys,
14832 total_v_mod_map_keys,
14833 virtual_mods: Into::<u32>::into(virtual_mods.into()) as _,
14834 values: Cow::Borrowed(values.borrow()),
14835 };
14836 let cookie = self.send_void_request(request, true);
14837 cookie
14838 }
14839 #[cfg(feature = "xkb")]
14840 fn xkb_set_map_checked(
14841 &mut self,
14842 device_spec: types::DeviceSpec,
14843 flags: impl Into<types::SetMapFlags>,
14844 min_key_code: types::Keycode,
14845 max_key_code: types::Keycode,
14846 first_type: types::Card8,
14847 n_types: types::Card8,
14848 first_key_sym: types::Keycode,
14849 n_key_syms: types::Card8,
14850 total_syms: types::Card16,
14851 first_key_action: types::Keycode,
14852 n_key_actions: types::Card8,
14853 total_actions: types::Card16,
14854 first_key_behavior: types::Keycode,
14855 n_key_behaviors: types::Card8,
14856 total_key_behaviors: types::Card8,
14857 first_key_explicit: types::Keycode,
14858 n_key_explicit: types::Card8,
14859 total_key_explicit: types::Card8,
14860 first_mod_map_key: types::Keycode,
14861 n_mod_map_keys: types::Card8,
14862 total_mod_map_keys: types::Card8,
14863 first_v_mod_map_key: types::Keycode,
14864 n_v_mod_map_keys: types::Card8,
14865 total_v_mod_map_keys: types::Card8,
14866 virtual_mods: impl Into<types::VMod>,
14867 values: impl Borrow<types::xkb::SetMapAux>,
14868 ) -> Result<()> {
14869 let request = types::xkb::SetMapRequest {
14870 device_spec,
14871 flags: Into::<u32>::into(flags.into()) as _,
14872 min_key_code,
14873 max_key_code,
14874 first_type,
14875 n_types,
14876 first_key_sym,
14877 n_key_syms,
14878 total_syms,
14879 first_key_action,
14880 n_key_actions,
14881 total_actions,
14882 first_key_behavior,
14883 n_key_behaviors,
14884 total_key_behaviors,
14885 first_key_explicit,
14886 n_key_explicit,
14887 total_key_explicit,
14888 first_mod_map_key,
14889 n_mod_map_keys,
14890 total_mod_map_keys,
14891 first_v_mod_map_key,
14892 n_v_mod_map_keys,
14893 total_v_mod_map_keys,
14894 virtual_mods: Into::<u32>::into(virtual_mods.into()) as _,
14895 values: Cow::Borrowed(values.borrow()),
14896 };
14897 let cookie = self.send_void_request(request, false)?;
14898 self.wait_for_reply(cookie)
14899 }
14900 #[cfg(feature = "xkb")]
14901 fn xkb_get_compat_map(
14902 &mut self,
14903 device_spec: types::DeviceSpec,
14904 groups: impl Into<types::SetOfGroup>,
14905 get_all_si: types::Bool,
14906 first_si: types::Card16,
14907 n_si: types::Card16,
14908 ) -> Result<Cookie<types::xkb::GetCompatMapReply>> {
14909 let span = tracing::info_span!(
14910 "xkb_get_compat_map",
14911 device_spec = ?device_spec,
14912 get_all_si = ?get_all_si,
14913 first_si = ?first_si,
14914 n_si = ?n_si,
14915 );
14916 let _enter = span.enter();
14917 let request = types::xkb::GetCompatMapRequest {
14918 device_spec,
14919 groups: Into::<u32>::into(groups.into()) as _,
14920 get_all_si,
14921 first_si,
14922 n_si,
14923 };
14924 let cookie = self.send_reply_request(request);
14925 cookie
14926 }
14927 #[cfg(feature = "xkb")]
14928 fn xkb_get_compat_map_immediate(
14929 &mut self,
14930 device_spec: types::DeviceSpec,
14931 groups: impl Into<types::SetOfGroup>,
14932 get_all_si: types::Bool,
14933 first_si: types::Card16,
14934 n_si: types::Card16,
14935 ) -> Result<types::xkb::GetCompatMapReply> {
14936 let request = types::xkb::GetCompatMapRequest {
14937 device_spec,
14938 groups: Into::<u32>::into(groups.into()) as _,
14939 get_all_si,
14940 first_si,
14941 n_si,
14942 };
14943 let cookie = self.send_reply_request(request)?;
14944 self.wait_for_reply(cookie)
14945 }
14946 #[cfg(feature = "xkb")]
14947 fn xkb_set_compat_map(
14948 &mut self,
14949 device_spec: types::DeviceSpec,
14950 recompute_actions: types::Bool,
14951 truncate_si: types::Bool,
14952 groups: impl Into<types::SetOfGroup>,
14953 first_si: types::Card16,
14954 si: impl AsRef<[types::SymInterpret]>,
14955 group_maps: impl AsRef<[types::ModDef]>,
14956 ) -> Result<Cookie<()>> {
14957 let span = tracing::info_span!(
14958 "xkb_set_compat_map",
14959 device_spec = ?device_spec,
14960 recompute_actions = ?recompute_actions,
14961 truncate_si = ?truncate_si,
14962 first_si = ?first_si,
14963 );
14964 let _enter = span.enter();
14965 let request = types::xkb::SetCompatMapRequest {
14966 device_spec,
14967 recompute_actions,
14968 truncate_si,
14969 groups: Into::<u32>::into(groups.into()) as _,
14970 first_si,
14971 si: Cow::Borrowed(si.as_ref()),
14972 group_maps: Cow::Borrowed(group_maps.as_ref()),
14973 };
14974 let cookie = self.send_void_request(request, true);
14975 cookie
14976 }
14977 #[cfg(feature = "xkb")]
14978 fn xkb_set_compat_map_checked(
14979 &mut self,
14980 device_spec: types::DeviceSpec,
14981 recompute_actions: types::Bool,
14982 truncate_si: types::Bool,
14983 groups: impl Into<types::SetOfGroup>,
14984 first_si: types::Card16,
14985 si: impl AsRef<[types::SymInterpret]>,
14986 group_maps: impl AsRef<[types::ModDef]>,
14987 ) -> Result<()> {
14988 let request = types::xkb::SetCompatMapRequest {
14989 device_spec,
14990 recompute_actions,
14991 truncate_si,
14992 groups: Into::<u32>::into(groups.into()) as _,
14993 first_si,
14994 si: Cow::Borrowed(si.as_ref()),
14995 group_maps: Cow::Borrowed(group_maps.as_ref()),
14996 };
14997 let cookie = self.send_void_request(request, false)?;
14998 self.wait_for_reply(cookie)
14999 }
15000 #[cfg(feature = "xkb")]
15001 fn xkb_get_indicator_state(
15002 &mut self,
15003 device_spec: types::DeviceSpec,
15004 ) -> Result<Cookie<types::xkb::GetIndicatorStateReply>> {
15005 let span = tracing::info_span!(
15006 "xkb_get_indicator_state",
15007 device_spec = ?device_spec,
15008 );
15009 let _enter = span.enter();
15010 let request = types::xkb::GetIndicatorStateRequest { device_spec };
15011 let cookie = self.send_reply_request(request);
15012 cookie
15013 }
15014 #[cfg(feature = "xkb")]
15015 fn xkb_get_indicator_state_immediate(
15016 &mut self,
15017 device_spec: types::DeviceSpec,
15018 ) -> Result<types::xkb::GetIndicatorStateReply> {
15019 let request = types::xkb::GetIndicatorStateRequest { device_spec };
15020 let cookie = self.send_reply_request(request)?;
15021 self.wait_for_reply(cookie)
15022 }
15023 #[cfg(feature = "xkb")]
15024 fn xkb_get_indicator_map(
15025 &mut self,
15026 device_spec: types::DeviceSpec,
15027 which: types::Card32,
15028 ) -> Result<Cookie<types::xkb::GetIndicatorMapReply>> {
15029 let span = tracing::info_span!(
15030 "xkb_get_indicator_map",
15031 device_spec = ?device_spec,
15032 which = ?which,
15033 );
15034 let _enter = span.enter();
15035 let request = types::xkb::GetIndicatorMapRequest { device_spec, which };
15036 let cookie = self.send_reply_request(request);
15037 cookie
15038 }
15039 #[cfg(feature = "xkb")]
15040 fn xkb_get_indicator_map_immediate(
15041 &mut self,
15042 device_spec: types::DeviceSpec,
15043 which: types::Card32,
15044 ) -> Result<types::xkb::GetIndicatorMapReply> {
15045 let request = types::xkb::GetIndicatorMapRequest { device_spec, which };
15046 let cookie = self.send_reply_request(request)?;
15047 self.wait_for_reply(cookie)
15048 }
15049 #[cfg(feature = "xkb")]
15050 fn xkb_set_indicator_map(
15051 &mut self,
15052 device_spec: types::DeviceSpec,
15053 which: types::Card32,
15054 maps: impl AsRef<[types::IndicatorMap]>,
15055 ) -> Result<Cookie<()>> {
15056 let span = tracing::info_span!(
15057 "xkb_set_indicator_map",
15058 device_spec = ?device_spec,
15059 which = ?which,
15060 );
15061 let _enter = span.enter();
15062 let request = types::xkb::SetIndicatorMapRequest {
15063 device_spec,
15064 which,
15065 maps: Cow::Borrowed(maps.as_ref()),
15066 };
15067 let cookie = self.send_void_request(request, true);
15068 cookie
15069 }
15070 #[cfg(feature = "xkb")]
15071 fn xkb_set_indicator_map_checked(
15072 &mut self,
15073 device_spec: types::DeviceSpec,
15074 which: types::Card32,
15075 maps: impl AsRef<[types::IndicatorMap]>,
15076 ) -> Result<()> {
15077 let request = types::xkb::SetIndicatorMapRequest {
15078 device_spec,
15079 which,
15080 maps: Cow::Borrowed(maps.as_ref()),
15081 };
15082 let cookie = self.send_void_request(request, false)?;
15083 self.wait_for_reply(cookie)
15084 }
15085 #[cfg(feature = "xkb")]
15086 fn xkb_get_named_indicator(
15087 &mut self,
15088 device_spec: types::DeviceSpec,
15089 led_class: types::LedClass,
15090 led_id: impl Into<types::ID>,
15091 indicator: types::Atom,
15092 ) -> Result<Cookie<types::xkb::GetNamedIndicatorReply>> {
15093 let span = tracing::info_span!(
15094 "xkb_get_named_indicator",
15095 device_spec = ?device_spec,
15096 led_class = ?led_class,
15097 indicator = ?indicator,
15098 );
15099 let _enter = span.enter();
15100 let request = types::xkb::GetNamedIndicatorRequest {
15101 device_spec,
15102 led_class,
15103 led_id: Into::<u32>::into(led_id.into()) as _,
15104 indicator,
15105 };
15106 let cookie = self.send_reply_request(request);
15107 cookie
15108 }
15109 #[cfg(feature = "xkb")]
15110 fn xkb_get_named_indicator_immediate(
15111 &mut self,
15112 device_spec: types::DeviceSpec,
15113 led_class: types::LedClass,
15114 led_id: impl Into<types::ID>,
15115 indicator: types::Atom,
15116 ) -> Result<types::xkb::GetNamedIndicatorReply> {
15117 let request = types::xkb::GetNamedIndicatorRequest {
15118 device_spec,
15119 led_class,
15120 led_id: Into::<u32>::into(led_id.into()) as _,
15121 indicator,
15122 };
15123 let cookie = self.send_reply_request(request)?;
15124 self.wait_for_reply(cookie)
15125 }
15126 #[cfg(feature = "xkb")]
15127 fn xkb_set_named_indicator(
15128 &mut self,
15129 device_spec: types::DeviceSpec,
15130 led_class: types::LedClass,
15131 led_id: impl Into<types::ID>,
15132 indicator: types::Atom,
15133 set_state: types::Bool,
15134 on: types::Bool,
15135 set_map: types::Bool,
15136 create_map: types::Bool,
15137 map_flags: impl Into<types::IMFlag>,
15138 map_which_groups: impl Into<types::IMGroupsWhich>,
15139 map_groups: impl Into<types::SetOfGroups>,
15140 map_which_mods: impl Into<types::IMModsWhich>,
15141 map_real_mods: impl Into<types::ModMask>,
15142 map_vmods: impl Into<types::VMod>,
15143 map_ctrls: impl Into<types::BoolCtrl>,
15144 ) -> Result<Cookie<()>> {
15145 let span = tracing::info_span!(
15146 "xkb_set_named_indicator",
15147 device_spec = ?device_spec,
15148 led_class = ?led_class,
15149 indicator = ?indicator,
15150 set_state = ?set_state,
15151 on = ?on,
15152 set_map = ?set_map,
15153 create_map = ?create_map,
15154 );
15155 let _enter = span.enter();
15156 let request = types::xkb::SetNamedIndicatorRequest {
15157 device_spec,
15158 led_class,
15159 led_id: Into::<u32>::into(led_id.into()) as _,
15160 indicator,
15161 set_state,
15162 on,
15163 set_map,
15164 create_map,
15165 map_flags: Into::<u32>::into(map_flags.into()) as _,
15166 map_which_groups: Into::<u32>::into(map_which_groups.into()) as _,
15167 map_groups: Into::<u32>::into(map_groups.into()) as _,
15168 map_which_mods: Into::<u32>::into(map_which_mods.into()) as _,
15169 map_real_mods: Into::<u32>::into(map_real_mods.into()) as _,
15170 map_vmods: Into::<u32>::into(map_vmods.into()) as _,
15171 map_ctrls: Into::<u32>::into(map_ctrls.into()) as _,
15172 };
15173 let cookie = self.send_void_request(request, true);
15174 cookie
15175 }
15176 #[cfg(feature = "xkb")]
15177 fn xkb_set_named_indicator_checked(
15178 &mut self,
15179 device_spec: types::DeviceSpec,
15180 led_class: types::LedClass,
15181 led_id: impl Into<types::ID>,
15182 indicator: types::Atom,
15183 set_state: types::Bool,
15184 on: types::Bool,
15185 set_map: types::Bool,
15186 create_map: types::Bool,
15187 map_flags: impl Into<types::IMFlag>,
15188 map_which_groups: impl Into<types::IMGroupsWhich>,
15189 map_groups: impl Into<types::SetOfGroups>,
15190 map_which_mods: impl Into<types::IMModsWhich>,
15191 map_real_mods: impl Into<types::ModMask>,
15192 map_vmods: impl Into<types::VMod>,
15193 map_ctrls: impl Into<types::BoolCtrl>,
15194 ) -> Result<()> {
15195 let request = types::xkb::SetNamedIndicatorRequest {
15196 device_spec,
15197 led_class,
15198 led_id: Into::<u32>::into(led_id.into()) as _,
15199 indicator,
15200 set_state,
15201 on,
15202 set_map,
15203 create_map,
15204 map_flags: Into::<u32>::into(map_flags.into()) as _,
15205 map_which_groups: Into::<u32>::into(map_which_groups.into()) as _,
15206 map_groups: Into::<u32>::into(map_groups.into()) as _,
15207 map_which_mods: Into::<u32>::into(map_which_mods.into()) as _,
15208 map_real_mods: Into::<u32>::into(map_real_mods.into()) as _,
15209 map_vmods: Into::<u32>::into(map_vmods.into()) as _,
15210 map_ctrls: Into::<u32>::into(map_ctrls.into()) as _,
15211 };
15212 let cookie = self.send_void_request(request, false)?;
15213 self.wait_for_reply(cookie)
15214 }
15215 #[cfg(feature = "xkb")]
15216 fn xkb_get_names(
15217 &mut self,
15218 device_spec: types::DeviceSpec,
15219 which: impl Into<types::NameDetail>,
15220 ) -> Result<Cookie<types::xkb::GetNamesReply>> {
15221 let span = tracing::info_span!(
15222 "xkb_get_names",
15223 device_spec = ?device_spec,
15224 );
15225 let _enter = span.enter();
15226 let request = types::xkb::GetNamesRequest {
15227 device_spec,
15228 which: Into::<u32>::into(which.into()) as _,
15229 };
15230 let cookie = self.send_reply_request(request);
15231 cookie
15232 }
15233 #[cfg(feature = "xkb")]
15234 fn xkb_get_names_immediate(
15235 &mut self,
15236 device_spec: types::DeviceSpec,
15237 which: impl Into<types::NameDetail>,
15238 ) -> Result<types::xkb::GetNamesReply> {
15239 let request = types::xkb::GetNamesRequest {
15240 device_spec,
15241 which: Into::<u32>::into(which.into()) as _,
15242 };
15243 let cookie = self.send_reply_request(request)?;
15244 self.wait_for_reply(cookie)
15245 }
15246 #[cfg(feature = "xkb")]
15247 fn xkb_set_names(
15248 &mut self,
15249 device_spec: types::DeviceSpec,
15250 virtual_mods: impl Into<types::VMod>,
15251 first_type: types::Card8,
15252 n_types: types::Card8,
15253 first_kt_levelt: types::Card8,
15254 n_kt_levels: types::Card8,
15255 indicators: types::Card32,
15256 group_names: impl Into<types::SetOfGroup>,
15257 n_radio_groups: types::Card8,
15258 first_key: types::Keycode,
15259 n_keys: types::Card8,
15260 n_key_aliases: types::Card8,
15261 total_kt_level_names: types::Card16,
15262 values: impl Borrow<types::xkb::SetNamesAux>,
15263 ) -> Result<Cookie<()>> {
15264 let span = tracing::info_span!(
15265 "xkb_set_names",
15266 device_spec = ?device_spec,
15267 first_type = ?first_type,
15268 n_types = ?n_types,
15269 first_kt_levelt = ?first_kt_levelt,
15270 n_kt_levels = ?n_kt_levels,
15271 indicators = ?indicators,
15272 n_radio_groups = ?n_radio_groups,
15273 first_key = ?first_key,
15274 n_keys = ?n_keys,
15275 n_key_aliases = ?n_key_aliases,
15276 total_kt_level_names = ?total_kt_level_names,
15277 );
15278 let _enter = span.enter();
15279 let request = types::xkb::SetNamesRequest {
15280 device_spec,
15281 virtual_mods: Into::<u32>::into(virtual_mods.into()) as _,
15282 first_type,
15283 n_types,
15284 first_kt_levelt,
15285 n_kt_levels,
15286 indicators,
15287 group_names: Into::<u32>::into(group_names.into()) as _,
15288 n_radio_groups,
15289 first_key,
15290 n_keys,
15291 n_key_aliases,
15292 total_kt_level_names,
15293 values: Cow::Borrowed(values.borrow()),
15294 };
15295 let cookie = self.send_void_request(request, true);
15296 cookie
15297 }
15298 #[cfg(feature = "xkb")]
15299 fn xkb_set_names_checked(
15300 &mut self,
15301 device_spec: types::DeviceSpec,
15302 virtual_mods: impl Into<types::VMod>,
15303 first_type: types::Card8,
15304 n_types: types::Card8,
15305 first_kt_levelt: types::Card8,
15306 n_kt_levels: types::Card8,
15307 indicators: types::Card32,
15308 group_names: impl Into<types::SetOfGroup>,
15309 n_radio_groups: types::Card8,
15310 first_key: types::Keycode,
15311 n_keys: types::Card8,
15312 n_key_aliases: types::Card8,
15313 total_kt_level_names: types::Card16,
15314 values: impl Borrow<types::xkb::SetNamesAux>,
15315 ) -> Result<()> {
15316 let request = types::xkb::SetNamesRequest {
15317 device_spec,
15318 virtual_mods: Into::<u32>::into(virtual_mods.into()) as _,
15319 first_type,
15320 n_types,
15321 first_kt_levelt,
15322 n_kt_levels,
15323 indicators,
15324 group_names: Into::<u32>::into(group_names.into()) as _,
15325 n_radio_groups,
15326 first_key,
15327 n_keys,
15328 n_key_aliases,
15329 total_kt_level_names,
15330 values: Cow::Borrowed(values.borrow()),
15331 };
15332 let cookie = self.send_void_request(request, false)?;
15333 self.wait_for_reply(cookie)
15334 }
15335 #[cfg(feature = "xkb")]
15336 fn xkb_per_client_flags(
15337 &mut self,
15338 device_spec: types::DeviceSpec,
15339 change: impl Into<types::PerClientFlag>,
15340 value: impl Into<types::PerClientFlag>,
15341 ctrls_to_change: impl Into<types::BoolCtrl>,
15342 auto_ctrls: impl Into<types::BoolCtrl>,
15343 auto_ctrls_values: impl Into<types::BoolCtrl>,
15344 ) -> Result<Cookie<types::xkb::PerClientFlagsReply>> {
15345 let span = tracing::info_span!(
15346 "xkb_per_client_flags",
15347 device_spec = ?device_spec,
15348 );
15349 let _enter = span.enter();
15350 let request = types::xkb::PerClientFlagsRequest {
15351 device_spec,
15352 change: Into::<u32>::into(change.into()) as _,
15353 value: Into::<u32>::into(value.into()) as _,
15354 ctrls_to_change: Into::<u32>::into(ctrls_to_change.into()) as _,
15355 auto_ctrls: Into::<u32>::into(auto_ctrls.into()) as _,
15356 auto_ctrls_values: Into::<u32>::into(auto_ctrls_values.into()) as _,
15357 };
15358 let cookie = self.send_reply_request(request);
15359 cookie
15360 }
15361 #[cfg(feature = "xkb")]
15362 fn xkb_per_client_flags_immediate(
15363 &mut self,
15364 device_spec: types::DeviceSpec,
15365 change: impl Into<types::PerClientFlag>,
15366 value: impl Into<types::PerClientFlag>,
15367 ctrls_to_change: impl Into<types::BoolCtrl>,
15368 auto_ctrls: impl Into<types::BoolCtrl>,
15369 auto_ctrls_values: impl Into<types::BoolCtrl>,
15370 ) -> Result<types::xkb::PerClientFlagsReply> {
15371 let request = types::xkb::PerClientFlagsRequest {
15372 device_spec,
15373 change: Into::<u32>::into(change.into()) as _,
15374 value: Into::<u32>::into(value.into()) as _,
15375 ctrls_to_change: Into::<u32>::into(ctrls_to_change.into()) as _,
15376 auto_ctrls: Into::<u32>::into(auto_ctrls.into()) as _,
15377 auto_ctrls_values: Into::<u32>::into(auto_ctrls_values.into()) as _,
15378 };
15379 let cookie = self.send_reply_request(request)?;
15380 self.wait_for_reply(cookie)
15381 }
15382 #[cfg(feature = "xkb")]
15383 fn xkb_list_components(
15384 &mut self,
15385 device_spec: types::DeviceSpec,
15386 max_names: types::Card16,
15387 ) -> Result<Cookie<types::xkb::ListComponentsReply>> {
15388 let span = tracing::info_span!(
15389 "xkb_list_components",
15390 device_spec = ?device_spec,
15391 max_names = ?max_names,
15392 );
15393 let _enter = span.enter();
15394 let request = types::xkb::ListComponentsRequest {
15395 device_spec,
15396 max_names,
15397 };
15398 let cookie = self.send_reply_request(request);
15399 cookie
15400 }
15401 #[cfg(feature = "xkb")]
15402 fn xkb_list_components_immediate(
15403 &mut self,
15404 device_spec: types::DeviceSpec,
15405 max_names: types::Card16,
15406 ) -> Result<types::xkb::ListComponentsReply> {
15407 let request = types::xkb::ListComponentsRequest {
15408 device_spec,
15409 max_names,
15410 };
15411 let cookie = self.send_reply_request(request)?;
15412 self.wait_for_reply(cookie)
15413 }
15414 #[cfg(feature = "xkb")]
15415 fn xkb_get_kbd_by_name(
15416 &mut self,
15417 device_spec: types::DeviceSpec,
15418 need: impl Into<types::GBNDetail>,
15419 want: impl Into<types::GBNDetail>,
15420 load: types::Bool,
15421 ) -> Result<Cookie<types::xkb::GetKbdByNameReply>> {
15422 let span = tracing::info_span!(
15423 "xkb_get_kbd_by_name",
15424 device_spec = ?device_spec,
15425 load = ?load,
15426 );
15427 let _enter = span.enter();
15428 let request = types::xkb::GetKbdByNameRequest {
15429 device_spec,
15430 need: Into::<u32>::into(need.into()) as _,
15431 want: Into::<u32>::into(want.into()) as _,
15432 load,
15433 };
15434 let cookie = self.send_reply_request(request);
15435 cookie
15436 }
15437 #[cfg(feature = "xkb")]
15438 fn xkb_get_kbd_by_name_immediate(
15439 &mut self,
15440 device_spec: types::DeviceSpec,
15441 need: impl Into<types::GBNDetail>,
15442 want: impl Into<types::GBNDetail>,
15443 load: types::Bool,
15444 ) -> Result<types::xkb::GetKbdByNameReply> {
15445 let request = types::xkb::GetKbdByNameRequest {
15446 device_spec,
15447 need: Into::<u32>::into(need.into()) as _,
15448 want: Into::<u32>::into(want.into()) as _,
15449 load,
15450 };
15451 let cookie = self.send_reply_request(request)?;
15452 self.wait_for_reply(cookie)
15453 }
15454 #[cfg(feature = "xkb")]
15455 fn xkb_get_device_info(
15456 &mut self,
15457 device_spec: types::DeviceSpec,
15458 wanted: impl Into<types::XIFeature>,
15459 all_buttons: types::Bool,
15460 first_button: types::Card8,
15461 n_buttons: types::Card8,
15462 led_class: types::LedClass,
15463 led_id: impl Into<types::ID>,
15464 ) -> Result<Cookie<types::xkb::GetDeviceInfoReply>> {
15465 let span = tracing::info_span!(
15466 "xkb_get_device_info",
15467 device_spec = ?device_spec,
15468 all_buttons = ?all_buttons,
15469 first_button = ?first_button,
15470 n_buttons = ?n_buttons,
15471 led_class = ?led_class,
15472 );
15473 let _enter = span.enter();
15474 let request = types::xkb::GetDeviceInfoRequest {
15475 device_spec,
15476 wanted: Into::<u32>::into(wanted.into()) as _,
15477 all_buttons,
15478 first_button,
15479 n_buttons,
15480 led_class,
15481 led_id: Into::<u32>::into(led_id.into()) as _,
15482 };
15483 let cookie = self.send_reply_request(request);
15484 cookie
15485 }
15486 #[cfg(feature = "xkb")]
15487 fn xkb_get_device_info_immediate(
15488 &mut self,
15489 device_spec: types::DeviceSpec,
15490 wanted: impl Into<types::XIFeature>,
15491 all_buttons: types::Bool,
15492 first_button: types::Card8,
15493 n_buttons: types::Card8,
15494 led_class: types::LedClass,
15495 led_id: impl Into<types::ID>,
15496 ) -> Result<types::xkb::GetDeviceInfoReply> {
15497 let request = types::xkb::GetDeviceInfoRequest {
15498 device_spec,
15499 wanted: Into::<u32>::into(wanted.into()) as _,
15500 all_buttons,
15501 first_button,
15502 n_buttons,
15503 led_class,
15504 led_id: Into::<u32>::into(led_id.into()) as _,
15505 };
15506 let cookie = self.send_reply_request(request)?;
15507 self.wait_for_reply(cookie)
15508 }
15509 #[cfg(feature = "xkb")]
15510 fn xkb_set_device_info(
15511 &mut self,
15512 device_spec: types::DeviceSpec,
15513 first_btn: types::Card8,
15514 change: impl Into<types::XIFeature>,
15515 btn_actions: impl AsRef<[types::Action]>,
15516 leds: impl AsRef<[types::DeviceLedInfo]>,
15517 ) -> Result<Cookie<()>> {
15518 let span = tracing::info_span!(
15519 "xkb_set_device_info",
15520 device_spec = ?device_spec,
15521 first_btn = ?first_btn,
15522 );
15523 let _enter = span.enter();
15524 let request = types::xkb::SetDeviceInfoRequest {
15525 device_spec,
15526 first_btn,
15527 change: Into::<u32>::into(change.into()) as _,
15528 btn_actions: Cow::Borrowed(btn_actions.as_ref()),
15529 leds: Cow::Borrowed(leds.as_ref()),
15530 };
15531 let cookie = self.send_void_request(request, true);
15532 cookie
15533 }
15534 #[cfg(feature = "xkb")]
15535 fn xkb_set_device_info_checked(
15536 &mut self,
15537 device_spec: types::DeviceSpec,
15538 first_btn: types::Card8,
15539 change: impl Into<types::XIFeature>,
15540 btn_actions: impl AsRef<[types::Action]>,
15541 leds: impl AsRef<[types::DeviceLedInfo]>,
15542 ) -> Result<()> {
15543 let request = types::xkb::SetDeviceInfoRequest {
15544 device_spec,
15545 first_btn,
15546 change: Into::<u32>::into(change.into()) as _,
15547 btn_actions: Cow::Borrowed(btn_actions.as_ref()),
15548 leds: Cow::Borrowed(leds.as_ref()),
15549 };
15550 let cookie = self.send_void_request(request, false)?;
15551 self.wait_for_reply(cookie)
15552 }
15553 #[cfg(feature = "xkb")]
15554 fn xkb_set_debugging_flags(
15555 &mut self,
15556 affect_flags: types::Card32,
15557 flags: types::Card32,
15558 affect_ctrls: types::Card32,
15559 ctrls: types::Card32,
15560 message: impl AsRef<[types::xkb::String8]>,
15561 ) -> Result<Cookie<types::xkb::SetDebuggingFlagsReply>> {
15562 let span = tracing::info_span!(
15563 "xkb_set_debugging_flags",
15564 affect_flags = ?affect_flags,
15565 flags = ?flags,
15566 affect_ctrls = ?affect_ctrls,
15567 ctrls = ?ctrls,
15568 );
15569 let _enter = span.enter();
15570 let request = types::xkb::SetDebuggingFlagsRequest {
15571 affect_flags,
15572 flags,
15573 affect_ctrls,
15574 ctrls,
15575 message: Cow::Borrowed(message.as_ref()),
15576 };
15577 let cookie = self.send_reply_request(request);
15578 cookie
15579 }
15580 #[cfg(feature = "xkb")]
15581 fn xkb_set_debugging_flags_immediate(
15582 &mut self,
15583 affect_flags: types::Card32,
15584 flags: types::Card32,
15585 affect_ctrls: types::Card32,
15586 ctrls: types::Card32,
15587 message: impl AsRef<[types::xkb::String8]>,
15588 ) -> Result<types::xkb::SetDebuggingFlagsReply> {
15589 let request = types::xkb::SetDebuggingFlagsRequest {
15590 affect_flags,
15591 flags,
15592 affect_ctrls,
15593 ctrls,
15594 message: Cow::Borrowed(message.as_ref()),
15595 };
15596 let cookie = self.send_reply_request(request)?;
15597 self.wait_for_reply(cookie)
15598 }
15599
15600 #[cfg(feature = "xprint")]
15601 fn xprint_print_query_version(
15602 &mut self,
15603 ) -> Result<Cookie<types::xprint::PrintQueryVersionReply>> {
15604 let span = tracing::info_span!("xprint_print_query_version",);
15605 let _enter = span.enter();
15606 let request = types::xprint::PrintQueryVersionRequest {};
15607 let cookie = self.send_reply_request(request);
15608 cookie
15609 }
15610 #[cfg(feature = "xprint")]
15611 fn xprint_print_query_version_immediate(
15612 &mut self,
15613 ) -> Result<types::xprint::PrintQueryVersionReply> {
15614 let request = types::xprint::PrintQueryVersionRequest {};
15615 let cookie = self.send_reply_request(request)?;
15616 self.wait_for_reply(cookie)
15617 }
15618 #[cfg(feature = "xprint")]
15619 fn xprint_print_get_printer_list(
15620 &mut self,
15621 printer_name: impl AsRef<[types::xprint::String8]>,
15622 locale: impl AsRef<[types::xprint::String8]>,
15623 ) -> Result<Cookie<types::xprint::PrintGetPrinterListReply>> {
15624 let span = tracing::info_span!("xprint_print_get_printer_list",);
15625 let _enter = span.enter();
15626 let request = types::xprint::PrintGetPrinterListRequest {
15627 printer_name: Cow::Borrowed(printer_name.as_ref()),
15628 locale: Cow::Borrowed(locale.as_ref()),
15629 };
15630 let cookie = self.send_reply_request(request);
15631 cookie
15632 }
15633 #[cfg(feature = "xprint")]
15634 fn xprint_print_get_printer_list_immediate(
15635 &mut self,
15636 printer_name: impl AsRef<[types::xprint::String8]>,
15637 locale: impl AsRef<[types::xprint::String8]>,
15638 ) -> Result<types::xprint::PrintGetPrinterListReply> {
15639 let request = types::xprint::PrintGetPrinterListRequest {
15640 printer_name: Cow::Borrowed(printer_name.as_ref()),
15641 locale: Cow::Borrowed(locale.as_ref()),
15642 };
15643 let cookie = self.send_reply_request(request)?;
15644 self.wait_for_reply(cookie)
15645 }
15646 #[cfg(feature = "xprint")]
15647 fn xprint_print_rehash_printer_list(&mut self) -> Result<Cookie<()>> {
15648 let span = tracing::info_span!("xprint_print_rehash_printer_list",);
15649 let _enter = span.enter();
15650 let request = types::xprint::PrintRehashPrinterListRequest {};
15651 let cookie = self.send_void_request(request, true);
15652 cookie
15653 }
15654 #[cfg(feature = "xprint")]
15655 fn xprint_print_rehash_printer_list_checked(&mut self) -> Result<()> {
15656 let request = types::xprint::PrintRehashPrinterListRequest {};
15657 let cookie = self.send_void_request(request, false)?;
15658 self.wait_for_reply(cookie)
15659 }
15660 #[cfg(feature = "xprint")]
15661 fn xprint_create_context(
15662 &mut self,
15663 context_id: types::Card32,
15664 printer_name: impl AsRef<[types::xprint::String8]>,
15665 locale: impl AsRef<[types::xprint::String8]>,
15666 ) -> Result<Cookie<()>> {
15667 let span = tracing::info_span!(
15668 "xprint_create_context",
15669 context_id = ?context_id,
15670 );
15671 let _enter = span.enter();
15672 let request = types::xprint::CreateContextRequest {
15673 context_id,
15674 printer_name: Cow::Borrowed(printer_name.as_ref()),
15675 locale: Cow::Borrowed(locale.as_ref()),
15676 };
15677 let cookie = self.send_void_request(request, true);
15678 cookie
15679 }
15680 #[cfg(feature = "xprint")]
15681 fn xprint_create_context_checked(
15682 &mut self,
15683 context_id: types::Card32,
15684 printer_name: impl AsRef<[types::xprint::String8]>,
15685 locale: impl AsRef<[types::xprint::String8]>,
15686 ) -> Result<()> {
15687 let request = types::xprint::CreateContextRequest {
15688 context_id,
15689 printer_name: Cow::Borrowed(printer_name.as_ref()),
15690 locale: Cow::Borrowed(locale.as_ref()),
15691 };
15692 let cookie = self.send_void_request(request, false)?;
15693 self.wait_for_reply(cookie)
15694 }
15695 #[cfg(feature = "xprint")]
15696 fn xprint_print_set_context(&mut self, context: types::Card32) -> Result<Cookie<()>> {
15697 let span = tracing::info_span!(
15698 "xprint_print_set_context",
15699 context = ?context,
15700 );
15701 let _enter = span.enter();
15702 let request = types::xprint::PrintSetContextRequest { context };
15703 let cookie = self.send_void_request(request, true);
15704 cookie
15705 }
15706 #[cfg(feature = "xprint")]
15707 fn xprint_print_set_context_checked(&mut self, context: types::Card32) -> Result<()> {
15708 let request = types::xprint::PrintSetContextRequest { context };
15709 let cookie = self.send_void_request(request, false)?;
15710 self.wait_for_reply(cookie)
15711 }
15712 #[cfg(feature = "xprint")]
15713 fn xprint_print_get_context(&mut self) -> Result<Cookie<types::xprint::PrintGetContextReply>> {
15714 let span = tracing::info_span!("xprint_print_get_context",);
15715 let _enter = span.enter();
15716 let request = types::xprint::PrintGetContextRequest {};
15717 let cookie = self.send_reply_request(request);
15718 cookie
15719 }
15720 #[cfg(feature = "xprint")]
15721 fn xprint_print_get_context_immediate(
15722 &mut self,
15723 ) -> Result<types::xprint::PrintGetContextReply> {
15724 let request = types::xprint::PrintGetContextRequest {};
15725 let cookie = self.send_reply_request(request)?;
15726 self.wait_for_reply(cookie)
15727 }
15728 #[cfg(feature = "xprint")]
15729 fn xprint_print_destroy_context(&mut self, context: types::Card32) -> Result<Cookie<()>> {
15730 let span = tracing::info_span!(
15731 "xprint_print_destroy_context",
15732 context = ?context,
15733 );
15734 let _enter = span.enter();
15735 let request = types::xprint::PrintDestroyContextRequest { context };
15736 let cookie = self.send_void_request(request, true);
15737 cookie
15738 }
15739 #[cfg(feature = "xprint")]
15740 fn xprint_print_destroy_context_checked(&mut self, context: types::Card32) -> Result<()> {
15741 let request = types::xprint::PrintDestroyContextRequest { context };
15742 let cookie = self.send_void_request(request, false)?;
15743 self.wait_for_reply(cookie)
15744 }
15745 #[cfg(feature = "xprint")]
15746 fn xprint_print_get_screen_of_context(
15747 &mut self,
15748 ) -> Result<Cookie<types::xprint::PrintGetScreenOfContextReply>> {
15749 let span = tracing::info_span!("xprint_print_get_screen_of_context",);
15750 let _enter = span.enter();
15751 let request = types::xprint::PrintGetScreenOfContextRequest {};
15752 let cookie = self.send_reply_request(request);
15753 cookie
15754 }
15755 #[cfg(feature = "xprint")]
15756 fn xprint_print_get_screen_of_context_immediate(
15757 &mut self,
15758 ) -> Result<types::xprint::PrintGetScreenOfContextReply> {
15759 let request = types::xprint::PrintGetScreenOfContextRequest {};
15760 let cookie = self.send_reply_request(request)?;
15761 self.wait_for_reply(cookie)
15762 }
15763 #[cfg(feature = "xprint")]
15764 fn xprint_print_start_job(&mut self, output_mode: types::Card8) -> Result<Cookie<()>> {
15765 let span = tracing::info_span!(
15766 "xprint_print_start_job",
15767 output_mode = ?output_mode,
15768 );
15769 let _enter = span.enter();
15770 let request = types::xprint::PrintStartJobRequest { output_mode };
15771 let cookie = self.send_void_request(request, true);
15772 cookie
15773 }
15774 #[cfg(feature = "xprint")]
15775 fn xprint_print_start_job_checked(&mut self, output_mode: types::Card8) -> Result<()> {
15776 let request = types::xprint::PrintStartJobRequest { output_mode };
15777 let cookie = self.send_void_request(request, false)?;
15778 self.wait_for_reply(cookie)
15779 }
15780 #[cfg(feature = "xprint")]
15781 fn xprint_print_end_job(&mut self, cancel: types::Bool) -> Result<Cookie<()>> {
15782 let span = tracing::info_span!(
15783 "xprint_print_end_job",
15784 cancel = ?cancel,
15785 );
15786 let _enter = span.enter();
15787 let request = types::xprint::PrintEndJobRequest { cancel };
15788 let cookie = self.send_void_request(request, true);
15789 cookie
15790 }
15791 #[cfg(feature = "xprint")]
15792 fn xprint_print_end_job_checked(&mut self, cancel: types::Bool) -> Result<()> {
15793 let request = types::xprint::PrintEndJobRequest { cancel };
15794 let cookie = self.send_void_request(request, false)?;
15795 self.wait_for_reply(cookie)
15796 }
15797 #[cfg(feature = "xprint")]
15798 fn xprint_print_start_doc(&mut self, driver_mode: types::Card8) -> Result<Cookie<()>> {
15799 let span = tracing::info_span!(
15800 "xprint_print_start_doc",
15801 driver_mode = ?driver_mode,
15802 );
15803 let _enter = span.enter();
15804 let request = types::xprint::PrintStartDocRequest { driver_mode };
15805 let cookie = self.send_void_request(request, true);
15806 cookie
15807 }
15808 #[cfg(feature = "xprint")]
15809 fn xprint_print_start_doc_checked(&mut self, driver_mode: types::Card8) -> Result<()> {
15810 let request = types::xprint::PrintStartDocRequest { driver_mode };
15811 let cookie = self.send_void_request(request, false)?;
15812 self.wait_for_reply(cookie)
15813 }
15814 #[cfg(feature = "xprint")]
15815 fn xprint_print_end_doc(&mut self, cancel: types::Bool) -> Result<Cookie<()>> {
15816 let span = tracing::info_span!(
15817 "xprint_print_end_doc",
15818 cancel = ?cancel,
15819 );
15820 let _enter = span.enter();
15821 let request = types::xprint::PrintEndDocRequest { cancel };
15822 let cookie = self.send_void_request(request, true);
15823 cookie
15824 }
15825 #[cfg(feature = "xprint")]
15826 fn xprint_print_end_doc_checked(&mut self, cancel: types::Bool) -> Result<()> {
15827 let request = types::xprint::PrintEndDocRequest { cancel };
15828 let cookie = self.send_void_request(request, false)?;
15829 self.wait_for_reply(cookie)
15830 }
15831 #[cfg(feature = "xprint")]
15832 fn xprint_print_put_document_data(
15833 &mut self,
15834 drawable: types::xproto::Drawable,
15835 data: impl AsRef<[types::Byte]>,
15836 doc_format: impl AsRef<[types::xprint::String8]>,
15837 options: impl AsRef<[types::xprint::String8]>,
15838 ) -> Result<Cookie<()>> {
15839 let span = tracing::info_span!(
15840 "xprint_print_put_document_data",
15841 drawable = ?drawable,
15842 );
15843 let _enter = span.enter();
15844 let request = types::xprint::PrintPutDocumentDataRequest {
15845 drawable,
15846 data: Cow::Borrowed(data.as_ref()),
15847 doc_format: Cow::Borrowed(doc_format.as_ref()),
15848 options: Cow::Borrowed(options.as_ref()),
15849 };
15850 let cookie = self.send_void_request(request, true);
15851 cookie
15852 }
15853 #[cfg(feature = "xprint")]
15854 fn xprint_print_put_document_data_checked(
15855 &mut self,
15856 drawable: types::xproto::Drawable,
15857 data: impl AsRef<[types::Byte]>,
15858 doc_format: impl AsRef<[types::xprint::String8]>,
15859 options: impl AsRef<[types::xprint::String8]>,
15860 ) -> Result<()> {
15861 let request = types::xprint::PrintPutDocumentDataRequest {
15862 drawable,
15863 data: Cow::Borrowed(data.as_ref()),
15864 doc_format: Cow::Borrowed(doc_format.as_ref()),
15865 options: Cow::Borrowed(options.as_ref()),
15866 };
15867 let cookie = self.send_void_request(request, false)?;
15868 self.wait_for_reply(cookie)
15869 }
15870 #[cfg(feature = "xprint")]
15871 fn xprint_print_get_document_data(
15872 &mut self,
15873 context: types::Pcontext,
15874 max_bytes: types::Card32,
15875 ) -> Result<Cookie<types::xprint::PrintGetDocumentDataReply>> {
15876 let span = tracing::info_span!(
15877 "xprint_print_get_document_data",
15878 context = ?context,
15879 max_bytes = ?max_bytes,
15880 );
15881 let _enter = span.enter();
15882 let request = types::xprint::PrintGetDocumentDataRequest { context, max_bytes };
15883 let cookie = self.send_reply_request(request);
15884 cookie
15885 }
15886 #[cfg(feature = "xprint")]
15887 fn xprint_print_get_document_data_immediate(
15888 &mut self,
15889 context: types::Pcontext,
15890 max_bytes: types::Card32,
15891 ) -> Result<types::xprint::PrintGetDocumentDataReply> {
15892 let request = types::xprint::PrintGetDocumentDataRequest { context, max_bytes };
15893 let cookie = self.send_reply_request(request)?;
15894 self.wait_for_reply(cookie)
15895 }
15896 #[cfg(feature = "xprint")]
15897 fn xprint_print_start_page(&mut self, window: types::xproto::Window) -> Result<Cookie<()>> {
15898 let span = tracing::info_span!(
15899 "xprint_print_start_page",
15900 window = ?window,
15901 );
15902 let _enter = span.enter();
15903 let request = types::xprint::PrintStartPageRequest { window };
15904 let cookie = self.send_void_request(request, true);
15905 cookie
15906 }
15907 #[cfg(feature = "xprint")]
15908 fn xprint_print_start_page_checked(&mut self, window: types::xproto::Window) -> Result<()> {
15909 let request = types::xprint::PrintStartPageRequest { window };
15910 let cookie = self.send_void_request(request, false)?;
15911 self.wait_for_reply(cookie)
15912 }
15913 #[cfg(feature = "xprint")]
15914 fn xprint_print_end_page(&mut self, cancel: types::Bool) -> Result<Cookie<()>> {
15915 let span = tracing::info_span!(
15916 "xprint_print_end_page",
15917 cancel = ?cancel,
15918 );
15919 let _enter = span.enter();
15920 let request = types::xprint::PrintEndPageRequest { cancel };
15921 let cookie = self.send_void_request(request, true);
15922 cookie
15923 }
15924 #[cfg(feature = "xprint")]
15925 fn xprint_print_end_page_checked(&mut self, cancel: types::Bool) -> Result<()> {
15926 let request = types::xprint::PrintEndPageRequest { cancel };
15927 let cookie = self.send_void_request(request, false)?;
15928 self.wait_for_reply(cookie)
15929 }
15930 #[cfg(feature = "xprint")]
15931 fn xprint_print_select_input(
15932 &mut self,
15933 context: types::Pcontext,
15934 event_mask: types::Card32,
15935 ) -> Result<Cookie<()>> {
15936 let span = tracing::info_span!(
15937 "xprint_print_select_input",
15938 context = ?context,
15939 event_mask = ?event_mask,
15940 );
15941 let _enter = span.enter();
15942 let request = types::xprint::PrintSelectInputRequest {
15943 context,
15944 event_mask,
15945 };
15946 let cookie = self.send_void_request(request, true);
15947 cookie
15948 }
15949 #[cfg(feature = "xprint")]
15950 fn xprint_print_select_input_checked(
15951 &mut self,
15952 context: types::Pcontext,
15953 event_mask: types::Card32,
15954 ) -> Result<()> {
15955 let request = types::xprint::PrintSelectInputRequest {
15956 context,
15957 event_mask,
15958 };
15959 let cookie = self.send_void_request(request, false)?;
15960 self.wait_for_reply(cookie)
15961 }
15962 #[cfg(feature = "xprint")]
15963 fn xprint_print_input_selected(
15964 &mut self,
15965 context: types::Pcontext,
15966 ) -> Result<Cookie<types::xprint::PrintInputSelectedReply>> {
15967 let span = tracing::info_span!(
15968 "xprint_print_input_selected",
15969 context = ?context,
15970 );
15971 let _enter = span.enter();
15972 let request = types::xprint::PrintInputSelectedRequest { context };
15973 let cookie = self.send_reply_request(request);
15974 cookie
15975 }
15976 #[cfg(feature = "xprint")]
15977 fn xprint_print_input_selected_immediate(
15978 &mut self,
15979 context: types::Pcontext,
15980 ) -> Result<types::xprint::PrintInputSelectedReply> {
15981 let request = types::xprint::PrintInputSelectedRequest { context };
15982 let cookie = self.send_reply_request(request)?;
15983 self.wait_for_reply(cookie)
15984 }
15985 #[cfg(feature = "xprint")]
15986 fn xprint_print_get_attributes(
15987 &mut self,
15988 context: types::Pcontext,
15989 pool: types::Card8,
15990 ) -> Result<Cookie<types::xprint::PrintGetAttributesReply>> {
15991 let span = tracing::info_span!(
15992 "xprint_print_get_attributes",
15993 context = ?context,
15994 pool = ?pool,
15995 );
15996 let _enter = span.enter();
15997 let request = types::xprint::PrintGetAttributesRequest { context, pool };
15998 let cookie = self.send_reply_request(request);
15999 cookie
16000 }
16001 #[cfg(feature = "xprint")]
16002 fn xprint_print_get_attributes_immediate(
16003 &mut self,
16004 context: types::Pcontext,
16005 pool: types::Card8,
16006 ) -> Result<types::xprint::PrintGetAttributesReply> {
16007 let request = types::xprint::PrintGetAttributesRequest { context, pool };
16008 let cookie = self.send_reply_request(request)?;
16009 self.wait_for_reply(cookie)
16010 }
16011 #[cfg(feature = "xprint")]
16012 fn xprint_print_get_one_attributes(
16013 &mut self,
16014 context: types::Pcontext,
16015 pool: types::Card8,
16016 name: impl AsRef<[types::xprint::String8]>,
16017 ) -> Result<Cookie<types::xprint::PrintGetOneAttributesReply>> {
16018 let span = tracing::info_span!(
16019 "xprint_print_get_one_attributes",
16020 context = ?context,
16021 pool = ?pool,
16022 );
16023 let _enter = span.enter();
16024 let request = types::xprint::PrintGetOneAttributesRequest {
16025 context,
16026 pool,
16027 name: Cow::Borrowed(name.as_ref()),
16028 };
16029 let cookie = self.send_reply_request(request);
16030 cookie
16031 }
16032 #[cfg(feature = "xprint")]
16033 fn xprint_print_get_one_attributes_immediate(
16034 &mut self,
16035 context: types::Pcontext,
16036 pool: types::Card8,
16037 name: impl AsRef<[types::xprint::String8]>,
16038 ) -> Result<types::xprint::PrintGetOneAttributesReply> {
16039 let request = types::xprint::PrintGetOneAttributesRequest {
16040 context,
16041 pool,
16042 name: Cow::Borrowed(name.as_ref()),
16043 };
16044 let cookie = self.send_reply_request(request)?;
16045 self.wait_for_reply(cookie)
16046 }
16047 #[cfg(feature = "xprint")]
16048 fn xprint_print_set_attributes(
16049 &mut self,
16050 context: types::Pcontext,
16051 string_len: types::Card32,
16052 pool: types::Card8,
16053 rule: types::Card8,
16054 attributes: impl AsRef<[types::xprint::String8]>,
16055 ) -> Result<Cookie<()>> {
16056 let span = tracing::info_span!(
16057 "xprint_print_set_attributes",
16058 context = ?context,
16059 string_len = ?string_len,
16060 pool = ?pool,
16061 rule = ?rule,
16062 );
16063 let _enter = span.enter();
16064 let request = types::xprint::PrintSetAttributesRequest {
16065 context,
16066 string_len,
16067 pool,
16068 rule,
16069 attributes: Cow::Borrowed(attributes.as_ref()),
16070 };
16071 let cookie = self.send_void_request(request, true);
16072 cookie
16073 }
16074 #[cfg(feature = "xprint")]
16075 fn xprint_print_set_attributes_checked(
16076 &mut self,
16077 context: types::Pcontext,
16078 string_len: types::Card32,
16079 pool: types::Card8,
16080 rule: types::Card8,
16081 attributes: impl AsRef<[types::xprint::String8]>,
16082 ) -> Result<()> {
16083 let request = types::xprint::PrintSetAttributesRequest {
16084 context,
16085 string_len,
16086 pool,
16087 rule,
16088 attributes: Cow::Borrowed(attributes.as_ref()),
16089 };
16090 let cookie = self.send_void_request(request, false)?;
16091 self.wait_for_reply(cookie)
16092 }
16093 #[cfg(feature = "xprint")]
16094 fn xprint_print_get_page_dimensions(
16095 &mut self,
16096 context: types::Pcontext,
16097 ) -> Result<Cookie<types::xprint::PrintGetPageDimensionsReply>> {
16098 let span = tracing::info_span!(
16099 "xprint_print_get_page_dimensions",
16100 context = ?context,
16101 );
16102 let _enter = span.enter();
16103 let request = types::xprint::PrintGetPageDimensionsRequest { context };
16104 let cookie = self.send_reply_request(request);
16105 cookie
16106 }
16107 #[cfg(feature = "xprint")]
16108 fn xprint_print_get_page_dimensions_immediate(
16109 &mut self,
16110 context: types::Pcontext,
16111 ) -> Result<types::xprint::PrintGetPageDimensionsReply> {
16112 let request = types::xprint::PrintGetPageDimensionsRequest { context };
16113 let cookie = self.send_reply_request(request)?;
16114 self.wait_for_reply(cookie)
16115 }
16116 #[cfg(feature = "xprint")]
16117 fn xprint_print_query_screens(
16118 &mut self,
16119 ) -> Result<Cookie<types::xprint::PrintQueryScreensReply>> {
16120 let span = tracing::info_span!("xprint_print_query_screens",);
16121 let _enter = span.enter();
16122 let request = types::xprint::PrintQueryScreensRequest {};
16123 let cookie = self.send_reply_request(request);
16124 cookie
16125 }
16126 #[cfg(feature = "xprint")]
16127 fn xprint_print_query_screens_immediate(
16128 &mut self,
16129 ) -> Result<types::xprint::PrintQueryScreensReply> {
16130 let request = types::xprint::PrintQueryScreensRequest {};
16131 let cookie = self.send_reply_request(request)?;
16132 self.wait_for_reply(cookie)
16133 }
16134 #[cfg(feature = "xprint")]
16135 fn xprint_print_set_image_resolution(
16136 &mut self,
16137 context: types::Pcontext,
16138 image_resolution: types::Card16,
16139 ) -> Result<Cookie<types::xprint::PrintSetImageResolutionReply>> {
16140 let span = tracing::info_span!(
16141 "xprint_print_set_image_resolution",
16142 context = ?context,
16143 image_resolution = ?image_resolution,
16144 );
16145 let _enter = span.enter();
16146 let request = types::xprint::PrintSetImageResolutionRequest {
16147 context,
16148 image_resolution,
16149 };
16150 let cookie = self.send_reply_request(request);
16151 cookie
16152 }
16153 #[cfg(feature = "xprint")]
16154 fn xprint_print_set_image_resolution_immediate(
16155 &mut self,
16156 context: types::Pcontext,
16157 image_resolution: types::Card16,
16158 ) -> Result<types::xprint::PrintSetImageResolutionReply> {
16159 let request = types::xprint::PrintSetImageResolutionRequest {
16160 context,
16161 image_resolution,
16162 };
16163 let cookie = self.send_reply_request(request)?;
16164 self.wait_for_reply(cookie)
16165 }
16166 #[cfg(feature = "xprint")]
16167 fn xprint_print_get_image_resolution(
16168 &mut self,
16169 context: types::Pcontext,
16170 ) -> Result<Cookie<types::xprint::PrintGetImageResolutionReply>> {
16171 let span = tracing::info_span!(
16172 "xprint_print_get_image_resolution",
16173 context = ?context,
16174 );
16175 let _enter = span.enter();
16176 let request = types::xprint::PrintGetImageResolutionRequest { context };
16177 let cookie = self.send_reply_request(request);
16178 cookie
16179 }
16180 #[cfg(feature = "xprint")]
16181 fn xprint_print_get_image_resolution_immediate(
16182 &mut self,
16183 context: types::Pcontext,
16184 ) -> Result<types::xprint::PrintGetImageResolutionReply> {
16185 let request = types::xprint::PrintGetImageResolutionRequest { context };
16186 let cookie = self.send_reply_request(request)?;
16187 self.wait_for_reply(cookie)
16188 }
16189
16190 fn create_window(
16191 &mut self,
16192 depth: types::Card8,
16193 wid: types::xproto::Window,
16194 parent: types::xproto::Window,
16195 x: types::Int16,
16196 y: types::Int16,
16197 width: types::Card16,
16198 height: types::Card16,
16199 border_width: types::Card16,
16200 class: types::WindowClass,
16201 visual: types::Visualid,
16202 value_list: impl Borrow<types::xproto::CreateWindowAux>,
16203 ) -> Result<Cookie<()>> {
16204 let span = tracing::info_span!(
16205 "create_window",
16206 depth = ?depth,
16207 wid = ?wid,
16208 parent = ?parent,
16209 x = ?x,
16210 y = ?y,
16211 width = ?width,
16212 height = ?height,
16213 border_width = ?border_width,
16214 class = ?class,
16215 visual = ?visual,
16216 );
16217 let _enter = span.enter();
16218 let request = types::xproto::CreateWindowRequest {
16219 depth,
16220 wid,
16221 parent,
16222 x,
16223 y,
16224 width,
16225 height,
16226 border_width,
16227 class,
16228 visual,
16229 value_list: Cow::Borrowed(value_list.borrow()),
16230 };
16231 let cookie = self.send_void_request(request, true);
16232 cookie
16233 }
16234 fn create_window_checked(
16235 &mut self,
16236 depth: types::Card8,
16237 wid: types::xproto::Window,
16238 parent: types::xproto::Window,
16239 x: types::Int16,
16240 y: types::Int16,
16241 width: types::Card16,
16242 height: types::Card16,
16243 border_width: types::Card16,
16244 class: types::WindowClass,
16245 visual: types::Visualid,
16246 value_list: impl Borrow<types::xproto::CreateWindowAux>,
16247 ) -> Result<()> {
16248 let request = types::xproto::CreateWindowRequest {
16249 depth,
16250 wid,
16251 parent,
16252 x,
16253 y,
16254 width,
16255 height,
16256 border_width,
16257 class,
16258 visual,
16259 value_list: Cow::Borrowed(value_list.borrow()),
16260 };
16261 let cookie = self.send_void_request(request, false)?;
16262 self.wait_for_reply(cookie)
16263 }
16264 fn change_window_attributes(
16265 &mut self,
16266 window: types::xproto::Window,
16267 value_list: impl Borrow<types::xproto::ChangeWindowAttributesAux>,
16268 ) -> Result<Cookie<()>> {
16269 let span = tracing::info_span!(
16270 "change_window_attributes",
16271 window = ?window,
16272 );
16273 let _enter = span.enter();
16274 let request = types::xproto::ChangeWindowAttributesRequest {
16275 window,
16276 value_list: Cow::Borrowed(value_list.borrow()),
16277 };
16278 let cookie = self.send_void_request(request, true);
16279 cookie
16280 }
16281 fn change_window_attributes_checked(
16282 &mut self,
16283 window: types::xproto::Window,
16284 value_list: impl Borrow<types::xproto::ChangeWindowAttributesAux>,
16285 ) -> Result<()> {
16286 let request = types::xproto::ChangeWindowAttributesRequest {
16287 window,
16288 value_list: Cow::Borrowed(value_list.borrow()),
16289 };
16290 let cookie = self.send_void_request(request, false)?;
16291 self.wait_for_reply(cookie)
16292 }
16293 fn get_window_attributes(
16294 &mut self,
16295 window: types::xproto::Window,
16296 ) -> Result<Cookie<types::xproto::GetWindowAttributesReply>> {
16297 let span = tracing::info_span!(
16298 "get_window_attributes",
16299 window = ?window,
16300 );
16301 let _enter = span.enter();
16302 let request = types::xproto::GetWindowAttributesRequest { window };
16303 let cookie = self.send_reply_request(request);
16304 cookie
16305 }
16306 fn get_window_attributes_immediate(
16307 &mut self,
16308 window: types::xproto::Window,
16309 ) -> Result<types::xproto::GetWindowAttributesReply> {
16310 let request = types::xproto::GetWindowAttributesRequest { window };
16311 let cookie = self.send_reply_request(request)?;
16312 self.wait_for_reply(cookie)
16313 }
16314 fn destroy_window(&mut self, window: types::xproto::Window) -> Result<Cookie<()>> {
16315 let span = tracing::info_span!(
16316 "destroy_window",
16317 window = ?window,
16318 );
16319 let _enter = span.enter();
16320 let request = types::xproto::DestroyWindowRequest { window };
16321 let cookie = self.send_void_request(request, true);
16322 cookie
16323 }
16324 fn destroy_window_checked(&mut self, window: types::xproto::Window) -> Result<()> {
16325 let request = types::xproto::DestroyWindowRequest { window };
16326 let cookie = self.send_void_request(request, false)?;
16327 self.wait_for_reply(cookie)
16328 }
16329 fn destroy_subwindows(&mut self, window: types::xproto::Window) -> Result<Cookie<()>> {
16330 let span = tracing::info_span!(
16331 "destroy_subwindows",
16332 window = ?window,
16333 );
16334 let _enter = span.enter();
16335 let request = types::xproto::DestroySubwindowsRequest { window };
16336 let cookie = self.send_void_request(request, true);
16337 cookie
16338 }
16339 fn destroy_subwindows_checked(&mut self, window: types::xproto::Window) -> Result<()> {
16340 let request = types::xproto::DestroySubwindowsRequest { window };
16341 let cookie = self.send_void_request(request, false)?;
16342 self.wait_for_reply(cookie)
16343 }
16344 fn change_save_set(
16345 &mut self,
16346 mode: types::SetMode,
16347 window: types::xproto::Window,
16348 ) -> Result<Cookie<()>> {
16349 let span = tracing::info_span!(
16350 "change_save_set",
16351 mode = ?mode,
16352 window = ?window,
16353 );
16354 let _enter = span.enter();
16355 let request = types::xproto::ChangeSaveSetRequest { mode, window };
16356 let cookie = self.send_void_request(request, true);
16357 cookie
16358 }
16359 fn change_save_set_checked(
16360 &mut self,
16361 mode: types::SetMode,
16362 window: types::xproto::Window,
16363 ) -> Result<()> {
16364 let request = types::xproto::ChangeSaveSetRequest { mode, window };
16365 let cookie = self.send_void_request(request, false)?;
16366 self.wait_for_reply(cookie)
16367 }
16368 fn reparent_window(
16369 &mut self,
16370 window: types::xproto::Window,
16371 parent: types::xproto::Window,
16372 x: types::Int16,
16373 y: types::Int16,
16374 ) -> Result<Cookie<()>> {
16375 let span = tracing::info_span!(
16376 "reparent_window",
16377 window = ?window,
16378 parent = ?parent,
16379 x = ?x,
16380 y = ?y,
16381 );
16382 let _enter = span.enter();
16383 let request = types::xproto::ReparentWindowRequest {
16384 window,
16385 parent,
16386 x,
16387 y,
16388 };
16389 let cookie = self.send_void_request(request, true);
16390 cookie
16391 }
16392 fn reparent_window_checked(
16393 &mut self,
16394 window: types::xproto::Window,
16395 parent: types::xproto::Window,
16396 x: types::Int16,
16397 y: types::Int16,
16398 ) -> Result<()> {
16399 let request = types::xproto::ReparentWindowRequest {
16400 window,
16401 parent,
16402 x,
16403 y,
16404 };
16405 let cookie = self.send_void_request(request, false)?;
16406 self.wait_for_reply(cookie)
16407 }
16408 fn map_window(&mut self, window: types::xproto::Window) -> Result<Cookie<()>> {
16409 let span = tracing::info_span!(
16410 "map_window",
16411 window = ?window,
16412 );
16413 let _enter = span.enter();
16414 let request = types::xproto::MapWindowRequest { window };
16415 let cookie = self.send_void_request(request, true);
16416 cookie
16417 }
16418 fn map_window_checked(&mut self, window: types::xproto::Window) -> Result<()> {
16419 let request = types::xproto::MapWindowRequest { window };
16420 let cookie = self.send_void_request(request, false)?;
16421 self.wait_for_reply(cookie)
16422 }
16423 fn map_subwindows(&mut self, window: types::xproto::Window) -> Result<Cookie<()>> {
16424 let span = tracing::info_span!(
16425 "map_subwindows",
16426 window = ?window,
16427 );
16428 let _enter = span.enter();
16429 let request = types::xproto::MapSubwindowsRequest { window };
16430 let cookie = self.send_void_request(request, true);
16431 cookie
16432 }
16433 fn map_subwindows_checked(&mut self, window: types::xproto::Window) -> Result<()> {
16434 let request = types::xproto::MapSubwindowsRequest { window };
16435 let cookie = self.send_void_request(request, false)?;
16436 self.wait_for_reply(cookie)
16437 }
16438 fn unmap_window(&mut self, window: types::xproto::Window) -> Result<Cookie<()>> {
16439 let span = tracing::info_span!(
16440 "unmap_window",
16441 window = ?window,
16442 );
16443 let _enter = span.enter();
16444 let request = types::xproto::UnmapWindowRequest { window };
16445 let cookie = self.send_void_request(request, true);
16446 cookie
16447 }
16448 fn unmap_window_checked(&mut self, window: types::xproto::Window) -> Result<()> {
16449 let request = types::xproto::UnmapWindowRequest { window };
16450 let cookie = self.send_void_request(request, false)?;
16451 self.wait_for_reply(cookie)
16452 }
16453 fn unmap_subwindows(&mut self, window: types::xproto::Window) -> Result<Cookie<()>> {
16454 let span = tracing::info_span!(
16455 "unmap_subwindows",
16456 window = ?window,
16457 );
16458 let _enter = span.enter();
16459 let request = types::xproto::UnmapSubwindowsRequest { window };
16460 let cookie = self.send_void_request(request, true);
16461 cookie
16462 }
16463 fn unmap_subwindows_checked(&mut self, window: types::xproto::Window) -> Result<()> {
16464 let request = types::xproto::UnmapSubwindowsRequest { window };
16465 let cookie = self.send_void_request(request, false)?;
16466 self.wait_for_reply(cookie)
16467 }
16468 fn configure_window(
16469 &mut self,
16470 window: types::xproto::Window,
16471 value_list: impl Borrow<types::xproto::ConfigureWindowAux>,
16472 ) -> Result<Cookie<()>> {
16473 let span = tracing::info_span!(
16474 "configure_window",
16475 window = ?window,
16476 );
16477 let _enter = span.enter();
16478 let request = types::xproto::ConfigureWindowRequest {
16479 window,
16480 value_list: Cow::Borrowed(value_list.borrow()),
16481 };
16482 let cookie = self.send_void_request(request, true);
16483 cookie
16484 }
16485 fn configure_window_checked(
16486 &mut self,
16487 window: types::xproto::Window,
16488 value_list: impl Borrow<types::xproto::ConfigureWindowAux>,
16489 ) -> Result<()> {
16490 let request = types::xproto::ConfigureWindowRequest {
16491 window,
16492 value_list: Cow::Borrowed(value_list.borrow()),
16493 };
16494 let cookie = self.send_void_request(request, false)?;
16495 self.wait_for_reply(cookie)
16496 }
16497 fn circulate_window(
16498 &mut self,
16499 direction: types::Circulate,
16500 window: types::xproto::Window,
16501 ) -> Result<Cookie<()>> {
16502 let span = tracing::info_span!(
16503 "circulate_window",
16504 direction = ?direction,
16505 window = ?window,
16506 );
16507 let _enter = span.enter();
16508 let request = types::xproto::CirculateWindowRequest { direction, window };
16509 let cookie = self.send_void_request(request, true);
16510 cookie
16511 }
16512 fn circulate_window_checked(
16513 &mut self,
16514 direction: types::Circulate,
16515 window: types::xproto::Window,
16516 ) -> Result<()> {
16517 let request = types::xproto::CirculateWindowRequest { direction, window };
16518 let cookie = self.send_void_request(request, false)?;
16519 self.wait_for_reply(cookie)
16520 }
16521 fn get_geometry(
16522 &mut self,
16523 drawable: types::xproto::Drawable,
16524 ) -> Result<Cookie<types::xproto::GetGeometryReply>> {
16525 let span = tracing::info_span!(
16526 "get_geometry",
16527 drawable = ?drawable,
16528 );
16529 let _enter = span.enter();
16530 let request = types::xproto::GetGeometryRequest { drawable };
16531 let cookie = self.send_reply_request(request);
16532 cookie
16533 }
16534 fn get_geometry_immediate(
16535 &mut self,
16536 drawable: types::xproto::Drawable,
16537 ) -> Result<types::xproto::GetGeometryReply> {
16538 let request = types::xproto::GetGeometryRequest { drawable };
16539 let cookie = self.send_reply_request(request)?;
16540 self.wait_for_reply(cookie)
16541 }
16542 fn query_tree(
16543 &mut self,
16544 window: types::xproto::Window,
16545 ) -> Result<Cookie<types::xproto::QueryTreeReply>> {
16546 let span = tracing::info_span!(
16547 "query_tree",
16548 window = ?window,
16549 );
16550 let _enter = span.enter();
16551 let request = types::xproto::QueryTreeRequest { window };
16552 let cookie = self.send_reply_request(request);
16553 cookie
16554 }
16555 fn query_tree_immediate(
16556 &mut self,
16557 window: types::xproto::Window,
16558 ) -> Result<types::xproto::QueryTreeReply> {
16559 let request = types::xproto::QueryTreeRequest { window };
16560 let cookie = self.send_reply_request(request)?;
16561 self.wait_for_reply(cookie)
16562 }
16563 fn intern_atom(
16564 &mut self,
16565 only_if_exists: types::Bool,
16566 name: impl AsRef<[types::Char]>,
16567 ) -> Result<Cookie<types::xproto::InternAtomReply>> {
16568 let span = tracing::info_span!(
16569 "intern_atom",
16570 only_if_exists = ?only_if_exists,
16571 );
16572 let _enter = span.enter();
16573 let request = types::xproto::InternAtomRequest {
16574 only_if_exists,
16575 name: Cow::Borrowed(name.as_ref()),
16576 };
16577 let cookie = self.send_reply_request(request);
16578 cookie
16579 }
16580 fn intern_atom_immediate(
16581 &mut self,
16582 only_if_exists: types::Bool,
16583 name: impl AsRef<[types::Char]>,
16584 ) -> Result<types::xproto::InternAtomReply> {
16585 let request = types::xproto::InternAtomRequest {
16586 only_if_exists,
16587 name: Cow::Borrowed(name.as_ref()),
16588 };
16589 let cookie = self.send_reply_request(request)?;
16590 self.wait_for_reply(cookie)
16591 }
16592 fn get_atom_name(
16593 &mut self,
16594 atom: types::Atom,
16595 ) -> Result<Cookie<types::xproto::GetAtomNameReply>> {
16596 let span = tracing::info_span!(
16597 "get_atom_name",
16598 atom = ?atom,
16599 );
16600 let _enter = span.enter();
16601 let request = types::xproto::GetAtomNameRequest { atom };
16602 let cookie = self.send_reply_request(request);
16603 cookie
16604 }
16605 fn get_atom_name_immediate(
16606 &mut self,
16607 atom: types::Atom,
16608 ) -> Result<types::xproto::GetAtomNameReply> {
16609 let request = types::xproto::GetAtomNameRequest { atom };
16610 let cookie = self.send_reply_request(request)?;
16611 self.wait_for_reply(cookie)
16612 }
16613 fn change_property(
16614 &mut self,
16615 mode: types::PropMode,
16616 window: types::xproto::Window,
16617 property: types::Atom,
16618 type_: types::Atom,
16619 format: types::Card8,
16620 data_len: types::Card32,
16621 data: &(impl crate::Void + ?Sized),
16622 ) -> Result<Cookie<()>> {
16623 let span = tracing::info_span!(
16624 "change_property",
16625 mode = ?mode,
16626 window = ?window,
16627 property = ?property,
16628 type_ = ?type_,
16629 format = ?format,
16630 data_len = ?data_len,
16631 );
16632 let _enter = span.enter();
16633 let request = types::xproto::ChangePropertyRequest {
16634 mode,
16635 window,
16636 property,
16637 type_,
16638 format,
16639 data_len,
16640 data: Cow::Borrowed(data.bytes()),
16641 };
16642 let cookie = self.send_void_request(request, true);
16643 cookie
16644 }
16645 fn change_property_checked(
16646 &mut self,
16647 mode: types::PropMode,
16648 window: types::xproto::Window,
16649 property: types::Atom,
16650 type_: types::Atom,
16651 format: types::Card8,
16652 data_len: types::Card32,
16653 data: &(impl crate::Void + ?Sized),
16654 ) -> Result<()> {
16655 let request = types::xproto::ChangePropertyRequest {
16656 mode,
16657 window,
16658 property,
16659 type_,
16660 format,
16661 data_len,
16662 data: Cow::Borrowed(data.bytes()),
16663 };
16664 let cookie = self.send_void_request(request, false)?;
16665 self.wait_for_reply(cookie)
16666 }
16667 fn delete_property(
16668 &mut self,
16669 window: types::xproto::Window,
16670 property: types::Atom,
16671 ) -> Result<Cookie<()>> {
16672 let span = tracing::info_span!(
16673 "delete_property",
16674 window = ?window,
16675 property = ?property,
16676 );
16677 let _enter = span.enter();
16678 let request = types::xproto::DeletePropertyRequest { window, property };
16679 let cookie = self.send_void_request(request, true);
16680 cookie
16681 }
16682 fn delete_property_checked(
16683 &mut self,
16684 window: types::xproto::Window,
16685 property: types::Atom,
16686 ) -> Result<()> {
16687 let request = types::xproto::DeletePropertyRequest { window, property };
16688 let cookie = self.send_void_request(request, false)?;
16689 self.wait_for_reply(cookie)
16690 }
16691 fn get_property(
16692 &mut self,
16693 delete: types::Bool,
16694 window: types::xproto::Window,
16695 property: types::Atom,
16696 type_: impl Into<types::GetPropertyType>,
16697 long_offset: types::Card32,
16698 long_length: types::Card32,
16699 ) -> Result<Cookie<types::xproto::GetPropertyReply>> {
16700 let span = tracing::info_span!(
16701 "get_property",
16702 delete = ?delete,
16703 window = ?window,
16704 property = ?property,
16705 long_offset = ?long_offset,
16706 long_length = ?long_length,
16707 );
16708 let _enter = span.enter();
16709 let request = types::xproto::GetPropertyRequest {
16710 delete,
16711 window,
16712 property,
16713 type_: Into::<u32>::into(type_.into()) as _,
16714 long_offset,
16715 long_length,
16716 };
16717 let cookie = self.send_reply_request(request);
16718 cookie
16719 }
16720 fn get_property_immediate(
16721 &mut self,
16722 delete: types::Bool,
16723 window: types::xproto::Window,
16724 property: types::Atom,
16725 type_: impl Into<types::GetPropertyType>,
16726 long_offset: types::Card32,
16727 long_length: types::Card32,
16728 ) -> Result<types::xproto::GetPropertyReply> {
16729 let request = types::xproto::GetPropertyRequest {
16730 delete,
16731 window,
16732 property,
16733 type_: Into::<u32>::into(type_.into()) as _,
16734 long_offset,
16735 long_length,
16736 };
16737 let cookie = self.send_reply_request(request)?;
16738 self.wait_for_reply(cookie)
16739 }
16740 fn list_properties(
16741 &mut self,
16742 window: types::xproto::Window,
16743 ) -> Result<Cookie<types::xproto::ListPropertiesReply>> {
16744 let span = tracing::info_span!(
16745 "list_properties",
16746 window = ?window,
16747 );
16748 let _enter = span.enter();
16749 let request = types::xproto::ListPropertiesRequest { window };
16750 let cookie = self.send_reply_request(request);
16751 cookie
16752 }
16753 fn list_properties_immediate(
16754 &mut self,
16755 window: types::xproto::Window,
16756 ) -> Result<types::xproto::ListPropertiesReply> {
16757 let request = types::xproto::ListPropertiesRequest { window };
16758 let cookie = self.send_reply_request(request)?;
16759 self.wait_for_reply(cookie)
16760 }
16761 fn set_selection_owner(
16762 &mut self,
16763 owner: impl Into<types::xproto::Window>,
16764 selection: types::Atom,
16765 time: impl Into<types::Time>,
16766 ) -> Result<Cookie<()>> {
16767 let span = tracing::info_span!(
16768 "set_selection_owner",
16769 selection = ?selection,
16770 );
16771 let _enter = span.enter();
16772 let request = types::xproto::SetSelectionOwnerRequest {
16773 owner: Into::<u32>::into(owner.into()) as _,
16774 selection,
16775 time: Into::<u32>::into(time.into()) as _,
16776 };
16777 let cookie = self.send_void_request(request, true);
16778 cookie
16779 }
16780 fn set_selection_owner_checked(
16781 &mut self,
16782 owner: impl Into<types::xproto::Window>,
16783 selection: types::Atom,
16784 time: impl Into<types::Time>,
16785 ) -> Result<()> {
16786 let request = types::xproto::SetSelectionOwnerRequest {
16787 owner: Into::<u32>::into(owner.into()) as _,
16788 selection,
16789 time: Into::<u32>::into(time.into()) as _,
16790 };
16791 let cookie = self.send_void_request(request, false)?;
16792 self.wait_for_reply(cookie)
16793 }
16794 fn get_selection_owner(
16795 &mut self,
16796 selection: types::Atom,
16797 ) -> Result<Cookie<types::xproto::GetSelectionOwnerReply>> {
16798 let span = tracing::info_span!(
16799 "get_selection_owner",
16800 selection = ?selection,
16801 );
16802 let _enter = span.enter();
16803 let request = types::xproto::GetSelectionOwnerRequest { selection };
16804 let cookie = self.send_reply_request(request);
16805 cookie
16806 }
16807 fn get_selection_owner_immediate(
16808 &mut self,
16809 selection: types::Atom,
16810 ) -> Result<types::xproto::GetSelectionOwnerReply> {
16811 let request = types::xproto::GetSelectionOwnerRequest { selection };
16812 let cookie = self.send_reply_request(request)?;
16813 self.wait_for_reply(cookie)
16814 }
16815 fn convert_selection(
16816 &mut self,
16817 requestor: types::xproto::Window,
16818 selection: types::Atom,
16819 target: types::Atom,
16820 property: impl Into<types::Atom>,
16821 time: impl Into<types::Time>,
16822 ) -> Result<Cookie<()>> {
16823 let span = tracing::info_span!(
16824 "convert_selection",
16825 requestor = ?requestor,
16826 selection = ?selection,
16827 target = ?target,
16828 );
16829 let _enter = span.enter();
16830 let request = types::xproto::ConvertSelectionRequest {
16831 requestor,
16832 selection,
16833 target,
16834 property: Into::<u32>::into(property.into()) as _,
16835 time: Into::<u32>::into(time.into()) as _,
16836 };
16837 let cookie = self.send_void_request(request, true);
16838 cookie
16839 }
16840 fn convert_selection_checked(
16841 &mut self,
16842 requestor: types::xproto::Window,
16843 selection: types::Atom,
16844 target: types::Atom,
16845 property: impl Into<types::Atom>,
16846 time: impl Into<types::Time>,
16847 ) -> Result<()> {
16848 let request = types::xproto::ConvertSelectionRequest {
16849 requestor,
16850 selection,
16851 target,
16852 property: Into::<u32>::into(property.into()) as _,
16853 time: Into::<u32>::into(time.into()) as _,
16854 };
16855 let cookie = self.send_void_request(request, false)?;
16856 self.wait_for_reply(cookie)
16857 }
16858 fn send_event(
16859 &mut self,
16860 propagate: types::Bool,
16861 destination: impl Into<types::SendEventDest>,
16862 event_mask: impl Into<types::xproto::EventMask>,
16863 event: impl Borrow<[types::Char; 32]>,
16864 ) -> Result<Cookie<()>> {
16865 let span = tracing::info_span!(
16866 "send_event",
16867 propagate = ?propagate,
16868 );
16869 let _enter = span.enter();
16870 let request = types::xproto::SendEventRequest {
16871 propagate,
16872 destination: Into::<u32>::into(destination.into()) as _,
16873 event_mask: Into::<u32>::into(event_mask.into()) as _,
16874 event: Cow::Borrowed(event.borrow()),
16875 };
16876 let cookie = self.send_void_request(request, true);
16877 cookie
16878 }
16879 fn send_event_checked(
16880 &mut self,
16881 propagate: types::Bool,
16882 destination: impl Into<types::SendEventDest>,
16883 event_mask: impl Into<types::xproto::EventMask>,
16884 event: impl Borrow<[types::Char; 32]>,
16885 ) -> Result<()> {
16886 let request = types::xproto::SendEventRequest {
16887 propagate,
16888 destination: Into::<u32>::into(destination.into()) as _,
16889 event_mask: Into::<u32>::into(event_mask.into()) as _,
16890 event: Cow::Borrowed(event.borrow()),
16891 };
16892 let cookie = self.send_void_request(request, false)?;
16893 self.wait_for_reply(cookie)
16894 }
16895 fn grab_pointer(
16896 &mut self,
16897 owner_events: types::Bool,
16898 grab_window: types::xproto::Window,
16899 event_mask: impl Into<types::xproto::EventMask>,
16900 pointer_mode: types::GrabMode,
16901 keyboard_mode: types::GrabMode,
16902 confine_to: impl Into<types::xproto::Window>,
16903 cursor: impl Into<types::xproto::Cursor>,
16904 time: impl Into<types::Time>,
16905 ) -> Result<Cookie<types::xproto::GrabPointerReply>> {
16906 let span = tracing::info_span!(
16907 "grab_pointer",
16908 owner_events = ?owner_events,
16909 grab_window = ?grab_window,
16910 pointer_mode = ?pointer_mode,
16911 keyboard_mode = ?keyboard_mode,
16912 );
16913 let _enter = span.enter();
16914 let request = types::xproto::GrabPointerRequest {
16915 owner_events,
16916 grab_window,
16917 event_mask: Into::<u32>::into(event_mask.into()) as _,
16918 pointer_mode,
16919 keyboard_mode,
16920 confine_to: Into::<u32>::into(confine_to.into()) as _,
16921 cursor: Into::<u32>::into(cursor.into()) as _,
16922 time: Into::<u32>::into(time.into()) as _,
16923 };
16924 let cookie = self.send_reply_request(request);
16925 cookie
16926 }
16927 fn grab_pointer_immediate(
16928 &mut self,
16929 owner_events: types::Bool,
16930 grab_window: types::xproto::Window,
16931 event_mask: impl Into<types::xproto::EventMask>,
16932 pointer_mode: types::GrabMode,
16933 keyboard_mode: types::GrabMode,
16934 confine_to: impl Into<types::xproto::Window>,
16935 cursor: impl Into<types::xproto::Cursor>,
16936 time: impl Into<types::Time>,
16937 ) -> Result<types::xproto::GrabPointerReply> {
16938 let request = types::xproto::GrabPointerRequest {
16939 owner_events,
16940 grab_window,
16941 event_mask: Into::<u32>::into(event_mask.into()) as _,
16942 pointer_mode,
16943 keyboard_mode,
16944 confine_to: Into::<u32>::into(confine_to.into()) as _,
16945 cursor: Into::<u32>::into(cursor.into()) as _,
16946 time: Into::<u32>::into(time.into()) as _,
16947 };
16948 let cookie = self.send_reply_request(request)?;
16949 self.wait_for_reply(cookie)
16950 }
16951 fn ungrab_pointer(&mut self, time: impl Into<types::Time>) -> Result<Cookie<()>> {
16952 let span = tracing::info_span!("ungrab_pointer",);
16953 let _enter = span.enter();
16954 let request = types::xproto::UngrabPointerRequest {
16955 time: Into::<u32>::into(time.into()) as _,
16956 };
16957 let cookie = self.send_void_request(request, true);
16958 cookie
16959 }
16960 fn ungrab_pointer_checked(&mut self, time: impl Into<types::Time>) -> Result<()> {
16961 let request = types::xproto::UngrabPointerRequest {
16962 time: Into::<u32>::into(time.into()) as _,
16963 };
16964 let cookie = self.send_void_request(request, false)?;
16965 self.wait_for_reply(cookie)
16966 }
16967 fn grab_button(
16968 &mut self,
16969 owner_events: types::Bool,
16970 grab_window: types::xproto::Window,
16971 event_mask: impl Into<types::xproto::EventMask>,
16972 pointer_mode: types::GrabMode,
16973 keyboard_mode: types::GrabMode,
16974 confine_to: impl Into<types::xproto::Window>,
16975 cursor: impl Into<types::xproto::Cursor>,
16976 button: types::ButtonIndex,
16977 modifiers: impl Into<types::ModMask>,
16978 ) -> Result<Cookie<()>> {
16979 let span = tracing::info_span!(
16980 "grab_button",
16981 owner_events = ?owner_events,
16982 grab_window = ?grab_window,
16983 pointer_mode = ?pointer_mode,
16984 keyboard_mode = ?keyboard_mode,
16985 button = ?button,
16986 );
16987 let _enter = span.enter();
16988 let request = types::xproto::GrabButtonRequest {
16989 owner_events,
16990 grab_window,
16991 event_mask: Into::<u32>::into(event_mask.into()) as _,
16992 pointer_mode,
16993 keyboard_mode,
16994 confine_to: Into::<u32>::into(confine_to.into()) as _,
16995 cursor: Into::<u32>::into(cursor.into()) as _,
16996 button,
16997 modifiers: Into::<u32>::into(modifiers.into()) as _,
16998 };
16999 let cookie = self.send_void_request(request, true);
17000 cookie
17001 }
17002 fn grab_button_checked(
17003 &mut self,
17004 owner_events: types::Bool,
17005 grab_window: types::xproto::Window,
17006 event_mask: impl Into<types::xproto::EventMask>,
17007 pointer_mode: types::GrabMode,
17008 keyboard_mode: types::GrabMode,
17009 confine_to: impl Into<types::xproto::Window>,
17010 cursor: impl Into<types::xproto::Cursor>,
17011 button: types::ButtonIndex,
17012 modifiers: impl Into<types::ModMask>,
17013 ) -> Result<()> {
17014 let request = types::xproto::GrabButtonRequest {
17015 owner_events,
17016 grab_window,
17017 event_mask: Into::<u32>::into(event_mask.into()) as _,
17018 pointer_mode,
17019 keyboard_mode,
17020 confine_to: Into::<u32>::into(confine_to.into()) as _,
17021 cursor: Into::<u32>::into(cursor.into()) as _,
17022 button,
17023 modifiers: Into::<u32>::into(modifiers.into()) as _,
17024 };
17025 let cookie = self.send_void_request(request, false)?;
17026 self.wait_for_reply(cookie)
17027 }
17028 fn ungrab_button(
17029 &mut self,
17030 button: types::ButtonIndex,
17031 grab_window: types::xproto::Window,
17032 modifiers: impl Into<types::ModMask>,
17033 ) -> Result<Cookie<()>> {
17034 let span = tracing::info_span!(
17035 "ungrab_button",
17036 button = ?button,
17037 grab_window = ?grab_window,
17038 );
17039 let _enter = span.enter();
17040 let request = types::xproto::UngrabButtonRequest {
17041 button,
17042 grab_window,
17043 modifiers: Into::<u32>::into(modifiers.into()) as _,
17044 };
17045 let cookie = self.send_void_request(request, true);
17046 cookie
17047 }
17048 fn ungrab_button_checked(
17049 &mut self,
17050 button: types::ButtonIndex,
17051 grab_window: types::xproto::Window,
17052 modifiers: impl Into<types::ModMask>,
17053 ) -> Result<()> {
17054 let request = types::xproto::UngrabButtonRequest {
17055 button,
17056 grab_window,
17057 modifiers: Into::<u32>::into(modifiers.into()) as _,
17058 };
17059 let cookie = self.send_void_request(request, false)?;
17060 self.wait_for_reply(cookie)
17061 }
17062 fn change_active_pointer_grab(
17063 &mut self,
17064 cursor: impl Into<types::xproto::Cursor>,
17065 time: impl Into<types::Time>,
17066 event_mask: impl Into<types::xproto::EventMask>,
17067 ) -> Result<Cookie<()>> {
17068 let span = tracing::info_span!("change_active_pointer_grab",);
17069 let _enter = span.enter();
17070 let request = types::xproto::ChangeActivePointerGrabRequest {
17071 cursor: Into::<u32>::into(cursor.into()) as _,
17072 time: Into::<u32>::into(time.into()) as _,
17073 event_mask: Into::<u32>::into(event_mask.into()) as _,
17074 };
17075 let cookie = self.send_void_request(request, true);
17076 cookie
17077 }
17078 fn change_active_pointer_grab_checked(
17079 &mut self,
17080 cursor: impl Into<types::xproto::Cursor>,
17081 time: impl Into<types::Time>,
17082 event_mask: impl Into<types::xproto::EventMask>,
17083 ) -> Result<()> {
17084 let request = types::xproto::ChangeActivePointerGrabRequest {
17085 cursor: Into::<u32>::into(cursor.into()) as _,
17086 time: Into::<u32>::into(time.into()) as _,
17087 event_mask: Into::<u32>::into(event_mask.into()) as _,
17088 };
17089 let cookie = self.send_void_request(request, false)?;
17090 self.wait_for_reply(cookie)
17091 }
17092 fn grab_keyboard(
17093 &mut self,
17094 owner_events: types::Bool,
17095 grab_window: types::xproto::Window,
17096 time: impl Into<types::Time>,
17097 pointer_mode: types::GrabMode,
17098 keyboard_mode: types::GrabMode,
17099 ) -> Result<Cookie<types::xproto::GrabKeyboardReply>> {
17100 let span = tracing::info_span!(
17101 "grab_keyboard",
17102 owner_events = ?owner_events,
17103 grab_window = ?grab_window,
17104 pointer_mode = ?pointer_mode,
17105 keyboard_mode = ?keyboard_mode,
17106 );
17107 let _enter = span.enter();
17108 let request = types::xproto::GrabKeyboardRequest {
17109 owner_events,
17110 grab_window,
17111 time: Into::<u32>::into(time.into()) as _,
17112 pointer_mode,
17113 keyboard_mode,
17114 };
17115 let cookie = self.send_reply_request(request);
17116 cookie
17117 }
17118 fn grab_keyboard_immediate(
17119 &mut self,
17120 owner_events: types::Bool,
17121 grab_window: types::xproto::Window,
17122 time: impl Into<types::Time>,
17123 pointer_mode: types::GrabMode,
17124 keyboard_mode: types::GrabMode,
17125 ) -> Result<types::xproto::GrabKeyboardReply> {
17126 let request = types::xproto::GrabKeyboardRequest {
17127 owner_events,
17128 grab_window,
17129 time: Into::<u32>::into(time.into()) as _,
17130 pointer_mode,
17131 keyboard_mode,
17132 };
17133 let cookie = self.send_reply_request(request)?;
17134 self.wait_for_reply(cookie)
17135 }
17136 fn ungrab_keyboard(&mut self, time: impl Into<types::Time>) -> Result<Cookie<()>> {
17137 let span = tracing::info_span!("ungrab_keyboard",);
17138 let _enter = span.enter();
17139 let request = types::xproto::UngrabKeyboardRequest {
17140 time: Into::<u32>::into(time.into()) as _,
17141 };
17142 let cookie = self.send_void_request(request, true);
17143 cookie
17144 }
17145 fn ungrab_keyboard_checked(&mut self, time: impl Into<types::Time>) -> Result<()> {
17146 let request = types::xproto::UngrabKeyboardRequest {
17147 time: Into::<u32>::into(time.into()) as _,
17148 };
17149 let cookie = self.send_void_request(request, false)?;
17150 self.wait_for_reply(cookie)
17151 }
17152 fn grab_key(
17153 &mut self,
17154 owner_events: types::Bool,
17155 grab_window: types::xproto::Window,
17156 modifiers: impl Into<types::ModMask>,
17157 key: impl Into<types::Grab>,
17158 pointer_mode: types::GrabMode,
17159 keyboard_mode: types::GrabMode,
17160 ) -> Result<Cookie<()>> {
17161 let span = tracing::info_span!(
17162 "grab_key",
17163 owner_events = ?owner_events,
17164 grab_window = ?grab_window,
17165 pointer_mode = ?pointer_mode,
17166 keyboard_mode = ?keyboard_mode,
17167 );
17168 let _enter = span.enter();
17169 let request = types::xproto::GrabKeyRequest {
17170 owner_events,
17171 grab_window,
17172 modifiers: Into::<u32>::into(modifiers.into()) as _,
17173 key: Into::<u32>::into(key.into()) as _,
17174 pointer_mode,
17175 keyboard_mode,
17176 };
17177 let cookie = self.send_void_request(request, true);
17178 cookie
17179 }
17180 fn grab_key_checked(
17181 &mut self,
17182 owner_events: types::Bool,
17183 grab_window: types::xproto::Window,
17184 modifiers: impl Into<types::ModMask>,
17185 key: impl Into<types::Grab>,
17186 pointer_mode: types::GrabMode,
17187 keyboard_mode: types::GrabMode,
17188 ) -> Result<()> {
17189 let request = types::xproto::GrabKeyRequest {
17190 owner_events,
17191 grab_window,
17192 modifiers: Into::<u32>::into(modifiers.into()) as _,
17193 key: Into::<u32>::into(key.into()) as _,
17194 pointer_mode,
17195 keyboard_mode,
17196 };
17197 let cookie = self.send_void_request(request, false)?;
17198 self.wait_for_reply(cookie)
17199 }
17200 fn ungrab_key(
17201 &mut self,
17202 key: impl Into<types::Grab>,
17203 grab_window: types::xproto::Window,
17204 modifiers: impl Into<types::ModMask>,
17205 ) -> Result<Cookie<()>> {
17206 let span = tracing::info_span!(
17207 "ungrab_key",
17208 grab_window = ?grab_window,
17209 );
17210 let _enter = span.enter();
17211 let request = types::xproto::UngrabKeyRequest {
17212 key: Into::<u32>::into(key.into()) as _,
17213 grab_window,
17214 modifiers: Into::<u32>::into(modifiers.into()) as _,
17215 };
17216 let cookie = self.send_void_request(request, true);
17217 cookie
17218 }
17219 fn ungrab_key_checked(
17220 &mut self,
17221 key: impl Into<types::Grab>,
17222 grab_window: types::xproto::Window,
17223 modifiers: impl Into<types::ModMask>,
17224 ) -> Result<()> {
17225 let request = types::xproto::UngrabKeyRequest {
17226 key: Into::<u32>::into(key.into()) as _,
17227 grab_window,
17228 modifiers: Into::<u32>::into(modifiers.into()) as _,
17229 };
17230 let cookie = self.send_void_request(request, false)?;
17231 self.wait_for_reply(cookie)
17232 }
17233 fn allow_events(
17234 &mut self,
17235 mode: types::Allow,
17236 time: impl Into<types::Time>,
17237 ) -> Result<Cookie<()>> {
17238 let span = tracing::info_span!(
17239 "allow_events",
17240 mode = ?mode,
17241 );
17242 let _enter = span.enter();
17243 let request = types::xproto::AllowEventsRequest {
17244 mode,
17245 time: Into::<u32>::into(time.into()) as _,
17246 };
17247 let cookie = self.send_void_request(request, true);
17248 cookie
17249 }
17250 fn allow_events_checked(
17251 &mut self,
17252 mode: types::Allow,
17253 time: impl Into<types::Time>,
17254 ) -> Result<()> {
17255 let request = types::xproto::AllowEventsRequest {
17256 mode,
17257 time: Into::<u32>::into(time.into()) as _,
17258 };
17259 let cookie = self.send_void_request(request, false)?;
17260 self.wait_for_reply(cookie)
17261 }
17262 fn grab_server(&mut self) -> Result<Cookie<()>> {
17263 let span = tracing::info_span!("grab_server",);
17264 let _enter = span.enter();
17265 let request = types::xproto::GrabServerRequest {};
17266 let cookie = self.send_void_request(request, true);
17267 cookie
17268 }
17269 fn grab_server_checked(&mut self) -> Result<()> {
17270 let request = types::xproto::GrabServerRequest {};
17271 let cookie = self.send_void_request(request, false)?;
17272 self.wait_for_reply(cookie)
17273 }
17274 fn ungrab_server(&mut self) -> Result<Cookie<()>> {
17275 let span = tracing::info_span!("ungrab_server",);
17276 let _enter = span.enter();
17277 let request = types::xproto::UngrabServerRequest {};
17278 let cookie = self.send_void_request(request, true);
17279 cookie
17280 }
17281 fn ungrab_server_checked(&mut self) -> Result<()> {
17282 let request = types::xproto::UngrabServerRequest {};
17283 let cookie = self.send_void_request(request, false)?;
17284 self.wait_for_reply(cookie)
17285 }
17286 fn query_pointer(
17287 &mut self,
17288 window: types::xproto::Window,
17289 ) -> Result<Cookie<types::xproto::QueryPointerReply>> {
17290 let span = tracing::info_span!(
17291 "query_pointer",
17292 window = ?window,
17293 );
17294 let _enter = span.enter();
17295 let request = types::xproto::QueryPointerRequest { window };
17296 let cookie = self.send_reply_request(request);
17297 cookie
17298 }
17299 fn query_pointer_immediate(
17300 &mut self,
17301 window: types::xproto::Window,
17302 ) -> Result<types::xproto::QueryPointerReply> {
17303 let request = types::xproto::QueryPointerRequest { window };
17304 let cookie = self.send_reply_request(request)?;
17305 self.wait_for_reply(cookie)
17306 }
17307 fn get_motion_events(
17308 &mut self,
17309 window: types::xproto::Window,
17310 start: impl Into<types::Time>,
17311 stop: impl Into<types::Time>,
17312 ) -> Result<Cookie<types::xproto::GetMotionEventsReply>> {
17313 let span = tracing::info_span!(
17314 "get_motion_events",
17315 window = ?window,
17316 );
17317 let _enter = span.enter();
17318 let request = types::xproto::GetMotionEventsRequest {
17319 window,
17320 start: Into::<u32>::into(start.into()) as _,
17321 stop: Into::<u32>::into(stop.into()) as _,
17322 };
17323 let cookie = self.send_reply_request(request);
17324 cookie
17325 }
17326 fn get_motion_events_immediate(
17327 &mut self,
17328 window: types::xproto::Window,
17329 start: impl Into<types::Time>,
17330 stop: impl Into<types::Time>,
17331 ) -> Result<types::xproto::GetMotionEventsReply> {
17332 let request = types::xproto::GetMotionEventsRequest {
17333 window,
17334 start: Into::<u32>::into(start.into()) as _,
17335 stop: Into::<u32>::into(stop.into()) as _,
17336 };
17337 let cookie = self.send_reply_request(request)?;
17338 self.wait_for_reply(cookie)
17339 }
17340 fn translate_coordinates(
17341 &mut self,
17342 src_window: types::xproto::Window,
17343 dst_window: types::xproto::Window,
17344 src_x: types::Int16,
17345 src_y: types::Int16,
17346 ) -> Result<Cookie<types::xproto::TranslateCoordinatesReply>> {
17347 let span = tracing::info_span!(
17348 "translate_coordinates",
17349 src_window = ?src_window,
17350 dst_window = ?dst_window,
17351 src_x = ?src_x,
17352 src_y = ?src_y,
17353 );
17354 let _enter = span.enter();
17355 let request = types::xproto::TranslateCoordinatesRequest {
17356 src_window,
17357 dst_window,
17358 src_x,
17359 src_y,
17360 };
17361 let cookie = self.send_reply_request(request);
17362 cookie
17363 }
17364 fn translate_coordinates_immediate(
17365 &mut self,
17366 src_window: types::xproto::Window,
17367 dst_window: types::xproto::Window,
17368 src_x: types::Int16,
17369 src_y: types::Int16,
17370 ) -> Result<types::xproto::TranslateCoordinatesReply> {
17371 let request = types::xproto::TranslateCoordinatesRequest {
17372 src_window,
17373 dst_window,
17374 src_x,
17375 src_y,
17376 };
17377 let cookie = self.send_reply_request(request)?;
17378 self.wait_for_reply(cookie)
17379 }
17380 fn warp_pointer(
17381 &mut self,
17382 src_window: impl Into<types::xproto::Window>,
17383 dst_window: impl Into<types::xproto::Window>,
17384 src_x: types::Int16,
17385 src_y: types::Int16,
17386 src_width: types::Card16,
17387 src_height: types::Card16,
17388 dst_x: types::Int16,
17389 dst_y: types::Int16,
17390 ) -> Result<Cookie<()>> {
17391 let span = tracing::info_span!(
17392 "warp_pointer",
17393 src_x = ?src_x,
17394 src_y = ?src_y,
17395 src_width = ?src_width,
17396 src_height = ?src_height,
17397 dst_x = ?dst_x,
17398 dst_y = ?dst_y,
17399 );
17400 let _enter = span.enter();
17401 let request = types::xproto::WarpPointerRequest {
17402 src_window: Into::<u32>::into(src_window.into()) as _,
17403 dst_window: Into::<u32>::into(dst_window.into()) as _,
17404 src_x,
17405 src_y,
17406 src_width,
17407 src_height,
17408 dst_x,
17409 dst_y,
17410 };
17411 let cookie = self.send_void_request(request, true);
17412 cookie
17413 }
17414 fn warp_pointer_checked(
17415 &mut self,
17416 src_window: impl Into<types::xproto::Window>,
17417 dst_window: impl Into<types::xproto::Window>,
17418 src_x: types::Int16,
17419 src_y: types::Int16,
17420 src_width: types::Card16,
17421 src_height: types::Card16,
17422 dst_x: types::Int16,
17423 dst_y: types::Int16,
17424 ) -> Result<()> {
17425 let request = types::xproto::WarpPointerRequest {
17426 src_window: Into::<u32>::into(src_window.into()) as _,
17427 dst_window: Into::<u32>::into(dst_window.into()) as _,
17428 src_x,
17429 src_y,
17430 src_width,
17431 src_height,
17432 dst_x,
17433 dst_y,
17434 };
17435 let cookie = self.send_void_request(request, false)?;
17436 self.wait_for_reply(cookie)
17437 }
17438 fn set_input_focus(
17439 &mut self,
17440 revert_to: types::InputFocus,
17441 focus: impl Into<types::InputFocus>,
17442 time: impl Into<types::Time>,
17443 ) -> Result<Cookie<()>> {
17444 let span = tracing::info_span!(
17445 "set_input_focus",
17446 revert_to = ?revert_to,
17447 );
17448 let _enter = span.enter();
17449 let request = types::xproto::SetInputFocusRequest {
17450 revert_to,
17451 focus: Into::<u32>::into(focus.into()) as _,
17452 time: Into::<u32>::into(time.into()) as _,
17453 };
17454 let cookie = self.send_void_request(request, true);
17455 cookie
17456 }
17457 fn set_input_focus_checked(
17458 &mut self,
17459 revert_to: types::InputFocus,
17460 focus: impl Into<types::InputFocus>,
17461 time: impl Into<types::Time>,
17462 ) -> Result<()> {
17463 let request = types::xproto::SetInputFocusRequest {
17464 revert_to,
17465 focus: Into::<u32>::into(focus.into()) as _,
17466 time: Into::<u32>::into(time.into()) as _,
17467 };
17468 let cookie = self.send_void_request(request, false)?;
17469 self.wait_for_reply(cookie)
17470 }
17471 fn get_input_focus(&mut self) -> Result<Cookie<types::xproto::GetInputFocusReply>> {
17472 let span = tracing::info_span!("get_input_focus",);
17473 let _enter = span.enter();
17474 let request = types::xproto::GetInputFocusRequest {};
17475 let cookie = self.send_reply_request(request);
17476 cookie
17477 }
17478 fn get_input_focus_immediate(&mut self) -> Result<types::xproto::GetInputFocusReply> {
17479 let request = types::xproto::GetInputFocusRequest {};
17480 let cookie = self.send_reply_request(request)?;
17481 self.wait_for_reply(cookie)
17482 }
17483 fn query_keymap(&mut self) -> Result<Cookie<types::xproto::QueryKeymapReply>> {
17484 let span = tracing::info_span!("query_keymap",);
17485 let _enter = span.enter();
17486 let request = types::xproto::QueryKeymapRequest {};
17487 let cookie = self.send_reply_request(request);
17488 cookie
17489 }
17490 fn query_keymap_immediate(&mut self) -> Result<types::xproto::QueryKeymapReply> {
17491 let request = types::xproto::QueryKeymapRequest {};
17492 let cookie = self.send_reply_request(request)?;
17493 self.wait_for_reply(cookie)
17494 }
17495 fn open_font(
17496 &mut self,
17497 fid: types::Font,
17498 name: impl AsRef<[types::Char]>,
17499 ) -> Result<Cookie<()>> {
17500 let span = tracing::info_span!(
17501 "open_font",
17502 fid = ?fid,
17503 );
17504 let _enter = span.enter();
17505 let request = types::xproto::OpenFontRequest {
17506 fid,
17507 name: Cow::Borrowed(name.as_ref()),
17508 };
17509 let cookie = self.send_void_request(request, true);
17510 cookie
17511 }
17512 fn open_font_checked(
17513 &mut self,
17514 fid: types::Font,
17515 name: impl AsRef<[types::Char]>,
17516 ) -> Result<()> {
17517 let request = types::xproto::OpenFontRequest {
17518 fid,
17519 name: Cow::Borrowed(name.as_ref()),
17520 };
17521 let cookie = self.send_void_request(request, false)?;
17522 self.wait_for_reply(cookie)
17523 }
17524 fn close_font(&mut self, font: types::Font) -> Result<Cookie<()>> {
17525 let span = tracing::info_span!(
17526 "close_font",
17527 font = ?font,
17528 );
17529 let _enter = span.enter();
17530 let request = types::xproto::CloseFontRequest { font };
17531 let cookie = self.send_void_request(request, true);
17532 cookie
17533 }
17534 fn close_font_checked(&mut self, font: types::Font) -> Result<()> {
17535 let request = types::xproto::CloseFontRequest { font };
17536 let cookie = self.send_void_request(request, false)?;
17537 self.wait_for_reply(cookie)
17538 }
17539 fn query_font(
17540 &mut self,
17541 font: types::Fontable,
17542 ) -> Result<Cookie<types::xproto::QueryFontReply>> {
17543 let span = tracing::info_span!(
17544 "query_font",
17545 font = ?font,
17546 );
17547 let _enter = span.enter();
17548 let request = types::xproto::QueryFontRequest { font };
17549 let cookie = self.send_reply_request(request);
17550 cookie
17551 }
17552 fn query_font_immediate(
17553 &mut self,
17554 font: types::Fontable,
17555 ) -> Result<types::xproto::QueryFontReply> {
17556 let request = types::xproto::QueryFontRequest { font };
17557 let cookie = self.send_reply_request(request)?;
17558 self.wait_for_reply(cookie)
17559 }
17560 fn query_text_extents(
17561 &mut self,
17562 font: types::Fontable,
17563 string: impl AsRef<[types::Char2b]>,
17564 ) -> Result<Cookie<types::xproto::QueryTextExtentsReply>> {
17565 let span = tracing::info_span!(
17566 "query_text_extents",
17567 font = ?font,
17568 );
17569 let _enter = span.enter();
17570 let request = types::xproto::QueryTextExtentsRequest {
17571 font,
17572 string: Cow::Borrowed(string.as_ref()),
17573 };
17574 let cookie = self.send_reply_request(request);
17575 cookie
17576 }
17577 fn query_text_extents_immediate(
17578 &mut self,
17579 font: types::Fontable,
17580 string: impl AsRef<[types::Char2b]>,
17581 ) -> Result<types::xproto::QueryTextExtentsReply> {
17582 let request = types::xproto::QueryTextExtentsRequest {
17583 font,
17584 string: Cow::Borrowed(string.as_ref()),
17585 };
17586 let cookie = self.send_reply_request(request)?;
17587 self.wait_for_reply(cookie)
17588 }
17589 fn list_fonts(
17590 &mut self,
17591 max_names: types::Card16,
17592 pattern: impl AsRef<[types::Char]>,
17593 ) -> Result<Cookie<types::xproto::ListFontsReply>> {
17594 let span = tracing::info_span!(
17595 "list_fonts",
17596 max_names = ?max_names,
17597 );
17598 let _enter = span.enter();
17599 let request = types::xproto::ListFontsRequest {
17600 max_names,
17601 pattern: Cow::Borrowed(pattern.as_ref()),
17602 };
17603 let cookie = self.send_reply_request(request);
17604 cookie
17605 }
17606 fn list_fonts_immediate(
17607 &mut self,
17608 max_names: types::Card16,
17609 pattern: impl AsRef<[types::Char]>,
17610 ) -> Result<types::xproto::ListFontsReply> {
17611 let request = types::xproto::ListFontsRequest {
17612 max_names,
17613 pattern: Cow::Borrowed(pattern.as_ref()),
17614 };
17615 let cookie = self.send_reply_request(request)?;
17616 self.wait_for_reply(cookie)
17617 }
17618 fn list_fonts_with_info(
17619 &mut self,
17620 max_names: types::Card16,
17621 pattern: impl AsRef<[types::Char]>,
17622 ) -> Result<Cookie<types::xproto::ListFontsWithInfoReply>> {
17623 let span = tracing::info_span!(
17624 "list_fonts_with_info",
17625 max_names = ?max_names,
17626 );
17627 let _enter = span.enter();
17628 let request = types::xproto::ListFontsWithInfoRequest {
17629 max_names,
17630 pattern: Cow::Borrowed(pattern.as_ref()),
17631 };
17632 let cookie = self.send_reply_request(request);
17633 cookie
17634 }
17635 fn list_fonts_with_info_immediate(
17636 &mut self,
17637 max_names: types::Card16,
17638 pattern: impl AsRef<[types::Char]>,
17639 ) -> Result<types::xproto::ListFontsWithInfoReply> {
17640 let request = types::xproto::ListFontsWithInfoRequest {
17641 max_names,
17642 pattern: Cow::Borrowed(pattern.as_ref()),
17643 };
17644 let cookie = self.send_reply_request(request)?;
17645 self.wait_for_reply(cookie)
17646 }
17647 fn set_font_path(&mut self, font: impl AsRef<[types::Str]>) -> Result<Cookie<()>> {
17648 let span = tracing::info_span!("set_font_path",);
17649 let _enter = span.enter();
17650 let request = types::xproto::SetFontPathRequest {
17651 font: Cow::Borrowed(font.as_ref()),
17652 };
17653 let cookie = self.send_void_request(request, true);
17654 cookie
17655 }
17656 fn set_font_path_checked(&mut self, font: impl AsRef<[types::Str]>) -> Result<()> {
17657 let request = types::xproto::SetFontPathRequest {
17658 font: Cow::Borrowed(font.as_ref()),
17659 };
17660 let cookie = self.send_void_request(request, false)?;
17661 self.wait_for_reply(cookie)
17662 }
17663 fn get_font_path(&mut self) -> Result<Cookie<types::xproto::GetFontPathReply>> {
17664 let span = tracing::info_span!("get_font_path",);
17665 let _enter = span.enter();
17666 let request = types::xproto::GetFontPathRequest {};
17667 let cookie = self.send_reply_request(request);
17668 cookie
17669 }
17670 fn get_font_path_immediate(&mut self) -> Result<types::xproto::GetFontPathReply> {
17671 let request = types::xproto::GetFontPathRequest {};
17672 let cookie = self.send_reply_request(request)?;
17673 self.wait_for_reply(cookie)
17674 }
17675 fn create_pixmap(
17676 &mut self,
17677 depth: types::Card8,
17678 pid: types::xproto::Pixmap,
17679 drawable: types::xproto::Drawable,
17680 width: types::Card16,
17681 height: types::Card16,
17682 ) -> Result<Cookie<()>> {
17683 let span = tracing::info_span!(
17684 "create_pixmap",
17685 depth = ?depth,
17686 pid = ?pid,
17687 drawable = ?drawable,
17688 width = ?width,
17689 height = ?height,
17690 );
17691 let _enter = span.enter();
17692 let request = types::xproto::CreatePixmapRequest {
17693 depth,
17694 pid,
17695 drawable,
17696 width,
17697 height,
17698 };
17699 let cookie = self.send_void_request(request, true);
17700 cookie
17701 }
17702 fn create_pixmap_checked(
17703 &mut self,
17704 depth: types::Card8,
17705 pid: types::xproto::Pixmap,
17706 drawable: types::xproto::Drawable,
17707 width: types::Card16,
17708 height: types::Card16,
17709 ) -> Result<()> {
17710 let request = types::xproto::CreatePixmapRequest {
17711 depth,
17712 pid,
17713 drawable,
17714 width,
17715 height,
17716 };
17717 let cookie = self.send_void_request(request, false)?;
17718 self.wait_for_reply(cookie)
17719 }
17720 fn free_pixmap(&mut self, pixmap: types::xproto::Pixmap) -> Result<Cookie<()>> {
17721 let span = tracing::info_span!(
17722 "free_pixmap",
17723 pixmap = ?pixmap,
17724 );
17725 let _enter = span.enter();
17726 let request = types::xproto::FreePixmapRequest { pixmap };
17727 let cookie = self.send_void_request(request, true);
17728 cookie
17729 }
17730 fn free_pixmap_checked(&mut self, pixmap: types::xproto::Pixmap) -> Result<()> {
17731 let request = types::xproto::FreePixmapRequest { pixmap };
17732 let cookie = self.send_void_request(request, false)?;
17733 self.wait_for_reply(cookie)
17734 }
17735 fn create_gc(
17736 &mut self,
17737 cid: types::Gcontext,
17738 drawable: types::xproto::Drawable,
17739 value_list: impl Borrow<types::xproto::CreateGCAux>,
17740 ) -> Result<Cookie<()>> {
17741 let span = tracing::info_span!(
17742 "create_gc",
17743 cid = ?cid,
17744 drawable = ?drawable,
17745 );
17746 let _enter = span.enter();
17747 let request = types::xproto::CreateGCRequest {
17748 cid,
17749 drawable,
17750 value_list: Cow::Borrowed(value_list.borrow()),
17751 };
17752 let cookie = self.send_void_request(request, true);
17753 cookie
17754 }
17755 fn create_gc_checked(
17756 &mut self,
17757 cid: types::Gcontext,
17758 drawable: types::xproto::Drawable,
17759 value_list: impl Borrow<types::xproto::CreateGCAux>,
17760 ) -> Result<()> {
17761 let request = types::xproto::CreateGCRequest {
17762 cid,
17763 drawable,
17764 value_list: Cow::Borrowed(value_list.borrow()),
17765 };
17766 let cookie = self.send_void_request(request, false)?;
17767 self.wait_for_reply(cookie)
17768 }
17769 fn change_gc(
17770 &mut self,
17771 gc: types::Gcontext,
17772 value_list: impl Borrow<types::xproto::ChangeGCAux>,
17773 ) -> Result<Cookie<()>> {
17774 let span = tracing::info_span!(
17775 "change_gc",
17776 gc = ?gc,
17777 );
17778 let _enter = span.enter();
17779 let request = types::xproto::ChangeGCRequest {
17780 gc,
17781 value_list: Cow::Borrowed(value_list.borrow()),
17782 };
17783 let cookie = self.send_void_request(request, true);
17784 cookie
17785 }
17786 fn change_gc_checked(
17787 &mut self,
17788 gc: types::Gcontext,
17789 value_list: impl Borrow<types::xproto::ChangeGCAux>,
17790 ) -> Result<()> {
17791 let request = types::xproto::ChangeGCRequest {
17792 gc,
17793 value_list: Cow::Borrowed(value_list.borrow()),
17794 };
17795 let cookie = self.send_void_request(request, false)?;
17796 self.wait_for_reply(cookie)
17797 }
17798 fn copy_gc(
17799 &mut self,
17800 src_gc: types::Gcontext,
17801 dst_gc: types::Gcontext,
17802 value_mask: impl Into<types::xproto::GC>,
17803 ) -> Result<Cookie<()>> {
17804 let span = tracing::info_span!(
17805 "copy_gc",
17806 src_gc = ?src_gc,
17807 dst_gc = ?dst_gc,
17808 );
17809 let _enter = span.enter();
17810 let request = types::xproto::CopyGCRequest {
17811 src_gc,
17812 dst_gc,
17813 value_mask: Into::<u32>::into(value_mask.into()) as _,
17814 };
17815 let cookie = self.send_void_request(request, true);
17816 cookie
17817 }
17818 fn copy_gc_checked(
17819 &mut self,
17820 src_gc: types::Gcontext,
17821 dst_gc: types::Gcontext,
17822 value_mask: impl Into<types::xproto::GC>,
17823 ) -> Result<()> {
17824 let request = types::xproto::CopyGCRequest {
17825 src_gc,
17826 dst_gc,
17827 value_mask: Into::<u32>::into(value_mask.into()) as _,
17828 };
17829 let cookie = self.send_void_request(request, false)?;
17830 self.wait_for_reply(cookie)
17831 }
17832 fn set_dashes(
17833 &mut self,
17834 gc: types::Gcontext,
17835 dash_offset: types::Card16,
17836 dashes: impl AsRef<[types::Card8]>,
17837 ) -> Result<Cookie<()>> {
17838 let span = tracing::info_span!(
17839 "set_dashes",
17840 gc = ?gc,
17841 dash_offset = ?dash_offset,
17842 );
17843 let _enter = span.enter();
17844 let request = types::xproto::SetDashesRequest {
17845 gc,
17846 dash_offset,
17847 dashes: Cow::Borrowed(dashes.as_ref()),
17848 };
17849 let cookie = self.send_void_request(request, true);
17850 cookie
17851 }
17852 fn set_dashes_checked(
17853 &mut self,
17854 gc: types::Gcontext,
17855 dash_offset: types::Card16,
17856 dashes: impl AsRef<[types::Card8]>,
17857 ) -> Result<()> {
17858 let request = types::xproto::SetDashesRequest {
17859 gc,
17860 dash_offset,
17861 dashes: Cow::Borrowed(dashes.as_ref()),
17862 };
17863 let cookie = self.send_void_request(request, false)?;
17864 self.wait_for_reply(cookie)
17865 }
17866 fn set_clip_rectangles(
17867 &mut self,
17868 ordering: types::ClipOrdering,
17869 gc: types::Gcontext,
17870 clip_x_origin: types::Int16,
17871 clip_y_origin: types::Int16,
17872 rectangles: impl AsRef<[types::Rectangle]>,
17873 ) -> Result<Cookie<()>> {
17874 let span = tracing::info_span!(
17875 "set_clip_rectangles",
17876 ordering = ?ordering,
17877 gc = ?gc,
17878 clip_x_origin = ?clip_x_origin,
17879 clip_y_origin = ?clip_y_origin,
17880 );
17881 let _enter = span.enter();
17882 let request = types::xproto::SetClipRectanglesRequest {
17883 ordering,
17884 gc,
17885 clip_x_origin,
17886 clip_y_origin,
17887 rectangles: Cow::Borrowed(rectangles.as_ref()),
17888 };
17889 let cookie = self.send_void_request(request, true);
17890 cookie
17891 }
17892 fn set_clip_rectangles_checked(
17893 &mut self,
17894 ordering: types::ClipOrdering,
17895 gc: types::Gcontext,
17896 clip_x_origin: types::Int16,
17897 clip_y_origin: types::Int16,
17898 rectangles: impl AsRef<[types::Rectangle]>,
17899 ) -> Result<()> {
17900 let request = types::xproto::SetClipRectanglesRequest {
17901 ordering,
17902 gc,
17903 clip_x_origin,
17904 clip_y_origin,
17905 rectangles: Cow::Borrowed(rectangles.as_ref()),
17906 };
17907 let cookie = self.send_void_request(request, false)?;
17908 self.wait_for_reply(cookie)
17909 }
17910 fn free_gc(&mut self, gc: types::Gcontext) -> Result<Cookie<()>> {
17911 let span = tracing::info_span!(
17912 "free_gc",
17913 gc = ?gc,
17914 );
17915 let _enter = span.enter();
17916 let request = types::xproto::FreeGCRequest { gc };
17917 let cookie = self.send_void_request(request, true);
17918 cookie
17919 }
17920 fn free_gc_checked(&mut self, gc: types::Gcontext) -> Result<()> {
17921 let request = types::xproto::FreeGCRequest { gc };
17922 let cookie = self.send_void_request(request, false)?;
17923 self.wait_for_reply(cookie)
17924 }
17925 fn clear_area(
17926 &mut self,
17927 exposures: types::Bool,
17928 window: types::xproto::Window,
17929 x: types::Int16,
17930 y: types::Int16,
17931 width: types::Card16,
17932 height: types::Card16,
17933 ) -> Result<Cookie<()>> {
17934 let span = tracing::info_span!(
17935 "clear_area",
17936 exposures = ?exposures,
17937 window = ?window,
17938 x = ?x,
17939 y = ?y,
17940 width = ?width,
17941 height = ?height,
17942 );
17943 let _enter = span.enter();
17944 let request = types::xproto::ClearAreaRequest {
17945 exposures,
17946 window,
17947 x,
17948 y,
17949 width,
17950 height,
17951 };
17952 let cookie = self.send_void_request(request, true);
17953 cookie
17954 }
17955 fn clear_area_checked(
17956 &mut self,
17957 exposures: types::Bool,
17958 window: types::xproto::Window,
17959 x: types::Int16,
17960 y: types::Int16,
17961 width: types::Card16,
17962 height: types::Card16,
17963 ) -> Result<()> {
17964 let request = types::xproto::ClearAreaRequest {
17965 exposures,
17966 window,
17967 x,
17968 y,
17969 width,
17970 height,
17971 };
17972 let cookie = self.send_void_request(request, false)?;
17973 self.wait_for_reply(cookie)
17974 }
17975 fn copy_area(
17976 &mut self,
17977 src_drawable: types::xproto::Drawable,
17978 dst_drawable: types::xproto::Drawable,
17979 gc: types::Gcontext,
17980 src_x: types::Int16,
17981 src_y: types::Int16,
17982 dst_x: types::Int16,
17983 dst_y: types::Int16,
17984 width: types::Card16,
17985 height: types::Card16,
17986 ) -> Result<Cookie<()>> {
17987 let span = tracing::info_span!(
17988 "copy_area",
17989 src_drawable = ?src_drawable,
17990 dst_drawable = ?dst_drawable,
17991 gc = ?gc,
17992 src_x = ?src_x,
17993 src_y = ?src_y,
17994 dst_x = ?dst_x,
17995 dst_y = ?dst_y,
17996 width = ?width,
17997 height = ?height,
17998 );
17999 let _enter = span.enter();
18000 let request = types::xproto::CopyAreaRequest {
18001 src_drawable,
18002 dst_drawable,
18003 gc,
18004 src_x,
18005 src_y,
18006 dst_x,
18007 dst_y,
18008 width,
18009 height,
18010 };
18011 let cookie = self.send_void_request(request, true);
18012 cookie
18013 }
18014 fn copy_area_checked(
18015 &mut self,
18016 src_drawable: types::xproto::Drawable,
18017 dst_drawable: types::xproto::Drawable,
18018 gc: types::Gcontext,
18019 src_x: types::Int16,
18020 src_y: types::Int16,
18021 dst_x: types::Int16,
18022 dst_y: types::Int16,
18023 width: types::Card16,
18024 height: types::Card16,
18025 ) -> Result<()> {
18026 let request = types::xproto::CopyAreaRequest {
18027 src_drawable,
18028 dst_drawable,
18029 gc,
18030 src_x,
18031 src_y,
18032 dst_x,
18033 dst_y,
18034 width,
18035 height,
18036 };
18037 let cookie = self.send_void_request(request, false)?;
18038 self.wait_for_reply(cookie)
18039 }
18040 fn copy_plane(
18041 &mut self,
18042 src_drawable: types::xproto::Drawable,
18043 dst_drawable: types::xproto::Drawable,
18044 gc: types::Gcontext,
18045 src_x: types::Int16,
18046 src_y: types::Int16,
18047 dst_x: types::Int16,
18048 dst_y: types::Int16,
18049 width: types::Card16,
18050 height: types::Card16,
18051 bit_plane: types::Card32,
18052 ) -> Result<Cookie<()>> {
18053 let span = tracing::info_span!(
18054 "copy_plane",
18055 src_drawable = ?src_drawable,
18056 dst_drawable = ?dst_drawable,
18057 gc = ?gc,
18058 src_x = ?src_x,
18059 src_y = ?src_y,
18060 dst_x = ?dst_x,
18061 dst_y = ?dst_y,
18062 width = ?width,
18063 height = ?height,
18064 bit_plane = ?bit_plane,
18065 );
18066 let _enter = span.enter();
18067 let request = types::xproto::CopyPlaneRequest {
18068 src_drawable,
18069 dst_drawable,
18070 gc,
18071 src_x,
18072 src_y,
18073 dst_x,
18074 dst_y,
18075 width,
18076 height,
18077 bit_plane,
18078 };
18079 let cookie = self.send_void_request(request, true);
18080 cookie
18081 }
18082 fn copy_plane_checked(
18083 &mut self,
18084 src_drawable: types::xproto::Drawable,
18085 dst_drawable: types::xproto::Drawable,
18086 gc: types::Gcontext,
18087 src_x: types::Int16,
18088 src_y: types::Int16,
18089 dst_x: types::Int16,
18090 dst_y: types::Int16,
18091 width: types::Card16,
18092 height: types::Card16,
18093 bit_plane: types::Card32,
18094 ) -> Result<()> {
18095 let request = types::xproto::CopyPlaneRequest {
18096 src_drawable,
18097 dst_drawable,
18098 gc,
18099 src_x,
18100 src_y,
18101 dst_x,
18102 dst_y,
18103 width,
18104 height,
18105 bit_plane,
18106 };
18107 let cookie = self.send_void_request(request, false)?;
18108 self.wait_for_reply(cookie)
18109 }
18110 fn poly_point(
18111 &mut self,
18112 coordinate_mode: types::CoordMode,
18113 drawable: types::xproto::Drawable,
18114 gc: types::Gcontext,
18115 points: impl AsRef<[types::Point]>,
18116 ) -> Result<Cookie<()>> {
18117 let span = tracing::info_span!(
18118 "poly_point",
18119 coordinate_mode = ?coordinate_mode,
18120 drawable = ?drawable,
18121 gc = ?gc,
18122 );
18123 let _enter = span.enter();
18124 let request = types::xproto::PolyPointRequest {
18125 coordinate_mode,
18126 drawable,
18127 gc,
18128 points: Cow::Borrowed(points.as_ref()),
18129 };
18130 let cookie = self.send_void_request(request, true);
18131 cookie
18132 }
18133 fn poly_point_checked(
18134 &mut self,
18135 coordinate_mode: types::CoordMode,
18136 drawable: types::xproto::Drawable,
18137 gc: types::Gcontext,
18138 points: impl AsRef<[types::Point]>,
18139 ) -> Result<()> {
18140 let request = types::xproto::PolyPointRequest {
18141 coordinate_mode,
18142 drawable,
18143 gc,
18144 points: Cow::Borrowed(points.as_ref()),
18145 };
18146 let cookie = self.send_void_request(request, false)?;
18147 self.wait_for_reply(cookie)
18148 }
18149 fn poly_line(
18150 &mut self,
18151 coordinate_mode: types::CoordMode,
18152 drawable: types::xproto::Drawable,
18153 gc: types::Gcontext,
18154 points: impl AsRef<[types::Point]>,
18155 ) -> Result<Cookie<()>> {
18156 let span = tracing::info_span!(
18157 "poly_line",
18158 coordinate_mode = ?coordinate_mode,
18159 drawable = ?drawable,
18160 gc = ?gc,
18161 );
18162 let _enter = span.enter();
18163 let request = types::xproto::PolyLineRequest {
18164 coordinate_mode,
18165 drawable,
18166 gc,
18167 points: Cow::Borrowed(points.as_ref()),
18168 };
18169 let cookie = self.send_void_request(request, true);
18170 cookie
18171 }
18172 fn poly_line_checked(
18173 &mut self,
18174 coordinate_mode: types::CoordMode,
18175 drawable: types::xproto::Drawable,
18176 gc: types::Gcontext,
18177 points: impl AsRef<[types::Point]>,
18178 ) -> Result<()> {
18179 let request = types::xproto::PolyLineRequest {
18180 coordinate_mode,
18181 drawable,
18182 gc,
18183 points: Cow::Borrowed(points.as_ref()),
18184 };
18185 let cookie = self.send_void_request(request, false)?;
18186 self.wait_for_reply(cookie)
18187 }
18188 fn poly_segment(
18189 &mut self,
18190 drawable: types::xproto::Drawable,
18191 gc: types::Gcontext,
18192 segments: impl AsRef<[types::Segment]>,
18193 ) -> Result<Cookie<()>> {
18194 let span = tracing::info_span!(
18195 "poly_segment",
18196 drawable = ?drawable,
18197 gc = ?gc,
18198 );
18199 let _enter = span.enter();
18200 let request = types::xproto::PolySegmentRequest {
18201 drawable,
18202 gc,
18203 segments: Cow::Borrowed(segments.as_ref()),
18204 };
18205 let cookie = self.send_void_request(request, true);
18206 cookie
18207 }
18208 fn poly_segment_checked(
18209 &mut self,
18210 drawable: types::xproto::Drawable,
18211 gc: types::Gcontext,
18212 segments: impl AsRef<[types::Segment]>,
18213 ) -> Result<()> {
18214 let request = types::xproto::PolySegmentRequest {
18215 drawable,
18216 gc,
18217 segments: Cow::Borrowed(segments.as_ref()),
18218 };
18219 let cookie = self.send_void_request(request, false)?;
18220 self.wait_for_reply(cookie)
18221 }
18222 fn poly_rectangle(
18223 &mut self,
18224 drawable: types::xproto::Drawable,
18225 gc: types::Gcontext,
18226 rectangles: impl AsRef<[types::Rectangle]>,
18227 ) -> Result<Cookie<()>> {
18228 let span = tracing::info_span!(
18229 "poly_rectangle",
18230 drawable = ?drawable,
18231 gc = ?gc,
18232 );
18233 let _enter = span.enter();
18234 let request = types::xproto::PolyRectangleRequest {
18235 drawable,
18236 gc,
18237 rectangles: Cow::Borrowed(rectangles.as_ref()),
18238 };
18239 let cookie = self.send_void_request(request, true);
18240 cookie
18241 }
18242 fn poly_rectangle_checked(
18243 &mut self,
18244 drawable: types::xproto::Drawable,
18245 gc: types::Gcontext,
18246 rectangles: impl AsRef<[types::Rectangle]>,
18247 ) -> Result<()> {
18248 let request = types::xproto::PolyRectangleRequest {
18249 drawable,
18250 gc,
18251 rectangles: Cow::Borrowed(rectangles.as_ref()),
18252 };
18253 let cookie = self.send_void_request(request, false)?;
18254 self.wait_for_reply(cookie)
18255 }
18256 fn poly_arc(
18257 &mut self,
18258 drawable: types::xproto::Drawable,
18259 gc: types::Gcontext,
18260 arcs: impl AsRef<[types::Arc]>,
18261 ) -> Result<Cookie<()>> {
18262 let span = tracing::info_span!(
18263 "poly_arc",
18264 drawable = ?drawable,
18265 gc = ?gc,
18266 );
18267 let _enter = span.enter();
18268 let request = types::xproto::PolyArcRequest {
18269 drawable,
18270 gc,
18271 arcs: Cow::Borrowed(arcs.as_ref()),
18272 };
18273 let cookie = self.send_void_request(request, true);
18274 cookie
18275 }
18276 fn poly_arc_checked(
18277 &mut self,
18278 drawable: types::xproto::Drawable,
18279 gc: types::Gcontext,
18280 arcs: impl AsRef<[types::Arc]>,
18281 ) -> Result<()> {
18282 let request = types::xproto::PolyArcRequest {
18283 drawable,
18284 gc,
18285 arcs: Cow::Borrowed(arcs.as_ref()),
18286 };
18287 let cookie = self.send_void_request(request, false)?;
18288 self.wait_for_reply(cookie)
18289 }
18290 fn fill_poly(
18291 &mut self,
18292 drawable: types::xproto::Drawable,
18293 gc: types::Gcontext,
18294 shape: types::PolyShape,
18295 coordinate_mode: types::CoordMode,
18296 points: impl AsRef<[types::Point]>,
18297 ) -> Result<Cookie<()>> {
18298 let span = tracing::info_span!(
18299 "fill_poly",
18300 drawable = ?drawable,
18301 gc = ?gc,
18302 shape = ?shape,
18303 coordinate_mode = ?coordinate_mode,
18304 );
18305 let _enter = span.enter();
18306 let request = types::xproto::FillPolyRequest {
18307 drawable,
18308 gc,
18309 shape,
18310 coordinate_mode,
18311 points: Cow::Borrowed(points.as_ref()),
18312 };
18313 let cookie = self.send_void_request(request, true);
18314 cookie
18315 }
18316 fn fill_poly_checked(
18317 &mut self,
18318 drawable: types::xproto::Drawable,
18319 gc: types::Gcontext,
18320 shape: types::PolyShape,
18321 coordinate_mode: types::CoordMode,
18322 points: impl AsRef<[types::Point]>,
18323 ) -> Result<()> {
18324 let request = types::xproto::FillPolyRequest {
18325 drawable,
18326 gc,
18327 shape,
18328 coordinate_mode,
18329 points: Cow::Borrowed(points.as_ref()),
18330 };
18331 let cookie = self.send_void_request(request, false)?;
18332 self.wait_for_reply(cookie)
18333 }
18334 fn poly_fill_rectangle(
18335 &mut self,
18336 drawable: types::xproto::Drawable,
18337 gc: types::Gcontext,
18338 rectangles: impl AsRef<[types::Rectangle]>,
18339 ) -> Result<Cookie<()>> {
18340 let span = tracing::info_span!(
18341 "poly_fill_rectangle",
18342 drawable = ?drawable,
18343 gc = ?gc,
18344 );
18345 let _enter = span.enter();
18346 let request = types::xproto::PolyFillRectangleRequest {
18347 drawable,
18348 gc,
18349 rectangles: Cow::Borrowed(rectangles.as_ref()),
18350 };
18351 let cookie = self.send_void_request(request, true);
18352 cookie
18353 }
18354 fn poly_fill_rectangle_checked(
18355 &mut self,
18356 drawable: types::xproto::Drawable,
18357 gc: types::Gcontext,
18358 rectangles: impl AsRef<[types::Rectangle]>,
18359 ) -> Result<()> {
18360 let request = types::xproto::PolyFillRectangleRequest {
18361 drawable,
18362 gc,
18363 rectangles: Cow::Borrowed(rectangles.as_ref()),
18364 };
18365 let cookie = self.send_void_request(request, false)?;
18366 self.wait_for_reply(cookie)
18367 }
18368 fn poly_fill_arc(
18369 &mut self,
18370 drawable: types::xproto::Drawable,
18371 gc: types::Gcontext,
18372 arcs: impl AsRef<[types::Arc]>,
18373 ) -> Result<Cookie<()>> {
18374 let span = tracing::info_span!(
18375 "poly_fill_arc",
18376 drawable = ?drawable,
18377 gc = ?gc,
18378 );
18379 let _enter = span.enter();
18380 let request = types::xproto::PolyFillArcRequest {
18381 drawable,
18382 gc,
18383 arcs: Cow::Borrowed(arcs.as_ref()),
18384 };
18385 let cookie = self.send_void_request(request, true);
18386 cookie
18387 }
18388 fn poly_fill_arc_checked(
18389 &mut self,
18390 drawable: types::xproto::Drawable,
18391 gc: types::Gcontext,
18392 arcs: impl AsRef<[types::Arc]>,
18393 ) -> Result<()> {
18394 let request = types::xproto::PolyFillArcRequest {
18395 drawable,
18396 gc,
18397 arcs: Cow::Borrowed(arcs.as_ref()),
18398 };
18399 let cookie = self.send_void_request(request, false)?;
18400 self.wait_for_reply(cookie)
18401 }
18402 fn put_image(
18403 &mut self,
18404 format: types::ImageFormat,
18405 drawable: types::xproto::Drawable,
18406 gc: types::Gcontext,
18407 width: types::Card16,
18408 height: types::Card16,
18409 dst_x: types::Int16,
18410 dst_y: types::Int16,
18411 left_pad: types::Card8,
18412 depth: types::Card8,
18413 data: impl AsRef<[types::Byte]>,
18414 ) -> Result<Cookie<()>> {
18415 let span = tracing::info_span!(
18416 "put_image",
18417 format = ?format,
18418 drawable = ?drawable,
18419 gc = ?gc,
18420 width = ?width,
18421 height = ?height,
18422 dst_x = ?dst_x,
18423 dst_y = ?dst_y,
18424 left_pad = ?left_pad,
18425 depth = ?depth,
18426 );
18427 let _enter = span.enter();
18428 let request = types::xproto::PutImageRequest {
18429 format,
18430 drawable,
18431 gc,
18432 width,
18433 height,
18434 dst_x,
18435 dst_y,
18436 left_pad,
18437 depth,
18438 data: Cow::Borrowed(data.as_ref()),
18439 };
18440 let cookie = self.send_void_request(request, true);
18441 cookie
18442 }
18443 fn put_image_checked(
18444 &mut self,
18445 format: types::ImageFormat,
18446 drawable: types::xproto::Drawable,
18447 gc: types::Gcontext,
18448 width: types::Card16,
18449 height: types::Card16,
18450 dst_x: types::Int16,
18451 dst_y: types::Int16,
18452 left_pad: types::Card8,
18453 depth: types::Card8,
18454 data: impl AsRef<[types::Byte]>,
18455 ) -> Result<()> {
18456 let request = types::xproto::PutImageRequest {
18457 format,
18458 drawable,
18459 gc,
18460 width,
18461 height,
18462 dst_x,
18463 dst_y,
18464 left_pad,
18465 depth,
18466 data: Cow::Borrowed(data.as_ref()),
18467 };
18468 let cookie = self.send_void_request(request, false)?;
18469 self.wait_for_reply(cookie)
18470 }
18471 fn get_image(
18472 &mut self,
18473 format: types::ImageFormat,
18474 drawable: types::xproto::Drawable,
18475 x: types::Int16,
18476 y: types::Int16,
18477 width: types::Card16,
18478 height: types::Card16,
18479 plane_mask: types::Card32,
18480 ) -> Result<Cookie<types::xproto::GetImageReply>> {
18481 let span = tracing::info_span!(
18482 "get_image",
18483 format = ?format,
18484 drawable = ?drawable,
18485 x = ?x,
18486 y = ?y,
18487 width = ?width,
18488 height = ?height,
18489 plane_mask = ?plane_mask,
18490 );
18491 let _enter = span.enter();
18492 let request = types::xproto::GetImageRequest {
18493 format,
18494 drawable,
18495 x,
18496 y,
18497 width,
18498 height,
18499 plane_mask,
18500 };
18501 let cookie = self.send_reply_request(request);
18502 cookie
18503 }
18504 fn get_image_immediate(
18505 &mut self,
18506 format: types::ImageFormat,
18507 drawable: types::xproto::Drawable,
18508 x: types::Int16,
18509 y: types::Int16,
18510 width: types::Card16,
18511 height: types::Card16,
18512 plane_mask: types::Card32,
18513 ) -> Result<types::xproto::GetImageReply> {
18514 let request = types::xproto::GetImageRequest {
18515 format,
18516 drawable,
18517 x,
18518 y,
18519 width,
18520 height,
18521 plane_mask,
18522 };
18523 let cookie = self.send_reply_request(request)?;
18524 self.wait_for_reply(cookie)
18525 }
18526 fn poly_text8(
18527 &mut self,
18528 drawable: types::xproto::Drawable,
18529 gc: types::Gcontext,
18530 x: types::Int16,
18531 y: types::Int16,
18532 items: impl AsRef<[types::Byte]>,
18533 ) -> Result<Cookie<()>> {
18534 let span = tracing::info_span!(
18535 "poly_text8",
18536 drawable = ?drawable,
18537 gc = ?gc,
18538 x = ?x,
18539 y = ?y,
18540 );
18541 let _enter = span.enter();
18542 let request = types::xproto::PolyText8Request {
18543 drawable,
18544 gc,
18545 x,
18546 y,
18547 items: Cow::Borrowed(items.as_ref()),
18548 };
18549 let cookie = self.send_void_request(request, true);
18550 cookie
18551 }
18552 fn poly_text8_checked(
18553 &mut self,
18554 drawable: types::xproto::Drawable,
18555 gc: types::Gcontext,
18556 x: types::Int16,
18557 y: types::Int16,
18558 items: impl AsRef<[types::Byte]>,
18559 ) -> Result<()> {
18560 let request = types::xproto::PolyText8Request {
18561 drawable,
18562 gc,
18563 x,
18564 y,
18565 items: Cow::Borrowed(items.as_ref()),
18566 };
18567 let cookie = self.send_void_request(request, false)?;
18568 self.wait_for_reply(cookie)
18569 }
18570 fn poly_text16(
18571 &mut self,
18572 drawable: types::xproto::Drawable,
18573 gc: types::Gcontext,
18574 x: types::Int16,
18575 y: types::Int16,
18576 items: impl AsRef<[types::Byte]>,
18577 ) -> Result<Cookie<()>> {
18578 let span = tracing::info_span!(
18579 "poly_text16",
18580 drawable = ?drawable,
18581 gc = ?gc,
18582 x = ?x,
18583 y = ?y,
18584 );
18585 let _enter = span.enter();
18586 let request = types::xproto::PolyText16Request {
18587 drawable,
18588 gc,
18589 x,
18590 y,
18591 items: Cow::Borrowed(items.as_ref()),
18592 };
18593 let cookie = self.send_void_request(request, true);
18594 cookie
18595 }
18596 fn poly_text16_checked(
18597 &mut self,
18598 drawable: types::xproto::Drawable,
18599 gc: types::Gcontext,
18600 x: types::Int16,
18601 y: types::Int16,
18602 items: impl AsRef<[types::Byte]>,
18603 ) -> Result<()> {
18604 let request = types::xproto::PolyText16Request {
18605 drawable,
18606 gc,
18607 x,
18608 y,
18609 items: Cow::Borrowed(items.as_ref()),
18610 };
18611 let cookie = self.send_void_request(request, false)?;
18612 self.wait_for_reply(cookie)
18613 }
18614 fn image_text8(
18615 &mut self,
18616 drawable: types::xproto::Drawable,
18617 gc: types::Gcontext,
18618 x: types::Int16,
18619 y: types::Int16,
18620 string: impl AsRef<[types::Char]>,
18621 ) -> Result<Cookie<()>> {
18622 let span = tracing::info_span!(
18623 "image_text8",
18624 drawable = ?drawable,
18625 gc = ?gc,
18626 x = ?x,
18627 y = ?y,
18628 );
18629 let _enter = span.enter();
18630 let request = types::xproto::ImageText8Request {
18631 drawable,
18632 gc,
18633 x,
18634 y,
18635 string: Cow::Borrowed(string.as_ref()),
18636 };
18637 let cookie = self.send_void_request(request, true);
18638 cookie
18639 }
18640 fn image_text8_checked(
18641 &mut self,
18642 drawable: types::xproto::Drawable,
18643 gc: types::Gcontext,
18644 x: types::Int16,
18645 y: types::Int16,
18646 string: impl AsRef<[types::Char]>,
18647 ) -> Result<()> {
18648 let request = types::xproto::ImageText8Request {
18649 drawable,
18650 gc,
18651 x,
18652 y,
18653 string: Cow::Borrowed(string.as_ref()),
18654 };
18655 let cookie = self.send_void_request(request, false)?;
18656 self.wait_for_reply(cookie)
18657 }
18658 fn image_text16(
18659 &mut self,
18660 drawable: types::xproto::Drawable,
18661 gc: types::Gcontext,
18662 x: types::Int16,
18663 y: types::Int16,
18664 string: impl AsRef<[types::Char2b]>,
18665 ) -> Result<Cookie<()>> {
18666 let span = tracing::info_span!(
18667 "image_text16",
18668 drawable = ?drawable,
18669 gc = ?gc,
18670 x = ?x,
18671 y = ?y,
18672 );
18673 let _enter = span.enter();
18674 let request = types::xproto::ImageText16Request {
18675 drawable,
18676 gc,
18677 x,
18678 y,
18679 string: Cow::Borrowed(string.as_ref()),
18680 };
18681 let cookie = self.send_void_request(request, true);
18682 cookie
18683 }
18684 fn image_text16_checked(
18685 &mut self,
18686 drawable: types::xproto::Drawable,
18687 gc: types::Gcontext,
18688 x: types::Int16,
18689 y: types::Int16,
18690 string: impl AsRef<[types::Char2b]>,
18691 ) -> Result<()> {
18692 let request = types::xproto::ImageText16Request {
18693 drawable,
18694 gc,
18695 x,
18696 y,
18697 string: Cow::Borrowed(string.as_ref()),
18698 };
18699 let cookie = self.send_void_request(request, false)?;
18700 self.wait_for_reply(cookie)
18701 }
18702 fn create_colormap(
18703 &mut self,
18704 alloc: types::ColormapAlloc,
18705 mid: types::Colormap,
18706 window: types::xproto::Window,
18707 visual: types::Visualid,
18708 ) -> Result<Cookie<()>> {
18709 let span = tracing::info_span!(
18710 "create_colormap",
18711 alloc = ?alloc,
18712 mid = ?mid,
18713 window = ?window,
18714 visual = ?visual,
18715 );
18716 let _enter = span.enter();
18717 let request = types::xproto::CreateColormapRequest {
18718 alloc,
18719 mid,
18720 window,
18721 visual,
18722 };
18723 let cookie = self.send_void_request(request, true);
18724 cookie
18725 }
18726 fn create_colormap_checked(
18727 &mut self,
18728 alloc: types::ColormapAlloc,
18729 mid: types::Colormap,
18730 window: types::xproto::Window,
18731 visual: types::Visualid,
18732 ) -> Result<()> {
18733 let request = types::xproto::CreateColormapRequest {
18734 alloc,
18735 mid,
18736 window,
18737 visual,
18738 };
18739 let cookie = self.send_void_request(request, false)?;
18740 self.wait_for_reply(cookie)
18741 }
18742 fn free_colormap(&mut self, cmap: types::Colormap) -> Result<Cookie<()>> {
18743 let span = tracing::info_span!(
18744 "free_colormap",
18745 cmap = ?cmap,
18746 );
18747 let _enter = span.enter();
18748 let request = types::xproto::FreeColormapRequest { cmap };
18749 let cookie = self.send_void_request(request, true);
18750 cookie
18751 }
18752 fn free_colormap_checked(&mut self, cmap: types::Colormap) -> Result<()> {
18753 let request = types::xproto::FreeColormapRequest { cmap };
18754 let cookie = self.send_void_request(request, false)?;
18755 self.wait_for_reply(cookie)
18756 }
18757 fn copy_colormap_and_free(
18758 &mut self,
18759 mid: types::Colormap,
18760 src_cmap: types::Colormap,
18761 ) -> Result<Cookie<()>> {
18762 let span = tracing::info_span!(
18763 "copy_colormap_and_free",
18764 mid = ?mid,
18765 src_cmap = ?src_cmap,
18766 );
18767 let _enter = span.enter();
18768 let request = types::xproto::CopyColormapAndFreeRequest { mid, src_cmap };
18769 let cookie = self.send_void_request(request, true);
18770 cookie
18771 }
18772 fn copy_colormap_and_free_checked(
18773 &mut self,
18774 mid: types::Colormap,
18775 src_cmap: types::Colormap,
18776 ) -> Result<()> {
18777 let request = types::xproto::CopyColormapAndFreeRequest { mid, src_cmap };
18778 let cookie = self.send_void_request(request, false)?;
18779 self.wait_for_reply(cookie)
18780 }
18781 fn install_colormap(&mut self, cmap: types::Colormap) -> Result<Cookie<()>> {
18782 let span = tracing::info_span!(
18783 "install_colormap",
18784 cmap = ?cmap,
18785 );
18786 let _enter = span.enter();
18787 let request = types::xproto::InstallColormapRequest { cmap };
18788 let cookie = self.send_void_request(request, true);
18789 cookie
18790 }
18791 fn install_colormap_checked(&mut self, cmap: types::Colormap) -> Result<()> {
18792 let request = types::xproto::InstallColormapRequest { cmap };
18793 let cookie = self.send_void_request(request, false)?;
18794 self.wait_for_reply(cookie)
18795 }
18796 fn uninstall_colormap(&mut self, cmap: types::Colormap) -> Result<Cookie<()>> {
18797 let span = tracing::info_span!(
18798 "uninstall_colormap",
18799 cmap = ?cmap,
18800 );
18801 let _enter = span.enter();
18802 let request = types::xproto::UninstallColormapRequest { cmap };
18803 let cookie = self.send_void_request(request, true);
18804 cookie
18805 }
18806 fn uninstall_colormap_checked(&mut self, cmap: types::Colormap) -> Result<()> {
18807 let request = types::xproto::UninstallColormapRequest { cmap };
18808 let cookie = self.send_void_request(request, false)?;
18809 self.wait_for_reply(cookie)
18810 }
18811 fn list_installed_colormaps(
18812 &mut self,
18813 window: types::xproto::Window,
18814 ) -> Result<Cookie<types::xproto::ListInstalledColormapsReply>> {
18815 let span = tracing::info_span!(
18816 "list_installed_colormaps",
18817 window = ?window,
18818 );
18819 let _enter = span.enter();
18820 let request = types::xproto::ListInstalledColormapsRequest { window };
18821 let cookie = self.send_reply_request(request);
18822 cookie
18823 }
18824 fn list_installed_colormaps_immediate(
18825 &mut self,
18826 window: types::xproto::Window,
18827 ) -> Result<types::xproto::ListInstalledColormapsReply> {
18828 let request = types::xproto::ListInstalledColormapsRequest { window };
18829 let cookie = self.send_reply_request(request)?;
18830 self.wait_for_reply(cookie)
18831 }
18832 fn alloc_color(
18833 &mut self,
18834 cmap: types::Colormap,
18835 red: types::Card16,
18836 green: types::Card16,
18837 blue: types::Card16,
18838 ) -> Result<Cookie<types::xproto::AllocColorReply>> {
18839 let span = tracing::info_span!(
18840 "alloc_color",
18841 cmap = ?cmap,
18842 red = ?red,
18843 green = ?green,
18844 blue = ?blue,
18845 );
18846 let _enter = span.enter();
18847 let request = types::xproto::AllocColorRequest {
18848 cmap,
18849 red,
18850 green,
18851 blue,
18852 };
18853 let cookie = self.send_reply_request(request);
18854 cookie
18855 }
18856 fn alloc_color_immediate(
18857 &mut self,
18858 cmap: types::Colormap,
18859 red: types::Card16,
18860 green: types::Card16,
18861 blue: types::Card16,
18862 ) -> Result<types::xproto::AllocColorReply> {
18863 let request = types::xproto::AllocColorRequest {
18864 cmap,
18865 red,
18866 green,
18867 blue,
18868 };
18869 let cookie = self.send_reply_request(request)?;
18870 self.wait_for_reply(cookie)
18871 }
18872 fn alloc_named_color(
18873 &mut self,
18874 cmap: types::Colormap,
18875 name: impl AsRef<[types::Char]>,
18876 ) -> Result<Cookie<types::xproto::AllocNamedColorReply>> {
18877 let span = tracing::info_span!(
18878 "alloc_named_color",
18879 cmap = ?cmap,
18880 );
18881 let _enter = span.enter();
18882 let request = types::xproto::AllocNamedColorRequest {
18883 cmap,
18884 name: Cow::Borrowed(name.as_ref()),
18885 };
18886 let cookie = self.send_reply_request(request);
18887 cookie
18888 }
18889 fn alloc_named_color_immediate(
18890 &mut self,
18891 cmap: types::Colormap,
18892 name: impl AsRef<[types::Char]>,
18893 ) -> Result<types::xproto::AllocNamedColorReply> {
18894 let request = types::xproto::AllocNamedColorRequest {
18895 cmap,
18896 name: Cow::Borrowed(name.as_ref()),
18897 };
18898 let cookie = self.send_reply_request(request)?;
18899 self.wait_for_reply(cookie)
18900 }
18901 fn alloc_color_cells(
18902 &mut self,
18903 contiguous: types::Bool,
18904 cmap: types::Colormap,
18905 colors: types::Card16,
18906 planes: types::Card16,
18907 ) -> Result<Cookie<types::xproto::AllocColorCellsReply>> {
18908 let span = tracing::info_span!(
18909 "alloc_color_cells",
18910 contiguous = ?contiguous,
18911 cmap = ?cmap,
18912 colors = ?colors,
18913 planes = ?planes,
18914 );
18915 let _enter = span.enter();
18916 let request = types::xproto::AllocColorCellsRequest {
18917 contiguous,
18918 cmap,
18919 colors,
18920 planes,
18921 };
18922 let cookie = self.send_reply_request(request);
18923 cookie
18924 }
18925 fn alloc_color_cells_immediate(
18926 &mut self,
18927 contiguous: types::Bool,
18928 cmap: types::Colormap,
18929 colors: types::Card16,
18930 planes: types::Card16,
18931 ) -> Result<types::xproto::AllocColorCellsReply> {
18932 let request = types::xproto::AllocColorCellsRequest {
18933 contiguous,
18934 cmap,
18935 colors,
18936 planes,
18937 };
18938 let cookie = self.send_reply_request(request)?;
18939 self.wait_for_reply(cookie)
18940 }
18941 fn alloc_color_planes(
18942 &mut self,
18943 contiguous: types::Bool,
18944 cmap: types::Colormap,
18945 colors: types::Card16,
18946 reds: types::Card16,
18947 greens: types::Card16,
18948 blues: types::Card16,
18949 ) -> Result<Cookie<types::xproto::AllocColorPlanesReply>> {
18950 let span = tracing::info_span!(
18951 "alloc_color_planes",
18952 contiguous = ?contiguous,
18953 cmap = ?cmap,
18954 colors = ?colors,
18955 reds = ?reds,
18956 greens = ?greens,
18957 blues = ?blues,
18958 );
18959 let _enter = span.enter();
18960 let request = types::xproto::AllocColorPlanesRequest {
18961 contiguous,
18962 cmap,
18963 colors,
18964 reds,
18965 greens,
18966 blues,
18967 };
18968 let cookie = self.send_reply_request(request);
18969 cookie
18970 }
18971 fn alloc_color_planes_immediate(
18972 &mut self,
18973 contiguous: types::Bool,
18974 cmap: types::Colormap,
18975 colors: types::Card16,
18976 reds: types::Card16,
18977 greens: types::Card16,
18978 blues: types::Card16,
18979 ) -> Result<types::xproto::AllocColorPlanesReply> {
18980 let request = types::xproto::AllocColorPlanesRequest {
18981 contiguous,
18982 cmap,
18983 colors,
18984 reds,
18985 greens,
18986 blues,
18987 };
18988 let cookie = self.send_reply_request(request)?;
18989 self.wait_for_reply(cookie)
18990 }
18991 fn free_colors(
18992 &mut self,
18993 cmap: types::Colormap,
18994 plane_mask: types::Card32,
18995 pixels: impl AsRef<[types::Card32]>,
18996 ) -> Result<Cookie<()>> {
18997 let span = tracing::info_span!(
18998 "free_colors",
18999 cmap = ?cmap,
19000 plane_mask = ?plane_mask,
19001 );
19002 let _enter = span.enter();
19003 let request = types::xproto::FreeColorsRequest {
19004 cmap,
19005 plane_mask,
19006 pixels: Cow::Borrowed(pixels.as_ref()),
19007 };
19008 let cookie = self.send_void_request(request, true);
19009 cookie
19010 }
19011 fn free_colors_checked(
19012 &mut self,
19013 cmap: types::Colormap,
19014 plane_mask: types::Card32,
19015 pixels: impl AsRef<[types::Card32]>,
19016 ) -> Result<()> {
19017 let request = types::xproto::FreeColorsRequest {
19018 cmap,
19019 plane_mask,
19020 pixels: Cow::Borrowed(pixels.as_ref()),
19021 };
19022 let cookie = self.send_void_request(request, false)?;
19023 self.wait_for_reply(cookie)
19024 }
19025 fn store_colors(
19026 &mut self,
19027 cmap: types::Colormap,
19028 items: impl AsRef<[types::Coloritem]>,
19029 ) -> Result<Cookie<()>> {
19030 let span = tracing::info_span!(
19031 "store_colors",
19032 cmap = ?cmap,
19033 );
19034 let _enter = span.enter();
19035 let request = types::xproto::StoreColorsRequest {
19036 cmap,
19037 items: Cow::Borrowed(items.as_ref()),
19038 };
19039 let cookie = self.send_void_request(request, true);
19040 cookie
19041 }
19042 fn store_colors_checked(
19043 &mut self,
19044 cmap: types::Colormap,
19045 items: impl AsRef<[types::Coloritem]>,
19046 ) -> Result<()> {
19047 let request = types::xproto::StoreColorsRequest {
19048 cmap,
19049 items: Cow::Borrowed(items.as_ref()),
19050 };
19051 let cookie = self.send_void_request(request, false)?;
19052 self.wait_for_reply(cookie)
19053 }
19054 fn store_named_color(
19055 &mut self,
19056 flags: impl Into<types::ColorFlag>,
19057 cmap: types::Colormap,
19058 pixel: types::Card32,
19059 name: impl AsRef<[types::Char]>,
19060 ) -> Result<Cookie<()>> {
19061 let span = tracing::info_span!(
19062 "store_named_color",
19063 cmap = ?cmap,
19064 pixel = ?pixel,
19065 );
19066 let _enter = span.enter();
19067 let request = types::xproto::StoreNamedColorRequest {
19068 flags: Into::<u32>::into(flags.into()) as _,
19069 cmap,
19070 pixel,
19071 name: Cow::Borrowed(name.as_ref()),
19072 };
19073 let cookie = self.send_void_request(request, true);
19074 cookie
19075 }
19076 fn store_named_color_checked(
19077 &mut self,
19078 flags: impl Into<types::ColorFlag>,
19079 cmap: types::Colormap,
19080 pixel: types::Card32,
19081 name: impl AsRef<[types::Char]>,
19082 ) -> Result<()> {
19083 let request = types::xproto::StoreNamedColorRequest {
19084 flags: Into::<u32>::into(flags.into()) as _,
19085 cmap,
19086 pixel,
19087 name: Cow::Borrowed(name.as_ref()),
19088 };
19089 let cookie = self.send_void_request(request, false)?;
19090 self.wait_for_reply(cookie)
19091 }
19092 fn query_colors(
19093 &mut self,
19094 cmap: types::Colormap,
19095 pixels: impl AsRef<[types::Card32]>,
19096 ) -> Result<Cookie<types::xproto::QueryColorsReply>> {
19097 let span = tracing::info_span!(
19098 "query_colors",
19099 cmap = ?cmap,
19100 );
19101 let _enter = span.enter();
19102 let request = types::xproto::QueryColorsRequest {
19103 cmap,
19104 pixels: Cow::Borrowed(pixels.as_ref()),
19105 };
19106 let cookie = self.send_reply_request(request);
19107 cookie
19108 }
19109 fn query_colors_immediate(
19110 &mut self,
19111 cmap: types::Colormap,
19112 pixels: impl AsRef<[types::Card32]>,
19113 ) -> Result<types::xproto::QueryColorsReply> {
19114 let request = types::xproto::QueryColorsRequest {
19115 cmap,
19116 pixels: Cow::Borrowed(pixels.as_ref()),
19117 };
19118 let cookie = self.send_reply_request(request)?;
19119 self.wait_for_reply(cookie)
19120 }
19121 fn lookup_color(
19122 &mut self,
19123 cmap: types::Colormap,
19124 name: impl AsRef<[types::Char]>,
19125 ) -> Result<Cookie<types::xproto::LookupColorReply>> {
19126 let span = tracing::info_span!(
19127 "lookup_color",
19128 cmap = ?cmap,
19129 );
19130 let _enter = span.enter();
19131 let request = types::xproto::LookupColorRequest {
19132 cmap,
19133 name: Cow::Borrowed(name.as_ref()),
19134 };
19135 let cookie = self.send_reply_request(request);
19136 cookie
19137 }
19138 fn lookup_color_immediate(
19139 &mut self,
19140 cmap: types::Colormap,
19141 name: impl AsRef<[types::Char]>,
19142 ) -> Result<types::xproto::LookupColorReply> {
19143 let request = types::xproto::LookupColorRequest {
19144 cmap,
19145 name: Cow::Borrowed(name.as_ref()),
19146 };
19147 let cookie = self.send_reply_request(request)?;
19148 self.wait_for_reply(cookie)
19149 }
19150 fn create_cursor(
19151 &mut self,
19152 cid: types::xproto::Cursor,
19153 source: types::xproto::Pixmap,
19154 mask: impl Into<types::xproto::Pixmap>,
19155 fore_red: types::Card16,
19156 fore_green: types::Card16,
19157 fore_blue: types::Card16,
19158 back_red: types::Card16,
19159 back_green: types::Card16,
19160 back_blue: types::Card16,
19161 x: types::Card16,
19162 y: types::Card16,
19163 ) -> Result<Cookie<()>> {
19164 let span = tracing::info_span!(
19165 "create_cursor",
19166 cid = ?cid,
19167 source = ?source,
19168 fore_red = ?fore_red,
19169 fore_green = ?fore_green,
19170 fore_blue = ?fore_blue,
19171 back_red = ?back_red,
19172 back_green = ?back_green,
19173 back_blue = ?back_blue,
19174 x = ?x,
19175 y = ?y,
19176 );
19177 let _enter = span.enter();
19178 let request = types::xproto::CreateCursorRequest {
19179 cid,
19180 source,
19181 mask: Into::<u32>::into(mask.into()) as _,
19182 fore_red,
19183 fore_green,
19184 fore_blue,
19185 back_red,
19186 back_green,
19187 back_blue,
19188 x,
19189 y,
19190 };
19191 let cookie = self.send_void_request(request, true);
19192 cookie
19193 }
19194 fn create_cursor_checked(
19195 &mut self,
19196 cid: types::xproto::Cursor,
19197 source: types::xproto::Pixmap,
19198 mask: impl Into<types::xproto::Pixmap>,
19199 fore_red: types::Card16,
19200 fore_green: types::Card16,
19201 fore_blue: types::Card16,
19202 back_red: types::Card16,
19203 back_green: types::Card16,
19204 back_blue: types::Card16,
19205 x: types::Card16,
19206 y: types::Card16,
19207 ) -> Result<()> {
19208 let request = types::xproto::CreateCursorRequest {
19209 cid,
19210 source,
19211 mask: Into::<u32>::into(mask.into()) as _,
19212 fore_red,
19213 fore_green,
19214 fore_blue,
19215 back_red,
19216 back_green,
19217 back_blue,
19218 x,
19219 y,
19220 };
19221 let cookie = self.send_void_request(request, false)?;
19222 self.wait_for_reply(cookie)
19223 }
19224 fn create_glyph_cursor(
19225 &mut self,
19226 cid: types::xproto::Cursor,
19227 source_font: types::Font,
19228 mask_font: impl Into<types::Font>,
19229 source_char: types::Card16,
19230 mask_char: types::Card16,
19231 fore_red: types::Card16,
19232 fore_green: types::Card16,
19233 fore_blue: types::Card16,
19234 back_red: types::Card16,
19235 back_green: types::Card16,
19236 back_blue: types::Card16,
19237 ) -> Result<Cookie<()>> {
19238 let span = tracing::info_span!(
19239 "create_glyph_cursor",
19240 cid = ?cid,
19241 source_font = ?source_font,
19242 source_char = ?source_char,
19243 mask_char = ?mask_char,
19244 fore_red = ?fore_red,
19245 fore_green = ?fore_green,
19246 fore_blue = ?fore_blue,
19247 back_red = ?back_red,
19248 back_green = ?back_green,
19249 back_blue = ?back_blue,
19250 );
19251 let _enter = span.enter();
19252 let request = types::xproto::CreateGlyphCursorRequest {
19253 cid,
19254 source_font,
19255 mask_font: Into::<u32>::into(mask_font.into()) as _,
19256 source_char,
19257 mask_char,
19258 fore_red,
19259 fore_green,
19260 fore_blue,
19261 back_red,
19262 back_green,
19263 back_blue,
19264 };
19265 let cookie = self.send_void_request(request, true);
19266 cookie
19267 }
19268 fn create_glyph_cursor_checked(
19269 &mut self,
19270 cid: types::xproto::Cursor,
19271 source_font: types::Font,
19272 mask_font: impl Into<types::Font>,
19273 source_char: types::Card16,
19274 mask_char: types::Card16,
19275 fore_red: types::Card16,
19276 fore_green: types::Card16,
19277 fore_blue: types::Card16,
19278 back_red: types::Card16,
19279 back_green: types::Card16,
19280 back_blue: types::Card16,
19281 ) -> Result<()> {
19282 let request = types::xproto::CreateGlyphCursorRequest {
19283 cid,
19284 source_font,
19285 mask_font: Into::<u32>::into(mask_font.into()) as _,
19286 source_char,
19287 mask_char,
19288 fore_red,
19289 fore_green,
19290 fore_blue,
19291 back_red,
19292 back_green,
19293 back_blue,
19294 };
19295 let cookie = self.send_void_request(request, false)?;
19296 self.wait_for_reply(cookie)
19297 }
19298 fn free_cursor(&mut self, cursor: types::xproto::Cursor) -> Result<Cookie<()>> {
19299 let span = tracing::info_span!(
19300 "free_cursor",
19301 cursor = ?cursor,
19302 );
19303 let _enter = span.enter();
19304 let request = types::xproto::FreeCursorRequest { cursor };
19305 let cookie = self.send_void_request(request, true);
19306 cookie
19307 }
19308 fn free_cursor_checked(&mut self, cursor: types::xproto::Cursor) -> Result<()> {
19309 let request = types::xproto::FreeCursorRequest { cursor };
19310 let cookie = self.send_void_request(request, false)?;
19311 self.wait_for_reply(cookie)
19312 }
19313 fn recolor_cursor(
19314 &mut self,
19315 cursor: types::xproto::Cursor,
19316 fore_red: types::Card16,
19317 fore_green: types::Card16,
19318 fore_blue: types::Card16,
19319 back_red: types::Card16,
19320 back_green: types::Card16,
19321 back_blue: types::Card16,
19322 ) -> Result<Cookie<()>> {
19323 let span = tracing::info_span!(
19324 "recolor_cursor",
19325 cursor = ?cursor,
19326 fore_red = ?fore_red,
19327 fore_green = ?fore_green,
19328 fore_blue = ?fore_blue,
19329 back_red = ?back_red,
19330 back_green = ?back_green,
19331 back_blue = ?back_blue,
19332 );
19333 let _enter = span.enter();
19334 let request = types::xproto::RecolorCursorRequest {
19335 cursor,
19336 fore_red,
19337 fore_green,
19338 fore_blue,
19339 back_red,
19340 back_green,
19341 back_blue,
19342 };
19343 let cookie = self.send_void_request(request, true);
19344 cookie
19345 }
19346 fn recolor_cursor_checked(
19347 &mut self,
19348 cursor: types::xproto::Cursor,
19349 fore_red: types::Card16,
19350 fore_green: types::Card16,
19351 fore_blue: types::Card16,
19352 back_red: types::Card16,
19353 back_green: types::Card16,
19354 back_blue: types::Card16,
19355 ) -> Result<()> {
19356 let request = types::xproto::RecolorCursorRequest {
19357 cursor,
19358 fore_red,
19359 fore_green,
19360 fore_blue,
19361 back_red,
19362 back_green,
19363 back_blue,
19364 };
19365 let cookie = self.send_void_request(request, false)?;
19366 self.wait_for_reply(cookie)
19367 }
19368 fn query_best_size(
19369 &mut self,
19370 class: types::QueryShapeOf,
19371 drawable: types::xproto::Drawable,
19372 width: types::Card16,
19373 height: types::Card16,
19374 ) -> Result<Cookie<types::xproto::QueryBestSizeReply>> {
19375 let span = tracing::info_span!(
19376 "query_best_size",
19377 class = ?class,
19378 drawable = ?drawable,
19379 width = ?width,
19380 height = ?height,
19381 );
19382 let _enter = span.enter();
19383 let request = types::xproto::QueryBestSizeRequest {
19384 class,
19385 drawable,
19386 width,
19387 height,
19388 };
19389 let cookie = self.send_reply_request(request);
19390 cookie
19391 }
19392 fn query_best_size_immediate(
19393 &mut self,
19394 class: types::QueryShapeOf,
19395 drawable: types::xproto::Drawable,
19396 width: types::Card16,
19397 height: types::Card16,
19398 ) -> Result<types::xproto::QueryBestSizeReply> {
19399 let request = types::xproto::QueryBestSizeRequest {
19400 class,
19401 drawable,
19402 width,
19403 height,
19404 };
19405 let cookie = self.send_reply_request(request)?;
19406 self.wait_for_reply(cookie)
19407 }
19408 fn query_extension(
19409 &mut self,
19410 name: impl AsRef<[types::Char]>,
19411 ) -> Result<Cookie<types::xproto::QueryExtensionReply>> {
19412 let span = tracing::info_span!("query_extension",);
19413 let _enter = span.enter();
19414 let request = types::xproto::QueryExtensionRequest {
19415 name: Cow::Borrowed(name.as_ref()),
19416 };
19417 let cookie = self.send_reply_request(request);
19418 cookie
19419 }
19420 fn query_extension_immediate(
19421 &mut self,
19422 name: impl AsRef<[types::Char]>,
19423 ) -> Result<types::xproto::QueryExtensionReply> {
19424 let request = types::xproto::QueryExtensionRequest {
19425 name: Cow::Borrowed(name.as_ref()),
19426 };
19427 let cookie = self.send_reply_request(request)?;
19428 self.wait_for_reply(cookie)
19429 }
19430 fn list_extensions(&mut self) -> Result<Cookie<types::xproto::ListExtensionsReply>> {
19431 let span = tracing::info_span!("list_extensions",);
19432 let _enter = span.enter();
19433 let request = types::xproto::ListExtensionsRequest {};
19434 let cookie = self.send_reply_request(request);
19435 cookie
19436 }
19437 fn list_extensions_immediate(&mut self) -> Result<types::xproto::ListExtensionsReply> {
19438 let request = types::xproto::ListExtensionsRequest {};
19439 let cookie = self.send_reply_request(request)?;
19440 self.wait_for_reply(cookie)
19441 }
19442 fn change_keyboard_mapping(
19443 &mut self,
19444 keycode_count: types::Card8,
19445 first_keycode: types::Keycode,
19446 keysyms_per_keycode: types::Card8,
19447 keysyms: impl AsRef<[types::Keysym]>,
19448 ) -> Result<Cookie<()>> {
19449 let span = tracing::info_span!(
19450 "change_keyboard_mapping",
19451 keycode_count = ?keycode_count,
19452 first_keycode = ?first_keycode,
19453 keysyms_per_keycode = ?keysyms_per_keycode,
19454 );
19455 let _enter = span.enter();
19456 let request = types::xproto::ChangeKeyboardMappingRequest {
19457 keycode_count,
19458 first_keycode,
19459 keysyms_per_keycode,
19460 keysyms: Cow::Borrowed(keysyms.as_ref()),
19461 };
19462 let cookie = self.send_void_request(request, true);
19463 cookie
19464 }
19465 fn change_keyboard_mapping_checked(
19466 &mut self,
19467 keycode_count: types::Card8,
19468 first_keycode: types::Keycode,
19469 keysyms_per_keycode: types::Card8,
19470 keysyms: impl AsRef<[types::Keysym]>,
19471 ) -> Result<()> {
19472 let request = types::xproto::ChangeKeyboardMappingRequest {
19473 keycode_count,
19474 first_keycode,
19475 keysyms_per_keycode,
19476 keysyms: Cow::Borrowed(keysyms.as_ref()),
19477 };
19478 let cookie = self.send_void_request(request, false)?;
19479 self.wait_for_reply(cookie)
19480 }
19481 fn get_keyboard_mapping(
19482 &mut self,
19483 first_keycode: types::Keycode,
19484 count: types::Card8,
19485 ) -> Result<Cookie<types::xproto::GetKeyboardMappingReply>> {
19486 let span = tracing::info_span!(
19487 "get_keyboard_mapping",
19488 first_keycode = ?first_keycode,
19489 count = ?count,
19490 );
19491 let _enter = span.enter();
19492 let request = types::xproto::GetKeyboardMappingRequest {
19493 first_keycode,
19494 count,
19495 };
19496 let cookie = self.send_reply_request(request);
19497 cookie
19498 }
19499 fn get_keyboard_mapping_immediate(
19500 &mut self,
19501 first_keycode: types::Keycode,
19502 count: types::Card8,
19503 ) -> Result<types::xproto::GetKeyboardMappingReply> {
19504 let request = types::xproto::GetKeyboardMappingRequest {
19505 first_keycode,
19506 count,
19507 };
19508 let cookie = self.send_reply_request(request)?;
19509 self.wait_for_reply(cookie)
19510 }
19511 fn change_keyboard_control(
19512 &mut self,
19513 value_list: impl Borrow<types::xproto::ChangeKeyboardControlAux>,
19514 ) -> Result<Cookie<()>> {
19515 let span = tracing::info_span!("change_keyboard_control",);
19516 let _enter = span.enter();
19517 let request = types::xproto::ChangeKeyboardControlRequest {
19518 value_list: Cow::Borrowed(value_list.borrow()),
19519 };
19520 let cookie = self.send_void_request(request, true);
19521 cookie
19522 }
19523 fn change_keyboard_control_checked(
19524 &mut self,
19525 value_list: impl Borrow<types::xproto::ChangeKeyboardControlAux>,
19526 ) -> Result<()> {
19527 let request = types::xproto::ChangeKeyboardControlRequest {
19528 value_list: Cow::Borrowed(value_list.borrow()),
19529 };
19530 let cookie = self.send_void_request(request, false)?;
19531 self.wait_for_reply(cookie)
19532 }
19533 fn get_keyboard_control(&mut self) -> Result<Cookie<types::xproto::GetKeyboardControlReply>> {
19534 let span = tracing::info_span!("get_keyboard_control",);
19535 let _enter = span.enter();
19536 let request = types::xproto::GetKeyboardControlRequest {};
19537 let cookie = self.send_reply_request(request);
19538 cookie
19539 }
19540 fn get_keyboard_control_immediate(&mut self) -> Result<types::xproto::GetKeyboardControlReply> {
19541 let request = types::xproto::GetKeyboardControlRequest {};
19542 let cookie = self.send_reply_request(request)?;
19543 self.wait_for_reply(cookie)
19544 }
19545 fn bell(&mut self, percent: types::Int8) -> Result<Cookie<()>> {
19546 let span = tracing::info_span!(
19547 "bell",
19548 percent = ?percent,
19549 );
19550 let _enter = span.enter();
19551 let request = types::xproto::BellRequest { percent };
19552 let cookie = self.send_void_request(request, true);
19553 cookie
19554 }
19555 fn bell_checked(&mut self, percent: types::Int8) -> Result<()> {
19556 let request = types::xproto::BellRequest { percent };
19557 let cookie = self.send_void_request(request, false)?;
19558 self.wait_for_reply(cookie)
19559 }
19560 fn change_pointer_control(
19561 &mut self,
19562 acceleration_numerator: types::Int16,
19563 acceleration_denominator: types::Int16,
19564 threshold: types::Int16,
19565 do_acceleration: types::Bool,
19566 do_threshold: types::Bool,
19567 ) -> Result<Cookie<()>> {
19568 let span = tracing::info_span!(
19569 "change_pointer_control",
19570 acceleration_numerator = ?acceleration_numerator,
19571 acceleration_denominator = ?acceleration_denominator,
19572 threshold = ?threshold,
19573 do_acceleration = ?do_acceleration,
19574 do_threshold = ?do_threshold,
19575 );
19576 let _enter = span.enter();
19577 let request = types::xproto::ChangePointerControlRequest {
19578 acceleration_numerator,
19579 acceleration_denominator,
19580 threshold,
19581 do_acceleration,
19582 do_threshold,
19583 };
19584 let cookie = self.send_void_request(request, true);
19585 cookie
19586 }
19587 fn change_pointer_control_checked(
19588 &mut self,
19589 acceleration_numerator: types::Int16,
19590 acceleration_denominator: types::Int16,
19591 threshold: types::Int16,
19592 do_acceleration: types::Bool,
19593 do_threshold: types::Bool,
19594 ) -> Result<()> {
19595 let request = types::xproto::ChangePointerControlRequest {
19596 acceleration_numerator,
19597 acceleration_denominator,
19598 threshold,
19599 do_acceleration,
19600 do_threshold,
19601 };
19602 let cookie = self.send_void_request(request, false)?;
19603 self.wait_for_reply(cookie)
19604 }
19605 fn get_pointer_control(&mut self) -> Result<Cookie<types::xproto::GetPointerControlReply>> {
19606 let span = tracing::info_span!("get_pointer_control",);
19607 let _enter = span.enter();
19608 let request = types::xproto::GetPointerControlRequest {};
19609 let cookie = self.send_reply_request(request);
19610 cookie
19611 }
19612 fn get_pointer_control_immediate(&mut self) -> Result<types::xproto::GetPointerControlReply> {
19613 let request = types::xproto::GetPointerControlRequest {};
19614 let cookie = self.send_reply_request(request)?;
19615 self.wait_for_reply(cookie)
19616 }
19617 fn set_screen_saver(
19618 &mut self,
19619 timeout: types::Int16,
19620 interval: types::Int16,
19621 prefer_blanking: types::Blanking,
19622 allow_exposures: types::Exposures,
19623 ) -> Result<Cookie<()>> {
19624 let span = tracing::info_span!(
19625 "set_screen_saver",
19626 timeout = ?timeout,
19627 interval = ?interval,
19628 prefer_blanking = ?prefer_blanking,
19629 allow_exposures = ?allow_exposures,
19630 );
19631 let _enter = span.enter();
19632 let request = types::xproto::SetScreenSaverRequest {
19633 timeout,
19634 interval,
19635 prefer_blanking,
19636 allow_exposures,
19637 };
19638 let cookie = self.send_void_request(request, true);
19639 cookie
19640 }
19641 fn set_screen_saver_checked(
19642 &mut self,
19643 timeout: types::Int16,
19644 interval: types::Int16,
19645 prefer_blanking: types::Blanking,
19646 allow_exposures: types::Exposures,
19647 ) -> Result<()> {
19648 let request = types::xproto::SetScreenSaverRequest {
19649 timeout,
19650 interval,
19651 prefer_blanking,
19652 allow_exposures,
19653 };
19654 let cookie = self.send_void_request(request, false)?;
19655 self.wait_for_reply(cookie)
19656 }
19657 fn get_screen_saver(&mut self) -> Result<Cookie<types::xproto::GetScreenSaverReply>> {
19658 let span = tracing::info_span!("get_screen_saver",);
19659 let _enter = span.enter();
19660 let request = types::xproto::GetScreenSaverRequest {};
19661 let cookie = self.send_reply_request(request);
19662 cookie
19663 }
19664 fn get_screen_saver_immediate(&mut self) -> Result<types::xproto::GetScreenSaverReply> {
19665 let request = types::xproto::GetScreenSaverRequest {};
19666 let cookie = self.send_reply_request(request)?;
19667 self.wait_for_reply(cookie)
19668 }
19669 fn change_hosts(
19670 &mut self,
19671 mode: types::HostMode,
19672 family: types::Family,
19673 address: impl AsRef<[types::Byte]>,
19674 ) -> Result<Cookie<()>> {
19675 let span = tracing::info_span!(
19676 "change_hosts",
19677 mode = ?mode,
19678 family = ?family,
19679 );
19680 let _enter = span.enter();
19681 let request = types::xproto::ChangeHostsRequest {
19682 mode,
19683 family,
19684 address: Cow::Borrowed(address.as_ref()),
19685 };
19686 let cookie = self.send_void_request(request, true);
19687 cookie
19688 }
19689 fn change_hosts_checked(
19690 &mut self,
19691 mode: types::HostMode,
19692 family: types::Family,
19693 address: impl AsRef<[types::Byte]>,
19694 ) -> Result<()> {
19695 let request = types::xproto::ChangeHostsRequest {
19696 mode,
19697 family,
19698 address: Cow::Borrowed(address.as_ref()),
19699 };
19700 let cookie = self.send_void_request(request, false)?;
19701 self.wait_for_reply(cookie)
19702 }
19703 fn list_hosts(&mut self) -> Result<Cookie<types::xproto::ListHostsReply>> {
19704 let span = tracing::info_span!("list_hosts",);
19705 let _enter = span.enter();
19706 let request = types::xproto::ListHostsRequest {};
19707 let cookie = self.send_reply_request(request);
19708 cookie
19709 }
19710 fn list_hosts_immediate(&mut self) -> Result<types::xproto::ListHostsReply> {
19711 let request = types::xproto::ListHostsRequest {};
19712 let cookie = self.send_reply_request(request)?;
19713 self.wait_for_reply(cookie)
19714 }
19715 fn set_access_control(&mut self, mode: types::AccessControl) -> Result<Cookie<()>> {
19716 let span = tracing::info_span!(
19717 "set_access_control",
19718 mode = ?mode,
19719 );
19720 let _enter = span.enter();
19721 let request = types::xproto::SetAccessControlRequest { mode };
19722 let cookie = self.send_void_request(request, true);
19723 cookie
19724 }
19725 fn set_access_control_checked(&mut self, mode: types::AccessControl) -> Result<()> {
19726 let request = types::xproto::SetAccessControlRequest { mode };
19727 let cookie = self.send_void_request(request, false)?;
19728 self.wait_for_reply(cookie)
19729 }
19730 fn set_close_down_mode(&mut self, mode: types::CloseDown) -> Result<Cookie<()>> {
19731 let span = tracing::info_span!(
19732 "set_close_down_mode",
19733 mode = ?mode,
19734 );
19735 let _enter = span.enter();
19736 let request = types::xproto::SetCloseDownModeRequest { mode };
19737 let cookie = self.send_void_request(request, true);
19738 cookie
19739 }
19740 fn set_close_down_mode_checked(&mut self, mode: types::CloseDown) -> Result<()> {
19741 let request = types::xproto::SetCloseDownModeRequest { mode };
19742 let cookie = self.send_void_request(request, false)?;
19743 self.wait_for_reply(cookie)
19744 }
19745 fn kill_client(&mut self, resource: impl Into<types::Kill>) -> Result<Cookie<()>> {
19746 let span = tracing::info_span!("kill_client",);
19747 let _enter = span.enter();
19748 let request = types::xproto::KillClientRequest {
19749 resource: Into::<u32>::into(resource.into()) as _,
19750 };
19751 let cookie = self.send_void_request(request, true);
19752 cookie
19753 }
19754 fn kill_client_checked(&mut self, resource: impl Into<types::Kill>) -> Result<()> {
19755 let request = types::xproto::KillClientRequest {
19756 resource: Into::<u32>::into(resource.into()) as _,
19757 };
19758 let cookie = self.send_void_request(request, false)?;
19759 self.wait_for_reply(cookie)
19760 }
19761 fn rotate_properties(
19762 &mut self,
19763 window: types::xproto::Window,
19764 delta: types::Int16,
19765 atoms: impl AsRef<[types::Atom]>,
19766 ) -> Result<Cookie<()>> {
19767 let span = tracing::info_span!(
19768 "rotate_properties",
19769 window = ?window,
19770 delta = ?delta,
19771 );
19772 let _enter = span.enter();
19773 let request = types::xproto::RotatePropertiesRequest {
19774 window,
19775 delta,
19776 atoms: Cow::Borrowed(atoms.as_ref()),
19777 };
19778 let cookie = self.send_void_request(request, true);
19779 cookie
19780 }
19781 fn rotate_properties_checked(
19782 &mut self,
19783 window: types::xproto::Window,
19784 delta: types::Int16,
19785 atoms: impl AsRef<[types::Atom]>,
19786 ) -> Result<()> {
19787 let request = types::xproto::RotatePropertiesRequest {
19788 window,
19789 delta,
19790 atoms: Cow::Borrowed(atoms.as_ref()),
19791 };
19792 let cookie = self.send_void_request(request, false)?;
19793 self.wait_for_reply(cookie)
19794 }
19795 fn force_screen_saver(&mut self, mode: types::ScreenSaver) -> Result<Cookie<()>> {
19796 let span = tracing::info_span!(
19797 "force_screen_saver",
19798 mode = ?mode,
19799 );
19800 let _enter = span.enter();
19801 let request = types::xproto::ForceScreenSaverRequest { mode };
19802 let cookie = self.send_void_request(request, true);
19803 cookie
19804 }
19805 fn force_screen_saver_checked(&mut self, mode: types::ScreenSaver) -> Result<()> {
19806 let request = types::xproto::ForceScreenSaverRequest { mode };
19807 let cookie = self.send_void_request(request, false)?;
19808 self.wait_for_reply(cookie)
19809 }
19810 fn set_pointer_mapping(
19811 &mut self,
19812 map: impl AsRef<[types::Card8]>,
19813 ) -> Result<Cookie<types::xproto::SetPointerMappingReply>> {
19814 let span = tracing::info_span!("set_pointer_mapping",);
19815 let _enter = span.enter();
19816 let request = types::xproto::SetPointerMappingRequest {
19817 map: Cow::Borrowed(map.as_ref()),
19818 };
19819 let cookie = self.send_reply_request(request);
19820 cookie
19821 }
19822 fn set_pointer_mapping_immediate(
19823 &mut self,
19824 map: impl AsRef<[types::Card8]>,
19825 ) -> Result<types::xproto::SetPointerMappingReply> {
19826 let request = types::xproto::SetPointerMappingRequest {
19827 map: Cow::Borrowed(map.as_ref()),
19828 };
19829 let cookie = self.send_reply_request(request)?;
19830 self.wait_for_reply(cookie)
19831 }
19832 fn get_pointer_mapping(&mut self) -> Result<Cookie<types::xproto::GetPointerMappingReply>> {
19833 let span = tracing::info_span!("get_pointer_mapping",);
19834 let _enter = span.enter();
19835 let request = types::xproto::GetPointerMappingRequest {};
19836 let cookie = self.send_reply_request(request);
19837 cookie
19838 }
19839 fn get_pointer_mapping_immediate(&mut self) -> Result<types::xproto::GetPointerMappingReply> {
19840 let request = types::xproto::GetPointerMappingRequest {};
19841 let cookie = self.send_reply_request(request)?;
19842 self.wait_for_reply(cookie)
19843 }
19844 fn set_modifier_mapping(
19845 &mut self,
19846 keycodes: impl AsRef<[types::Keycode]>,
19847 ) -> Result<Cookie<types::xproto::SetModifierMappingReply>> {
19848 let span = tracing::info_span!("set_modifier_mapping",);
19849 let _enter = span.enter();
19850 let request = types::xproto::SetModifierMappingRequest {
19851 keycodes: Cow::Borrowed(keycodes.as_ref()),
19852 };
19853 let cookie = self.send_reply_request(request);
19854 cookie
19855 }
19856 fn set_modifier_mapping_immediate(
19857 &mut self,
19858 keycodes: impl AsRef<[types::Keycode]>,
19859 ) -> Result<types::xproto::SetModifierMappingReply> {
19860 let request = types::xproto::SetModifierMappingRequest {
19861 keycodes: Cow::Borrowed(keycodes.as_ref()),
19862 };
19863 let cookie = self.send_reply_request(request)?;
19864 self.wait_for_reply(cookie)
19865 }
19866 fn get_modifier_mapping(&mut self) -> Result<Cookie<types::xproto::GetModifierMappingReply>> {
19867 let span = tracing::info_span!("get_modifier_mapping",);
19868 let _enter = span.enter();
19869 let request = types::xproto::GetModifierMappingRequest {};
19870 let cookie = self.send_reply_request(request);
19871 cookie
19872 }
19873 fn get_modifier_mapping_immediate(&mut self) -> Result<types::xproto::GetModifierMappingReply> {
19874 let request = types::xproto::GetModifierMappingRequest {};
19875 let cookie = self.send_reply_request(request)?;
19876 self.wait_for_reply(cookie)
19877 }
19878 fn no_operation(&mut self) -> Result<Cookie<()>> {
19879 let span = tracing::info_span!("no_operation",);
19880 let _enter = span.enter();
19881 let request = types::xproto::NoOperationRequest {};
19882 let cookie = self.send_void_request(request, true);
19883 cookie
19884 }
19885 fn no_operation_checked(&mut self) -> Result<()> {
19886 let request = types::xproto::NoOperationRequest {};
19887 let cookie = self.send_void_request(request, false)?;
19888 self.wait_for_reply(cookie)
19889 }
19890
19891 #[cfg(feature = "xselinux")]
19892 fn xselinux_query_version(
19893 &mut self,
19894 client_major: types::Card8,
19895 client_minor: types::Card8,
19896 ) -> Result<Cookie<types::xselinux::QueryVersionReply>> {
19897 let span = tracing::info_span!(
19898 "xselinux_query_version",
19899 client_major = ?client_major,
19900 client_minor = ?client_minor,
19901 );
19902 let _enter = span.enter();
19903 let request = types::xselinux::QueryVersionRequest {
19904 client_major,
19905 client_minor,
19906 };
19907 let cookie = self.send_reply_request(request);
19908 cookie
19909 }
19910 #[cfg(feature = "xselinux")]
19911 fn xselinux_query_version_immediate(
19912 &mut self,
19913 client_major: types::Card8,
19914 client_minor: types::Card8,
19915 ) -> Result<types::xselinux::QueryVersionReply> {
19916 let request = types::xselinux::QueryVersionRequest {
19917 client_major,
19918 client_minor,
19919 };
19920 let cookie = self.send_reply_request(request)?;
19921 self.wait_for_reply(cookie)
19922 }
19923 #[cfg(feature = "xselinux")]
19924 fn xselinux_set_device_create_context(
19925 &mut self,
19926 context: impl AsRef<[types::Char]>,
19927 ) -> Result<Cookie<()>> {
19928 let span = tracing::info_span!("xselinux_set_device_create_context",);
19929 let _enter = span.enter();
19930 let request = types::xselinux::SetDeviceCreateContextRequest {
19931 context: Cow::Borrowed(context.as_ref()),
19932 };
19933 let cookie = self.send_void_request(request, true);
19934 cookie
19935 }
19936 #[cfg(feature = "xselinux")]
19937 fn xselinux_set_device_create_context_checked(
19938 &mut self,
19939 context: impl AsRef<[types::Char]>,
19940 ) -> Result<()> {
19941 let request = types::xselinux::SetDeviceCreateContextRequest {
19942 context: Cow::Borrowed(context.as_ref()),
19943 };
19944 let cookie = self.send_void_request(request, false)?;
19945 self.wait_for_reply(cookie)
19946 }
19947 #[cfg(feature = "xselinux")]
19948 fn xselinux_get_device_create_context(
19949 &mut self,
19950 ) -> Result<Cookie<types::xselinux::GetDeviceCreateContextReply>> {
19951 let span = tracing::info_span!("xselinux_get_device_create_context",);
19952 let _enter = span.enter();
19953 let request = types::xselinux::GetDeviceCreateContextRequest {};
19954 let cookie = self.send_reply_request(request);
19955 cookie
19956 }
19957 #[cfg(feature = "xselinux")]
19958 fn xselinux_get_device_create_context_immediate(
19959 &mut self,
19960 ) -> Result<types::xselinux::GetDeviceCreateContextReply> {
19961 let request = types::xselinux::GetDeviceCreateContextRequest {};
19962 let cookie = self.send_reply_request(request)?;
19963 self.wait_for_reply(cookie)
19964 }
19965 #[cfg(feature = "xselinux")]
19966 fn xselinux_set_device_context(
19967 &mut self,
19968 device: types::Card32,
19969 context: impl AsRef<[types::Char]>,
19970 ) -> Result<Cookie<()>> {
19971 let span = tracing::info_span!(
19972 "xselinux_set_device_context",
19973 device = ?device,
19974 );
19975 let _enter = span.enter();
19976 let request = types::xselinux::SetDeviceContextRequest {
19977 device,
19978 context: Cow::Borrowed(context.as_ref()),
19979 };
19980 let cookie = self.send_void_request(request, true);
19981 cookie
19982 }
19983 #[cfg(feature = "xselinux")]
19984 fn xselinux_set_device_context_checked(
19985 &mut self,
19986 device: types::Card32,
19987 context: impl AsRef<[types::Char]>,
19988 ) -> Result<()> {
19989 let request = types::xselinux::SetDeviceContextRequest {
19990 device,
19991 context: Cow::Borrowed(context.as_ref()),
19992 };
19993 let cookie = self.send_void_request(request, false)?;
19994 self.wait_for_reply(cookie)
19995 }
19996 #[cfg(feature = "xselinux")]
19997 fn xselinux_get_device_context(
19998 &mut self,
19999 device: types::Card32,
20000 ) -> Result<Cookie<types::xselinux::GetDeviceContextReply>> {
20001 let span = tracing::info_span!(
20002 "xselinux_get_device_context",
20003 device = ?device,
20004 );
20005 let _enter = span.enter();
20006 let request = types::xselinux::GetDeviceContextRequest { device };
20007 let cookie = self.send_reply_request(request);
20008 cookie
20009 }
20010 #[cfg(feature = "xselinux")]
20011 fn xselinux_get_device_context_immediate(
20012 &mut self,
20013 device: types::Card32,
20014 ) -> Result<types::xselinux::GetDeviceContextReply> {
20015 let request = types::xselinux::GetDeviceContextRequest { device };
20016 let cookie = self.send_reply_request(request)?;
20017 self.wait_for_reply(cookie)
20018 }
20019 #[cfg(feature = "xselinux")]
20020 fn xselinux_set_window_create_context(
20021 &mut self,
20022 context: impl AsRef<[types::Char]>,
20023 ) -> Result<Cookie<()>> {
20024 let span = tracing::info_span!("xselinux_set_window_create_context",);
20025 let _enter = span.enter();
20026 let request = types::xselinux::SetWindowCreateContextRequest {
20027 context: Cow::Borrowed(context.as_ref()),
20028 };
20029 let cookie = self.send_void_request(request, true);
20030 cookie
20031 }
20032 #[cfg(feature = "xselinux")]
20033 fn xselinux_set_window_create_context_checked(
20034 &mut self,
20035 context: impl AsRef<[types::Char]>,
20036 ) -> Result<()> {
20037 let request = types::xselinux::SetWindowCreateContextRequest {
20038 context: Cow::Borrowed(context.as_ref()),
20039 };
20040 let cookie = self.send_void_request(request, false)?;
20041 self.wait_for_reply(cookie)
20042 }
20043 #[cfg(feature = "xselinux")]
20044 fn xselinux_get_window_create_context(
20045 &mut self,
20046 ) -> Result<Cookie<types::xselinux::GetWindowCreateContextReply>> {
20047 let span = tracing::info_span!("xselinux_get_window_create_context",);
20048 let _enter = span.enter();
20049 let request = types::xselinux::GetWindowCreateContextRequest {};
20050 let cookie = self.send_reply_request(request);
20051 cookie
20052 }
20053 #[cfg(feature = "xselinux")]
20054 fn xselinux_get_window_create_context_immediate(
20055 &mut self,
20056 ) -> Result<types::xselinux::GetWindowCreateContextReply> {
20057 let request = types::xselinux::GetWindowCreateContextRequest {};
20058 let cookie = self.send_reply_request(request)?;
20059 self.wait_for_reply(cookie)
20060 }
20061 #[cfg(feature = "xselinux")]
20062 fn xselinux_get_window_context(
20063 &mut self,
20064 window: types::xproto::Window,
20065 ) -> Result<Cookie<types::xselinux::GetWindowContextReply>> {
20066 let span = tracing::info_span!(
20067 "xselinux_get_window_context",
20068 window = ?window,
20069 );
20070 let _enter = span.enter();
20071 let request = types::xselinux::GetWindowContextRequest { window };
20072 let cookie = self.send_reply_request(request);
20073 cookie
20074 }
20075 #[cfg(feature = "xselinux")]
20076 fn xselinux_get_window_context_immediate(
20077 &mut self,
20078 window: types::xproto::Window,
20079 ) -> Result<types::xselinux::GetWindowContextReply> {
20080 let request = types::xselinux::GetWindowContextRequest { window };
20081 let cookie = self.send_reply_request(request)?;
20082 self.wait_for_reply(cookie)
20083 }
20084 #[cfg(feature = "xselinux")]
20085 fn xselinux_set_property_create_context(
20086 &mut self,
20087 context: impl AsRef<[types::Char]>,
20088 ) -> Result<Cookie<()>> {
20089 let span = tracing::info_span!("xselinux_set_property_create_context",);
20090 let _enter = span.enter();
20091 let request = types::xselinux::SetPropertyCreateContextRequest {
20092 context: Cow::Borrowed(context.as_ref()),
20093 };
20094 let cookie = self.send_void_request(request, true);
20095 cookie
20096 }
20097 #[cfg(feature = "xselinux")]
20098 fn xselinux_set_property_create_context_checked(
20099 &mut self,
20100 context: impl AsRef<[types::Char]>,
20101 ) -> Result<()> {
20102 let request = types::xselinux::SetPropertyCreateContextRequest {
20103 context: Cow::Borrowed(context.as_ref()),
20104 };
20105 let cookie = self.send_void_request(request, false)?;
20106 self.wait_for_reply(cookie)
20107 }
20108 #[cfg(feature = "xselinux")]
20109 fn xselinux_get_property_create_context(
20110 &mut self,
20111 ) -> Result<Cookie<types::xselinux::GetPropertyCreateContextReply>> {
20112 let span = tracing::info_span!("xselinux_get_property_create_context",);
20113 let _enter = span.enter();
20114 let request = types::xselinux::GetPropertyCreateContextRequest {};
20115 let cookie = self.send_reply_request(request);
20116 cookie
20117 }
20118 #[cfg(feature = "xselinux")]
20119 fn xselinux_get_property_create_context_immediate(
20120 &mut self,
20121 ) -> Result<types::xselinux::GetPropertyCreateContextReply> {
20122 let request = types::xselinux::GetPropertyCreateContextRequest {};
20123 let cookie = self.send_reply_request(request)?;
20124 self.wait_for_reply(cookie)
20125 }
20126 #[cfg(feature = "xselinux")]
20127 fn xselinux_set_property_use_context(
20128 &mut self,
20129 context: impl AsRef<[types::Char]>,
20130 ) -> Result<Cookie<()>> {
20131 let span = tracing::info_span!("xselinux_set_property_use_context",);
20132 let _enter = span.enter();
20133 let request = types::xselinux::SetPropertyUseContextRequest {
20134 context: Cow::Borrowed(context.as_ref()),
20135 };
20136 let cookie = self.send_void_request(request, true);
20137 cookie
20138 }
20139 #[cfg(feature = "xselinux")]
20140 fn xselinux_set_property_use_context_checked(
20141 &mut self,
20142 context: impl AsRef<[types::Char]>,
20143 ) -> Result<()> {
20144 let request = types::xselinux::SetPropertyUseContextRequest {
20145 context: Cow::Borrowed(context.as_ref()),
20146 };
20147 let cookie = self.send_void_request(request, false)?;
20148 self.wait_for_reply(cookie)
20149 }
20150 #[cfg(feature = "xselinux")]
20151 fn xselinux_get_property_use_context(
20152 &mut self,
20153 ) -> Result<Cookie<types::xselinux::GetPropertyUseContextReply>> {
20154 let span = tracing::info_span!("xselinux_get_property_use_context",);
20155 let _enter = span.enter();
20156 let request = types::xselinux::GetPropertyUseContextRequest {};
20157 let cookie = self.send_reply_request(request);
20158 cookie
20159 }
20160 #[cfg(feature = "xselinux")]
20161 fn xselinux_get_property_use_context_immediate(
20162 &mut self,
20163 ) -> Result<types::xselinux::GetPropertyUseContextReply> {
20164 let request = types::xselinux::GetPropertyUseContextRequest {};
20165 let cookie = self.send_reply_request(request)?;
20166 self.wait_for_reply(cookie)
20167 }
20168 #[cfg(feature = "xselinux")]
20169 fn xselinux_get_property_context(
20170 &mut self,
20171 window: types::xproto::Window,
20172 property: types::Atom,
20173 ) -> Result<Cookie<types::xselinux::GetPropertyContextReply>> {
20174 let span = tracing::info_span!(
20175 "xselinux_get_property_context",
20176 window = ?window,
20177 property = ?property,
20178 );
20179 let _enter = span.enter();
20180 let request = types::xselinux::GetPropertyContextRequest { window, property };
20181 let cookie = self.send_reply_request(request);
20182 cookie
20183 }
20184 #[cfg(feature = "xselinux")]
20185 fn xselinux_get_property_context_immediate(
20186 &mut self,
20187 window: types::xproto::Window,
20188 property: types::Atom,
20189 ) -> Result<types::xselinux::GetPropertyContextReply> {
20190 let request = types::xselinux::GetPropertyContextRequest { window, property };
20191 let cookie = self.send_reply_request(request)?;
20192 self.wait_for_reply(cookie)
20193 }
20194 #[cfg(feature = "xselinux")]
20195 fn xselinux_get_property_data_context(
20196 &mut self,
20197 window: types::xproto::Window,
20198 property: types::Atom,
20199 ) -> Result<Cookie<types::xselinux::GetPropertyDataContextReply>> {
20200 let span = tracing::info_span!(
20201 "xselinux_get_property_data_context",
20202 window = ?window,
20203 property = ?property,
20204 );
20205 let _enter = span.enter();
20206 let request = types::xselinux::GetPropertyDataContextRequest { window, property };
20207 let cookie = self.send_reply_request(request);
20208 cookie
20209 }
20210 #[cfg(feature = "xselinux")]
20211 fn xselinux_get_property_data_context_immediate(
20212 &mut self,
20213 window: types::xproto::Window,
20214 property: types::Atom,
20215 ) -> Result<types::xselinux::GetPropertyDataContextReply> {
20216 let request = types::xselinux::GetPropertyDataContextRequest { window, property };
20217 let cookie = self.send_reply_request(request)?;
20218 self.wait_for_reply(cookie)
20219 }
20220 #[cfg(feature = "xselinux")]
20221 fn xselinux_list_properties(
20222 &mut self,
20223 window: types::xproto::Window,
20224 ) -> Result<Cookie<types::xselinux::ListPropertiesReply>> {
20225 let span = tracing::info_span!(
20226 "xselinux_list_properties",
20227 window = ?window,
20228 );
20229 let _enter = span.enter();
20230 let request = types::xselinux::ListPropertiesRequest { window };
20231 let cookie = self.send_reply_request(request);
20232 cookie
20233 }
20234 #[cfg(feature = "xselinux")]
20235 fn xselinux_list_properties_immediate(
20236 &mut self,
20237 window: types::xproto::Window,
20238 ) -> Result<types::xselinux::ListPropertiesReply> {
20239 let request = types::xselinux::ListPropertiesRequest { window };
20240 let cookie = self.send_reply_request(request)?;
20241 self.wait_for_reply(cookie)
20242 }
20243 #[cfg(feature = "xselinux")]
20244 fn xselinux_set_selection_create_context(
20245 &mut self,
20246 context: impl AsRef<[types::Char]>,
20247 ) -> Result<Cookie<()>> {
20248 let span = tracing::info_span!("xselinux_set_selection_create_context",);
20249 let _enter = span.enter();
20250 let request = types::xselinux::SetSelectionCreateContextRequest {
20251 context: Cow::Borrowed(context.as_ref()),
20252 };
20253 let cookie = self.send_void_request(request, true);
20254 cookie
20255 }
20256 #[cfg(feature = "xselinux")]
20257 fn xselinux_set_selection_create_context_checked(
20258 &mut self,
20259 context: impl AsRef<[types::Char]>,
20260 ) -> Result<()> {
20261 let request = types::xselinux::SetSelectionCreateContextRequest {
20262 context: Cow::Borrowed(context.as_ref()),
20263 };
20264 let cookie = self.send_void_request(request, false)?;
20265 self.wait_for_reply(cookie)
20266 }
20267 #[cfg(feature = "xselinux")]
20268 fn xselinux_get_selection_create_context(
20269 &mut self,
20270 ) -> Result<Cookie<types::xselinux::GetSelectionCreateContextReply>> {
20271 let span = tracing::info_span!("xselinux_get_selection_create_context",);
20272 let _enter = span.enter();
20273 let request = types::xselinux::GetSelectionCreateContextRequest {};
20274 let cookie = self.send_reply_request(request);
20275 cookie
20276 }
20277 #[cfg(feature = "xselinux")]
20278 fn xselinux_get_selection_create_context_immediate(
20279 &mut self,
20280 ) -> Result<types::xselinux::GetSelectionCreateContextReply> {
20281 let request = types::xselinux::GetSelectionCreateContextRequest {};
20282 let cookie = self.send_reply_request(request)?;
20283 self.wait_for_reply(cookie)
20284 }
20285 #[cfg(feature = "xselinux")]
20286 fn xselinux_set_selection_use_context(
20287 &mut self,
20288 context: impl AsRef<[types::Char]>,
20289 ) -> Result<Cookie<()>> {
20290 let span = tracing::info_span!("xselinux_set_selection_use_context",);
20291 let _enter = span.enter();
20292 let request = types::xselinux::SetSelectionUseContextRequest {
20293 context: Cow::Borrowed(context.as_ref()),
20294 };
20295 let cookie = self.send_void_request(request, true);
20296 cookie
20297 }
20298 #[cfg(feature = "xselinux")]
20299 fn xselinux_set_selection_use_context_checked(
20300 &mut self,
20301 context: impl AsRef<[types::Char]>,
20302 ) -> Result<()> {
20303 let request = types::xselinux::SetSelectionUseContextRequest {
20304 context: Cow::Borrowed(context.as_ref()),
20305 };
20306 let cookie = self.send_void_request(request, false)?;
20307 self.wait_for_reply(cookie)
20308 }
20309 #[cfg(feature = "xselinux")]
20310 fn xselinux_get_selection_use_context(
20311 &mut self,
20312 ) -> Result<Cookie<types::xselinux::GetSelectionUseContextReply>> {
20313 let span = tracing::info_span!("xselinux_get_selection_use_context",);
20314 let _enter = span.enter();
20315 let request = types::xselinux::GetSelectionUseContextRequest {};
20316 let cookie = self.send_reply_request(request);
20317 cookie
20318 }
20319 #[cfg(feature = "xselinux")]
20320 fn xselinux_get_selection_use_context_immediate(
20321 &mut self,
20322 ) -> Result<types::xselinux::GetSelectionUseContextReply> {
20323 let request = types::xselinux::GetSelectionUseContextRequest {};
20324 let cookie = self.send_reply_request(request)?;
20325 self.wait_for_reply(cookie)
20326 }
20327 #[cfg(feature = "xselinux")]
20328 fn xselinux_get_selection_context(
20329 &mut self,
20330 selection: types::Atom,
20331 ) -> Result<Cookie<types::xselinux::GetSelectionContextReply>> {
20332 let span = tracing::info_span!(
20333 "xselinux_get_selection_context",
20334 selection = ?selection,
20335 );
20336 let _enter = span.enter();
20337 let request = types::xselinux::GetSelectionContextRequest { selection };
20338 let cookie = self.send_reply_request(request);
20339 cookie
20340 }
20341 #[cfg(feature = "xselinux")]
20342 fn xselinux_get_selection_context_immediate(
20343 &mut self,
20344 selection: types::Atom,
20345 ) -> Result<types::xselinux::GetSelectionContextReply> {
20346 let request = types::xselinux::GetSelectionContextRequest { selection };
20347 let cookie = self.send_reply_request(request)?;
20348 self.wait_for_reply(cookie)
20349 }
20350 #[cfg(feature = "xselinux")]
20351 fn xselinux_get_selection_data_context(
20352 &mut self,
20353 selection: types::Atom,
20354 ) -> Result<Cookie<types::xselinux::GetSelectionDataContextReply>> {
20355 let span = tracing::info_span!(
20356 "xselinux_get_selection_data_context",
20357 selection = ?selection,
20358 );
20359 let _enter = span.enter();
20360 let request = types::xselinux::GetSelectionDataContextRequest { selection };
20361 let cookie = self.send_reply_request(request);
20362 cookie
20363 }
20364 #[cfg(feature = "xselinux")]
20365 fn xselinux_get_selection_data_context_immediate(
20366 &mut self,
20367 selection: types::Atom,
20368 ) -> Result<types::xselinux::GetSelectionDataContextReply> {
20369 let request = types::xselinux::GetSelectionDataContextRequest { selection };
20370 let cookie = self.send_reply_request(request)?;
20371 self.wait_for_reply(cookie)
20372 }
20373 #[cfg(feature = "xselinux")]
20374 fn xselinux_list_selections(&mut self) -> Result<Cookie<types::xselinux::ListSelectionsReply>> {
20375 let span = tracing::info_span!("xselinux_list_selections",);
20376 let _enter = span.enter();
20377 let request = types::xselinux::ListSelectionsRequest {};
20378 let cookie = self.send_reply_request(request);
20379 cookie
20380 }
20381 #[cfg(feature = "xselinux")]
20382 fn xselinux_list_selections_immediate(
20383 &mut self,
20384 ) -> Result<types::xselinux::ListSelectionsReply> {
20385 let request = types::xselinux::ListSelectionsRequest {};
20386 let cookie = self.send_reply_request(request)?;
20387 self.wait_for_reply(cookie)
20388 }
20389 #[cfg(feature = "xselinux")]
20390 fn xselinux_get_client_context(
20391 &mut self,
20392 resource: types::Card32,
20393 ) -> Result<Cookie<types::xselinux::GetClientContextReply>> {
20394 let span = tracing::info_span!(
20395 "xselinux_get_client_context",
20396 resource = ?resource,
20397 );
20398 let _enter = span.enter();
20399 let request = types::xselinux::GetClientContextRequest { resource };
20400 let cookie = self.send_reply_request(request);
20401 cookie
20402 }
20403 #[cfg(feature = "xselinux")]
20404 fn xselinux_get_client_context_immediate(
20405 &mut self,
20406 resource: types::Card32,
20407 ) -> Result<types::xselinux::GetClientContextReply> {
20408 let request = types::xselinux::GetClientContextRequest { resource };
20409 let cookie = self.send_reply_request(request)?;
20410 self.wait_for_reply(cookie)
20411 }
20412
20413 #[cfg(feature = "xtest")]
20414 fn xtest_get_version(
20415 &mut self,
20416 major_version: types::Card8,
20417 minor_version: types::Card16,
20418 ) -> Result<Cookie<types::xtest::GetVersionReply>> {
20419 let span = tracing::info_span!(
20420 "xtest_get_version",
20421 major_version = ?major_version,
20422 minor_version = ?minor_version,
20423 );
20424 let _enter = span.enter();
20425 let request = types::xtest::GetVersionRequest {
20426 major_version,
20427 minor_version,
20428 };
20429 let cookie = self.send_reply_request(request);
20430 cookie
20431 }
20432 #[cfg(feature = "xtest")]
20433 fn xtest_get_version_immediate(
20434 &mut self,
20435 major_version: types::Card8,
20436 minor_version: types::Card16,
20437 ) -> Result<types::xtest::GetVersionReply> {
20438 let request = types::xtest::GetVersionRequest {
20439 major_version,
20440 minor_version,
20441 };
20442 let cookie = self.send_reply_request(request)?;
20443 self.wait_for_reply(cookie)
20444 }
20445 #[cfg(feature = "xtest")]
20446 fn xtest_compare_cursor(
20447 &mut self,
20448 window: types::xproto::Window,
20449 cursor: types::xproto::Cursor,
20450 ) -> Result<Cookie<types::xtest::CompareCursorReply>> {
20451 let span = tracing::info_span!(
20452 "xtest_compare_cursor",
20453 window = ?window,
20454 cursor = ?cursor,
20455 );
20456 let _enter = span.enter();
20457 let request = types::xtest::CompareCursorRequest { window, cursor };
20458 let cookie = self.send_reply_request(request);
20459 cookie
20460 }
20461 #[cfg(feature = "xtest")]
20462 fn xtest_compare_cursor_immediate(
20463 &mut self,
20464 window: types::xproto::Window,
20465 cursor: types::xproto::Cursor,
20466 ) -> Result<types::xtest::CompareCursorReply> {
20467 let request = types::xtest::CompareCursorRequest { window, cursor };
20468 let cookie = self.send_reply_request(request)?;
20469 self.wait_for_reply(cookie)
20470 }
20471 #[cfg(feature = "xtest")]
20472 fn xtest_fake_input(
20473 &mut self,
20474 type_: types::Byte,
20475 detail: types::Byte,
20476 time: types::Card32,
20477 root: types::xproto::Window,
20478 root_x: types::Int16,
20479 root_y: types::Int16,
20480 deviceid: types::Card8,
20481 ) -> Result<Cookie<()>> {
20482 let span = tracing::info_span!(
20483 "xtest_fake_input",
20484 type_ = ?type_,
20485 detail = ?detail,
20486 time = ?time,
20487 root = ?root,
20488 root_x = ?root_x,
20489 root_y = ?root_y,
20490 deviceid = ?deviceid,
20491 );
20492 let _enter = span.enter();
20493 let request = types::xtest::FakeInputRequest {
20494 type_,
20495 detail,
20496 time,
20497 root,
20498 root_x,
20499 root_y,
20500 deviceid,
20501 };
20502 let cookie = self.send_void_request(request, true);
20503 cookie
20504 }
20505 #[cfg(feature = "xtest")]
20506 fn xtest_fake_input_checked(
20507 &mut self,
20508 type_: types::Byte,
20509 detail: types::Byte,
20510 time: types::Card32,
20511 root: types::xproto::Window,
20512 root_x: types::Int16,
20513 root_y: types::Int16,
20514 deviceid: types::Card8,
20515 ) -> Result<()> {
20516 let request = types::xtest::FakeInputRequest {
20517 type_,
20518 detail,
20519 time,
20520 root,
20521 root_x,
20522 root_y,
20523 deviceid,
20524 };
20525 let cookie = self.send_void_request(request, false)?;
20526 self.wait_for_reply(cookie)
20527 }
20528 #[cfg(feature = "xtest")]
20529 fn xtest_grab_control(&mut self, impervious: types::Bool) -> Result<Cookie<()>> {
20530 let span = tracing::info_span!(
20531 "xtest_grab_control",
20532 impervious = ?impervious,
20533 );
20534 let _enter = span.enter();
20535 let request = types::xtest::GrabControlRequest { impervious };
20536 let cookie = self.send_void_request(request, true);
20537 cookie
20538 }
20539 #[cfg(feature = "xtest")]
20540 fn xtest_grab_control_checked(&mut self, impervious: types::Bool) -> Result<()> {
20541 let request = types::xtest::GrabControlRequest { impervious };
20542 let cookie = self.send_void_request(request, false)?;
20543 self.wait_for_reply(cookie)
20544 }
20545
20546 #[cfg(feature = "xv")]
20547 fn xv_query_extension(&mut self) -> Result<Cookie<types::xv::QueryExtensionReply>> {
20548 let span = tracing::info_span!("xv_query_extension",);
20549 let _enter = span.enter();
20550 let request = types::xv::QueryExtensionRequest {};
20551 let cookie = self.send_reply_request(request);
20552 cookie
20553 }
20554 #[cfg(feature = "xv")]
20555 fn xv_query_extension_immediate(&mut self) -> Result<types::xv::QueryExtensionReply> {
20556 let request = types::xv::QueryExtensionRequest {};
20557 let cookie = self.send_reply_request(request)?;
20558 self.wait_for_reply(cookie)
20559 }
20560 #[cfg(feature = "xv")]
20561 fn xv_query_adaptors(
20562 &mut self,
20563 window: types::xproto::Window,
20564 ) -> Result<Cookie<types::xv::QueryAdaptorsReply>> {
20565 let span = tracing::info_span!(
20566 "xv_query_adaptors",
20567 window = ?window,
20568 );
20569 let _enter = span.enter();
20570 let request = types::xv::QueryAdaptorsRequest { window };
20571 let cookie = self.send_reply_request(request);
20572 cookie
20573 }
20574 #[cfg(feature = "xv")]
20575 fn xv_query_adaptors_immediate(
20576 &mut self,
20577 window: types::xproto::Window,
20578 ) -> Result<types::xv::QueryAdaptorsReply> {
20579 let request = types::xv::QueryAdaptorsRequest { window };
20580 let cookie = self.send_reply_request(request)?;
20581 self.wait_for_reply(cookie)
20582 }
20583 #[cfg(feature = "xv")]
20584 fn xv_query_encodings(
20585 &mut self,
20586 port: types::Port,
20587 ) -> Result<Cookie<types::xv::QueryEncodingsReply>> {
20588 let span = tracing::info_span!(
20589 "xv_query_encodings",
20590 port = ?port,
20591 );
20592 let _enter = span.enter();
20593 let request = types::xv::QueryEncodingsRequest { port };
20594 let cookie = self.send_reply_request(request);
20595 cookie
20596 }
20597 #[cfg(feature = "xv")]
20598 fn xv_query_encodings_immediate(
20599 &mut self,
20600 port: types::Port,
20601 ) -> Result<types::xv::QueryEncodingsReply> {
20602 let request = types::xv::QueryEncodingsRequest { port };
20603 let cookie = self.send_reply_request(request)?;
20604 self.wait_for_reply(cookie)
20605 }
20606 #[cfg(feature = "xv")]
20607 fn xv_grab_port(
20608 &mut self,
20609 port: types::Port,
20610 time: impl Into<types::Time>,
20611 ) -> Result<Cookie<types::xv::GrabPortReply>> {
20612 let span = tracing::info_span!(
20613 "xv_grab_port",
20614 port = ?port,
20615 );
20616 let _enter = span.enter();
20617 let request = types::xv::GrabPortRequest {
20618 port,
20619 time: Into::<u32>::into(time.into()) as _,
20620 };
20621 let cookie = self.send_reply_request(request);
20622 cookie
20623 }
20624 #[cfg(feature = "xv")]
20625 fn xv_grab_port_immediate(
20626 &mut self,
20627 port: types::Port,
20628 time: impl Into<types::Time>,
20629 ) -> Result<types::xv::GrabPortReply> {
20630 let request = types::xv::GrabPortRequest {
20631 port,
20632 time: Into::<u32>::into(time.into()) as _,
20633 };
20634 let cookie = self.send_reply_request(request)?;
20635 self.wait_for_reply(cookie)
20636 }
20637 #[cfg(feature = "xv")]
20638 fn xv_ungrab_port(
20639 &mut self,
20640 port: types::Port,
20641 time: impl Into<types::Time>,
20642 ) -> Result<Cookie<()>> {
20643 let span = tracing::info_span!(
20644 "xv_ungrab_port",
20645 port = ?port,
20646 );
20647 let _enter = span.enter();
20648 let request = types::xv::UngrabPortRequest {
20649 port,
20650 time: Into::<u32>::into(time.into()) as _,
20651 };
20652 let cookie = self.send_void_request(request, true);
20653 cookie
20654 }
20655 #[cfg(feature = "xv")]
20656 fn xv_ungrab_port_checked(
20657 &mut self,
20658 port: types::Port,
20659 time: impl Into<types::Time>,
20660 ) -> Result<()> {
20661 let request = types::xv::UngrabPortRequest {
20662 port,
20663 time: Into::<u32>::into(time.into()) as _,
20664 };
20665 let cookie = self.send_void_request(request, false)?;
20666 self.wait_for_reply(cookie)
20667 }
20668 #[cfg(feature = "xv")]
20669 fn xv_put_video(
20670 &mut self,
20671 port: types::Port,
20672 drawable: types::xproto::Drawable,
20673 gc: types::Gcontext,
20674 vid_x: types::Int16,
20675 vid_y: types::Int16,
20676 vid_w: types::Card16,
20677 vid_h: types::Card16,
20678 drw_x: types::Int16,
20679 drw_y: types::Int16,
20680 drw_w: types::Card16,
20681 drw_h: types::Card16,
20682 ) -> Result<Cookie<()>> {
20683 let span = tracing::info_span!(
20684 "xv_put_video",
20685 port = ?port,
20686 drawable = ?drawable,
20687 gc = ?gc,
20688 vid_x = ?vid_x,
20689 vid_y = ?vid_y,
20690 vid_w = ?vid_w,
20691 vid_h = ?vid_h,
20692 drw_x = ?drw_x,
20693 drw_y = ?drw_y,
20694 drw_w = ?drw_w,
20695 drw_h = ?drw_h,
20696 );
20697 let _enter = span.enter();
20698 let request = types::xv::PutVideoRequest {
20699 port,
20700 drawable,
20701 gc,
20702 vid_x,
20703 vid_y,
20704 vid_w,
20705 vid_h,
20706 drw_x,
20707 drw_y,
20708 drw_w,
20709 drw_h,
20710 };
20711 let cookie = self.send_void_request(request, true);
20712 cookie
20713 }
20714 #[cfg(feature = "xv")]
20715 fn xv_put_video_checked(
20716 &mut self,
20717 port: types::Port,
20718 drawable: types::xproto::Drawable,
20719 gc: types::Gcontext,
20720 vid_x: types::Int16,
20721 vid_y: types::Int16,
20722 vid_w: types::Card16,
20723 vid_h: types::Card16,
20724 drw_x: types::Int16,
20725 drw_y: types::Int16,
20726 drw_w: types::Card16,
20727 drw_h: types::Card16,
20728 ) -> Result<()> {
20729 let request = types::xv::PutVideoRequest {
20730 port,
20731 drawable,
20732 gc,
20733 vid_x,
20734 vid_y,
20735 vid_w,
20736 vid_h,
20737 drw_x,
20738 drw_y,
20739 drw_w,
20740 drw_h,
20741 };
20742 let cookie = self.send_void_request(request, false)?;
20743 self.wait_for_reply(cookie)
20744 }
20745 #[cfg(feature = "xv")]
20746 fn xv_put_still(
20747 &mut self,
20748 port: types::Port,
20749 drawable: types::xproto::Drawable,
20750 gc: types::Gcontext,
20751 vid_x: types::Int16,
20752 vid_y: types::Int16,
20753 vid_w: types::Card16,
20754 vid_h: types::Card16,
20755 drw_x: types::Int16,
20756 drw_y: types::Int16,
20757 drw_w: types::Card16,
20758 drw_h: types::Card16,
20759 ) -> Result<Cookie<()>> {
20760 let span = tracing::info_span!(
20761 "xv_put_still",
20762 port = ?port,
20763 drawable = ?drawable,
20764 gc = ?gc,
20765 vid_x = ?vid_x,
20766 vid_y = ?vid_y,
20767 vid_w = ?vid_w,
20768 vid_h = ?vid_h,
20769 drw_x = ?drw_x,
20770 drw_y = ?drw_y,
20771 drw_w = ?drw_w,
20772 drw_h = ?drw_h,
20773 );
20774 let _enter = span.enter();
20775 let request = types::xv::PutStillRequest {
20776 port,
20777 drawable,
20778 gc,
20779 vid_x,
20780 vid_y,
20781 vid_w,
20782 vid_h,
20783 drw_x,
20784 drw_y,
20785 drw_w,
20786 drw_h,
20787 };
20788 let cookie = self.send_void_request(request, true);
20789 cookie
20790 }
20791 #[cfg(feature = "xv")]
20792 fn xv_put_still_checked(
20793 &mut self,
20794 port: types::Port,
20795 drawable: types::xproto::Drawable,
20796 gc: types::Gcontext,
20797 vid_x: types::Int16,
20798 vid_y: types::Int16,
20799 vid_w: types::Card16,
20800 vid_h: types::Card16,
20801 drw_x: types::Int16,
20802 drw_y: types::Int16,
20803 drw_w: types::Card16,
20804 drw_h: types::Card16,
20805 ) -> Result<()> {
20806 let request = types::xv::PutStillRequest {
20807 port,
20808 drawable,
20809 gc,
20810 vid_x,
20811 vid_y,
20812 vid_w,
20813 vid_h,
20814 drw_x,
20815 drw_y,
20816 drw_w,
20817 drw_h,
20818 };
20819 let cookie = self.send_void_request(request, false)?;
20820 self.wait_for_reply(cookie)
20821 }
20822 #[cfg(feature = "xv")]
20823 fn xv_get_video(
20824 &mut self,
20825 port: types::Port,
20826 drawable: types::xproto::Drawable,
20827 gc: types::Gcontext,
20828 vid_x: types::Int16,
20829 vid_y: types::Int16,
20830 vid_w: types::Card16,
20831 vid_h: types::Card16,
20832 drw_x: types::Int16,
20833 drw_y: types::Int16,
20834 drw_w: types::Card16,
20835 drw_h: types::Card16,
20836 ) -> Result<Cookie<()>> {
20837 let span = tracing::info_span!(
20838 "xv_get_video",
20839 port = ?port,
20840 drawable = ?drawable,
20841 gc = ?gc,
20842 vid_x = ?vid_x,
20843 vid_y = ?vid_y,
20844 vid_w = ?vid_w,
20845 vid_h = ?vid_h,
20846 drw_x = ?drw_x,
20847 drw_y = ?drw_y,
20848 drw_w = ?drw_w,
20849 drw_h = ?drw_h,
20850 );
20851 let _enter = span.enter();
20852 let request = types::xv::GetVideoRequest {
20853 port,
20854 drawable,
20855 gc,
20856 vid_x,
20857 vid_y,
20858 vid_w,
20859 vid_h,
20860 drw_x,
20861 drw_y,
20862 drw_w,
20863 drw_h,
20864 };
20865 let cookie = self.send_void_request(request, true);
20866 cookie
20867 }
20868 #[cfg(feature = "xv")]
20869 fn xv_get_video_checked(
20870 &mut self,
20871 port: types::Port,
20872 drawable: types::xproto::Drawable,
20873 gc: types::Gcontext,
20874 vid_x: types::Int16,
20875 vid_y: types::Int16,
20876 vid_w: types::Card16,
20877 vid_h: types::Card16,
20878 drw_x: types::Int16,
20879 drw_y: types::Int16,
20880 drw_w: types::Card16,
20881 drw_h: types::Card16,
20882 ) -> Result<()> {
20883 let request = types::xv::GetVideoRequest {
20884 port,
20885 drawable,
20886 gc,
20887 vid_x,
20888 vid_y,
20889 vid_w,
20890 vid_h,
20891 drw_x,
20892 drw_y,
20893 drw_w,
20894 drw_h,
20895 };
20896 let cookie = self.send_void_request(request, false)?;
20897 self.wait_for_reply(cookie)
20898 }
20899 #[cfg(feature = "xv")]
20900 fn xv_get_still(
20901 &mut self,
20902 port: types::Port,
20903 drawable: types::xproto::Drawable,
20904 gc: types::Gcontext,
20905 vid_x: types::Int16,
20906 vid_y: types::Int16,
20907 vid_w: types::Card16,
20908 vid_h: types::Card16,
20909 drw_x: types::Int16,
20910 drw_y: types::Int16,
20911 drw_w: types::Card16,
20912 drw_h: types::Card16,
20913 ) -> Result<Cookie<()>> {
20914 let span = tracing::info_span!(
20915 "xv_get_still",
20916 port = ?port,
20917 drawable = ?drawable,
20918 gc = ?gc,
20919 vid_x = ?vid_x,
20920 vid_y = ?vid_y,
20921 vid_w = ?vid_w,
20922 vid_h = ?vid_h,
20923 drw_x = ?drw_x,
20924 drw_y = ?drw_y,
20925 drw_w = ?drw_w,
20926 drw_h = ?drw_h,
20927 );
20928 let _enter = span.enter();
20929 let request = types::xv::GetStillRequest {
20930 port,
20931 drawable,
20932 gc,
20933 vid_x,
20934 vid_y,
20935 vid_w,
20936 vid_h,
20937 drw_x,
20938 drw_y,
20939 drw_w,
20940 drw_h,
20941 };
20942 let cookie = self.send_void_request(request, true);
20943 cookie
20944 }
20945 #[cfg(feature = "xv")]
20946 fn xv_get_still_checked(
20947 &mut self,
20948 port: types::Port,
20949 drawable: types::xproto::Drawable,
20950 gc: types::Gcontext,
20951 vid_x: types::Int16,
20952 vid_y: types::Int16,
20953 vid_w: types::Card16,
20954 vid_h: types::Card16,
20955 drw_x: types::Int16,
20956 drw_y: types::Int16,
20957 drw_w: types::Card16,
20958 drw_h: types::Card16,
20959 ) -> Result<()> {
20960 let request = types::xv::GetStillRequest {
20961 port,
20962 drawable,
20963 gc,
20964 vid_x,
20965 vid_y,
20966 vid_w,
20967 vid_h,
20968 drw_x,
20969 drw_y,
20970 drw_w,
20971 drw_h,
20972 };
20973 let cookie = self.send_void_request(request, false)?;
20974 self.wait_for_reply(cookie)
20975 }
20976 #[cfg(feature = "xv")]
20977 fn xv_stop_video(
20978 &mut self,
20979 port: types::Port,
20980 drawable: types::xproto::Drawable,
20981 ) -> Result<Cookie<()>> {
20982 let span = tracing::info_span!(
20983 "xv_stop_video",
20984 port = ?port,
20985 drawable = ?drawable,
20986 );
20987 let _enter = span.enter();
20988 let request = types::xv::StopVideoRequest { port, drawable };
20989 let cookie = self.send_void_request(request, true);
20990 cookie
20991 }
20992 #[cfg(feature = "xv")]
20993 fn xv_stop_video_checked(
20994 &mut self,
20995 port: types::Port,
20996 drawable: types::xproto::Drawable,
20997 ) -> Result<()> {
20998 let request = types::xv::StopVideoRequest { port, drawable };
20999 let cookie = self.send_void_request(request, false)?;
21000 self.wait_for_reply(cookie)
21001 }
21002 #[cfg(feature = "xv")]
21003 fn xv_select_video_notify(
21004 &mut self,
21005 drawable: types::xproto::Drawable,
21006 onoff: types::Bool,
21007 ) -> Result<Cookie<()>> {
21008 let span = tracing::info_span!(
21009 "xv_select_video_notify",
21010 drawable = ?drawable,
21011 onoff = ?onoff,
21012 );
21013 let _enter = span.enter();
21014 let request = types::xv::SelectVideoNotifyRequest { drawable, onoff };
21015 let cookie = self.send_void_request(request, true);
21016 cookie
21017 }
21018 #[cfg(feature = "xv")]
21019 fn xv_select_video_notify_checked(
21020 &mut self,
21021 drawable: types::xproto::Drawable,
21022 onoff: types::Bool,
21023 ) -> Result<()> {
21024 let request = types::xv::SelectVideoNotifyRequest { drawable, onoff };
21025 let cookie = self.send_void_request(request, false)?;
21026 self.wait_for_reply(cookie)
21027 }
21028 #[cfg(feature = "xv")]
21029 fn xv_select_port_notify(
21030 &mut self,
21031 port: types::Port,
21032 onoff: types::Bool,
21033 ) -> Result<Cookie<()>> {
21034 let span = tracing::info_span!(
21035 "xv_select_port_notify",
21036 port = ?port,
21037 onoff = ?onoff,
21038 );
21039 let _enter = span.enter();
21040 let request = types::xv::SelectPortNotifyRequest { port, onoff };
21041 let cookie = self.send_void_request(request, true);
21042 cookie
21043 }
21044 #[cfg(feature = "xv")]
21045 fn xv_select_port_notify_checked(
21046 &mut self,
21047 port: types::Port,
21048 onoff: types::Bool,
21049 ) -> Result<()> {
21050 let request = types::xv::SelectPortNotifyRequest { port, onoff };
21051 let cookie = self.send_void_request(request, false)?;
21052 self.wait_for_reply(cookie)
21053 }
21054 #[cfg(feature = "xv")]
21055 fn xv_query_best_size(
21056 &mut self,
21057 port: types::Port,
21058 vid_w: types::Card16,
21059 vid_h: types::Card16,
21060 drw_w: types::Card16,
21061 drw_h: types::Card16,
21062 motion: types::Bool,
21063 ) -> Result<Cookie<types::xv::QueryBestSizeReply>> {
21064 let span = tracing::info_span!(
21065 "xv_query_best_size",
21066 port = ?port,
21067 vid_w = ?vid_w,
21068 vid_h = ?vid_h,
21069 drw_w = ?drw_w,
21070 drw_h = ?drw_h,
21071 motion = ?motion,
21072 );
21073 let _enter = span.enter();
21074 let request = types::xv::QueryBestSizeRequest {
21075 port,
21076 vid_w,
21077 vid_h,
21078 drw_w,
21079 drw_h,
21080 motion,
21081 };
21082 let cookie = self.send_reply_request(request);
21083 cookie
21084 }
21085 #[cfg(feature = "xv")]
21086 fn xv_query_best_size_immediate(
21087 &mut self,
21088 port: types::Port,
21089 vid_w: types::Card16,
21090 vid_h: types::Card16,
21091 drw_w: types::Card16,
21092 drw_h: types::Card16,
21093 motion: types::Bool,
21094 ) -> Result<types::xv::QueryBestSizeReply> {
21095 let request = types::xv::QueryBestSizeRequest {
21096 port,
21097 vid_w,
21098 vid_h,
21099 drw_w,
21100 drw_h,
21101 motion,
21102 };
21103 let cookie = self.send_reply_request(request)?;
21104 self.wait_for_reply(cookie)
21105 }
21106 #[cfg(feature = "xv")]
21107 fn xv_set_port_attribute(
21108 &mut self,
21109 port: types::Port,
21110 attribute: types::Atom,
21111 value: types::Int32,
21112 ) -> Result<Cookie<()>> {
21113 let span = tracing::info_span!(
21114 "xv_set_port_attribute",
21115 port = ?port,
21116 attribute = ?attribute,
21117 value = ?value,
21118 );
21119 let _enter = span.enter();
21120 let request = types::xv::SetPortAttributeRequest {
21121 port,
21122 attribute,
21123 value,
21124 };
21125 let cookie = self.send_void_request(request, true);
21126 cookie
21127 }
21128 #[cfg(feature = "xv")]
21129 fn xv_set_port_attribute_checked(
21130 &mut self,
21131 port: types::Port,
21132 attribute: types::Atom,
21133 value: types::Int32,
21134 ) -> Result<()> {
21135 let request = types::xv::SetPortAttributeRequest {
21136 port,
21137 attribute,
21138 value,
21139 };
21140 let cookie = self.send_void_request(request, false)?;
21141 self.wait_for_reply(cookie)
21142 }
21143 #[cfg(feature = "xv")]
21144 fn xv_get_port_attribute(
21145 &mut self,
21146 port: types::Port,
21147 attribute: types::Atom,
21148 ) -> Result<Cookie<types::xv::GetPortAttributeReply>> {
21149 let span = tracing::info_span!(
21150 "xv_get_port_attribute",
21151 port = ?port,
21152 attribute = ?attribute,
21153 );
21154 let _enter = span.enter();
21155 let request = types::xv::GetPortAttributeRequest { port, attribute };
21156 let cookie = self.send_reply_request(request);
21157 cookie
21158 }
21159 #[cfg(feature = "xv")]
21160 fn xv_get_port_attribute_immediate(
21161 &mut self,
21162 port: types::Port,
21163 attribute: types::Atom,
21164 ) -> Result<types::xv::GetPortAttributeReply> {
21165 let request = types::xv::GetPortAttributeRequest { port, attribute };
21166 let cookie = self.send_reply_request(request)?;
21167 self.wait_for_reply(cookie)
21168 }
21169 #[cfg(feature = "xv")]
21170 fn xv_query_port_attributes(
21171 &mut self,
21172 port: types::Port,
21173 ) -> Result<Cookie<types::xv::QueryPortAttributesReply>> {
21174 let span = tracing::info_span!(
21175 "xv_query_port_attributes",
21176 port = ?port,
21177 );
21178 let _enter = span.enter();
21179 let request = types::xv::QueryPortAttributesRequest { port };
21180 let cookie = self.send_reply_request(request);
21181 cookie
21182 }
21183 #[cfg(feature = "xv")]
21184 fn xv_query_port_attributes_immediate(
21185 &mut self,
21186 port: types::Port,
21187 ) -> Result<types::xv::QueryPortAttributesReply> {
21188 let request = types::xv::QueryPortAttributesRequest { port };
21189 let cookie = self.send_reply_request(request)?;
21190 self.wait_for_reply(cookie)
21191 }
21192 #[cfg(feature = "xv")]
21193 fn xv_list_image_formats(
21194 &mut self,
21195 port: types::Port,
21196 ) -> Result<Cookie<types::xv::ListImageFormatsReply>> {
21197 let span = tracing::info_span!(
21198 "xv_list_image_formats",
21199 port = ?port,
21200 );
21201 let _enter = span.enter();
21202 let request = types::xv::ListImageFormatsRequest { port };
21203 let cookie = self.send_reply_request(request);
21204 cookie
21205 }
21206 #[cfg(feature = "xv")]
21207 fn xv_list_image_formats_immediate(
21208 &mut self,
21209 port: types::Port,
21210 ) -> Result<types::xv::ListImageFormatsReply> {
21211 let request = types::xv::ListImageFormatsRequest { port };
21212 let cookie = self.send_reply_request(request)?;
21213 self.wait_for_reply(cookie)
21214 }
21215 #[cfg(feature = "xv")]
21216 fn xv_query_image_attributes(
21217 &mut self,
21218 port: types::Port,
21219 id: types::Card32,
21220 width: types::Card16,
21221 height: types::Card16,
21222 ) -> Result<Cookie<types::xv::QueryImageAttributesReply>> {
21223 let span = tracing::info_span!(
21224 "xv_query_image_attributes",
21225 port = ?port,
21226 id = ?id,
21227 width = ?width,
21228 height = ?height,
21229 );
21230 let _enter = span.enter();
21231 let request = types::xv::QueryImageAttributesRequest {
21232 port,
21233 id,
21234 width,
21235 height,
21236 };
21237 let cookie = self.send_reply_request(request);
21238 cookie
21239 }
21240 #[cfg(feature = "xv")]
21241 fn xv_query_image_attributes_immediate(
21242 &mut self,
21243 port: types::Port,
21244 id: types::Card32,
21245 width: types::Card16,
21246 height: types::Card16,
21247 ) -> Result<types::xv::QueryImageAttributesReply> {
21248 let request = types::xv::QueryImageAttributesRequest {
21249 port,
21250 id,
21251 width,
21252 height,
21253 };
21254 let cookie = self.send_reply_request(request)?;
21255 self.wait_for_reply(cookie)
21256 }
21257 #[cfg(feature = "xv")]
21258 fn xv_put_image(
21259 &mut self,
21260 port: types::Port,
21261 drawable: types::xproto::Drawable,
21262 gc: types::Gcontext,
21263 id: types::Card32,
21264 src_x: types::Int16,
21265 src_y: types::Int16,
21266 src_w: types::Card16,
21267 src_h: types::Card16,
21268 drw_x: types::Int16,
21269 drw_y: types::Int16,
21270 drw_w: types::Card16,
21271 drw_h: types::Card16,
21272 width: types::Card16,
21273 height: types::Card16,
21274 data: impl AsRef<[types::Card8]>,
21275 ) -> Result<Cookie<()>> {
21276 let span = tracing::info_span!(
21277 "xv_put_image",
21278 port = ?port,
21279 drawable = ?drawable,
21280 gc = ?gc,
21281 id = ?id,
21282 src_x = ?src_x,
21283 src_y = ?src_y,
21284 src_w = ?src_w,
21285 src_h = ?src_h,
21286 drw_x = ?drw_x,
21287 drw_y = ?drw_y,
21288 drw_w = ?drw_w,
21289 drw_h = ?drw_h,
21290 width = ?width,
21291 height = ?height,
21292 );
21293 let _enter = span.enter();
21294 let request = types::xv::PutImageRequest {
21295 port,
21296 drawable,
21297 gc,
21298 id,
21299 src_x,
21300 src_y,
21301 src_w,
21302 src_h,
21303 drw_x,
21304 drw_y,
21305 drw_w,
21306 drw_h,
21307 width,
21308 height,
21309 data: Cow::Borrowed(data.as_ref()),
21310 };
21311 let cookie = self.send_void_request(request, true);
21312 cookie
21313 }
21314 #[cfg(feature = "xv")]
21315 fn xv_put_image_checked(
21316 &mut self,
21317 port: types::Port,
21318 drawable: types::xproto::Drawable,
21319 gc: types::Gcontext,
21320 id: types::Card32,
21321 src_x: types::Int16,
21322 src_y: types::Int16,
21323 src_w: types::Card16,
21324 src_h: types::Card16,
21325 drw_x: types::Int16,
21326 drw_y: types::Int16,
21327 drw_w: types::Card16,
21328 drw_h: types::Card16,
21329 width: types::Card16,
21330 height: types::Card16,
21331 data: impl AsRef<[types::Card8]>,
21332 ) -> Result<()> {
21333 let request = types::xv::PutImageRequest {
21334 port,
21335 drawable,
21336 gc,
21337 id,
21338 src_x,
21339 src_y,
21340 src_w,
21341 src_h,
21342 drw_x,
21343 drw_y,
21344 drw_w,
21345 drw_h,
21346 width,
21347 height,
21348 data: Cow::Borrowed(data.as_ref()),
21349 };
21350 let cookie = self.send_void_request(request, false)?;
21351 self.wait_for_reply(cookie)
21352 }
21353 #[cfg(feature = "xv")]
21354 fn xv_shm_put_image(
21355 &mut self,
21356 port: types::Port,
21357 drawable: types::xproto::Drawable,
21358 gc: types::Gcontext,
21359 shmseg: types::Seg,
21360 id: types::Card32,
21361 offset: types::Card32,
21362 src_x: types::Int16,
21363 src_y: types::Int16,
21364 src_w: types::Card16,
21365 src_h: types::Card16,
21366 drw_x: types::Int16,
21367 drw_y: types::Int16,
21368 drw_w: types::Card16,
21369 drw_h: types::Card16,
21370 width: types::Card16,
21371 height: types::Card16,
21372 send_event: types::Card8,
21373 ) -> Result<Cookie<()>> {
21374 let span = tracing::info_span!(
21375 "xv_shm_put_image",
21376 port = ?port,
21377 drawable = ?drawable,
21378 gc = ?gc,
21379 shmseg = ?shmseg,
21380 id = ?id,
21381 offset = ?offset,
21382 src_x = ?src_x,
21383 src_y = ?src_y,
21384 src_w = ?src_w,
21385 src_h = ?src_h,
21386 drw_x = ?drw_x,
21387 drw_y = ?drw_y,
21388 drw_w = ?drw_w,
21389 drw_h = ?drw_h,
21390 width = ?width,
21391 height = ?height,
21392 send_event = ?send_event,
21393 );
21394 let _enter = span.enter();
21395 let request = types::xv::ShmPutImageRequest {
21396 port,
21397 drawable,
21398 gc,
21399 shmseg,
21400 id,
21401 offset,
21402 src_x,
21403 src_y,
21404 src_w,
21405 src_h,
21406 drw_x,
21407 drw_y,
21408 drw_w,
21409 drw_h,
21410 width,
21411 height,
21412 send_event,
21413 };
21414 let cookie = self.send_void_request(request, true);
21415 cookie
21416 }
21417 #[cfg(feature = "xv")]
21418 fn xv_shm_put_image_checked(
21419 &mut self,
21420 port: types::Port,
21421 drawable: types::xproto::Drawable,
21422 gc: types::Gcontext,
21423 shmseg: types::Seg,
21424 id: types::Card32,
21425 offset: types::Card32,
21426 src_x: types::Int16,
21427 src_y: types::Int16,
21428 src_w: types::Card16,
21429 src_h: types::Card16,
21430 drw_x: types::Int16,
21431 drw_y: types::Int16,
21432 drw_w: types::Card16,
21433 drw_h: types::Card16,
21434 width: types::Card16,
21435 height: types::Card16,
21436 send_event: types::Card8,
21437 ) -> Result<()> {
21438 let request = types::xv::ShmPutImageRequest {
21439 port,
21440 drawable,
21441 gc,
21442 shmseg,
21443 id,
21444 offset,
21445 src_x,
21446 src_y,
21447 src_w,
21448 src_h,
21449 drw_x,
21450 drw_y,
21451 drw_w,
21452 drw_h,
21453 width,
21454 height,
21455 send_event,
21456 };
21457 let cookie = self.send_void_request(request, false)?;
21458 self.wait_for_reply(cookie)
21459 }
21460
21461 #[cfg(feature = "xvmc")]
21462 fn xvmc_query_version(&mut self) -> Result<Cookie<types::xvmc::QueryVersionReply>> {
21463 let span = tracing::info_span!("xvmc_query_version",);
21464 let _enter = span.enter();
21465 let request = types::xvmc::QueryVersionRequest {};
21466 let cookie = self.send_reply_request(request);
21467 cookie
21468 }
21469 #[cfg(feature = "xvmc")]
21470 fn xvmc_query_version_immediate(&mut self) -> Result<types::xvmc::QueryVersionReply> {
21471 let request = types::xvmc::QueryVersionRequest {};
21472 let cookie = self.send_reply_request(request)?;
21473 self.wait_for_reply(cookie)
21474 }
21475 #[cfg(feature = "xvmc")]
21476 fn xvmc_list_surface_types(
21477 &mut self,
21478 port_id: types::Port,
21479 ) -> Result<Cookie<types::xvmc::ListSurfaceTypesReply>> {
21480 let span = tracing::info_span!(
21481 "xvmc_list_surface_types",
21482 port_id = ?port_id,
21483 );
21484 let _enter = span.enter();
21485 let request = types::xvmc::ListSurfaceTypesRequest { port_id };
21486 let cookie = self.send_reply_request(request);
21487 cookie
21488 }
21489 #[cfg(feature = "xvmc")]
21490 fn xvmc_list_surface_types_immediate(
21491 &mut self,
21492 port_id: types::Port,
21493 ) -> Result<types::xvmc::ListSurfaceTypesReply> {
21494 let request = types::xvmc::ListSurfaceTypesRequest { port_id };
21495 let cookie = self.send_reply_request(request)?;
21496 self.wait_for_reply(cookie)
21497 }
21498 #[cfg(feature = "xvmc")]
21499 fn xvmc_create_context(
21500 &mut self,
21501 context_id: types::xvmc::Context,
21502 port_id: types::Port,
21503 surface_id: types::Surface,
21504 width: types::Card16,
21505 height: types::Card16,
21506 flags: types::Card32,
21507 ) -> Result<Cookie<types::xvmc::CreateContextReply>> {
21508 let span = tracing::info_span!(
21509 "xvmc_create_context",
21510 context_id = ?context_id,
21511 port_id = ?port_id,
21512 surface_id = ?surface_id,
21513 width = ?width,
21514 height = ?height,
21515 flags = ?flags,
21516 );
21517 let _enter = span.enter();
21518 let request = types::xvmc::CreateContextRequest {
21519 context_id,
21520 port_id,
21521 surface_id,
21522 width,
21523 height,
21524 flags,
21525 };
21526 let cookie = self.send_reply_request(request);
21527 cookie
21528 }
21529 #[cfg(feature = "xvmc")]
21530 fn xvmc_create_context_immediate(
21531 &mut self,
21532 context_id: types::xvmc::Context,
21533 port_id: types::Port,
21534 surface_id: types::Surface,
21535 width: types::Card16,
21536 height: types::Card16,
21537 flags: types::Card32,
21538 ) -> Result<types::xvmc::CreateContextReply> {
21539 let request = types::xvmc::CreateContextRequest {
21540 context_id,
21541 port_id,
21542 surface_id,
21543 width,
21544 height,
21545 flags,
21546 };
21547 let cookie = self.send_reply_request(request)?;
21548 self.wait_for_reply(cookie)
21549 }
21550 #[cfg(feature = "xvmc")]
21551 fn xvmc_destroy_context(&mut self, context_id: types::xvmc::Context) -> Result<Cookie<()>> {
21552 let span = tracing::info_span!(
21553 "xvmc_destroy_context",
21554 context_id = ?context_id,
21555 );
21556 let _enter = span.enter();
21557 let request = types::xvmc::DestroyContextRequest { context_id };
21558 let cookie = self.send_void_request(request, true);
21559 cookie
21560 }
21561 #[cfg(feature = "xvmc")]
21562 fn xvmc_destroy_context_checked(&mut self, context_id: types::xvmc::Context) -> Result<()> {
21563 let request = types::xvmc::DestroyContextRequest { context_id };
21564 let cookie = self.send_void_request(request, false)?;
21565 self.wait_for_reply(cookie)
21566 }
21567 #[cfg(feature = "xvmc")]
21568 fn xvmc_create_surface(
21569 &mut self,
21570 surface_id: types::Surface,
21571 context_id: types::xvmc::Context,
21572 ) -> Result<Cookie<types::xvmc::CreateSurfaceReply>> {
21573 let span = tracing::info_span!(
21574 "xvmc_create_surface",
21575 surface_id = ?surface_id,
21576 context_id = ?context_id,
21577 );
21578 let _enter = span.enter();
21579 let request = types::xvmc::CreateSurfaceRequest {
21580 surface_id,
21581 context_id,
21582 };
21583 let cookie = self.send_reply_request(request);
21584 cookie
21585 }
21586 #[cfg(feature = "xvmc")]
21587 fn xvmc_create_surface_immediate(
21588 &mut self,
21589 surface_id: types::Surface,
21590 context_id: types::xvmc::Context,
21591 ) -> Result<types::xvmc::CreateSurfaceReply> {
21592 let request = types::xvmc::CreateSurfaceRequest {
21593 surface_id,
21594 context_id,
21595 };
21596 let cookie = self.send_reply_request(request)?;
21597 self.wait_for_reply(cookie)
21598 }
21599 #[cfg(feature = "xvmc")]
21600 fn xvmc_destroy_surface(&mut self, surface_id: types::Surface) -> Result<Cookie<()>> {
21601 let span = tracing::info_span!(
21602 "xvmc_destroy_surface",
21603 surface_id = ?surface_id,
21604 );
21605 let _enter = span.enter();
21606 let request = types::xvmc::DestroySurfaceRequest { surface_id };
21607 let cookie = self.send_void_request(request, true);
21608 cookie
21609 }
21610 #[cfg(feature = "xvmc")]
21611 fn xvmc_destroy_surface_checked(&mut self, surface_id: types::Surface) -> Result<()> {
21612 let request = types::xvmc::DestroySurfaceRequest { surface_id };
21613 let cookie = self.send_void_request(request, false)?;
21614 self.wait_for_reply(cookie)
21615 }
21616 #[cfg(feature = "xvmc")]
21617 fn xvmc_create_subpicture(
21618 &mut self,
21619 subpicture_id: types::Subpicture,
21620 context: types::xvmc::Context,
21621 xvimage_id: types::Card32,
21622 width: types::Card16,
21623 height: types::Card16,
21624 ) -> Result<Cookie<types::xvmc::CreateSubpictureReply>> {
21625 let span = tracing::info_span!(
21626 "xvmc_create_subpicture",
21627 subpicture_id = ?subpicture_id,
21628 context = ?context,
21629 xvimage_id = ?xvimage_id,
21630 width = ?width,
21631 height = ?height,
21632 );
21633 let _enter = span.enter();
21634 let request = types::xvmc::CreateSubpictureRequest {
21635 subpicture_id,
21636 context,
21637 xvimage_id,
21638 width,
21639 height,
21640 };
21641 let cookie = self.send_reply_request(request);
21642 cookie
21643 }
21644 #[cfg(feature = "xvmc")]
21645 fn xvmc_create_subpicture_immediate(
21646 &mut self,
21647 subpicture_id: types::Subpicture,
21648 context: types::xvmc::Context,
21649 xvimage_id: types::Card32,
21650 width: types::Card16,
21651 height: types::Card16,
21652 ) -> Result<types::xvmc::CreateSubpictureReply> {
21653 let request = types::xvmc::CreateSubpictureRequest {
21654 subpicture_id,
21655 context,
21656 xvimage_id,
21657 width,
21658 height,
21659 };
21660 let cookie = self.send_reply_request(request)?;
21661 self.wait_for_reply(cookie)
21662 }
21663 #[cfg(feature = "xvmc")]
21664 fn xvmc_destroy_subpicture(&mut self, subpicture_id: types::Subpicture) -> Result<Cookie<()>> {
21665 let span = tracing::info_span!(
21666 "xvmc_destroy_subpicture",
21667 subpicture_id = ?subpicture_id,
21668 );
21669 let _enter = span.enter();
21670 let request = types::xvmc::DestroySubpictureRequest { subpicture_id };
21671 let cookie = self.send_void_request(request, true);
21672 cookie
21673 }
21674 #[cfg(feature = "xvmc")]
21675 fn xvmc_destroy_subpicture_checked(&mut self, subpicture_id: types::Subpicture) -> Result<()> {
21676 let request = types::xvmc::DestroySubpictureRequest { subpicture_id };
21677 let cookie = self.send_void_request(request, false)?;
21678 self.wait_for_reply(cookie)
21679 }
21680 #[cfg(feature = "xvmc")]
21681 fn xvmc_list_subpicture_types(
21682 &mut self,
21683 port_id: types::Port,
21684 surface_id: types::Surface,
21685 ) -> Result<Cookie<types::xvmc::ListSubpictureTypesReply>> {
21686 let span = tracing::info_span!(
21687 "xvmc_list_subpicture_types",
21688 port_id = ?port_id,
21689 surface_id = ?surface_id,
21690 );
21691 let _enter = span.enter();
21692 let request = types::xvmc::ListSubpictureTypesRequest {
21693 port_id,
21694 surface_id,
21695 };
21696 let cookie = self.send_reply_request(request);
21697 cookie
21698 }
21699 #[cfg(feature = "xvmc")]
21700 fn xvmc_list_subpicture_types_immediate(
21701 &mut self,
21702 port_id: types::Port,
21703 surface_id: types::Surface,
21704 ) -> Result<types::xvmc::ListSubpictureTypesReply> {
21705 let request = types::xvmc::ListSubpictureTypesRequest {
21706 port_id,
21707 surface_id,
21708 };
21709 let cookie = self.send_reply_request(request)?;
21710 self.wait_for_reply(cookie)
21711 }
21712}
21713
21714#[cfg(feature = "async")]
21715pub trait AsyncDisplayFunctionsExt: AsyncDisplay + Sealed2 {
21716 fn bigreq_enable<'this>(
21717 &'this mut self,
21718 ) -> futures::SendRequest<'this, Self, types::bigreq::EnableReply> {
21719 let span = tracing::info_span!("bigreq_enable",);
21720 let request = types::bigreq::EnableRequest {};
21721 let cookie = self.send_reply_request(request).with_span(span);
21722 cookie
21723 }
21724 fn bigreq_enable_immediate<'this>(
21725 &'this mut self,
21726 ) -> futures::CheckedSendRequest<'this, Self, types::bigreq::EnableReply> {
21727 let request = types::bigreq::EnableRequest {};
21728 let cookie = self.send_reply_request(request);
21729 let res: futures::CheckedSendRequest<'this, Self, types::bigreq::EnableReply> =
21730 cookie.into();
21731 res
21732 }
21733
21734 #[cfg(feature = "composite")]
21735 fn composite_query_version<'this>(
21736 &'this mut self,
21737 client_major_version: types::Card32,
21738 client_minor_version: types::Card32,
21739 ) -> futures::SendRequest<'this, Self, types::composite::QueryVersionReply> {
21740 let span = tracing::info_span!(
21741 "composite_query_version",
21742 client_major_version = ?client_major_version,
21743 client_minor_version = ?client_minor_version,
21744 );
21745 let request = types::composite::QueryVersionRequest {
21746 client_major_version,
21747 client_minor_version,
21748 };
21749 let cookie = self.send_reply_request(request).with_span(span);
21750 cookie
21751 }
21752 #[cfg(feature = "composite")]
21753 fn composite_query_version_immediate<'this>(
21754 &'this mut self,
21755 client_major_version: types::Card32,
21756 client_minor_version: types::Card32,
21757 ) -> futures::CheckedSendRequest<'this, Self, types::composite::QueryVersionReply> {
21758 let request = types::composite::QueryVersionRequest {
21759 client_major_version,
21760 client_minor_version,
21761 };
21762 let cookie = self.send_reply_request(request);
21763 let res: futures::CheckedSendRequest<'this, Self, types::composite::QueryVersionReply> =
21764 cookie.into();
21765 res
21766 }
21767 #[cfg(feature = "composite")]
21768 fn composite_redirect_window<'this>(
21769 &'this mut self,
21770 window: types::xproto::Window,
21771 update: types::Redirect,
21772 ) -> futures::SendRequest<'this, Self, ()> {
21773 let span = tracing::info_span!(
21774 "composite_redirect_window",
21775 window = ?window,
21776 update = ?update,
21777 );
21778 let request = types::composite::RedirectWindowRequest { window, update };
21779 let cookie = self.send_void_request(request, true).with_span(span);
21780 cookie
21781 }
21782 #[cfg(feature = "composite")]
21783 fn composite_redirect_window_checked<'this>(
21784 &'this mut self,
21785 window: types::xproto::Window,
21786 update: types::Redirect,
21787 ) -> futures::CheckedSendRequest<'this, Self, ()> {
21788 let request = types::composite::RedirectWindowRequest { window, update };
21789 let cookie = self.send_void_request(request, false);
21790 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
21791 res
21792 }
21793 #[cfg(feature = "composite")]
21794 fn composite_redirect_subwindows<'this>(
21795 &'this mut self,
21796 window: types::xproto::Window,
21797 update: types::Redirect,
21798 ) -> futures::SendRequest<'this, Self, ()> {
21799 let span = tracing::info_span!(
21800 "composite_redirect_subwindows",
21801 window = ?window,
21802 update = ?update,
21803 );
21804 let request = types::composite::RedirectSubwindowsRequest { window, update };
21805 let cookie = self.send_void_request(request, true).with_span(span);
21806 cookie
21807 }
21808 #[cfg(feature = "composite")]
21809 fn composite_redirect_subwindows_checked<'this>(
21810 &'this mut self,
21811 window: types::xproto::Window,
21812 update: types::Redirect,
21813 ) -> futures::CheckedSendRequest<'this, Self, ()> {
21814 let request = types::composite::RedirectSubwindowsRequest { window, update };
21815 let cookie = self.send_void_request(request, false);
21816 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
21817 res
21818 }
21819 #[cfg(feature = "composite")]
21820 fn composite_unredirect_window<'this>(
21821 &'this mut self,
21822 window: types::xproto::Window,
21823 update: types::Redirect,
21824 ) -> futures::SendRequest<'this, Self, ()> {
21825 let span = tracing::info_span!(
21826 "composite_unredirect_window",
21827 window = ?window,
21828 update = ?update,
21829 );
21830 let request = types::composite::UnredirectWindowRequest { window, update };
21831 let cookie = self.send_void_request(request, true).with_span(span);
21832 cookie
21833 }
21834 #[cfg(feature = "composite")]
21835 fn composite_unredirect_window_checked<'this>(
21836 &'this mut self,
21837 window: types::xproto::Window,
21838 update: types::Redirect,
21839 ) -> futures::CheckedSendRequest<'this, Self, ()> {
21840 let request = types::composite::UnredirectWindowRequest { window, update };
21841 let cookie = self.send_void_request(request, false);
21842 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
21843 res
21844 }
21845 #[cfg(feature = "composite")]
21846 fn composite_unredirect_subwindows<'this>(
21847 &'this mut self,
21848 window: types::xproto::Window,
21849 update: types::Redirect,
21850 ) -> futures::SendRequest<'this, Self, ()> {
21851 let span = tracing::info_span!(
21852 "composite_unredirect_subwindows",
21853 window = ?window,
21854 update = ?update,
21855 );
21856 let request = types::composite::UnredirectSubwindowsRequest { window, update };
21857 let cookie = self.send_void_request(request, true).with_span(span);
21858 cookie
21859 }
21860 #[cfg(feature = "composite")]
21861 fn composite_unredirect_subwindows_checked<'this>(
21862 &'this mut self,
21863 window: types::xproto::Window,
21864 update: types::Redirect,
21865 ) -> futures::CheckedSendRequest<'this, Self, ()> {
21866 let request = types::composite::UnredirectSubwindowsRequest { window, update };
21867 let cookie = self.send_void_request(request, false);
21868 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
21869 res
21870 }
21871 #[cfg(feature = "composite")]
21872 fn composite_create_region_from_border_clip<'this>(
21873 &'this mut self,
21874 region: types::Region,
21875 window: types::xproto::Window,
21876 ) -> futures::SendRequest<'this, Self, ()> {
21877 let span = tracing::info_span!(
21878 "composite_create_region_from_border_clip",
21879 region = ?region,
21880 window = ?window,
21881 );
21882 let request = types::composite::CreateRegionFromBorderClipRequest { region, window };
21883 let cookie = self.send_void_request(request, true).with_span(span);
21884 cookie
21885 }
21886 #[cfg(feature = "composite")]
21887 fn composite_create_region_from_border_clip_checked<'this>(
21888 &'this mut self,
21889 region: types::Region,
21890 window: types::xproto::Window,
21891 ) -> futures::CheckedSendRequest<'this, Self, ()> {
21892 let request = types::composite::CreateRegionFromBorderClipRequest { region, window };
21893 let cookie = self.send_void_request(request, false);
21894 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
21895 res
21896 }
21897 #[cfg(feature = "composite")]
21898 fn composite_name_window_pixmap<'this>(
21899 &'this mut self,
21900 window: types::xproto::Window,
21901 pixmap: types::xproto::Pixmap,
21902 ) -> futures::SendRequest<'this, Self, ()> {
21903 let span = tracing::info_span!(
21904 "composite_name_window_pixmap",
21905 window = ?window,
21906 pixmap = ?pixmap,
21907 );
21908 let request = types::composite::NameWindowPixmapRequest { window, pixmap };
21909 let cookie = self.send_void_request(request, true).with_span(span);
21910 cookie
21911 }
21912 #[cfg(feature = "composite")]
21913 fn composite_name_window_pixmap_checked<'this>(
21914 &'this mut self,
21915 window: types::xproto::Window,
21916 pixmap: types::xproto::Pixmap,
21917 ) -> futures::CheckedSendRequest<'this, Self, ()> {
21918 let request = types::composite::NameWindowPixmapRequest { window, pixmap };
21919 let cookie = self.send_void_request(request, false);
21920 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
21921 res
21922 }
21923 #[cfg(feature = "composite")]
21924 fn composite_get_overlay_window<'this>(
21925 &'this mut self,
21926 window: types::xproto::Window,
21927 ) -> futures::SendRequest<'this, Self, types::composite::GetOverlayWindowReply> {
21928 let span = tracing::info_span!(
21929 "composite_get_overlay_window",
21930 window = ?window,
21931 );
21932 let request = types::composite::GetOverlayWindowRequest { window };
21933 let cookie = self.send_reply_request(request).with_span(span);
21934 cookie
21935 }
21936 #[cfg(feature = "composite")]
21937 fn composite_get_overlay_window_immediate<'this>(
21938 &'this mut self,
21939 window: types::xproto::Window,
21940 ) -> futures::CheckedSendRequest<'this, Self, types::composite::GetOverlayWindowReply> {
21941 let request = types::composite::GetOverlayWindowRequest { window };
21942 let cookie = self.send_reply_request(request);
21943 let res: futures::CheckedSendRequest<'this, Self, types::composite::GetOverlayWindowReply> =
21944 cookie.into();
21945 res
21946 }
21947 #[cfg(feature = "composite")]
21948 fn composite_release_overlay_window<'this>(
21949 &'this mut self,
21950 window: types::xproto::Window,
21951 ) -> futures::SendRequest<'this, Self, ()> {
21952 let span = tracing::info_span!(
21953 "composite_release_overlay_window",
21954 window = ?window,
21955 );
21956 let request = types::composite::ReleaseOverlayWindowRequest { window };
21957 let cookie = self.send_void_request(request, true).with_span(span);
21958 cookie
21959 }
21960 #[cfg(feature = "composite")]
21961 fn composite_release_overlay_window_checked<'this>(
21962 &'this mut self,
21963 window: types::xproto::Window,
21964 ) -> futures::CheckedSendRequest<'this, Self, ()> {
21965 let request = types::composite::ReleaseOverlayWindowRequest { window };
21966 let cookie = self.send_void_request(request, false);
21967 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
21968 res
21969 }
21970
21971 #[cfg(feature = "damage")]
21972 fn damage_query_version<'this>(
21973 &'this mut self,
21974 client_major_version: types::Card32,
21975 client_minor_version: types::Card32,
21976 ) -> futures::SendRequest<'this, Self, types::damage::QueryVersionReply> {
21977 let span = tracing::info_span!(
21978 "damage_query_version",
21979 client_major_version = ?client_major_version,
21980 client_minor_version = ?client_minor_version,
21981 );
21982 let request = types::damage::QueryVersionRequest {
21983 client_major_version,
21984 client_minor_version,
21985 };
21986 let cookie = self.send_reply_request(request).with_span(span);
21987 cookie
21988 }
21989 #[cfg(feature = "damage")]
21990 fn damage_query_version_immediate<'this>(
21991 &'this mut self,
21992 client_major_version: types::Card32,
21993 client_minor_version: types::Card32,
21994 ) -> futures::CheckedSendRequest<'this, Self, types::damage::QueryVersionReply> {
21995 let request = types::damage::QueryVersionRequest {
21996 client_major_version,
21997 client_minor_version,
21998 };
21999 let cookie = self.send_reply_request(request);
22000 let res: futures::CheckedSendRequest<'this, Self, types::damage::QueryVersionReply> =
22001 cookie.into();
22002 res
22003 }
22004 #[cfg(feature = "damage")]
22005 fn damage_create<'this>(
22006 &'this mut self,
22007 damage: types::Damage,
22008 drawable: types::xproto::Drawable,
22009 level: types::ReportLevel,
22010 ) -> futures::SendRequest<'this, Self, ()> {
22011 let span = tracing::info_span!(
22012 "damage_create",
22013 damage = ?damage,
22014 drawable = ?drawable,
22015 level = ?level,
22016 );
22017 let request = types::damage::CreateRequest {
22018 damage,
22019 drawable,
22020 level,
22021 };
22022 let cookie = self.send_void_request(request, true).with_span(span);
22023 cookie
22024 }
22025 #[cfg(feature = "damage")]
22026 fn damage_create_checked<'this>(
22027 &'this mut self,
22028 damage: types::Damage,
22029 drawable: types::xproto::Drawable,
22030 level: types::ReportLevel,
22031 ) -> futures::CheckedSendRequest<'this, Self, ()> {
22032 let request = types::damage::CreateRequest {
22033 damage,
22034 drawable,
22035 level,
22036 };
22037 let cookie = self.send_void_request(request, false);
22038 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
22039 res
22040 }
22041 #[cfg(feature = "damage")]
22042 fn damage_destroy<'this>(
22043 &'this mut self,
22044 damage: types::Damage,
22045 ) -> futures::SendRequest<'this, Self, ()> {
22046 let span = tracing::info_span!(
22047 "damage_destroy",
22048 damage = ?damage,
22049 );
22050 let request = types::damage::DestroyRequest { damage };
22051 let cookie = self.send_void_request(request, true).with_span(span);
22052 cookie
22053 }
22054 #[cfg(feature = "damage")]
22055 fn damage_destroy_checked<'this>(
22056 &'this mut self,
22057 damage: types::Damage,
22058 ) -> futures::CheckedSendRequest<'this, Self, ()> {
22059 let request = types::damage::DestroyRequest { damage };
22060 let cookie = self.send_void_request(request, false);
22061 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
22062 res
22063 }
22064 #[cfg(feature = "damage")]
22065 fn damage_subtract<'this>(
22066 &'this mut self,
22067 damage: types::Damage,
22068 repair: impl Into<types::Region>,
22069 parts: impl Into<types::Region>,
22070 ) -> futures::SendRequest<'this, Self, ()> {
22071 let span = tracing::info_span!(
22072 "damage_subtract",
22073 damage = ?damage,
22074 );
22075 let request = types::damage::SubtractRequest {
22076 damage,
22077 repair: Into::<u32>::into(repair.into()) as _,
22078 parts: Into::<u32>::into(parts.into()) as _,
22079 };
22080 let cookie = self.send_void_request(request, true).with_span(span);
22081 cookie
22082 }
22083 #[cfg(feature = "damage")]
22084 fn damage_subtract_checked<'this>(
22085 &'this mut self,
22086 damage: types::Damage,
22087 repair: impl Into<types::Region>,
22088 parts: impl Into<types::Region>,
22089 ) -> futures::CheckedSendRequest<'this, Self, ()> {
22090 let request = types::damage::SubtractRequest {
22091 damage,
22092 repair: Into::<u32>::into(repair.into()) as _,
22093 parts: Into::<u32>::into(parts.into()) as _,
22094 };
22095 let cookie = self.send_void_request(request, false);
22096 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
22097 res
22098 }
22099 #[cfg(feature = "damage")]
22100 fn damage_add<'this>(
22101 &'this mut self,
22102 drawable: types::xproto::Drawable,
22103 region: types::Region,
22104 ) -> futures::SendRequest<'this, Self, ()> {
22105 let span = tracing::info_span!(
22106 "damage_add",
22107 drawable = ?drawable,
22108 region = ?region,
22109 );
22110 let request = types::damage::AddRequest { drawable, region };
22111 let cookie = self.send_void_request(request, true).with_span(span);
22112 cookie
22113 }
22114 #[cfg(feature = "damage")]
22115 fn damage_add_checked<'this>(
22116 &'this mut self,
22117 drawable: types::xproto::Drawable,
22118 region: types::Region,
22119 ) -> futures::CheckedSendRequest<'this, Self, ()> {
22120 let request = types::damage::AddRequest { drawable, region };
22121 let cookie = self.send_void_request(request, false);
22122 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
22123 res
22124 }
22125
22126 #[cfg(feature = "dpms")]
22127 fn dpms_get_version<'this>(
22128 &'this mut self,
22129 client_major_version: types::Card16,
22130 client_minor_version: types::Card16,
22131 ) -> futures::SendRequest<'this, Self, types::dpms::GetVersionReply> {
22132 let span = tracing::info_span!(
22133 "dpms_get_version",
22134 client_major_version = ?client_major_version,
22135 client_minor_version = ?client_minor_version,
22136 );
22137 let request = types::dpms::GetVersionRequest {
22138 client_major_version,
22139 client_minor_version,
22140 };
22141 let cookie = self.send_reply_request(request).with_span(span);
22142 cookie
22143 }
22144 #[cfg(feature = "dpms")]
22145 fn dpms_get_version_immediate<'this>(
22146 &'this mut self,
22147 client_major_version: types::Card16,
22148 client_minor_version: types::Card16,
22149 ) -> futures::CheckedSendRequest<'this, Self, types::dpms::GetVersionReply> {
22150 let request = types::dpms::GetVersionRequest {
22151 client_major_version,
22152 client_minor_version,
22153 };
22154 let cookie = self.send_reply_request(request);
22155 let res: futures::CheckedSendRequest<'this, Self, types::dpms::GetVersionReply> =
22156 cookie.into();
22157 res
22158 }
22159 #[cfg(feature = "dpms")]
22160 fn dpms_capable<'this>(
22161 &'this mut self,
22162 ) -> futures::SendRequest<'this, Self, types::dpms::CapableReply> {
22163 let span = tracing::info_span!("dpms_capable",);
22164 let request = types::dpms::CapableRequest {};
22165 let cookie = self.send_reply_request(request).with_span(span);
22166 cookie
22167 }
22168 #[cfg(feature = "dpms")]
22169 fn dpms_capable_immediate<'this>(
22170 &'this mut self,
22171 ) -> futures::CheckedSendRequest<'this, Self, types::dpms::CapableReply> {
22172 let request = types::dpms::CapableRequest {};
22173 let cookie = self.send_reply_request(request);
22174 let res: futures::CheckedSendRequest<'this, Self, types::dpms::CapableReply> =
22175 cookie.into();
22176 res
22177 }
22178 #[cfg(feature = "dpms")]
22179 fn dpms_get_timeouts<'this>(
22180 &'this mut self,
22181 ) -> futures::SendRequest<'this, Self, types::dpms::GetTimeoutsReply> {
22182 let span = tracing::info_span!("dpms_get_timeouts",);
22183 let request = types::dpms::GetTimeoutsRequest {};
22184 let cookie = self.send_reply_request(request).with_span(span);
22185 cookie
22186 }
22187 #[cfg(feature = "dpms")]
22188 fn dpms_get_timeouts_immediate<'this>(
22189 &'this mut self,
22190 ) -> futures::CheckedSendRequest<'this, Self, types::dpms::GetTimeoutsReply> {
22191 let request = types::dpms::GetTimeoutsRequest {};
22192 let cookie = self.send_reply_request(request);
22193 let res: futures::CheckedSendRequest<'this, Self, types::dpms::GetTimeoutsReply> =
22194 cookie.into();
22195 res
22196 }
22197 #[cfg(feature = "dpms")]
22198 fn dpms_set_timeouts<'this>(
22199 &'this mut self,
22200 standby_timeout: types::Card16,
22201 suspend_timeout: types::Card16,
22202 off_timeout: types::Card16,
22203 ) -> futures::SendRequest<'this, Self, ()> {
22204 let span = tracing::info_span!(
22205 "dpms_set_timeouts",
22206 standby_timeout = ?standby_timeout,
22207 suspend_timeout = ?suspend_timeout,
22208 off_timeout = ?off_timeout,
22209 );
22210 let request = types::dpms::SetTimeoutsRequest {
22211 standby_timeout,
22212 suspend_timeout,
22213 off_timeout,
22214 };
22215 let cookie = self.send_void_request(request, true).with_span(span);
22216 cookie
22217 }
22218 #[cfg(feature = "dpms")]
22219 fn dpms_set_timeouts_checked<'this>(
22220 &'this mut self,
22221 standby_timeout: types::Card16,
22222 suspend_timeout: types::Card16,
22223 off_timeout: types::Card16,
22224 ) -> futures::CheckedSendRequest<'this, Self, ()> {
22225 let request = types::dpms::SetTimeoutsRequest {
22226 standby_timeout,
22227 suspend_timeout,
22228 off_timeout,
22229 };
22230 let cookie = self.send_void_request(request, false);
22231 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
22232 res
22233 }
22234 #[cfg(feature = "dpms")]
22235 fn dpms_enable<'this>(&'this mut self) -> futures::SendRequest<'this, Self, ()> {
22236 let span = tracing::info_span!("dpms_enable",);
22237 let request = types::dpms::EnableRequest {};
22238 let cookie = self.send_void_request(request, true).with_span(span);
22239 cookie
22240 }
22241 #[cfg(feature = "dpms")]
22242 fn dpms_enable_checked<'this>(&'this mut self) -> futures::CheckedSendRequest<'this, Self, ()> {
22243 let request = types::dpms::EnableRequest {};
22244 let cookie = self.send_void_request(request, false);
22245 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
22246 res
22247 }
22248 #[cfg(feature = "dpms")]
22249 fn dpms_disable<'this>(&'this mut self) -> futures::SendRequest<'this, Self, ()> {
22250 let span = tracing::info_span!("dpms_disable",);
22251 let request = types::dpms::DisableRequest {};
22252 let cookie = self.send_void_request(request, true).with_span(span);
22253 cookie
22254 }
22255 #[cfg(feature = "dpms")]
22256 fn dpms_disable_checked<'this>(
22257 &'this mut self,
22258 ) -> futures::CheckedSendRequest<'this, Self, ()> {
22259 let request = types::dpms::DisableRequest {};
22260 let cookie = self.send_void_request(request, false);
22261 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
22262 res
22263 }
22264 #[cfg(feature = "dpms")]
22265 fn dpms_force_level<'this>(
22266 &'this mut self,
22267 power_level: types::DPMSMode,
22268 ) -> futures::SendRequest<'this, Self, ()> {
22269 let span = tracing::info_span!(
22270 "dpms_force_level",
22271 power_level = ?power_level,
22272 );
22273 let request = types::dpms::ForceLevelRequest { power_level };
22274 let cookie = self.send_void_request(request, true).with_span(span);
22275 cookie
22276 }
22277 #[cfg(feature = "dpms")]
22278 fn dpms_force_level_checked<'this>(
22279 &'this mut self,
22280 power_level: types::DPMSMode,
22281 ) -> futures::CheckedSendRequest<'this, Self, ()> {
22282 let request = types::dpms::ForceLevelRequest { power_level };
22283 let cookie = self.send_void_request(request, false);
22284 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
22285 res
22286 }
22287 #[cfg(feature = "dpms")]
22288 fn dpms_info<'this>(
22289 &'this mut self,
22290 ) -> futures::SendRequest<'this, Self, types::dpms::InfoReply> {
22291 let span = tracing::info_span!("dpms_info",);
22292 let request = types::dpms::InfoRequest {};
22293 let cookie = self.send_reply_request(request).with_span(span);
22294 cookie
22295 }
22296 #[cfg(feature = "dpms")]
22297 fn dpms_info_immediate<'this>(
22298 &'this mut self,
22299 ) -> futures::CheckedSendRequest<'this, Self, types::dpms::InfoReply> {
22300 let request = types::dpms::InfoRequest {};
22301 let cookie = self.send_reply_request(request);
22302 let res: futures::CheckedSendRequest<'this, Self, types::dpms::InfoReply> = cookie.into();
22303 res
22304 }
22305
22306 #[cfg(feature = "dri2")]
22307 fn dri2_query_version<'this>(
22308 &'this mut self,
22309 major_version: types::Card32,
22310 minor_version: types::Card32,
22311 ) -> futures::SendRequest<'this, Self, types::dri2::QueryVersionReply> {
22312 let span = tracing::info_span!(
22313 "dri2_query_version",
22314 major_version = ?major_version,
22315 minor_version = ?minor_version,
22316 );
22317 let request = types::dri2::QueryVersionRequest {
22318 major_version,
22319 minor_version,
22320 };
22321 let cookie = self.send_reply_request(request).with_span(span);
22322 cookie
22323 }
22324 #[cfg(feature = "dri2")]
22325 fn dri2_query_version_immediate<'this>(
22326 &'this mut self,
22327 major_version: types::Card32,
22328 minor_version: types::Card32,
22329 ) -> futures::CheckedSendRequest<'this, Self, types::dri2::QueryVersionReply> {
22330 let request = types::dri2::QueryVersionRequest {
22331 major_version,
22332 minor_version,
22333 };
22334 let cookie = self.send_reply_request(request);
22335 let res: futures::CheckedSendRequest<'this, Self, types::dri2::QueryVersionReply> =
22336 cookie.into();
22337 res
22338 }
22339 #[cfg(feature = "dri2")]
22340 fn dri2_connect<'this>(
22341 &'this mut self,
22342 window: types::xproto::Window,
22343 driver_type: types::DriverType,
22344 ) -> futures::SendRequest<'this, Self, types::dri2::ConnectReply> {
22345 let span = tracing::info_span!(
22346 "dri2_connect",
22347 window = ?window,
22348 driver_type = ?driver_type,
22349 );
22350 let request = types::dri2::ConnectRequest {
22351 window,
22352 driver_type,
22353 };
22354 let cookie = self.send_reply_request(request).with_span(span);
22355 cookie
22356 }
22357 #[cfg(feature = "dri2")]
22358 fn dri2_connect_immediate<'this>(
22359 &'this mut self,
22360 window: types::xproto::Window,
22361 driver_type: types::DriverType,
22362 ) -> futures::CheckedSendRequest<'this, Self, types::dri2::ConnectReply> {
22363 let request = types::dri2::ConnectRequest {
22364 window,
22365 driver_type,
22366 };
22367 let cookie = self.send_reply_request(request);
22368 let res: futures::CheckedSendRequest<'this, Self, types::dri2::ConnectReply> =
22369 cookie.into();
22370 res
22371 }
22372 #[cfg(feature = "dri2")]
22373 fn dri2_authenticate<'this>(
22374 &'this mut self,
22375 window: types::xproto::Window,
22376 magic: types::Card32,
22377 ) -> futures::SendRequest<'this, Self, types::dri2::AuthenticateReply> {
22378 let span = tracing::info_span!(
22379 "dri2_authenticate",
22380 window = ?window,
22381 magic = ?magic,
22382 );
22383 let request = types::dri2::AuthenticateRequest { window, magic };
22384 let cookie = self.send_reply_request(request).with_span(span);
22385 cookie
22386 }
22387 #[cfg(feature = "dri2")]
22388 fn dri2_authenticate_immediate<'this>(
22389 &'this mut self,
22390 window: types::xproto::Window,
22391 magic: types::Card32,
22392 ) -> futures::CheckedSendRequest<'this, Self, types::dri2::AuthenticateReply> {
22393 let request = types::dri2::AuthenticateRequest { window, magic };
22394 let cookie = self.send_reply_request(request);
22395 let res: futures::CheckedSendRequest<'this, Self, types::dri2::AuthenticateReply> =
22396 cookie.into();
22397 res
22398 }
22399 #[cfg(feature = "dri2")]
22400 fn dri2_create_drawable<'this>(
22401 &'this mut self,
22402 drawable: types::xproto::Drawable,
22403 ) -> futures::SendRequest<'this, Self, ()> {
22404 let span = tracing::info_span!(
22405 "dri2_create_drawable",
22406 drawable = ?drawable,
22407 );
22408 let request = types::dri2::CreateDrawableRequest { drawable };
22409 let cookie = self.send_void_request(request, true).with_span(span);
22410 cookie
22411 }
22412 #[cfg(feature = "dri2")]
22413 fn dri2_create_drawable_checked<'this>(
22414 &'this mut self,
22415 drawable: types::xproto::Drawable,
22416 ) -> futures::CheckedSendRequest<'this, Self, ()> {
22417 let request = types::dri2::CreateDrawableRequest { drawable };
22418 let cookie = self.send_void_request(request, false);
22419 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
22420 res
22421 }
22422 #[cfg(feature = "dri2")]
22423 fn dri2_destroy_drawable<'this>(
22424 &'this mut self,
22425 drawable: types::xproto::Drawable,
22426 ) -> futures::SendRequest<'this, Self, ()> {
22427 let span = tracing::info_span!(
22428 "dri2_destroy_drawable",
22429 drawable = ?drawable,
22430 );
22431 let request = types::dri2::DestroyDrawableRequest { drawable };
22432 let cookie = self.send_void_request(request, true).with_span(span);
22433 cookie
22434 }
22435 #[cfg(feature = "dri2")]
22436 fn dri2_destroy_drawable_checked<'this>(
22437 &'this mut self,
22438 drawable: types::xproto::Drawable,
22439 ) -> futures::CheckedSendRequest<'this, Self, ()> {
22440 let request = types::dri2::DestroyDrawableRequest { drawable };
22441 let cookie = self.send_void_request(request, false);
22442 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
22443 res
22444 }
22445 #[cfg(feature = "dri2")]
22446 fn dri2_copy_region<'this>(
22447 &'this mut self,
22448 drawable: types::xproto::Drawable,
22449 region: types::Card32,
22450 dest: types::Card32,
22451 src: types::Card32,
22452 ) -> futures::SendRequest<'this, Self, types::dri2::CopyRegionReply> {
22453 let span = tracing::info_span!(
22454 "dri2_copy_region",
22455 drawable = ?drawable,
22456 region = ?region,
22457 dest = ?dest,
22458 src = ?src,
22459 );
22460 let request = types::dri2::CopyRegionRequest {
22461 drawable,
22462 region,
22463 dest,
22464 src,
22465 };
22466 let cookie = self.send_reply_request(request).with_span(span);
22467 cookie
22468 }
22469 #[cfg(feature = "dri2")]
22470 fn dri2_copy_region_immediate<'this>(
22471 &'this mut self,
22472 drawable: types::xproto::Drawable,
22473 region: types::Card32,
22474 dest: types::Card32,
22475 src: types::Card32,
22476 ) -> futures::CheckedSendRequest<'this, Self, types::dri2::CopyRegionReply> {
22477 let request = types::dri2::CopyRegionRequest {
22478 drawable,
22479 region,
22480 dest,
22481 src,
22482 };
22483 let cookie = self.send_reply_request(request);
22484 let res: futures::CheckedSendRequest<'this, Self, types::dri2::CopyRegionReply> =
22485 cookie.into();
22486 res
22487 }
22488 #[cfg(feature = "dri2")]
22489 fn dri2_swap_buffers<'this>(
22490 &'this mut self,
22491 drawable: types::xproto::Drawable,
22492 target_msc_hi: types::Card32,
22493 target_msc_lo: types::Card32,
22494 divisor_hi: types::Card32,
22495 divisor_lo: types::Card32,
22496 remainder_hi: types::Card32,
22497 remainder_lo: types::Card32,
22498 ) -> futures::SendRequest<'this, Self, types::dri2::SwapBuffersReply> {
22499 let span = tracing::info_span!(
22500 "dri2_swap_buffers",
22501 drawable = ?drawable,
22502 target_msc_hi = ?target_msc_hi,
22503 target_msc_lo = ?target_msc_lo,
22504 divisor_hi = ?divisor_hi,
22505 divisor_lo = ?divisor_lo,
22506 remainder_hi = ?remainder_hi,
22507 remainder_lo = ?remainder_lo,
22508 );
22509 let request = types::dri2::SwapBuffersRequest {
22510 drawable,
22511 target_msc_hi,
22512 target_msc_lo,
22513 divisor_hi,
22514 divisor_lo,
22515 remainder_hi,
22516 remainder_lo,
22517 };
22518 let cookie = self.send_reply_request(request).with_span(span);
22519 cookie
22520 }
22521 #[cfg(feature = "dri2")]
22522 fn dri2_swap_buffers_immediate<'this>(
22523 &'this mut self,
22524 drawable: types::xproto::Drawable,
22525 target_msc_hi: types::Card32,
22526 target_msc_lo: types::Card32,
22527 divisor_hi: types::Card32,
22528 divisor_lo: types::Card32,
22529 remainder_hi: types::Card32,
22530 remainder_lo: types::Card32,
22531 ) -> futures::CheckedSendRequest<'this, Self, types::dri2::SwapBuffersReply> {
22532 let request = types::dri2::SwapBuffersRequest {
22533 drawable,
22534 target_msc_hi,
22535 target_msc_lo,
22536 divisor_hi,
22537 divisor_lo,
22538 remainder_hi,
22539 remainder_lo,
22540 };
22541 let cookie = self.send_reply_request(request);
22542 let res: futures::CheckedSendRequest<'this, Self, types::dri2::SwapBuffersReply> =
22543 cookie.into();
22544 res
22545 }
22546 #[cfg(feature = "dri2")]
22547 fn dri2_get_msc<'this>(
22548 &'this mut self,
22549 drawable: types::xproto::Drawable,
22550 ) -> futures::SendRequest<'this, Self, types::dri2::GetMSCReply> {
22551 let span = tracing::info_span!(
22552 "dri2_get_msc",
22553 drawable = ?drawable,
22554 );
22555 let request = types::dri2::GetMSCRequest { drawable };
22556 let cookie = self.send_reply_request(request).with_span(span);
22557 cookie
22558 }
22559 #[cfg(feature = "dri2")]
22560 fn dri2_get_msc_immediate<'this>(
22561 &'this mut self,
22562 drawable: types::xproto::Drawable,
22563 ) -> futures::CheckedSendRequest<'this, Self, types::dri2::GetMSCReply> {
22564 let request = types::dri2::GetMSCRequest { drawable };
22565 let cookie = self.send_reply_request(request);
22566 let res: futures::CheckedSendRequest<'this, Self, types::dri2::GetMSCReply> = cookie.into();
22567 res
22568 }
22569 #[cfg(feature = "dri2")]
22570 fn dri2_wait_msc<'this>(
22571 &'this mut self,
22572 drawable: types::xproto::Drawable,
22573 target_msc_hi: types::Card32,
22574 target_msc_lo: types::Card32,
22575 divisor_hi: types::Card32,
22576 divisor_lo: types::Card32,
22577 remainder_hi: types::Card32,
22578 remainder_lo: types::Card32,
22579 ) -> futures::SendRequest<'this, Self, types::dri2::WaitMSCReply> {
22580 let span = tracing::info_span!(
22581 "dri2_wait_msc",
22582 drawable = ?drawable,
22583 target_msc_hi = ?target_msc_hi,
22584 target_msc_lo = ?target_msc_lo,
22585 divisor_hi = ?divisor_hi,
22586 divisor_lo = ?divisor_lo,
22587 remainder_hi = ?remainder_hi,
22588 remainder_lo = ?remainder_lo,
22589 );
22590 let request = types::dri2::WaitMSCRequest {
22591 drawable,
22592 target_msc_hi,
22593 target_msc_lo,
22594 divisor_hi,
22595 divisor_lo,
22596 remainder_hi,
22597 remainder_lo,
22598 };
22599 let cookie = self.send_reply_request(request).with_span(span);
22600 cookie
22601 }
22602 #[cfg(feature = "dri2")]
22603 fn dri2_wait_msc_immediate<'this>(
22604 &'this mut self,
22605 drawable: types::xproto::Drawable,
22606 target_msc_hi: types::Card32,
22607 target_msc_lo: types::Card32,
22608 divisor_hi: types::Card32,
22609 divisor_lo: types::Card32,
22610 remainder_hi: types::Card32,
22611 remainder_lo: types::Card32,
22612 ) -> futures::CheckedSendRequest<'this, Self, types::dri2::WaitMSCReply> {
22613 let request = types::dri2::WaitMSCRequest {
22614 drawable,
22615 target_msc_hi,
22616 target_msc_lo,
22617 divisor_hi,
22618 divisor_lo,
22619 remainder_hi,
22620 remainder_lo,
22621 };
22622 let cookie = self.send_reply_request(request);
22623 let res: futures::CheckedSendRequest<'this, Self, types::dri2::WaitMSCReply> =
22624 cookie.into();
22625 res
22626 }
22627 #[cfg(feature = "dri2")]
22628 fn dri2_wait_sbc<'this>(
22629 &'this mut self,
22630 drawable: types::xproto::Drawable,
22631 target_sbc_hi: types::Card32,
22632 target_sbc_lo: types::Card32,
22633 ) -> futures::SendRequest<'this, Self, types::dri2::WaitSBCReply> {
22634 let span = tracing::info_span!(
22635 "dri2_wait_sbc",
22636 drawable = ?drawable,
22637 target_sbc_hi = ?target_sbc_hi,
22638 target_sbc_lo = ?target_sbc_lo,
22639 );
22640 let request = types::dri2::WaitSBCRequest {
22641 drawable,
22642 target_sbc_hi,
22643 target_sbc_lo,
22644 };
22645 let cookie = self.send_reply_request(request).with_span(span);
22646 cookie
22647 }
22648 #[cfg(feature = "dri2")]
22649 fn dri2_wait_sbc_immediate<'this>(
22650 &'this mut self,
22651 drawable: types::xproto::Drawable,
22652 target_sbc_hi: types::Card32,
22653 target_sbc_lo: types::Card32,
22654 ) -> futures::CheckedSendRequest<'this, Self, types::dri2::WaitSBCReply> {
22655 let request = types::dri2::WaitSBCRequest {
22656 drawable,
22657 target_sbc_hi,
22658 target_sbc_lo,
22659 };
22660 let cookie = self.send_reply_request(request);
22661 let res: futures::CheckedSendRequest<'this, Self, types::dri2::WaitSBCReply> =
22662 cookie.into();
22663 res
22664 }
22665 #[cfg(feature = "dri2")]
22666 fn dri2_swap_interval<'this>(
22667 &'this mut self,
22668 drawable: types::xproto::Drawable,
22669 interval: types::Card32,
22670 ) -> futures::SendRequest<'this, Self, ()> {
22671 let span = tracing::info_span!(
22672 "dri2_swap_interval",
22673 drawable = ?drawable,
22674 interval = ?interval,
22675 );
22676 let request = types::dri2::SwapIntervalRequest { drawable, interval };
22677 let cookie = self.send_void_request(request, true).with_span(span);
22678 cookie
22679 }
22680 #[cfg(feature = "dri2")]
22681 fn dri2_swap_interval_checked<'this>(
22682 &'this mut self,
22683 drawable: types::xproto::Drawable,
22684 interval: types::Card32,
22685 ) -> futures::CheckedSendRequest<'this, Self, ()> {
22686 let request = types::dri2::SwapIntervalRequest { drawable, interval };
22687 let cookie = self.send_void_request(request, false);
22688 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
22689 res
22690 }
22691 #[cfg(feature = "dri2")]
22692 fn dri2_get_param<'this>(
22693 &'this mut self,
22694 drawable: types::xproto::Drawable,
22695 param: types::Card32,
22696 ) -> futures::SendRequest<'this, Self, types::dri2::GetParamReply> {
22697 let span = tracing::info_span!(
22698 "dri2_get_param",
22699 drawable = ?drawable,
22700 param = ?param,
22701 );
22702 let request = types::dri2::GetParamRequest { drawable, param };
22703 let cookie = self.send_reply_request(request).with_span(span);
22704 cookie
22705 }
22706 #[cfg(feature = "dri2")]
22707 fn dri2_get_param_immediate<'this>(
22708 &'this mut self,
22709 drawable: types::xproto::Drawable,
22710 param: types::Card32,
22711 ) -> futures::CheckedSendRequest<'this, Self, types::dri2::GetParamReply> {
22712 let request = types::dri2::GetParamRequest { drawable, param };
22713 let cookie = self.send_reply_request(request);
22714 let res: futures::CheckedSendRequest<'this, Self, types::dri2::GetParamReply> =
22715 cookie.into();
22716 res
22717 }
22718
22719 #[cfg(feature = "dri3")]
22720 fn dri3_query_version<'this>(
22721 &'this mut self,
22722 major_version: types::Card32,
22723 minor_version: types::Card32,
22724 ) -> futures::SendRequest<'this, Self, types::dri3::QueryVersionReply> {
22725 let span = tracing::info_span!(
22726 "dri3_query_version",
22727 major_version = ?major_version,
22728 minor_version = ?minor_version,
22729 );
22730 let request = types::dri3::QueryVersionRequest {
22731 major_version,
22732 minor_version,
22733 };
22734 let cookie = self.send_reply_request(request).with_span(span);
22735 cookie
22736 }
22737 #[cfg(feature = "dri3")]
22738 fn dri3_query_version_immediate<'this>(
22739 &'this mut self,
22740 major_version: types::Card32,
22741 minor_version: types::Card32,
22742 ) -> futures::CheckedSendRequest<'this, Self, types::dri3::QueryVersionReply> {
22743 let request = types::dri3::QueryVersionRequest {
22744 major_version,
22745 minor_version,
22746 };
22747 let cookie = self.send_reply_request(request);
22748 let res: futures::CheckedSendRequest<'this, Self, types::dri3::QueryVersionReply> =
22749 cookie.into();
22750 res
22751 }
22752 #[cfg(feature = "dri3")]
22753 fn dri3_open<'this>(
22754 &'this mut self,
22755 drawable: types::xproto::Drawable,
22756 provider: types::Card32,
22757 ) -> futures::SendRequest<'this, Self, types::dri3::OpenReply> {
22758 let span = tracing::info_span!(
22759 "dri3_open",
22760 drawable = ?drawable,
22761 provider = ?provider,
22762 );
22763 let request = types::dri3::OpenRequest { drawable, provider };
22764 let cookie = self.send_reply_fd_request(request).with_span(span);
22765 cookie
22766 }
22767 #[cfg(feature = "dri3")]
22768 fn dri3_open_immediate<'this>(
22769 &'this mut self,
22770 drawable: types::xproto::Drawable,
22771 provider: types::Card32,
22772 ) -> futures::CheckedSendRequest<'this, Self, types::dri3::OpenReply> {
22773 let request = types::dri3::OpenRequest { drawable, provider };
22774 let cookie = self.send_reply_fd_request(request);
22775 let res: futures::CheckedSendRequest<'this, Self, types::dri3::OpenReply> = cookie.into();
22776 res
22777 }
22778 #[cfg(feature = "dri3")]
22779 fn dri3_pixmap_from_buffer<'this>(
22780 &'this mut self,
22781 pixmap: types::xproto::Pixmap,
22782 drawable: types::xproto::Drawable,
22783 size: types::Card32,
22784 width: types::Card16,
22785 height: types::Card16,
22786 stride: types::Card16,
22787 depth: types::Card8,
22788 bpp: types::Card8,
22789 pixmap_fd: types::Fd,
22790 ) -> futures::SendRequest<'this, Self, ()> {
22791 let span = tracing::info_span!(
22792 "dri3_pixmap_from_buffer",
22793 pixmap = ?pixmap,
22794 drawable = ?drawable,
22795 size = ?size,
22796 width = ?width,
22797 height = ?height,
22798 stride = ?stride,
22799 depth = ?depth,
22800 bpp = ?bpp,
22801 pixmap_fd = ?pixmap_fd,
22802 );
22803 let request = types::dri3::PixmapFromBufferRequest {
22804 pixmap,
22805 drawable,
22806 size,
22807 width,
22808 height,
22809 stride,
22810 depth,
22811 bpp,
22812 pixmap_fd,
22813 };
22814 let cookie = self.send_void_request(request, true).with_span(span);
22815 cookie
22816 }
22817 #[cfg(feature = "dri3")]
22818 fn dri3_pixmap_from_buffer_checked<'this>(
22819 &'this mut self,
22820 pixmap: types::xproto::Pixmap,
22821 drawable: types::xproto::Drawable,
22822 size: types::Card32,
22823 width: types::Card16,
22824 height: types::Card16,
22825 stride: types::Card16,
22826 depth: types::Card8,
22827 bpp: types::Card8,
22828 pixmap_fd: types::Fd,
22829 ) -> futures::CheckedSendRequest<'this, Self, ()> {
22830 let request = types::dri3::PixmapFromBufferRequest {
22831 pixmap,
22832 drawable,
22833 size,
22834 width,
22835 height,
22836 stride,
22837 depth,
22838 bpp,
22839 pixmap_fd,
22840 };
22841 let cookie = self.send_void_request(request, false);
22842 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
22843 res
22844 }
22845 #[cfg(feature = "dri3")]
22846 fn dri3_buffer_from_pixmap<'this>(
22847 &'this mut self,
22848 pixmap: types::xproto::Pixmap,
22849 ) -> futures::SendRequest<'this, Self, types::dri3::BufferFromPixmapReply> {
22850 let span = tracing::info_span!(
22851 "dri3_buffer_from_pixmap",
22852 pixmap = ?pixmap,
22853 );
22854 let request = types::dri3::BufferFromPixmapRequest { pixmap };
22855 let cookie = self.send_reply_fd_request(request).with_span(span);
22856 cookie
22857 }
22858 #[cfg(feature = "dri3")]
22859 fn dri3_buffer_from_pixmap_immediate<'this>(
22860 &'this mut self,
22861 pixmap: types::xproto::Pixmap,
22862 ) -> futures::CheckedSendRequest<'this, Self, types::dri3::BufferFromPixmapReply> {
22863 let request = types::dri3::BufferFromPixmapRequest { pixmap };
22864 let cookie = self.send_reply_fd_request(request);
22865 let res: futures::CheckedSendRequest<'this, Self, types::dri3::BufferFromPixmapReply> =
22866 cookie.into();
22867 res
22868 }
22869 #[cfg(feature = "dri3")]
22870 fn dri3_fence_from_fd<'this>(
22871 &'this mut self,
22872 drawable: types::xproto::Drawable,
22873 fence: types::Card32,
22874 initially_triggered: types::Bool,
22875 fence_fd: types::Fd,
22876 ) -> futures::SendRequest<'this, Self, ()> {
22877 let span = tracing::info_span!(
22878 "dri3_fence_from_fd",
22879 drawable = ?drawable,
22880 fence = ?fence,
22881 initially_triggered = ?initially_triggered,
22882 fence_fd = ?fence_fd,
22883 );
22884 let request = types::dri3::FenceFromFDRequest {
22885 drawable,
22886 fence,
22887 initially_triggered,
22888 fence_fd,
22889 };
22890 let cookie = self.send_void_request(request, true).with_span(span);
22891 cookie
22892 }
22893 #[cfg(feature = "dri3")]
22894 fn dri3_fence_from_fd_checked<'this>(
22895 &'this mut self,
22896 drawable: types::xproto::Drawable,
22897 fence: types::Card32,
22898 initially_triggered: types::Bool,
22899 fence_fd: types::Fd,
22900 ) -> futures::CheckedSendRequest<'this, Self, ()> {
22901 let request = types::dri3::FenceFromFDRequest {
22902 drawable,
22903 fence,
22904 initially_triggered,
22905 fence_fd,
22906 };
22907 let cookie = self.send_void_request(request, false);
22908 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
22909 res
22910 }
22911 #[cfg(feature = "dri3")]
22912 fn dri3_fd_from_fence<'this>(
22913 &'this mut self,
22914 drawable: types::xproto::Drawable,
22915 fence: types::Card32,
22916 ) -> futures::SendRequest<'this, Self, types::dri3::FDFromFenceReply> {
22917 let span = tracing::info_span!(
22918 "dri3_fd_from_fence",
22919 drawable = ?drawable,
22920 fence = ?fence,
22921 );
22922 let request = types::dri3::FDFromFenceRequest { drawable, fence };
22923 let cookie = self.send_reply_fd_request(request).with_span(span);
22924 cookie
22925 }
22926 #[cfg(feature = "dri3")]
22927 fn dri3_fd_from_fence_immediate<'this>(
22928 &'this mut self,
22929 drawable: types::xproto::Drawable,
22930 fence: types::Card32,
22931 ) -> futures::CheckedSendRequest<'this, Self, types::dri3::FDFromFenceReply> {
22932 let request = types::dri3::FDFromFenceRequest { drawable, fence };
22933 let cookie = self.send_reply_fd_request(request);
22934 let res: futures::CheckedSendRequest<'this, Self, types::dri3::FDFromFenceReply> =
22935 cookie.into();
22936 res
22937 }
22938 #[cfg(feature = "dri3")]
22939 fn dri3_get_supported_modifiers<'this>(
22940 &'this mut self,
22941 window: types::Card32,
22942 depth: types::Card8,
22943 bpp: types::Card8,
22944 ) -> futures::SendRequest<'this, Self, types::dri3::GetSupportedModifiersReply> {
22945 let span = tracing::info_span!(
22946 "dri3_get_supported_modifiers",
22947 window = ?window,
22948 depth = ?depth,
22949 bpp = ?bpp,
22950 );
22951 let request = types::dri3::GetSupportedModifiersRequest { window, depth, bpp };
22952 let cookie = self.send_reply_request(request).with_span(span);
22953 cookie
22954 }
22955 #[cfg(feature = "dri3")]
22956 fn dri3_get_supported_modifiers_immediate<'this>(
22957 &'this mut self,
22958 window: types::Card32,
22959 depth: types::Card8,
22960 bpp: types::Card8,
22961 ) -> futures::CheckedSendRequest<'this, Self, types::dri3::GetSupportedModifiersReply> {
22962 let request = types::dri3::GetSupportedModifiersRequest { window, depth, bpp };
22963 let cookie = self.send_reply_request(request);
22964 let res: futures::CheckedSendRequest<'this, Self, types::dri3::GetSupportedModifiersReply> =
22965 cookie.into();
22966 res
22967 }
22968 #[cfg(feature = "dri3")]
22969 fn dri3_pixmap_from_buffers<'this>(
22970 &'this mut self,
22971 pixmap: types::xproto::Pixmap,
22972 window: types::xproto::Window,
22973 width: types::Card16,
22974 height: types::Card16,
22975 stride0: types::Card32,
22976 offset0: types::Card32,
22977 stride1: types::Card32,
22978 offset1: types::Card32,
22979 stride2: types::Card32,
22980 offset2: types::Card32,
22981 stride3: types::Card32,
22982 offset3: types::Card32,
22983 depth: types::Card8,
22984 bpp: types::Card8,
22985 modifier: types::Card64,
22986 buffers: Vec<types::Fd>,
22987 ) -> futures::SendRequest<'this, Self, ()> {
22988 let span = tracing::info_span!(
22989 "dri3_pixmap_from_buffers",
22990 pixmap = ?pixmap,
22991 window = ?window,
22992 width = ?width,
22993 height = ?height,
22994 stride0 = ?stride0,
22995 offset0 = ?offset0,
22996 stride1 = ?stride1,
22997 offset1 = ?offset1,
22998 stride2 = ?stride2,
22999 offset2 = ?offset2,
23000 stride3 = ?stride3,
23001 offset3 = ?offset3,
23002 depth = ?depth,
23003 bpp = ?bpp,
23004 modifier = ?modifier,
23005 );
23006 let request = types::dri3::PixmapFromBuffersRequest {
23007 pixmap,
23008 window,
23009 width,
23010 height,
23011 stride0,
23012 offset0,
23013 stride1,
23014 offset1,
23015 stride2,
23016 offset2,
23017 stride3,
23018 offset3,
23019 depth,
23020 bpp,
23021 modifier,
23022 buffers,
23023 };
23024 let cookie = self.send_void_request(request, true).with_span(span);
23025 cookie
23026 }
23027 #[cfg(feature = "dri3")]
23028 fn dri3_pixmap_from_buffers_checked<'this>(
23029 &'this mut self,
23030 pixmap: types::xproto::Pixmap,
23031 window: types::xproto::Window,
23032 width: types::Card16,
23033 height: types::Card16,
23034 stride0: types::Card32,
23035 offset0: types::Card32,
23036 stride1: types::Card32,
23037 offset1: types::Card32,
23038 stride2: types::Card32,
23039 offset2: types::Card32,
23040 stride3: types::Card32,
23041 offset3: types::Card32,
23042 depth: types::Card8,
23043 bpp: types::Card8,
23044 modifier: types::Card64,
23045 buffers: Vec<types::Fd>,
23046 ) -> futures::CheckedSendRequest<'this, Self, ()> {
23047 let request = types::dri3::PixmapFromBuffersRequest {
23048 pixmap,
23049 window,
23050 width,
23051 height,
23052 stride0,
23053 offset0,
23054 stride1,
23055 offset1,
23056 stride2,
23057 offset2,
23058 stride3,
23059 offset3,
23060 depth,
23061 bpp,
23062 modifier,
23063 buffers,
23064 };
23065 let cookie = self.send_void_request(request, false);
23066 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
23067 res
23068 }
23069 #[cfg(feature = "dri3")]
23070 fn dri3_buffers_from_pixmap<'this>(
23071 &'this mut self,
23072 pixmap: types::xproto::Pixmap,
23073 ) -> futures::SendRequest<'this, Self, types::dri3::BuffersFromPixmapReply> {
23074 let span = tracing::info_span!(
23075 "dri3_buffers_from_pixmap",
23076 pixmap = ?pixmap,
23077 );
23078 let request = types::dri3::BuffersFromPixmapRequest { pixmap };
23079 let cookie = self.send_reply_fd_request(request).with_span(span);
23080 cookie
23081 }
23082 #[cfg(feature = "dri3")]
23083 fn dri3_buffers_from_pixmap_immediate<'this>(
23084 &'this mut self,
23085 pixmap: types::xproto::Pixmap,
23086 ) -> futures::CheckedSendRequest<'this, Self, types::dri3::BuffersFromPixmapReply> {
23087 let request = types::dri3::BuffersFromPixmapRequest { pixmap };
23088 let cookie = self.send_reply_fd_request(request);
23089 let res: futures::CheckedSendRequest<'this, Self, types::dri3::BuffersFromPixmapReply> =
23090 cookie.into();
23091 res
23092 }
23093
23094 fn ge_query_version<'this>(
23095 &'this mut self,
23096 client_major_version: types::Card16,
23097 client_minor_version: types::Card16,
23098 ) -> futures::SendRequest<'this, Self, types::ge::QueryVersionReply> {
23099 let span = tracing::info_span!(
23100 "ge_query_version",
23101 client_major_version = ?client_major_version,
23102 client_minor_version = ?client_minor_version,
23103 );
23104 let request = types::ge::QueryVersionRequest {
23105 client_major_version,
23106 client_minor_version,
23107 };
23108 let cookie = self.send_reply_request(request).with_span(span);
23109 cookie
23110 }
23111 fn ge_query_version_immediate<'this>(
23112 &'this mut self,
23113 client_major_version: types::Card16,
23114 client_minor_version: types::Card16,
23115 ) -> futures::CheckedSendRequest<'this, Self, types::ge::QueryVersionReply> {
23116 let request = types::ge::QueryVersionRequest {
23117 client_major_version,
23118 client_minor_version,
23119 };
23120 let cookie = self.send_reply_request(request);
23121 let res: futures::CheckedSendRequest<'this, Self, types::ge::QueryVersionReply> =
23122 cookie.into();
23123 res
23124 }
23125
23126 #[cfg(feature = "glx")]
23127 fn glx_render<'this>(
23128 &'this mut self,
23129 context_tag: types::ContextTag,
23130 data: impl AsRef<[types::Byte]>,
23131 ) -> futures::SendRequest<'this, Self, ()> {
23132 let span = tracing::info_span!(
23133 "glx_render",
23134 context_tag = ?context_tag,
23135 );
23136 let request = types::glx::RenderRequest {
23137 context_tag,
23138 data: Cow::Borrowed(data.as_ref()),
23139 };
23140 let cookie = self.send_void_request(request, true).with_span(span);
23141 cookie
23142 }
23143 #[cfg(feature = "glx")]
23144 fn glx_render_checked<'this>(
23145 &'this mut self,
23146 context_tag: types::ContextTag,
23147 data: impl AsRef<[types::Byte]>,
23148 ) -> futures::CheckedSendRequest<'this, Self, ()> {
23149 let request = types::glx::RenderRequest {
23150 context_tag,
23151 data: Cow::Borrowed(data.as_ref()),
23152 };
23153 let cookie = self.send_void_request(request, false);
23154 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
23155 res
23156 }
23157 #[cfg(feature = "glx")]
23158 fn glx_render_large<'this>(
23159 &'this mut self,
23160 context_tag: types::ContextTag,
23161 request_num: types::Card16,
23162 request_total: types::Card16,
23163 data: impl AsRef<[types::Byte]>,
23164 ) -> futures::SendRequest<'this, Self, ()> {
23165 let span = tracing::info_span!(
23166 "glx_render_large",
23167 context_tag = ?context_tag,
23168 request_num = ?request_num,
23169 request_total = ?request_total,
23170 );
23171 let request = types::glx::RenderLargeRequest {
23172 context_tag,
23173 request_num,
23174 request_total,
23175 data: Cow::Borrowed(data.as_ref()),
23176 };
23177 let cookie = self.send_void_request(request, true).with_span(span);
23178 cookie
23179 }
23180 #[cfg(feature = "glx")]
23181 fn glx_render_large_checked<'this>(
23182 &'this mut self,
23183 context_tag: types::ContextTag,
23184 request_num: types::Card16,
23185 request_total: types::Card16,
23186 data: impl AsRef<[types::Byte]>,
23187 ) -> futures::CheckedSendRequest<'this, Self, ()> {
23188 let request = types::glx::RenderLargeRequest {
23189 context_tag,
23190 request_num,
23191 request_total,
23192 data: Cow::Borrowed(data.as_ref()),
23193 };
23194 let cookie = self.send_void_request(request, false);
23195 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
23196 res
23197 }
23198 #[cfg(feature = "glx")]
23199 fn glx_create_context<'this>(
23200 &'this mut self,
23201 context: types::glx::Context,
23202 visual: types::Visualid,
23203 screen: types::Card32,
23204 share_list: types::glx::Context,
23205 is_direct: types::Bool,
23206 ) -> futures::SendRequest<'this, Self, ()> {
23207 let span = tracing::info_span!(
23208 "glx_create_context",
23209 context = ?context,
23210 visual = ?visual,
23211 screen = ?screen,
23212 share_list = ?share_list,
23213 is_direct = ?is_direct,
23214 );
23215 let request = types::glx::CreateContextRequest {
23216 context,
23217 visual,
23218 screen,
23219 share_list,
23220 is_direct,
23221 };
23222 let cookie = self.send_void_request(request, true).with_span(span);
23223 cookie
23224 }
23225 #[cfg(feature = "glx")]
23226 fn glx_create_context_checked<'this>(
23227 &'this mut self,
23228 context: types::glx::Context,
23229 visual: types::Visualid,
23230 screen: types::Card32,
23231 share_list: types::glx::Context,
23232 is_direct: types::Bool,
23233 ) -> futures::CheckedSendRequest<'this, Self, ()> {
23234 let request = types::glx::CreateContextRequest {
23235 context,
23236 visual,
23237 screen,
23238 share_list,
23239 is_direct,
23240 };
23241 let cookie = self.send_void_request(request, false);
23242 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
23243 res
23244 }
23245 #[cfg(feature = "glx")]
23246 fn glx_destroy_context<'this>(
23247 &'this mut self,
23248 context: types::glx::Context,
23249 ) -> futures::SendRequest<'this, Self, ()> {
23250 let span = tracing::info_span!(
23251 "glx_destroy_context",
23252 context = ?context,
23253 );
23254 let request = types::glx::DestroyContextRequest { context };
23255 let cookie = self.send_void_request(request, true).with_span(span);
23256 cookie
23257 }
23258 #[cfg(feature = "glx")]
23259 fn glx_destroy_context_checked<'this>(
23260 &'this mut self,
23261 context: types::glx::Context,
23262 ) -> futures::CheckedSendRequest<'this, Self, ()> {
23263 let request = types::glx::DestroyContextRequest { context };
23264 let cookie = self.send_void_request(request, false);
23265 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
23266 res
23267 }
23268 #[cfg(feature = "glx")]
23269 fn glx_make_current<'this>(
23270 &'this mut self,
23271 drawable: types::glx::Drawable,
23272 context: types::glx::Context,
23273 old_context_tag: types::ContextTag,
23274 ) -> futures::SendRequest<'this, Self, types::glx::MakeCurrentReply> {
23275 let span = tracing::info_span!(
23276 "glx_make_current",
23277 drawable = ?drawable,
23278 context = ?context,
23279 old_context_tag = ?old_context_tag,
23280 );
23281 let request = types::glx::MakeCurrentRequest {
23282 drawable,
23283 context,
23284 old_context_tag,
23285 };
23286 let cookie = self.send_reply_request(request).with_span(span);
23287 cookie
23288 }
23289 #[cfg(feature = "glx")]
23290 fn glx_make_current_immediate<'this>(
23291 &'this mut self,
23292 drawable: types::glx::Drawable,
23293 context: types::glx::Context,
23294 old_context_tag: types::ContextTag,
23295 ) -> futures::CheckedSendRequest<'this, Self, types::glx::MakeCurrentReply> {
23296 let request = types::glx::MakeCurrentRequest {
23297 drawable,
23298 context,
23299 old_context_tag,
23300 };
23301 let cookie = self.send_reply_request(request);
23302 let res: futures::CheckedSendRequest<'this, Self, types::glx::MakeCurrentReply> =
23303 cookie.into();
23304 res
23305 }
23306 #[cfg(feature = "glx")]
23307 fn glx_is_direct<'this>(
23308 &'this mut self,
23309 context: types::glx::Context,
23310 ) -> futures::SendRequest<'this, Self, types::glx::IsDirectReply> {
23311 let span = tracing::info_span!(
23312 "glx_is_direct",
23313 context = ?context,
23314 );
23315 let request = types::glx::IsDirectRequest { context };
23316 let cookie = self.send_reply_request(request).with_span(span);
23317 cookie
23318 }
23319 #[cfg(feature = "glx")]
23320 fn glx_is_direct_immediate<'this>(
23321 &'this mut self,
23322 context: types::glx::Context,
23323 ) -> futures::CheckedSendRequest<'this, Self, types::glx::IsDirectReply> {
23324 let request = types::glx::IsDirectRequest { context };
23325 let cookie = self.send_reply_request(request);
23326 let res: futures::CheckedSendRequest<'this, Self, types::glx::IsDirectReply> =
23327 cookie.into();
23328 res
23329 }
23330 #[cfg(feature = "glx")]
23331 fn glx_query_version<'this>(
23332 &'this mut self,
23333 major_version: types::Card32,
23334 minor_version: types::Card32,
23335 ) -> futures::SendRequest<'this, Self, types::glx::QueryVersionReply> {
23336 let span = tracing::info_span!(
23337 "glx_query_version",
23338 major_version = ?major_version,
23339 minor_version = ?minor_version,
23340 );
23341 let request = types::glx::QueryVersionRequest {
23342 major_version,
23343 minor_version,
23344 };
23345 let cookie = self.send_reply_request(request).with_span(span);
23346 cookie
23347 }
23348 #[cfg(feature = "glx")]
23349 fn glx_query_version_immediate<'this>(
23350 &'this mut self,
23351 major_version: types::Card32,
23352 minor_version: types::Card32,
23353 ) -> futures::CheckedSendRequest<'this, Self, types::glx::QueryVersionReply> {
23354 let request = types::glx::QueryVersionRequest {
23355 major_version,
23356 minor_version,
23357 };
23358 let cookie = self.send_reply_request(request);
23359 let res: futures::CheckedSendRequest<'this, Self, types::glx::QueryVersionReply> =
23360 cookie.into();
23361 res
23362 }
23363 #[cfg(feature = "glx")]
23364 fn glx_wait_gl<'this>(
23365 &'this mut self,
23366 context_tag: types::ContextTag,
23367 ) -> futures::SendRequest<'this, Self, ()> {
23368 let span = tracing::info_span!(
23369 "glx_wait_gl",
23370 context_tag = ?context_tag,
23371 );
23372 let request = types::glx::WaitGLRequest { context_tag };
23373 let cookie = self.send_void_request(request, true).with_span(span);
23374 cookie
23375 }
23376 #[cfg(feature = "glx")]
23377 fn glx_wait_gl_checked<'this>(
23378 &'this mut self,
23379 context_tag: types::ContextTag,
23380 ) -> futures::CheckedSendRequest<'this, Self, ()> {
23381 let request = types::glx::WaitGLRequest { context_tag };
23382 let cookie = self.send_void_request(request, false);
23383 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
23384 res
23385 }
23386 #[cfg(feature = "glx")]
23387 fn glx_wait_x<'this>(
23388 &'this mut self,
23389 context_tag: types::ContextTag,
23390 ) -> futures::SendRequest<'this, Self, ()> {
23391 let span = tracing::info_span!(
23392 "glx_wait_x",
23393 context_tag = ?context_tag,
23394 );
23395 let request = types::glx::WaitXRequest { context_tag };
23396 let cookie = self.send_void_request(request, true).with_span(span);
23397 cookie
23398 }
23399 #[cfg(feature = "glx")]
23400 fn glx_wait_x_checked<'this>(
23401 &'this mut self,
23402 context_tag: types::ContextTag,
23403 ) -> futures::CheckedSendRequest<'this, Self, ()> {
23404 let request = types::glx::WaitXRequest { context_tag };
23405 let cookie = self.send_void_request(request, false);
23406 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
23407 res
23408 }
23409 #[cfg(feature = "glx")]
23410 fn glx_copy_context<'this>(
23411 &'this mut self,
23412 src: types::glx::Context,
23413 dest: types::glx::Context,
23414 mask: types::Card32,
23415 src_context_tag: types::ContextTag,
23416 ) -> futures::SendRequest<'this, Self, ()> {
23417 let span = tracing::info_span!(
23418 "glx_copy_context",
23419 src = ?src,
23420 dest = ?dest,
23421 mask = ?mask,
23422 src_context_tag = ?src_context_tag,
23423 );
23424 let request = types::glx::CopyContextRequest {
23425 src,
23426 dest,
23427 mask,
23428 src_context_tag,
23429 };
23430 let cookie = self.send_void_request(request, true).with_span(span);
23431 cookie
23432 }
23433 #[cfg(feature = "glx")]
23434 fn glx_copy_context_checked<'this>(
23435 &'this mut self,
23436 src: types::glx::Context,
23437 dest: types::glx::Context,
23438 mask: types::Card32,
23439 src_context_tag: types::ContextTag,
23440 ) -> futures::CheckedSendRequest<'this, Self, ()> {
23441 let request = types::glx::CopyContextRequest {
23442 src,
23443 dest,
23444 mask,
23445 src_context_tag,
23446 };
23447 let cookie = self.send_void_request(request, false);
23448 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
23449 res
23450 }
23451 #[cfg(feature = "glx")]
23452 fn glx_swap_buffers<'this>(
23453 &'this mut self,
23454 context_tag: types::ContextTag,
23455 drawable: types::glx::Drawable,
23456 ) -> futures::SendRequest<'this, Self, ()> {
23457 let span = tracing::info_span!(
23458 "glx_swap_buffers",
23459 context_tag = ?context_tag,
23460 drawable = ?drawable,
23461 );
23462 let request = types::glx::SwapBuffersRequest {
23463 context_tag,
23464 drawable,
23465 };
23466 let cookie = self.send_void_request(request, true).with_span(span);
23467 cookie
23468 }
23469 #[cfg(feature = "glx")]
23470 fn glx_swap_buffers_checked<'this>(
23471 &'this mut self,
23472 context_tag: types::ContextTag,
23473 drawable: types::glx::Drawable,
23474 ) -> futures::CheckedSendRequest<'this, Self, ()> {
23475 let request = types::glx::SwapBuffersRequest {
23476 context_tag,
23477 drawable,
23478 };
23479 let cookie = self.send_void_request(request, false);
23480 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
23481 res
23482 }
23483 #[cfg(feature = "glx")]
23484 fn glx_use_x_font<'this>(
23485 &'this mut self,
23486 context_tag: types::ContextTag,
23487 font: types::Font,
23488 first: types::Card32,
23489 count: types::Card32,
23490 list_base: types::Card32,
23491 ) -> futures::SendRequest<'this, Self, ()> {
23492 let span = tracing::info_span!(
23493 "glx_use_x_font",
23494 context_tag = ?context_tag,
23495 font = ?font,
23496 first = ?first,
23497 count = ?count,
23498 list_base = ?list_base,
23499 );
23500 let request = types::glx::UseXFontRequest {
23501 context_tag,
23502 font,
23503 first,
23504 count,
23505 list_base,
23506 };
23507 let cookie = self.send_void_request(request, true).with_span(span);
23508 cookie
23509 }
23510 #[cfg(feature = "glx")]
23511 fn glx_use_x_font_checked<'this>(
23512 &'this mut self,
23513 context_tag: types::ContextTag,
23514 font: types::Font,
23515 first: types::Card32,
23516 count: types::Card32,
23517 list_base: types::Card32,
23518 ) -> futures::CheckedSendRequest<'this, Self, ()> {
23519 let request = types::glx::UseXFontRequest {
23520 context_tag,
23521 font,
23522 first,
23523 count,
23524 list_base,
23525 };
23526 let cookie = self.send_void_request(request, false);
23527 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
23528 res
23529 }
23530 #[cfg(feature = "glx")]
23531 fn glx_create_glx_pixmap<'this>(
23532 &'this mut self,
23533 screen: types::Card32,
23534 visual: types::Visualid,
23535 pixmap: types::xproto::Pixmap,
23536 glx_pixmap: types::glx::Pixmap,
23537 ) -> futures::SendRequest<'this, Self, ()> {
23538 let span = tracing::info_span!(
23539 "glx_create_glx_pixmap",
23540 screen = ?screen,
23541 visual = ?visual,
23542 pixmap = ?pixmap,
23543 glx_pixmap = ?glx_pixmap,
23544 );
23545 let request = types::glx::CreateGLXPixmapRequest {
23546 screen,
23547 visual,
23548 pixmap,
23549 glx_pixmap,
23550 };
23551 let cookie = self.send_void_request(request, true).with_span(span);
23552 cookie
23553 }
23554 #[cfg(feature = "glx")]
23555 fn glx_create_glx_pixmap_checked<'this>(
23556 &'this mut self,
23557 screen: types::Card32,
23558 visual: types::Visualid,
23559 pixmap: types::xproto::Pixmap,
23560 glx_pixmap: types::glx::Pixmap,
23561 ) -> futures::CheckedSendRequest<'this, Self, ()> {
23562 let request = types::glx::CreateGLXPixmapRequest {
23563 screen,
23564 visual,
23565 pixmap,
23566 glx_pixmap,
23567 };
23568 let cookie = self.send_void_request(request, false);
23569 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
23570 res
23571 }
23572 #[cfg(feature = "glx")]
23573 fn glx_get_visual_configs<'this>(
23574 &'this mut self,
23575 screen: types::Card32,
23576 ) -> futures::SendRequest<'this, Self, types::glx::GetVisualConfigsReply> {
23577 let span = tracing::info_span!(
23578 "glx_get_visual_configs",
23579 screen = ?screen,
23580 );
23581 let request = types::glx::GetVisualConfigsRequest { screen };
23582 let cookie = self.send_reply_request(request).with_span(span);
23583 cookie
23584 }
23585 #[cfg(feature = "glx")]
23586 fn glx_get_visual_configs_immediate<'this>(
23587 &'this mut self,
23588 screen: types::Card32,
23589 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetVisualConfigsReply> {
23590 let request = types::glx::GetVisualConfigsRequest { screen };
23591 let cookie = self.send_reply_request(request);
23592 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetVisualConfigsReply> =
23593 cookie.into();
23594 res
23595 }
23596 #[cfg(feature = "glx")]
23597 fn glx_destroy_glx_pixmap<'this>(
23598 &'this mut self,
23599 glx_pixmap: types::glx::Pixmap,
23600 ) -> futures::SendRequest<'this, Self, ()> {
23601 let span = tracing::info_span!(
23602 "glx_destroy_glx_pixmap",
23603 glx_pixmap = ?glx_pixmap,
23604 );
23605 let request = types::glx::DestroyGLXPixmapRequest { glx_pixmap };
23606 let cookie = self.send_void_request(request, true).with_span(span);
23607 cookie
23608 }
23609 #[cfg(feature = "glx")]
23610 fn glx_destroy_glx_pixmap_checked<'this>(
23611 &'this mut self,
23612 glx_pixmap: types::glx::Pixmap,
23613 ) -> futures::CheckedSendRequest<'this, Self, ()> {
23614 let request = types::glx::DestroyGLXPixmapRequest { glx_pixmap };
23615 let cookie = self.send_void_request(request, false);
23616 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
23617 res
23618 }
23619 #[cfg(feature = "glx")]
23620 fn glx_vendor_private<'this>(
23621 &'this mut self,
23622 vendor_code: types::Card32,
23623 context_tag: types::ContextTag,
23624 data: impl AsRef<[types::Byte]>,
23625 ) -> futures::SendRequest<'this, Self, ()> {
23626 let span = tracing::info_span!(
23627 "glx_vendor_private",
23628 vendor_code = ?vendor_code,
23629 context_tag = ?context_tag,
23630 );
23631 let request = types::glx::VendorPrivateRequest {
23632 vendor_code,
23633 context_tag,
23634 data: Cow::Borrowed(data.as_ref()),
23635 };
23636 let cookie = self.send_void_request(request, true).with_span(span);
23637 cookie
23638 }
23639 #[cfg(feature = "glx")]
23640 fn glx_vendor_private_checked<'this>(
23641 &'this mut self,
23642 vendor_code: types::Card32,
23643 context_tag: types::ContextTag,
23644 data: impl AsRef<[types::Byte]>,
23645 ) -> futures::CheckedSendRequest<'this, Self, ()> {
23646 let request = types::glx::VendorPrivateRequest {
23647 vendor_code,
23648 context_tag,
23649 data: Cow::Borrowed(data.as_ref()),
23650 };
23651 let cookie = self.send_void_request(request, false);
23652 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
23653 res
23654 }
23655 #[cfg(feature = "glx")]
23656 fn glx_vendor_private_with_reply<'this>(
23657 &'this mut self,
23658 vendor_code: types::Card32,
23659 context_tag: types::ContextTag,
23660 data: impl AsRef<[types::Byte]>,
23661 ) -> futures::SendRequest<'this, Self, types::glx::VendorPrivateWithReplyReply> {
23662 let span = tracing::info_span!(
23663 "glx_vendor_private_with_reply",
23664 vendor_code = ?vendor_code,
23665 context_tag = ?context_tag,
23666 );
23667 let request = types::glx::VendorPrivateWithReplyRequest {
23668 vendor_code,
23669 context_tag,
23670 data: Cow::Borrowed(data.as_ref()),
23671 };
23672 let cookie = self.send_reply_request(request).with_span(span);
23673 cookie
23674 }
23675 #[cfg(feature = "glx")]
23676 fn glx_vendor_private_with_reply_immediate<'this>(
23677 &'this mut self,
23678 vendor_code: types::Card32,
23679 context_tag: types::ContextTag,
23680 data: impl AsRef<[types::Byte]>,
23681 ) -> futures::CheckedSendRequest<'this, Self, types::glx::VendorPrivateWithReplyReply> {
23682 let request = types::glx::VendorPrivateWithReplyRequest {
23683 vendor_code,
23684 context_tag,
23685 data: Cow::Borrowed(data.as_ref()),
23686 };
23687 let cookie = self.send_reply_request(request);
23688 let res: futures::CheckedSendRequest<'this, Self, types::glx::VendorPrivateWithReplyReply> =
23689 cookie.into();
23690 res
23691 }
23692 #[cfg(feature = "glx")]
23693 fn glx_query_extensions_string<'this>(
23694 &'this mut self,
23695 screen: types::Card32,
23696 ) -> futures::SendRequest<'this, Self, types::glx::QueryExtensionsStringReply> {
23697 let span = tracing::info_span!(
23698 "glx_query_extensions_string",
23699 screen = ?screen,
23700 );
23701 let request = types::glx::QueryExtensionsStringRequest { screen };
23702 let cookie = self.send_reply_request(request).with_span(span);
23703 cookie
23704 }
23705 #[cfg(feature = "glx")]
23706 fn glx_query_extensions_string_immediate<'this>(
23707 &'this mut self,
23708 screen: types::Card32,
23709 ) -> futures::CheckedSendRequest<'this, Self, types::glx::QueryExtensionsStringReply> {
23710 let request = types::glx::QueryExtensionsStringRequest { screen };
23711 let cookie = self.send_reply_request(request);
23712 let res: futures::CheckedSendRequest<'this, Self, types::glx::QueryExtensionsStringReply> =
23713 cookie.into();
23714 res
23715 }
23716 #[cfg(feature = "glx")]
23717 fn glx_query_server_string<'this>(
23718 &'this mut self,
23719 screen: types::Card32,
23720 name: types::Card32,
23721 ) -> futures::SendRequest<'this, Self, types::glx::QueryServerStringReply> {
23722 let span = tracing::info_span!(
23723 "glx_query_server_string",
23724 screen = ?screen,
23725 name = ?name,
23726 );
23727 let request = types::glx::QueryServerStringRequest { screen, name };
23728 let cookie = self.send_reply_request(request).with_span(span);
23729 cookie
23730 }
23731 #[cfg(feature = "glx")]
23732 fn glx_query_server_string_immediate<'this>(
23733 &'this mut self,
23734 screen: types::Card32,
23735 name: types::Card32,
23736 ) -> futures::CheckedSendRequest<'this, Self, types::glx::QueryServerStringReply> {
23737 let request = types::glx::QueryServerStringRequest { screen, name };
23738 let cookie = self.send_reply_request(request);
23739 let res: futures::CheckedSendRequest<'this, Self, types::glx::QueryServerStringReply> =
23740 cookie.into();
23741 res
23742 }
23743 #[cfg(feature = "glx")]
23744 fn glx_client_info<'this>(
23745 &'this mut self,
23746 major_version: types::Card32,
23747 minor_version: types::Card32,
23748 string: impl AsRef<[types::Char]>,
23749 ) -> futures::SendRequest<'this, Self, ()> {
23750 let span = tracing::info_span!(
23751 "glx_client_info",
23752 major_version = ?major_version,
23753 minor_version = ?minor_version,
23754 );
23755 let request = types::glx::ClientInfoRequest {
23756 major_version,
23757 minor_version,
23758 string: Cow::Borrowed(string.as_ref()),
23759 };
23760 let cookie = self.send_void_request(request, true).with_span(span);
23761 cookie
23762 }
23763 #[cfg(feature = "glx")]
23764 fn glx_client_info_checked<'this>(
23765 &'this mut self,
23766 major_version: types::Card32,
23767 minor_version: types::Card32,
23768 string: impl AsRef<[types::Char]>,
23769 ) -> futures::CheckedSendRequest<'this, Self, ()> {
23770 let request = types::glx::ClientInfoRequest {
23771 major_version,
23772 minor_version,
23773 string: Cow::Borrowed(string.as_ref()),
23774 };
23775 let cookie = self.send_void_request(request, false);
23776 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
23777 res
23778 }
23779 #[cfg(feature = "glx")]
23780 fn glx_get_fb_configs<'this>(
23781 &'this mut self,
23782 screen: types::Card32,
23783 ) -> futures::SendRequest<'this, Self, types::glx::GetFBConfigsReply> {
23784 let span = tracing::info_span!(
23785 "glx_get_fb_configs",
23786 screen = ?screen,
23787 );
23788 let request = types::glx::GetFBConfigsRequest { screen };
23789 let cookie = self.send_reply_request(request).with_span(span);
23790 cookie
23791 }
23792 #[cfg(feature = "glx")]
23793 fn glx_get_fb_configs_immediate<'this>(
23794 &'this mut self,
23795 screen: types::Card32,
23796 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetFBConfigsReply> {
23797 let request = types::glx::GetFBConfigsRequest { screen };
23798 let cookie = self.send_reply_request(request);
23799 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetFBConfigsReply> =
23800 cookie.into();
23801 res
23802 }
23803 #[cfg(feature = "glx")]
23804 fn glx_create_pixmap<'this>(
23805 &'this mut self,
23806 screen: types::Card32,
23807 fbconfig: types::Fbconfig,
23808 pixmap: types::xproto::Pixmap,
23809 glx_pixmap: types::glx::Pixmap,
23810 attribs: impl AsRef<[types::Card32]>,
23811 ) -> futures::SendRequest<'this, Self, ()> {
23812 let span = tracing::info_span!(
23813 "glx_create_pixmap",
23814 screen = ?screen,
23815 fbconfig = ?fbconfig,
23816 pixmap = ?pixmap,
23817 glx_pixmap = ?glx_pixmap,
23818 );
23819 let request = types::glx::CreatePixmapRequest {
23820 screen,
23821 fbconfig,
23822 pixmap,
23823 glx_pixmap,
23824 attribs: Cow::Borrowed(attribs.as_ref()),
23825 };
23826 let cookie = self.send_void_request(request, true).with_span(span);
23827 cookie
23828 }
23829 #[cfg(feature = "glx")]
23830 fn glx_create_pixmap_checked<'this>(
23831 &'this mut self,
23832 screen: types::Card32,
23833 fbconfig: types::Fbconfig,
23834 pixmap: types::xproto::Pixmap,
23835 glx_pixmap: types::glx::Pixmap,
23836 attribs: impl AsRef<[types::Card32]>,
23837 ) -> futures::CheckedSendRequest<'this, Self, ()> {
23838 let request = types::glx::CreatePixmapRequest {
23839 screen,
23840 fbconfig,
23841 pixmap,
23842 glx_pixmap,
23843 attribs: Cow::Borrowed(attribs.as_ref()),
23844 };
23845 let cookie = self.send_void_request(request, false);
23846 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
23847 res
23848 }
23849 #[cfg(feature = "glx")]
23850 fn glx_destroy_pixmap<'this>(
23851 &'this mut self,
23852 glx_pixmap: types::glx::Pixmap,
23853 ) -> futures::SendRequest<'this, Self, ()> {
23854 let span = tracing::info_span!(
23855 "glx_destroy_pixmap",
23856 glx_pixmap = ?glx_pixmap,
23857 );
23858 let request = types::glx::DestroyPixmapRequest { glx_pixmap };
23859 let cookie = self.send_void_request(request, true).with_span(span);
23860 cookie
23861 }
23862 #[cfg(feature = "glx")]
23863 fn glx_destroy_pixmap_checked<'this>(
23864 &'this mut self,
23865 glx_pixmap: types::glx::Pixmap,
23866 ) -> futures::CheckedSendRequest<'this, Self, ()> {
23867 let request = types::glx::DestroyPixmapRequest { glx_pixmap };
23868 let cookie = self.send_void_request(request, false);
23869 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
23870 res
23871 }
23872 #[cfg(feature = "glx")]
23873 fn glx_create_new_context<'this>(
23874 &'this mut self,
23875 context: types::glx::Context,
23876 fbconfig: types::Fbconfig,
23877 screen: types::Card32,
23878 render_type: types::Card32,
23879 share_list: types::glx::Context,
23880 is_direct: types::Bool,
23881 ) -> futures::SendRequest<'this, Self, ()> {
23882 let span = tracing::info_span!(
23883 "glx_create_new_context",
23884 context = ?context,
23885 fbconfig = ?fbconfig,
23886 screen = ?screen,
23887 render_type = ?render_type,
23888 share_list = ?share_list,
23889 is_direct = ?is_direct,
23890 );
23891 let request = types::glx::CreateNewContextRequest {
23892 context,
23893 fbconfig,
23894 screen,
23895 render_type,
23896 share_list,
23897 is_direct,
23898 };
23899 let cookie = self.send_void_request(request, true).with_span(span);
23900 cookie
23901 }
23902 #[cfg(feature = "glx")]
23903 fn glx_create_new_context_checked<'this>(
23904 &'this mut self,
23905 context: types::glx::Context,
23906 fbconfig: types::Fbconfig,
23907 screen: types::Card32,
23908 render_type: types::Card32,
23909 share_list: types::glx::Context,
23910 is_direct: types::Bool,
23911 ) -> futures::CheckedSendRequest<'this, Self, ()> {
23912 let request = types::glx::CreateNewContextRequest {
23913 context,
23914 fbconfig,
23915 screen,
23916 render_type,
23917 share_list,
23918 is_direct,
23919 };
23920 let cookie = self.send_void_request(request, false);
23921 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
23922 res
23923 }
23924 #[cfg(feature = "glx")]
23925 fn glx_query_context<'this>(
23926 &'this mut self,
23927 context: types::glx::Context,
23928 ) -> futures::SendRequest<'this, Self, types::glx::QueryContextReply> {
23929 let span = tracing::info_span!(
23930 "glx_query_context",
23931 context = ?context,
23932 );
23933 let request = types::glx::QueryContextRequest { context };
23934 let cookie = self.send_reply_request(request).with_span(span);
23935 cookie
23936 }
23937 #[cfg(feature = "glx")]
23938 fn glx_query_context_immediate<'this>(
23939 &'this mut self,
23940 context: types::glx::Context,
23941 ) -> futures::CheckedSendRequest<'this, Self, types::glx::QueryContextReply> {
23942 let request = types::glx::QueryContextRequest { context };
23943 let cookie = self.send_reply_request(request);
23944 let res: futures::CheckedSendRequest<'this, Self, types::glx::QueryContextReply> =
23945 cookie.into();
23946 res
23947 }
23948 #[cfg(feature = "glx")]
23949 fn glx_make_context_current<'this>(
23950 &'this mut self,
23951 old_context_tag: types::ContextTag,
23952 drawable: types::glx::Drawable,
23953 read_drawable: types::glx::Drawable,
23954 context: types::glx::Context,
23955 ) -> futures::SendRequest<'this, Self, types::glx::MakeContextCurrentReply> {
23956 let span = tracing::info_span!(
23957 "glx_make_context_current",
23958 old_context_tag = ?old_context_tag,
23959 drawable = ?drawable,
23960 read_drawable = ?read_drawable,
23961 context = ?context,
23962 );
23963 let request = types::glx::MakeContextCurrentRequest {
23964 old_context_tag,
23965 drawable,
23966 read_drawable,
23967 context,
23968 };
23969 let cookie = self.send_reply_request(request).with_span(span);
23970 cookie
23971 }
23972 #[cfg(feature = "glx")]
23973 fn glx_make_context_current_immediate<'this>(
23974 &'this mut self,
23975 old_context_tag: types::ContextTag,
23976 drawable: types::glx::Drawable,
23977 read_drawable: types::glx::Drawable,
23978 context: types::glx::Context,
23979 ) -> futures::CheckedSendRequest<'this, Self, types::glx::MakeContextCurrentReply> {
23980 let request = types::glx::MakeContextCurrentRequest {
23981 old_context_tag,
23982 drawable,
23983 read_drawable,
23984 context,
23985 };
23986 let cookie = self.send_reply_request(request);
23987 let res: futures::CheckedSendRequest<'this, Self, types::glx::MakeContextCurrentReply> =
23988 cookie.into();
23989 res
23990 }
23991 #[cfg(feature = "glx")]
23992 fn glx_create_pbuffer<'this>(
23993 &'this mut self,
23994 screen: types::Card32,
23995 fbconfig: types::Fbconfig,
23996 pbuffer: types::Pbuffer,
23997 attribs: impl AsRef<[types::Card32]>,
23998 ) -> futures::SendRequest<'this, Self, ()> {
23999 let span = tracing::info_span!(
24000 "glx_create_pbuffer",
24001 screen = ?screen,
24002 fbconfig = ?fbconfig,
24003 pbuffer = ?pbuffer,
24004 );
24005 let request = types::glx::CreatePbufferRequest {
24006 screen,
24007 fbconfig,
24008 pbuffer,
24009 attribs: Cow::Borrowed(attribs.as_ref()),
24010 };
24011 let cookie = self.send_void_request(request, true).with_span(span);
24012 cookie
24013 }
24014 #[cfg(feature = "glx")]
24015 fn glx_create_pbuffer_checked<'this>(
24016 &'this mut self,
24017 screen: types::Card32,
24018 fbconfig: types::Fbconfig,
24019 pbuffer: types::Pbuffer,
24020 attribs: impl AsRef<[types::Card32]>,
24021 ) -> futures::CheckedSendRequest<'this, Self, ()> {
24022 let request = types::glx::CreatePbufferRequest {
24023 screen,
24024 fbconfig,
24025 pbuffer,
24026 attribs: Cow::Borrowed(attribs.as_ref()),
24027 };
24028 let cookie = self.send_void_request(request, false);
24029 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
24030 res
24031 }
24032 #[cfg(feature = "glx")]
24033 fn glx_destroy_pbuffer<'this>(
24034 &'this mut self,
24035 pbuffer: types::Pbuffer,
24036 ) -> futures::SendRequest<'this, Self, ()> {
24037 let span = tracing::info_span!(
24038 "glx_destroy_pbuffer",
24039 pbuffer = ?pbuffer,
24040 );
24041 let request = types::glx::DestroyPbufferRequest { pbuffer };
24042 let cookie = self.send_void_request(request, true).with_span(span);
24043 cookie
24044 }
24045 #[cfg(feature = "glx")]
24046 fn glx_destroy_pbuffer_checked<'this>(
24047 &'this mut self,
24048 pbuffer: types::Pbuffer,
24049 ) -> futures::CheckedSendRequest<'this, Self, ()> {
24050 let request = types::glx::DestroyPbufferRequest { pbuffer };
24051 let cookie = self.send_void_request(request, false);
24052 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
24053 res
24054 }
24055 #[cfg(feature = "glx")]
24056 fn glx_get_drawable_attributes<'this>(
24057 &'this mut self,
24058 drawable: types::glx::Drawable,
24059 ) -> futures::SendRequest<'this, Self, types::glx::GetDrawableAttributesReply> {
24060 let span = tracing::info_span!(
24061 "glx_get_drawable_attributes",
24062 drawable = ?drawable,
24063 );
24064 let request = types::glx::GetDrawableAttributesRequest { drawable };
24065 let cookie = self.send_reply_request(request).with_span(span);
24066 cookie
24067 }
24068 #[cfg(feature = "glx")]
24069 fn glx_get_drawable_attributes_immediate<'this>(
24070 &'this mut self,
24071 drawable: types::glx::Drawable,
24072 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetDrawableAttributesReply> {
24073 let request = types::glx::GetDrawableAttributesRequest { drawable };
24074 let cookie = self.send_reply_request(request);
24075 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetDrawableAttributesReply> =
24076 cookie.into();
24077 res
24078 }
24079 #[cfg(feature = "glx")]
24080 fn glx_change_drawable_attributes<'this>(
24081 &'this mut self,
24082 drawable: types::glx::Drawable,
24083 attribs: impl AsRef<[types::Card32]>,
24084 ) -> futures::SendRequest<'this, Self, ()> {
24085 let span = tracing::info_span!(
24086 "glx_change_drawable_attributes",
24087 drawable = ?drawable,
24088 );
24089 let request = types::glx::ChangeDrawableAttributesRequest {
24090 drawable,
24091 attribs: Cow::Borrowed(attribs.as_ref()),
24092 };
24093 let cookie = self.send_void_request(request, true).with_span(span);
24094 cookie
24095 }
24096 #[cfg(feature = "glx")]
24097 fn glx_change_drawable_attributes_checked<'this>(
24098 &'this mut self,
24099 drawable: types::glx::Drawable,
24100 attribs: impl AsRef<[types::Card32]>,
24101 ) -> futures::CheckedSendRequest<'this, Self, ()> {
24102 let request = types::glx::ChangeDrawableAttributesRequest {
24103 drawable,
24104 attribs: Cow::Borrowed(attribs.as_ref()),
24105 };
24106 let cookie = self.send_void_request(request, false);
24107 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
24108 res
24109 }
24110 #[cfg(feature = "glx")]
24111 fn glx_create_window<'this>(
24112 &'this mut self,
24113 screen: types::Card32,
24114 fbconfig: types::Fbconfig,
24115 window: types::xproto::Window,
24116 glx_window: types::glx::Window,
24117 attribs: impl AsRef<[types::Card32]>,
24118 ) -> futures::SendRequest<'this, Self, ()> {
24119 let span = tracing::info_span!(
24120 "glx_create_window",
24121 screen = ?screen,
24122 fbconfig = ?fbconfig,
24123 window = ?window,
24124 glx_window = ?glx_window,
24125 );
24126 let request = types::glx::CreateWindowRequest {
24127 screen,
24128 fbconfig,
24129 window,
24130 glx_window,
24131 attribs: Cow::Borrowed(attribs.as_ref()),
24132 };
24133 let cookie = self.send_void_request(request, true).with_span(span);
24134 cookie
24135 }
24136 #[cfg(feature = "glx")]
24137 fn glx_create_window_checked<'this>(
24138 &'this mut self,
24139 screen: types::Card32,
24140 fbconfig: types::Fbconfig,
24141 window: types::xproto::Window,
24142 glx_window: types::glx::Window,
24143 attribs: impl AsRef<[types::Card32]>,
24144 ) -> futures::CheckedSendRequest<'this, Self, ()> {
24145 let request = types::glx::CreateWindowRequest {
24146 screen,
24147 fbconfig,
24148 window,
24149 glx_window,
24150 attribs: Cow::Borrowed(attribs.as_ref()),
24151 };
24152 let cookie = self.send_void_request(request, false);
24153 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
24154 res
24155 }
24156 #[cfg(feature = "glx")]
24157 fn glx_delete_window<'this>(
24158 &'this mut self,
24159 glxwindow: types::glx::Window,
24160 ) -> futures::SendRequest<'this, Self, ()> {
24161 let span = tracing::info_span!(
24162 "glx_delete_window",
24163 glxwindow = ?glxwindow,
24164 );
24165 let request = types::glx::DeleteWindowRequest { glxwindow };
24166 let cookie = self.send_void_request(request, true).with_span(span);
24167 cookie
24168 }
24169 #[cfg(feature = "glx")]
24170 fn glx_delete_window_checked<'this>(
24171 &'this mut self,
24172 glxwindow: types::glx::Window,
24173 ) -> futures::CheckedSendRequest<'this, Self, ()> {
24174 let request = types::glx::DeleteWindowRequest { glxwindow };
24175 let cookie = self.send_void_request(request, false);
24176 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
24177 res
24178 }
24179 #[cfg(feature = "glx")]
24180 fn glx_set_client_info_arb<'this>(
24181 &'this mut self,
24182 major_version: types::Card32,
24183 minor_version: types::Card32,
24184 gl_versions: impl AsRef<[types::Card32]>,
24185 gl_extension_string: impl AsRef<[types::Char]>,
24186 glx_extension_string: impl AsRef<[types::Char]>,
24187 ) -> futures::SendRequest<'this, Self, ()> {
24188 let span = tracing::info_span!(
24189 "glx_set_client_info_arb",
24190 major_version = ?major_version,
24191 minor_version = ?minor_version,
24192 );
24193 let request = types::glx::SetClientInfoARBRequest {
24194 major_version,
24195 minor_version,
24196 gl_versions: Cow::Borrowed(gl_versions.as_ref()),
24197 gl_extension_string: Cow::Borrowed(gl_extension_string.as_ref()),
24198 glx_extension_string: Cow::Borrowed(glx_extension_string.as_ref()),
24199 };
24200 let cookie = self.send_void_request(request, true).with_span(span);
24201 cookie
24202 }
24203 #[cfg(feature = "glx")]
24204 fn glx_set_client_info_arb_checked<'this>(
24205 &'this mut self,
24206 major_version: types::Card32,
24207 minor_version: types::Card32,
24208 gl_versions: impl AsRef<[types::Card32]>,
24209 gl_extension_string: impl AsRef<[types::Char]>,
24210 glx_extension_string: impl AsRef<[types::Char]>,
24211 ) -> futures::CheckedSendRequest<'this, Self, ()> {
24212 let request = types::glx::SetClientInfoARBRequest {
24213 major_version,
24214 minor_version,
24215 gl_versions: Cow::Borrowed(gl_versions.as_ref()),
24216 gl_extension_string: Cow::Borrowed(gl_extension_string.as_ref()),
24217 glx_extension_string: Cow::Borrowed(glx_extension_string.as_ref()),
24218 };
24219 let cookie = self.send_void_request(request, false);
24220 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
24221 res
24222 }
24223 #[cfg(feature = "glx")]
24224 fn glx_create_context_attribs_arb<'this>(
24225 &'this mut self,
24226 context: types::glx::Context,
24227 fbconfig: types::Fbconfig,
24228 screen: types::Card32,
24229 share_list: types::glx::Context,
24230 is_direct: types::Bool,
24231 attribs: impl AsRef<[types::Card32]>,
24232 ) -> futures::SendRequest<'this, Self, ()> {
24233 let span = tracing::info_span!(
24234 "glx_create_context_attribs_arb",
24235 context = ?context,
24236 fbconfig = ?fbconfig,
24237 screen = ?screen,
24238 share_list = ?share_list,
24239 is_direct = ?is_direct,
24240 );
24241 let request = types::glx::CreateContextAttribsARBRequest {
24242 context,
24243 fbconfig,
24244 screen,
24245 share_list,
24246 is_direct,
24247 attribs: Cow::Borrowed(attribs.as_ref()),
24248 };
24249 let cookie = self.send_void_request(request, true).with_span(span);
24250 cookie
24251 }
24252 #[cfg(feature = "glx")]
24253 fn glx_create_context_attribs_arb_checked<'this>(
24254 &'this mut self,
24255 context: types::glx::Context,
24256 fbconfig: types::Fbconfig,
24257 screen: types::Card32,
24258 share_list: types::glx::Context,
24259 is_direct: types::Bool,
24260 attribs: impl AsRef<[types::Card32]>,
24261 ) -> futures::CheckedSendRequest<'this, Self, ()> {
24262 let request = types::glx::CreateContextAttribsARBRequest {
24263 context,
24264 fbconfig,
24265 screen,
24266 share_list,
24267 is_direct,
24268 attribs: Cow::Borrowed(attribs.as_ref()),
24269 };
24270 let cookie = self.send_void_request(request, false);
24271 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
24272 res
24273 }
24274 #[cfg(feature = "glx")]
24275 fn glx_set_client_info2_arb<'this>(
24276 &'this mut self,
24277 major_version: types::Card32,
24278 minor_version: types::Card32,
24279 gl_versions: impl AsRef<[types::Card32]>,
24280 gl_extension_string: impl AsRef<[types::Char]>,
24281 glx_extension_string: impl AsRef<[types::Char]>,
24282 ) -> futures::SendRequest<'this, Self, ()> {
24283 let span = tracing::info_span!(
24284 "glx_set_client_info2_arb",
24285 major_version = ?major_version,
24286 minor_version = ?minor_version,
24287 );
24288 let request = types::glx::SetClientInfo2ARBRequest {
24289 major_version,
24290 minor_version,
24291 gl_versions: Cow::Borrowed(gl_versions.as_ref()),
24292 gl_extension_string: Cow::Borrowed(gl_extension_string.as_ref()),
24293 glx_extension_string: Cow::Borrowed(glx_extension_string.as_ref()),
24294 };
24295 let cookie = self.send_void_request(request, true).with_span(span);
24296 cookie
24297 }
24298 #[cfg(feature = "glx")]
24299 fn glx_set_client_info2_arb_checked<'this>(
24300 &'this mut self,
24301 major_version: types::Card32,
24302 minor_version: types::Card32,
24303 gl_versions: impl AsRef<[types::Card32]>,
24304 gl_extension_string: impl AsRef<[types::Char]>,
24305 glx_extension_string: impl AsRef<[types::Char]>,
24306 ) -> futures::CheckedSendRequest<'this, Self, ()> {
24307 let request = types::glx::SetClientInfo2ARBRequest {
24308 major_version,
24309 minor_version,
24310 gl_versions: Cow::Borrowed(gl_versions.as_ref()),
24311 gl_extension_string: Cow::Borrowed(gl_extension_string.as_ref()),
24312 glx_extension_string: Cow::Borrowed(glx_extension_string.as_ref()),
24313 };
24314 let cookie = self.send_void_request(request, false);
24315 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
24316 res
24317 }
24318 #[cfg(feature = "glx")]
24319 fn glx_new_list<'this>(
24320 &'this mut self,
24321 context_tag: types::ContextTag,
24322 list: types::Card32,
24323 mode: types::Card32,
24324 ) -> futures::SendRequest<'this, Self, ()> {
24325 let span = tracing::info_span!(
24326 "glx_new_list",
24327 context_tag = ?context_tag,
24328 list = ?list,
24329 mode = ?mode,
24330 );
24331 let request = types::glx::NewListRequest {
24332 context_tag,
24333 list,
24334 mode,
24335 };
24336 let cookie = self.send_void_request(request, true).with_span(span);
24337 cookie
24338 }
24339 #[cfg(feature = "glx")]
24340 fn glx_new_list_checked<'this>(
24341 &'this mut self,
24342 context_tag: types::ContextTag,
24343 list: types::Card32,
24344 mode: types::Card32,
24345 ) -> futures::CheckedSendRequest<'this, Self, ()> {
24346 let request = types::glx::NewListRequest {
24347 context_tag,
24348 list,
24349 mode,
24350 };
24351 let cookie = self.send_void_request(request, false);
24352 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
24353 res
24354 }
24355 #[cfg(feature = "glx")]
24356 fn glx_end_list<'this>(
24357 &'this mut self,
24358 context_tag: types::ContextTag,
24359 ) -> futures::SendRequest<'this, Self, ()> {
24360 let span = tracing::info_span!(
24361 "glx_end_list",
24362 context_tag = ?context_tag,
24363 );
24364 let request = types::glx::EndListRequest { context_tag };
24365 let cookie = self.send_void_request(request, true).with_span(span);
24366 cookie
24367 }
24368 #[cfg(feature = "glx")]
24369 fn glx_end_list_checked<'this>(
24370 &'this mut self,
24371 context_tag: types::ContextTag,
24372 ) -> futures::CheckedSendRequest<'this, Self, ()> {
24373 let request = types::glx::EndListRequest { context_tag };
24374 let cookie = self.send_void_request(request, false);
24375 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
24376 res
24377 }
24378 #[cfg(feature = "glx")]
24379 fn glx_delete_lists<'this>(
24380 &'this mut self,
24381 context_tag: types::ContextTag,
24382 list: types::Card32,
24383 range: types::Int32,
24384 ) -> futures::SendRequest<'this, Self, ()> {
24385 let span = tracing::info_span!(
24386 "glx_delete_lists",
24387 context_tag = ?context_tag,
24388 list = ?list,
24389 range = ?range,
24390 );
24391 let request = types::glx::DeleteListsRequest {
24392 context_tag,
24393 list,
24394 range,
24395 };
24396 let cookie = self.send_void_request(request, true).with_span(span);
24397 cookie
24398 }
24399 #[cfg(feature = "glx")]
24400 fn glx_delete_lists_checked<'this>(
24401 &'this mut self,
24402 context_tag: types::ContextTag,
24403 list: types::Card32,
24404 range: types::Int32,
24405 ) -> futures::CheckedSendRequest<'this, Self, ()> {
24406 let request = types::glx::DeleteListsRequest {
24407 context_tag,
24408 list,
24409 range,
24410 };
24411 let cookie = self.send_void_request(request, false);
24412 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
24413 res
24414 }
24415 #[cfg(feature = "glx")]
24416 fn glx_gen_lists<'this>(
24417 &'this mut self,
24418 context_tag: types::ContextTag,
24419 range: types::Int32,
24420 ) -> futures::SendRequest<'this, Self, types::glx::GenListsReply> {
24421 let span = tracing::info_span!(
24422 "glx_gen_lists",
24423 context_tag = ?context_tag,
24424 range = ?range,
24425 );
24426 let request = types::glx::GenListsRequest { context_tag, range };
24427 let cookie = self.send_reply_request(request).with_span(span);
24428 cookie
24429 }
24430 #[cfg(feature = "glx")]
24431 fn glx_gen_lists_immediate<'this>(
24432 &'this mut self,
24433 context_tag: types::ContextTag,
24434 range: types::Int32,
24435 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GenListsReply> {
24436 let request = types::glx::GenListsRequest { context_tag, range };
24437 let cookie = self.send_reply_request(request);
24438 let res: futures::CheckedSendRequest<'this, Self, types::glx::GenListsReply> =
24439 cookie.into();
24440 res
24441 }
24442 #[cfg(feature = "glx")]
24443 fn glx_feedback_buffer<'this>(
24444 &'this mut self,
24445 context_tag: types::ContextTag,
24446 size: types::Int32,
24447 type_: types::Int32,
24448 ) -> futures::SendRequest<'this, Self, ()> {
24449 let span = tracing::info_span!(
24450 "glx_feedback_buffer",
24451 context_tag = ?context_tag,
24452 size = ?size,
24453 type_ = ?type_,
24454 );
24455 let request = types::glx::FeedbackBufferRequest {
24456 context_tag,
24457 size,
24458 type_,
24459 };
24460 let cookie = self.send_void_request(request, true).with_span(span);
24461 cookie
24462 }
24463 #[cfg(feature = "glx")]
24464 fn glx_feedback_buffer_checked<'this>(
24465 &'this mut self,
24466 context_tag: types::ContextTag,
24467 size: types::Int32,
24468 type_: types::Int32,
24469 ) -> futures::CheckedSendRequest<'this, Self, ()> {
24470 let request = types::glx::FeedbackBufferRequest {
24471 context_tag,
24472 size,
24473 type_,
24474 };
24475 let cookie = self.send_void_request(request, false);
24476 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
24477 res
24478 }
24479 #[cfg(feature = "glx")]
24480 fn glx_select_buffer<'this>(
24481 &'this mut self,
24482 context_tag: types::ContextTag,
24483 size: types::Int32,
24484 ) -> futures::SendRequest<'this, Self, ()> {
24485 let span = tracing::info_span!(
24486 "glx_select_buffer",
24487 context_tag = ?context_tag,
24488 size = ?size,
24489 );
24490 let request = types::glx::SelectBufferRequest { context_tag, size };
24491 let cookie = self.send_void_request(request, true).with_span(span);
24492 cookie
24493 }
24494 #[cfg(feature = "glx")]
24495 fn glx_select_buffer_checked<'this>(
24496 &'this mut self,
24497 context_tag: types::ContextTag,
24498 size: types::Int32,
24499 ) -> futures::CheckedSendRequest<'this, Self, ()> {
24500 let request = types::glx::SelectBufferRequest { context_tag, size };
24501 let cookie = self.send_void_request(request, false);
24502 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
24503 res
24504 }
24505 #[cfg(feature = "glx")]
24506 fn glx_render_mode<'this>(
24507 &'this mut self,
24508 context_tag: types::ContextTag,
24509 mode: types::Card32,
24510 ) -> futures::SendRequest<'this, Self, types::glx::RenderModeReply> {
24511 let span = tracing::info_span!(
24512 "glx_render_mode",
24513 context_tag = ?context_tag,
24514 mode = ?mode,
24515 );
24516 let request = types::glx::RenderModeRequest { context_tag, mode };
24517 let cookie = self.send_reply_request(request).with_span(span);
24518 cookie
24519 }
24520 #[cfg(feature = "glx")]
24521 fn glx_render_mode_immediate<'this>(
24522 &'this mut self,
24523 context_tag: types::ContextTag,
24524 mode: types::Card32,
24525 ) -> futures::CheckedSendRequest<'this, Self, types::glx::RenderModeReply> {
24526 let request = types::glx::RenderModeRequest { context_tag, mode };
24527 let cookie = self.send_reply_request(request);
24528 let res: futures::CheckedSendRequest<'this, Self, types::glx::RenderModeReply> =
24529 cookie.into();
24530 res
24531 }
24532 #[cfg(feature = "glx")]
24533 fn glx_finish<'this>(
24534 &'this mut self,
24535 context_tag: types::ContextTag,
24536 ) -> futures::SendRequest<'this, Self, types::glx::FinishReply> {
24537 let span = tracing::info_span!(
24538 "glx_finish",
24539 context_tag = ?context_tag,
24540 );
24541 let request = types::glx::FinishRequest { context_tag };
24542 let cookie = self.send_reply_request(request).with_span(span);
24543 cookie
24544 }
24545 #[cfg(feature = "glx")]
24546 fn glx_finish_immediate<'this>(
24547 &'this mut self,
24548 context_tag: types::ContextTag,
24549 ) -> futures::CheckedSendRequest<'this, Self, types::glx::FinishReply> {
24550 let request = types::glx::FinishRequest { context_tag };
24551 let cookie = self.send_reply_request(request);
24552 let res: futures::CheckedSendRequest<'this, Self, types::glx::FinishReply> = cookie.into();
24553 res
24554 }
24555 #[cfg(feature = "glx")]
24556 fn glx_pixel_storef<'this>(
24557 &'this mut self,
24558 context_tag: types::ContextTag,
24559 pname: types::Card32,
24560 datum: types::Float32,
24561 ) -> futures::SendRequest<'this, Self, ()> {
24562 let span = tracing::info_span!(
24563 "glx_pixel_storef",
24564 context_tag = ?context_tag,
24565 pname = ?pname,
24566 datum = ?datum,
24567 );
24568 let request = types::glx::PixelStorefRequest {
24569 context_tag,
24570 pname,
24571 datum,
24572 };
24573 let cookie = self.send_void_request(request, true).with_span(span);
24574 cookie
24575 }
24576 #[cfg(feature = "glx")]
24577 fn glx_pixel_storef_checked<'this>(
24578 &'this mut self,
24579 context_tag: types::ContextTag,
24580 pname: types::Card32,
24581 datum: types::Float32,
24582 ) -> futures::CheckedSendRequest<'this, Self, ()> {
24583 let request = types::glx::PixelStorefRequest {
24584 context_tag,
24585 pname,
24586 datum,
24587 };
24588 let cookie = self.send_void_request(request, false);
24589 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
24590 res
24591 }
24592 #[cfg(feature = "glx")]
24593 fn glx_pixel_storei<'this>(
24594 &'this mut self,
24595 context_tag: types::ContextTag,
24596 pname: types::Card32,
24597 datum: types::Int32,
24598 ) -> futures::SendRequest<'this, Self, ()> {
24599 let span = tracing::info_span!(
24600 "glx_pixel_storei",
24601 context_tag = ?context_tag,
24602 pname = ?pname,
24603 datum = ?datum,
24604 );
24605 let request = types::glx::PixelStoreiRequest {
24606 context_tag,
24607 pname,
24608 datum,
24609 };
24610 let cookie = self.send_void_request(request, true).with_span(span);
24611 cookie
24612 }
24613 #[cfg(feature = "glx")]
24614 fn glx_pixel_storei_checked<'this>(
24615 &'this mut self,
24616 context_tag: types::ContextTag,
24617 pname: types::Card32,
24618 datum: types::Int32,
24619 ) -> futures::CheckedSendRequest<'this, Self, ()> {
24620 let request = types::glx::PixelStoreiRequest {
24621 context_tag,
24622 pname,
24623 datum,
24624 };
24625 let cookie = self.send_void_request(request, false);
24626 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
24627 res
24628 }
24629 #[cfg(feature = "glx")]
24630 fn glx_read_pixels<'this>(
24631 &'this mut self,
24632 context_tag: types::ContextTag,
24633 x: types::Int32,
24634 y: types::Int32,
24635 width: types::Int32,
24636 height: types::Int32,
24637 format: types::Card32,
24638 type_: types::Card32,
24639 swap_bytes: types::Bool,
24640 lsb_first: types::Bool,
24641 ) -> futures::SendRequest<'this, Self, types::glx::ReadPixelsReply> {
24642 let span = tracing::info_span!(
24643 "glx_read_pixels",
24644 context_tag = ?context_tag,
24645 x = ?x,
24646 y = ?y,
24647 width = ?width,
24648 height = ?height,
24649 format = ?format,
24650 type_ = ?type_,
24651 swap_bytes = ?swap_bytes,
24652 lsb_first = ?lsb_first,
24653 );
24654 let request = types::glx::ReadPixelsRequest {
24655 context_tag,
24656 x,
24657 y,
24658 width,
24659 height,
24660 format,
24661 type_,
24662 swap_bytes,
24663 lsb_first,
24664 };
24665 let cookie = self.send_reply_request(request).with_span(span);
24666 cookie
24667 }
24668 #[cfg(feature = "glx")]
24669 fn glx_read_pixels_immediate<'this>(
24670 &'this mut self,
24671 context_tag: types::ContextTag,
24672 x: types::Int32,
24673 y: types::Int32,
24674 width: types::Int32,
24675 height: types::Int32,
24676 format: types::Card32,
24677 type_: types::Card32,
24678 swap_bytes: types::Bool,
24679 lsb_first: types::Bool,
24680 ) -> futures::CheckedSendRequest<'this, Self, types::glx::ReadPixelsReply> {
24681 let request = types::glx::ReadPixelsRequest {
24682 context_tag,
24683 x,
24684 y,
24685 width,
24686 height,
24687 format,
24688 type_,
24689 swap_bytes,
24690 lsb_first,
24691 };
24692 let cookie = self.send_reply_request(request);
24693 let res: futures::CheckedSendRequest<'this, Self, types::glx::ReadPixelsReply> =
24694 cookie.into();
24695 res
24696 }
24697 #[cfg(feature = "glx")]
24698 fn glx_get_booleanv<'this>(
24699 &'this mut self,
24700 context_tag: types::ContextTag,
24701 pname: types::Int32,
24702 ) -> futures::SendRequest<'this, Self, types::glx::GetBooleanvReply> {
24703 let span = tracing::info_span!(
24704 "glx_get_booleanv",
24705 context_tag = ?context_tag,
24706 pname = ?pname,
24707 );
24708 let request = types::glx::GetBooleanvRequest { context_tag, pname };
24709 let cookie = self.send_reply_request(request).with_span(span);
24710 cookie
24711 }
24712 #[cfg(feature = "glx")]
24713 fn glx_get_booleanv_immediate<'this>(
24714 &'this mut self,
24715 context_tag: types::ContextTag,
24716 pname: types::Int32,
24717 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetBooleanvReply> {
24718 let request = types::glx::GetBooleanvRequest { context_tag, pname };
24719 let cookie = self.send_reply_request(request);
24720 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetBooleanvReply> =
24721 cookie.into();
24722 res
24723 }
24724 #[cfg(feature = "glx")]
24725 fn glx_get_clip_plane<'this>(
24726 &'this mut self,
24727 context_tag: types::ContextTag,
24728 plane: types::Int32,
24729 ) -> futures::SendRequest<'this, Self, types::glx::GetClipPlaneReply> {
24730 let span = tracing::info_span!(
24731 "glx_get_clip_plane",
24732 context_tag = ?context_tag,
24733 plane = ?plane,
24734 );
24735 let request = types::glx::GetClipPlaneRequest { context_tag, plane };
24736 let cookie = self.send_reply_request(request).with_span(span);
24737 cookie
24738 }
24739 #[cfg(feature = "glx")]
24740 fn glx_get_clip_plane_immediate<'this>(
24741 &'this mut self,
24742 context_tag: types::ContextTag,
24743 plane: types::Int32,
24744 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetClipPlaneReply> {
24745 let request = types::glx::GetClipPlaneRequest { context_tag, plane };
24746 let cookie = self.send_reply_request(request);
24747 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetClipPlaneReply> =
24748 cookie.into();
24749 res
24750 }
24751 #[cfg(feature = "glx")]
24752 fn glx_get_doublev<'this>(
24753 &'this mut self,
24754 context_tag: types::ContextTag,
24755 pname: types::Card32,
24756 ) -> futures::SendRequest<'this, Self, types::glx::GetDoublevReply> {
24757 let span = tracing::info_span!(
24758 "glx_get_doublev",
24759 context_tag = ?context_tag,
24760 pname = ?pname,
24761 );
24762 let request = types::glx::GetDoublevRequest { context_tag, pname };
24763 let cookie = self.send_reply_request(request).with_span(span);
24764 cookie
24765 }
24766 #[cfg(feature = "glx")]
24767 fn glx_get_doublev_immediate<'this>(
24768 &'this mut self,
24769 context_tag: types::ContextTag,
24770 pname: types::Card32,
24771 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetDoublevReply> {
24772 let request = types::glx::GetDoublevRequest { context_tag, pname };
24773 let cookie = self.send_reply_request(request);
24774 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetDoublevReply> =
24775 cookie.into();
24776 res
24777 }
24778 #[cfg(feature = "glx")]
24779 fn glx_get_error<'this>(
24780 &'this mut self,
24781 context_tag: types::ContextTag,
24782 ) -> futures::SendRequest<'this, Self, types::glx::GetErrorReply> {
24783 let span = tracing::info_span!(
24784 "glx_get_error",
24785 context_tag = ?context_tag,
24786 );
24787 let request = types::glx::GetErrorRequest { context_tag };
24788 let cookie = self.send_reply_request(request).with_span(span);
24789 cookie
24790 }
24791 #[cfg(feature = "glx")]
24792 fn glx_get_error_immediate<'this>(
24793 &'this mut self,
24794 context_tag: types::ContextTag,
24795 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetErrorReply> {
24796 let request = types::glx::GetErrorRequest { context_tag };
24797 let cookie = self.send_reply_request(request);
24798 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetErrorReply> =
24799 cookie.into();
24800 res
24801 }
24802 #[cfg(feature = "glx")]
24803 fn glx_get_floatv<'this>(
24804 &'this mut self,
24805 context_tag: types::ContextTag,
24806 pname: types::Card32,
24807 ) -> futures::SendRequest<'this, Self, types::glx::GetFloatvReply> {
24808 let span = tracing::info_span!(
24809 "glx_get_floatv",
24810 context_tag = ?context_tag,
24811 pname = ?pname,
24812 );
24813 let request = types::glx::GetFloatvRequest { context_tag, pname };
24814 let cookie = self.send_reply_request(request).with_span(span);
24815 cookie
24816 }
24817 #[cfg(feature = "glx")]
24818 fn glx_get_floatv_immediate<'this>(
24819 &'this mut self,
24820 context_tag: types::ContextTag,
24821 pname: types::Card32,
24822 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetFloatvReply> {
24823 let request = types::glx::GetFloatvRequest { context_tag, pname };
24824 let cookie = self.send_reply_request(request);
24825 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetFloatvReply> =
24826 cookie.into();
24827 res
24828 }
24829 #[cfg(feature = "glx")]
24830 fn glx_get_integerv<'this>(
24831 &'this mut self,
24832 context_tag: types::ContextTag,
24833 pname: types::Card32,
24834 ) -> futures::SendRequest<'this, Self, types::glx::GetIntegervReply> {
24835 let span = tracing::info_span!(
24836 "glx_get_integerv",
24837 context_tag = ?context_tag,
24838 pname = ?pname,
24839 );
24840 let request = types::glx::GetIntegervRequest { context_tag, pname };
24841 let cookie = self.send_reply_request(request).with_span(span);
24842 cookie
24843 }
24844 #[cfg(feature = "glx")]
24845 fn glx_get_integerv_immediate<'this>(
24846 &'this mut self,
24847 context_tag: types::ContextTag,
24848 pname: types::Card32,
24849 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetIntegervReply> {
24850 let request = types::glx::GetIntegervRequest { context_tag, pname };
24851 let cookie = self.send_reply_request(request);
24852 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetIntegervReply> =
24853 cookie.into();
24854 res
24855 }
24856 #[cfg(feature = "glx")]
24857 fn glx_get_lightfv<'this>(
24858 &'this mut self,
24859 context_tag: types::ContextTag,
24860 light: types::Card32,
24861 pname: types::Card32,
24862 ) -> futures::SendRequest<'this, Self, types::glx::GetLightfvReply> {
24863 let span = tracing::info_span!(
24864 "glx_get_lightfv",
24865 context_tag = ?context_tag,
24866 light = ?light,
24867 pname = ?pname,
24868 );
24869 let request = types::glx::GetLightfvRequest {
24870 context_tag,
24871 light,
24872 pname,
24873 };
24874 let cookie = self.send_reply_request(request).with_span(span);
24875 cookie
24876 }
24877 #[cfg(feature = "glx")]
24878 fn glx_get_lightfv_immediate<'this>(
24879 &'this mut self,
24880 context_tag: types::ContextTag,
24881 light: types::Card32,
24882 pname: types::Card32,
24883 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetLightfvReply> {
24884 let request = types::glx::GetLightfvRequest {
24885 context_tag,
24886 light,
24887 pname,
24888 };
24889 let cookie = self.send_reply_request(request);
24890 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetLightfvReply> =
24891 cookie.into();
24892 res
24893 }
24894 #[cfg(feature = "glx")]
24895 fn glx_get_lightiv<'this>(
24896 &'this mut self,
24897 context_tag: types::ContextTag,
24898 light: types::Card32,
24899 pname: types::Card32,
24900 ) -> futures::SendRequest<'this, Self, types::glx::GetLightivReply> {
24901 let span = tracing::info_span!(
24902 "glx_get_lightiv",
24903 context_tag = ?context_tag,
24904 light = ?light,
24905 pname = ?pname,
24906 );
24907 let request = types::glx::GetLightivRequest {
24908 context_tag,
24909 light,
24910 pname,
24911 };
24912 let cookie = self.send_reply_request(request).with_span(span);
24913 cookie
24914 }
24915 #[cfg(feature = "glx")]
24916 fn glx_get_lightiv_immediate<'this>(
24917 &'this mut self,
24918 context_tag: types::ContextTag,
24919 light: types::Card32,
24920 pname: types::Card32,
24921 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetLightivReply> {
24922 let request = types::glx::GetLightivRequest {
24923 context_tag,
24924 light,
24925 pname,
24926 };
24927 let cookie = self.send_reply_request(request);
24928 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetLightivReply> =
24929 cookie.into();
24930 res
24931 }
24932 #[cfg(feature = "glx")]
24933 fn glx_get_mapdv<'this>(
24934 &'this mut self,
24935 context_tag: types::ContextTag,
24936 target: types::Card32,
24937 query: types::Card32,
24938 ) -> futures::SendRequest<'this, Self, types::glx::GetMapdvReply> {
24939 let span = tracing::info_span!(
24940 "glx_get_mapdv",
24941 context_tag = ?context_tag,
24942 target = ?target,
24943 query = ?query,
24944 );
24945 let request = types::glx::GetMapdvRequest {
24946 context_tag,
24947 target,
24948 query,
24949 };
24950 let cookie = self.send_reply_request(request).with_span(span);
24951 cookie
24952 }
24953 #[cfg(feature = "glx")]
24954 fn glx_get_mapdv_immediate<'this>(
24955 &'this mut self,
24956 context_tag: types::ContextTag,
24957 target: types::Card32,
24958 query: types::Card32,
24959 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetMapdvReply> {
24960 let request = types::glx::GetMapdvRequest {
24961 context_tag,
24962 target,
24963 query,
24964 };
24965 let cookie = self.send_reply_request(request);
24966 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetMapdvReply> =
24967 cookie.into();
24968 res
24969 }
24970 #[cfg(feature = "glx")]
24971 fn glx_get_mapfv<'this>(
24972 &'this mut self,
24973 context_tag: types::ContextTag,
24974 target: types::Card32,
24975 query: types::Card32,
24976 ) -> futures::SendRequest<'this, Self, types::glx::GetMapfvReply> {
24977 let span = tracing::info_span!(
24978 "glx_get_mapfv",
24979 context_tag = ?context_tag,
24980 target = ?target,
24981 query = ?query,
24982 );
24983 let request = types::glx::GetMapfvRequest {
24984 context_tag,
24985 target,
24986 query,
24987 };
24988 let cookie = self.send_reply_request(request).with_span(span);
24989 cookie
24990 }
24991 #[cfg(feature = "glx")]
24992 fn glx_get_mapfv_immediate<'this>(
24993 &'this mut self,
24994 context_tag: types::ContextTag,
24995 target: types::Card32,
24996 query: types::Card32,
24997 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetMapfvReply> {
24998 let request = types::glx::GetMapfvRequest {
24999 context_tag,
25000 target,
25001 query,
25002 };
25003 let cookie = self.send_reply_request(request);
25004 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetMapfvReply> =
25005 cookie.into();
25006 res
25007 }
25008 #[cfg(feature = "glx")]
25009 fn glx_get_mapiv<'this>(
25010 &'this mut self,
25011 context_tag: types::ContextTag,
25012 target: types::Card32,
25013 query: types::Card32,
25014 ) -> futures::SendRequest<'this, Self, types::glx::GetMapivReply> {
25015 let span = tracing::info_span!(
25016 "glx_get_mapiv",
25017 context_tag = ?context_tag,
25018 target = ?target,
25019 query = ?query,
25020 );
25021 let request = types::glx::GetMapivRequest {
25022 context_tag,
25023 target,
25024 query,
25025 };
25026 let cookie = self.send_reply_request(request).with_span(span);
25027 cookie
25028 }
25029 #[cfg(feature = "glx")]
25030 fn glx_get_mapiv_immediate<'this>(
25031 &'this mut self,
25032 context_tag: types::ContextTag,
25033 target: types::Card32,
25034 query: types::Card32,
25035 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetMapivReply> {
25036 let request = types::glx::GetMapivRequest {
25037 context_tag,
25038 target,
25039 query,
25040 };
25041 let cookie = self.send_reply_request(request);
25042 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetMapivReply> =
25043 cookie.into();
25044 res
25045 }
25046 #[cfg(feature = "glx")]
25047 fn glx_get_materialfv<'this>(
25048 &'this mut self,
25049 context_tag: types::ContextTag,
25050 face: types::Card32,
25051 pname: types::Card32,
25052 ) -> futures::SendRequest<'this, Self, types::glx::GetMaterialfvReply> {
25053 let span = tracing::info_span!(
25054 "glx_get_materialfv",
25055 context_tag = ?context_tag,
25056 face = ?face,
25057 pname = ?pname,
25058 );
25059 let request = types::glx::GetMaterialfvRequest {
25060 context_tag,
25061 face,
25062 pname,
25063 };
25064 let cookie = self.send_reply_request(request).with_span(span);
25065 cookie
25066 }
25067 #[cfg(feature = "glx")]
25068 fn glx_get_materialfv_immediate<'this>(
25069 &'this mut self,
25070 context_tag: types::ContextTag,
25071 face: types::Card32,
25072 pname: types::Card32,
25073 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetMaterialfvReply> {
25074 let request = types::glx::GetMaterialfvRequest {
25075 context_tag,
25076 face,
25077 pname,
25078 };
25079 let cookie = self.send_reply_request(request);
25080 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetMaterialfvReply> =
25081 cookie.into();
25082 res
25083 }
25084 #[cfg(feature = "glx")]
25085 fn glx_get_materialiv<'this>(
25086 &'this mut self,
25087 context_tag: types::ContextTag,
25088 face: types::Card32,
25089 pname: types::Card32,
25090 ) -> futures::SendRequest<'this, Self, types::glx::GetMaterialivReply> {
25091 let span = tracing::info_span!(
25092 "glx_get_materialiv",
25093 context_tag = ?context_tag,
25094 face = ?face,
25095 pname = ?pname,
25096 );
25097 let request = types::glx::GetMaterialivRequest {
25098 context_tag,
25099 face,
25100 pname,
25101 };
25102 let cookie = self.send_reply_request(request).with_span(span);
25103 cookie
25104 }
25105 #[cfg(feature = "glx")]
25106 fn glx_get_materialiv_immediate<'this>(
25107 &'this mut self,
25108 context_tag: types::ContextTag,
25109 face: types::Card32,
25110 pname: types::Card32,
25111 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetMaterialivReply> {
25112 let request = types::glx::GetMaterialivRequest {
25113 context_tag,
25114 face,
25115 pname,
25116 };
25117 let cookie = self.send_reply_request(request);
25118 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetMaterialivReply> =
25119 cookie.into();
25120 res
25121 }
25122 #[cfg(feature = "glx")]
25123 fn glx_get_pixel_mapfv<'this>(
25124 &'this mut self,
25125 context_tag: types::ContextTag,
25126 map: types::Card32,
25127 ) -> futures::SendRequest<'this, Self, types::glx::GetPixelMapfvReply> {
25128 let span = tracing::info_span!(
25129 "glx_get_pixel_mapfv",
25130 context_tag = ?context_tag,
25131 map = ?map,
25132 );
25133 let request = types::glx::GetPixelMapfvRequest { context_tag, map };
25134 let cookie = self.send_reply_request(request).with_span(span);
25135 cookie
25136 }
25137 #[cfg(feature = "glx")]
25138 fn glx_get_pixel_mapfv_immediate<'this>(
25139 &'this mut self,
25140 context_tag: types::ContextTag,
25141 map: types::Card32,
25142 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetPixelMapfvReply> {
25143 let request = types::glx::GetPixelMapfvRequest { context_tag, map };
25144 let cookie = self.send_reply_request(request);
25145 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetPixelMapfvReply> =
25146 cookie.into();
25147 res
25148 }
25149 #[cfg(feature = "glx")]
25150 fn glx_get_pixel_mapuiv<'this>(
25151 &'this mut self,
25152 context_tag: types::ContextTag,
25153 map: types::Card32,
25154 ) -> futures::SendRequest<'this, Self, types::glx::GetPixelMapuivReply> {
25155 let span = tracing::info_span!(
25156 "glx_get_pixel_mapuiv",
25157 context_tag = ?context_tag,
25158 map = ?map,
25159 );
25160 let request = types::glx::GetPixelMapuivRequest { context_tag, map };
25161 let cookie = self.send_reply_request(request).with_span(span);
25162 cookie
25163 }
25164 #[cfg(feature = "glx")]
25165 fn glx_get_pixel_mapuiv_immediate<'this>(
25166 &'this mut self,
25167 context_tag: types::ContextTag,
25168 map: types::Card32,
25169 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetPixelMapuivReply> {
25170 let request = types::glx::GetPixelMapuivRequest { context_tag, map };
25171 let cookie = self.send_reply_request(request);
25172 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetPixelMapuivReply> =
25173 cookie.into();
25174 res
25175 }
25176 #[cfg(feature = "glx")]
25177 fn glx_get_pixel_mapusv<'this>(
25178 &'this mut self,
25179 context_tag: types::ContextTag,
25180 map: types::Card32,
25181 ) -> futures::SendRequest<'this, Self, types::glx::GetPixelMapusvReply> {
25182 let span = tracing::info_span!(
25183 "glx_get_pixel_mapusv",
25184 context_tag = ?context_tag,
25185 map = ?map,
25186 );
25187 let request = types::glx::GetPixelMapusvRequest { context_tag, map };
25188 let cookie = self.send_reply_request(request).with_span(span);
25189 cookie
25190 }
25191 #[cfg(feature = "glx")]
25192 fn glx_get_pixel_mapusv_immediate<'this>(
25193 &'this mut self,
25194 context_tag: types::ContextTag,
25195 map: types::Card32,
25196 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetPixelMapusvReply> {
25197 let request = types::glx::GetPixelMapusvRequest { context_tag, map };
25198 let cookie = self.send_reply_request(request);
25199 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetPixelMapusvReply> =
25200 cookie.into();
25201 res
25202 }
25203 #[cfg(feature = "glx")]
25204 fn glx_get_polygon_stipple<'this>(
25205 &'this mut self,
25206 context_tag: types::ContextTag,
25207 lsb_first: types::Bool,
25208 ) -> futures::SendRequest<'this, Self, types::glx::GetPolygonStippleReply> {
25209 let span = tracing::info_span!(
25210 "glx_get_polygon_stipple",
25211 context_tag = ?context_tag,
25212 lsb_first = ?lsb_first,
25213 );
25214 let request = types::glx::GetPolygonStippleRequest {
25215 context_tag,
25216 lsb_first,
25217 };
25218 let cookie = self.send_reply_request(request).with_span(span);
25219 cookie
25220 }
25221 #[cfg(feature = "glx")]
25222 fn glx_get_polygon_stipple_immediate<'this>(
25223 &'this mut self,
25224 context_tag: types::ContextTag,
25225 lsb_first: types::Bool,
25226 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetPolygonStippleReply> {
25227 let request = types::glx::GetPolygonStippleRequest {
25228 context_tag,
25229 lsb_first,
25230 };
25231 let cookie = self.send_reply_request(request);
25232 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetPolygonStippleReply> =
25233 cookie.into();
25234 res
25235 }
25236 #[cfg(feature = "glx")]
25237 fn glx_get_string<'this>(
25238 &'this mut self,
25239 context_tag: types::ContextTag,
25240 name: types::Card32,
25241 ) -> futures::SendRequest<'this, Self, types::glx::GetStringReply> {
25242 let span = tracing::info_span!(
25243 "glx_get_string",
25244 context_tag = ?context_tag,
25245 name = ?name,
25246 );
25247 let request = types::glx::GetStringRequest { context_tag, name };
25248 let cookie = self.send_reply_request(request).with_span(span);
25249 cookie
25250 }
25251 #[cfg(feature = "glx")]
25252 fn glx_get_string_immediate<'this>(
25253 &'this mut self,
25254 context_tag: types::ContextTag,
25255 name: types::Card32,
25256 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetStringReply> {
25257 let request = types::glx::GetStringRequest { context_tag, name };
25258 let cookie = self.send_reply_request(request);
25259 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetStringReply> =
25260 cookie.into();
25261 res
25262 }
25263 #[cfg(feature = "glx")]
25264 fn glx_get_tex_envfv<'this>(
25265 &'this mut self,
25266 context_tag: types::ContextTag,
25267 target: types::Card32,
25268 pname: types::Card32,
25269 ) -> futures::SendRequest<'this, Self, types::glx::GetTexEnvfvReply> {
25270 let span = tracing::info_span!(
25271 "glx_get_tex_envfv",
25272 context_tag = ?context_tag,
25273 target = ?target,
25274 pname = ?pname,
25275 );
25276 let request = types::glx::GetTexEnvfvRequest {
25277 context_tag,
25278 target,
25279 pname,
25280 };
25281 let cookie = self.send_reply_request(request).with_span(span);
25282 cookie
25283 }
25284 #[cfg(feature = "glx")]
25285 fn glx_get_tex_envfv_immediate<'this>(
25286 &'this mut self,
25287 context_tag: types::ContextTag,
25288 target: types::Card32,
25289 pname: types::Card32,
25290 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetTexEnvfvReply> {
25291 let request = types::glx::GetTexEnvfvRequest {
25292 context_tag,
25293 target,
25294 pname,
25295 };
25296 let cookie = self.send_reply_request(request);
25297 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetTexEnvfvReply> =
25298 cookie.into();
25299 res
25300 }
25301 #[cfg(feature = "glx")]
25302 fn glx_get_tex_enviv<'this>(
25303 &'this mut self,
25304 context_tag: types::ContextTag,
25305 target: types::Card32,
25306 pname: types::Card32,
25307 ) -> futures::SendRequest<'this, Self, types::glx::GetTexEnvivReply> {
25308 let span = tracing::info_span!(
25309 "glx_get_tex_enviv",
25310 context_tag = ?context_tag,
25311 target = ?target,
25312 pname = ?pname,
25313 );
25314 let request = types::glx::GetTexEnvivRequest {
25315 context_tag,
25316 target,
25317 pname,
25318 };
25319 let cookie = self.send_reply_request(request).with_span(span);
25320 cookie
25321 }
25322 #[cfg(feature = "glx")]
25323 fn glx_get_tex_enviv_immediate<'this>(
25324 &'this mut self,
25325 context_tag: types::ContextTag,
25326 target: types::Card32,
25327 pname: types::Card32,
25328 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetTexEnvivReply> {
25329 let request = types::glx::GetTexEnvivRequest {
25330 context_tag,
25331 target,
25332 pname,
25333 };
25334 let cookie = self.send_reply_request(request);
25335 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetTexEnvivReply> =
25336 cookie.into();
25337 res
25338 }
25339 #[cfg(feature = "glx")]
25340 fn glx_get_tex_gendv<'this>(
25341 &'this mut self,
25342 context_tag: types::ContextTag,
25343 coord: types::Card32,
25344 pname: types::Card32,
25345 ) -> futures::SendRequest<'this, Self, types::glx::GetTexGendvReply> {
25346 let span = tracing::info_span!(
25347 "glx_get_tex_gendv",
25348 context_tag = ?context_tag,
25349 coord = ?coord,
25350 pname = ?pname,
25351 );
25352 let request = types::glx::GetTexGendvRequest {
25353 context_tag,
25354 coord,
25355 pname,
25356 };
25357 let cookie = self.send_reply_request(request).with_span(span);
25358 cookie
25359 }
25360 #[cfg(feature = "glx")]
25361 fn glx_get_tex_gendv_immediate<'this>(
25362 &'this mut self,
25363 context_tag: types::ContextTag,
25364 coord: types::Card32,
25365 pname: types::Card32,
25366 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetTexGendvReply> {
25367 let request = types::glx::GetTexGendvRequest {
25368 context_tag,
25369 coord,
25370 pname,
25371 };
25372 let cookie = self.send_reply_request(request);
25373 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetTexGendvReply> =
25374 cookie.into();
25375 res
25376 }
25377 #[cfg(feature = "glx")]
25378 fn glx_get_tex_genfv<'this>(
25379 &'this mut self,
25380 context_tag: types::ContextTag,
25381 coord: types::Card32,
25382 pname: types::Card32,
25383 ) -> futures::SendRequest<'this, Self, types::glx::GetTexGenfvReply> {
25384 let span = tracing::info_span!(
25385 "glx_get_tex_genfv",
25386 context_tag = ?context_tag,
25387 coord = ?coord,
25388 pname = ?pname,
25389 );
25390 let request = types::glx::GetTexGenfvRequest {
25391 context_tag,
25392 coord,
25393 pname,
25394 };
25395 let cookie = self.send_reply_request(request).with_span(span);
25396 cookie
25397 }
25398 #[cfg(feature = "glx")]
25399 fn glx_get_tex_genfv_immediate<'this>(
25400 &'this mut self,
25401 context_tag: types::ContextTag,
25402 coord: types::Card32,
25403 pname: types::Card32,
25404 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetTexGenfvReply> {
25405 let request = types::glx::GetTexGenfvRequest {
25406 context_tag,
25407 coord,
25408 pname,
25409 };
25410 let cookie = self.send_reply_request(request);
25411 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetTexGenfvReply> =
25412 cookie.into();
25413 res
25414 }
25415 #[cfg(feature = "glx")]
25416 fn glx_get_tex_geniv<'this>(
25417 &'this mut self,
25418 context_tag: types::ContextTag,
25419 coord: types::Card32,
25420 pname: types::Card32,
25421 ) -> futures::SendRequest<'this, Self, types::glx::GetTexGenivReply> {
25422 let span = tracing::info_span!(
25423 "glx_get_tex_geniv",
25424 context_tag = ?context_tag,
25425 coord = ?coord,
25426 pname = ?pname,
25427 );
25428 let request = types::glx::GetTexGenivRequest {
25429 context_tag,
25430 coord,
25431 pname,
25432 };
25433 let cookie = self.send_reply_request(request).with_span(span);
25434 cookie
25435 }
25436 #[cfg(feature = "glx")]
25437 fn glx_get_tex_geniv_immediate<'this>(
25438 &'this mut self,
25439 context_tag: types::ContextTag,
25440 coord: types::Card32,
25441 pname: types::Card32,
25442 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetTexGenivReply> {
25443 let request = types::glx::GetTexGenivRequest {
25444 context_tag,
25445 coord,
25446 pname,
25447 };
25448 let cookie = self.send_reply_request(request);
25449 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetTexGenivReply> =
25450 cookie.into();
25451 res
25452 }
25453 #[cfg(feature = "glx")]
25454 fn glx_get_tex_image<'this>(
25455 &'this mut self,
25456 context_tag: types::ContextTag,
25457 target: types::Card32,
25458 level: types::Int32,
25459 format: types::Card32,
25460 type_: types::Card32,
25461 swap_bytes: types::Bool,
25462 ) -> futures::SendRequest<'this, Self, types::glx::GetTexImageReply> {
25463 let span = tracing::info_span!(
25464 "glx_get_tex_image",
25465 context_tag = ?context_tag,
25466 target = ?target,
25467 level = ?level,
25468 format = ?format,
25469 type_ = ?type_,
25470 swap_bytes = ?swap_bytes,
25471 );
25472 let request = types::glx::GetTexImageRequest {
25473 context_tag,
25474 target,
25475 level,
25476 format,
25477 type_,
25478 swap_bytes,
25479 };
25480 let cookie = self.send_reply_request(request).with_span(span);
25481 cookie
25482 }
25483 #[cfg(feature = "glx")]
25484 fn glx_get_tex_image_immediate<'this>(
25485 &'this mut self,
25486 context_tag: types::ContextTag,
25487 target: types::Card32,
25488 level: types::Int32,
25489 format: types::Card32,
25490 type_: types::Card32,
25491 swap_bytes: types::Bool,
25492 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetTexImageReply> {
25493 let request = types::glx::GetTexImageRequest {
25494 context_tag,
25495 target,
25496 level,
25497 format,
25498 type_,
25499 swap_bytes,
25500 };
25501 let cookie = self.send_reply_request(request);
25502 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetTexImageReply> =
25503 cookie.into();
25504 res
25505 }
25506 #[cfg(feature = "glx")]
25507 fn glx_get_tex_parameterfv<'this>(
25508 &'this mut self,
25509 context_tag: types::ContextTag,
25510 target: types::Card32,
25511 pname: types::Card32,
25512 ) -> futures::SendRequest<'this, Self, types::glx::GetTexParameterfvReply> {
25513 let span = tracing::info_span!(
25514 "glx_get_tex_parameterfv",
25515 context_tag = ?context_tag,
25516 target = ?target,
25517 pname = ?pname,
25518 );
25519 let request = types::glx::GetTexParameterfvRequest {
25520 context_tag,
25521 target,
25522 pname,
25523 };
25524 let cookie = self.send_reply_request(request).with_span(span);
25525 cookie
25526 }
25527 #[cfg(feature = "glx")]
25528 fn glx_get_tex_parameterfv_immediate<'this>(
25529 &'this mut self,
25530 context_tag: types::ContextTag,
25531 target: types::Card32,
25532 pname: types::Card32,
25533 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetTexParameterfvReply> {
25534 let request = types::glx::GetTexParameterfvRequest {
25535 context_tag,
25536 target,
25537 pname,
25538 };
25539 let cookie = self.send_reply_request(request);
25540 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetTexParameterfvReply> =
25541 cookie.into();
25542 res
25543 }
25544 #[cfg(feature = "glx")]
25545 fn glx_get_tex_parameteriv<'this>(
25546 &'this mut self,
25547 context_tag: types::ContextTag,
25548 target: types::Card32,
25549 pname: types::Card32,
25550 ) -> futures::SendRequest<'this, Self, types::glx::GetTexParameterivReply> {
25551 let span = tracing::info_span!(
25552 "glx_get_tex_parameteriv",
25553 context_tag = ?context_tag,
25554 target = ?target,
25555 pname = ?pname,
25556 );
25557 let request = types::glx::GetTexParameterivRequest {
25558 context_tag,
25559 target,
25560 pname,
25561 };
25562 let cookie = self.send_reply_request(request).with_span(span);
25563 cookie
25564 }
25565 #[cfg(feature = "glx")]
25566 fn glx_get_tex_parameteriv_immediate<'this>(
25567 &'this mut self,
25568 context_tag: types::ContextTag,
25569 target: types::Card32,
25570 pname: types::Card32,
25571 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetTexParameterivReply> {
25572 let request = types::glx::GetTexParameterivRequest {
25573 context_tag,
25574 target,
25575 pname,
25576 };
25577 let cookie = self.send_reply_request(request);
25578 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetTexParameterivReply> =
25579 cookie.into();
25580 res
25581 }
25582 #[cfg(feature = "glx")]
25583 fn glx_get_tex_level_parameterfv<'this>(
25584 &'this mut self,
25585 context_tag: types::ContextTag,
25586 target: types::Card32,
25587 level: types::Int32,
25588 pname: types::Card32,
25589 ) -> futures::SendRequest<'this, Self, types::glx::GetTexLevelParameterfvReply> {
25590 let span = tracing::info_span!(
25591 "glx_get_tex_level_parameterfv",
25592 context_tag = ?context_tag,
25593 target = ?target,
25594 level = ?level,
25595 pname = ?pname,
25596 );
25597 let request = types::glx::GetTexLevelParameterfvRequest {
25598 context_tag,
25599 target,
25600 level,
25601 pname,
25602 };
25603 let cookie = self.send_reply_request(request).with_span(span);
25604 cookie
25605 }
25606 #[cfg(feature = "glx")]
25607 fn glx_get_tex_level_parameterfv_immediate<'this>(
25608 &'this mut self,
25609 context_tag: types::ContextTag,
25610 target: types::Card32,
25611 level: types::Int32,
25612 pname: types::Card32,
25613 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetTexLevelParameterfvReply> {
25614 let request = types::glx::GetTexLevelParameterfvRequest {
25615 context_tag,
25616 target,
25617 level,
25618 pname,
25619 };
25620 let cookie = self.send_reply_request(request);
25621 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetTexLevelParameterfvReply> =
25622 cookie.into();
25623 res
25624 }
25625 #[cfg(feature = "glx")]
25626 fn glx_get_tex_level_parameteriv<'this>(
25627 &'this mut self,
25628 context_tag: types::ContextTag,
25629 target: types::Card32,
25630 level: types::Int32,
25631 pname: types::Card32,
25632 ) -> futures::SendRequest<'this, Self, types::glx::GetTexLevelParameterivReply> {
25633 let span = tracing::info_span!(
25634 "glx_get_tex_level_parameteriv",
25635 context_tag = ?context_tag,
25636 target = ?target,
25637 level = ?level,
25638 pname = ?pname,
25639 );
25640 let request = types::glx::GetTexLevelParameterivRequest {
25641 context_tag,
25642 target,
25643 level,
25644 pname,
25645 };
25646 let cookie = self.send_reply_request(request).with_span(span);
25647 cookie
25648 }
25649 #[cfg(feature = "glx")]
25650 fn glx_get_tex_level_parameteriv_immediate<'this>(
25651 &'this mut self,
25652 context_tag: types::ContextTag,
25653 target: types::Card32,
25654 level: types::Int32,
25655 pname: types::Card32,
25656 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetTexLevelParameterivReply> {
25657 let request = types::glx::GetTexLevelParameterivRequest {
25658 context_tag,
25659 target,
25660 level,
25661 pname,
25662 };
25663 let cookie = self.send_reply_request(request);
25664 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetTexLevelParameterivReply> =
25665 cookie.into();
25666 res
25667 }
25668 #[cfg(feature = "glx")]
25669 fn glx_is_enabled<'this>(
25670 &'this mut self,
25671 context_tag: types::ContextTag,
25672 capability: types::Card32,
25673 ) -> futures::SendRequest<'this, Self, types::glx::IsEnabledReply> {
25674 let span = tracing::info_span!(
25675 "glx_is_enabled",
25676 context_tag = ?context_tag,
25677 capability = ?capability,
25678 );
25679 let request = types::glx::IsEnabledRequest {
25680 context_tag,
25681 capability,
25682 };
25683 let cookie = self.send_reply_request(request).with_span(span);
25684 cookie
25685 }
25686 #[cfg(feature = "glx")]
25687 fn glx_is_enabled_immediate<'this>(
25688 &'this mut self,
25689 context_tag: types::ContextTag,
25690 capability: types::Card32,
25691 ) -> futures::CheckedSendRequest<'this, Self, types::glx::IsEnabledReply> {
25692 let request = types::glx::IsEnabledRequest {
25693 context_tag,
25694 capability,
25695 };
25696 let cookie = self.send_reply_request(request);
25697 let res: futures::CheckedSendRequest<'this, Self, types::glx::IsEnabledReply> =
25698 cookie.into();
25699 res
25700 }
25701 #[cfg(feature = "glx")]
25702 fn glx_is_list<'this>(
25703 &'this mut self,
25704 context_tag: types::ContextTag,
25705 list: types::Card32,
25706 ) -> futures::SendRequest<'this, Self, types::glx::IsListReply> {
25707 let span = tracing::info_span!(
25708 "glx_is_list",
25709 context_tag = ?context_tag,
25710 list = ?list,
25711 );
25712 let request = types::glx::IsListRequest { context_tag, list };
25713 let cookie = self.send_reply_request(request).with_span(span);
25714 cookie
25715 }
25716 #[cfg(feature = "glx")]
25717 fn glx_is_list_immediate<'this>(
25718 &'this mut self,
25719 context_tag: types::ContextTag,
25720 list: types::Card32,
25721 ) -> futures::CheckedSendRequest<'this, Self, types::glx::IsListReply> {
25722 let request = types::glx::IsListRequest { context_tag, list };
25723 let cookie = self.send_reply_request(request);
25724 let res: futures::CheckedSendRequest<'this, Self, types::glx::IsListReply> = cookie.into();
25725 res
25726 }
25727 #[cfg(feature = "glx")]
25728 fn glx_flush<'this>(
25729 &'this mut self,
25730 context_tag: types::ContextTag,
25731 ) -> futures::SendRequest<'this, Self, ()> {
25732 let span = tracing::info_span!(
25733 "glx_flush",
25734 context_tag = ?context_tag,
25735 );
25736 let request = types::glx::FlushRequest { context_tag };
25737 let cookie = self.send_void_request(request, true).with_span(span);
25738 cookie
25739 }
25740 #[cfg(feature = "glx")]
25741 fn glx_flush_checked<'this>(
25742 &'this mut self,
25743 context_tag: types::ContextTag,
25744 ) -> futures::CheckedSendRequest<'this, Self, ()> {
25745 let request = types::glx::FlushRequest { context_tag };
25746 let cookie = self.send_void_request(request, false);
25747 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
25748 res
25749 }
25750 #[cfg(feature = "glx")]
25751 fn glx_are_textures_resident<'this>(
25752 &'this mut self,
25753 context_tag: types::ContextTag,
25754 textures: impl AsRef<[types::Card32]>,
25755 ) -> futures::SendRequest<'this, Self, types::glx::AreTexturesResidentReply> {
25756 let span = tracing::info_span!(
25757 "glx_are_textures_resident",
25758 context_tag = ?context_tag,
25759 );
25760 let request = types::glx::AreTexturesResidentRequest {
25761 context_tag,
25762 textures: Cow::Borrowed(textures.as_ref()),
25763 };
25764 let cookie = self.send_reply_request(request).with_span(span);
25765 cookie
25766 }
25767 #[cfg(feature = "glx")]
25768 fn glx_are_textures_resident_immediate<'this>(
25769 &'this mut self,
25770 context_tag: types::ContextTag,
25771 textures: impl AsRef<[types::Card32]>,
25772 ) -> futures::CheckedSendRequest<'this, Self, types::glx::AreTexturesResidentReply> {
25773 let request = types::glx::AreTexturesResidentRequest {
25774 context_tag,
25775 textures: Cow::Borrowed(textures.as_ref()),
25776 };
25777 let cookie = self.send_reply_request(request);
25778 let res: futures::CheckedSendRequest<'this, Self, types::glx::AreTexturesResidentReply> =
25779 cookie.into();
25780 res
25781 }
25782 #[cfg(feature = "glx")]
25783 fn glx_delete_textures<'this>(
25784 &'this mut self,
25785 context_tag: types::ContextTag,
25786 textures: impl AsRef<[types::Card32]>,
25787 ) -> futures::SendRequest<'this, Self, ()> {
25788 let span = tracing::info_span!(
25789 "glx_delete_textures",
25790 context_tag = ?context_tag,
25791 );
25792 let request = types::glx::DeleteTexturesRequest {
25793 context_tag,
25794 textures: Cow::Borrowed(textures.as_ref()),
25795 };
25796 let cookie = self.send_void_request(request, true).with_span(span);
25797 cookie
25798 }
25799 #[cfg(feature = "glx")]
25800 fn glx_delete_textures_checked<'this>(
25801 &'this mut self,
25802 context_tag: types::ContextTag,
25803 textures: impl AsRef<[types::Card32]>,
25804 ) -> futures::CheckedSendRequest<'this, Self, ()> {
25805 let request = types::glx::DeleteTexturesRequest {
25806 context_tag,
25807 textures: Cow::Borrowed(textures.as_ref()),
25808 };
25809 let cookie = self.send_void_request(request, false);
25810 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
25811 res
25812 }
25813 #[cfg(feature = "glx")]
25814 fn glx_gen_textures<'this>(
25815 &'this mut self,
25816 context_tag: types::ContextTag,
25817 n: types::Int32,
25818 ) -> futures::SendRequest<'this, Self, types::glx::GenTexturesReply> {
25819 let span = tracing::info_span!(
25820 "glx_gen_textures",
25821 context_tag = ?context_tag,
25822 n = ?n,
25823 );
25824 let request = types::glx::GenTexturesRequest { context_tag, n };
25825 let cookie = self.send_reply_request(request).with_span(span);
25826 cookie
25827 }
25828 #[cfg(feature = "glx")]
25829 fn glx_gen_textures_immediate<'this>(
25830 &'this mut self,
25831 context_tag: types::ContextTag,
25832 n: types::Int32,
25833 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GenTexturesReply> {
25834 let request = types::glx::GenTexturesRequest { context_tag, n };
25835 let cookie = self.send_reply_request(request);
25836 let res: futures::CheckedSendRequest<'this, Self, types::glx::GenTexturesReply> =
25837 cookie.into();
25838 res
25839 }
25840 #[cfg(feature = "glx")]
25841 fn glx_is_texture<'this>(
25842 &'this mut self,
25843 context_tag: types::ContextTag,
25844 texture: types::Card32,
25845 ) -> futures::SendRequest<'this, Self, types::glx::IsTextureReply> {
25846 let span = tracing::info_span!(
25847 "glx_is_texture",
25848 context_tag = ?context_tag,
25849 texture = ?texture,
25850 );
25851 let request = types::glx::IsTextureRequest {
25852 context_tag,
25853 texture,
25854 };
25855 let cookie = self.send_reply_request(request).with_span(span);
25856 cookie
25857 }
25858 #[cfg(feature = "glx")]
25859 fn glx_is_texture_immediate<'this>(
25860 &'this mut self,
25861 context_tag: types::ContextTag,
25862 texture: types::Card32,
25863 ) -> futures::CheckedSendRequest<'this, Self, types::glx::IsTextureReply> {
25864 let request = types::glx::IsTextureRequest {
25865 context_tag,
25866 texture,
25867 };
25868 let cookie = self.send_reply_request(request);
25869 let res: futures::CheckedSendRequest<'this, Self, types::glx::IsTextureReply> =
25870 cookie.into();
25871 res
25872 }
25873 #[cfg(feature = "glx")]
25874 fn glx_get_color_table<'this>(
25875 &'this mut self,
25876 context_tag: types::ContextTag,
25877 target: types::Card32,
25878 format: types::Card32,
25879 type_: types::Card32,
25880 swap_bytes: types::Bool,
25881 ) -> futures::SendRequest<'this, Self, types::glx::GetColorTableReply> {
25882 let span = tracing::info_span!(
25883 "glx_get_color_table",
25884 context_tag = ?context_tag,
25885 target = ?target,
25886 format = ?format,
25887 type_ = ?type_,
25888 swap_bytes = ?swap_bytes,
25889 );
25890 let request = types::glx::GetColorTableRequest {
25891 context_tag,
25892 target,
25893 format,
25894 type_,
25895 swap_bytes,
25896 };
25897 let cookie = self.send_reply_request(request).with_span(span);
25898 cookie
25899 }
25900 #[cfg(feature = "glx")]
25901 fn glx_get_color_table_immediate<'this>(
25902 &'this mut self,
25903 context_tag: types::ContextTag,
25904 target: types::Card32,
25905 format: types::Card32,
25906 type_: types::Card32,
25907 swap_bytes: types::Bool,
25908 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetColorTableReply> {
25909 let request = types::glx::GetColorTableRequest {
25910 context_tag,
25911 target,
25912 format,
25913 type_,
25914 swap_bytes,
25915 };
25916 let cookie = self.send_reply_request(request);
25917 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetColorTableReply> =
25918 cookie.into();
25919 res
25920 }
25921 #[cfg(feature = "glx")]
25922 fn glx_get_color_table_parameterfv<'this>(
25923 &'this mut self,
25924 context_tag: types::ContextTag,
25925 target: types::Card32,
25926 pname: types::Card32,
25927 ) -> futures::SendRequest<'this, Self, types::glx::GetColorTableParameterfvReply> {
25928 let span = tracing::info_span!(
25929 "glx_get_color_table_parameterfv",
25930 context_tag = ?context_tag,
25931 target = ?target,
25932 pname = ?pname,
25933 );
25934 let request = types::glx::GetColorTableParameterfvRequest {
25935 context_tag,
25936 target,
25937 pname,
25938 };
25939 let cookie = self.send_reply_request(request).with_span(span);
25940 cookie
25941 }
25942 #[cfg(feature = "glx")]
25943 fn glx_get_color_table_parameterfv_immediate<'this>(
25944 &'this mut self,
25945 context_tag: types::ContextTag,
25946 target: types::Card32,
25947 pname: types::Card32,
25948 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetColorTableParameterfvReply> {
25949 let request = types::glx::GetColorTableParameterfvRequest {
25950 context_tag,
25951 target,
25952 pname,
25953 };
25954 let cookie = self.send_reply_request(request);
25955 let res: futures::CheckedSendRequest<
25956 'this,
25957 Self,
25958 types::glx::GetColorTableParameterfvReply,
25959 > = cookie.into();
25960 res
25961 }
25962 #[cfg(feature = "glx")]
25963 fn glx_get_color_table_parameteriv<'this>(
25964 &'this mut self,
25965 context_tag: types::ContextTag,
25966 target: types::Card32,
25967 pname: types::Card32,
25968 ) -> futures::SendRequest<'this, Self, types::glx::GetColorTableParameterivReply> {
25969 let span = tracing::info_span!(
25970 "glx_get_color_table_parameteriv",
25971 context_tag = ?context_tag,
25972 target = ?target,
25973 pname = ?pname,
25974 );
25975 let request = types::glx::GetColorTableParameterivRequest {
25976 context_tag,
25977 target,
25978 pname,
25979 };
25980 let cookie = self.send_reply_request(request).with_span(span);
25981 cookie
25982 }
25983 #[cfg(feature = "glx")]
25984 fn glx_get_color_table_parameteriv_immediate<'this>(
25985 &'this mut self,
25986 context_tag: types::ContextTag,
25987 target: types::Card32,
25988 pname: types::Card32,
25989 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetColorTableParameterivReply> {
25990 let request = types::glx::GetColorTableParameterivRequest {
25991 context_tag,
25992 target,
25993 pname,
25994 };
25995 let cookie = self.send_reply_request(request);
25996 let res: futures::CheckedSendRequest<
25997 'this,
25998 Self,
25999 types::glx::GetColorTableParameterivReply,
26000 > = cookie.into();
26001 res
26002 }
26003 #[cfg(feature = "glx")]
26004 fn glx_get_convolution_filter<'this>(
26005 &'this mut self,
26006 context_tag: types::ContextTag,
26007 target: types::Card32,
26008 format: types::Card32,
26009 type_: types::Card32,
26010 swap_bytes: types::Bool,
26011 ) -> futures::SendRequest<'this, Self, types::glx::GetConvolutionFilterReply> {
26012 let span = tracing::info_span!(
26013 "glx_get_convolution_filter",
26014 context_tag = ?context_tag,
26015 target = ?target,
26016 format = ?format,
26017 type_ = ?type_,
26018 swap_bytes = ?swap_bytes,
26019 );
26020 let request = types::glx::GetConvolutionFilterRequest {
26021 context_tag,
26022 target,
26023 format,
26024 type_,
26025 swap_bytes,
26026 };
26027 let cookie = self.send_reply_request(request).with_span(span);
26028 cookie
26029 }
26030 #[cfg(feature = "glx")]
26031 fn glx_get_convolution_filter_immediate<'this>(
26032 &'this mut self,
26033 context_tag: types::ContextTag,
26034 target: types::Card32,
26035 format: types::Card32,
26036 type_: types::Card32,
26037 swap_bytes: types::Bool,
26038 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetConvolutionFilterReply> {
26039 let request = types::glx::GetConvolutionFilterRequest {
26040 context_tag,
26041 target,
26042 format,
26043 type_,
26044 swap_bytes,
26045 };
26046 let cookie = self.send_reply_request(request);
26047 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetConvolutionFilterReply> =
26048 cookie.into();
26049 res
26050 }
26051 #[cfg(feature = "glx")]
26052 fn glx_get_convolution_parameterfv<'this>(
26053 &'this mut self,
26054 context_tag: types::ContextTag,
26055 target: types::Card32,
26056 pname: types::Card32,
26057 ) -> futures::SendRequest<'this, Self, types::glx::GetConvolutionParameterfvReply> {
26058 let span = tracing::info_span!(
26059 "glx_get_convolution_parameterfv",
26060 context_tag = ?context_tag,
26061 target = ?target,
26062 pname = ?pname,
26063 );
26064 let request = types::glx::GetConvolutionParameterfvRequest {
26065 context_tag,
26066 target,
26067 pname,
26068 };
26069 let cookie = self.send_reply_request(request).with_span(span);
26070 cookie
26071 }
26072 #[cfg(feature = "glx")]
26073 fn glx_get_convolution_parameterfv_immediate<'this>(
26074 &'this mut self,
26075 context_tag: types::ContextTag,
26076 target: types::Card32,
26077 pname: types::Card32,
26078 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetConvolutionParameterfvReply> {
26079 let request = types::glx::GetConvolutionParameterfvRequest {
26080 context_tag,
26081 target,
26082 pname,
26083 };
26084 let cookie = self.send_reply_request(request);
26085 let res: futures::CheckedSendRequest<
26086 'this,
26087 Self,
26088 types::glx::GetConvolutionParameterfvReply,
26089 > = cookie.into();
26090 res
26091 }
26092 #[cfg(feature = "glx")]
26093 fn glx_get_convolution_parameteriv<'this>(
26094 &'this mut self,
26095 context_tag: types::ContextTag,
26096 target: types::Card32,
26097 pname: types::Card32,
26098 ) -> futures::SendRequest<'this, Self, types::glx::GetConvolutionParameterivReply> {
26099 let span = tracing::info_span!(
26100 "glx_get_convolution_parameteriv",
26101 context_tag = ?context_tag,
26102 target = ?target,
26103 pname = ?pname,
26104 );
26105 let request = types::glx::GetConvolutionParameterivRequest {
26106 context_tag,
26107 target,
26108 pname,
26109 };
26110 let cookie = self.send_reply_request(request).with_span(span);
26111 cookie
26112 }
26113 #[cfg(feature = "glx")]
26114 fn glx_get_convolution_parameteriv_immediate<'this>(
26115 &'this mut self,
26116 context_tag: types::ContextTag,
26117 target: types::Card32,
26118 pname: types::Card32,
26119 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetConvolutionParameterivReply> {
26120 let request = types::glx::GetConvolutionParameterivRequest {
26121 context_tag,
26122 target,
26123 pname,
26124 };
26125 let cookie = self.send_reply_request(request);
26126 let res: futures::CheckedSendRequest<
26127 'this,
26128 Self,
26129 types::glx::GetConvolutionParameterivReply,
26130 > = cookie.into();
26131 res
26132 }
26133 #[cfg(feature = "glx")]
26134 fn glx_get_separable_filter<'this>(
26135 &'this mut self,
26136 context_tag: types::ContextTag,
26137 target: types::Card32,
26138 format: types::Card32,
26139 type_: types::Card32,
26140 swap_bytes: types::Bool,
26141 ) -> futures::SendRequest<'this, Self, types::glx::GetSeparableFilterReply> {
26142 let span = tracing::info_span!(
26143 "glx_get_separable_filter",
26144 context_tag = ?context_tag,
26145 target = ?target,
26146 format = ?format,
26147 type_ = ?type_,
26148 swap_bytes = ?swap_bytes,
26149 );
26150 let request = types::glx::GetSeparableFilterRequest {
26151 context_tag,
26152 target,
26153 format,
26154 type_,
26155 swap_bytes,
26156 };
26157 let cookie = self.send_reply_request(request).with_span(span);
26158 cookie
26159 }
26160 #[cfg(feature = "glx")]
26161 fn glx_get_separable_filter_immediate<'this>(
26162 &'this mut self,
26163 context_tag: types::ContextTag,
26164 target: types::Card32,
26165 format: types::Card32,
26166 type_: types::Card32,
26167 swap_bytes: types::Bool,
26168 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetSeparableFilterReply> {
26169 let request = types::glx::GetSeparableFilterRequest {
26170 context_tag,
26171 target,
26172 format,
26173 type_,
26174 swap_bytes,
26175 };
26176 let cookie = self.send_reply_request(request);
26177 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetSeparableFilterReply> =
26178 cookie.into();
26179 res
26180 }
26181 #[cfg(feature = "glx")]
26182 fn glx_get_histogram<'this>(
26183 &'this mut self,
26184 context_tag: types::ContextTag,
26185 target: types::Card32,
26186 format: types::Card32,
26187 type_: types::Card32,
26188 swap_bytes: types::Bool,
26189 reset: types::Bool,
26190 ) -> futures::SendRequest<'this, Self, types::glx::GetHistogramReply> {
26191 let span = tracing::info_span!(
26192 "glx_get_histogram",
26193 context_tag = ?context_tag,
26194 target = ?target,
26195 format = ?format,
26196 type_ = ?type_,
26197 swap_bytes = ?swap_bytes,
26198 reset = ?reset,
26199 );
26200 let request = types::glx::GetHistogramRequest {
26201 context_tag,
26202 target,
26203 format,
26204 type_,
26205 swap_bytes,
26206 reset,
26207 };
26208 let cookie = self.send_reply_request(request).with_span(span);
26209 cookie
26210 }
26211 #[cfg(feature = "glx")]
26212 fn glx_get_histogram_immediate<'this>(
26213 &'this mut self,
26214 context_tag: types::ContextTag,
26215 target: types::Card32,
26216 format: types::Card32,
26217 type_: types::Card32,
26218 swap_bytes: types::Bool,
26219 reset: types::Bool,
26220 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetHistogramReply> {
26221 let request = types::glx::GetHistogramRequest {
26222 context_tag,
26223 target,
26224 format,
26225 type_,
26226 swap_bytes,
26227 reset,
26228 };
26229 let cookie = self.send_reply_request(request);
26230 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetHistogramReply> =
26231 cookie.into();
26232 res
26233 }
26234 #[cfg(feature = "glx")]
26235 fn glx_get_histogram_parameterfv<'this>(
26236 &'this mut self,
26237 context_tag: types::ContextTag,
26238 target: types::Card32,
26239 pname: types::Card32,
26240 ) -> futures::SendRequest<'this, Self, types::glx::GetHistogramParameterfvReply> {
26241 let span = tracing::info_span!(
26242 "glx_get_histogram_parameterfv",
26243 context_tag = ?context_tag,
26244 target = ?target,
26245 pname = ?pname,
26246 );
26247 let request = types::glx::GetHistogramParameterfvRequest {
26248 context_tag,
26249 target,
26250 pname,
26251 };
26252 let cookie = self.send_reply_request(request).with_span(span);
26253 cookie
26254 }
26255 #[cfg(feature = "glx")]
26256 fn glx_get_histogram_parameterfv_immediate<'this>(
26257 &'this mut self,
26258 context_tag: types::ContextTag,
26259 target: types::Card32,
26260 pname: types::Card32,
26261 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetHistogramParameterfvReply> {
26262 let request = types::glx::GetHistogramParameterfvRequest {
26263 context_tag,
26264 target,
26265 pname,
26266 };
26267 let cookie = self.send_reply_request(request);
26268 let res: futures::CheckedSendRequest<
26269 'this,
26270 Self,
26271 types::glx::GetHistogramParameterfvReply,
26272 > = cookie.into();
26273 res
26274 }
26275 #[cfg(feature = "glx")]
26276 fn glx_get_histogram_parameteriv<'this>(
26277 &'this mut self,
26278 context_tag: types::ContextTag,
26279 target: types::Card32,
26280 pname: types::Card32,
26281 ) -> futures::SendRequest<'this, Self, types::glx::GetHistogramParameterivReply> {
26282 let span = tracing::info_span!(
26283 "glx_get_histogram_parameteriv",
26284 context_tag = ?context_tag,
26285 target = ?target,
26286 pname = ?pname,
26287 );
26288 let request = types::glx::GetHistogramParameterivRequest {
26289 context_tag,
26290 target,
26291 pname,
26292 };
26293 let cookie = self.send_reply_request(request).with_span(span);
26294 cookie
26295 }
26296 #[cfg(feature = "glx")]
26297 fn glx_get_histogram_parameteriv_immediate<'this>(
26298 &'this mut self,
26299 context_tag: types::ContextTag,
26300 target: types::Card32,
26301 pname: types::Card32,
26302 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetHistogramParameterivReply> {
26303 let request = types::glx::GetHistogramParameterivRequest {
26304 context_tag,
26305 target,
26306 pname,
26307 };
26308 let cookie = self.send_reply_request(request);
26309 let res: futures::CheckedSendRequest<
26310 'this,
26311 Self,
26312 types::glx::GetHistogramParameterivReply,
26313 > = cookie.into();
26314 res
26315 }
26316 #[cfg(feature = "glx")]
26317 fn glx_get_minmax<'this>(
26318 &'this mut self,
26319 context_tag: types::ContextTag,
26320 target: types::Card32,
26321 format: types::Card32,
26322 type_: types::Card32,
26323 swap_bytes: types::Bool,
26324 reset: types::Bool,
26325 ) -> futures::SendRequest<'this, Self, types::glx::GetMinmaxReply> {
26326 let span = tracing::info_span!(
26327 "glx_get_minmax",
26328 context_tag = ?context_tag,
26329 target = ?target,
26330 format = ?format,
26331 type_ = ?type_,
26332 swap_bytes = ?swap_bytes,
26333 reset = ?reset,
26334 );
26335 let request = types::glx::GetMinmaxRequest {
26336 context_tag,
26337 target,
26338 format,
26339 type_,
26340 swap_bytes,
26341 reset,
26342 };
26343 let cookie = self.send_reply_request(request).with_span(span);
26344 cookie
26345 }
26346 #[cfg(feature = "glx")]
26347 fn glx_get_minmax_immediate<'this>(
26348 &'this mut self,
26349 context_tag: types::ContextTag,
26350 target: types::Card32,
26351 format: types::Card32,
26352 type_: types::Card32,
26353 swap_bytes: types::Bool,
26354 reset: types::Bool,
26355 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetMinmaxReply> {
26356 let request = types::glx::GetMinmaxRequest {
26357 context_tag,
26358 target,
26359 format,
26360 type_,
26361 swap_bytes,
26362 reset,
26363 };
26364 let cookie = self.send_reply_request(request);
26365 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetMinmaxReply> =
26366 cookie.into();
26367 res
26368 }
26369 #[cfg(feature = "glx")]
26370 fn glx_get_minmax_parameterfv<'this>(
26371 &'this mut self,
26372 context_tag: types::ContextTag,
26373 target: types::Card32,
26374 pname: types::Card32,
26375 ) -> futures::SendRequest<'this, Self, types::glx::GetMinmaxParameterfvReply> {
26376 let span = tracing::info_span!(
26377 "glx_get_minmax_parameterfv",
26378 context_tag = ?context_tag,
26379 target = ?target,
26380 pname = ?pname,
26381 );
26382 let request = types::glx::GetMinmaxParameterfvRequest {
26383 context_tag,
26384 target,
26385 pname,
26386 };
26387 let cookie = self.send_reply_request(request).with_span(span);
26388 cookie
26389 }
26390 #[cfg(feature = "glx")]
26391 fn glx_get_minmax_parameterfv_immediate<'this>(
26392 &'this mut self,
26393 context_tag: types::ContextTag,
26394 target: types::Card32,
26395 pname: types::Card32,
26396 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetMinmaxParameterfvReply> {
26397 let request = types::glx::GetMinmaxParameterfvRequest {
26398 context_tag,
26399 target,
26400 pname,
26401 };
26402 let cookie = self.send_reply_request(request);
26403 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetMinmaxParameterfvReply> =
26404 cookie.into();
26405 res
26406 }
26407 #[cfg(feature = "glx")]
26408 fn glx_get_minmax_parameteriv<'this>(
26409 &'this mut self,
26410 context_tag: types::ContextTag,
26411 target: types::Card32,
26412 pname: types::Card32,
26413 ) -> futures::SendRequest<'this, Self, types::glx::GetMinmaxParameterivReply> {
26414 let span = tracing::info_span!(
26415 "glx_get_minmax_parameteriv",
26416 context_tag = ?context_tag,
26417 target = ?target,
26418 pname = ?pname,
26419 );
26420 let request = types::glx::GetMinmaxParameterivRequest {
26421 context_tag,
26422 target,
26423 pname,
26424 };
26425 let cookie = self.send_reply_request(request).with_span(span);
26426 cookie
26427 }
26428 #[cfg(feature = "glx")]
26429 fn glx_get_minmax_parameteriv_immediate<'this>(
26430 &'this mut self,
26431 context_tag: types::ContextTag,
26432 target: types::Card32,
26433 pname: types::Card32,
26434 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetMinmaxParameterivReply> {
26435 let request = types::glx::GetMinmaxParameterivRequest {
26436 context_tag,
26437 target,
26438 pname,
26439 };
26440 let cookie = self.send_reply_request(request);
26441 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetMinmaxParameterivReply> =
26442 cookie.into();
26443 res
26444 }
26445 #[cfg(feature = "glx")]
26446 fn glx_get_compressed_tex_image_arb<'this>(
26447 &'this mut self,
26448 context_tag: types::ContextTag,
26449 target: types::Card32,
26450 level: types::Int32,
26451 ) -> futures::SendRequest<'this, Self, types::glx::GetCompressedTexImageARBReply> {
26452 let span = tracing::info_span!(
26453 "glx_get_compressed_tex_image_arb",
26454 context_tag = ?context_tag,
26455 target = ?target,
26456 level = ?level,
26457 );
26458 let request = types::glx::GetCompressedTexImageARBRequest {
26459 context_tag,
26460 target,
26461 level,
26462 };
26463 let cookie = self.send_reply_request(request).with_span(span);
26464 cookie
26465 }
26466 #[cfg(feature = "glx")]
26467 fn glx_get_compressed_tex_image_arb_immediate<'this>(
26468 &'this mut self,
26469 context_tag: types::ContextTag,
26470 target: types::Card32,
26471 level: types::Int32,
26472 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetCompressedTexImageARBReply> {
26473 let request = types::glx::GetCompressedTexImageARBRequest {
26474 context_tag,
26475 target,
26476 level,
26477 };
26478 let cookie = self.send_reply_request(request);
26479 let res: futures::CheckedSendRequest<
26480 'this,
26481 Self,
26482 types::glx::GetCompressedTexImageARBReply,
26483 > = cookie.into();
26484 res
26485 }
26486 #[cfg(feature = "glx")]
26487 fn glx_delete_queries_arb<'this>(
26488 &'this mut self,
26489 context_tag: types::ContextTag,
26490 ids: impl AsRef<[types::Card32]>,
26491 ) -> futures::SendRequest<'this, Self, ()> {
26492 let span = tracing::info_span!(
26493 "glx_delete_queries_arb",
26494 context_tag = ?context_tag,
26495 );
26496 let request = types::glx::DeleteQueriesARBRequest {
26497 context_tag,
26498 ids: Cow::Borrowed(ids.as_ref()),
26499 };
26500 let cookie = self.send_void_request(request, true).with_span(span);
26501 cookie
26502 }
26503 #[cfg(feature = "glx")]
26504 fn glx_delete_queries_arb_checked<'this>(
26505 &'this mut self,
26506 context_tag: types::ContextTag,
26507 ids: impl AsRef<[types::Card32]>,
26508 ) -> futures::CheckedSendRequest<'this, Self, ()> {
26509 let request = types::glx::DeleteQueriesARBRequest {
26510 context_tag,
26511 ids: Cow::Borrowed(ids.as_ref()),
26512 };
26513 let cookie = self.send_void_request(request, false);
26514 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
26515 res
26516 }
26517 #[cfg(feature = "glx")]
26518 fn glx_gen_queries_arb<'this>(
26519 &'this mut self,
26520 context_tag: types::ContextTag,
26521 n: types::Int32,
26522 ) -> futures::SendRequest<'this, Self, types::glx::GenQueriesARBReply> {
26523 let span = tracing::info_span!(
26524 "glx_gen_queries_arb",
26525 context_tag = ?context_tag,
26526 n = ?n,
26527 );
26528 let request = types::glx::GenQueriesARBRequest { context_tag, n };
26529 let cookie = self.send_reply_request(request).with_span(span);
26530 cookie
26531 }
26532 #[cfg(feature = "glx")]
26533 fn glx_gen_queries_arb_immediate<'this>(
26534 &'this mut self,
26535 context_tag: types::ContextTag,
26536 n: types::Int32,
26537 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GenQueriesARBReply> {
26538 let request = types::glx::GenQueriesARBRequest { context_tag, n };
26539 let cookie = self.send_reply_request(request);
26540 let res: futures::CheckedSendRequest<'this, Self, types::glx::GenQueriesARBReply> =
26541 cookie.into();
26542 res
26543 }
26544 #[cfg(feature = "glx")]
26545 fn glx_is_query_arb<'this>(
26546 &'this mut self,
26547 context_tag: types::ContextTag,
26548 id: types::Card32,
26549 ) -> futures::SendRequest<'this, Self, types::glx::IsQueryARBReply> {
26550 let span = tracing::info_span!(
26551 "glx_is_query_arb",
26552 context_tag = ?context_tag,
26553 id = ?id,
26554 );
26555 let request = types::glx::IsQueryARBRequest { context_tag, id };
26556 let cookie = self.send_reply_request(request).with_span(span);
26557 cookie
26558 }
26559 #[cfg(feature = "glx")]
26560 fn glx_is_query_arb_immediate<'this>(
26561 &'this mut self,
26562 context_tag: types::ContextTag,
26563 id: types::Card32,
26564 ) -> futures::CheckedSendRequest<'this, Self, types::glx::IsQueryARBReply> {
26565 let request = types::glx::IsQueryARBRequest { context_tag, id };
26566 let cookie = self.send_reply_request(request);
26567 let res: futures::CheckedSendRequest<'this, Self, types::glx::IsQueryARBReply> =
26568 cookie.into();
26569 res
26570 }
26571 #[cfg(feature = "glx")]
26572 fn glx_get_queryiv_arb<'this>(
26573 &'this mut self,
26574 context_tag: types::ContextTag,
26575 target: types::Card32,
26576 pname: types::Card32,
26577 ) -> futures::SendRequest<'this, Self, types::glx::GetQueryivARBReply> {
26578 let span = tracing::info_span!(
26579 "glx_get_queryiv_arb",
26580 context_tag = ?context_tag,
26581 target = ?target,
26582 pname = ?pname,
26583 );
26584 let request = types::glx::GetQueryivARBRequest {
26585 context_tag,
26586 target,
26587 pname,
26588 };
26589 let cookie = self.send_reply_request(request).with_span(span);
26590 cookie
26591 }
26592 #[cfg(feature = "glx")]
26593 fn glx_get_queryiv_arb_immediate<'this>(
26594 &'this mut self,
26595 context_tag: types::ContextTag,
26596 target: types::Card32,
26597 pname: types::Card32,
26598 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetQueryivARBReply> {
26599 let request = types::glx::GetQueryivARBRequest {
26600 context_tag,
26601 target,
26602 pname,
26603 };
26604 let cookie = self.send_reply_request(request);
26605 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetQueryivARBReply> =
26606 cookie.into();
26607 res
26608 }
26609 #[cfg(feature = "glx")]
26610 fn glx_get_query_objectiv_arb<'this>(
26611 &'this mut self,
26612 context_tag: types::ContextTag,
26613 id: types::Card32,
26614 pname: types::Card32,
26615 ) -> futures::SendRequest<'this, Self, types::glx::GetQueryObjectivARBReply> {
26616 let span = tracing::info_span!(
26617 "glx_get_query_objectiv_arb",
26618 context_tag = ?context_tag,
26619 id = ?id,
26620 pname = ?pname,
26621 );
26622 let request = types::glx::GetQueryObjectivARBRequest {
26623 context_tag,
26624 id,
26625 pname,
26626 };
26627 let cookie = self.send_reply_request(request).with_span(span);
26628 cookie
26629 }
26630 #[cfg(feature = "glx")]
26631 fn glx_get_query_objectiv_arb_immediate<'this>(
26632 &'this mut self,
26633 context_tag: types::ContextTag,
26634 id: types::Card32,
26635 pname: types::Card32,
26636 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetQueryObjectivARBReply> {
26637 let request = types::glx::GetQueryObjectivARBRequest {
26638 context_tag,
26639 id,
26640 pname,
26641 };
26642 let cookie = self.send_reply_request(request);
26643 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetQueryObjectivARBReply> =
26644 cookie.into();
26645 res
26646 }
26647 #[cfg(feature = "glx")]
26648 fn glx_get_query_objectuiv_arb<'this>(
26649 &'this mut self,
26650 context_tag: types::ContextTag,
26651 id: types::Card32,
26652 pname: types::Card32,
26653 ) -> futures::SendRequest<'this, Self, types::glx::GetQueryObjectuivARBReply> {
26654 let span = tracing::info_span!(
26655 "glx_get_query_objectuiv_arb",
26656 context_tag = ?context_tag,
26657 id = ?id,
26658 pname = ?pname,
26659 );
26660 let request = types::glx::GetQueryObjectuivARBRequest {
26661 context_tag,
26662 id,
26663 pname,
26664 };
26665 let cookie = self.send_reply_request(request).with_span(span);
26666 cookie
26667 }
26668 #[cfg(feature = "glx")]
26669 fn glx_get_query_objectuiv_arb_immediate<'this>(
26670 &'this mut self,
26671 context_tag: types::ContextTag,
26672 id: types::Card32,
26673 pname: types::Card32,
26674 ) -> futures::CheckedSendRequest<'this, Self, types::glx::GetQueryObjectuivARBReply> {
26675 let request = types::glx::GetQueryObjectuivARBRequest {
26676 context_tag,
26677 id,
26678 pname,
26679 };
26680 let cookie = self.send_reply_request(request);
26681 let res: futures::CheckedSendRequest<'this, Self, types::glx::GetQueryObjectuivARBReply> =
26682 cookie.into();
26683 res
26684 }
26685
26686 #[cfg(feature = "present")]
26687 fn present_query_version<'this>(
26688 &'this mut self,
26689 major_version: types::Card32,
26690 minor_version: types::Card32,
26691 ) -> futures::SendRequest<'this, Self, types::present::QueryVersionReply> {
26692 let span = tracing::info_span!(
26693 "present_query_version",
26694 major_version = ?major_version,
26695 minor_version = ?minor_version,
26696 );
26697 let request = types::present::QueryVersionRequest {
26698 major_version,
26699 minor_version,
26700 };
26701 let cookie = self.send_reply_request(request).with_span(span);
26702 cookie
26703 }
26704 #[cfg(feature = "present")]
26705 fn present_query_version_immediate<'this>(
26706 &'this mut self,
26707 major_version: types::Card32,
26708 minor_version: types::Card32,
26709 ) -> futures::CheckedSendRequest<'this, Self, types::present::QueryVersionReply> {
26710 let request = types::present::QueryVersionRequest {
26711 major_version,
26712 minor_version,
26713 };
26714 let cookie = self.send_reply_request(request);
26715 let res: futures::CheckedSendRequest<'this, Self, types::present::QueryVersionReply> =
26716 cookie.into();
26717 res
26718 }
26719 #[cfg(feature = "present")]
26720 fn present_pixmap<'this>(
26721 &'this mut self,
26722 window: types::xproto::Window,
26723 pixmap: types::xproto::Pixmap,
26724 serial: types::Card32,
26725 valid: types::Region,
26726 update: types::Region,
26727 x_off: types::Int16,
26728 y_off: types::Int16,
26729 target_crtc: types::Crtc,
26730 wait_fence: types::Fence,
26731 idle_fence: types::Fence,
26732 options: types::Card32,
26733 target_msc: types::Card64,
26734 divisor: types::Card64,
26735 remainder: types::Card64,
26736 notifies: impl AsRef<[types::present::Notify]>,
26737 ) -> futures::SendRequest<'this, Self, ()> {
26738 let span = tracing::info_span!(
26739 "present_pixmap",
26740 window = ?window,
26741 pixmap = ?pixmap,
26742 serial = ?serial,
26743 valid = ?valid,
26744 update = ?update,
26745 x_off = ?x_off,
26746 y_off = ?y_off,
26747 target_crtc = ?target_crtc,
26748 wait_fence = ?wait_fence,
26749 idle_fence = ?idle_fence,
26750 options = ?options,
26751 target_msc = ?target_msc,
26752 divisor = ?divisor,
26753 remainder = ?remainder,
26754 );
26755 let request = types::present::PixmapRequest {
26756 window,
26757 pixmap,
26758 serial,
26759 valid,
26760 update,
26761 x_off,
26762 y_off,
26763 target_crtc,
26764 wait_fence,
26765 idle_fence,
26766 options,
26767 target_msc,
26768 divisor,
26769 remainder,
26770 notifies: Cow::Borrowed(notifies.as_ref()),
26771 };
26772 let cookie = self.send_void_request(request, true).with_span(span);
26773 cookie
26774 }
26775 #[cfg(feature = "present")]
26776 fn present_pixmap_checked<'this>(
26777 &'this mut self,
26778 window: types::xproto::Window,
26779 pixmap: types::xproto::Pixmap,
26780 serial: types::Card32,
26781 valid: types::Region,
26782 update: types::Region,
26783 x_off: types::Int16,
26784 y_off: types::Int16,
26785 target_crtc: types::Crtc,
26786 wait_fence: types::Fence,
26787 idle_fence: types::Fence,
26788 options: types::Card32,
26789 target_msc: types::Card64,
26790 divisor: types::Card64,
26791 remainder: types::Card64,
26792 notifies: impl AsRef<[types::present::Notify]>,
26793 ) -> futures::CheckedSendRequest<'this, Self, ()> {
26794 let request = types::present::PixmapRequest {
26795 window,
26796 pixmap,
26797 serial,
26798 valid,
26799 update,
26800 x_off,
26801 y_off,
26802 target_crtc,
26803 wait_fence,
26804 idle_fence,
26805 options,
26806 target_msc,
26807 divisor,
26808 remainder,
26809 notifies: Cow::Borrowed(notifies.as_ref()),
26810 };
26811 let cookie = self.send_void_request(request, false);
26812 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
26813 res
26814 }
26815 #[cfg(feature = "present")]
26816 fn present_notify_msc<'this>(
26817 &'this mut self,
26818 window: types::xproto::Window,
26819 serial: types::Card32,
26820 target_msc: types::Card64,
26821 divisor: types::Card64,
26822 remainder: types::Card64,
26823 ) -> futures::SendRequest<'this, Self, ()> {
26824 let span = tracing::info_span!(
26825 "present_notify_msc",
26826 window = ?window,
26827 serial = ?serial,
26828 target_msc = ?target_msc,
26829 divisor = ?divisor,
26830 remainder = ?remainder,
26831 );
26832 let request = types::present::NotifyMSCRequest {
26833 window,
26834 serial,
26835 target_msc,
26836 divisor,
26837 remainder,
26838 };
26839 let cookie = self.send_void_request(request, true).with_span(span);
26840 cookie
26841 }
26842 #[cfg(feature = "present")]
26843 fn present_notify_msc_checked<'this>(
26844 &'this mut self,
26845 window: types::xproto::Window,
26846 serial: types::Card32,
26847 target_msc: types::Card64,
26848 divisor: types::Card64,
26849 remainder: types::Card64,
26850 ) -> futures::CheckedSendRequest<'this, Self, ()> {
26851 let request = types::present::NotifyMSCRequest {
26852 window,
26853 serial,
26854 target_msc,
26855 divisor,
26856 remainder,
26857 };
26858 let cookie = self.send_void_request(request, false);
26859 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
26860 res
26861 }
26862 #[cfg(feature = "present")]
26863 fn present_select_input<'this>(
26864 &'this mut self,
26865 eid: types::present::Event,
26866 window: types::xproto::Window,
26867 event_mask: impl Into<types::present::EventMask>,
26868 ) -> futures::SendRequest<'this, Self, ()> {
26869 let span = tracing::info_span!(
26870 "present_select_input",
26871 eid = ?eid,
26872 window = ?window,
26873 );
26874 let request = types::present::SelectInputRequest {
26875 eid,
26876 window,
26877 event_mask: Into::<u32>::into(event_mask.into()) as _,
26878 };
26879 let cookie = self.send_void_request(request, true).with_span(span);
26880 cookie
26881 }
26882 #[cfg(feature = "present")]
26883 fn present_select_input_checked<'this>(
26884 &'this mut self,
26885 eid: types::present::Event,
26886 window: types::xproto::Window,
26887 event_mask: impl Into<types::present::EventMask>,
26888 ) -> futures::CheckedSendRequest<'this, Self, ()> {
26889 let request = types::present::SelectInputRequest {
26890 eid,
26891 window,
26892 event_mask: Into::<u32>::into(event_mask.into()) as _,
26893 };
26894 let cookie = self.send_void_request(request, false);
26895 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
26896 res
26897 }
26898 #[cfg(feature = "present")]
26899 fn present_query_capabilities<'this>(
26900 &'this mut self,
26901 target: types::Card32,
26902 ) -> futures::SendRequest<'this, Self, types::present::QueryCapabilitiesReply> {
26903 let span = tracing::info_span!(
26904 "present_query_capabilities",
26905 target = ?target,
26906 );
26907 let request = types::present::QueryCapabilitiesRequest { target };
26908 let cookie = self.send_reply_request(request).with_span(span);
26909 cookie
26910 }
26911 #[cfg(feature = "present")]
26912 fn present_query_capabilities_immediate<'this>(
26913 &'this mut self,
26914 target: types::Card32,
26915 ) -> futures::CheckedSendRequest<'this, Self, types::present::QueryCapabilitiesReply> {
26916 let request = types::present::QueryCapabilitiesRequest { target };
26917 let cookie = self.send_reply_request(request);
26918 let res: futures::CheckedSendRequest<'this, Self, types::present::QueryCapabilitiesReply> =
26919 cookie.into();
26920 res
26921 }
26922
26923 #[cfg(feature = "randr")]
26924 fn randr_query_version<'this>(
26925 &'this mut self,
26926 major_version: types::Card32,
26927 minor_version: types::Card32,
26928 ) -> futures::SendRequest<'this, Self, types::randr::QueryVersionReply> {
26929 let span = tracing::info_span!(
26930 "randr_query_version",
26931 major_version = ?major_version,
26932 minor_version = ?minor_version,
26933 );
26934 let request = types::randr::QueryVersionRequest {
26935 major_version,
26936 minor_version,
26937 };
26938 let cookie = self.send_reply_request(request).with_span(span);
26939 cookie
26940 }
26941 #[cfg(feature = "randr")]
26942 fn randr_query_version_immediate<'this>(
26943 &'this mut self,
26944 major_version: types::Card32,
26945 minor_version: types::Card32,
26946 ) -> futures::CheckedSendRequest<'this, Self, types::randr::QueryVersionReply> {
26947 let request = types::randr::QueryVersionRequest {
26948 major_version,
26949 minor_version,
26950 };
26951 let cookie = self.send_reply_request(request);
26952 let res: futures::CheckedSendRequest<'this, Self, types::randr::QueryVersionReply> =
26953 cookie.into();
26954 res
26955 }
26956 #[cfg(feature = "randr")]
26957 fn randr_set_screen_config<'this>(
26958 &'this mut self,
26959 window: types::xproto::Window,
26960 timestamp: types::Timestamp,
26961 config_timestamp: types::Timestamp,
26962 size_id: types::Card16,
26963 rotation: impl Into<types::Rotation>,
26964 rate: types::Card16,
26965 ) -> futures::SendRequest<'this, Self, types::randr::SetScreenConfigReply> {
26966 let span = tracing::info_span!(
26967 "randr_set_screen_config",
26968 window = ?window,
26969 timestamp = ?timestamp,
26970 config_timestamp = ?config_timestamp,
26971 size_id = ?size_id,
26972 rate = ?rate,
26973 );
26974 let request = types::randr::SetScreenConfigRequest {
26975 window,
26976 timestamp,
26977 config_timestamp,
26978 size_id,
26979 rotation: Into::<u32>::into(rotation.into()) as _,
26980 rate,
26981 };
26982 let cookie = self.send_reply_request(request).with_span(span);
26983 cookie
26984 }
26985 #[cfg(feature = "randr")]
26986 fn randr_set_screen_config_immediate<'this>(
26987 &'this mut self,
26988 window: types::xproto::Window,
26989 timestamp: types::Timestamp,
26990 config_timestamp: types::Timestamp,
26991 size_id: types::Card16,
26992 rotation: impl Into<types::Rotation>,
26993 rate: types::Card16,
26994 ) -> futures::CheckedSendRequest<'this, Self, types::randr::SetScreenConfigReply> {
26995 let request = types::randr::SetScreenConfigRequest {
26996 window,
26997 timestamp,
26998 config_timestamp,
26999 size_id,
27000 rotation: Into::<u32>::into(rotation.into()) as _,
27001 rate,
27002 };
27003 let cookie = self.send_reply_request(request);
27004 let res: futures::CheckedSendRequest<'this, Self, types::randr::SetScreenConfigReply> =
27005 cookie.into();
27006 res
27007 }
27008 #[cfg(feature = "randr")]
27009 fn randr_select_input<'this>(
27010 &'this mut self,
27011 window: types::xproto::Window,
27012 enable: impl Into<types::NotifyMask>,
27013 ) -> futures::SendRequest<'this, Self, ()> {
27014 let span = tracing::info_span!(
27015 "randr_select_input",
27016 window = ?window,
27017 );
27018 let request = types::randr::SelectInputRequest {
27019 window,
27020 enable: Into::<u32>::into(enable.into()) as _,
27021 };
27022 let cookie = self.send_void_request(request, true).with_span(span);
27023 cookie
27024 }
27025 #[cfg(feature = "randr")]
27026 fn randr_select_input_checked<'this>(
27027 &'this mut self,
27028 window: types::xproto::Window,
27029 enable: impl Into<types::NotifyMask>,
27030 ) -> futures::CheckedSendRequest<'this, Self, ()> {
27031 let request = types::randr::SelectInputRequest {
27032 window,
27033 enable: Into::<u32>::into(enable.into()) as _,
27034 };
27035 let cookie = self.send_void_request(request, false);
27036 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
27037 res
27038 }
27039 #[cfg(feature = "randr")]
27040 fn randr_get_screen_info<'this>(
27041 &'this mut self,
27042 window: types::xproto::Window,
27043 ) -> futures::SendRequest<'this, Self, types::randr::GetScreenInfoReply> {
27044 let span = tracing::info_span!(
27045 "randr_get_screen_info",
27046 window = ?window,
27047 );
27048 let request = types::randr::GetScreenInfoRequest { window };
27049 let cookie = self.send_reply_request(request).with_span(span);
27050 cookie
27051 }
27052 #[cfg(feature = "randr")]
27053 fn randr_get_screen_info_immediate<'this>(
27054 &'this mut self,
27055 window: types::xproto::Window,
27056 ) -> futures::CheckedSendRequest<'this, Self, types::randr::GetScreenInfoReply> {
27057 let request = types::randr::GetScreenInfoRequest { window };
27058 let cookie = self.send_reply_request(request);
27059 let res: futures::CheckedSendRequest<'this, Self, types::randr::GetScreenInfoReply> =
27060 cookie.into();
27061 res
27062 }
27063 #[cfg(feature = "randr")]
27064 fn randr_get_screen_size_range<'this>(
27065 &'this mut self,
27066 window: types::xproto::Window,
27067 ) -> futures::SendRequest<'this, Self, types::randr::GetScreenSizeRangeReply> {
27068 let span = tracing::info_span!(
27069 "randr_get_screen_size_range",
27070 window = ?window,
27071 );
27072 let request = types::randr::GetScreenSizeRangeRequest { window };
27073 let cookie = self.send_reply_request(request).with_span(span);
27074 cookie
27075 }
27076 #[cfg(feature = "randr")]
27077 fn randr_get_screen_size_range_immediate<'this>(
27078 &'this mut self,
27079 window: types::xproto::Window,
27080 ) -> futures::CheckedSendRequest<'this, Self, types::randr::GetScreenSizeRangeReply> {
27081 let request = types::randr::GetScreenSizeRangeRequest { window };
27082 let cookie = self.send_reply_request(request);
27083 let res: futures::CheckedSendRequest<'this, Self, types::randr::GetScreenSizeRangeReply> =
27084 cookie.into();
27085 res
27086 }
27087 #[cfg(feature = "randr")]
27088 fn randr_set_screen_size<'this>(
27089 &'this mut self,
27090 window: types::xproto::Window,
27091 width: types::Card16,
27092 height: types::Card16,
27093 mm_width: types::Card32,
27094 mm_height: types::Card32,
27095 ) -> futures::SendRequest<'this, Self, ()> {
27096 let span = tracing::info_span!(
27097 "randr_set_screen_size",
27098 window = ?window,
27099 width = ?width,
27100 height = ?height,
27101 mm_width = ?mm_width,
27102 mm_height = ?mm_height,
27103 );
27104 let request = types::randr::SetScreenSizeRequest {
27105 window,
27106 width,
27107 height,
27108 mm_width,
27109 mm_height,
27110 };
27111 let cookie = self.send_void_request(request, true).with_span(span);
27112 cookie
27113 }
27114 #[cfg(feature = "randr")]
27115 fn randr_set_screen_size_checked<'this>(
27116 &'this mut self,
27117 window: types::xproto::Window,
27118 width: types::Card16,
27119 height: types::Card16,
27120 mm_width: types::Card32,
27121 mm_height: types::Card32,
27122 ) -> futures::CheckedSendRequest<'this, Self, ()> {
27123 let request = types::randr::SetScreenSizeRequest {
27124 window,
27125 width,
27126 height,
27127 mm_width,
27128 mm_height,
27129 };
27130 let cookie = self.send_void_request(request, false);
27131 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
27132 res
27133 }
27134 #[cfg(feature = "randr")]
27135 fn randr_get_screen_resources<'this>(
27136 &'this mut self,
27137 window: types::xproto::Window,
27138 ) -> futures::SendRequest<'this, Self, types::randr::GetScreenResourcesReply> {
27139 let span = tracing::info_span!(
27140 "randr_get_screen_resources",
27141 window = ?window,
27142 );
27143 let request = types::randr::GetScreenResourcesRequest { window };
27144 let cookie = self.send_reply_request(request).with_span(span);
27145 cookie
27146 }
27147 #[cfg(feature = "randr")]
27148 fn randr_get_screen_resources_immediate<'this>(
27149 &'this mut self,
27150 window: types::xproto::Window,
27151 ) -> futures::CheckedSendRequest<'this, Self, types::randr::GetScreenResourcesReply> {
27152 let request = types::randr::GetScreenResourcesRequest { window };
27153 let cookie = self.send_reply_request(request);
27154 let res: futures::CheckedSendRequest<'this, Self, types::randr::GetScreenResourcesReply> =
27155 cookie.into();
27156 res
27157 }
27158 #[cfg(feature = "randr")]
27159 fn randr_get_output_info<'this>(
27160 &'this mut self,
27161 output: types::Output,
27162 config_timestamp: types::Timestamp,
27163 ) -> futures::SendRequest<'this, Self, types::randr::GetOutputInfoReply> {
27164 let span = tracing::info_span!(
27165 "randr_get_output_info",
27166 output = ?output,
27167 config_timestamp = ?config_timestamp,
27168 );
27169 let request = types::randr::GetOutputInfoRequest {
27170 output,
27171 config_timestamp,
27172 };
27173 let cookie = self.send_reply_request(request).with_span(span);
27174 cookie
27175 }
27176 #[cfg(feature = "randr")]
27177 fn randr_get_output_info_immediate<'this>(
27178 &'this mut self,
27179 output: types::Output,
27180 config_timestamp: types::Timestamp,
27181 ) -> futures::CheckedSendRequest<'this, Self, types::randr::GetOutputInfoReply> {
27182 let request = types::randr::GetOutputInfoRequest {
27183 output,
27184 config_timestamp,
27185 };
27186 let cookie = self.send_reply_request(request);
27187 let res: futures::CheckedSendRequest<'this, Self, types::randr::GetOutputInfoReply> =
27188 cookie.into();
27189 res
27190 }
27191 #[cfg(feature = "randr")]
27192 fn randr_list_output_properties<'this>(
27193 &'this mut self,
27194 output: types::Output,
27195 ) -> futures::SendRequest<'this, Self, types::randr::ListOutputPropertiesReply> {
27196 let span = tracing::info_span!(
27197 "randr_list_output_properties",
27198 output = ?output,
27199 );
27200 let request = types::randr::ListOutputPropertiesRequest { output };
27201 let cookie = self.send_reply_request(request).with_span(span);
27202 cookie
27203 }
27204 #[cfg(feature = "randr")]
27205 fn randr_list_output_properties_immediate<'this>(
27206 &'this mut self,
27207 output: types::Output,
27208 ) -> futures::CheckedSendRequest<'this, Self, types::randr::ListOutputPropertiesReply> {
27209 let request = types::randr::ListOutputPropertiesRequest { output };
27210 let cookie = self.send_reply_request(request);
27211 let res: futures::CheckedSendRequest<'this, Self, types::randr::ListOutputPropertiesReply> =
27212 cookie.into();
27213 res
27214 }
27215 #[cfg(feature = "randr")]
27216 fn randr_query_output_property<'this>(
27217 &'this mut self,
27218 output: types::Output,
27219 property: types::Atom,
27220 ) -> futures::SendRequest<'this, Self, types::randr::QueryOutputPropertyReply> {
27221 let span = tracing::info_span!(
27222 "randr_query_output_property",
27223 output = ?output,
27224 property = ?property,
27225 );
27226 let request = types::randr::QueryOutputPropertyRequest { output, property };
27227 let cookie = self.send_reply_request(request).with_span(span);
27228 cookie
27229 }
27230 #[cfg(feature = "randr")]
27231 fn randr_query_output_property_immediate<'this>(
27232 &'this mut self,
27233 output: types::Output,
27234 property: types::Atom,
27235 ) -> futures::CheckedSendRequest<'this, Self, types::randr::QueryOutputPropertyReply> {
27236 let request = types::randr::QueryOutputPropertyRequest { output, property };
27237 let cookie = self.send_reply_request(request);
27238 let res: futures::CheckedSendRequest<'this, Self, types::randr::QueryOutputPropertyReply> =
27239 cookie.into();
27240 res
27241 }
27242 #[cfg(feature = "randr")]
27243 fn randr_configure_output_property<'this>(
27244 &'this mut self,
27245 output: types::Output,
27246 property: types::Atom,
27247 pending: types::Bool,
27248 range: types::Bool,
27249 values: impl AsRef<[types::Int32]>,
27250 ) -> futures::SendRequest<'this, Self, ()> {
27251 let span = tracing::info_span!(
27252 "randr_configure_output_property",
27253 output = ?output,
27254 property = ?property,
27255 pending = ?pending,
27256 range = ?range,
27257 );
27258 let request = types::randr::ConfigureOutputPropertyRequest {
27259 output,
27260 property,
27261 pending,
27262 range,
27263 values: Cow::Borrowed(values.as_ref()),
27264 };
27265 let cookie = self.send_void_request(request, true).with_span(span);
27266 cookie
27267 }
27268 #[cfg(feature = "randr")]
27269 fn randr_configure_output_property_checked<'this>(
27270 &'this mut self,
27271 output: types::Output,
27272 property: types::Atom,
27273 pending: types::Bool,
27274 range: types::Bool,
27275 values: impl AsRef<[types::Int32]>,
27276 ) -> futures::CheckedSendRequest<'this, Self, ()> {
27277 let request = types::randr::ConfigureOutputPropertyRequest {
27278 output,
27279 property,
27280 pending,
27281 range,
27282 values: Cow::Borrowed(values.as_ref()),
27283 };
27284 let cookie = self.send_void_request(request, false);
27285 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
27286 res
27287 }
27288 #[cfg(feature = "randr")]
27289 fn randr_change_output_property<'this>(
27290 &'this mut self,
27291 output: types::Output,
27292 property: types::Atom,
27293 type_: types::Atom,
27294 format: types::Card8,
27295 mode: types::PropMode,
27296 num_units: types::Card32,
27297 data: &(impl crate::Void + ?Sized),
27298 ) -> futures::SendRequest<'this, Self, ()> {
27299 let span = tracing::info_span!(
27300 "randr_change_output_property",
27301 output = ?output,
27302 property = ?property,
27303 type_ = ?type_,
27304 format = ?format,
27305 mode = ?mode,
27306 num_units = ?num_units,
27307 );
27308 let request = types::randr::ChangeOutputPropertyRequest {
27309 output,
27310 property,
27311 type_,
27312 format,
27313 mode,
27314 num_units,
27315 data: Cow::Borrowed(data.bytes()),
27316 };
27317 let cookie = self.send_void_request(request, true).with_span(span);
27318 cookie
27319 }
27320 #[cfg(feature = "randr")]
27321 fn randr_change_output_property_checked<'this>(
27322 &'this mut self,
27323 output: types::Output,
27324 property: types::Atom,
27325 type_: types::Atom,
27326 format: types::Card8,
27327 mode: types::PropMode,
27328 num_units: types::Card32,
27329 data: &(impl crate::Void + ?Sized),
27330 ) -> futures::CheckedSendRequest<'this, Self, ()> {
27331 let request = types::randr::ChangeOutputPropertyRequest {
27332 output,
27333 property,
27334 type_,
27335 format,
27336 mode,
27337 num_units,
27338 data: Cow::Borrowed(data.bytes()),
27339 };
27340 let cookie = self.send_void_request(request, false);
27341 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
27342 res
27343 }
27344 #[cfg(feature = "randr")]
27345 fn randr_delete_output_property<'this>(
27346 &'this mut self,
27347 output: types::Output,
27348 property: types::Atom,
27349 ) -> futures::SendRequest<'this, Self, ()> {
27350 let span = tracing::info_span!(
27351 "randr_delete_output_property",
27352 output = ?output,
27353 property = ?property,
27354 );
27355 let request = types::randr::DeleteOutputPropertyRequest { output, property };
27356 let cookie = self.send_void_request(request, true).with_span(span);
27357 cookie
27358 }
27359 #[cfg(feature = "randr")]
27360 fn randr_delete_output_property_checked<'this>(
27361 &'this mut self,
27362 output: types::Output,
27363 property: types::Atom,
27364 ) -> futures::CheckedSendRequest<'this, Self, ()> {
27365 let request = types::randr::DeleteOutputPropertyRequest { output, property };
27366 let cookie = self.send_void_request(request, false);
27367 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
27368 res
27369 }
27370 #[cfg(feature = "randr")]
27371 fn randr_get_output_property<'this>(
27372 &'this mut self,
27373 output: types::Output,
27374 property: types::Atom,
27375 type_: impl Into<types::GetPropertyType>,
27376 long_offset: types::Card32,
27377 long_length: types::Card32,
27378 delete: types::Bool,
27379 pending: types::Bool,
27380 ) -> futures::SendRequest<'this, Self, types::randr::GetOutputPropertyReply> {
27381 let span = tracing::info_span!(
27382 "randr_get_output_property",
27383 output = ?output,
27384 property = ?property,
27385 long_offset = ?long_offset,
27386 long_length = ?long_length,
27387 delete = ?delete,
27388 pending = ?pending,
27389 );
27390 let request = types::randr::GetOutputPropertyRequest {
27391 output,
27392 property,
27393 type_: Into::<u32>::into(type_.into()) as _,
27394 long_offset,
27395 long_length,
27396 delete,
27397 pending,
27398 };
27399 let cookie = self.send_reply_request(request).with_span(span);
27400 cookie
27401 }
27402 #[cfg(feature = "randr")]
27403 fn randr_get_output_property_immediate<'this>(
27404 &'this mut self,
27405 output: types::Output,
27406 property: types::Atom,
27407 type_: impl Into<types::GetPropertyType>,
27408 long_offset: types::Card32,
27409 long_length: types::Card32,
27410 delete: types::Bool,
27411 pending: types::Bool,
27412 ) -> futures::CheckedSendRequest<'this, Self, types::randr::GetOutputPropertyReply> {
27413 let request = types::randr::GetOutputPropertyRequest {
27414 output,
27415 property,
27416 type_: Into::<u32>::into(type_.into()) as _,
27417 long_offset,
27418 long_length,
27419 delete,
27420 pending,
27421 };
27422 let cookie = self.send_reply_request(request);
27423 let res: futures::CheckedSendRequest<'this, Self, types::randr::GetOutputPropertyReply> =
27424 cookie.into();
27425 res
27426 }
27427 #[cfg(feature = "randr")]
27428 fn randr_create_mode<'this>(
27429 &'this mut self,
27430 window: types::xproto::Window,
27431 mode_info: types::randr::ModeInfo,
27432 name: impl AsRef<[types::Char]>,
27433 ) -> futures::SendRequest<'this, Self, types::randr::CreateModeReply> {
27434 let span = tracing::info_span!(
27435 "randr_create_mode",
27436 window = ?window,
27437 mode_info = ?mode_info,
27438 );
27439 let request = types::randr::CreateModeRequest {
27440 window,
27441 mode_info,
27442 name: Cow::Borrowed(name.as_ref()),
27443 };
27444 let cookie = self.send_reply_request(request).with_span(span);
27445 cookie
27446 }
27447 #[cfg(feature = "randr")]
27448 fn randr_create_mode_immediate<'this>(
27449 &'this mut self,
27450 window: types::xproto::Window,
27451 mode_info: types::randr::ModeInfo,
27452 name: impl AsRef<[types::Char]>,
27453 ) -> futures::CheckedSendRequest<'this, Self, types::randr::CreateModeReply> {
27454 let request = types::randr::CreateModeRequest {
27455 window,
27456 mode_info,
27457 name: Cow::Borrowed(name.as_ref()),
27458 };
27459 let cookie = self.send_reply_request(request);
27460 let res: futures::CheckedSendRequest<'this, Self, types::randr::CreateModeReply> =
27461 cookie.into();
27462 res
27463 }
27464 #[cfg(feature = "randr")]
27465 fn randr_destroy_mode<'this>(
27466 &'this mut self,
27467 mode: types::Mode,
27468 ) -> futures::SendRequest<'this, Self, ()> {
27469 let span = tracing::info_span!(
27470 "randr_destroy_mode",
27471 mode = ?mode,
27472 );
27473 let request = types::randr::DestroyModeRequest { mode };
27474 let cookie = self.send_void_request(request, true).with_span(span);
27475 cookie
27476 }
27477 #[cfg(feature = "randr")]
27478 fn randr_destroy_mode_checked<'this>(
27479 &'this mut self,
27480 mode: types::Mode,
27481 ) -> futures::CheckedSendRequest<'this, Self, ()> {
27482 let request = types::randr::DestroyModeRequest { mode };
27483 let cookie = self.send_void_request(request, false);
27484 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
27485 res
27486 }
27487 #[cfg(feature = "randr")]
27488 fn randr_add_output_mode<'this>(
27489 &'this mut self,
27490 output: types::Output,
27491 mode: types::Mode,
27492 ) -> futures::SendRequest<'this, Self, ()> {
27493 let span = tracing::info_span!(
27494 "randr_add_output_mode",
27495 output = ?output,
27496 mode = ?mode,
27497 );
27498 let request = types::randr::AddOutputModeRequest { output, mode };
27499 let cookie = self.send_void_request(request, true).with_span(span);
27500 cookie
27501 }
27502 #[cfg(feature = "randr")]
27503 fn randr_add_output_mode_checked<'this>(
27504 &'this mut self,
27505 output: types::Output,
27506 mode: types::Mode,
27507 ) -> futures::CheckedSendRequest<'this, Self, ()> {
27508 let request = types::randr::AddOutputModeRequest { output, mode };
27509 let cookie = self.send_void_request(request, false);
27510 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
27511 res
27512 }
27513 #[cfg(feature = "randr")]
27514 fn randr_delete_output_mode<'this>(
27515 &'this mut self,
27516 output: types::Output,
27517 mode: types::Mode,
27518 ) -> futures::SendRequest<'this, Self, ()> {
27519 let span = tracing::info_span!(
27520 "randr_delete_output_mode",
27521 output = ?output,
27522 mode = ?mode,
27523 );
27524 let request = types::randr::DeleteOutputModeRequest { output, mode };
27525 let cookie = self.send_void_request(request, true).with_span(span);
27526 cookie
27527 }
27528 #[cfg(feature = "randr")]
27529 fn randr_delete_output_mode_checked<'this>(
27530 &'this mut self,
27531 output: types::Output,
27532 mode: types::Mode,
27533 ) -> futures::CheckedSendRequest<'this, Self, ()> {
27534 let request = types::randr::DeleteOutputModeRequest { output, mode };
27535 let cookie = self.send_void_request(request, false);
27536 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
27537 res
27538 }
27539 #[cfg(feature = "randr")]
27540 fn randr_get_crtc_info<'this>(
27541 &'this mut self,
27542 crtc: types::Crtc,
27543 config_timestamp: types::Timestamp,
27544 ) -> futures::SendRequest<'this, Self, types::randr::GetCrtcInfoReply> {
27545 let span = tracing::info_span!(
27546 "randr_get_crtc_info",
27547 crtc = ?crtc,
27548 config_timestamp = ?config_timestamp,
27549 );
27550 let request = types::randr::GetCrtcInfoRequest {
27551 crtc,
27552 config_timestamp,
27553 };
27554 let cookie = self.send_reply_request(request).with_span(span);
27555 cookie
27556 }
27557 #[cfg(feature = "randr")]
27558 fn randr_get_crtc_info_immediate<'this>(
27559 &'this mut self,
27560 crtc: types::Crtc,
27561 config_timestamp: types::Timestamp,
27562 ) -> futures::CheckedSendRequest<'this, Self, types::randr::GetCrtcInfoReply> {
27563 let request = types::randr::GetCrtcInfoRequest {
27564 crtc,
27565 config_timestamp,
27566 };
27567 let cookie = self.send_reply_request(request);
27568 let res: futures::CheckedSendRequest<'this, Self, types::randr::GetCrtcInfoReply> =
27569 cookie.into();
27570 res
27571 }
27572 #[cfg(feature = "randr")]
27573 fn randr_set_crtc_config<'this>(
27574 &'this mut self,
27575 crtc: types::Crtc,
27576 timestamp: types::Timestamp,
27577 config_timestamp: types::Timestamp,
27578 x: types::Int16,
27579 y: types::Int16,
27580 mode: types::Mode,
27581 rotation: impl Into<types::Rotation>,
27582 outputs: impl AsRef<[types::Output]>,
27583 ) -> futures::SendRequest<'this, Self, types::randr::SetCrtcConfigReply> {
27584 let span = tracing::info_span!(
27585 "randr_set_crtc_config",
27586 crtc = ?crtc,
27587 timestamp = ?timestamp,
27588 config_timestamp = ?config_timestamp,
27589 x = ?x,
27590 y = ?y,
27591 mode = ?mode,
27592 );
27593 let request = types::randr::SetCrtcConfigRequest {
27594 crtc,
27595 timestamp,
27596 config_timestamp,
27597 x,
27598 y,
27599 mode,
27600 rotation: Into::<u32>::into(rotation.into()) as _,
27601 outputs: Cow::Borrowed(outputs.as_ref()),
27602 };
27603 let cookie = self.send_reply_request(request).with_span(span);
27604 cookie
27605 }
27606 #[cfg(feature = "randr")]
27607 fn randr_set_crtc_config_immediate<'this>(
27608 &'this mut self,
27609 crtc: types::Crtc,
27610 timestamp: types::Timestamp,
27611 config_timestamp: types::Timestamp,
27612 x: types::Int16,
27613 y: types::Int16,
27614 mode: types::Mode,
27615 rotation: impl Into<types::Rotation>,
27616 outputs: impl AsRef<[types::Output]>,
27617 ) -> futures::CheckedSendRequest<'this, Self, types::randr::SetCrtcConfigReply> {
27618 let request = types::randr::SetCrtcConfigRequest {
27619 crtc,
27620 timestamp,
27621 config_timestamp,
27622 x,
27623 y,
27624 mode,
27625 rotation: Into::<u32>::into(rotation.into()) as _,
27626 outputs: Cow::Borrowed(outputs.as_ref()),
27627 };
27628 let cookie = self.send_reply_request(request);
27629 let res: futures::CheckedSendRequest<'this, Self, types::randr::SetCrtcConfigReply> =
27630 cookie.into();
27631 res
27632 }
27633 #[cfg(feature = "randr")]
27634 fn randr_get_crtc_gamma_size<'this>(
27635 &'this mut self,
27636 crtc: types::Crtc,
27637 ) -> futures::SendRequest<'this, Self, types::randr::GetCrtcGammaSizeReply> {
27638 let span = tracing::info_span!(
27639 "randr_get_crtc_gamma_size",
27640 crtc = ?crtc,
27641 );
27642 let request = types::randr::GetCrtcGammaSizeRequest { crtc };
27643 let cookie = self.send_reply_request(request).with_span(span);
27644 cookie
27645 }
27646 #[cfg(feature = "randr")]
27647 fn randr_get_crtc_gamma_size_immediate<'this>(
27648 &'this mut self,
27649 crtc: types::Crtc,
27650 ) -> futures::CheckedSendRequest<'this, Self, types::randr::GetCrtcGammaSizeReply> {
27651 let request = types::randr::GetCrtcGammaSizeRequest { crtc };
27652 let cookie = self.send_reply_request(request);
27653 let res: futures::CheckedSendRequest<'this, Self, types::randr::GetCrtcGammaSizeReply> =
27654 cookie.into();
27655 res
27656 }
27657 #[cfg(feature = "randr")]
27658 fn randr_get_crtc_gamma<'this>(
27659 &'this mut self,
27660 crtc: types::Crtc,
27661 ) -> futures::SendRequest<'this, Self, types::randr::GetCrtcGammaReply> {
27662 let span = tracing::info_span!(
27663 "randr_get_crtc_gamma",
27664 crtc = ?crtc,
27665 );
27666 let request = types::randr::GetCrtcGammaRequest { crtc };
27667 let cookie = self.send_reply_request(request).with_span(span);
27668 cookie
27669 }
27670 #[cfg(feature = "randr")]
27671 fn randr_get_crtc_gamma_immediate<'this>(
27672 &'this mut self,
27673 crtc: types::Crtc,
27674 ) -> futures::CheckedSendRequest<'this, Self, types::randr::GetCrtcGammaReply> {
27675 let request = types::randr::GetCrtcGammaRequest { crtc };
27676 let cookie = self.send_reply_request(request);
27677 let res: futures::CheckedSendRequest<'this, Self, types::randr::GetCrtcGammaReply> =
27678 cookie.into();
27679 res
27680 }
27681 #[cfg(feature = "randr")]
27682 fn randr_set_crtc_gamma<'this>(
27683 &'this mut self,
27684 crtc: types::Crtc,
27685 red: impl AsRef<[types::Card16]>,
27686 green: impl AsRef<[types::Card16]>,
27687 blue: impl AsRef<[types::Card16]>,
27688 ) -> futures::SendRequest<'this, Self, ()> {
27689 let span = tracing::info_span!(
27690 "randr_set_crtc_gamma",
27691 crtc = ?crtc,
27692 );
27693 let request = types::randr::SetCrtcGammaRequest {
27694 crtc,
27695 red: Cow::Borrowed(red.as_ref()),
27696 green: Cow::Borrowed(green.as_ref()),
27697 blue: Cow::Borrowed(blue.as_ref()),
27698 };
27699 let cookie = self.send_void_request(request, true).with_span(span);
27700 cookie
27701 }
27702 #[cfg(feature = "randr")]
27703 fn randr_set_crtc_gamma_checked<'this>(
27704 &'this mut self,
27705 crtc: types::Crtc,
27706 red: impl AsRef<[types::Card16]>,
27707 green: impl AsRef<[types::Card16]>,
27708 blue: impl AsRef<[types::Card16]>,
27709 ) -> futures::CheckedSendRequest<'this, Self, ()> {
27710 let request = types::randr::SetCrtcGammaRequest {
27711 crtc,
27712 red: Cow::Borrowed(red.as_ref()),
27713 green: Cow::Borrowed(green.as_ref()),
27714 blue: Cow::Borrowed(blue.as_ref()),
27715 };
27716 let cookie = self.send_void_request(request, false);
27717 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
27718 res
27719 }
27720 #[cfg(feature = "randr")]
27721 fn randr_get_screen_resources_current<'this>(
27722 &'this mut self,
27723 window: types::xproto::Window,
27724 ) -> futures::SendRequest<'this, Self, types::randr::GetScreenResourcesCurrentReply> {
27725 let span = tracing::info_span!(
27726 "randr_get_screen_resources_current",
27727 window = ?window,
27728 );
27729 let request = types::randr::GetScreenResourcesCurrentRequest { window };
27730 let cookie = self.send_reply_request(request).with_span(span);
27731 cookie
27732 }
27733 #[cfg(feature = "randr")]
27734 fn randr_get_screen_resources_current_immediate<'this>(
27735 &'this mut self,
27736 window: types::xproto::Window,
27737 ) -> futures::CheckedSendRequest<'this, Self, types::randr::GetScreenResourcesCurrentReply>
27738 {
27739 let request = types::randr::GetScreenResourcesCurrentRequest { window };
27740 let cookie = self.send_reply_request(request);
27741 let res: futures::CheckedSendRequest<
27742 'this,
27743 Self,
27744 types::randr::GetScreenResourcesCurrentReply,
27745 > = cookie.into();
27746 res
27747 }
27748 #[cfg(feature = "randr")]
27749 fn randr_set_crtc_transform<'this>(
27750 &'this mut self,
27751 crtc: types::Crtc,
27752 transform: types::render::Transform,
27753 filter_name: impl AsRef<[types::Char]>,
27754 filter_params: impl AsRef<[types::Fixed]>,
27755 ) -> futures::SendRequest<'this, Self, ()> {
27756 let span = tracing::info_span!(
27757 "randr_set_crtc_transform",
27758 crtc = ?crtc,
27759 transform = ?transform,
27760 );
27761 let request = types::randr::SetCrtcTransformRequest {
27762 crtc,
27763 transform,
27764 filter_name: Cow::Borrowed(filter_name.as_ref()),
27765 filter_params: Cow::Borrowed(filter_params.as_ref()),
27766 };
27767 let cookie = self.send_void_request(request, true).with_span(span);
27768 cookie
27769 }
27770 #[cfg(feature = "randr")]
27771 fn randr_set_crtc_transform_checked<'this>(
27772 &'this mut self,
27773 crtc: types::Crtc,
27774 transform: types::render::Transform,
27775 filter_name: impl AsRef<[types::Char]>,
27776 filter_params: impl AsRef<[types::Fixed]>,
27777 ) -> futures::CheckedSendRequest<'this, Self, ()> {
27778 let request = types::randr::SetCrtcTransformRequest {
27779 crtc,
27780 transform,
27781 filter_name: Cow::Borrowed(filter_name.as_ref()),
27782 filter_params: Cow::Borrowed(filter_params.as_ref()),
27783 };
27784 let cookie = self.send_void_request(request, false);
27785 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
27786 res
27787 }
27788 #[cfg(feature = "randr")]
27789 fn randr_get_crtc_transform<'this>(
27790 &'this mut self,
27791 crtc: types::Crtc,
27792 ) -> futures::SendRequest<'this, Self, types::randr::GetCrtcTransformReply> {
27793 let span = tracing::info_span!(
27794 "randr_get_crtc_transform",
27795 crtc = ?crtc,
27796 );
27797 let request = types::randr::GetCrtcTransformRequest { crtc };
27798 let cookie = self.send_reply_request(request).with_span(span);
27799 cookie
27800 }
27801 #[cfg(feature = "randr")]
27802 fn randr_get_crtc_transform_immediate<'this>(
27803 &'this mut self,
27804 crtc: types::Crtc,
27805 ) -> futures::CheckedSendRequest<'this, Self, types::randr::GetCrtcTransformReply> {
27806 let request = types::randr::GetCrtcTransformRequest { crtc };
27807 let cookie = self.send_reply_request(request);
27808 let res: futures::CheckedSendRequest<'this, Self, types::randr::GetCrtcTransformReply> =
27809 cookie.into();
27810 res
27811 }
27812 #[cfg(feature = "randr")]
27813 fn randr_get_panning<'this>(
27814 &'this mut self,
27815 crtc: types::Crtc,
27816 ) -> futures::SendRequest<'this, Self, types::randr::GetPanningReply> {
27817 let span = tracing::info_span!(
27818 "randr_get_panning",
27819 crtc = ?crtc,
27820 );
27821 let request = types::randr::GetPanningRequest { crtc };
27822 let cookie = self.send_reply_request(request).with_span(span);
27823 cookie
27824 }
27825 #[cfg(feature = "randr")]
27826 fn randr_get_panning_immediate<'this>(
27827 &'this mut self,
27828 crtc: types::Crtc,
27829 ) -> futures::CheckedSendRequest<'this, Self, types::randr::GetPanningReply> {
27830 let request = types::randr::GetPanningRequest { crtc };
27831 let cookie = self.send_reply_request(request);
27832 let res: futures::CheckedSendRequest<'this, Self, types::randr::GetPanningReply> =
27833 cookie.into();
27834 res
27835 }
27836 #[cfg(feature = "randr")]
27837 fn randr_set_panning<'this>(
27838 &'this mut self,
27839 crtc: types::Crtc,
27840 timestamp: types::Timestamp,
27841 left: types::Card16,
27842 top: types::Card16,
27843 width: types::Card16,
27844 height: types::Card16,
27845 track_left: types::Card16,
27846 track_top: types::Card16,
27847 track_width: types::Card16,
27848 track_height: types::Card16,
27849 border_left: types::Int16,
27850 border_top: types::Int16,
27851 border_right: types::Int16,
27852 border_bottom: types::Int16,
27853 ) -> futures::SendRequest<'this, Self, types::randr::SetPanningReply> {
27854 let span = tracing::info_span!(
27855 "randr_set_panning",
27856 crtc = ?crtc,
27857 timestamp = ?timestamp,
27858 left = ?left,
27859 top = ?top,
27860 width = ?width,
27861 height = ?height,
27862 track_left = ?track_left,
27863 track_top = ?track_top,
27864 track_width = ?track_width,
27865 track_height = ?track_height,
27866 border_left = ?border_left,
27867 border_top = ?border_top,
27868 border_right = ?border_right,
27869 border_bottom = ?border_bottom,
27870 );
27871 let request = types::randr::SetPanningRequest {
27872 crtc,
27873 timestamp,
27874 left,
27875 top,
27876 width,
27877 height,
27878 track_left,
27879 track_top,
27880 track_width,
27881 track_height,
27882 border_left,
27883 border_top,
27884 border_right,
27885 border_bottom,
27886 };
27887 let cookie = self.send_reply_request(request).with_span(span);
27888 cookie
27889 }
27890 #[cfg(feature = "randr")]
27891 fn randr_set_panning_immediate<'this>(
27892 &'this mut self,
27893 crtc: types::Crtc,
27894 timestamp: types::Timestamp,
27895 left: types::Card16,
27896 top: types::Card16,
27897 width: types::Card16,
27898 height: types::Card16,
27899 track_left: types::Card16,
27900 track_top: types::Card16,
27901 track_width: types::Card16,
27902 track_height: types::Card16,
27903 border_left: types::Int16,
27904 border_top: types::Int16,
27905 border_right: types::Int16,
27906 border_bottom: types::Int16,
27907 ) -> futures::CheckedSendRequest<'this, Self, types::randr::SetPanningReply> {
27908 let request = types::randr::SetPanningRequest {
27909 crtc,
27910 timestamp,
27911 left,
27912 top,
27913 width,
27914 height,
27915 track_left,
27916 track_top,
27917 track_width,
27918 track_height,
27919 border_left,
27920 border_top,
27921 border_right,
27922 border_bottom,
27923 };
27924 let cookie = self.send_reply_request(request);
27925 let res: futures::CheckedSendRequest<'this, Self, types::randr::SetPanningReply> =
27926 cookie.into();
27927 res
27928 }
27929 #[cfg(feature = "randr")]
27930 fn randr_set_output_primary<'this>(
27931 &'this mut self,
27932 window: types::xproto::Window,
27933 output: types::Output,
27934 ) -> futures::SendRequest<'this, Self, ()> {
27935 let span = tracing::info_span!(
27936 "randr_set_output_primary",
27937 window = ?window,
27938 output = ?output,
27939 );
27940 let request = types::randr::SetOutputPrimaryRequest { window, output };
27941 let cookie = self.send_void_request(request, true).with_span(span);
27942 cookie
27943 }
27944 #[cfg(feature = "randr")]
27945 fn randr_set_output_primary_checked<'this>(
27946 &'this mut self,
27947 window: types::xproto::Window,
27948 output: types::Output,
27949 ) -> futures::CheckedSendRequest<'this, Self, ()> {
27950 let request = types::randr::SetOutputPrimaryRequest { window, output };
27951 let cookie = self.send_void_request(request, false);
27952 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
27953 res
27954 }
27955 #[cfg(feature = "randr")]
27956 fn randr_get_output_primary<'this>(
27957 &'this mut self,
27958 window: types::xproto::Window,
27959 ) -> futures::SendRequest<'this, Self, types::randr::GetOutputPrimaryReply> {
27960 let span = tracing::info_span!(
27961 "randr_get_output_primary",
27962 window = ?window,
27963 );
27964 let request = types::randr::GetOutputPrimaryRequest { window };
27965 let cookie = self.send_reply_request(request).with_span(span);
27966 cookie
27967 }
27968 #[cfg(feature = "randr")]
27969 fn randr_get_output_primary_immediate<'this>(
27970 &'this mut self,
27971 window: types::xproto::Window,
27972 ) -> futures::CheckedSendRequest<'this, Self, types::randr::GetOutputPrimaryReply> {
27973 let request = types::randr::GetOutputPrimaryRequest { window };
27974 let cookie = self.send_reply_request(request);
27975 let res: futures::CheckedSendRequest<'this, Self, types::randr::GetOutputPrimaryReply> =
27976 cookie.into();
27977 res
27978 }
27979 #[cfg(feature = "randr")]
27980 fn randr_get_providers<'this>(
27981 &'this mut self,
27982 window: types::xproto::Window,
27983 ) -> futures::SendRequest<'this, Self, types::randr::GetProvidersReply> {
27984 let span = tracing::info_span!(
27985 "randr_get_providers",
27986 window = ?window,
27987 );
27988 let request = types::randr::GetProvidersRequest { window };
27989 let cookie = self.send_reply_request(request).with_span(span);
27990 cookie
27991 }
27992 #[cfg(feature = "randr")]
27993 fn randr_get_providers_immediate<'this>(
27994 &'this mut self,
27995 window: types::xproto::Window,
27996 ) -> futures::CheckedSendRequest<'this, Self, types::randr::GetProvidersReply> {
27997 let request = types::randr::GetProvidersRequest { window };
27998 let cookie = self.send_reply_request(request);
27999 let res: futures::CheckedSendRequest<'this, Self, types::randr::GetProvidersReply> =
28000 cookie.into();
28001 res
28002 }
28003 #[cfg(feature = "randr")]
28004 fn randr_get_provider_info<'this>(
28005 &'this mut self,
28006 provider: types::Provider,
28007 config_timestamp: types::Timestamp,
28008 ) -> futures::SendRequest<'this, Self, types::randr::GetProviderInfoReply> {
28009 let span = tracing::info_span!(
28010 "randr_get_provider_info",
28011 provider = ?provider,
28012 config_timestamp = ?config_timestamp,
28013 );
28014 let request = types::randr::GetProviderInfoRequest {
28015 provider,
28016 config_timestamp,
28017 };
28018 let cookie = self.send_reply_request(request).with_span(span);
28019 cookie
28020 }
28021 #[cfg(feature = "randr")]
28022 fn randr_get_provider_info_immediate<'this>(
28023 &'this mut self,
28024 provider: types::Provider,
28025 config_timestamp: types::Timestamp,
28026 ) -> futures::CheckedSendRequest<'this, Self, types::randr::GetProviderInfoReply> {
28027 let request = types::randr::GetProviderInfoRequest {
28028 provider,
28029 config_timestamp,
28030 };
28031 let cookie = self.send_reply_request(request);
28032 let res: futures::CheckedSendRequest<'this, Self, types::randr::GetProviderInfoReply> =
28033 cookie.into();
28034 res
28035 }
28036 #[cfg(feature = "randr")]
28037 fn randr_set_provider_offload_sink<'this>(
28038 &'this mut self,
28039 provider: types::Provider,
28040 sink_provider: types::Provider,
28041 config_timestamp: types::Timestamp,
28042 ) -> futures::SendRequest<'this, Self, ()> {
28043 let span = tracing::info_span!(
28044 "randr_set_provider_offload_sink",
28045 provider = ?provider,
28046 sink_provider = ?sink_provider,
28047 config_timestamp = ?config_timestamp,
28048 );
28049 let request = types::randr::SetProviderOffloadSinkRequest {
28050 provider,
28051 sink_provider,
28052 config_timestamp,
28053 };
28054 let cookie = self.send_void_request(request, true).with_span(span);
28055 cookie
28056 }
28057 #[cfg(feature = "randr")]
28058 fn randr_set_provider_offload_sink_checked<'this>(
28059 &'this mut self,
28060 provider: types::Provider,
28061 sink_provider: types::Provider,
28062 config_timestamp: types::Timestamp,
28063 ) -> futures::CheckedSendRequest<'this, Self, ()> {
28064 let request = types::randr::SetProviderOffloadSinkRequest {
28065 provider,
28066 sink_provider,
28067 config_timestamp,
28068 };
28069 let cookie = self.send_void_request(request, false);
28070 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
28071 res
28072 }
28073 #[cfg(feature = "randr")]
28074 fn randr_set_provider_output_source<'this>(
28075 &'this mut self,
28076 provider: types::Provider,
28077 source_provider: types::Provider,
28078 config_timestamp: types::Timestamp,
28079 ) -> futures::SendRequest<'this, Self, ()> {
28080 let span = tracing::info_span!(
28081 "randr_set_provider_output_source",
28082 provider = ?provider,
28083 source_provider = ?source_provider,
28084 config_timestamp = ?config_timestamp,
28085 );
28086 let request = types::randr::SetProviderOutputSourceRequest {
28087 provider,
28088 source_provider,
28089 config_timestamp,
28090 };
28091 let cookie = self.send_void_request(request, true).with_span(span);
28092 cookie
28093 }
28094 #[cfg(feature = "randr")]
28095 fn randr_set_provider_output_source_checked<'this>(
28096 &'this mut self,
28097 provider: types::Provider,
28098 source_provider: types::Provider,
28099 config_timestamp: types::Timestamp,
28100 ) -> futures::CheckedSendRequest<'this, Self, ()> {
28101 let request = types::randr::SetProviderOutputSourceRequest {
28102 provider,
28103 source_provider,
28104 config_timestamp,
28105 };
28106 let cookie = self.send_void_request(request, false);
28107 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
28108 res
28109 }
28110 #[cfg(feature = "randr")]
28111 fn randr_list_provider_properties<'this>(
28112 &'this mut self,
28113 provider: types::Provider,
28114 ) -> futures::SendRequest<'this, Self, types::randr::ListProviderPropertiesReply> {
28115 let span = tracing::info_span!(
28116 "randr_list_provider_properties",
28117 provider = ?provider,
28118 );
28119 let request = types::randr::ListProviderPropertiesRequest { provider };
28120 let cookie = self.send_reply_request(request).with_span(span);
28121 cookie
28122 }
28123 #[cfg(feature = "randr")]
28124 fn randr_list_provider_properties_immediate<'this>(
28125 &'this mut self,
28126 provider: types::Provider,
28127 ) -> futures::CheckedSendRequest<'this, Self, types::randr::ListProviderPropertiesReply> {
28128 let request = types::randr::ListProviderPropertiesRequest { provider };
28129 let cookie = self.send_reply_request(request);
28130 let res: futures::CheckedSendRequest<
28131 'this,
28132 Self,
28133 types::randr::ListProviderPropertiesReply,
28134 > = cookie.into();
28135 res
28136 }
28137 #[cfg(feature = "randr")]
28138 fn randr_query_provider_property<'this>(
28139 &'this mut self,
28140 provider: types::Provider,
28141 property: types::Atom,
28142 ) -> futures::SendRequest<'this, Self, types::randr::QueryProviderPropertyReply> {
28143 let span = tracing::info_span!(
28144 "randr_query_provider_property",
28145 provider = ?provider,
28146 property = ?property,
28147 );
28148 let request = types::randr::QueryProviderPropertyRequest { provider, property };
28149 let cookie = self.send_reply_request(request).with_span(span);
28150 cookie
28151 }
28152 #[cfg(feature = "randr")]
28153 fn randr_query_provider_property_immediate<'this>(
28154 &'this mut self,
28155 provider: types::Provider,
28156 property: types::Atom,
28157 ) -> futures::CheckedSendRequest<'this, Self, types::randr::QueryProviderPropertyReply> {
28158 let request = types::randr::QueryProviderPropertyRequest { provider, property };
28159 let cookie = self.send_reply_request(request);
28160 let res: futures::CheckedSendRequest<
28161 'this,
28162 Self,
28163 types::randr::QueryProviderPropertyReply,
28164 > = cookie.into();
28165 res
28166 }
28167 #[cfg(feature = "randr")]
28168 fn randr_configure_provider_property<'this>(
28169 &'this mut self,
28170 provider: types::Provider,
28171 property: types::Atom,
28172 pending: types::Bool,
28173 range: types::Bool,
28174 values: impl AsRef<[types::Int32]>,
28175 ) -> futures::SendRequest<'this, Self, ()> {
28176 let span = tracing::info_span!(
28177 "randr_configure_provider_property",
28178 provider = ?provider,
28179 property = ?property,
28180 pending = ?pending,
28181 range = ?range,
28182 );
28183 let request = types::randr::ConfigureProviderPropertyRequest {
28184 provider,
28185 property,
28186 pending,
28187 range,
28188 values: Cow::Borrowed(values.as_ref()),
28189 };
28190 let cookie = self.send_void_request(request, true).with_span(span);
28191 cookie
28192 }
28193 #[cfg(feature = "randr")]
28194 fn randr_configure_provider_property_checked<'this>(
28195 &'this mut self,
28196 provider: types::Provider,
28197 property: types::Atom,
28198 pending: types::Bool,
28199 range: types::Bool,
28200 values: impl AsRef<[types::Int32]>,
28201 ) -> futures::CheckedSendRequest<'this, Self, ()> {
28202 let request = types::randr::ConfigureProviderPropertyRequest {
28203 provider,
28204 property,
28205 pending,
28206 range,
28207 values: Cow::Borrowed(values.as_ref()),
28208 };
28209 let cookie = self.send_void_request(request, false);
28210 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
28211 res
28212 }
28213 #[cfg(feature = "randr")]
28214 fn randr_change_provider_property<'this>(
28215 &'this mut self,
28216 provider: types::Provider,
28217 property: types::Atom,
28218 type_: types::Atom,
28219 format: types::Card8,
28220 mode: types::Card8,
28221 num_items: types::Card32,
28222 data: &(impl crate::Void + ?Sized),
28223 ) -> futures::SendRequest<'this, Self, ()> {
28224 let span = tracing::info_span!(
28225 "randr_change_provider_property",
28226 provider = ?provider,
28227 property = ?property,
28228 type_ = ?type_,
28229 format = ?format,
28230 mode = ?mode,
28231 num_items = ?num_items,
28232 );
28233 let request = types::randr::ChangeProviderPropertyRequest {
28234 provider,
28235 property,
28236 type_,
28237 format,
28238 mode,
28239 num_items,
28240 data: Cow::Borrowed(data.bytes()),
28241 };
28242 let cookie = self.send_void_request(request, true).with_span(span);
28243 cookie
28244 }
28245 #[cfg(feature = "randr")]
28246 fn randr_change_provider_property_checked<'this>(
28247 &'this mut self,
28248 provider: types::Provider,
28249 property: types::Atom,
28250 type_: types::Atom,
28251 format: types::Card8,
28252 mode: types::Card8,
28253 num_items: types::Card32,
28254 data: &(impl crate::Void + ?Sized),
28255 ) -> futures::CheckedSendRequest<'this, Self, ()> {
28256 let request = types::randr::ChangeProviderPropertyRequest {
28257 provider,
28258 property,
28259 type_,
28260 format,
28261 mode,
28262 num_items,
28263 data: Cow::Borrowed(data.bytes()),
28264 };
28265 let cookie = self.send_void_request(request, false);
28266 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
28267 res
28268 }
28269 #[cfg(feature = "randr")]
28270 fn randr_delete_provider_property<'this>(
28271 &'this mut self,
28272 provider: types::Provider,
28273 property: types::Atom,
28274 ) -> futures::SendRequest<'this, Self, ()> {
28275 let span = tracing::info_span!(
28276 "randr_delete_provider_property",
28277 provider = ?provider,
28278 property = ?property,
28279 );
28280 let request = types::randr::DeleteProviderPropertyRequest { provider, property };
28281 let cookie = self.send_void_request(request, true).with_span(span);
28282 cookie
28283 }
28284 #[cfg(feature = "randr")]
28285 fn randr_delete_provider_property_checked<'this>(
28286 &'this mut self,
28287 provider: types::Provider,
28288 property: types::Atom,
28289 ) -> futures::CheckedSendRequest<'this, Self, ()> {
28290 let request = types::randr::DeleteProviderPropertyRequest { provider, property };
28291 let cookie = self.send_void_request(request, false);
28292 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
28293 res
28294 }
28295 #[cfg(feature = "randr")]
28296 fn randr_get_provider_property<'this>(
28297 &'this mut self,
28298 provider: types::Provider,
28299 property: types::Atom,
28300 type_: types::Atom,
28301 long_offset: types::Card32,
28302 long_length: types::Card32,
28303 delete: types::Bool,
28304 pending: types::Bool,
28305 ) -> futures::SendRequest<'this, Self, types::randr::GetProviderPropertyReply> {
28306 let span = tracing::info_span!(
28307 "randr_get_provider_property",
28308 provider = ?provider,
28309 property = ?property,
28310 type_ = ?type_,
28311 long_offset = ?long_offset,
28312 long_length = ?long_length,
28313 delete = ?delete,
28314 pending = ?pending,
28315 );
28316 let request = types::randr::GetProviderPropertyRequest {
28317 provider,
28318 property,
28319 type_,
28320 long_offset,
28321 long_length,
28322 delete,
28323 pending,
28324 };
28325 let cookie = self.send_reply_request(request).with_span(span);
28326 cookie
28327 }
28328 #[cfg(feature = "randr")]
28329 fn randr_get_provider_property_immediate<'this>(
28330 &'this mut self,
28331 provider: types::Provider,
28332 property: types::Atom,
28333 type_: types::Atom,
28334 long_offset: types::Card32,
28335 long_length: types::Card32,
28336 delete: types::Bool,
28337 pending: types::Bool,
28338 ) -> futures::CheckedSendRequest<'this, Self, types::randr::GetProviderPropertyReply> {
28339 let request = types::randr::GetProviderPropertyRequest {
28340 provider,
28341 property,
28342 type_,
28343 long_offset,
28344 long_length,
28345 delete,
28346 pending,
28347 };
28348 let cookie = self.send_reply_request(request);
28349 let res: futures::CheckedSendRequest<'this, Self, types::randr::GetProviderPropertyReply> =
28350 cookie.into();
28351 res
28352 }
28353 #[cfg(feature = "randr")]
28354 fn randr_get_monitors<'this>(
28355 &'this mut self,
28356 window: types::xproto::Window,
28357 get_active: types::Bool,
28358 ) -> futures::SendRequest<'this, Self, types::randr::GetMonitorsReply> {
28359 let span = tracing::info_span!(
28360 "randr_get_monitors",
28361 window = ?window,
28362 get_active = ?get_active,
28363 );
28364 let request = types::randr::GetMonitorsRequest { window, get_active };
28365 let cookie = self.send_reply_request(request).with_span(span);
28366 cookie
28367 }
28368 #[cfg(feature = "randr")]
28369 fn randr_get_monitors_immediate<'this>(
28370 &'this mut self,
28371 window: types::xproto::Window,
28372 get_active: types::Bool,
28373 ) -> futures::CheckedSendRequest<'this, Self, types::randr::GetMonitorsReply> {
28374 let request = types::randr::GetMonitorsRequest { window, get_active };
28375 let cookie = self.send_reply_request(request);
28376 let res: futures::CheckedSendRequest<'this, Self, types::randr::GetMonitorsReply> =
28377 cookie.into();
28378 res
28379 }
28380 #[cfg(feature = "randr")]
28381 fn randr_set_monitor<'this>(
28382 &'this mut self,
28383 window: types::xproto::Window,
28384 monitorinfo: types::MonitorInfo,
28385 ) -> futures::SendRequest<'this, Self, ()> {
28386 let span = tracing::info_span!(
28387 "randr_set_monitor",
28388 window = ?window,
28389 monitorinfo = ?monitorinfo,
28390 );
28391 let request = types::randr::SetMonitorRequest {
28392 window,
28393 monitorinfo,
28394 };
28395 let cookie = self.send_void_request(request, true).with_span(span);
28396 cookie
28397 }
28398 #[cfg(feature = "randr")]
28399 fn randr_set_monitor_checked<'this>(
28400 &'this mut self,
28401 window: types::xproto::Window,
28402 monitorinfo: types::MonitorInfo,
28403 ) -> futures::CheckedSendRequest<'this, Self, ()> {
28404 let request = types::randr::SetMonitorRequest {
28405 window,
28406 monitorinfo,
28407 };
28408 let cookie = self.send_void_request(request, false);
28409 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
28410 res
28411 }
28412 #[cfg(feature = "randr")]
28413 fn randr_delete_monitor<'this>(
28414 &'this mut self,
28415 window: types::xproto::Window,
28416 name: types::Atom,
28417 ) -> futures::SendRequest<'this, Self, ()> {
28418 let span = tracing::info_span!(
28419 "randr_delete_monitor",
28420 window = ?window,
28421 name = ?name,
28422 );
28423 let request = types::randr::DeleteMonitorRequest { window, name };
28424 let cookie = self.send_void_request(request, true).with_span(span);
28425 cookie
28426 }
28427 #[cfg(feature = "randr")]
28428 fn randr_delete_monitor_checked<'this>(
28429 &'this mut self,
28430 window: types::xproto::Window,
28431 name: types::Atom,
28432 ) -> futures::CheckedSendRequest<'this, Self, ()> {
28433 let request = types::randr::DeleteMonitorRequest { window, name };
28434 let cookie = self.send_void_request(request, false);
28435 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
28436 res
28437 }
28438 #[cfg(feature = "randr")]
28439 fn randr_create_lease<'this>(
28440 &'this mut self,
28441 window: types::xproto::Window,
28442 lid: types::Lease,
28443 crtcs: impl AsRef<[types::Crtc]>,
28444 outputs: impl AsRef<[types::Output]>,
28445 ) -> futures::SendRequest<'this, Self, types::randr::CreateLeaseReply> {
28446 let span = tracing::info_span!(
28447 "randr_create_lease",
28448 window = ?window,
28449 lid = ?lid,
28450 );
28451 let request = types::randr::CreateLeaseRequest {
28452 window,
28453 lid,
28454 crtcs: Cow::Borrowed(crtcs.as_ref()),
28455 outputs: Cow::Borrowed(outputs.as_ref()),
28456 };
28457 let cookie = self.send_reply_fd_request(request).with_span(span);
28458 cookie
28459 }
28460 #[cfg(feature = "randr")]
28461 fn randr_create_lease_immediate<'this>(
28462 &'this mut self,
28463 window: types::xproto::Window,
28464 lid: types::Lease,
28465 crtcs: impl AsRef<[types::Crtc]>,
28466 outputs: impl AsRef<[types::Output]>,
28467 ) -> futures::CheckedSendRequest<'this, Self, types::randr::CreateLeaseReply> {
28468 let request = types::randr::CreateLeaseRequest {
28469 window,
28470 lid,
28471 crtcs: Cow::Borrowed(crtcs.as_ref()),
28472 outputs: Cow::Borrowed(outputs.as_ref()),
28473 };
28474 let cookie = self.send_reply_fd_request(request);
28475 let res: futures::CheckedSendRequest<'this, Self, types::randr::CreateLeaseReply> =
28476 cookie.into();
28477 res
28478 }
28479 #[cfg(feature = "randr")]
28480 fn randr_free_lease<'this>(
28481 &'this mut self,
28482 lid: types::Lease,
28483 terminate: types::Byte,
28484 ) -> futures::SendRequest<'this, Self, ()> {
28485 let span = tracing::info_span!(
28486 "randr_free_lease",
28487 lid = ?lid,
28488 terminate = ?terminate,
28489 );
28490 let request = types::randr::FreeLeaseRequest { lid, terminate };
28491 let cookie = self.send_void_request(request, true).with_span(span);
28492 cookie
28493 }
28494 #[cfg(feature = "randr")]
28495 fn randr_free_lease_checked<'this>(
28496 &'this mut self,
28497 lid: types::Lease,
28498 terminate: types::Byte,
28499 ) -> futures::CheckedSendRequest<'this, Self, ()> {
28500 let request = types::randr::FreeLeaseRequest { lid, terminate };
28501 let cookie = self.send_void_request(request, false);
28502 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
28503 res
28504 }
28505
28506 #[cfg(feature = "record")]
28507 fn record_query_version<'this>(
28508 &'this mut self,
28509 major_version: types::Card16,
28510 minor_version: types::Card16,
28511 ) -> futures::SendRequest<'this, Self, types::record::QueryVersionReply> {
28512 let span = tracing::info_span!(
28513 "record_query_version",
28514 major_version = ?major_version,
28515 minor_version = ?minor_version,
28516 );
28517 let request = types::record::QueryVersionRequest {
28518 major_version,
28519 minor_version,
28520 };
28521 let cookie = self.send_reply_request(request).with_span(span);
28522 cookie
28523 }
28524 #[cfg(feature = "record")]
28525 fn record_query_version_immediate<'this>(
28526 &'this mut self,
28527 major_version: types::Card16,
28528 minor_version: types::Card16,
28529 ) -> futures::CheckedSendRequest<'this, Self, types::record::QueryVersionReply> {
28530 let request = types::record::QueryVersionRequest {
28531 major_version,
28532 minor_version,
28533 };
28534 let cookie = self.send_reply_request(request);
28535 let res: futures::CheckedSendRequest<'this, Self, types::record::QueryVersionReply> =
28536 cookie.into();
28537 res
28538 }
28539 #[cfg(feature = "record")]
28540 fn record_create_context<'this>(
28541 &'this mut self,
28542 context: types::record::Context,
28543 element_header: types::ElementHeader,
28544 client_specs: impl AsRef<[types::ClientSpec]>,
28545 ranges: impl AsRef<[types::Range]>,
28546 ) -> futures::SendRequest<'this, Self, ()> {
28547 let span = tracing::info_span!(
28548 "record_create_context",
28549 context = ?context,
28550 element_header = ?element_header,
28551 );
28552 let request = types::record::CreateContextRequest {
28553 context,
28554 element_header,
28555 client_specs: Cow::Borrowed(client_specs.as_ref()),
28556 ranges: Cow::Borrowed(ranges.as_ref()),
28557 };
28558 let cookie = self.send_void_request(request, true).with_span(span);
28559 cookie
28560 }
28561 #[cfg(feature = "record")]
28562 fn record_create_context_checked<'this>(
28563 &'this mut self,
28564 context: types::record::Context,
28565 element_header: types::ElementHeader,
28566 client_specs: impl AsRef<[types::ClientSpec]>,
28567 ranges: impl AsRef<[types::Range]>,
28568 ) -> futures::CheckedSendRequest<'this, Self, ()> {
28569 let request = types::record::CreateContextRequest {
28570 context,
28571 element_header,
28572 client_specs: Cow::Borrowed(client_specs.as_ref()),
28573 ranges: Cow::Borrowed(ranges.as_ref()),
28574 };
28575 let cookie = self.send_void_request(request, false);
28576 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
28577 res
28578 }
28579 #[cfg(feature = "record")]
28580 fn record_register_clients<'this>(
28581 &'this mut self,
28582 context: types::record::Context,
28583 element_header: types::ElementHeader,
28584 client_specs: impl AsRef<[types::ClientSpec]>,
28585 ranges: impl AsRef<[types::Range]>,
28586 ) -> futures::SendRequest<'this, Self, ()> {
28587 let span = tracing::info_span!(
28588 "record_register_clients",
28589 context = ?context,
28590 element_header = ?element_header,
28591 );
28592 let request = types::record::RegisterClientsRequest {
28593 context,
28594 element_header,
28595 client_specs: Cow::Borrowed(client_specs.as_ref()),
28596 ranges: Cow::Borrowed(ranges.as_ref()),
28597 };
28598 let cookie = self.send_void_request(request, true).with_span(span);
28599 cookie
28600 }
28601 #[cfg(feature = "record")]
28602 fn record_register_clients_checked<'this>(
28603 &'this mut self,
28604 context: types::record::Context,
28605 element_header: types::ElementHeader,
28606 client_specs: impl AsRef<[types::ClientSpec]>,
28607 ranges: impl AsRef<[types::Range]>,
28608 ) -> futures::CheckedSendRequest<'this, Self, ()> {
28609 let request = types::record::RegisterClientsRequest {
28610 context,
28611 element_header,
28612 client_specs: Cow::Borrowed(client_specs.as_ref()),
28613 ranges: Cow::Borrowed(ranges.as_ref()),
28614 };
28615 let cookie = self.send_void_request(request, false);
28616 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
28617 res
28618 }
28619 #[cfg(feature = "record")]
28620 fn record_unregister_clients<'this>(
28621 &'this mut self,
28622 context: types::record::Context,
28623 client_specs: impl AsRef<[types::ClientSpec]>,
28624 ) -> futures::SendRequest<'this, Self, ()> {
28625 let span = tracing::info_span!(
28626 "record_unregister_clients",
28627 context = ?context,
28628 );
28629 let request = types::record::UnregisterClientsRequest {
28630 context,
28631 client_specs: Cow::Borrowed(client_specs.as_ref()),
28632 };
28633 let cookie = self.send_void_request(request, true).with_span(span);
28634 cookie
28635 }
28636 #[cfg(feature = "record")]
28637 fn record_unregister_clients_checked<'this>(
28638 &'this mut self,
28639 context: types::record::Context,
28640 client_specs: impl AsRef<[types::ClientSpec]>,
28641 ) -> futures::CheckedSendRequest<'this, Self, ()> {
28642 let request = types::record::UnregisterClientsRequest {
28643 context,
28644 client_specs: Cow::Borrowed(client_specs.as_ref()),
28645 };
28646 let cookie = self.send_void_request(request, false);
28647 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
28648 res
28649 }
28650 #[cfg(feature = "record")]
28651 fn record_get_context<'this>(
28652 &'this mut self,
28653 context: types::record::Context,
28654 ) -> futures::SendRequest<'this, Self, types::record::GetContextReply> {
28655 let span = tracing::info_span!(
28656 "record_get_context",
28657 context = ?context,
28658 );
28659 let request = types::record::GetContextRequest { context };
28660 let cookie = self.send_reply_request(request).with_span(span);
28661 cookie
28662 }
28663 #[cfg(feature = "record")]
28664 fn record_get_context_immediate<'this>(
28665 &'this mut self,
28666 context: types::record::Context,
28667 ) -> futures::CheckedSendRequest<'this, Self, types::record::GetContextReply> {
28668 let request = types::record::GetContextRequest { context };
28669 let cookie = self.send_reply_request(request);
28670 let res: futures::CheckedSendRequest<'this, Self, types::record::GetContextReply> =
28671 cookie.into();
28672 res
28673 }
28674 #[cfg(feature = "record")]
28675 fn record_enable_context<'this>(
28676 &'this mut self,
28677 context: types::record::Context,
28678 ) -> futures::SendRequest<'this, Self, types::record::EnableContextReply> {
28679 let span = tracing::info_span!(
28680 "record_enable_context",
28681 context = ?context,
28682 );
28683 let request = types::record::EnableContextRequest { context };
28684 let cookie = self.send_reply_request(request).with_span(span);
28685 cookie
28686 }
28687 #[cfg(feature = "record")]
28688 fn record_enable_context_immediate<'this>(
28689 &'this mut self,
28690 context: types::record::Context,
28691 ) -> futures::CheckedSendRequest<'this, Self, types::record::EnableContextReply> {
28692 let request = types::record::EnableContextRequest { context };
28693 let cookie = self.send_reply_request(request);
28694 let res: futures::CheckedSendRequest<'this, Self, types::record::EnableContextReply> =
28695 cookie.into();
28696 res
28697 }
28698 #[cfg(feature = "record")]
28699 fn record_disable_context<'this>(
28700 &'this mut self,
28701 context: types::record::Context,
28702 ) -> futures::SendRequest<'this, Self, ()> {
28703 let span = tracing::info_span!(
28704 "record_disable_context",
28705 context = ?context,
28706 );
28707 let request = types::record::DisableContextRequest { context };
28708 let cookie = self.send_void_request(request, true).with_span(span);
28709 cookie
28710 }
28711 #[cfg(feature = "record")]
28712 fn record_disable_context_checked<'this>(
28713 &'this mut self,
28714 context: types::record::Context,
28715 ) -> futures::CheckedSendRequest<'this, Self, ()> {
28716 let request = types::record::DisableContextRequest { context };
28717 let cookie = self.send_void_request(request, false);
28718 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
28719 res
28720 }
28721 #[cfg(feature = "record")]
28722 fn record_free_context<'this>(
28723 &'this mut self,
28724 context: types::record::Context,
28725 ) -> futures::SendRequest<'this, Self, ()> {
28726 let span = tracing::info_span!(
28727 "record_free_context",
28728 context = ?context,
28729 );
28730 let request = types::record::FreeContextRequest { context };
28731 let cookie = self.send_void_request(request, true).with_span(span);
28732 cookie
28733 }
28734 #[cfg(feature = "record")]
28735 fn record_free_context_checked<'this>(
28736 &'this mut self,
28737 context: types::record::Context,
28738 ) -> futures::CheckedSendRequest<'this, Self, ()> {
28739 let request = types::record::FreeContextRequest { context };
28740 let cookie = self.send_void_request(request, false);
28741 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
28742 res
28743 }
28744
28745 #[cfg(feature = "render")]
28746 fn render_query_version<'this>(
28747 &'this mut self,
28748 client_major_version: types::Card32,
28749 client_minor_version: types::Card32,
28750 ) -> futures::SendRequest<'this, Self, types::render::QueryVersionReply> {
28751 let span = tracing::info_span!(
28752 "render_query_version",
28753 client_major_version = ?client_major_version,
28754 client_minor_version = ?client_minor_version,
28755 );
28756 let request = types::render::QueryVersionRequest {
28757 client_major_version,
28758 client_minor_version,
28759 };
28760 let cookie = self.send_reply_request(request).with_span(span);
28761 cookie
28762 }
28763 #[cfg(feature = "render")]
28764 fn render_query_version_immediate<'this>(
28765 &'this mut self,
28766 client_major_version: types::Card32,
28767 client_minor_version: types::Card32,
28768 ) -> futures::CheckedSendRequest<'this, Self, types::render::QueryVersionReply> {
28769 let request = types::render::QueryVersionRequest {
28770 client_major_version,
28771 client_minor_version,
28772 };
28773 let cookie = self.send_reply_request(request);
28774 let res: futures::CheckedSendRequest<'this, Self, types::render::QueryVersionReply> =
28775 cookie.into();
28776 res
28777 }
28778 #[cfg(feature = "render")]
28779 fn render_query_pict_formats<'this>(
28780 &'this mut self,
28781 ) -> futures::SendRequest<'this, Self, types::render::QueryPictFormatsReply> {
28782 let span = tracing::info_span!("render_query_pict_formats",);
28783 let request = types::render::QueryPictFormatsRequest {};
28784 let cookie = self.send_reply_request(request).with_span(span);
28785 cookie
28786 }
28787 #[cfg(feature = "render")]
28788 fn render_query_pict_formats_immediate<'this>(
28789 &'this mut self,
28790 ) -> futures::CheckedSendRequest<'this, Self, types::render::QueryPictFormatsReply> {
28791 let request = types::render::QueryPictFormatsRequest {};
28792 let cookie = self.send_reply_request(request);
28793 let res: futures::CheckedSendRequest<'this, Self, types::render::QueryPictFormatsReply> =
28794 cookie.into();
28795 res
28796 }
28797 #[cfg(feature = "render")]
28798 fn render_query_pict_index_values<'this>(
28799 &'this mut self,
28800 format: types::Pictformat,
28801 ) -> futures::SendRequest<'this, Self, types::render::QueryPictIndexValuesReply> {
28802 let span = tracing::info_span!(
28803 "render_query_pict_index_values",
28804 format = ?format,
28805 );
28806 let request = types::render::QueryPictIndexValuesRequest { format };
28807 let cookie = self.send_reply_request(request).with_span(span);
28808 cookie
28809 }
28810 #[cfg(feature = "render")]
28811 fn render_query_pict_index_values_immediate<'this>(
28812 &'this mut self,
28813 format: types::Pictformat,
28814 ) -> futures::CheckedSendRequest<'this, Self, types::render::QueryPictIndexValuesReply> {
28815 let request = types::render::QueryPictIndexValuesRequest { format };
28816 let cookie = self.send_reply_request(request);
28817 let res: futures::CheckedSendRequest<
28818 'this,
28819 Self,
28820 types::render::QueryPictIndexValuesReply,
28821 > = cookie.into();
28822 res
28823 }
28824 #[cfg(feature = "render")]
28825 fn render_create_picture<'this>(
28826 &'this mut self,
28827 pid: types::Picture,
28828 drawable: types::xproto::Drawable,
28829 format: types::Pictformat,
28830 value_list: impl Borrow<types::render::CreatePictureAux>,
28831 ) -> futures::SendRequest<'this, Self, ()> {
28832 let span = tracing::info_span!(
28833 "render_create_picture",
28834 pid = ?pid,
28835 drawable = ?drawable,
28836 format = ?format,
28837 );
28838 let request = types::render::CreatePictureRequest {
28839 pid,
28840 drawable,
28841 format,
28842 value_list: Cow::Borrowed(value_list.borrow()),
28843 };
28844 let cookie = self.send_void_request(request, true).with_span(span);
28845 cookie
28846 }
28847 #[cfg(feature = "render")]
28848 fn render_create_picture_checked<'this>(
28849 &'this mut self,
28850 pid: types::Picture,
28851 drawable: types::xproto::Drawable,
28852 format: types::Pictformat,
28853 value_list: impl Borrow<types::render::CreatePictureAux>,
28854 ) -> futures::CheckedSendRequest<'this, Self, ()> {
28855 let request = types::render::CreatePictureRequest {
28856 pid,
28857 drawable,
28858 format,
28859 value_list: Cow::Borrowed(value_list.borrow()),
28860 };
28861 let cookie = self.send_void_request(request, false);
28862 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
28863 res
28864 }
28865 #[cfg(feature = "render")]
28866 fn render_change_picture<'this>(
28867 &'this mut self,
28868 picture: types::Picture,
28869 value_list: impl Borrow<types::render::ChangePictureAux>,
28870 ) -> futures::SendRequest<'this, Self, ()> {
28871 let span = tracing::info_span!(
28872 "render_change_picture",
28873 picture = ?picture,
28874 );
28875 let request = types::render::ChangePictureRequest {
28876 picture,
28877 value_list: Cow::Borrowed(value_list.borrow()),
28878 };
28879 let cookie = self.send_void_request(request, true).with_span(span);
28880 cookie
28881 }
28882 #[cfg(feature = "render")]
28883 fn render_change_picture_checked<'this>(
28884 &'this mut self,
28885 picture: types::Picture,
28886 value_list: impl Borrow<types::render::ChangePictureAux>,
28887 ) -> futures::CheckedSendRequest<'this, Self, ()> {
28888 let request = types::render::ChangePictureRequest {
28889 picture,
28890 value_list: Cow::Borrowed(value_list.borrow()),
28891 };
28892 let cookie = self.send_void_request(request, false);
28893 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
28894 res
28895 }
28896 #[cfg(feature = "render")]
28897 fn render_set_picture_clip_rectangles<'this>(
28898 &'this mut self,
28899 picture: types::Picture,
28900 clip_x_origin: types::Int16,
28901 clip_y_origin: types::Int16,
28902 rectangles: impl AsRef<[types::Rectangle]>,
28903 ) -> futures::SendRequest<'this, Self, ()> {
28904 let span = tracing::info_span!(
28905 "render_set_picture_clip_rectangles",
28906 picture = ?picture,
28907 clip_x_origin = ?clip_x_origin,
28908 clip_y_origin = ?clip_y_origin,
28909 );
28910 let request = types::render::SetPictureClipRectanglesRequest {
28911 picture,
28912 clip_x_origin,
28913 clip_y_origin,
28914 rectangles: Cow::Borrowed(rectangles.as_ref()),
28915 };
28916 let cookie = self.send_void_request(request, true).with_span(span);
28917 cookie
28918 }
28919 #[cfg(feature = "render")]
28920 fn render_set_picture_clip_rectangles_checked<'this>(
28921 &'this mut self,
28922 picture: types::Picture,
28923 clip_x_origin: types::Int16,
28924 clip_y_origin: types::Int16,
28925 rectangles: impl AsRef<[types::Rectangle]>,
28926 ) -> futures::CheckedSendRequest<'this, Self, ()> {
28927 let request = types::render::SetPictureClipRectanglesRequest {
28928 picture,
28929 clip_x_origin,
28930 clip_y_origin,
28931 rectangles: Cow::Borrowed(rectangles.as_ref()),
28932 };
28933 let cookie = self.send_void_request(request, false);
28934 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
28935 res
28936 }
28937 #[cfg(feature = "render")]
28938 fn render_free_picture<'this>(
28939 &'this mut self,
28940 picture: types::Picture,
28941 ) -> futures::SendRequest<'this, Self, ()> {
28942 let span = tracing::info_span!(
28943 "render_free_picture",
28944 picture = ?picture,
28945 );
28946 let request = types::render::FreePictureRequest { picture };
28947 let cookie = self.send_void_request(request, true).with_span(span);
28948 cookie
28949 }
28950 #[cfg(feature = "render")]
28951 fn render_free_picture_checked<'this>(
28952 &'this mut self,
28953 picture: types::Picture,
28954 ) -> futures::CheckedSendRequest<'this, Self, ()> {
28955 let request = types::render::FreePictureRequest { picture };
28956 let cookie = self.send_void_request(request, false);
28957 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
28958 res
28959 }
28960 #[cfg(feature = "render")]
28961 fn render_composite<'this>(
28962 &'this mut self,
28963 op: types::PictOp,
28964 src: types::Picture,
28965 mask: impl Into<types::Picture>,
28966 dst: types::Picture,
28967 src_x: types::Int16,
28968 src_y: types::Int16,
28969 mask_x: types::Int16,
28970 mask_y: types::Int16,
28971 dst_x: types::Int16,
28972 dst_y: types::Int16,
28973 width: types::Card16,
28974 height: types::Card16,
28975 ) -> futures::SendRequest<'this, Self, ()> {
28976 let span = tracing::info_span!(
28977 "render_composite",
28978 op = ?op,
28979 src = ?src,
28980 dst = ?dst,
28981 src_x = ?src_x,
28982 src_y = ?src_y,
28983 mask_x = ?mask_x,
28984 mask_y = ?mask_y,
28985 dst_x = ?dst_x,
28986 dst_y = ?dst_y,
28987 width = ?width,
28988 height = ?height,
28989 );
28990 let request = types::render::CompositeRequest {
28991 op,
28992 src,
28993 mask: Into::<u32>::into(mask.into()) as _,
28994 dst,
28995 src_x,
28996 src_y,
28997 mask_x,
28998 mask_y,
28999 dst_x,
29000 dst_y,
29001 width,
29002 height,
29003 };
29004 let cookie = self.send_void_request(request, true).with_span(span);
29005 cookie
29006 }
29007 #[cfg(feature = "render")]
29008 fn render_composite_checked<'this>(
29009 &'this mut self,
29010 op: types::PictOp,
29011 src: types::Picture,
29012 mask: impl Into<types::Picture>,
29013 dst: types::Picture,
29014 src_x: types::Int16,
29015 src_y: types::Int16,
29016 mask_x: types::Int16,
29017 mask_y: types::Int16,
29018 dst_x: types::Int16,
29019 dst_y: types::Int16,
29020 width: types::Card16,
29021 height: types::Card16,
29022 ) -> futures::CheckedSendRequest<'this, Self, ()> {
29023 let request = types::render::CompositeRequest {
29024 op,
29025 src,
29026 mask: Into::<u32>::into(mask.into()) as _,
29027 dst,
29028 src_x,
29029 src_y,
29030 mask_x,
29031 mask_y,
29032 dst_x,
29033 dst_y,
29034 width,
29035 height,
29036 };
29037 let cookie = self.send_void_request(request, false);
29038 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
29039 res
29040 }
29041 #[cfg(feature = "render")]
29042 fn render_trapezoids<'this>(
29043 &'this mut self,
29044 op: types::PictOp,
29045 src: types::Picture,
29046 dst: types::Picture,
29047 mask_format: types::Pictformat,
29048 src_x: types::Int16,
29049 src_y: types::Int16,
29050 traps: impl AsRef<[types::Trapezoid]>,
29051 ) -> futures::SendRequest<'this, Self, ()> {
29052 let span = tracing::info_span!(
29053 "render_trapezoids",
29054 op = ?op,
29055 src = ?src,
29056 dst = ?dst,
29057 mask_format = ?mask_format,
29058 src_x = ?src_x,
29059 src_y = ?src_y,
29060 );
29061 let request = types::render::TrapezoidsRequest {
29062 op,
29063 src,
29064 dst,
29065 mask_format,
29066 src_x,
29067 src_y,
29068 traps: Cow::Borrowed(traps.as_ref()),
29069 };
29070 let cookie = self.send_void_request(request, true).with_span(span);
29071 cookie
29072 }
29073 #[cfg(feature = "render")]
29074 fn render_trapezoids_checked<'this>(
29075 &'this mut self,
29076 op: types::PictOp,
29077 src: types::Picture,
29078 dst: types::Picture,
29079 mask_format: types::Pictformat,
29080 src_x: types::Int16,
29081 src_y: types::Int16,
29082 traps: impl AsRef<[types::Trapezoid]>,
29083 ) -> futures::CheckedSendRequest<'this, Self, ()> {
29084 let request = types::render::TrapezoidsRequest {
29085 op,
29086 src,
29087 dst,
29088 mask_format,
29089 src_x,
29090 src_y,
29091 traps: Cow::Borrowed(traps.as_ref()),
29092 };
29093 let cookie = self.send_void_request(request, false);
29094 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
29095 res
29096 }
29097 #[cfg(feature = "render")]
29098 fn render_triangles<'this>(
29099 &'this mut self,
29100 op: types::PictOp,
29101 src: types::Picture,
29102 dst: types::Picture,
29103 mask_format: types::Pictformat,
29104 src_x: types::Int16,
29105 src_y: types::Int16,
29106 triangles: impl AsRef<[types::Triangle]>,
29107 ) -> futures::SendRequest<'this, Self, ()> {
29108 let span = tracing::info_span!(
29109 "render_triangles",
29110 op = ?op,
29111 src = ?src,
29112 dst = ?dst,
29113 mask_format = ?mask_format,
29114 src_x = ?src_x,
29115 src_y = ?src_y,
29116 );
29117 let request = types::render::TrianglesRequest {
29118 op,
29119 src,
29120 dst,
29121 mask_format,
29122 src_x,
29123 src_y,
29124 triangles: Cow::Borrowed(triangles.as_ref()),
29125 };
29126 let cookie = self.send_void_request(request, true).with_span(span);
29127 cookie
29128 }
29129 #[cfg(feature = "render")]
29130 fn render_triangles_checked<'this>(
29131 &'this mut self,
29132 op: types::PictOp,
29133 src: types::Picture,
29134 dst: types::Picture,
29135 mask_format: types::Pictformat,
29136 src_x: types::Int16,
29137 src_y: types::Int16,
29138 triangles: impl AsRef<[types::Triangle]>,
29139 ) -> futures::CheckedSendRequest<'this, Self, ()> {
29140 let request = types::render::TrianglesRequest {
29141 op,
29142 src,
29143 dst,
29144 mask_format,
29145 src_x,
29146 src_y,
29147 triangles: Cow::Borrowed(triangles.as_ref()),
29148 };
29149 let cookie = self.send_void_request(request, false);
29150 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
29151 res
29152 }
29153 #[cfg(feature = "render")]
29154 fn render_tri_strip<'this>(
29155 &'this mut self,
29156 op: types::PictOp,
29157 src: types::Picture,
29158 dst: types::Picture,
29159 mask_format: types::Pictformat,
29160 src_x: types::Int16,
29161 src_y: types::Int16,
29162 points: impl AsRef<[types::Pointfix]>,
29163 ) -> futures::SendRequest<'this, Self, ()> {
29164 let span = tracing::info_span!(
29165 "render_tri_strip",
29166 op = ?op,
29167 src = ?src,
29168 dst = ?dst,
29169 mask_format = ?mask_format,
29170 src_x = ?src_x,
29171 src_y = ?src_y,
29172 );
29173 let request = types::render::TriStripRequest {
29174 op,
29175 src,
29176 dst,
29177 mask_format,
29178 src_x,
29179 src_y,
29180 points: Cow::Borrowed(points.as_ref()),
29181 };
29182 let cookie = self.send_void_request(request, true).with_span(span);
29183 cookie
29184 }
29185 #[cfg(feature = "render")]
29186 fn render_tri_strip_checked<'this>(
29187 &'this mut self,
29188 op: types::PictOp,
29189 src: types::Picture,
29190 dst: types::Picture,
29191 mask_format: types::Pictformat,
29192 src_x: types::Int16,
29193 src_y: types::Int16,
29194 points: impl AsRef<[types::Pointfix]>,
29195 ) -> futures::CheckedSendRequest<'this, Self, ()> {
29196 let request = types::render::TriStripRequest {
29197 op,
29198 src,
29199 dst,
29200 mask_format,
29201 src_x,
29202 src_y,
29203 points: Cow::Borrowed(points.as_ref()),
29204 };
29205 let cookie = self.send_void_request(request, false);
29206 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
29207 res
29208 }
29209 #[cfg(feature = "render")]
29210 fn render_tri_fan<'this>(
29211 &'this mut self,
29212 op: types::PictOp,
29213 src: types::Picture,
29214 dst: types::Picture,
29215 mask_format: types::Pictformat,
29216 src_x: types::Int16,
29217 src_y: types::Int16,
29218 points: impl AsRef<[types::Pointfix]>,
29219 ) -> futures::SendRequest<'this, Self, ()> {
29220 let span = tracing::info_span!(
29221 "render_tri_fan",
29222 op = ?op,
29223 src = ?src,
29224 dst = ?dst,
29225 mask_format = ?mask_format,
29226 src_x = ?src_x,
29227 src_y = ?src_y,
29228 );
29229 let request = types::render::TriFanRequest {
29230 op,
29231 src,
29232 dst,
29233 mask_format,
29234 src_x,
29235 src_y,
29236 points: Cow::Borrowed(points.as_ref()),
29237 };
29238 let cookie = self.send_void_request(request, true).with_span(span);
29239 cookie
29240 }
29241 #[cfg(feature = "render")]
29242 fn render_tri_fan_checked<'this>(
29243 &'this mut self,
29244 op: types::PictOp,
29245 src: types::Picture,
29246 dst: types::Picture,
29247 mask_format: types::Pictformat,
29248 src_x: types::Int16,
29249 src_y: types::Int16,
29250 points: impl AsRef<[types::Pointfix]>,
29251 ) -> futures::CheckedSendRequest<'this, Self, ()> {
29252 let request = types::render::TriFanRequest {
29253 op,
29254 src,
29255 dst,
29256 mask_format,
29257 src_x,
29258 src_y,
29259 points: Cow::Borrowed(points.as_ref()),
29260 };
29261 let cookie = self.send_void_request(request, false);
29262 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
29263 res
29264 }
29265 #[cfg(feature = "render")]
29266 fn render_create_glyph_set<'this>(
29267 &'this mut self,
29268 gsid: types::Glyphset,
29269 format: types::Pictformat,
29270 ) -> futures::SendRequest<'this, Self, ()> {
29271 let span = tracing::info_span!(
29272 "render_create_glyph_set",
29273 gsid = ?gsid,
29274 format = ?format,
29275 );
29276 let request = types::render::CreateGlyphSetRequest { gsid, format };
29277 let cookie = self.send_void_request(request, true).with_span(span);
29278 cookie
29279 }
29280 #[cfg(feature = "render")]
29281 fn render_create_glyph_set_checked<'this>(
29282 &'this mut self,
29283 gsid: types::Glyphset,
29284 format: types::Pictformat,
29285 ) -> futures::CheckedSendRequest<'this, Self, ()> {
29286 let request = types::render::CreateGlyphSetRequest { gsid, format };
29287 let cookie = self.send_void_request(request, false);
29288 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
29289 res
29290 }
29291 #[cfg(feature = "render")]
29292 fn render_reference_glyph_set<'this>(
29293 &'this mut self,
29294 gsid: types::Glyphset,
29295 existing: types::Glyphset,
29296 ) -> futures::SendRequest<'this, Self, ()> {
29297 let span = tracing::info_span!(
29298 "render_reference_glyph_set",
29299 gsid = ?gsid,
29300 existing = ?existing,
29301 );
29302 let request = types::render::ReferenceGlyphSetRequest { gsid, existing };
29303 let cookie = self.send_void_request(request, true).with_span(span);
29304 cookie
29305 }
29306 #[cfg(feature = "render")]
29307 fn render_reference_glyph_set_checked<'this>(
29308 &'this mut self,
29309 gsid: types::Glyphset,
29310 existing: types::Glyphset,
29311 ) -> futures::CheckedSendRequest<'this, Self, ()> {
29312 let request = types::render::ReferenceGlyphSetRequest { gsid, existing };
29313 let cookie = self.send_void_request(request, false);
29314 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
29315 res
29316 }
29317 #[cfg(feature = "render")]
29318 fn render_free_glyph_set<'this>(
29319 &'this mut self,
29320 glyphset: types::Glyphset,
29321 ) -> futures::SendRequest<'this, Self, ()> {
29322 let span = tracing::info_span!(
29323 "render_free_glyph_set",
29324 glyphset = ?glyphset,
29325 );
29326 let request = types::render::FreeGlyphSetRequest { glyphset };
29327 let cookie = self.send_void_request(request, true).with_span(span);
29328 cookie
29329 }
29330 #[cfg(feature = "render")]
29331 fn render_free_glyph_set_checked<'this>(
29332 &'this mut self,
29333 glyphset: types::Glyphset,
29334 ) -> futures::CheckedSendRequest<'this, Self, ()> {
29335 let request = types::render::FreeGlyphSetRequest { glyphset };
29336 let cookie = self.send_void_request(request, false);
29337 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
29338 res
29339 }
29340 #[cfg(feature = "render")]
29341 fn render_add_glyphs<'this>(
29342 &'this mut self,
29343 glyphset: types::Glyphset,
29344 glyphids: impl AsRef<[types::Card32]>,
29345 glyphs: impl AsRef<[types::Glyphinfo]>,
29346 data: impl AsRef<[types::Byte]>,
29347 ) -> futures::SendRequest<'this, Self, ()> {
29348 let span = tracing::info_span!(
29349 "render_add_glyphs",
29350 glyphset = ?glyphset,
29351 );
29352 let request = types::render::AddGlyphsRequest {
29353 glyphset,
29354 glyphids: Cow::Borrowed(glyphids.as_ref()),
29355 glyphs: Cow::Borrowed(glyphs.as_ref()),
29356 data: Cow::Borrowed(data.as_ref()),
29357 };
29358 let cookie = self.send_void_request(request, true).with_span(span);
29359 cookie
29360 }
29361 #[cfg(feature = "render")]
29362 fn render_add_glyphs_checked<'this>(
29363 &'this mut self,
29364 glyphset: types::Glyphset,
29365 glyphids: impl AsRef<[types::Card32]>,
29366 glyphs: impl AsRef<[types::Glyphinfo]>,
29367 data: impl AsRef<[types::Byte]>,
29368 ) -> futures::CheckedSendRequest<'this, Self, ()> {
29369 let request = types::render::AddGlyphsRequest {
29370 glyphset,
29371 glyphids: Cow::Borrowed(glyphids.as_ref()),
29372 glyphs: Cow::Borrowed(glyphs.as_ref()),
29373 data: Cow::Borrowed(data.as_ref()),
29374 };
29375 let cookie = self.send_void_request(request, false);
29376 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
29377 res
29378 }
29379 #[cfg(feature = "render")]
29380 fn render_free_glyphs<'this>(
29381 &'this mut self,
29382 glyphset: types::Glyphset,
29383 glyphs: impl AsRef<[types::Glyph]>,
29384 ) -> futures::SendRequest<'this, Self, ()> {
29385 let span = tracing::info_span!(
29386 "render_free_glyphs",
29387 glyphset = ?glyphset,
29388 );
29389 let request = types::render::FreeGlyphsRequest {
29390 glyphset,
29391 glyphs: Cow::Borrowed(glyphs.as_ref()),
29392 };
29393 let cookie = self.send_void_request(request, true).with_span(span);
29394 cookie
29395 }
29396 #[cfg(feature = "render")]
29397 fn render_free_glyphs_checked<'this>(
29398 &'this mut self,
29399 glyphset: types::Glyphset,
29400 glyphs: impl AsRef<[types::Glyph]>,
29401 ) -> futures::CheckedSendRequest<'this, Self, ()> {
29402 let request = types::render::FreeGlyphsRequest {
29403 glyphset,
29404 glyphs: Cow::Borrowed(glyphs.as_ref()),
29405 };
29406 let cookie = self.send_void_request(request, false);
29407 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
29408 res
29409 }
29410 #[cfg(feature = "render")]
29411 fn render_composite_glyphs8<'this>(
29412 &'this mut self,
29413 op: types::PictOp,
29414 src: types::Picture,
29415 dst: types::Picture,
29416 mask_format: types::Pictformat,
29417 glyphset: types::Glyphset,
29418 src_x: types::Int16,
29419 src_y: types::Int16,
29420 glyphcmds: impl AsRef<[types::Byte]>,
29421 ) -> futures::SendRequest<'this, Self, ()> {
29422 let span = tracing::info_span!(
29423 "render_composite_glyphs8",
29424 op = ?op,
29425 src = ?src,
29426 dst = ?dst,
29427 mask_format = ?mask_format,
29428 glyphset = ?glyphset,
29429 src_x = ?src_x,
29430 src_y = ?src_y,
29431 );
29432 let request = types::render::CompositeGlyphs8Request {
29433 op,
29434 src,
29435 dst,
29436 mask_format,
29437 glyphset,
29438 src_x,
29439 src_y,
29440 glyphcmds: Cow::Borrowed(glyphcmds.as_ref()),
29441 };
29442 let cookie = self.send_void_request(request, true).with_span(span);
29443 cookie
29444 }
29445 #[cfg(feature = "render")]
29446 fn render_composite_glyphs8_checked<'this>(
29447 &'this mut self,
29448 op: types::PictOp,
29449 src: types::Picture,
29450 dst: types::Picture,
29451 mask_format: types::Pictformat,
29452 glyphset: types::Glyphset,
29453 src_x: types::Int16,
29454 src_y: types::Int16,
29455 glyphcmds: impl AsRef<[types::Byte]>,
29456 ) -> futures::CheckedSendRequest<'this, Self, ()> {
29457 let request = types::render::CompositeGlyphs8Request {
29458 op,
29459 src,
29460 dst,
29461 mask_format,
29462 glyphset,
29463 src_x,
29464 src_y,
29465 glyphcmds: Cow::Borrowed(glyphcmds.as_ref()),
29466 };
29467 let cookie = self.send_void_request(request, false);
29468 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
29469 res
29470 }
29471 #[cfg(feature = "render")]
29472 fn render_composite_glyphs16<'this>(
29473 &'this mut self,
29474 op: types::PictOp,
29475 src: types::Picture,
29476 dst: types::Picture,
29477 mask_format: types::Pictformat,
29478 glyphset: types::Glyphset,
29479 src_x: types::Int16,
29480 src_y: types::Int16,
29481 glyphcmds: impl AsRef<[types::Byte]>,
29482 ) -> futures::SendRequest<'this, Self, ()> {
29483 let span = tracing::info_span!(
29484 "render_composite_glyphs16",
29485 op = ?op,
29486 src = ?src,
29487 dst = ?dst,
29488 mask_format = ?mask_format,
29489 glyphset = ?glyphset,
29490 src_x = ?src_x,
29491 src_y = ?src_y,
29492 );
29493 let request = types::render::CompositeGlyphs16Request {
29494 op,
29495 src,
29496 dst,
29497 mask_format,
29498 glyphset,
29499 src_x,
29500 src_y,
29501 glyphcmds: Cow::Borrowed(glyphcmds.as_ref()),
29502 };
29503 let cookie = self.send_void_request(request, true).with_span(span);
29504 cookie
29505 }
29506 #[cfg(feature = "render")]
29507 fn render_composite_glyphs16_checked<'this>(
29508 &'this mut self,
29509 op: types::PictOp,
29510 src: types::Picture,
29511 dst: types::Picture,
29512 mask_format: types::Pictformat,
29513 glyphset: types::Glyphset,
29514 src_x: types::Int16,
29515 src_y: types::Int16,
29516 glyphcmds: impl AsRef<[types::Byte]>,
29517 ) -> futures::CheckedSendRequest<'this, Self, ()> {
29518 let request = types::render::CompositeGlyphs16Request {
29519 op,
29520 src,
29521 dst,
29522 mask_format,
29523 glyphset,
29524 src_x,
29525 src_y,
29526 glyphcmds: Cow::Borrowed(glyphcmds.as_ref()),
29527 };
29528 let cookie = self.send_void_request(request, false);
29529 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
29530 res
29531 }
29532 #[cfg(feature = "render")]
29533 fn render_composite_glyphs32<'this>(
29534 &'this mut self,
29535 op: types::PictOp,
29536 src: types::Picture,
29537 dst: types::Picture,
29538 mask_format: types::Pictformat,
29539 glyphset: types::Glyphset,
29540 src_x: types::Int16,
29541 src_y: types::Int16,
29542 glyphcmds: impl AsRef<[types::Byte]>,
29543 ) -> futures::SendRequest<'this, Self, ()> {
29544 let span = tracing::info_span!(
29545 "render_composite_glyphs32",
29546 op = ?op,
29547 src = ?src,
29548 dst = ?dst,
29549 mask_format = ?mask_format,
29550 glyphset = ?glyphset,
29551 src_x = ?src_x,
29552 src_y = ?src_y,
29553 );
29554 let request = types::render::CompositeGlyphs32Request {
29555 op,
29556 src,
29557 dst,
29558 mask_format,
29559 glyphset,
29560 src_x,
29561 src_y,
29562 glyphcmds: Cow::Borrowed(glyphcmds.as_ref()),
29563 };
29564 let cookie = self.send_void_request(request, true).with_span(span);
29565 cookie
29566 }
29567 #[cfg(feature = "render")]
29568 fn render_composite_glyphs32_checked<'this>(
29569 &'this mut self,
29570 op: types::PictOp,
29571 src: types::Picture,
29572 dst: types::Picture,
29573 mask_format: types::Pictformat,
29574 glyphset: types::Glyphset,
29575 src_x: types::Int16,
29576 src_y: types::Int16,
29577 glyphcmds: impl AsRef<[types::Byte]>,
29578 ) -> futures::CheckedSendRequest<'this, Self, ()> {
29579 let request = types::render::CompositeGlyphs32Request {
29580 op,
29581 src,
29582 dst,
29583 mask_format,
29584 glyphset,
29585 src_x,
29586 src_y,
29587 glyphcmds: Cow::Borrowed(glyphcmds.as_ref()),
29588 };
29589 let cookie = self.send_void_request(request, false);
29590 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
29591 res
29592 }
29593 #[cfg(feature = "render")]
29594 fn render_fill_rectangles<'this>(
29595 &'this mut self,
29596 op: types::PictOp,
29597 dst: types::Picture,
29598 color: types::Color,
29599 rects: impl AsRef<[types::Rectangle]>,
29600 ) -> futures::SendRequest<'this, Self, ()> {
29601 let span = tracing::info_span!(
29602 "render_fill_rectangles",
29603 op = ?op,
29604 dst = ?dst,
29605 color = ?color,
29606 );
29607 let request = types::render::FillRectanglesRequest {
29608 op,
29609 dst,
29610 color,
29611 rects: Cow::Borrowed(rects.as_ref()),
29612 };
29613 let cookie = self.send_void_request(request, true).with_span(span);
29614 cookie
29615 }
29616 #[cfg(feature = "render")]
29617 fn render_fill_rectangles_checked<'this>(
29618 &'this mut self,
29619 op: types::PictOp,
29620 dst: types::Picture,
29621 color: types::Color,
29622 rects: impl AsRef<[types::Rectangle]>,
29623 ) -> futures::CheckedSendRequest<'this, Self, ()> {
29624 let request = types::render::FillRectanglesRequest {
29625 op,
29626 dst,
29627 color,
29628 rects: Cow::Borrowed(rects.as_ref()),
29629 };
29630 let cookie = self.send_void_request(request, false);
29631 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
29632 res
29633 }
29634 #[cfg(feature = "render")]
29635 fn render_create_cursor<'this>(
29636 &'this mut self,
29637 cid: types::xproto::Cursor,
29638 source: types::Picture,
29639 x: types::Card16,
29640 y: types::Card16,
29641 ) -> futures::SendRequest<'this, Self, ()> {
29642 let span = tracing::info_span!(
29643 "render_create_cursor",
29644 cid = ?cid,
29645 source = ?source,
29646 x = ?x,
29647 y = ?y,
29648 );
29649 let request = types::render::CreateCursorRequest { cid, source, x, y };
29650 let cookie = self.send_void_request(request, true).with_span(span);
29651 cookie
29652 }
29653 #[cfg(feature = "render")]
29654 fn render_create_cursor_checked<'this>(
29655 &'this mut self,
29656 cid: types::xproto::Cursor,
29657 source: types::Picture,
29658 x: types::Card16,
29659 y: types::Card16,
29660 ) -> futures::CheckedSendRequest<'this, Self, ()> {
29661 let request = types::render::CreateCursorRequest { cid, source, x, y };
29662 let cookie = self.send_void_request(request, false);
29663 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
29664 res
29665 }
29666 #[cfg(feature = "render")]
29667 fn render_set_picture_transform<'this>(
29668 &'this mut self,
29669 picture: types::Picture,
29670 transform: types::render::Transform,
29671 ) -> futures::SendRequest<'this, Self, ()> {
29672 let span = tracing::info_span!(
29673 "render_set_picture_transform",
29674 picture = ?picture,
29675 transform = ?transform,
29676 );
29677 let request = types::render::SetPictureTransformRequest { picture, transform };
29678 let cookie = self.send_void_request(request, true).with_span(span);
29679 cookie
29680 }
29681 #[cfg(feature = "render")]
29682 fn render_set_picture_transform_checked<'this>(
29683 &'this mut self,
29684 picture: types::Picture,
29685 transform: types::render::Transform,
29686 ) -> futures::CheckedSendRequest<'this, Self, ()> {
29687 let request = types::render::SetPictureTransformRequest { picture, transform };
29688 let cookie = self.send_void_request(request, false);
29689 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
29690 res
29691 }
29692 #[cfg(feature = "render")]
29693 fn render_query_filters<'this>(
29694 &'this mut self,
29695 drawable: types::xproto::Drawable,
29696 ) -> futures::SendRequest<'this, Self, types::render::QueryFiltersReply> {
29697 let span = tracing::info_span!(
29698 "render_query_filters",
29699 drawable = ?drawable,
29700 );
29701 let request = types::render::QueryFiltersRequest { drawable };
29702 let cookie = self.send_reply_request(request).with_span(span);
29703 cookie
29704 }
29705 #[cfg(feature = "render")]
29706 fn render_query_filters_immediate<'this>(
29707 &'this mut self,
29708 drawable: types::xproto::Drawable,
29709 ) -> futures::CheckedSendRequest<'this, Self, types::render::QueryFiltersReply> {
29710 let request = types::render::QueryFiltersRequest { drawable };
29711 let cookie = self.send_reply_request(request);
29712 let res: futures::CheckedSendRequest<'this, Self, types::render::QueryFiltersReply> =
29713 cookie.into();
29714 res
29715 }
29716 #[cfg(feature = "render")]
29717 fn render_set_picture_filter<'this>(
29718 &'this mut self,
29719 picture: types::Picture,
29720 filter: impl AsRef<[types::Char]>,
29721 values: impl AsRef<[types::Fixed]>,
29722 ) -> futures::SendRequest<'this, Self, ()> {
29723 let span = tracing::info_span!(
29724 "render_set_picture_filter",
29725 picture = ?picture,
29726 );
29727 let request = types::render::SetPictureFilterRequest {
29728 picture,
29729 filter: Cow::Borrowed(filter.as_ref()),
29730 values: Cow::Borrowed(values.as_ref()),
29731 };
29732 let cookie = self.send_void_request(request, true).with_span(span);
29733 cookie
29734 }
29735 #[cfg(feature = "render")]
29736 fn render_set_picture_filter_checked<'this>(
29737 &'this mut self,
29738 picture: types::Picture,
29739 filter: impl AsRef<[types::Char]>,
29740 values: impl AsRef<[types::Fixed]>,
29741 ) -> futures::CheckedSendRequest<'this, Self, ()> {
29742 let request = types::render::SetPictureFilterRequest {
29743 picture,
29744 filter: Cow::Borrowed(filter.as_ref()),
29745 values: Cow::Borrowed(values.as_ref()),
29746 };
29747 let cookie = self.send_void_request(request, false);
29748 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
29749 res
29750 }
29751 #[cfg(feature = "render")]
29752 fn render_create_anim_cursor<'this>(
29753 &'this mut self,
29754 cid: types::xproto::Cursor,
29755 cursors: impl AsRef<[types::Animcursorelt]>,
29756 ) -> futures::SendRequest<'this, Self, ()> {
29757 let span = tracing::info_span!(
29758 "render_create_anim_cursor",
29759 cid = ?cid,
29760 );
29761 let request = types::render::CreateAnimCursorRequest {
29762 cid,
29763 cursors: Cow::Borrowed(cursors.as_ref()),
29764 };
29765 let cookie = self.send_void_request(request, true).with_span(span);
29766 cookie
29767 }
29768 #[cfg(feature = "render")]
29769 fn render_create_anim_cursor_checked<'this>(
29770 &'this mut self,
29771 cid: types::xproto::Cursor,
29772 cursors: impl AsRef<[types::Animcursorelt]>,
29773 ) -> futures::CheckedSendRequest<'this, Self, ()> {
29774 let request = types::render::CreateAnimCursorRequest {
29775 cid,
29776 cursors: Cow::Borrowed(cursors.as_ref()),
29777 };
29778 let cookie = self.send_void_request(request, false);
29779 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
29780 res
29781 }
29782 #[cfg(feature = "render")]
29783 fn render_add_traps<'this>(
29784 &'this mut self,
29785 picture: types::Picture,
29786 x_off: types::Int16,
29787 y_off: types::Int16,
29788 traps: impl AsRef<[types::Trap]>,
29789 ) -> futures::SendRequest<'this, Self, ()> {
29790 let span = tracing::info_span!(
29791 "render_add_traps",
29792 picture = ?picture,
29793 x_off = ?x_off,
29794 y_off = ?y_off,
29795 );
29796 let request = types::render::AddTrapsRequest {
29797 picture,
29798 x_off,
29799 y_off,
29800 traps: Cow::Borrowed(traps.as_ref()),
29801 };
29802 let cookie = self.send_void_request(request, true).with_span(span);
29803 cookie
29804 }
29805 #[cfg(feature = "render")]
29806 fn render_add_traps_checked<'this>(
29807 &'this mut self,
29808 picture: types::Picture,
29809 x_off: types::Int16,
29810 y_off: types::Int16,
29811 traps: impl AsRef<[types::Trap]>,
29812 ) -> futures::CheckedSendRequest<'this, Self, ()> {
29813 let request = types::render::AddTrapsRequest {
29814 picture,
29815 x_off,
29816 y_off,
29817 traps: Cow::Borrowed(traps.as_ref()),
29818 };
29819 let cookie = self.send_void_request(request, false);
29820 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
29821 res
29822 }
29823 #[cfg(feature = "render")]
29824 fn render_create_solid_fill<'this>(
29825 &'this mut self,
29826 picture: types::Picture,
29827 color: types::Color,
29828 ) -> futures::SendRequest<'this, Self, ()> {
29829 let span = tracing::info_span!(
29830 "render_create_solid_fill",
29831 picture = ?picture,
29832 color = ?color,
29833 );
29834 let request = types::render::CreateSolidFillRequest { picture, color };
29835 let cookie = self.send_void_request(request, true).with_span(span);
29836 cookie
29837 }
29838 #[cfg(feature = "render")]
29839 fn render_create_solid_fill_checked<'this>(
29840 &'this mut self,
29841 picture: types::Picture,
29842 color: types::Color,
29843 ) -> futures::CheckedSendRequest<'this, Self, ()> {
29844 let request = types::render::CreateSolidFillRequest { picture, color };
29845 let cookie = self.send_void_request(request, false);
29846 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
29847 res
29848 }
29849 #[cfg(feature = "render")]
29850 fn render_create_linear_gradient<'this>(
29851 &'this mut self,
29852 picture: types::Picture,
29853 p1: types::Pointfix,
29854 p2: types::Pointfix,
29855 stops: impl AsRef<[types::Fixed]>,
29856 colors: impl AsRef<[types::Color]>,
29857 ) -> futures::SendRequest<'this, Self, ()> {
29858 let span = tracing::info_span!(
29859 "render_create_linear_gradient",
29860 picture = ?picture,
29861 p1 = ?p1,
29862 p2 = ?p2,
29863 );
29864 let request = types::render::CreateLinearGradientRequest {
29865 picture,
29866 p1,
29867 p2,
29868 stops: Cow::Borrowed(stops.as_ref()),
29869 colors: Cow::Borrowed(colors.as_ref()),
29870 };
29871 let cookie = self.send_void_request(request, true).with_span(span);
29872 cookie
29873 }
29874 #[cfg(feature = "render")]
29875 fn render_create_linear_gradient_checked<'this>(
29876 &'this mut self,
29877 picture: types::Picture,
29878 p1: types::Pointfix,
29879 p2: types::Pointfix,
29880 stops: impl AsRef<[types::Fixed]>,
29881 colors: impl AsRef<[types::Color]>,
29882 ) -> futures::CheckedSendRequest<'this, Self, ()> {
29883 let request = types::render::CreateLinearGradientRequest {
29884 picture,
29885 p1,
29886 p2,
29887 stops: Cow::Borrowed(stops.as_ref()),
29888 colors: Cow::Borrowed(colors.as_ref()),
29889 };
29890 let cookie = self.send_void_request(request, false);
29891 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
29892 res
29893 }
29894 #[cfg(feature = "render")]
29895 fn render_create_radial_gradient<'this>(
29896 &'this mut self,
29897 picture: types::Picture,
29898 inner: types::Pointfix,
29899 outer: types::Pointfix,
29900 inner_radius: types::Fixed,
29901 outer_radius: types::Fixed,
29902 stops: impl AsRef<[types::Fixed]>,
29903 colors: impl AsRef<[types::Color]>,
29904 ) -> futures::SendRequest<'this, Self, ()> {
29905 let span = tracing::info_span!(
29906 "render_create_radial_gradient",
29907 picture = ?picture,
29908 inner = ?inner,
29909 outer = ?outer,
29910 inner_radius = ?inner_radius,
29911 outer_radius = ?outer_radius,
29912 );
29913 let request = types::render::CreateRadialGradientRequest {
29914 picture,
29915 inner,
29916 outer,
29917 inner_radius,
29918 outer_radius,
29919 stops: Cow::Borrowed(stops.as_ref()),
29920 colors: Cow::Borrowed(colors.as_ref()),
29921 };
29922 let cookie = self.send_void_request(request, true).with_span(span);
29923 cookie
29924 }
29925 #[cfg(feature = "render")]
29926 fn render_create_radial_gradient_checked<'this>(
29927 &'this mut self,
29928 picture: types::Picture,
29929 inner: types::Pointfix,
29930 outer: types::Pointfix,
29931 inner_radius: types::Fixed,
29932 outer_radius: types::Fixed,
29933 stops: impl AsRef<[types::Fixed]>,
29934 colors: impl AsRef<[types::Color]>,
29935 ) -> futures::CheckedSendRequest<'this, Self, ()> {
29936 let request = types::render::CreateRadialGradientRequest {
29937 picture,
29938 inner,
29939 outer,
29940 inner_radius,
29941 outer_radius,
29942 stops: Cow::Borrowed(stops.as_ref()),
29943 colors: Cow::Borrowed(colors.as_ref()),
29944 };
29945 let cookie = self.send_void_request(request, false);
29946 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
29947 res
29948 }
29949 #[cfg(feature = "render")]
29950 fn render_create_conical_gradient<'this>(
29951 &'this mut self,
29952 picture: types::Picture,
29953 center: types::Pointfix,
29954 angle: types::Fixed,
29955 stops: impl AsRef<[types::Fixed]>,
29956 colors: impl AsRef<[types::Color]>,
29957 ) -> futures::SendRequest<'this, Self, ()> {
29958 let span = tracing::info_span!(
29959 "render_create_conical_gradient",
29960 picture = ?picture,
29961 center = ?center,
29962 angle = ?angle,
29963 );
29964 let request = types::render::CreateConicalGradientRequest {
29965 picture,
29966 center,
29967 angle,
29968 stops: Cow::Borrowed(stops.as_ref()),
29969 colors: Cow::Borrowed(colors.as_ref()),
29970 };
29971 let cookie = self.send_void_request(request, true).with_span(span);
29972 cookie
29973 }
29974 #[cfg(feature = "render")]
29975 fn render_create_conical_gradient_checked<'this>(
29976 &'this mut self,
29977 picture: types::Picture,
29978 center: types::Pointfix,
29979 angle: types::Fixed,
29980 stops: impl AsRef<[types::Fixed]>,
29981 colors: impl AsRef<[types::Color]>,
29982 ) -> futures::CheckedSendRequest<'this, Self, ()> {
29983 let request = types::render::CreateConicalGradientRequest {
29984 picture,
29985 center,
29986 angle,
29987 stops: Cow::Borrowed(stops.as_ref()),
29988 colors: Cow::Borrowed(colors.as_ref()),
29989 };
29990 let cookie = self.send_void_request(request, false);
29991 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
29992 res
29993 }
29994
29995 #[cfg(feature = "res")]
29996 fn res_query_version<'this>(
29997 &'this mut self,
29998 client_major: types::Card8,
29999 client_minor: types::Card8,
30000 ) -> futures::SendRequest<'this, Self, types::res::QueryVersionReply> {
30001 let span = tracing::info_span!(
30002 "res_query_version",
30003 client_major = ?client_major,
30004 client_minor = ?client_minor,
30005 );
30006 let request = types::res::QueryVersionRequest {
30007 client_major,
30008 client_minor,
30009 };
30010 let cookie = self.send_reply_request(request).with_span(span);
30011 cookie
30012 }
30013 #[cfg(feature = "res")]
30014 fn res_query_version_immediate<'this>(
30015 &'this mut self,
30016 client_major: types::Card8,
30017 client_minor: types::Card8,
30018 ) -> futures::CheckedSendRequest<'this, Self, types::res::QueryVersionReply> {
30019 let request = types::res::QueryVersionRequest {
30020 client_major,
30021 client_minor,
30022 };
30023 let cookie = self.send_reply_request(request);
30024 let res: futures::CheckedSendRequest<'this, Self, types::res::QueryVersionReply> =
30025 cookie.into();
30026 res
30027 }
30028 #[cfg(feature = "res")]
30029 fn res_query_clients<'this>(
30030 &'this mut self,
30031 ) -> futures::SendRequest<'this, Self, types::res::QueryClientsReply> {
30032 let span = tracing::info_span!("res_query_clients",);
30033 let request = types::res::QueryClientsRequest {};
30034 let cookie = self.send_reply_request(request).with_span(span);
30035 cookie
30036 }
30037 #[cfg(feature = "res")]
30038 fn res_query_clients_immediate<'this>(
30039 &'this mut self,
30040 ) -> futures::CheckedSendRequest<'this, Self, types::res::QueryClientsReply> {
30041 let request = types::res::QueryClientsRequest {};
30042 let cookie = self.send_reply_request(request);
30043 let res: futures::CheckedSendRequest<'this, Self, types::res::QueryClientsReply> =
30044 cookie.into();
30045 res
30046 }
30047 #[cfg(feature = "res")]
30048 fn res_query_client_resources<'this>(
30049 &'this mut self,
30050 xid: types::Card32,
30051 ) -> futures::SendRequest<'this, Self, types::res::QueryClientResourcesReply> {
30052 let span = tracing::info_span!(
30053 "res_query_client_resources",
30054 xid = ?xid,
30055 );
30056 let request = types::res::QueryClientResourcesRequest { xid };
30057 let cookie = self.send_reply_request(request).with_span(span);
30058 cookie
30059 }
30060 #[cfg(feature = "res")]
30061 fn res_query_client_resources_immediate<'this>(
30062 &'this mut self,
30063 xid: types::Card32,
30064 ) -> futures::CheckedSendRequest<'this, Self, types::res::QueryClientResourcesReply> {
30065 let request = types::res::QueryClientResourcesRequest { xid };
30066 let cookie = self.send_reply_request(request);
30067 let res: futures::CheckedSendRequest<'this, Self, types::res::QueryClientResourcesReply> =
30068 cookie.into();
30069 res
30070 }
30071 #[cfg(feature = "res")]
30072 fn res_query_client_pixmap_bytes<'this>(
30073 &'this mut self,
30074 xid: types::Card32,
30075 ) -> futures::SendRequest<'this, Self, types::res::QueryClientPixmapBytesReply> {
30076 let span = tracing::info_span!(
30077 "res_query_client_pixmap_bytes",
30078 xid = ?xid,
30079 );
30080 let request = types::res::QueryClientPixmapBytesRequest { xid };
30081 let cookie = self.send_reply_request(request).with_span(span);
30082 cookie
30083 }
30084 #[cfg(feature = "res")]
30085 fn res_query_client_pixmap_bytes_immediate<'this>(
30086 &'this mut self,
30087 xid: types::Card32,
30088 ) -> futures::CheckedSendRequest<'this, Self, types::res::QueryClientPixmapBytesReply> {
30089 let request = types::res::QueryClientPixmapBytesRequest { xid };
30090 let cookie = self.send_reply_request(request);
30091 let res: futures::CheckedSendRequest<'this, Self, types::res::QueryClientPixmapBytesReply> =
30092 cookie.into();
30093 res
30094 }
30095 #[cfg(feature = "res")]
30096 fn res_query_client_ids<'this>(
30097 &'this mut self,
30098 specs: impl AsRef<[types::ClientIdSpec]>,
30099 ) -> futures::SendRequest<'this, Self, types::res::QueryClientIdsReply> {
30100 let span = tracing::info_span!("res_query_client_ids",);
30101 let request = types::res::QueryClientIdsRequest {
30102 specs: Cow::Borrowed(specs.as_ref()),
30103 };
30104 let cookie = self.send_reply_request(request).with_span(span);
30105 cookie
30106 }
30107 #[cfg(feature = "res")]
30108 fn res_query_client_ids_immediate<'this>(
30109 &'this mut self,
30110 specs: impl AsRef<[types::ClientIdSpec]>,
30111 ) -> futures::CheckedSendRequest<'this, Self, types::res::QueryClientIdsReply> {
30112 let request = types::res::QueryClientIdsRequest {
30113 specs: Cow::Borrowed(specs.as_ref()),
30114 };
30115 let cookie = self.send_reply_request(request);
30116 let res: futures::CheckedSendRequest<'this, Self, types::res::QueryClientIdsReply> =
30117 cookie.into();
30118 res
30119 }
30120 #[cfg(feature = "res")]
30121 fn res_query_resource_bytes<'this>(
30122 &'this mut self,
30123 client: types::Card32,
30124 specs: impl AsRef<[types::ResourceIdSpec]>,
30125 ) -> futures::SendRequest<'this, Self, types::res::QueryResourceBytesReply> {
30126 let span = tracing::info_span!(
30127 "res_query_resource_bytes",
30128 client = ?client,
30129 );
30130 let request = types::res::QueryResourceBytesRequest {
30131 client,
30132 specs: Cow::Borrowed(specs.as_ref()),
30133 };
30134 let cookie = self.send_reply_request(request).with_span(span);
30135 cookie
30136 }
30137 #[cfg(feature = "res")]
30138 fn res_query_resource_bytes_immediate<'this>(
30139 &'this mut self,
30140 client: types::Card32,
30141 specs: impl AsRef<[types::ResourceIdSpec]>,
30142 ) -> futures::CheckedSendRequest<'this, Self, types::res::QueryResourceBytesReply> {
30143 let request = types::res::QueryResourceBytesRequest {
30144 client,
30145 specs: Cow::Borrowed(specs.as_ref()),
30146 };
30147 let cookie = self.send_reply_request(request);
30148 let res: futures::CheckedSendRequest<'this, Self, types::res::QueryResourceBytesReply> =
30149 cookie.into();
30150 res
30151 }
30152
30153 #[cfg(feature = "screensaver")]
30154 fn screensaver_query_version<'this>(
30155 &'this mut self,
30156 client_major_version: types::Card8,
30157 client_minor_version: types::Card8,
30158 ) -> futures::SendRequest<'this, Self, types::screensaver::QueryVersionReply> {
30159 let span = tracing::info_span!(
30160 "screensaver_query_version",
30161 client_major_version = ?client_major_version,
30162 client_minor_version = ?client_minor_version,
30163 );
30164 let request = types::screensaver::QueryVersionRequest {
30165 client_major_version,
30166 client_minor_version,
30167 };
30168 let cookie = self.send_reply_request(request).with_span(span);
30169 cookie
30170 }
30171 #[cfg(feature = "screensaver")]
30172 fn screensaver_query_version_immediate<'this>(
30173 &'this mut self,
30174 client_major_version: types::Card8,
30175 client_minor_version: types::Card8,
30176 ) -> futures::CheckedSendRequest<'this, Self, types::screensaver::QueryVersionReply> {
30177 let request = types::screensaver::QueryVersionRequest {
30178 client_major_version,
30179 client_minor_version,
30180 };
30181 let cookie = self.send_reply_request(request);
30182 let res: futures::CheckedSendRequest<'this, Self, types::screensaver::QueryVersionReply> =
30183 cookie.into();
30184 res
30185 }
30186 #[cfg(feature = "screensaver")]
30187 fn screensaver_query_info<'this>(
30188 &'this mut self,
30189 drawable: types::xproto::Drawable,
30190 ) -> futures::SendRequest<'this, Self, types::screensaver::QueryInfoReply> {
30191 let span = tracing::info_span!(
30192 "screensaver_query_info",
30193 drawable = ?drawable,
30194 );
30195 let request = types::screensaver::QueryInfoRequest { drawable };
30196 let cookie = self.send_reply_request(request).with_span(span);
30197 cookie
30198 }
30199 #[cfg(feature = "screensaver")]
30200 fn screensaver_query_info_immediate<'this>(
30201 &'this mut self,
30202 drawable: types::xproto::Drawable,
30203 ) -> futures::CheckedSendRequest<'this, Self, types::screensaver::QueryInfoReply> {
30204 let request = types::screensaver::QueryInfoRequest { drawable };
30205 let cookie = self.send_reply_request(request);
30206 let res: futures::CheckedSendRequest<'this, Self, types::screensaver::QueryInfoReply> =
30207 cookie.into();
30208 res
30209 }
30210 #[cfg(feature = "screensaver")]
30211 fn screensaver_select_input<'this>(
30212 &'this mut self,
30213 drawable: types::xproto::Drawable,
30214 event_mask: impl Into<types::screensaver::Event>,
30215 ) -> futures::SendRequest<'this, Self, ()> {
30216 let span = tracing::info_span!(
30217 "screensaver_select_input",
30218 drawable = ?drawable,
30219 );
30220 let request = types::screensaver::SelectInputRequest {
30221 drawable,
30222 event_mask: Into::<u32>::into(event_mask.into()) as _,
30223 };
30224 let cookie = self.send_void_request(request, true).with_span(span);
30225 cookie
30226 }
30227 #[cfg(feature = "screensaver")]
30228 fn screensaver_select_input_checked<'this>(
30229 &'this mut self,
30230 drawable: types::xproto::Drawable,
30231 event_mask: impl Into<types::screensaver::Event>,
30232 ) -> futures::CheckedSendRequest<'this, Self, ()> {
30233 let request = types::screensaver::SelectInputRequest {
30234 drawable,
30235 event_mask: Into::<u32>::into(event_mask.into()) as _,
30236 };
30237 let cookie = self.send_void_request(request, false);
30238 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
30239 res
30240 }
30241 #[cfg(feature = "screensaver")]
30242 fn screensaver_set_attributes<'this>(
30243 &'this mut self,
30244 drawable: types::xproto::Drawable,
30245 x: types::Int16,
30246 y: types::Int16,
30247 width: types::Card16,
30248 height: types::Card16,
30249 border_width: types::Card16,
30250 class: types::WindowClass,
30251 depth: types::Card8,
30252 visual: types::Visualid,
30253 value_list: impl Borrow<types::screensaver::SetAttributesAux>,
30254 ) -> futures::SendRequest<'this, Self, ()> {
30255 let span = tracing::info_span!(
30256 "screensaver_set_attributes",
30257 drawable = ?drawable,
30258 x = ?x,
30259 y = ?y,
30260 width = ?width,
30261 height = ?height,
30262 border_width = ?border_width,
30263 class = ?class,
30264 depth = ?depth,
30265 visual = ?visual,
30266 );
30267 let request = types::screensaver::SetAttributesRequest {
30268 drawable,
30269 x,
30270 y,
30271 width,
30272 height,
30273 border_width,
30274 class,
30275 depth,
30276 visual,
30277 value_list: Cow::Borrowed(value_list.borrow()),
30278 };
30279 let cookie = self.send_void_request(request, true).with_span(span);
30280 cookie
30281 }
30282 #[cfg(feature = "screensaver")]
30283 fn screensaver_set_attributes_checked<'this>(
30284 &'this mut self,
30285 drawable: types::xproto::Drawable,
30286 x: types::Int16,
30287 y: types::Int16,
30288 width: types::Card16,
30289 height: types::Card16,
30290 border_width: types::Card16,
30291 class: types::WindowClass,
30292 depth: types::Card8,
30293 visual: types::Visualid,
30294 value_list: impl Borrow<types::screensaver::SetAttributesAux>,
30295 ) -> futures::CheckedSendRequest<'this, Self, ()> {
30296 let request = types::screensaver::SetAttributesRequest {
30297 drawable,
30298 x,
30299 y,
30300 width,
30301 height,
30302 border_width,
30303 class,
30304 depth,
30305 visual,
30306 value_list: Cow::Borrowed(value_list.borrow()),
30307 };
30308 let cookie = self.send_void_request(request, false);
30309 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
30310 res
30311 }
30312 #[cfg(feature = "screensaver")]
30313 fn screensaver_unset_attributes<'this>(
30314 &'this mut self,
30315 drawable: types::xproto::Drawable,
30316 ) -> futures::SendRequest<'this, Self, ()> {
30317 let span = tracing::info_span!(
30318 "screensaver_unset_attributes",
30319 drawable = ?drawable,
30320 );
30321 let request = types::screensaver::UnsetAttributesRequest { drawable };
30322 let cookie = self.send_void_request(request, true).with_span(span);
30323 cookie
30324 }
30325 #[cfg(feature = "screensaver")]
30326 fn screensaver_unset_attributes_checked<'this>(
30327 &'this mut self,
30328 drawable: types::xproto::Drawable,
30329 ) -> futures::CheckedSendRequest<'this, Self, ()> {
30330 let request = types::screensaver::UnsetAttributesRequest { drawable };
30331 let cookie = self.send_void_request(request, false);
30332 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
30333 res
30334 }
30335 #[cfg(feature = "screensaver")]
30336 fn screensaver_suspend<'this>(
30337 &'this mut self,
30338 suspend: types::Card32,
30339 ) -> futures::SendRequest<'this, Self, ()> {
30340 let span = tracing::info_span!(
30341 "screensaver_suspend",
30342 suspend = ?suspend,
30343 );
30344 let request = types::screensaver::SuspendRequest { suspend };
30345 let cookie = self.send_void_request(request, true).with_span(span);
30346 cookie
30347 }
30348 #[cfg(feature = "screensaver")]
30349 fn screensaver_suspend_checked<'this>(
30350 &'this mut self,
30351 suspend: types::Card32,
30352 ) -> futures::CheckedSendRequest<'this, Self, ()> {
30353 let request = types::screensaver::SuspendRequest { suspend };
30354 let cookie = self.send_void_request(request, false);
30355 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
30356 res
30357 }
30358
30359 #[cfg(feature = "shape")]
30360 fn shape_query_version<'this>(
30361 &'this mut self,
30362 ) -> futures::SendRequest<'this, Self, types::shape::QueryVersionReply> {
30363 let span = tracing::info_span!("shape_query_version",);
30364 let request = types::shape::QueryVersionRequest {};
30365 let cookie = self.send_reply_request(request).with_span(span);
30366 cookie
30367 }
30368 #[cfg(feature = "shape")]
30369 fn shape_query_version_immediate<'this>(
30370 &'this mut self,
30371 ) -> futures::CheckedSendRequest<'this, Self, types::shape::QueryVersionReply> {
30372 let request = types::shape::QueryVersionRequest {};
30373 let cookie = self.send_reply_request(request);
30374 let res: futures::CheckedSendRequest<'this, Self, types::shape::QueryVersionReply> =
30375 cookie.into();
30376 res
30377 }
30378 #[cfg(feature = "shape")]
30379 fn shape_rectangles<'this>(
30380 &'this mut self,
30381 operation: types::SO,
30382 destination_kind: types::SK,
30383 ordering: types::ClipOrdering,
30384 destination_window: types::xproto::Window,
30385 x_offset: types::Int16,
30386 y_offset: types::Int16,
30387 rectangles: impl AsRef<[types::Rectangle]>,
30388 ) -> futures::SendRequest<'this, Self, ()> {
30389 let span = tracing::info_span!(
30390 "shape_rectangles",
30391 operation = ?operation,
30392 destination_kind = ?destination_kind,
30393 ordering = ?ordering,
30394 destination_window = ?destination_window,
30395 x_offset = ?x_offset,
30396 y_offset = ?y_offset,
30397 );
30398 let request = types::shape::RectanglesRequest {
30399 operation,
30400 destination_kind,
30401 ordering,
30402 destination_window,
30403 x_offset,
30404 y_offset,
30405 rectangles: Cow::Borrowed(rectangles.as_ref()),
30406 };
30407 let cookie = self.send_void_request(request, true).with_span(span);
30408 cookie
30409 }
30410 #[cfg(feature = "shape")]
30411 fn shape_rectangles_checked<'this>(
30412 &'this mut self,
30413 operation: types::SO,
30414 destination_kind: types::SK,
30415 ordering: types::ClipOrdering,
30416 destination_window: types::xproto::Window,
30417 x_offset: types::Int16,
30418 y_offset: types::Int16,
30419 rectangles: impl AsRef<[types::Rectangle]>,
30420 ) -> futures::CheckedSendRequest<'this, Self, ()> {
30421 let request = types::shape::RectanglesRequest {
30422 operation,
30423 destination_kind,
30424 ordering,
30425 destination_window,
30426 x_offset,
30427 y_offset,
30428 rectangles: Cow::Borrowed(rectangles.as_ref()),
30429 };
30430 let cookie = self.send_void_request(request, false);
30431 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
30432 res
30433 }
30434 #[cfg(feature = "shape")]
30435 fn shape_mask<'this>(
30436 &'this mut self,
30437 operation: types::SO,
30438 destination_kind: types::SK,
30439 destination_window: types::xproto::Window,
30440 x_offset: types::Int16,
30441 y_offset: types::Int16,
30442 source_bitmap: impl Into<types::xproto::Pixmap>,
30443 ) -> futures::SendRequest<'this, Self, ()> {
30444 let span = tracing::info_span!(
30445 "shape_mask",
30446 operation = ?operation,
30447 destination_kind = ?destination_kind,
30448 destination_window = ?destination_window,
30449 x_offset = ?x_offset,
30450 y_offset = ?y_offset,
30451 );
30452 let request = types::shape::MaskRequest {
30453 operation,
30454 destination_kind,
30455 destination_window,
30456 x_offset,
30457 y_offset,
30458 source_bitmap: Into::<u32>::into(source_bitmap.into()) as _,
30459 };
30460 let cookie = self.send_void_request(request, true).with_span(span);
30461 cookie
30462 }
30463 #[cfg(feature = "shape")]
30464 fn shape_mask_checked<'this>(
30465 &'this mut self,
30466 operation: types::SO,
30467 destination_kind: types::SK,
30468 destination_window: types::xproto::Window,
30469 x_offset: types::Int16,
30470 y_offset: types::Int16,
30471 source_bitmap: impl Into<types::xproto::Pixmap>,
30472 ) -> futures::CheckedSendRequest<'this, Self, ()> {
30473 let request = types::shape::MaskRequest {
30474 operation,
30475 destination_kind,
30476 destination_window,
30477 x_offset,
30478 y_offset,
30479 source_bitmap: Into::<u32>::into(source_bitmap.into()) as _,
30480 };
30481 let cookie = self.send_void_request(request, false);
30482 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
30483 res
30484 }
30485 #[cfg(feature = "shape")]
30486 fn shape_combine<'this>(
30487 &'this mut self,
30488 operation: types::SO,
30489 destination_kind: types::SK,
30490 source_kind: types::SK,
30491 destination_window: types::xproto::Window,
30492 x_offset: types::Int16,
30493 y_offset: types::Int16,
30494 source_window: types::xproto::Window,
30495 ) -> futures::SendRequest<'this, Self, ()> {
30496 let span = tracing::info_span!(
30497 "shape_combine",
30498 operation = ?operation,
30499 destination_kind = ?destination_kind,
30500 source_kind = ?source_kind,
30501 destination_window = ?destination_window,
30502 x_offset = ?x_offset,
30503 y_offset = ?y_offset,
30504 source_window = ?source_window,
30505 );
30506 let request = types::shape::CombineRequest {
30507 operation,
30508 destination_kind,
30509 source_kind,
30510 destination_window,
30511 x_offset,
30512 y_offset,
30513 source_window,
30514 };
30515 let cookie = self.send_void_request(request, true).with_span(span);
30516 cookie
30517 }
30518 #[cfg(feature = "shape")]
30519 fn shape_combine_checked<'this>(
30520 &'this mut self,
30521 operation: types::SO,
30522 destination_kind: types::SK,
30523 source_kind: types::SK,
30524 destination_window: types::xproto::Window,
30525 x_offset: types::Int16,
30526 y_offset: types::Int16,
30527 source_window: types::xproto::Window,
30528 ) -> futures::CheckedSendRequest<'this, Self, ()> {
30529 let request = types::shape::CombineRequest {
30530 operation,
30531 destination_kind,
30532 source_kind,
30533 destination_window,
30534 x_offset,
30535 y_offset,
30536 source_window,
30537 };
30538 let cookie = self.send_void_request(request, false);
30539 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
30540 res
30541 }
30542 #[cfg(feature = "shape")]
30543 fn shape_offset<'this>(
30544 &'this mut self,
30545 destination_kind: types::SK,
30546 destination_window: types::xproto::Window,
30547 x_offset: types::Int16,
30548 y_offset: types::Int16,
30549 ) -> futures::SendRequest<'this, Self, ()> {
30550 let span = tracing::info_span!(
30551 "shape_offset",
30552 destination_kind = ?destination_kind,
30553 destination_window = ?destination_window,
30554 x_offset = ?x_offset,
30555 y_offset = ?y_offset,
30556 );
30557 let request = types::shape::OffsetRequest {
30558 destination_kind,
30559 destination_window,
30560 x_offset,
30561 y_offset,
30562 };
30563 let cookie = self.send_void_request(request, true).with_span(span);
30564 cookie
30565 }
30566 #[cfg(feature = "shape")]
30567 fn shape_offset_checked<'this>(
30568 &'this mut self,
30569 destination_kind: types::SK,
30570 destination_window: types::xproto::Window,
30571 x_offset: types::Int16,
30572 y_offset: types::Int16,
30573 ) -> futures::CheckedSendRequest<'this, Self, ()> {
30574 let request = types::shape::OffsetRequest {
30575 destination_kind,
30576 destination_window,
30577 x_offset,
30578 y_offset,
30579 };
30580 let cookie = self.send_void_request(request, false);
30581 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
30582 res
30583 }
30584 #[cfg(feature = "shape")]
30585 fn shape_query_extents<'this>(
30586 &'this mut self,
30587 destination_window: types::xproto::Window,
30588 ) -> futures::SendRequest<'this, Self, types::shape::QueryExtentsReply> {
30589 let span = tracing::info_span!(
30590 "shape_query_extents",
30591 destination_window = ?destination_window,
30592 );
30593 let request = types::shape::QueryExtentsRequest { destination_window };
30594 let cookie = self.send_reply_request(request).with_span(span);
30595 cookie
30596 }
30597 #[cfg(feature = "shape")]
30598 fn shape_query_extents_immediate<'this>(
30599 &'this mut self,
30600 destination_window: types::xproto::Window,
30601 ) -> futures::CheckedSendRequest<'this, Self, types::shape::QueryExtentsReply> {
30602 let request = types::shape::QueryExtentsRequest { destination_window };
30603 let cookie = self.send_reply_request(request);
30604 let res: futures::CheckedSendRequest<'this, Self, types::shape::QueryExtentsReply> =
30605 cookie.into();
30606 res
30607 }
30608 #[cfg(feature = "shape")]
30609 fn shape_select_input<'this>(
30610 &'this mut self,
30611 destination_window: types::xproto::Window,
30612 enable: types::Bool,
30613 ) -> futures::SendRequest<'this, Self, ()> {
30614 let span = tracing::info_span!(
30615 "shape_select_input",
30616 destination_window = ?destination_window,
30617 enable = ?enable,
30618 );
30619 let request = types::shape::SelectInputRequest {
30620 destination_window,
30621 enable,
30622 };
30623 let cookie = self.send_void_request(request, true).with_span(span);
30624 cookie
30625 }
30626 #[cfg(feature = "shape")]
30627 fn shape_select_input_checked<'this>(
30628 &'this mut self,
30629 destination_window: types::xproto::Window,
30630 enable: types::Bool,
30631 ) -> futures::CheckedSendRequest<'this, Self, ()> {
30632 let request = types::shape::SelectInputRequest {
30633 destination_window,
30634 enable,
30635 };
30636 let cookie = self.send_void_request(request, false);
30637 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
30638 res
30639 }
30640 #[cfg(feature = "shape")]
30641 fn shape_input_selected<'this>(
30642 &'this mut self,
30643 destination_window: types::xproto::Window,
30644 ) -> futures::SendRequest<'this, Self, types::shape::InputSelectedReply> {
30645 let span = tracing::info_span!(
30646 "shape_input_selected",
30647 destination_window = ?destination_window,
30648 );
30649 let request = types::shape::InputSelectedRequest { destination_window };
30650 let cookie = self.send_reply_request(request).with_span(span);
30651 cookie
30652 }
30653 #[cfg(feature = "shape")]
30654 fn shape_input_selected_immediate<'this>(
30655 &'this mut self,
30656 destination_window: types::xproto::Window,
30657 ) -> futures::CheckedSendRequest<'this, Self, types::shape::InputSelectedReply> {
30658 let request = types::shape::InputSelectedRequest { destination_window };
30659 let cookie = self.send_reply_request(request);
30660 let res: futures::CheckedSendRequest<'this, Self, types::shape::InputSelectedReply> =
30661 cookie.into();
30662 res
30663 }
30664 #[cfg(feature = "shape")]
30665 fn shape_get_rectangles<'this>(
30666 &'this mut self,
30667 window: types::xproto::Window,
30668 source_kind: types::SK,
30669 ) -> futures::SendRequest<'this, Self, types::shape::GetRectanglesReply> {
30670 let span = tracing::info_span!(
30671 "shape_get_rectangles",
30672 window = ?window,
30673 source_kind = ?source_kind,
30674 );
30675 let request = types::shape::GetRectanglesRequest {
30676 window,
30677 source_kind,
30678 };
30679 let cookie = self.send_reply_request(request).with_span(span);
30680 cookie
30681 }
30682 #[cfg(feature = "shape")]
30683 fn shape_get_rectangles_immediate<'this>(
30684 &'this mut self,
30685 window: types::xproto::Window,
30686 source_kind: types::SK,
30687 ) -> futures::CheckedSendRequest<'this, Self, types::shape::GetRectanglesReply> {
30688 let request = types::shape::GetRectanglesRequest {
30689 window,
30690 source_kind,
30691 };
30692 let cookie = self.send_reply_request(request);
30693 let res: futures::CheckedSendRequest<'this, Self, types::shape::GetRectanglesReply> =
30694 cookie.into();
30695 res
30696 }
30697
30698 #[cfg(feature = "shm")]
30699 fn shm_query_version<'this>(
30700 &'this mut self,
30701 ) -> futures::SendRequest<'this, Self, types::shm::QueryVersionReply> {
30702 let span = tracing::info_span!("shm_query_version",);
30703 let request = types::shm::QueryVersionRequest {};
30704 let cookie = self.send_reply_request(request).with_span(span);
30705 cookie
30706 }
30707 #[cfg(feature = "shm")]
30708 fn shm_query_version_immediate<'this>(
30709 &'this mut self,
30710 ) -> futures::CheckedSendRequest<'this, Self, types::shm::QueryVersionReply> {
30711 let request = types::shm::QueryVersionRequest {};
30712 let cookie = self.send_reply_request(request);
30713 let res: futures::CheckedSendRequest<'this, Self, types::shm::QueryVersionReply> =
30714 cookie.into();
30715 res
30716 }
30717 #[cfg(feature = "shm")]
30718 fn shm_attach<'this>(
30719 &'this mut self,
30720 shmseg: types::Seg,
30721 shmid: types::Card32,
30722 read_only: types::Bool,
30723 ) -> futures::SendRequest<'this, Self, ()> {
30724 let span = tracing::info_span!(
30725 "shm_attach",
30726 shmseg = ?shmseg,
30727 shmid = ?shmid,
30728 read_only = ?read_only,
30729 );
30730 let request = types::shm::AttachRequest {
30731 shmseg,
30732 shmid,
30733 read_only,
30734 };
30735 let cookie = self.send_void_request(request, true).with_span(span);
30736 cookie
30737 }
30738 #[cfg(feature = "shm")]
30739 fn shm_attach_checked<'this>(
30740 &'this mut self,
30741 shmseg: types::Seg,
30742 shmid: types::Card32,
30743 read_only: types::Bool,
30744 ) -> futures::CheckedSendRequest<'this, Self, ()> {
30745 let request = types::shm::AttachRequest {
30746 shmseg,
30747 shmid,
30748 read_only,
30749 };
30750 let cookie = self.send_void_request(request, false);
30751 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
30752 res
30753 }
30754 #[cfg(feature = "shm")]
30755 fn shm_detach<'this>(
30756 &'this mut self,
30757 shmseg: types::Seg,
30758 ) -> futures::SendRequest<'this, Self, ()> {
30759 let span = tracing::info_span!(
30760 "shm_detach",
30761 shmseg = ?shmseg,
30762 );
30763 let request = types::shm::DetachRequest { shmseg };
30764 let cookie = self.send_void_request(request, true).with_span(span);
30765 cookie
30766 }
30767 #[cfg(feature = "shm")]
30768 fn shm_detach_checked<'this>(
30769 &'this mut self,
30770 shmseg: types::Seg,
30771 ) -> futures::CheckedSendRequest<'this, Self, ()> {
30772 let request = types::shm::DetachRequest { shmseg };
30773 let cookie = self.send_void_request(request, false);
30774 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
30775 res
30776 }
30777 #[cfg(feature = "shm")]
30778 fn shm_put_image<'this>(
30779 &'this mut self,
30780 drawable: types::xproto::Drawable,
30781 gc: types::Gcontext,
30782 total_width: types::Card16,
30783 total_height: types::Card16,
30784 src_x: types::Card16,
30785 src_y: types::Card16,
30786 src_width: types::Card16,
30787 src_height: types::Card16,
30788 dst_x: types::Int16,
30789 dst_y: types::Int16,
30790 depth: types::Card8,
30791 format: types::Card8,
30792 send_event: types::Bool,
30793 shmseg: types::Seg,
30794 offset: types::Card32,
30795 ) -> futures::SendRequest<'this, Self, ()> {
30796 let span = tracing::info_span!(
30797 "shm_put_image",
30798 drawable = ?drawable,
30799 gc = ?gc,
30800 total_width = ?total_width,
30801 total_height = ?total_height,
30802 src_x = ?src_x,
30803 src_y = ?src_y,
30804 src_width = ?src_width,
30805 src_height = ?src_height,
30806 dst_x = ?dst_x,
30807 dst_y = ?dst_y,
30808 depth = ?depth,
30809 format = ?format,
30810 send_event = ?send_event,
30811 shmseg = ?shmseg,
30812 offset = ?offset,
30813 );
30814 let request = types::shm::PutImageRequest {
30815 drawable,
30816 gc,
30817 total_width,
30818 total_height,
30819 src_x,
30820 src_y,
30821 src_width,
30822 src_height,
30823 dst_x,
30824 dst_y,
30825 depth,
30826 format,
30827 send_event,
30828 shmseg,
30829 offset,
30830 };
30831 let cookie = self.send_void_request(request, true).with_span(span);
30832 cookie
30833 }
30834 #[cfg(feature = "shm")]
30835 fn shm_put_image_checked<'this>(
30836 &'this mut self,
30837 drawable: types::xproto::Drawable,
30838 gc: types::Gcontext,
30839 total_width: types::Card16,
30840 total_height: types::Card16,
30841 src_x: types::Card16,
30842 src_y: types::Card16,
30843 src_width: types::Card16,
30844 src_height: types::Card16,
30845 dst_x: types::Int16,
30846 dst_y: types::Int16,
30847 depth: types::Card8,
30848 format: types::Card8,
30849 send_event: types::Bool,
30850 shmseg: types::Seg,
30851 offset: types::Card32,
30852 ) -> futures::CheckedSendRequest<'this, Self, ()> {
30853 let request = types::shm::PutImageRequest {
30854 drawable,
30855 gc,
30856 total_width,
30857 total_height,
30858 src_x,
30859 src_y,
30860 src_width,
30861 src_height,
30862 dst_x,
30863 dst_y,
30864 depth,
30865 format,
30866 send_event,
30867 shmseg,
30868 offset,
30869 };
30870 let cookie = self.send_void_request(request, false);
30871 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
30872 res
30873 }
30874 #[cfg(feature = "shm")]
30875 fn shm_get_image<'this>(
30876 &'this mut self,
30877 drawable: types::xproto::Drawable,
30878 x: types::Int16,
30879 y: types::Int16,
30880 width: types::Card16,
30881 height: types::Card16,
30882 plane_mask: types::Card32,
30883 format: types::Card8,
30884 shmseg: types::Seg,
30885 offset: types::Card32,
30886 ) -> futures::SendRequest<'this, Self, types::shm::GetImageReply> {
30887 let span = tracing::info_span!(
30888 "shm_get_image",
30889 drawable = ?drawable,
30890 x = ?x,
30891 y = ?y,
30892 width = ?width,
30893 height = ?height,
30894 plane_mask = ?plane_mask,
30895 format = ?format,
30896 shmseg = ?shmseg,
30897 offset = ?offset,
30898 );
30899 let request = types::shm::GetImageRequest {
30900 drawable,
30901 x,
30902 y,
30903 width,
30904 height,
30905 plane_mask,
30906 format,
30907 shmseg,
30908 offset,
30909 };
30910 let cookie = self.send_reply_request(request).with_span(span);
30911 cookie
30912 }
30913 #[cfg(feature = "shm")]
30914 fn shm_get_image_immediate<'this>(
30915 &'this mut self,
30916 drawable: types::xproto::Drawable,
30917 x: types::Int16,
30918 y: types::Int16,
30919 width: types::Card16,
30920 height: types::Card16,
30921 plane_mask: types::Card32,
30922 format: types::Card8,
30923 shmseg: types::Seg,
30924 offset: types::Card32,
30925 ) -> futures::CheckedSendRequest<'this, Self, types::shm::GetImageReply> {
30926 let request = types::shm::GetImageRequest {
30927 drawable,
30928 x,
30929 y,
30930 width,
30931 height,
30932 plane_mask,
30933 format,
30934 shmseg,
30935 offset,
30936 };
30937 let cookie = self.send_reply_request(request);
30938 let res: futures::CheckedSendRequest<'this, Self, types::shm::GetImageReply> =
30939 cookie.into();
30940 res
30941 }
30942 #[cfg(feature = "shm")]
30943 fn shm_create_pixmap<'this>(
30944 &'this mut self,
30945 pid: types::xproto::Pixmap,
30946 drawable: types::xproto::Drawable,
30947 width: types::Card16,
30948 height: types::Card16,
30949 depth: types::Card8,
30950 shmseg: types::Seg,
30951 offset: types::Card32,
30952 ) -> futures::SendRequest<'this, Self, ()> {
30953 let span = tracing::info_span!(
30954 "shm_create_pixmap",
30955 pid = ?pid,
30956 drawable = ?drawable,
30957 width = ?width,
30958 height = ?height,
30959 depth = ?depth,
30960 shmseg = ?shmseg,
30961 offset = ?offset,
30962 );
30963 let request = types::shm::CreatePixmapRequest {
30964 pid,
30965 drawable,
30966 width,
30967 height,
30968 depth,
30969 shmseg,
30970 offset,
30971 };
30972 let cookie = self.send_void_request(request, true).with_span(span);
30973 cookie
30974 }
30975 #[cfg(feature = "shm")]
30976 fn shm_create_pixmap_checked<'this>(
30977 &'this mut self,
30978 pid: types::xproto::Pixmap,
30979 drawable: types::xproto::Drawable,
30980 width: types::Card16,
30981 height: types::Card16,
30982 depth: types::Card8,
30983 shmseg: types::Seg,
30984 offset: types::Card32,
30985 ) -> futures::CheckedSendRequest<'this, Self, ()> {
30986 let request = types::shm::CreatePixmapRequest {
30987 pid,
30988 drawable,
30989 width,
30990 height,
30991 depth,
30992 shmseg,
30993 offset,
30994 };
30995 let cookie = self.send_void_request(request, false);
30996 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
30997 res
30998 }
30999 #[cfg(feature = "shm")]
31000 fn shm_attach_fd<'this>(
31001 &'this mut self,
31002 shmseg: types::Seg,
31003 shm_fd: types::Fd,
31004 read_only: types::Bool,
31005 ) -> futures::SendRequest<'this, Self, ()> {
31006 let span = tracing::info_span!(
31007 "shm_attach_fd",
31008 shmseg = ?shmseg,
31009 shm_fd = ?shm_fd,
31010 read_only = ?read_only,
31011 );
31012 let request = types::shm::AttachFdRequest {
31013 shmseg,
31014 shm_fd,
31015 read_only,
31016 };
31017 let cookie = self.send_void_request(request, true).with_span(span);
31018 cookie
31019 }
31020 #[cfg(feature = "shm")]
31021 fn shm_attach_fd_checked<'this>(
31022 &'this mut self,
31023 shmseg: types::Seg,
31024 shm_fd: types::Fd,
31025 read_only: types::Bool,
31026 ) -> futures::CheckedSendRequest<'this, Self, ()> {
31027 let request = types::shm::AttachFdRequest {
31028 shmseg,
31029 shm_fd,
31030 read_only,
31031 };
31032 let cookie = self.send_void_request(request, false);
31033 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
31034 res
31035 }
31036 #[cfg(feature = "shm")]
31037 fn shm_create_segment<'this>(
31038 &'this mut self,
31039 shmseg: types::Seg,
31040 size: types::Card32,
31041 read_only: types::Bool,
31042 ) -> futures::SendRequest<'this, Self, types::shm::CreateSegmentReply> {
31043 let span = tracing::info_span!(
31044 "shm_create_segment",
31045 shmseg = ?shmseg,
31046 size = ?size,
31047 read_only = ?read_only,
31048 );
31049 let request = types::shm::CreateSegmentRequest {
31050 shmseg,
31051 size,
31052 read_only,
31053 };
31054 let cookie = self.send_reply_fd_request(request).with_span(span);
31055 cookie
31056 }
31057 #[cfg(feature = "shm")]
31058 fn shm_create_segment_immediate<'this>(
31059 &'this mut self,
31060 shmseg: types::Seg,
31061 size: types::Card32,
31062 read_only: types::Bool,
31063 ) -> futures::CheckedSendRequest<'this, Self, types::shm::CreateSegmentReply> {
31064 let request = types::shm::CreateSegmentRequest {
31065 shmseg,
31066 size,
31067 read_only,
31068 };
31069 let cookie = self.send_reply_fd_request(request);
31070 let res: futures::CheckedSendRequest<'this, Self, types::shm::CreateSegmentReply> =
31071 cookie.into();
31072 res
31073 }
31074
31075 #[cfg(feature = "sync")]
31076 fn sync_initialize<'this>(
31077 &'this mut self,
31078 desired_major_version: types::Card8,
31079 desired_minor_version: types::Card8,
31080 ) -> futures::SendRequest<'this, Self, types::sync::InitializeReply> {
31081 let span = tracing::info_span!(
31082 "sync_initialize",
31083 desired_major_version = ?desired_major_version,
31084 desired_minor_version = ?desired_minor_version,
31085 );
31086 let request = types::sync::InitializeRequest {
31087 desired_major_version,
31088 desired_minor_version,
31089 };
31090 let cookie = self.send_reply_request(request).with_span(span);
31091 cookie
31092 }
31093 #[cfg(feature = "sync")]
31094 fn sync_initialize_immediate<'this>(
31095 &'this mut self,
31096 desired_major_version: types::Card8,
31097 desired_minor_version: types::Card8,
31098 ) -> futures::CheckedSendRequest<'this, Self, types::sync::InitializeReply> {
31099 let request = types::sync::InitializeRequest {
31100 desired_major_version,
31101 desired_minor_version,
31102 };
31103 let cookie = self.send_reply_request(request);
31104 let res: futures::CheckedSendRequest<'this, Self, types::sync::InitializeReply> =
31105 cookie.into();
31106 res
31107 }
31108 #[cfg(feature = "sync")]
31109 fn sync_list_system_counters<'this>(
31110 &'this mut self,
31111 ) -> futures::SendRequest<'this, Self, types::sync::ListSystemCountersReply> {
31112 let span = tracing::info_span!("sync_list_system_counters",);
31113 let request = types::sync::ListSystemCountersRequest {};
31114 let cookie = self.send_reply_request(request).with_span(span);
31115 cookie
31116 }
31117 #[cfg(feature = "sync")]
31118 fn sync_list_system_counters_immediate<'this>(
31119 &'this mut self,
31120 ) -> futures::CheckedSendRequest<'this, Self, types::sync::ListSystemCountersReply> {
31121 let request = types::sync::ListSystemCountersRequest {};
31122 let cookie = self.send_reply_request(request);
31123 let res: futures::CheckedSendRequest<'this, Self, types::sync::ListSystemCountersReply> =
31124 cookie.into();
31125 res
31126 }
31127 #[cfg(feature = "sync")]
31128 fn sync_create_counter<'this>(
31129 &'this mut self,
31130 id: types::Counter,
31131 initial_value: types::sync::Int64,
31132 ) -> futures::SendRequest<'this, Self, ()> {
31133 let span = tracing::info_span!(
31134 "sync_create_counter",
31135 id = ?id,
31136 initial_value = ?initial_value,
31137 );
31138 let request = types::sync::CreateCounterRequest { id, initial_value };
31139 let cookie = self.send_void_request(request, true).with_span(span);
31140 cookie
31141 }
31142 #[cfg(feature = "sync")]
31143 fn sync_create_counter_checked<'this>(
31144 &'this mut self,
31145 id: types::Counter,
31146 initial_value: types::sync::Int64,
31147 ) -> futures::CheckedSendRequest<'this, Self, ()> {
31148 let request = types::sync::CreateCounterRequest { id, initial_value };
31149 let cookie = self.send_void_request(request, false);
31150 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
31151 res
31152 }
31153 #[cfg(feature = "sync")]
31154 fn sync_destroy_counter<'this>(
31155 &'this mut self,
31156 counter: types::Counter,
31157 ) -> futures::SendRequest<'this, Self, ()> {
31158 let span = tracing::info_span!(
31159 "sync_destroy_counter",
31160 counter = ?counter,
31161 );
31162 let request = types::sync::DestroyCounterRequest { counter };
31163 let cookie = self.send_void_request(request, true).with_span(span);
31164 cookie
31165 }
31166 #[cfg(feature = "sync")]
31167 fn sync_destroy_counter_checked<'this>(
31168 &'this mut self,
31169 counter: types::Counter,
31170 ) -> futures::CheckedSendRequest<'this, Self, ()> {
31171 let request = types::sync::DestroyCounterRequest { counter };
31172 let cookie = self.send_void_request(request, false);
31173 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
31174 res
31175 }
31176 #[cfg(feature = "sync")]
31177 fn sync_query_counter<'this>(
31178 &'this mut self,
31179 counter: types::Counter,
31180 ) -> futures::SendRequest<'this, Self, types::sync::QueryCounterReply> {
31181 let span = tracing::info_span!(
31182 "sync_query_counter",
31183 counter = ?counter,
31184 );
31185 let request = types::sync::QueryCounterRequest { counter };
31186 let cookie = self.send_reply_request(request).with_span(span);
31187 cookie
31188 }
31189 #[cfg(feature = "sync")]
31190 fn sync_query_counter_immediate<'this>(
31191 &'this mut self,
31192 counter: types::Counter,
31193 ) -> futures::CheckedSendRequest<'this, Self, types::sync::QueryCounterReply> {
31194 let request = types::sync::QueryCounterRequest { counter };
31195 let cookie = self.send_reply_request(request);
31196 let res: futures::CheckedSendRequest<'this, Self, types::sync::QueryCounterReply> =
31197 cookie.into();
31198 res
31199 }
31200 #[cfg(feature = "sync")]
31201 fn sync_await<'this>(
31202 &'this mut self,
31203 wait_list: impl AsRef<[types::Waitcondition]>,
31204 ) -> futures::SendRequest<'this, Self, ()> {
31205 let span = tracing::info_span!("sync_await",);
31206 let request = types::sync::AwaitRequest {
31207 wait_list: Cow::Borrowed(wait_list.as_ref()),
31208 };
31209 let cookie = self.send_void_request(request, true).with_span(span);
31210 cookie
31211 }
31212 #[cfg(feature = "sync")]
31213 fn sync_await_checked<'this>(
31214 &'this mut self,
31215 wait_list: impl AsRef<[types::Waitcondition]>,
31216 ) -> futures::CheckedSendRequest<'this, Self, ()> {
31217 let request = types::sync::AwaitRequest {
31218 wait_list: Cow::Borrowed(wait_list.as_ref()),
31219 };
31220 let cookie = self.send_void_request(request, false);
31221 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
31222 res
31223 }
31224 #[cfg(feature = "sync")]
31225 fn sync_change_counter<'this>(
31226 &'this mut self,
31227 counter: types::Counter,
31228 amount: types::sync::Int64,
31229 ) -> futures::SendRequest<'this, Self, ()> {
31230 let span = tracing::info_span!(
31231 "sync_change_counter",
31232 counter = ?counter,
31233 amount = ?amount,
31234 );
31235 let request = types::sync::ChangeCounterRequest { counter, amount };
31236 let cookie = self.send_void_request(request, true).with_span(span);
31237 cookie
31238 }
31239 #[cfg(feature = "sync")]
31240 fn sync_change_counter_checked<'this>(
31241 &'this mut self,
31242 counter: types::Counter,
31243 amount: types::sync::Int64,
31244 ) -> futures::CheckedSendRequest<'this, Self, ()> {
31245 let request = types::sync::ChangeCounterRequest { counter, amount };
31246 let cookie = self.send_void_request(request, false);
31247 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
31248 res
31249 }
31250 #[cfg(feature = "sync")]
31251 fn sync_set_counter<'this>(
31252 &'this mut self,
31253 counter: types::Counter,
31254 value: types::sync::Int64,
31255 ) -> futures::SendRequest<'this, Self, ()> {
31256 let span = tracing::info_span!(
31257 "sync_set_counter",
31258 counter = ?counter,
31259 value = ?value,
31260 );
31261 let request = types::sync::SetCounterRequest { counter, value };
31262 let cookie = self.send_void_request(request, true).with_span(span);
31263 cookie
31264 }
31265 #[cfg(feature = "sync")]
31266 fn sync_set_counter_checked<'this>(
31267 &'this mut self,
31268 counter: types::Counter,
31269 value: types::sync::Int64,
31270 ) -> futures::CheckedSendRequest<'this, Self, ()> {
31271 let request = types::sync::SetCounterRequest { counter, value };
31272 let cookie = self.send_void_request(request, false);
31273 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
31274 res
31275 }
31276 #[cfg(feature = "sync")]
31277 fn sync_create_alarm<'this>(
31278 &'this mut self,
31279 id: types::Alarm,
31280 value_list: impl Borrow<types::sync::CreateAlarmAux>,
31281 ) -> futures::SendRequest<'this, Self, ()> {
31282 let span = tracing::info_span!(
31283 "sync_create_alarm",
31284 id = ?id,
31285 );
31286 let request = types::sync::CreateAlarmRequest {
31287 id,
31288 value_list: Cow::Borrowed(value_list.borrow()),
31289 };
31290 let cookie = self.send_void_request(request, true).with_span(span);
31291 cookie
31292 }
31293 #[cfg(feature = "sync")]
31294 fn sync_create_alarm_checked<'this>(
31295 &'this mut self,
31296 id: types::Alarm,
31297 value_list: impl Borrow<types::sync::CreateAlarmAux>,
31298 ) -> futures::CheckedSendRequest<'this, Self, ()> {
31299 let request = types::sync::CreateAlarmRequest {
31300 id,
31301 value_list: Cow::Borrowed(value_list.borrow()),
31302 };
31303 let cookie = self.send_void_request(request, false);
31304 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
31305 res
31306 }
31307 #[cfg(feature = "sync")]
31308 fn sync_change_alarm<'this>(
31309 &'this mut self,
31310 id: types::Alarm,
31311 value_list: impl Borrow<types::sync::ChangeAlarmAux>,
31312 ) -> futures::SendRequest<'this, Self, ()> {
31313 let span = tracing::info_span!(
31314 "sync_change_alarm",
31315 id = ?id,
31316 );
31317 let request = types::sync::ChangeAlarmRequest {
31318 id,
31319 value_list: Cow::Borrowed(value_list.borrow()),
31320 };
31321 let cookie = self.send_void_request(request, true).with_span(span);
31322 cookie
31323 }
31324 #[cfg(feature = "sync")]
31325 fn sync_change_alarm_checked<'this>(
31326 &'this mut self,
31327 id: types::Alarm,
31328 value_list: impl Borrow<types::sync::ChangeAlarmAux>,
31329 ) -> futures::CheckedSendRequest<'this, Self, ()> {
31330 let request = types::sync::ChangeAlarmRequest {
31331 id,
31332 value_list: Cow::Borrowed(value_list.borrow()),
31333 };
31334 let cookie = self.send_void_request(request, false);
31335 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
31336 res
31337 }
31338 #[cfg(feature = "sync")]
31339 fn sync_destroy_alarm<'this>(
31340 &'this mut self,
31341 alarm: types::Alarm,
31342 ) -> futures::SendRequest<'this, Self, ()> {
31343 let span = tracing::info_span!(
31344 "sync_destroy_alarm",
31345 alarm = ?alarm,
31346 );
31347 let request = types::sync::DestroyAlarmRequest { alarm };
31348 let cookie = self.send_void_request(request, true).with_span(span);
31349 cookie
31350 }
31351 #[cfg(feature = "sync")]
31352 fn sync_destroy_alarm_checked<'this>(
31353 &'this mut self,
31354 alarm: types::Alarm,
31355 ) -> futures::CheckedSendRequest<'this, Self, ()> {
31356 let request = types::sync::DestroyAlarmRequest { alarm };
31357 let cookie = self.send_void_request(request, false);
31358 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
31359 res
31360 }
31361 #[cfg(feature = "sync")]
31362 fn sync_query_alarm<'this>(
31363 &'this mut self,
31364 alarm: types::Alarm,
31365 ) -> futures::SendRequest<'this, Self, types::sync::QueryAlarmReply> {
31366 let span = tracing::info_span!(
31367 "sync_query_alarm",
31368 alarm = ?alarm,
31369 );
31370 let request = types::sync::QueryAlarmRequest { alarm };
31371 let cookie = self.send_reply_request(request).with_span(span);
31372 cookie
31373 }
31374 #[cfg(feature = "sync")]
31375 fn sync_query_alarm_immediate<'this>(
31376 &'this mut self,
31377 alarm: types::Alarm,
31378 ) -> futures::CheckedSendRequest<'this, Self, types::sync::QueryAlarmReply> {
31379 let request = types::sync::QueryAlarmRequest { alarm };
31380 let cookie = self.send_reply_request(request);
31381 let res: futures::CheckedSendRequest<'this, Self, types::sync::QueryAlarmReply> =
31382 cookie.into();
31383 res
31384 }
31385 #[cfg(feature = "sync")]
31386 fn sync_set_priority<'this>(
31387 &'this mut self,
31388 id: types::Card32,
31389 priority: types::Int32,
31390 ) -> futures::SendRequest<'this, Self, ()> {
31391 let span = tracing::info_span!(
31392 "sync_set_priority",
31393 id = ?id,
31394 priority = ?priority,
31395 );
31396 let request = types::sync::SetPriorityRequest { id, priority };
31397 let cookie = self.send_void_request(request, true).with_span(span);
31398 cookie
31399 }
31400 #[cfg(feature = "sync")]
31401 fn sync_set_priority_checked<'this>(
31402 &'this mut self,
31403 id: types::Card32,
31404 priority: types::Int32,
31405 ) -> futures::CheckedSendRequest<'this, Self, ()> {
31406 let request = types::sync::SetPriorityRequest { id, priority };
31407 let cookie = self.send_void_request(request, false);
31408 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
31409 res
31410 }
31411 #[cfg(feature = "sync")]
31412 fn sync_get_priority<'this>(
31413 &'this mut self,
31414 id: types::Card32,
31415 ) -> futures::SendRequest<'this, Self, types::sync::GetPriorityReply> {
31416 let span = tracing::info_span!(
31417 "sync_get_priority",
31418 id = ?id,
31419 );
31420 let request = types::sync::GetPriorityRequest { id };
31421 let cookie = self.send_reply_request(request).with_span(span);
31422 cookie
31423 }
31424 #[cfg(feature = "sync")]
31425 fn sync_get_priority_immediate<'this>(
31426 &'this mut self,
31427 id: types::Card32,
31428 ) -> futures::CheckedSendRequest<'this, Self, types::sync::GetPriorityReply> {
31429 let request = types::sync::GetPriorityRequest { id };
31430 let cookie = self.send_reply_request(request);
31431 let res: futures::CheckedSendRequest<'this, Self, types::sync::GetPriorityReply> =
31432 cookie.into();
31433 res
31434 }
31435 #[cfg(feature = "sync")]
31436 fn sync_create_fence<'this>(
31437 &'this mut self,
31438 drawable: types::xproto::Drawable,
31439 fence: types::Fence,
31440 initially_triggered: types::Bool,
31441 ) -> futures::SendRequest<'this, Self, ()> {
31442 let span = tracing::info_span!(
31443 "sync_create_fence",
31444 drawable = ?drawable,
31445 fence = ?fence,
31446 initially_triggered = ?initially_triggered,
31447 );
31448 let request = types::sync::CreateFenceRequest {
31449 drawable,
31450 fence,
31451 initially_triggered,
31452 };
31453 let cookie = self.send_void_request(request, true).with_span(span);
31454 cookie
31455 }
31456 #[cfg(feature = "sync")]
31457 fn sync_create_fence_checked<'this>(
31458 &'this mut self,
31459 drawable: types::xproto::Drawable,
31460 fence: types::Fence,
31461 initially_triggered: types::Bool,
31462 ) -> futures::CheckedSendRequest<'this, Self, ()> {
31463 let request = types::sync::CreateFenceRequest {
31464 drawable,
31465 fence,
31466 initially_triggered,
31467 };
31468 let cookie = self.send_void_request(request, false);
31469 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
31470 res
31471 }
31472 #[cfg(feature = "sync")]
31473 fn sync_trigger_fence<'this>(
31474 &'this mut self,
31475 fence: types::Fence,
31476 ) -> futures::SendRequest<'this, Self, ()> {
31477 let span = tracing::info_span!(
31478 "sync_trigger_fence",
31479 fence = ?fence,
31480 );
31481 let request = types::sync::TriggerFenceRequest { fence };
31482 let cookie = self.send_void_request(request, true).with_span(span);
31483 cookie
31484 }
31485 #[cfg(feature = "sync")]
31486 fn sync_trigger_fence_checked<'this>(
31487 &'this mut self,
31488 fence: types::Fence,
31489 ) -> futures::CheckedSendRequest<'this, Self, ()> {
31490 let request = types::sync::TriggerFenceRequest { fence };
31491 let cookie = self.send_void_request(request, false);
31492 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
31493 res
31494 }
31495 #[cfg(feature = "sync")]
31496 fn sync_reset_fence<'this>(
31497 &'this mut self,
31498 fence: types::Fence,
31499 ) -> futures::SendRequest<'this, Self, ()> {
31500 let span = tracing::info_span!(
31501 "sync_reset_fence",
31502 fence = ?fence,
31503 );
31504 let request = types::sync::ResetFenceRequest { fence };
31505 let cookie = self.send_void_request(request, true).with_span(span);
31506 cookie
31507 }
31508 #[cfg(feature = "sync")]
31509 fn sync_reset_fence_checked<'this>(
31510 &'this mut self,
31511 fence: types::Fence,
31512 ) -> futures::CheckedSendRequest<'this, Self, ()> {
31513 let request = types::sync::ResetFenceRequest { fence };
31514 let cookie = self.send_void_request(request, false);
31515 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
31516 res
31517 }
31518 #[cfg(feature = "sync")]
31519 fn sync_destroy_fence<'this>(
31520 &'this mut self,
31521 fence: types::Fence,
31522 ) -> futures::SendRequest<'this, Self, ()> {
31523 let span = tracing::info_span!(
31524 "sync_destroy_fence",
31525 fence = ?fence,
31526 );
31527 let request = types::sync::DestroyFenceRequest { fence };
31528 let cookie = self.send_void_request(request, true).with_span(span);
31529 cookie
31530 }
31531 #[cfg(feature = "sync")]
31532 fn sync_destroy_fence_checked<'this>(
31533 &'this mut self,
31534 fence: types::Fence,
31535 ) -> futures::CheckedSendRequest<'this, Self, ()> {
31536 let request = types::sync::DestroyFenceRequest { fence };
31537 let cookie = self.send_void_request(request, false);
31538 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
31539 res
31540 }
31541 #[cfg(feature = "sync")]
31542 fn sync_query_fence<'this>(
31543 &'this mut self,
31544 fence: types::Fence,
31545 ) -> futures::SendRequest<'this, Self, types::sync::QueryFenceReply> {
31546 let span = tracing::info_span!(
31547 "sync_query_fence",
31548 fence = ?fence,
31549 );
31550 let request = types::sync::QueryFenceRequest { fence };
31551 let cookie = self.send_reply_request(request).with_span(span);
31552 cookie
31553 }
31554 #[cfg(feature = "sync")]
31555 fn sync_query_fence_immediate<'this>(
31556 &'this mut self,
31557 fence: types::Fence,
31558 ) -> futures::CheckedSendRequest<'this, Self, types::sync::QueryFenceReply> {
31559 let request = types::sync::QueryFenceRequest { fence };
31560 let cookie = self.send_reply_request(request);
31561 let res: futures::CheckedSendRequest<'this, Self, types::sync::QueryFenceReply> =
31562 cookie.into();
31563 res
31564 }
31565 #[cfg(feature = "sync")]
31566 fn sync_await_fence<'this>(
31567 &'this mut self,
31568 fence_list: impl AsRef<[types::Fence]>,
31569 ) -> futures::SendRequest<'this, Self, ()> {
31570 let span = tracing::info_span!("sync_await_fence",);
31571 let request = types::sync::AwaitFenceRequest {
31572 fence_list: Cow::Borrowed(fence_list.as_ref()),
31573 };
31574 let cookie = self.send_void_request(request, true).with_span(span);
31575 cookie
31576 }
31577 #[cfg(feature = "sync")]
31578 fn sync_await_fence_checked<'this>(
31579 &'this mut self,
31580 fence_list: impl AsRef<[types::Fence]>,
31581 ) -> futures::CheckedSendRequest<'this, Self, ()> {
31582 let request = types::sync::AwaitFenceRequest {
31583 fence_list: Cow::Borrowed(fence_list.as_ref()),
31584 };
31585 let cookie = self.send_void_request(request, false);
31586 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
31587 res
31588 }
31589
31590 fn xc_misc_get_version<'this>(
31591 &'this mut self,
31592 client_major_version: types::Card16,
31593 client_minor_version: types::Card16,
31594 ) -> futures::SendRequest<'this, Self, types::xc_misc::GetVersionReply> {
31595 let span = tracing::info_span!(
31596 "xc_misc_get_version",
31597 client_major_version = ?client_major_version,
31598 client_minor_version = ?client_minor_version,
31599 );
31600 let request = types::xc_misc::GetVersionRequest {
31601 client_major_version,
31602 client_minor_version,
31603 };
31604 let cookie = self.send_reply_request(request).with_span(span);
31605 cookie
31606 }
31607 fn xc_misc_get_version_immediate<'this>(
31608 &'this mut self,
31609 client_major_version: types::Card16,
31610 client_minor_version: types::Card16,
31611 ) -> futures::CheckedSendRequest<'this, Self, types::xc_misc::GetVersionReply> {
31612 let request = types::xc_misc::GetVersionRequest {
31613 client_major_version,
31614 client_minor_version,
31615 };
31616 let cookie = self.send_reply_request(request);
31617 let res: futures::CheckedSendRequest<'this, Self, types::xc_misc::GetVersionReply> =
31618 cookie.into();
31619 res
31620 }
31621 fn xc_misc_get_xid_range<'this>(
31622 &'this mut self,
31623 ) -> futures::SendRequest<'this, Self, types::xc_misc::GetXIDRangeReply> {
31624 let span = tracing::info_span!("xc_misc_get_xid_range",);
31625 let request = types::xc_misc::GetXIDRangeRequest {};
31626 let cookie = self.send_reply_request(request).with_span(span);
31627 cookie
31628 }
31629 fn xc_misc_get_xid_range_immediate<'this>(
31630 &'this mut self,
31631 ) -> futures::CheckedSendRequest<'this, Self, types::xc_misc::GetXIDRangeReply> {
31632 let request = types::xc_misc::GetXIDRangeRequest {};
31633 let cookie = self.send_reply_request(request);
31634 let res: futures::CheckedSendRequest<'this, Self, types::xc_misc::GetXIDRangeReply> =
31635 cookie.into();
31636 res
31637 }
31638 fn xc_misc_get_xid_list<'this>(
31639 &'this mut self,
31640 count: types::Card32,
31641 ) -> futures::SendRequest<'this, Self, types::xc_misc::GetXIDListReply> {
31642 let span = tracing::info_span!(
31643 "xc_misc_get_xid_list",
31644 count = ?count,
31645 );
31646 let request = types::xc_misc::GetXIDListRequest { count };
31647 let cookie = self.send_reply_request(request).with_span(span);
31648 cookie
31649 }
31650 fn xc_misc_get_xid_list_immediate<'this>(
31651 &'this mut self,
31652 count: types::Card32,
31653 ) -> futures::CheckedSendRequest<'this, Self, types::xc_misc::GetXIDListReply> {
31654 let request = types::xc_misc::GetXIDListRequest { count };
31655 let cookie = self.send_reply_request(request);
31656 let res: futures::CheckedSendRequest<'this, Self, types::xc_misc::GetXIDListReply> =
31657 cookie.into();
31658 res
31659 }
31660
31661 #[cfg(feature = "xevie")]
31662 fn xevie_query_version<'this>(
31663 &'this mut self,
31664 client_major_version: types::Card16,
31665 client_minor_version: types::Card16,
31666 ) -> futures::SendRequest<'this, Self, types::xevie::QueryVersionReply> {
31667 let span = tracing::info_span!(
31668 "xevie_query_version",
31669 client_major_version = ?client_major_version,
31670 client_minor_version = ?client_minor_version,
31671 );
31672 let request = types::xevie::QueryVersionRequest {
31673 client_major_version,
31674 client_minor_version,
31675 };
31676 let cookie = self.send_reply_request(request).with_span(span);
31677 cookie
31678 }
31679 #[cfg(feature = "xevie")]
31680 fn xevie_query_version_immediate<'this>(
31681 &'this mut self,
31682 client_major_version: types::Card16,
31683 client_minor_version: types::Card16,
31684 ) -> futures::CheckedSendRequest<'this, Self, types::xevie::QueryVersionReply> {
31685 let request = types::xevie::QueryVersionRequest {
31686 client_major_version,
31687 client_minor_version,
31688 };
31689 let cookie = self.send_reply_request(request);
31690 let res: futures::CheckedSendRequest<'this, Self, types::xevie::QueryVersionReply> =
31691 cookie.into();
31692 res
31693 }
31694 #[cfg(feature = "xevie")]
31695 fn xevie_start<'this>(
31696 &'this mut self,
31697 screen: types::Card32,
31698 ) -> futures::SendRequest<'this, Self, types::xevie::StartReply> {
31699 let span = tracing::info_span!(
31700 "xevie_start",
31701 screen = ?screen,
31702 );
31703 let request = types::xevie::StartRequest { screen };
31704 let cookie = self.send_reply_request(request).with_span(span);
31705 cookie
31706 }
31707 #[cfg(feature = "xevie")]
31708 fn xevie_start_immediate<'this>(
31709 &'this mut self,
31710 screen: types::Card32,
31711 ) -> futures::CheckedSendRequest<'this, Self, types::xevie::StartReply> {
31712 let request = types::xevie::StartRequest { screen };
31713 let cookie = self.send_reply_request(request);
31714 let res: futures::CheckedSendRequest<'this, Self, types::xevie::StartReply> = cookie.into();
31715 res
31716 }
31717 #[cfg(feature = "xevie")]
31718 fn xevie_end<'this>(
31719 &'this mut self,
31720 cmap: types::Card32,
31721 ) -> futures::SendRequest<'this, Self, types::xevie::EndReply> {
31722 let span = tracing::info_span!(
31723 "xevie_end",
31724 cmap = ?cmap,
31725 );
31726 let request = types::xevie::EndRequest { cmap };
31727 let cookie = self.send_reply_request(request).with_span(span);
31728 cookie
31729 }
31730 #[cfg(feature = "xevie")]
31731 fn xevie_end_immediate<'this>(
31732 &'this mut self,
31733 cmap: types::Card32,
31734 ) -> futures::CheckedSendRequest<'this, Self, types::xevie::EndReply> {
31735 let request = types::xevie::EndRequest { cmap };
31736 let cookie = self.send_reply_request(request);
31737 let res: futures::CheckedSendRequest<'this, Self, types::xevie::EndReply> = cookie.into();
31738 res
31739 }
31740 #[cfg(feature = "xevie")]
31741 fn xevie_send<'this>(
31742 &'this mut self,
31743 event: types::xevie::Event,
31744 data_type: types::Card32,
31745 ) -> futures::SendRequest<'this, Self, types::xevie::SendReply> {
31746 let span = tracing::info_span!(
31747 "xevie_send",
31748 event = ?event,
31749 data_type = ?data_type,
31750 );
31751 let request = types::xevie::SendRequest { event, data_type };
31752 let cookie = self.send_reply_request(request).with_span(span);
31753 cookie
31754 }
31755 #[cfg(feature = "xevie")]
31756 fn xevie_send_immediate<'this>(
31757 &'this mut self,
31758 event: types::xevie::Event,
31759 data_type: types::Card32,
31760 ) -> futures::CheckedSendRequest<'this, Self, types::xevie::SendReply> {
31761 let request = types::xevie::SendRequest { event, data_type };
31762 let cookie = self.send_reply_request(request);
31763 let res: futures::CheckedSendRequest<'this, Self, types::xevie::SendReply> = cookie.into();
31764 res
31765 }
31766 #[cfg(feature = "xevie")]
31767 fn xevie_select_input<'this>(
31768 &'this mut self,
31769 event_mask: types::Card32,
31770 ) -> futures::SendRequest<'this, Self, types::xevie::SelectInputReply> {
31771 let span = tracing::info_span!(
31772 "xevie_select_input",
31773 event_mask = ?event_mask,
31774 );
31775 let request = types::xevie::SelectInputRequest { event_mask };
31776 let cookie = self.send_reply_request(request).with_span(span);
31777 cookie
31778 }
31779 #[cfg(feature = "xevie")]
31780 fn xevie_select_input_immediate<'this>(
31781 &'this mut self,
31782 event_mask: types::Card32,
31783 ) -> futures::CheckedSendRequest<'this, Self, types::xevie::SelectInputReply> {
31784 let request = types::xevie::SelectInputRequest { event_mask };
31785 let cookie = self.send_reply_request(request);
31786 let res: futures::CheckedSendRequest<'this, Self, types::xevie::SelectInputReply> =
31787 cookie.into();
31788 res
31789 }
31790
31791 #[cfg(feature = "xf86dri")]
31792 fn xf86dri_query_version<'this>(
31793 &'this mut self,
31794 ) -> futures::SendRequest<'this, Self, types::xf86dri::QueryVersionReply> {
31795 let span = tracing::info_span!("xf86dri_query_version",);
31796 let request = types::xf86dri::QueryVersionRequest {};
31797 let cookie = self.send_reply_request(request).with_span(span);
31798 cookie
31799 }
31800 #[cfg(feature = "xf86dri")]
31801 fn xf86dri_query_version_immediate<'this>(
31802 &'this mut self,
31803 ) -> futures::CheckedSendRequest<'this, Self, types::xf86dri::QueryVersionReply> {
31804 let request = types::xf86dri::QueryVersionRequest {};
31805 let cookie = self.send_reply_request(request);
31806 let res: futures::CheckedSendRequest<'this, Self, types::xf86dri::QueryVersionReply> =
31807 cookie.into();
31808 res
31809 }
31810 #[cfg(feature = "xf86dri")]
31811 fn xf86dri_query_direct_rendering_capable<'this>(
31812 &'this mut self,
31813 screen: types::Card32,
31814 ) -> futures::SendRequest<'this, Self, types::xf86dri::QueryDirectRenderingCapableReply> {
31815 let span = tracing::info_span!(
31816 "xf86dri_query_direct_rendering_capable",
31817 screen = ?screen,
31818 );
31819 let request = types::xf86dri::QueryDirectRenderingCapableRequest { screen };
31820 let cookie = self.send_reply_request(request).with_span(span);
31821 cookie
31822 }
31823 #[cfg(feature = "xf86dri")]
31824 fn xf86dri_query_direct_rendering_capable_immediate<'this>(
31825 &'this mut self,
31826 screen: types::Card32,
31827 ) -> futures::CheckedSendRequest<'this, Self, types::xf86dri::QueryDirectRenderingCapableReply>
31828 {
31829 let request = types::xf86dri::QueryDirectRenderingCapableRequest { screen };
31830 let cookie = self.send_reply_request(request);
31831 let res: futures::CheckedSendRequest<
31832 'this,
31833 Self,
31834 types::xf86dri::QueryDirectRenderingCapableReply,
31835 > = cookie.into();
31836 res
31837 }
31838 #[cfg(feature = "xf86dri")]
31839 fn xf86dri_open_connection<'this>(
31840 &'this mut self,
31841 screen: types::Card32,
31842 ) -> futures::SendRequest<'this, Self, types::xf86dri::OpenConnectionReply> {
31843 let span = tracing::info_span!(
31844 "xf86dri_open_connection",
31845 screen = ?screen,
31846 );
31847 let request = types::xf86dri::OpenConnectionRequest { screen };
31848 let cookie = self.send_reply_request(request).with_span(span);
31849 cookie
31850 }
31851 #[cfg(feature = "xf86dri")]
31852 fn xf86dri_open_connection_immediate<'this>(
31853 &'this mut self,
31854 screen: types::Card32,
31855 ) -> futures::CheckedSendRequest<'this, Self, types::xf86dri::OpenConnectionReply> {
31856 let request = types::xf86dri::OpenConnectionRequest { screen };
31857 let cookie = self.send_reply_request(request);
31858 let res: futures::CheckedSendRequest<'this, Self, types::xf86dri::OpenConnectionReply> =
31859 cookie.into();
31860 res
31861 }
31862 #[cfg(feature = "xf86dri")]
31863 fn xf86dri_close_connection<'this>(
31864 &'this mut self,
31865 screen: types::Card32,
31866 ) -> futures::SendRequest<'this, Self, ()> {
31867 let span = tracing::info_span!(
31868 "xf86dri_close_connection",
31869 screen = ?screen,
31870 );
31871 let request = types::xf86dri::CloseConnectionRequest { screen };
31872 let cookie = self.send_void_request(request, true).with_span(span);
31873 cookie
31874 }
31875 #[cfg(feature = "xf86dri")]
31876 fn xf86dri_close_connection_checked<'this>(
31877 &'this mut self,
31878 screen: types::Card32,
31879 ) -> futures::CheckedSendRequest<'this, Self, ()> {
31880 let request = types::xf86dri::CloseConnectionRequest { screen };
31881 let cookie = self.send_void_request(request, false);
31882 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
31883 res
31884 }
31885 #[cfg(feature = "xf86dri")]
31886 fn xf86dri_get_client_driver_name<'this>(
31887 &'this mut self,
31888 screen: types::Card32,
31889 ) -> futures::SendRequest<'this, Self, types::xf86dri::GetClientDriverNameReply> {
31890 let span = tracing::info_span!(
31891 "xf86dri_get_client_driver_name",
31892 screen = ?screen,
31893 );
31894 let request = types::xf86dri::GetClientDriverNameRequest { screen };
31895 let cookie = self.send_reply_request(request).with_span(span);
31896 cookie
31897 }
31898 #[cfg(feature = "xf86dri")]
31899 fn xf86dri_get_client_driver_name_immediate<'this>(
31900 &'this mut self,
31901 screen: types::Card32,
31902 ) -> futures::CheckedSendRequest<'this, Self, types::xf86dri::GetClientDriverNameReply> {
31903 let request = types::xf86dri::GetClientDriverNameRequest { screen };
31904 let cookie = self.send_reply_request(request);
31905 let res: futures::CheckedSendRequest<
31906 'this,
31907 Self,
31908 types::xf86dri::GetClientDriverNameReply,
31909 > = cookie.into();
31910 res
31911 }
31912 #[cfg(feature = "xf86dri")]
31913 fn xf86dri_create_context<'this>(
31914 &'this mut self,
31915 screen: types::Card32,
31916 visual: types::Card32,
31917 context: types::Card32,
31918 ) -> futures::SendRequest<'this, Self, types::xf86dri::CreateContextReply> {
31919 let span = tracing::info_span!(
31920 "xf86dri_create_context",
31921 screen = ?screen,
31922 visual = ?visual,
31923 context = ?context,
31924 );
31925 let request = types::xf86dri::CreateContextRequest {
31926 screen,
31927 visual,
31928 context,
31929 };
31930 let cookie = self.send_reply_request(request).with_span(span);
31931 cookie
31932 }
31933 #[cfg(feature = "xf86dri")]
31934 fn xf86dri_create_context_immediate<'this>(
31935 &'this mut self,
31936 screen: types::Card32,
31937 visual: types::Card32,
31938 context: types::Card32,
31939 ) -> futures::CheckedSendRequest<'this, Self, types::xf86dri::CreateContextReply> {
31940 let request = types::xf86dri::CreateContextRequest {
31941 screen,
31942 visual,
31943 context,
31944 };
31945 let cookie = self.send_reply_request(request);
31946 let res: futures::CheckedSendRequest<'this, Self, types::xf86dri::CreateContextReply> =
31947 cookie.into();
31948 res
31949 }
31950 #[cfg(feature = "xf86dri")]
31951 fn xf86dri_destroy_context<'this>(
31952 &'this mut self,
31953 screen: types::Card32,
31954 context: types::Card32,
31955 ) -> futures::SendRequest<'this, Self, ()> {
31956 let span = tracing::info_span!(
31957 "xf86dri_destroy_context",
31958 screen = ?screen,
31959 context = ?context,
31960 );
31961 let request = types::xf86dri::DestroyContextRequest { screen, context };
31962 let cookie = self.send_void_request(request, true).with_span(span);
31963 cookie
31964 }
31965 #[cfg(feature = "xf86dri")]
31966 fn xf86dri_destroy_context_checked<'this>(
31967 &'this mut self,
31968 screen: types::Card32,
31969 context: types::Card32,
31970 ) -> futures::CheckedSendRequest<'this, Self, ()> {
31971 let request = types::xf86dri::DestroyContextRequest { screen, context };
31972 let cookie = self.send_void_request(request, false);
31973 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
31974 res
31975 }
31976 #[cfg(feature = "xf86dri")]
31977 fn xf86dri_create_drawable<'this>(
31978 &'this mut self,
31979 screen: types::Card32,
31980 drawable: types::Card32,
31981 ) -> futures::SendRequest<'this, Self, types::xf86dri::CreateDrawableReply> {
31982 let span = tracing::info_span!(
31983 "xf86dri_create_drawable",
31984 screen = ?screen,
31985 drawable = ?drawable,
31986 );
31987 let request = types::xf86dri::CreateDrawableRequest { screen, drawable };
31988 let cookie = self.send_reply_request(request).with_span(span);
31989 cookie
31990 }
31991 #[cfg(feature = "xf86dri")]
31992 fn xf86dri_create_drawable_immediate<'this>(
31993 &'this mut self,
31994 screen: types::Card32,
31995 drawable: types::Card32,
31996 ) -> futures::CheckedSendRequest<'this, Self, types::xf86dri::CreateDrawableReply> {
31997 let request = types::xf86dri::CreateDrawableRequest { screen, drawable };
31998 let cookie = self.send_reply_request(request);
31999 let res: futures::CheckedSendRequest<'this, Self, types::xf86dri::CreateDrawableReply> =
32000 cookie.into();
32001 res
32002 }
32003 #[cfg(feature = "xf86dri")]
32004 fn xf86dri_destroy_drawable<'this>(
32005 &'this mut self,
32006 screen: types::Card32,
32007 drawable: types::Card32,
32008 ) -> futures::SendRequest<'this, Self, ()> {
32009 let span = tracing::info_span!(
32010 "xf86dri_destroy_drawable",
32011 screen = ?screen,
32012 drawable = ?drawable,
32013 );
32014 let request = types::xf86dri::DestroyDrawableRequest { screen, drawable };
32015 let cookie = self.send_void_request(request, true).with_span(span);
32016 cookie
32017 }
32018 #[cfg(feature = "xf86dri")]
32019 fn xf86dri_destroy_drawable_checked<'this>(
32020 &'this mut self,
32021 screen: types::Card32,
32022 drawable: types::Card32,
32023 ) -> futures::CheckedSendRequest<'this, Self, ()> {
32024 let request = types::xf86dri::DestroyDrawableRequest { screen, drawable };
32025 let cookie = self.send_void_request(request, false);
32026 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
32027 res
32028 }
32029 #[cfg(feature = "xf86dri")]
32030 fn xf86dri_get_drawable_info<'this>(
32031 &'this mut self,
32032 screen: types::Card32,
32033 drawable: types::Card32,
32034 ) -> futures::SendRequest<'this, Self, types::xf86dri::GetDrawableInfoReply> {
32035 let span = tracing::info_span!(
32036 "xf86dri_get_drawable_info",
32037 screen = ?screen,
32038 drawable = ?drawable,
32039 );
32040 let request = types::xf86dri::GetDrawableInfoRequest { screen, drawable };
32041 let cookie = self.send_reply_request(request).with_span(span);
32042 cookie
32043 }
32044 #[cfg(feature = "xf86dri")]
32045 fn xf86dri_get_drawable_info_immediate<'this>(
32046 &'this mut self,
32047 screen: types::Card32,
32048 drawable: types::Card32,
32049 ) -> futures::CheckedSendRequest<'this, Self, types::xf86dri::GetDrawableInfoReply> {
32050 let request = types::xf86dri::GetDrawableInfoRequest { screen, drawable };
32051 let cookie = self.send_reply_request(request);
32052 let res: futures::CheckedSendRequest<'this, Self, types::xf86dri::GetDrawableInfoReply> =
32053 cookie.into();
32054 res
32055 }
32056 #[cfg(feature = "xf86dri")]
32057 fn xf86dri_get_device_info<'this>(
32058 &'this mut self,
32059 screen: types::Card32,
32060 ) -> futures::SendRequest<'this, Self, types::xf86dri::GetDeviceInfoReply> {
32061 let span = tracing::info_span!(
32062 "xf86dri_get_device_info",
32063 screen = ?screen,
32064 );
32065 let request = types::xf86dri::GetDeviceInfoRequest { screen };
32066 let cookie = self.send_reply_request(request).with_span(span);
32067 cookie
32068 }
32069 #[cfg(feature = "xf86dri")]
32070 fn xf86dri_get_device_info_immediate<'this>(
32071 &'this mut self,
32072 screen: types::Card32,
32073 ) -> futures::CheckedSendRequest<'this, Self, types::xf86dri::GetDeviceInfoReply> {
32074 let request = types::xf86dri::GetDeviceInfoRequest { screen };
32075 let cookie = self.send_reply_request(request);
32076 let res: futures::CheckedSendRequest<'this, Self, types::xf86dri::GetDeviceInfoReply> =
32077 cookie.into();
32078 res
32079 }
32080 #[cfg(feature = "xf86dri")]
32081 fn xf86dri_auth_connection<'this>(
32082 &'this mut self,
32083 screen: types::Card32,
32084 magic: types::Card32,
32085 ) -> futures::SendRequest<'this, Self, types::xf86dri::AuthConnectionReply> {
32086 let span = tracing::info_span!(
32087 "xf86dri_auth_connection",
32088 screen = ?screen,
32089 magic = ?magic,
32090 );
32091 let request = types::xf86dri::AuthConnectionRequest { screen, magic };
32092 let cookie = self.send_reply_request(request).with_span(span);
32093 cookie
32094 }
32095 #[cfg(feature = "xf86dri")]
32096 fn xf86dri_auth_connection_immediate<'this>(
32097 &'this mut self,
32098 screen: types::Card32,
32099 magic: types::Card32,
32100 ) -> futures::CheckedSendRequest<'this, Self, types::xf86dri::AuthConnectionReply> {
32101 let request = types::xf86dri::AuthConnectionRequest { screen, magic };
32102 let cookie = self.send_reply_request(request);
32103 let res: futures::CheckedSendRequest<'this, Self, types::xf86dri::AuthConnectionReply> =
32104 cookie.into();
32105 res
32106 }
32107
32108 #[cfg(feature = "xf86vidmode")]
32109 fn xf86vidmode_query_version<'this>(
32110 &'this mut self,
32111 ) -> futures::SendRequest<'this, Self, types::xf86vidmode::QueryVersionReply> {
32112 let span = tracing::info_span!("xf86vidmode_query_version",);
32113 let request = types::xf86vidmode::QueryVersionRequest {};
32114 let cookie = self.send_reply_request(request).with_span(span);
32115 cookie
32116 }
32117 #[cfg(feature = "xf86vidmode")]
32118 fn xf86vidmode_query_version_immediate<'this>(
32119 &'this mut self,
32120 ) -> futures::CheckedSendRequest<'this, Self, types::xf86vidmode::QueryVersionReply> {
32121 let request = types::xf86vidmode::QueryVersionRequest {};
32122 let cookie = self.send_reply_request(request);
32123 let res: futures::CheckedSendRequest<'this, Self, types::xf86vidmode::QueryVersionReply> =
32124 cookie.into();
32125 res
32126 }
32127 #[cfg(feature = "xf86vidmode")]
32128 fn xf86vidmode_get_mode_line<'this>(
32129 &'this mut self,
32130 screen: types::Card16,
32131 ) -> futures::SendRequest<'this, Self, types::xf86vidmode::GetModeLineReply> {
32132 let span = tracing::info_span!(
32133 "xf86vidmode_get_mode_line",
32134 screen = ?screen,
32135 );
32136 let request = types::xf86vidmode::GetModeLineRequest { screen };
32137 let cookie = self.send_reply_request(request).with_span(span);
32138 cookie
32139 }
32140 #[cfg(feature = "xf86vidmode")]
32141 fn xf86vidmode_get_mode_line_immediate<'this>(
32142 &'this mut self,
32143 screen: types::Card16,
32144 ) -> futures::CheckedSendRequest<'this, Self, types::xf86vidmode::GetModeLineReply> {
32145 let request = types::xf86vidmode::GetModeLineRequest { screen };
32146 let cookie = self.send_reply_request(request);
32147 let res: futures::CheckedSendRequest<'this, Self, types::xf86vidmode::GetModeLineReply> =
32148 cookie.into();
32149 res
32150 }
32151 #[cfg(feature = "xf86vidmode")]
32152 fn xf86vidmode_mod_mode_line<'this>(
32153 &'this mut self,
32154 screen: types::Card32,
32155 hdisplay: types::Card16,
32156 hsyncstart: types::Card16,
32157 hsyncend: types::Card16,
32158 htotal: types::Card16,
32159 hskew: types::Card16,
32160 vdisplay: types::Card16,
32161 vsyncstart: types::Card16,
32162 vsyncend: types::Card16,
32163 vtotal: types::Card16,
32164 flags: impl Into<types::xf86vidmode::ModeFlag>,
32165 private: impl AsRef<[types::Card8]>,
32166 ) -> futures::SendRequest<'this, Self, ()> {
32167 let span = tracing::info_span!(
32168 "xf86vidmode_mod_mode_line",
32169 screen = ?screen,
32170 hdisplay = ?hdisplay,
32171 hsyncstart = ?hsyncstart,
32172 hsyncend = ?hsyncend,
32173 htotal = ?htotal,
32174 hskew = ?hskew,
32175 vdisplay = ?vdisplay,
32176 vsyncstart = ?vsyncstart,
32177 vsyncend = ?vsyncend,
32178 vtotal = ?vtotal,
32179 );
32180 let request = types::xf86vidmode::ModModeLineRequest {
32181 screen,
32182 hdisplay,
32183 hsyncstart,
32184 hsyncend,
32185 htotal,
32186 hskew,
32187 vdisplay,
32188 vsyncstart,
32189 vsyncend,
32190 vtotal,
32191 flags: Into::<u32>::into(flags.into()) as _,
32192 private: Cow::Borrowed(private.as_ref()),
32193 };
32194 let cookie = self.send_void_request(request, true).with_span(span);
32195 cookie
32196 }
32197 #[cfg(feature = "xf86vidmode")]
32198 fn xf86vidmode_mod_mode_line_checked<'this>(
32199 &'this mut self,
32200 screen: types::Card32,
32201 hdisplay: types::Card16,
32202 hsyncstart: types::Card16,
32203 hsyncend: types::Card16,
32204 htotal: types::Card16,
32205 hskew: types::Card16,
32206 vdisplay: types::Card16,
32207 vsyncstart: types::Card16,
32208 vsyncend: types::Card16,
32209 vtotal: types::Card16,
32210 flags: impl Into<types::xf86vidmode::ModeFlag>,
32211 private: impl AsRef<[types::Card8]>,
32212 ) -> futures::CheckedSendRequest<'this, Self, ()> {
32213 let request = types::xf86vidmode::ModModeLineRequest {
32214 screen,
32215 hdisplay,
32216 hsyncstart,
32217 hsyncend,
32218 htotal,
32219 hskew,
32220 vdisplay,
32221 vsyncstart,
32222 vsyncend,
32223 vtotal,
32224 flags: Into::<u32>::into(flags.into()) as _,
32225 private: Cow::Borrowed(private.as_ref()),
32226 };
32227 let cookie = self.send_void_request(request, false);
32228 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
32229 res
32230 }
32231 #[cfg(feature = "xf86vidmode")]
32232 fn xf86vidmode_switch_mode<'this>(
32233 &'this mut self,
32234 screen: types::Card16,
32235 zoom: types::Card16,
32236 ) -> futures::SendRequest<'this, Self, ()> {
32237 let span = tracing::info_span!(
32238 "xf86vidmode_switch_mode",
32239 screen = ?screen,
32240 zoom = ?zoom,
32241 );
32242 let request = types::xf86vidmode::SwitchModeRequest { screen, zoom };
32243 let cookie = self.send_void_request(request, true).with_span(span);
32244 cookie
32245 }
32246 #[cfg(feature = "xf86vidmode")]
32247 fn xf86vidmode_switch_mode_checked<'this>(
32248 &'this mut self,
32249 screen: types::Card16,
32250 zoom: types::Card16,
32251 ) -> futures::CheckedSendRequest<'this, Self, ()> {
32252 let request = types::xf86vidmode::SwitchModeRequest { screen, zoom };
32253 let cookie = self.send_void_request(request, false);
32254 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
32255 res
32256 }
32257 #[cfg(feature = "xf86vidmode")]
32258 fn xf86vidmode_get_monitor<'this>(
32259 &'this mut self,
32260 screen: types::Card16,
32261 ) -> futures::SendRequest<'this, Self, types::xf86vidmode::GetMonitorReply> {
32262 let span = tracing::info_span!(
32263 "xf86vidmode_get_monitor",
32264 screen = ?screen,
32265 );
32266 let request = types::xf86vidmode::GetMonitorRequest { screen };
32267 let cookie = self.send_reply_request(request).with_span(span);
32268 cookie
32269 }
32270 #[cfg(feature = "xf86vidmode")]
32271 fn xf86vidmode_get_monitor_immediate<'this>(
32272 &'this mut self,
32273 screen: types::Card16,
32274 ) -> futures::CheckedSendRequest<'this, Self, types::xf86vidmode::GetMonitorReply> {
32275 let request = types::xf86vidmode::GetMonitorRequest { screen };
32276 let cookie = self.send_reply_request(request);
32277 let res: futures::CheckedSendRequest<'this, Self, types::xf86vidmode::GetMonitorReply> =
32278 cookie.into();
32279 res
32280 }
32281 #[cfg(feature = "xf86vidmode")]
32282 fn xf86vidmode_lock_mode_switch<'this>(
32283 &'this mut self,
32284 screen: types::Card16,
32285 lock: types::Card16,
32286 ) -> futures::SendRequest<'this, Self, ()> {
32287 let span = tracing::info_span!(
32288 "xf86vidmode_lock_mode_switch",
32289 screen = ?screen,
32290 lock = ?lock,
32291 );
32292 let request = types::xf86vidmode::LockModeSwitchRequest { screen, lock };
32293 let cookie = self.send_void_request(request, true).with_span(span);
32294 cookie
32295 }
32296 #[cfg(feature = "xf86vidmode")]
32297 fn xf86vidmode_lock_mode_switch_checked<'this>(
32298 &'this mut self,
32299 screen: types::Card16,
32300 lock: types::Card16,
32301 ) -> futures::CheckedSendRequest<'this, Self, ()> {
32302 let request = types::xf86vidmode::LockModeSwitchRequest { screen, lock };
32303 let cookie = self.send_void_request(request, false);
32304 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
32305 res
32306 }
32307 #[cfg(feature = "xf86vidmode")]
32308 fn xf86vidmode_get_all_mode_lines<'this>(
32309 &'this mut self,
32310 screen: types::Card16,
32311 ) -> futures::SendRequest<'this, Self, types::xf86vidmode::GetAllModeLinesReply> {
32312 let span = tracing::info_span!(
32313 "xf86vidmode_get_all_mode_lines",
32314 screen = ?screen,
32315 );
32316 let request = types::xf86vidmode::GetAllModeLinesRequest { screen };
32317 let cookie = self.send_reply_request(request).with_span(span);
32318 cookie
32319 }
32320 #[cfg(feature = "xf86vidmode")]
32321 fn xf86vidmode_get_all_mode_lines_immediate<'this>(
32322 &'this mut self,
32323 screen: types::Card16,
32324 ) -> futures::CheckedSendRequest<'this, Self, types::xf86vidmode::GetAllModeLinesReply> {
32325 let request = types::xf86vidmode::GetAllModeLinesRequest { screen };
32326 let cookie = self.send_reply_request(request);
32327 let res: futures::CheckedSendRequest<
32328 'this,
32329 Self,
32330 types::xf86vidmode::GetAllModeLinesReply,
32331 > = cookie.into();
32332 res
32333 }
32334 #[cfg(feature = "xf86vidmode")]
32335 fn xf86vidmode_add_mode_line<'this>(
32336 &'this mut self,
32337 screen: types::Card32,
32338 dotclock: types::Dotclock,
32339 hdisplay: types::Card16,
32340 hsyncstart: types::Card16,
32341 hsyncend: types::Card16,
32342 htotal: types::Card16,
32343 hskew: types::Card16,
32344 vdisplay: types::Card16,
32345 vsyncstart: types::Card16,
32346 vsyncend: types::Card16,
32347 vtotal: types::Card16,
32348 flags: impl Into<types::xf86vidmode::ModeFlag>,
32349 after_dotclock: types::Dotclock,
32350 after_hdisplay: types::Card16,
32351 after_hsyncstart: types::Card16,
32352 after_hsyncend: types::Card16,
32353 after_htotal: types::Card16,
32354 after_hskew: types::Card16,
32355 after_vdisplay: types::Card16,
32356 after_vsyncstart: types::Card16,
32357 after_vsyncend: types::Card16,
32358 after_vtotal: types::Card16,
32359 after_flags: impl Into<types::xf86vidmode::ModeFlag>,
32360 private: impl AsRef<[types::Card8]>,
32361 ) -> futures::SendRequest<'this, Self, ()> {
32362 let span = tracing::info_span!(
32363 "xf86vidmode_add_mode_line",
32364 screen = ?screen,
32365 dotclock = ?dotclock,
32366 hdisplay = ?hdisplay,
32367 hsyncstart = ?hsyncstart,
32368 hsyncend = ?hsyncend,
32369 htotal = ?htotal,
32370 hskew = ?hskew,
32371 vdisplay = ?vdisplay,
32372 vsyncstart = ?vsyncstart,
32373 vsyncend = ?vsyncend,
32374 vtotal = ?vtotal,
32375 after_dotclock = ?after_dotclock,
32376 after_hdisplay = ?after_hdisplay,
32377 after_hsyncstart = ?after_hsyncstart,
32378 after_hsyncend = ?after_hsyncend,
32379 after_htotal = ?after_htotal,
32380 after_hskew = ?after_hskew,
32381 after_vdisplay = ?after_vdisplay,
32382 after_vsyncstart = ?after_vsyncstart,
32383 after_vsyncend = ?after_vsyncend,
32384 after_vtotal = ?after_vtotal,
32385 );
32386 let request = types::xf86vidmode::AddModeLineRequest {
32387 screen,
32388 dotclock,
32389 hdisplay,
32390 hsyncstart,
32391 hsyncend,
32392 htotal,
32393 hskew,
32394 vdisplay,
32395 vsyncstart,
32396 vsyncend,
32397 vtotal,
32398 flags: Into::<u32>::into(flags.into()) as _,
32399 after_dotclock,
32400 after_hdisplay,
32401 after_hsyncstart,
32402 after_hsyncend,
32403 after_htotal,
32404 after_hskew,
32405 after_vdisplay,
32406 after_vsyncstart,
32407 after_vsyncend,
32408 after_vtotal,
32409 after_flags: Into::<u32>::into(after_flags.into()) as _,
32410 private: Cow::Borrowed(private.as_ref()),
32411 };
32412 let cookie = self.send_void_request(request, true).with_span(span);
32413 cookie
32414 }
32415 #[cfg(feature = "xf86vidmode")]
32416 fn xf86vidmode_add_mode_line_checked<'this>(
32417 &'this mut self,
32418 screen: types::Card32,
32419 dotclock: types::Dotclock,
32420 hdisplay: types::Card16,
32421 hsyncstart: types::Card16,
32422 hsyncend: types::Card16,
32423 htotal: types::Card16,
32424 hskew: types::Card16,
32425 vdisplay: types::Card16,
32426 vsyncstart: types::Card16,
32427 vsyncend: types::Card16,
32428 vtotal: types::Card16,
32429 flags: impl Into<types::xf86vidmode::ModeFlag>,
32430 after_dotclock: types::Dotclock,
32431 after_hdisplay: types::Card16,
32432 after_hsyncstart: types::Card16,
32433 after_hsyncend: types::Card16,
32434 after_htotal: types::Card16,
32435 after_hskew: types::Card16,
32436 after_vdisplay: types::Card16,
32437 after_vsyncstart: types::Card16,
32438 after_vsyncend: types::Card16,
32439 after_vtotal: types::Card16,
32440 after_flags: impl Into<types::xf86vidmode::ModeFlag>,
32441 private: impl AsRef<[types::Card8]>,
32442 ) -> futures::CheckedSendRequest<'this, Self, ()> {
32443 let request = types::xf86vidmode::AddModeLineRequest {
32444 screen,
32445 dotclock,
32446 hdisplay,
32447 hsyncstart,
32448 hsyncend,
32449 htotal,
32450 hskew,
32451 vdisplay,
32452 vsyncstart,
32453 vsyncend,
32454 vtotal,
32455 flags: Into::<u32>::into(flags.into()) as _,
32456 after_dotclock,
32457 after_hdisplay,
32458 after_hsyncstart,
32459 after_hsyncend,
32460 after_htotal,
32461 after_hskew,
32462 after_vdisplay,
32463 after_vsyncstart,
32464 after_vsyncend,
32465 after_vtotal,
32466 after_flags: Into::<u32>::into(after_flags.into()) as _,
32467 private: Cow::Borrowed(private.as_ref()),
32468 };
32469 let cookie = self.send_void_request(request, false);
32470 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
32471 res
32472 }
32473 #[cfg(feature = "xf86vidmode")]
32474 fn xf86vidmode_delete_mode_line<'this>(
32475 &'this mut self,
32476 screen: types::Card32,
32477 dotclock: types::Dotclock,
32478 hdisplay: types::Card16,
32479 hsyncstart: types::Card16,
32480 hsyncend: types::Card16,
32481 htotal: types::Card16,
32482 hskew: types::Card16,
32483 vdisplay: types::Card16,
32484 vsyncstart: types::Card16,
32485 vsyncend: types::Card16,
32486 vtotal: types::Card16,
32487 flags: impl Into<types::xf86vidmode::ModeFlag>,
32488 private: impl AsRef<[types::Card8]>,
32489 ) -> futures::SendRequest<'this, Self, ()> {
32490 let span = tracing::info_span!(
32491 "xf86vidmode_delete_mode_line",
32492 screen = ?screen,
32493 dotclock = ?dotclock,
32494 hdisplay = ?hdisplay,
32495 hsyncstart = ?hsyncstart,
32496 hsyncend = ?hsyncend,
32497 htotal = ?htotal,
32498 hskew = ?hskew,
32499 vdisplay = ?vdisplay,
32500 vsyncstart = ?vsyncstart,
32501 vsyncend = ?vsyncend,
32502 vtotal = ?vtotal,
32503 );
32504 let request = types::xf86vidmode::DeleteModeLineRequest {
32505 screen,
32506 dotclock,
32507 hdisplay,
32508 hsyncstart,
32509 hsyncend,
32510 htotal,
32511 hskew,
32512 vdisplay,
32513 vsyncstart,
32514 vsyncend,
32515 vtotal,
32516 flags: Into::<u32>::into(flags.into()) as _,
32517 private: Cow::Borrowed(private.as_ref()),
32518 };
32519 let cookie = self.send_void_request(request, true).with_span(span);
32520 cookie
32521 }
32522 #[cfg(feature = "xf86vidmode")]
32523 fn xf86vidmode_delete_mode_line_checked<'this>(
32524 &'this mut self,
32525 screen: types::Card32,
32526 dotclock: types::Dotclock,
32527 hdisplay: types::Card16,
32528 hsyncstart: types::Card16,
32529 hsyncend: types::Card16,
32530 htotal: types::Card16,
32531 hskew: types::Card16,
32532 vdisplay: types::Card16,
32533 vsyncstart: types::Card16,
32534 vsyncend: types::Card16,
32535 vtotal: types::Card16,
32536 flags: impl Into<types::xf86vidmode::ModeFlag>,
32537 private: impl AsRef<[types::Card8]>,
32538 ) -> futures::CheckedSendRequest<'this, Self, ()> {
32539 let request = types::xf86vidmode::DeleteModeLineRequest {
32540 screen,
32541 dotclock,
32542 hdisplay,
32543 hsyncstart,
32544 hsyncend,
32545 htotal,
32546 hskew,
32547 vdisplay,
32548 vsyncstart,
32549 vsyncend,
32550 vtotal,
32551 flags: Into::<u32>::into(flags.into()) as _,
32552 private: Cow::Borrowed(private.as_ref()),
32553 };
32554 let cookie = self.send_void_request(request, false);
32555 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
32556 res
32557 }
32558 #[cfg(feature = "xf86vidmode")]
32559 fn xf86vidmode_validate_mode_line<'this>(
32560 &'this mut self,
32561 screen: types::Card32,
32562 dotclock: types::Dotclock,
32563 hdisplay: types::Card16,
32564 hsyncstart: types::Card16,
32565 hsyncend: types::Card16,
32566 htotal: types::Card16,
32567 hskew: types::Card16,
32568 vdisplay: types::Card16,
32569 vsyncstart: types::Card16,
32570 vsyncend: types::Card16,
32571 vtotal: types::Card16,
32572 flags: impl Into<types::xf86vidmode::ModeFlag>,
32573 private: impl AsRef<[types::Card8]>,
32574 ) -> futures::SendRequest<'this, Self, types::xf86vidmode::ValidateModeLineReply> {
32575 let span = tracing::info_span!(
32576 "xf86vidmode_validate_mode_line",
32577 screen = ?screen,
32578 dotclock = ?dotclock,
32579 hdisplay = ?hdisplay,
32580 hsyncstart = ?hsyncstart,
32581 hsyncend = ?hsyncend,
32582 htotal = ?htotal,
32583 hskew = ?hskew,
32584 vdisplay = ?vdisplay,
32585 vsyncstart = ?vsyncstart,
32586 vsyncend = ?vsyncend,
32587 vtotal = ?vtotal,
32588 );
32589 let request = types::xf86vidmode::ValidateModeLineRequest {
32590 screen,
32591 dotclock,
32592 hdisplay,
32593 hsyncstart,
32594 hsyncend,
32595 htotal,
32596 hskew,
32597 vdisplay,
32598 vsyncstart,
32599 vsyncend,
32600 vtotal,
32601 flags: Into::<u32>::into(flags.into()) as _,
32602 private: Cow::Borrowed(private.as_ref()),
32603 };
32604 let cookie = self.send_reply_request(request).with_span(span);
32605 cookie
32606 }
32607 #[cfg(feature = "xf86vidmode")]
32608 fn xf86vidmode_validate_mode_line_immediate<'this>(
32609 &'this mut self,
32610 screen: types::Card32,
32611 dotclock: types::Dotclock,
32612 hdisplay: types::Card16,
32613 hsyncstart: types::Card16,
32614 hsyncend: types::Card16,
32615 htotal: types::Card16,
32616 hskew: types::Card16,
32617 vdisplay: types::Card16,
32618 vsyncstart: types::Card16,
32619 vsyncend: types::Card16,
32620 vtotal: types::Card16,
32621 flags: impl Into<types::xf86vidmode::ModeFlag>,
32622 private: impl AsRef<[types::Card8]>,
32623 ) -> futures::CheckedSendRequest<'this, Self, types::xf86vidmode::ValidateModeLineReply> {
32624 let request = types::xf86vidmode::ValidateModeLineRequest {
32625 screen,
32626 dotclock,
32627 hdisplay,
32628 hsyncstart,
32629 hsyncend,
32630 htotal,
32631 hskew,
32632 vdisplay,
32633 vsyncstart,
32634 vsyncend,
32635 vtotal,
32636 flags: Into::<u32>::into(flags.into()) as _,
32637 private: Cow::Borrowed(private.as_ref()),
32638 };
32639 let cookie = self.send_reply_request(request);
32640 let res: futures::CheckedSendRequest<
32641 'this,
32642 Self,
32643 types::xf86vidmode::ValidateModeLineReply,
32644 > = cookie.into();
32645 res
32646 }
32647 #[cfg(feature = "xf86vidmode")]
32648 fn xf86vidmode_switch_to_mode<'this>(
32649 &'this mut self,
32650 screen: types::Card32,
32651 dotclock: types::Dotclock,
32652 hdisplay: types::Card16,
32653 hsyncstart: types::Card16,
32654 hsyncend: types::Card16,
32655 htotal: types::Card16,
32656 hskew: types::Card16,
32657 vdisplay: types::Card16,
32658 vsyncstart: types::Card16,
32659 vsyncend: types::Card16,
32660 vtotal: types::Card16,
32661 flags: impl Into<types::xf86vidmode::ModeFlag>,
32662 private: impl AsRef<[types::Card8]>,
32663 ) -> futures::SendRequest<'this, Self, ()> {
32664 let span = tracing::info_span!(
32665 "xf86vidmode_switch_to_mode",
32666 screen = ?screen,
32667 dotclock = ?dotclock,
32668 hdisplay = ?hdisplay,
32669 hsyncstart = ?hsyncstart,
32670 hsyncend = ?hsyncend,
32671 htotal = ?htotal,
32672 hskew = ?hskew,
32673 vdisplay = ?vdisplay,
32674 vsyncstart = ?vsyncstart,
32675 vsyncend = ?vsyncend,
32676 vtotal = ?vtotal,
32677 );
32678 let request = types::xf86vidmode::SwitchToModeRequest {
32679 screen,
32680 dotclock,
32681 hdisplay,
32682 hsyncstart,
32683 hsyncend,
32684 htotal,
32685 hskew,
32686 vdisplay,
32687 vsyncstart,
32688 vsyncend,
32689 vtotal,
32690 flags: Into::<u32>::into(flags.into()) as _,
32691 private: Cow::Borrowed(private.as_ref()),
32692 };
32693 let cookie = self.send_void_request(request, true).with_span(span);
32694 cookie
32695 }
32696 #[cfg(feature = "xf86vidmode")]
32697 fn xf86vidmode_switch_to_mode_checked<'this>(
32698 &'this mut self,
32699 screen: types::Card32,
32700 dotclock: types::Dotclock,
32701 hdisplay: types::Card16,
32702 hsyncstart: types::Card16,
32703 hsyncend: types::Card16,
32704 htotal: types::Card16,
32705 hskew: types::Card16,
32706 vdisplay: types::Card16,
32707 vsyncstart: types::Card16,
32708 vsyncend: types::Card16,
32709 vtotal: types::Card16,
32710 flags: impl Into<types::xf86vidmode::ModeFlag>,
32711 private: impl AsRef<[types::Card8]>,
32712 ) -> futures::CheckedSendRequest<'this, Self, ()> {
32713 let request = types::xf86vidmode::SwitchToModeRequest {
32714 screen,
32715 dotclock,
32716 hdisplay,
32717 hsyncstart,
32718 hsyncend,
32719 htotal,
32720 hskew,
32721 vdisplay,
32722 vsyncstart,
32723 vsyncend,
32724 vtotal,
32725 flags: Into::<u32>::into(flags.into()) as _,
32726 private: Cow::Borrowed(private.as_ref()),
32727 };
32728 let cookie = self.send_void_request(request, false);
32729 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
32730 res
32731 }
32732 #[cfg(feature = "xf86vidmode")]
32733 fn xf86vidmode_get_view_port<'this>(
32734 &'this mut self,
32735 screen: types::Card16,
32736 ) -> futures::SendRequest<'this, Self, types::xf86vidmode::GetViewPortReply> {
32737 let span = tracing::info_span!(
32738 "xf86vidmode_get_view_port",
32739 screen = ?screen,
32740 );
32741 let request = types::xf86vidmode::GetViewPortRequest { screen };
32742 let cookie = self.send_reply_request(request).with_span(span);
32743 cookie
32744 }
32745 #[cfg(feature = "xf86vidmode")]
32746 fn xf86vidmode_get_view_port_immediate<'this>(
32747 &'this mut self,
32748 screen: types::Card16,
32749 ) -> futures::CheckedSendRequest<'this, Self, types::xf86vidmode::GetViewPortReply> {
32750 let request = types::xf86vidmode::GetViewPortRequest { screen };
32751 let cookie = self.send_reply_request(request);
32752 let res: futures::CheckedSendRequest<'this, Self, types::xf86vidmode::GetViewPortReply> =
32753 cookie.into();
32754 res
32755 }
32756 #[cfg(feature = "xf86vidmode")]
32757 fn xf86vidmode_set_view_port<'this>(
32758 &'this mut self,
32759 screen: types::Card16,
32760 x: types::Card32,
32761 y: types::Card32,
32762 ) -> futures::SendRequest<'this, Self, ()> {
32763 let span = tracing::info_span!(
32764 "xf86vidmode_set_view_port",
32765 screen = ?screen,
32766 x = ?x,
32767 y = ?y,
32768 );
32769 let request = types::xf86vidmode::SetViewPortRequest { screen, x, y };
32770 let cookie = self.send_void_request(request, true).with_span(span);
32771 cookie
32772 }
32773 #[cfg(feature = "xf86vidmode")]
32774 fn xf86vidmode_set_view_port_checked<'this>(
32775 &'this mut self,
32776 screen: types::Card16,
32777 x: types::Card32,
32778 y: types::Card32,
32779 ) -> futures::CheckedSendRequest<'this, Self, ()> {
32780 let request = types::xf86vidmode::SetViewPortRequest { screen, x, y };
32781 let cookie = self.send_void_request(request, false);
32782 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
32783 res
32784 }
32785 #[cfg(feature = "xf86vidmode")]
32786 fn xf86vidmode_get_dot_clocks<'this>(
32787 &'this mut self,
32788 screen: types::Card16,
32789 ) -> futures::SendRequest<'this, Self, types::xf86vidmode::GetDotClocksReply> {
32790 let span = tracing::info_span!(
32791 "xf86vidmode_get_dot_clocks",
32792 screen = ?screen,
32793 );
32794 let request = types::xf86vidmode::GetDotClocksRequest { screen };
32795 let cookie = self.send_reply_request(request).with_span(span);
32796 cookie
32797 }
32798 #[cfg(feature = "xf86vidmode")]
32799 fn xf86vidmode_get_dot_clocks_immediate<'this>(
32800 &'this mut self,
32801 screen: types::Card16,
32802 ) -> futures::CheckedSendRequest<'this, Self, types::xf86vidmode::GetDotClocksReply> {
32803 let request = types::xf86vidmode::GetDotClocksRequest { screen };
32804 let cookie = self.send_reply_request(request);
32805 let res: futures::CheckedSendRequest<'this, Self, types::xf86vidmode::GetDotClocksReply> =
32806 cookie.into();
32807 res
32808 }
32809 #[cfg(feature = "xf86vidmode")]
32810 fn xf86vidmode_set_client_version<'this>(
32811 &'this mut self,
32812 major: types::Card16,
32813 minor: types::Card16,
32814 ) -> futures::SendRequest<'this, Self, ()> {
32815 let span = tracing::info_span!(
32816 "xf86vidmode_set_client_version",
32817 major = ?major,
32818 minor = ?minor,
32819 );
32820 let request = types::xf86vidmode::SetClientVersionRequest { major, minor };
32821 let cookie = self.send_void_request(request, true).with_span(span);
32822 cookie
32823 }
32824 #[cfg(feature = "xf86vidmode")]
32825 fn xf86vidmode_set_client_version_checked<'this>(
32826 &'this mut self,
32827 major: types::Card16,
32828 minor: types::Card16,
32829 ) -> futures::CheckedSendRequest<'this, Self, ()> {
32830 let request = types::xf86vidmode::SetClientVersionRequest { major, minor };
32831 let cookie = self.send_void_request(request, false);
32832 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
32833 res
32834 }
32835 #[cfg(feature = "xf86vidmode")]
32836 fn xf86vidmode_set_gamma<'this>(
32837 &'this mut self,
32838 screen: types::Card16,
32839 red: types::Card32,
32840 green: types::Card32,
32841 blue: types::Card32,
32842 ) -> futures::SendRequest<'this, Self, ()> {
32843 let span = tracing::info_span!(
32844 "xf86vidmode_set_gamma",
32845 screen = ?screen,
32846 red = ?red,
32847 green = ?green,
32848 blue = ?blue,
32849 );
32850 let request = types::xf86vidmode::SetGammaRequest {
32851 screen,
32852 red,
32853 green,
32854 blue,
32855 };
32856 let cookie = self.send_void_request(request, true).with_span(span);
32857 cookie
32858 }
32859 #[cfg(feature = "xf86vidmode")]
32860 fn xf86vidmode_set_gamma_checked<'this>(
32861 &'this mut self,
32862 screen: types::Card16,
32863 red: types::Card32,
32864 green: types::Card32,
32865 blue: types::Card32,
32866 ) -> futures::CheckedSendRequest<'this, Self, ()> {
32867 let request = types::xf86vidmode::SetGammaRequest {
32868 screen,
32869 red,
32870 green,
32871 blue,
32872 };
32873 let cookie = self.send_void_request(request, false);
32874 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
32875 res
32876 }
32877 #[cfg(feature = "xf86vidmode")]
32878 fn xf86vidmode_get_gamma<'this>(
32879 &'this mut self,
32880 screen: types::Card16,
32881 ) -> futures::SendRequest<'this, Self, types::xf86vidmode::GetGammaReply> {
32882 let span = tracing::info_span!(
32883 "xf86vidmode_get_gamma",
32884 screen = ?screen,
32885 );
32886 let request = types::xf86vidmode::GetGammaRequest { screen };
32887 let cookie = self.send_reply_request(request).with_span(span);
32888 cookie
32889 }
32890 #[cfg(feature = "xf86vidmode")]
32891 fn xf86vidmode_get_gamma_immediate<'this>(
32892 &'this mut self,
32893 screen: types::Card16,
32894 ) -> futures::CheckedSendRequest<'this, Self, types::xf86vidmode::GetGammaReply> {
32895 let request = types::xf86vidmode::GetGammaRequest { screen };
32896 let cookie = self.send_reply_request(request);
32897 let res: futures::CheckedSendRequest<'this, Self, types::xf86vidmode::GetGammaReply> =
32898 cookie.into();
32899 res
32900 }
32901 #[cfg(feature = "xf86vidmode")]
32902 fn xf86vidmode_get_gamma_ramp<'this>(
32903 &'this mut self,
32904 screen: types::Card16,
32905 size: types::Card16,
32906 ) -> futures::SendRequest<'this, Self, types::xf86vidmode::GetGammaRampReply> {
32907 let span = tracing::info_span!(
32908 "xf86vidmode_get_gamma_ramp",
32909 screen = ?screen,
32910 size = ?size,
32911 );
32912 let request = types::xf86vidmode::GetGammaRampRequest { screen, size };
32913 let cookie = self.send_reply_request(request).with_span(span);
32914 cookie
32915 }
32916 #[cfg(feature = "xf86vidmode")]
32917 fn xf86vidmode_get_gamma_ramp_immediate<'this>(
32918 &'this mut self,
32919 screen: types::Card16,
32920 size: types::Card16,
32921 ) -> futures::CheckedSendRequest<'this, Self, types::xf86vidmode::GetGammaRampReply> {
32922 let request = types::xf86vidmode::GetGammaRampRequest { screen, size };
32923 let cookie = self.send_reply_request(request);
32924 let res: futures::CheckedSendRequest<'this, Self, types::xf86vidmode::GetGammaRampReply> =
32925 cookie.into();
32926 res
32927 }
32928 #[cfg(feature = "xf86vidmode")]
32929 fn xf86vidmode_set_gamma_ramp<'this>(
32930 &'this mut self,
32931 screen: types::Card16,
32932 size: types::Card16,
32933 red: impl AsRef<[types::Card16]>,
32934 green: impl AsRef<[types::Card16]>,
32935 blue: impl AsRef<[types::Card16]>,
32936 ) -> futures::SendRequest<'this, Self, ()> {
32937 let span = tracing::info_span!(
32938 "xf86vidmode_set_gamma_ramp",
32939 screen = ?screen,
32940 size = ?size,
32941 );
32942 let request = types::xf86vidmode::SetGammaRampRequest {
32943 screen,
32944 size,
32945 red: Cow::Borrowed(red.as_ref()),
32946 green: Cow::Borrowed(green.as_ref()),
32947 blue: Cow::Borrowed(blue.as_ref()),
32948 };
32949 let cookie = self.send_void_request(request, true).with_span(span);
32950 cookie
32951 }
32952 #[cfg(feature = "xf86vidmode")]
32953 fn xf86vidmode_set_gamma_ramp_checked<'this>(
32954 &'this mut self,
32955 screen: types::Card16,
32956 size: types::Card16,
32957 red: impl AsRef<[types::Card16]>,
32958 green: impl AsRef<[types::Card16]>,
32959 blue: impl AsRef<[types::Card16]>,
32960 ) -> futures::CheckedSendRequest<'this, Self, ()> {
32961 let request = types::xf86vidmode::SetGammaRampRequest {
32962 screen,
32963 size,
32964 red: Cow::Borrowed(red.as_ref()),
32965 green: Cow::Borrowed(green.as_ref()),
32966 blue: Cow::Borrowed(blue.as_ref()),
32967 };
32968 let cookie = self.send_void_request(request, false);
32969 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
32970 res
32971 }
32972 #[cfg(feature = "xf86vidmode")]
32973 fn xf86vidmode_get_gamma_ramp_size<'this>(
32974 &'this mut self,
32975 screen: types::Card16,
32976 ) -> futures::SendRequest<'this, Self, types::xf86vidmode::GetGammaRampSizeReply> {
32977 let span = tracing::info_span!(
32978 "xf86vidmode_get_gamma_ramp_size",
32979 screen = ?screen,
32980 );
32981 let request = types::xf86vidmode::GetGammaRampSizeRequest { screen };
32982 let cookie = self.send_reply_request(request).with_span(span);
32983 cookie
32984 }
32985 #[cfg(feature = "xf86vidmode")]
32986 fn xf86vidmode_get_gamma_ramp_size_immediate<'this>(
32987 &'this mut self,
32988 screen: types::Card16,
32989 ) -> futures::CheckedSendRequest<'this, Self, types::xf86vidmode::GetGammaRampSizeReply> {
32990 let request = types::xf86vidmode::GetGammaRampSizeRequest { screen };
32991 let cookie = self.send_reply_request(request);
32992 let res: futures::CheckedSendRequest<
32993 'this,
32994 Self,
32995 types::xf86vidmode::GetGammaRampSizeReply,
32996 > = cookie.into();
32997 res
32998 }
32999 #[cfg(feature = "xf86vidmode")]
33000 fn xf86vidmode_get_permissions<'this>(
33001 &'this mut self,
33002 screen: types::Card16,
33003 ) -> futures::SendRequest<'this, Self, types::xf86vidmode::GetPermissionsReply> {
33004 let span = tracing::info_span!(
33005 "xf86vidmode_get_permissions",
33006 screen = ?screen,
33007 );
33008 let request = types::xf86vidmode::GetPermissionsRequest { screen };
33009 let cookie = self.send_reply_request(request).with_span(span);
33010 cookie
33011 }
33012 #[cfg(feature = "xf86vidmode")]
33013 fn xf86vidmode_get_permissions_immediate<'this>(
33014 &'this mut self,
33015 screen: types::Card16,
33016 ) -> futures::CheckedSendRequest<'this, Self, types::xf86vidmode::GetPermissionsReply> {
33017 let request = types::xf86vidmode::GetPermissionsRequest { screen };
33018 let cookie = self.send_reply_request(request);
33019 let res: futures::CheckedSendRequest<'this, Self, types::xf86vidmode::GetPermissionsReply> =
33020 cookie.into();
33021 res
33022 }
33023
33024 #[cfg(feature = "xfixes")]
33025 fn xfixes_query_version<'this>(
33026 &'this mut self,
33027 client_major_version: types::Card32,
33028 client_minor_version: types::Card32,
33029 ) -> futures::SendRequest<'this, Self, types::xfixes::QueryVersionReply> {
33030 let span = tracing::info_span!(
33031 "xfixes_query_version",
33032 client_major_version = ?client_major_version,
33033 client_minor_version = ?client_minor_version,
33034 );
33035 let request = types::xfixes::QueryVersionRequest {
33036 client_major_version,
33037 client_minor_version,
33038 };
33039 let cookie = self.send_reply_request(request).with_span(span);
33040 cookie
33041 }
33042 #[cfg(feature = "xfixes")]
33043 fn xfixes_query_version_immediate<'this>(
33044 &'this mut self,
33045 client_major_version: types::Card32,
33046 client_minor_version: types::Card32,
33047 ) -> futures::CheckedSendRequest<'this, Self, types::xfixes::QueryVersionReply> {
33048 let request = types::xfixes::QueryVersionRequest {
33049 client_major_version,
33050 client_minor_version,
33051 };
33052 let cookie = self.send_reply_request(request);
33053 let res: futures::CheckedSendRequest<'this, Self, types::xfixes::QueryVersionReply> =
33054 cookie.into();
33055 res
33056 }
33057 #[cfg(feature = "xfixes")]
33058 fn xfixes_change_save_set<'this>(
33059 &'this mut self,
33060 mode: types::SaveSetMode,
33061 target: types::SaveSetTarget,
33062 map: types::SaveSetMapping,
33063 window: types::xproto::Window,
33064 ) -> futures::SendRequest<'this, Self, ()> {
33065 let span = tracing::info_span!(
33066 "xfixes_change_save_set",
33067 mode = ?mode,
33068 target = ?target,
33069 map = ?map,
33070 window = ?window,
33071 );
33072 let request = types::xfixes::ChangeSaveSetRequest {
33073 mode,
33074 target,
33075 map,
33076 window,
33077 };
33078 let cookie = self.send_void_request(request, true).with_span(span);
33079 cookie
33080 }
33081 #[cfg(feature = "xfixes")]
33082 fn xfixes_change_save_set_checked<'this>(
33083 &'this mut self,
33084 mode: types::SaveSetMode,
33085 target: types::SaveSetTarget,
33086 map: types::SaveSetMapping,
33087 window: types::xproto::Window,
33088 ) -> futures::CheckedSendRequest<'this, Self, ()> {
33089 let request = types::xfixes::ChangeSaveSetRequest {
33090 mode,
33091 target,
33092 map,
33093 window,
33094 };
33095 let cookie = self.send_void_request(request, false);
33096 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
33097 res
33098 }
33099 #[cfg(feature = "xfixes")]
33100 fn xfixes_select_selection_input<'this>(
33101 &'this mut self,
33102 window: types::xproto::Window,
33103 selection: types::Atom,
33104 event_mask: impl Into<types::SelectionEventMask>,
33105 ) -> futures::SendRequest<'this, Self, ()> {
33106 let span = tracing::info_span!(
33107 "xfixes_select_selection_input",
33108 window = ?window,
33109 selection = ?selection,
33110 );
33111 let request = types::xfixes::SelectSelectionInputRequest {
33112 window,
33113 selection,
33114 event_mask: Into::<u32>::into(event_mask.into()) as _,
33115 };
33116 let cookie = self.send_void_request(request, true).with_span(span);
33117 cookie
33118 }
33119 #[cfg(feature = "xfixes")]
33120 fn xfixes_select_selection_input_checked<'this>(
33121 &'this mut self,
33122 window: types::xproto::Window,
33123 selection: types::Atom,
33124 event_mask: impl Into<types::SelectionEventMask>,
33125 ) -> futures::CheckedSendRequest<'this, Self, ()> {
33126 let request = types::xfixes::SelectSelectionInputRequest {
33127 window,
33128 selection,
33129 event_mask: Into::<u32>::into(event_mask.into()) as _,
33130 };
33131 let cookie = self.send_void_request(request, false);
33132 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
33133 res
33134 }
33135 #[cfg(feature = "xfixes")]
33136 fn xfixes_select_cursor_input<'this>(
33137 &'this mut self,
33138 window: types::xproto::Window,
33139 event_mask: impl Into<types::CursorNotifyMask>,
33140 ) -> futures::SendRequest<'this, Self, ()> {
33141 let span = tracing::info_span!(
33142 "xfixes_select_cursor_input",
33143 window = ?window,
33144 );
33145 let request = types::xfixes::SelectCursorInputRequest {
33146 window,
33147 event_mask: Into::<u32>::into(event_mask.into()) as _,
33148 };
33149 let cookie = self.send_void_request(request, true).with_span(span);
33150 cookie
33151 }
33152 #[cfg(feature = "xfixes")]
33153 fn xfixes_select_cursor_input_checked<'this>(
33154 &'this mut self,
33155 window: types::xproto::Window,
33156 event_mask: impl Into<types::CursorNotifyMask>,
33157 ) -> futures::CheckedSendRequest<'this, Self, ()> {
33158 let request = types::xfixes::SelectCursorInputRequest {
33159 window,
33160 event_mask: Into::<u32>::into(event_mask.into()) as _,
33161 };
33162 let cookie = self.send_void_request(request, false);
33163 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
33164 res
33165 }
33166 #[cfg(feature = "xfixes")]
33167 fn xfixes_get_cursor_image<'this>(
33168 &'this mut self,
33169 ) -> futures::SendRequest<'this, Self, types::xfixes::GetCursorImageReply> {
33170 let span = tracing::info_span!("xfixes_get_cursor_image",);
33171 let request = types::xfixes::GetCursorImageRequest {};
33172 let cookie = self.send_reply_request(request).with_span(span);
33173 cookie
33174 }
33175 #[cfg(feature = "xfixes")]
33176 fn xfixes_get_cursor_image_immediate<'this>(
33177 &'this mut self,
33178 ) -> futures::CheckedSendRequest<'this, Self, types::xfixes::GetCursorImageReply> {
33179 let request = types::xfixes::GetCursorImageRequest {};
33180 let cookie = self.send_reply_request(request);
33181 let res: futures::CheckedSendRequest<'this, Self, types::xfixes::GetCursorImageReply> =
33182 cookie.into();
33183 res
33184 }
33185 #[cfg(feature = "xfixes")]
33186 fn xfixes_create_region<'this>(
33187 &'this mut self,
33188 region: types::Region,
33189 rectangles: impl AsRef<[types::Rectangle]>,
33190 ) -> futures::SendRequest<'this, Self, ()> {
33191 let span = tracing::info_span!(
33192 "xfixes_create_region",
33193 region = ?region,
33194 );
33195 let request = types::xfixes::CreateRegionRequest {
33196 region,
33197 rectangles: Cow::Borrowed(rectangles.as_ref()),
33198 };
33199 let cookie = self.send_void_request(request, true).with_span(span);
33200 cookie
33201 }
33202 #[cfg(feature = "xfixes")]
33203 fn xfixes_create_region_checked<'this>(
33204 &'this mut self,
33205 region: types::Region,
33206 rectangles: impl AsRef<[types::Rectangle]>,
33207 ) -> futures::CheckedSendRequest<'this, Self, ()> {
33208 let request = types::xfixes::CreateRegionRequest {
33209 region,
33210 rectangles: Cow::Borrowed(rectangles.as_ref()),
33211 };
33212 let cookie = self.send_void_request(request, false);
33213 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
33214 res
33215 }
33216 #[cfg(feature = "xfixes")]
33217 fn xfixes_create_region_from_bitmap<'this>(
33218 &'this mut self,
33219 region: types::Region,
33220 bitmap: types::xproto::Pixmap,
33221 ) -> futures::SendRequest<'this, Self, ()> {
33222 let span = tracing::info_span!(
33223 "xfixes_create_region_from_bitmap",
33224 region = ?region,
33225 bitmap = ?bitmap,
33226 );
33227 let request = types::xfixes::CreateRegionFromBitmapRequest { region, bitmap };
33228 let cookie = self.send_void_request(request, true).with_span(span);
33229 cookie
33230 }
33231 #[cfg(feature = "xfixes")]
33232 fn xfixes_create_region_from_bitmap_checked<'this>(
33233 &'this mut self,
33234 region: types::Region,
33235 bitmap: types::xproto::Pixmap,
33236 ) -> futures::CheckedSendRequest<'this, Self, ()> {
33237 let request = types::xfixes::CreateRegionFromBitmapRequest { region, bitmap };
33238 let cookie = self.send_void_request(request, false);
33239 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
33240 res
33241 }
33242 #[cfg(feature = "xfixes")]
33243 fn xfixes_create_region_from_window<'this>(
33244 &'this mut self,
33245 region: types::Region,
33246 window: types::xproto::Window,
33247 kind: types::SK,
33248 ) -> futures::SendRequest<'this, Self, ()> {
33249 let span = tracing::info_span!(
33250 "xfixes_create_region_from_window",
33251 region = ?region,
33252 window = ?window,
33253 kind = ?kind,
33254 );
33255 let request = types::xfixes::CreateRegionFromWindowRequest {
33256 region,
33257 window,
33258 kind,
33259 };
33260 let cookie = self.send_void_request(request, true).with_span(span);
33261 cookie
33262 }
33263 #[cfg(feature = "xfixes")]
33264 fn xfixes_create_region_from_window_checked<'this>(
33265 &'this mut self,
33266 region: types::Region,
33267 window: types::xproto::Window,
33268 kind: types::SK,
33269 ) -> futures::CheckedSendRequest<'this, Self, ()> {
33270 let request = types::xfixes::CreateRegionFromWindowRequest {
33271 region,
33272 window,
33273 kind,
33274 };
33275 let cookie = self.send_void_request(request, false);
33276 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
33277 res
33278 }
33279 #[cfg(feature = "xfixes")]
33280 fn xfixes_create_region_from_gc<'this>(
33281 &'this mut self,
33282 region: types::Region,
33283 gc: types::Gcontext,
33284 ) -> futures::SendRequest<'this, Self, ()> {
33285 let span = tracing::info_span!(
33286 "xfixes_create_region_from_gc",
33287 region = ?region,
33288 gc = ?gc,
33289 );
33290 let request = types::xfixes::CreateRegionFromGCRequest { region, gc };
33291 let cookie = self.send_void_request(request, true).with_span(span);
33292 cookie
33293 }
33294 #[cfg(feature = "xfixes")]
33295 fn xfixes_create_region_from_gc_checked<'this>(
33296 &'this mut self,
33297 region: types::Region,
33298 gc: types::Gcontext,
33299 ) -> futures::CheckedSendRequest<'this, Self, ()> {
33300 let request = types::xfixes::CreateRegionFromGCRequest { region, gc };
33301 let cookie = self.send_void_request(request, false);
33302 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
33303 res
33304 }
33305 #[cfg(feature = "xfixes")]
33306 fn xfixes_create_region_from_picture<'this>(
33307 &'this mut self,
33308 region: types::Region,
33309 picture: types::Picture,
33310 ) -> futures::SendRequest<'this, Self, ()> {
33311 let span = tracing::info_span!(
33312 "xfixes_create_region_from_picture",
33313 region = ?region,
33314 picture = ?picture,
33315 );
33316 let request = types::xfixes::CreateRegionFromPictureRequest { region, picture };
33317 let cookie = self.send_void_request(request, true).with_span(span);
33318 cookie
33319 }
33320 #[cfg(feature = "xfixes")]
33321 fn xfixes_create_region_from_picture_checked<'this>(
33322 &'this mut self,
33323 region: types::Region,
33324 picture: types::Picture,
33325 ) -> futures::CheckedSendRequest<'this, Self, ()> {
33326 let request = types::xfixes::CreateRegionFromPictureRequest { region, picture };
33327 let cookie = self.send_void_request(request, false);
33328 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
33329 res
33330 }
33331 #[cfg(feature = "xfixes")]
33332 fn xfixes_destroy_region<'this>(
33333 &'this mut self,
33334 region: types::Region,
33335 ) -> futures::SendRequest<'this, Self, ()> {
33336 let span = tracing::info_span!(
33337 "xfixes_destroy_region",
33338 region = ?region,
33339 );
33340 let request = types::xfixes::DestroyRegionRequest { region };
33341 let cookie = self.send_void_request(request, true).with_span(span);
33342 cookie
33343 }
33344 #[cfg(feature = "xfixes")]
33345 fn xfixes_destroy_region_checked<'this>(
33346 &'this mut self,
33347 region: types::Region,
33348 ) -> futures::CheckedSendRequest<'this, Self, ()> {
33349 let request = types::xfixes::DestroyRegionRequest { region };
33350 let cookie = self.send_void_request(request, false);
33351 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
33352 res
33353 }
33354 #[cfg(feature = "xfixes")]
33355 fn xfixes_set_region<'this>(
33356 &'this mut self,
33357 region: types::Region,
33358 rectangles: impl AsRef<[types::Rectangle]>,
33359 ) -> futures::SendRequest<'this, Self, ()> {
33360 let span = tracing::info_span!(
33361 "xfixes_set_region",
33362 region = ?region,
33363 );
33364 let request = types::xfixes::SetRegionRequest {
33365 region,
33366 rectangles: Cow::Borrowed(rectangles.as_ref()),
33367 };
33368 let cookie = self.send_void_request(request, true).with_span(span);
33369 cookie
33370 }
33371 #[cfg(feature = "xfixes")]
33372 fn xfixes_set_region_checked<'this>(
33373 &'this mut self,
33374 region: types::Region,
33375 rectangles: impl AsRef<[types::Rectangle]>,
33376 ) -> futures::CheckedSendRequest<'this, Self, ()> {
33377 let request = types::xfixes::SetRegionRequest {
33378 region,
33379 rectangles: Cow::Borrowed(rectangles.as_ref()),
33380 };
33381 let cookie = self.send_void_request(request, false);
33382 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
33383 res
33384 }
33385 #[cfg(feature = "xfixes")]
33386 fn xfixes_copy_region<'this>(
33387 &'this mut self,
33388 source: types::Region,
33389 destination: types::Region,
33390 ) -> futures::SendRequest<'this, Self, ()> {
33391 let span = tracing::info_span!(
33392 "xfixes_copy_region",
33393 source = ?source,
33394 destination = ?destination,
33395 );
33396 let request = types::xfixes::CopyRegionRequest {
33397 source,
33398 destination,
33399 };
33400 let cookie = self.send_void_request(request, true).with_span(span);
33401 cookie
33402 }
33403 #[cfg(feature = "xfixes")]
33404 fn xfixes_copy_region_checked<'this>(
33405 &'this mut self,
33406 source: types::Region,
33407 destination: types::Region,
33408 ) -> futures::CheckedSendRequest<'this, Self, ()> {
33409 let request = types::xfixes::CopyRegionRequest {
33410 source,
33411 destination,
33412 };
33413 let cookie = self.send_void_request(request, false);
33414 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
33415 res
33416 }
33417 #[cfg(feature = "xfixes")]
33418 fn xfixes_union_region<'this>(
33419 &'this mut self,
33420 source1: types::Region,
33421 source2: types::Region,
33422 destination: types::Region,
33423 ) -> futures::SendRequest<'this, Self, ()> {
33424 let span = tracing::info_span!(
33425 "xfixes_union_region",
33426 source1 = ?source1,
33427 source2 = ?source2,
33428 destination = ?destination,
33429 );
33430 let request = types::xfixes::UnionRegionRequest {
33431 source1,
33432 source2,
33433 destination,
33434 };
33435 let cookie = self.send_void_request(request, true).with_span(span);
33436 cookie
33437 }
33438 #[cfg(feature = "xfixes")]
33439 fn xfixes_union_region_checked<'this>(
33440 &'this mut self,
33441 source1: types::Region,
33442 source2: types::Region,
33443 destination: types::Region,
33444 ) -> futures::CheckedSendRequest<'this, Self, ()> {
33445 let request = types::xfixes::UnionRegionRequest {
33446 source1,
33447 source2,
33448 destination,
33449 };
33450 let cookie = self.send_void_request(request, false);
33451 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
33452 res
33453 }
33454 #[cfg(feature = "xfixes")]
33455 fn xfixes_intersect_region<'this>(
33456 &'this mut self,
33457 source1: types::Region,
33458 source2: types::Region,
33459 destination: types::Region,
33460 ) -> futures::SendRequest<'this, Self, ()> {
33461 let span = tracing::info_span!(
33462 "xfixes_intersect_region",
33463 source1 = ?source1,
33464 source2 = ?source2,
33465 destination = ?destination,
33466 );
33467 let request = types::xfixes::IntersectRegionRequest {
33468 source1,
33469 source2,
33470 destination,
33471 };
33472 let cookie = self.send_void_request(request, true).with_span(span);
33473 cookie
33474 }
33475 #[cfg(feature = "xfixes")]
33476 fn xfixes_intersect_region_checked<'this>(
33477 &'this mut self,
33478 source1: types::Region,
33479 source2: types::Region,
33480 destination: types::Region,
33481 ) -> futures::CheckedSendRequest<'this, Self, ()> {
33482 let request = types::xfixes::IntersectRegionRequest {
33483 source1,
33484 source2,
33485 destination,
33486 };
33487 let cookie = self.send_void_request(request, false);
33488 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
33489 res
33490 }
33491 #[cfg(feature = "xfixes")]
33492 fn xfixes_subtract_region<'this>(
33493 &'this mut self,
33494 source1: types::Region,
33495 source2: types::Region,
33496 destination: types::Region,
33497 ) -> futures::SendRequest<'this, Self, ()> {
33498 let span = tracing::info_span!(
33499 "xfixes_subtract_region",
33500 source1 = ?source1,
33501 source2 = ?source2,
33502 destination = ?destination,
33503 );
33504 let request = types::xfixes::SubtractRegionRequest {
33505 source1,
33506 source2,
33507 destination,
33508 };
33509 let cookie = self.send_void_request(request, true).with_span(span);
33510 cookie
33511 }
33512 #[cfg(feature = "xfixes")]
33513 fn xfixes_subtract_region_checked<'this>(
33514 &'this mut self,
33515 source1: types::Region,
33516 source2: types::Region,
33517 destination: types::Region,
33518 ) -> futures::CheckedSendRequest<'this, Self, ()> {
33519 let request = types::xfixes::SubtractRegionRequest {
33520 source1,
33521 source2,
33522 destination,
33523 };
33524 let cookie = self.send_void_request(request, false);
33525 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
33526 res
33527 }
33528 #[cfg(feature = "xfixes")]
33529 fn xfixes_invert_region<'this>(
33530 &'this mut self,
33531 source: types::Region,
33532 bounds: types::Rectangle,
33533 destination: types::Region,
33534 ) -> futures::SendRequest<'this, Self, ()> {
33535 let span = tracing::info_span!(
33536 "xfixes_invert_region",
33537 source = ?source,
33538 bounds = ?bounds,
33539 destination = ?destination,
33540 );
33541 let request = types::xfixes::InvertRegionRequest {
33542 source,
33543 bounds,
33544 destination,
33545 };
33546 let cookie = self.send_void_request(request, true).with_span(span);
33547 cookie
33548 }
33549 #[cfg(feature = "xfixes")]
33550 fn xfixes_invert_region_checked<'this>(
33551 &'this mut self,
33552 source: types::Region,
33553 bounds: types::Rectangle,
33554 destination: types::Region,
33555 ) -> futures::CheckedSendRequest<'this, Self, ()> {
33556 let request = types::xfixes::InvertRegionRequest {
33557 source,
33558 bounds,
33559 destination,
33560 };
33561 let cookie = self.send_void_request(request, false);
33562 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
33563 res
33564 }
33565 #[cfg(feature = "xfixes")]
33566 fn xfixes_translate_region<'this>(
33567 &'this mut self,
33568 region: types::Region,
33569 dx: types::Int16,
33570 dy: types::Int16,
33571 ) -> futures::SendRequest<'this, Self, ()> {
33572 let span = tracing::info_span!(
33573 "xfixes_translate_region",
33574 region = ?region,
33575 dx = ?dx,
33576 dy = ?dy,
33577 );
33578 let request = types::xfixes::TranslateRegionRequest { region, dx, dy };
33579 let cookie = self.send_void_request(request, true).with_span(span);
33580 cookie
33581 }
33582 #[cfg(feature = "xfixes")]
33583 fn xfixes_translate_region_checked<'this>(
33584 &'this mut self,
33585 region: types::Region,
33586 dx: types::Int16,
33587 dy: types::Int16,
33588 ) -> futures::CheckedSendRequest<'this, Self, ()> {
33589 let request = types::xfixes::TranslateRegionRequest { region, dx, dy };
33590 let cookie = self.send_void_request(request, false);
33591 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
33592 res
33593 }
33594 #[cfg(feature = "xfixes")]
33595 fn xfixes_region_extents<'this>(
33596 &'this mut self,
33597 source: types::Region,
33598 destination: types::Region,
33599 ) -> futures::SendRequest<'this, Self, ()> {
33600 let span = tracing::info_span!(
33601 "xfixes_region_extents",
33602 source = ?source,
33603 destination = ?destination,
33604 );
33605 let request = types::xfixes::RegionExtentsRequest {
33606 source,
33607 destination,
33608 };
33609 let cookie = self.send_void_request(request, true).with_span(span);
33610 cookie
33611 }
33612 #[cfg(feature = "xfixes")]
33613 fn xfixes_region_extents_checked<'this>(
33614 &'this mut self,
33615 source: types::Region,
33616 destination: types::Region,
33617 ) -> futures::CheckedSendRequest<'this, Self, ()> {
33618 let request = types::xfixes::RegionExtentsRequest {
33619 source,
33620 destination,
33621 };
33622 let cookie = self.send_void_request(request, false);
33623 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
33624 res
33625 }
33626 #[cfg(feature = "xfixes")]
33627 fn xfixes_fetch_region<'this>(
33628 &'this mut self,
33629 region: types::Region,
33630 ) -> futures::SendRequest<'this, Self, types::xfixes::FetchRegionReply> {
33631 let span = tracing::info_span!(
33632 "xfixes_fetch_region",
33633 region = ?region,
33634 );
33635 let request = types::xfixes::FetchRegionRequest { region };
33636 let cookie = self.send_reply_request(request).with_span(span);
33637 cookie
33638 }
33639 #[cfg(feature = "xfixes")]
33640 fn xfixes_fetch_region_immediate<'this>(
33641 &'this mut self,
33642 region: types::Region,
33643 ) -> futures::CheckedSendRequest<'this, Self, types::xfixes::FetchRegionReply> {
33644 let request = types::xfixes::FetchRegionRequest { region };
33645 let cookie = self.send_reply_request(request);
33646 let res: futures::CheckedSendRequest<'this, Self, types::xfixes::FetchRegionReply> =
33647 cookie.into();
33648 res
33649 }
33650 #[cfg(feature = "xfixes")]
33651 fn xfixes_set_gc_clip_region<'this>(
33652 &'this mut self,
33653 gc: types::Gcontext,
33654 region: impl Into<types::Region>,
33655 x_origin: types::Int16,
33656 y_origin: types::Int16,
33657 ) -> futures::SendRequest<'this, Self, ()> {
33658 let span = tracing::info_span!(
33659 "xfixes_set_gc_clip_region",
33660 gc = ?gc,
33661 x_origin = ?x_origin,
33662 y_origin = ?y_origin,
33663 );
33664 let request = types::xfixes::SetGCClipRegionRequest {
33665 gc,
33666 region: Into::<u32>::into(region.into()) as _,
33667 x_origin,
33668 y_origin,
33669 };
33670 let cookie = self.send_void_request(request, true).with_span(span);
33671 cookie
33672 }
33673 #[cfg(feature = "xfixes")]
33674 fn xfixes_set_gc_clip_region_checked<'this>(
33675 &'this mut self,
33676 gc: types::Gcontext,
33677 region: impl Into<types::Region>,
33678 x_origin: types::Int16,
33679 y_origin: types::Int16,
33680 ) -> futures::CheckedSendRequest<'this, Self, ()> {
33681 let request = types::xfixes::SetGCClipRegionRequest {
33682 gc,
33683 region: Into::<u32>::into(region.into()) as _,
33684 x_origin,
33685 y_origin,
33686 };
33687 let cookie = self.send_void_request(request, false);
33688 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
33689 res
33690 }
33691 #[cfg(feature = "xfixes")]
33692 fn xfixes_set_window_shape_region<'this>(
33693 &'this mut self,
33694 dest: types::xproto::Window,
33695 dest_kind: types::SK,
33696 x_offset: types::Int16,
33697 y_offset: types::Int16,
33698 region: impl Into<types::Region>,
33699 ) -> futures::SendRequest<'this, Self, ()> {
33700 let span = tracing::info_span!(
33701 "xfixes_set_window_shape_region",
33702 dest = ?dest,
33703 dest_kind = ?dest_kind,
33704 x_offset = ?x_offset,
33705 y_offset = ?y_offset,
33706 );
33707 let request = types::xfixes::SetWindowShapeRegionRequest {
33708 dest,
33709 dest_kind,
33710 x_offset,
33711 y_offset,
33712 region: Into::<u32>::into(region.into()) as _,
33713 };
33714 let cookie = self.send_void_request(request, true).with_span(span);
33715 cookie
33716 }
33717 #[cfg(feature = "xfixes")]
33718 fn xfixes_set_window_shape_region_checked<'this>(
33719 &'this mut self,
33720 dest: types::xproto::Window,
33721 dest_kind: types::SK,
33722 x_offset: types::Int16,
33723 y_offset: types::Int16,
33724 region: impl Into<types::Region>,
33725 ) -> futures::CheckedSendRequest<'this, Self, ()> {
33726 let request = types::xfixes::SetWindowShapeRegionRequest {
33727 dest,
33728 dest_kind,
33729 x_offset,
33730 y_offset,
33731 region: Into::<u32>::into(region.into()) as _,
33732 };
33733 let cookie = self.send_void_request(request, false);
33734 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
33735 res
33736 }
33737 #[cfg(feature = "xfixes")]
33738 fn xfixes_set_picture_clip_region<'this>(
33739 &'this mut self,
33740 picture: types::Picture,
33741 region: impl Into<types::Region>,
33742 x_origin: types::Int16,
33743 y_origin: types::Int16,
33744 ) -> futures::SendRequest<'this, Self, ()> {
33745 let span = tracing::info_span!(
33746 "xfixes_set_picture_clip_region",
33747 picture = ?picture,
33748 x_origin = ?x_origin,
33749 y_origin = ?y_origin,
33750 );
33751 let request = types::xfixes::SetPictureClipRegionRequest {
33752 picture,
33753 region: Into::<u32>::into(region.into()) as _,
33754 x_origin,
33755 y_origin,
33756 };
33757 let cookie = self.send_void_request(request, true).with_span(span);
33758 cookie
33759 }
33760 #[cfg(feature = "xfixes")]
33761 fn xfixes_set_picture_clip_region_checked<'this>(
33762 &'this mut self,
33763 picture: types::Picture,
33764 region: impl Into<types::Region>,
33765 x_origin: types::Int16,
33766 y_origin: types::Int16,
33767 ) -> futures::CheckedSendRequest<'this, Self, ()> {
33768 let request = types::xfixes::SetPictureClipRegionRequest {
33769 picture,
33770 region: Into::<u32>::into(region.into()) as _,
33771 x_origin,
33772 y_origin,
33773 };
33774 let cookie = self.send_void_request(request, false);
33775 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
33776 res
33777 }
33778 #[cfg(feature = "xfixes")]
33779 fn xfixes_set_cursor_name<'this>(
33780 &'this mut self,
33781 cursor: types::xproto::Cursor,
33782 name: impl AsRef<[types::Char]>,
33783 ) -> futures::SendRequest<'this, Self, ()> {
33784 let span = tracing::info_span!(
33785 "xfixes_set_cursor_name",
33786 cursor = ?cursor,
33787 );
33788 let request = types::xfixes::SetCursorNameRequest {
33789 cursor,
33790 name: Cow::Borrowed(name.as_ref()),
33791 };
33792 let cookie = self.send_void_request(request, true).with_span(span);
33793 cookie
33794 }
33795 #[cfg(feature = "xfixes")]
33796 fn xfixes_set_cursor_name_checked<'this>(
33797 &'this mut self,
33798 cursor: types::xproto::Cursor,
33799 name: impl AsRef<[types::Char]>,
33800 ) -> futures::CheckedSendRequest<'this, Self, ()> {
33801 let request = types::xfixes::SetCursorNameRequest {
33802 cursor,
33803 name: Cow::Borrowed(name.as_ref()),
33804 };
33805 let cookie = self.send_void_request(request, false);
33806 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
33807 res
33808 }
33809 #[cfg(feature = "xfixes")]
33810 fn xfixes_get_cursor_name<'this>(
33811 &'this mut self,
33812 cursor: types::xproto::Cursor,
33813 ) -> futures::SendRequest<'this, Self, types::xfixes::GetCursorNameReply> {
33814 let span = tracing::info_span!(
33815 "xfixes_get_cursor_name",
33816 cursor = ?cursor,
33817 );
33818 let request = types::xfixes::GetCursorNameRequest { cursor };
33819 let cookie = self.send_reply_request(request).with_span(span);
33820 cookie
33821 }
33822 #[cfg(feature = "xfixes")]
33823 fn xfixes_get_cursor_name_immediate<'this>(
33824 &'this mut self,
33825 cursor: types::xproto::Cursor,
33826 ) -> futures::CheckedSendRequest<'this, Self, types::xfixes::GetCursorNameReply> {
33827 let request = types::xfixes::GetCursorNameRequest { cursor };
33828 let cookie = self.send_reply_request(request);
33829 let res: futures::CheckedSendRequest<'this, Self, types::xfixes::GetCursorNameReply> =
33830 cookie.into();
33831 res
33832 }
33833 #[cfg(feature = "xfixes")]
33834 fn xfixes_get_cursor_image_and_name<'this>(
33835 &'this mut self,
33836 ) -> futures::SendRequest<'this, Self, types::xfixes::GetCursorImageAndNameReply> {
33837 let span = tracing::info_span!("xfixes_get_cursor_image_and_name",);
33838 let request = types::xfixes::GetCursorImageAndNameRequest {};
33839 let cookie = self.send_reply_request(request).with_span(span);
33840 cookie
33841 }
33842 #[cfg(feature = "xfixes")]
33843 fn xfixes_get_cursor_image_and_name_immediate<'this>(
33844 &'this mut self,
33845 ) -> futures::CheckedSendRequest<'this, Self, types::xfixes::GetCursorImageAndNameReply> {
33846 let request = types::xfixes::GetCursorImageAndNameRequest {};
33847 let cookie = self.send_reply_request(request);
33848 let res: futures::CheckedSendRequest<
33849 'this,
33850 Self,
33851 types::xfixes::GetCursorImageAndNameReply,
33852 > = cookie.into();
33853 res
33854 }
33855 #[cfg(feature = "xfixes")]
33856 fn xfixes_change_cursor<'this>(
33857 &'this mut self,
33858 source: types::xproto::Cursor,
33859 destination: types::xproto::Cursor,
33860 ) -> futures::SendRequest<'this, Self, ()> {
33861 let span = tracing::info_span!(
33862 "xfixes_change_cursor",
33863 source = ?source,
33864 destination = ?destination,
33865 );
33866 let request = types::xfixes::ChangeCursorRequest {
33867 source,
33868 destination,
33869 };
33870 let cookie = self.send_void_request(request, true).with_span(span);
33871 cookie
33872 }
33873 #[cfg(feature = "xfixes")]
33874 fn xfixes_change_cursor_checked<'this>(
33875 &'this mut self,
33876 source: types::xproto::Cursor,
33877 destination: types::xproto::Cursor,
33878 ) -> futures::CheckedSendRequest<'this, Self, ()> {
33879 let request = types::xfixes::ChangeCursorRequest {
33880 source,
33881 destination,
33882 };
33883 let cookie = self.send_void_request(request, false);
33884 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
33885 res
33886 }
33887 #[cfg(feature = "xfixes")]
33888 fn xfixes_change_cursor_by_name<'this>(
33889 &'this mut self,
33890 src: types::xproto::Cursor,
33891 name: impl AsRef<[types::Char]>,
33892 ) -> futures::SendRequest<'this, Self, ()> {
33893 let span = tracing::info_span!(
33894 "xfixes_change_cursor_by_name",
33895 src = ?src,
33896 );
33897 let request = types::xfixes::ChangeCursorByNameRequest {
33898 src,
33899 name: Cow::Borrowed(name.as_ref()),
33900 };
33901 let cookie = self.send_void_request(request, true).with_span(span);
33902 cookie
33903 }
33904 #[cfg(feature = "xfixes")]
33905 fn xfixes_change_cursor_by_name_checked<'this>(
33906 &'this mut self,
33907 src: types::xproto::Cursor,
33908 name: impl AsRef<[types::Char]>,
33909 ) -> futures::CheckedSendRequest<'this, Self, ()> {
33910 let request = types::xfixes::ChangeCursorByNameRequest {
33911 src,
33912 name: Cow::Borrowed(name.as_ref()),
33913 };
33914 let cookie = self.send_void_request(request, false);
33915 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
33916 res
33917 }
33918 #[cfg(feature = "xfixes")]
33919 fn xfixes_expand_region<'this>(
33920 &'this mut self,
33921 source: types::Region,
33922 destination: types::Region,
33923 left: types::Card16,
33924 right: types::Card16,
33925 top: types::Card16,
33926 bottom: types::Card16,
33927 ) -> futures::SendRequest<'this, Self, ()> {
33928 let span = tracing::info_span!(
33929 "xfixes_expand_region",
33930 source = ?source,
33931 destination = ?destination,
33932 left = ?left,
33933 right = ?right,
33934 top = ?top,
33935 bottom = ?bottom,
33936 );
33937 let request = types::xfixes::ExpandRegionRequest {
33938 source,
33939 destination,
33940 left,
33941 right,
33942 top,
33943 bottom,
33944 };
33945 let cookie = self.send_void_request(request, true).with_span(span);
33946 cookie
33947 }
33948 #[cfg(feature = "xfixes")]
33949 fn xfixes_expand_region_checked<'this>(
33950 &'this mut self,
33951 source: types::Region,
33952 destination: types::Region,
33953 left: types::Card16,
33954 right: types::Card16,
33955 top: types::Card16,
33956 bottom: types::Card16,
33957 ) -> futures::CheckedSendRequest<'this, Self, ()> {
33958 let request = types::xfixes::ExpandRegionRequest {
33959 source,
33960 destination,
33961 left,
33962 right,
33963 top,
33964 bottom,
33965 };
33966 let cookie = self.send_void_request(request, false);
33967 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
33968 res
33969 }
33970 #[cfg(feature = "xfixes")]
33971 fn xfixes_hide_cursor<'this>(
33972 &'this mut self,
33973 window: types::xproto::Window,
33974 ) -> futures::SendRequest<'this, Self, ()> {
33975 let span = tracing::info_span!(
33976 "xfixes_hide_cursor",
33977 window = ?window,
33978 );
33979 let request = types::xfixes::HideCursorRequest { window };
33980 let cookie = self.send_void_request(request, true).with_span(span);
33981 cookie
33982 }
33983 #[cfg(feature = "xfixes")]
33984 fn xfixes_hide_cursor_checked<'this>(
33985 &'this mut self,
33986 window: types::xproto::Window,
33987 ) -> futures::CheckedSendRequest<'this, Self, ()> {
33988 let request = types::xfixes::HideCursorRequest { window };
33989 let cookie = self.send_void_request(request, false);
33990 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
33991 res
33992 }
33993 #[cfg(feature = "xfixes")]
33994 fn xfixes_show_cursor<'this>(
33995 &'this mut self,
33996 window: types::xproto::Window,
33997 ) -> futures::SendRequest<'this, Self, ()> {
33998 let span = tracing::info_span!(
33999 "xfixes_show_cursor",
34000 window = ?window,
34001 );
34002 let request = types::xfixes::ShowCursorRequest { window };
34003 let cookie = self.send_void_request(request, true).with_span(span);
34004 cookie
34005 }
34006 #[cfg(feature = "xfixes")]
34007 fn xfixes_show_cursor_checked<'this>(
34008 &'this mut self,
34009 window: types::xproto::Window,
34010 ) -> futures::CheckedSendRequest<'this, Self, ()> {
34011 let request = types::xfixes::ShowCursorRequest { window };
34012 let cookie = self.send_void_request(request, false);
34013 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
34014 res
34015 }
34016 #[cfg(feature = "xfixes")]
34017 fn xfixes_create_pointer_barrier<'this>(
34018 &'this mut self,
34019 barrier: types::Barrier,
34020 window: types::xproto::Window,
34021 x1: types::Card16,
34022 y1: types::Card16,
34023 x2: types::Card16,
34024 y2: types::Card16,
34025 directions: impl Into<types::BarrierDirections>,
34026 devices: impl AsRef<[types::Card16]>,
34027 ) -> futures::SendRequest<'this, Self, ()> {
34028 let span = tracing::info_span!(
34029 "xfixes_create_pointer_barrier",
34030 barrier = ?barrier,
34031 window = ?window,
34032 x1 = ?x1,
34033 y1 = ?y1,
34034 x2 = ?x2,
34035 y2 = ?y2,
34036 );
34037 let request = types::xfixes::CreatePointerBarrierRequest {
34038 barrier,
34039 window,
34040 x1,
34041 y1,
34042 x2,
34043 y2,
34044 directions: Into::<u32>::into(directions.into()) as _,
34045 devices: Cow::Borrowed(devices.as_ref()),
34046 };
34047 let cookie = self.send_void_request(request, true).with_span(span);
34048 cookie
34049 }
34050 #[cfg(feature = "xfixes")]
34051 fn xfixes_create_pointer_barrier_checked<'this>(
34052 &'this mut self,
34053 barrier: types::Barrier,
34054 window: types::xproto::Window,
34055 x1: types::Card16,
34056 y1: types::Card16,
34057 x2: types::Card16,
34058 y2: types::Card16,
34059 directions: impl Into<types::BarrierDirections>,
34060 devices: impl AsRef<[types::Card16]>,
34061 ) -> futures::CheckedSendRequest<'this, Self, ()> {
34062 let request = types::xfixes::CreatePointerBarrierRequest {
34063 barrier,
34064 window,
34065 x1,
34066 y1,
34067 x2,
34068 y2,
34069 directions: Into::<u32>::into(directions.into()) as _,
34070 devices: Cow::Borrowed(devices.as_ref()),
34071 };
34072 let cookie = self.send_void_request(request, false);
34073 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
34074 res
34075 }
34076 #[cfg(feature = "xfixes")]
34077 fn xfixes_delete_pointer_barrier<'this>(
34078 &'this mut self,
34079 barrier: types::Barrier,
34080 ) -> futures::SendRequest<'this, Self, ()> {
34081 let span = tracing::info_span!(
34082 "xfixes_delete_pointer_barrier",
34083 barrier = ?barrier,
34084 );
34085 let request = types::xfixes::DeletePointerBarrierRequest { barrier };
34086 let cookie = self.send_void_request(request, true).with_span(span);
34087 cookie
34088 }
34089 #[cfg(feature = "xfixes")]
34090 fn xfixes_delete_pointer_barrier_checked<'this>(
34091 &'this mut self,
34092 barrier: types::Barrier,
34093 ) -> futures::CheckedSendRequest<'this, Self, ()> {
34094 let request = types::xfixes::DeletePointerBarrierRequest { barrier };
34095 let cookie = self.send_void_request(request, false);
34096 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
34097 res
34098 }
34099
34100 #[cfg(feature = "xinerama")]
34101 fn xinerama_query_version<'this>(
34102 &'this mut self,
34103 major: types::Card8,
34104 minor: types::Card8,
34105 ) -> futures::SendRequest<'this, Self, types::xinerama::QueryVersionReply> {
34106 let span = tracing::info_span!(
34107 "xinerama_query_version",
34108 major = ?major,
34109 minor = ?minor,
34110 );
34111 let request = types::xinerama::QueryVersionRequest { major, minor };
34112 let cookie = self.send_reply_request(request).with_span(span);
34113 cookie
34114 }
34115 #[cfg(feature = "xinerama")]
34116 fn xinerama_query_version_immediate<'this>(
34117 &'this mut self,
34118 major: types::Card8,
34119 minor: types::Card8,
34120 ) -> futures::CheckedSendRequest<'this, Self, types::xinerama::QueryVersionReply> {
34121 let request = types::xinerama::QueryVersionRequest { major, minor };
34122 let cookie = self.send_reply_request(request);
34123 let res: futures::CheckedSendRequest<'this, Self, types::xinerama::QueryVersionReply> =
34124 cookie.into();
34125 res
34126 }
34127 #[cfg(feature = "xinerama")]
34128 fn xinerama_get_state<'this>(
34129 &'this mut self,
34130 window: types::xproto::Window,
34131 ) -> futures::SendRequest<'this, Self, types::xinerama::GetStateReply> {
34132 let span = tracing::info_span!(
34133 "xinerama_get_state",
34134 window = ?window,
34135 );
34136 let request = types::xinerama::GetStateRequest { window };
34137 let cookie = self.send_reply_request(request).with_span(span);
34138 cookie
34139 }
34140 #[cfg(feature = "xinerama")]
34141 fn xinerama_get_state_immediate<'this>(
34142 &'this mut self,
34143 window: types::xproto::Window,
34144 ) -> futures::CheckedSendRequest<'this, Self, types::xinerama::GetStateReply> {
34145 let request = types::xinerama::GetStateRequest { window };
34146 let cookie = self.send_reply_request(request);
34147 let res: futures::CheckedSendRequest<'this, Self, types::xinerama::GetStateReply> =
34148 cookie.into();
34149 res
34150 }
34151 #[cfg(feature = "xinerama")]
34152 fn xinerama_get_screen_count<'this>(
34153 &'this mut self,
34154 window: types::xproto::Window,
34155 ) -> futures::SendRequest<'this, Self, types::xinerama::GetScreenCountReply> {
34156 let span = tracing::info_span!(
34157 "xinerama_get_screen_count",
34158 window = ?window,
34159 );
34160 let request = types::xinerama::GetScreenCountRequest { window };
34161 let cookie = self.send_reply_request(request).with_span(span);
34162 cookie
34163 }
34164 #[cfg(feature = "xinerama")]
34165 fn xinerama_get_screen_count_immediate<'this>(
34166 &'this mut self,
34167 window: types::xproto::Window,
34168 ) -> futures::CheckedSendRequest<'this, Self, types::xinerama::GetScreenCountReply> {
34169 let request = types::xinerama::GetScreenCountRequest { window };
34170 let cookie = self.send_reply_request(request);
34171 let res: futures::CheckedSendRequest<'this, Self, types::xinerama::GetScreenCountReply> =
34172 cookie.into();
34173 res
34174 }
34175 #[cfg(feature = "xinerama")]
34176 fn xinerama_get_screen_size<'this>(
34177 &'this mut self,
34178 window: types::xproto::Window,
34179 screen: types::Card32,
34180 ) -> futures::SendRequest<'this, Self, types::xinerama::GetScreenSizeReply> {
34181 let span = tracing::info_span!(
34182 "xinerama_get_screen_size",
34183 window = ?window,
34184 screen = ?screen,
34185 );
34186 let request = types::xinerama::GetScreenSizeRequest { window, screen };
34187 let cookie = self.send_reply_request(request).with_span(span);
34188 cookie
34189 }
34190 #[cfg(feature = "xinerama")]
34191 fn xinerama_get_screen_size_immediate<'this>(
34192 &'this mut self,
34193 window: types::xproto::Window,
34194 screen: types::Card32,
34195 ) -> futures::CheckedSendRequest<'this, Self, types::xinerama::GetScreenSizeReply> {
34196 let request = types::xinerama::GetScreenSizeRequest { window, screen };
34197 let cookie = self.send_reply_request(request);
34198 let res: futures::CheckedSendRequest<'this, Self, types::xinerama::GetScreenSizeReply> =
34199 cookie.into();
34200 res
34201 }
34202 #[cfg(feature = "xinerama")]
34203 fn xinerama_is_active<'this>(
34204 &'this mut self,
34205 ) -> futures::SendRequest<'this, Self, types::xinerama::IsActiveReply> {
34206 let span = tracing::info_span!("xinerama_is_active",);
34207 let request = types::xinerama::IsActiveRequest {};
34208 let cookie = self.send_reply_request(request).with_span(span);
34209 cookie
34210 }
34211 #[cfg(feature = "xinerama")]
34212 fn xinerama_is_active_immediate<'this>(
34213 &'this mut self,
34214 ) -> futures::CheckedSendRequest<'this, Self, types::xinerama::IsActiveReply> {
34215 let request = types::xinerama::IsActiveRequest {};
34216 let cookie = self.send_reply_request(request);
34217 let res: futures::CheckedSendRequest<'this, Self, types::xinerama::IsActiveReply> =
34218 cookie.into();
34219 res
34220 }
34221 #[cfg(feature = "xinerama")]
34222 fn xinerama_query_screens<'this>(
34223 &'this mut self,
34224 ) -> futures::SendRequest<'this, Self, types::xinerama::QueryScreensReply> {
34225 let span = tracing::info_span!("xinerama_query_screens",);
34226 let request = types::xinerama::QueryScreensRequest {};
34227 let cookie = self.send_reply_request(request).with_span(span);
34228 cookie
34229 }
34230 #[cfg(feature = "xinerama")]
34231 fn xinerama_query_screens_immediate<'this>(
34232 &'this mut self,
34233 ) -> futures::CheckedSendRequest<'this, Self, types::xinerama::QueryScreensReply> {
34234 let request = types::xinerama::QueryScreensRequest {};
34235 let cookie = self.send_reply_request(request);
34236 let res: futures::CheckedSendRequest<'this, Self, types::xinerama::QueryScreensReply> =
34237 cookie.into();
34238 res
34239 }
34240
34241 #[cfg(feature = "xinput")]
34242 fn xinput_get_extension_version<'this>(
34243 &'this mut self,
34244 name: impl AsRef<[types::Char]>,
34245 ) -> futures::SendRequest<'this, Self, types::xinput::GetExtensionVersionReply> {
34246 let span = tracing::info_span!("xinput_get_extension_version",);
34247 let request = types::xinput::GetExtensionVersionRequest {
34248 name: Cow::Borrowed(name.as_ref()),
34249 };
34250 let cookie = self.send_reply_request(request).with_span(span);
34251 cookie
34252 }
34253 #[cfg(feature = "xinput")]
34254 fn xinput_get_extension_version_immediate<'this>(
34255 &'this mut self,
34256 name: impl AsRef<[types::Char]>,
34257 ) -> futures::CheckedSendRequest<'this, Self, types::xinput::GetExtensionVersionReply> {
34258 let request = types::xinput::GetExtensionVersionRequest {
34259 name: Cow::Borrowed(name.as_ref()),
34260 };
34261 let cookie = self.send_reply_request(request);
34262 let res: futures::CheckedSendRequest<'this, Self, types::xinput::GetExtensionVersionReply> =
34263 cookie.into();
34264 res
34265 }
34266 #[cfg(feature = "xinput")]
34267 fn xinput_list_input_devices<'this>(
34268 &'this mut self,
34269 ) -> futures::SendRequest<'this, Self, types::xinput::ListInputDevicesReply> {
34270 let span = tracing::info_span!("xinput_list_input_devices",);
34271 let request = types::xinput::ListInputDevicesRequest {};
34272 let cookie = self.send_reply_request(request).with_span(span);
34273 cookie
34274 }
34275 #[cfg(feature = "xinput")]
34276 fn xinput_list_input_devices_immediate<'this>(
34277 &'this mut self,
34278 ) -> futures::CheckedSendRequest<'this, Self, types::xinput::ListInputDevicesReply> {
34279 let request = types::xinput::ListInputDevicesRequest {};
34280 let cookie = self.send_reply_request(request);
34281 let res: futures::CheckedSendRequest<'this, Self, types::xinput::ListInputDevicesReply> =
34282 cookie.into();
34283 res
34284 }
34285 #[cfg(feature = "xinput")]
34286 fn xinput_open_device<'this>(
34287 &'this mut self,
34288 device_id: types::Card8,
34289 ) -> futures::SendRequest<'this, Self, types::xinput::OpenDeviceReply> {
34290 let span = tracing::info_span!(
34291 "xinput_open_device",
34292 device_id = ?device_id,
34293 );
34294 let request = types::xinput::OpenDeviceRequest { device_id };
34295 let cookie = self.send_reply_request(request).with_span(span);
34296 cookie
34297 }
34298 #[cfg(feature = "xinput")]
34299 fn xinput_open_device_immediate<'this>(
34300 &'this mut self,
34301 device_id: types::Card8,
34302 ) -> futures::CheckedSendRequest<'this, Self, types::xinput::OpenDeviceReply> {
34303 let request = types::xinput::OpenDeviceRequest { device_id };
34304 let cookie = self.send_reply_request(request);
34305 let res: futures::CheckedSendRequest<'this, Self, types::xinput::OpenDeviceReply> =
34306 cookie.into();
34307 res
34308 }
34309 #[cfg(feature = "xinput")]
34310 fn xinput_close_device<'this>(
34311 &'this mut self,
34312 device_id: types::Card8,
34313 ) -> futures::SendRequest<'this, Self, ()> {
34314 let span = tracing::info_span!(
34315 "xinput_close_device",
34316 device_id = ?device_id,
34317 );
34318 let request = types::xinput::CloseDeviceRequest { device_id };
34319 let cookie = self.send_void_request(request, true).with_span(span);
34320 cookie
34321 }
34322 #[cfg(feature = "xinput")]
34323 fn xinput_close_device_checked<'this>(
34324 &'this mut self,
34325 device_id: types::Card8,
34326 ) -> futures::CheckedSendRequest<'this, Self, ()> {
34327 let request = types::xinput::CloseDeviceRequest { device_id };
34328 let cookie = self.send_void_request(request, false);
34329 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
34330 res
34331 }
34332 #[cfg(feature = "xinput")]
34333 fn xinput_set_device_mode<'this>(
34334 &'this mut self,
34335 device_id: types::Card8,
34336 mode: types::ValuatorMode,
34337 ) -> futures::SendRequest<'this, Self, types::xinput::SetDeviceModeReply> {
34338 let span = tracing::info_span!(
34339 "xinput_set_device_mode",
34340 device_id = ?device_id,
34341 mode = ?mode,
34342 );
34343 let request = types::xinput::SetDeviceModeRequest { device_id, mode };
34344 let cookie = self.send_reply_request(request).with_span(span);
34345 cookie
34346 }
34347 #[cfg(feature = "xinput")]
34348 fn xinput_set_device_mode_immediate<'this>(
34349 &'this mut self,
34350 device_id: types::Card8,
34351 mode: types::ValuatorMode,
34352 ) -> futures::CheckedSendRequest<'this, Self, types::xinput::SetDeviceModeReply> {
34353 let request = types::xinput::SetDeviceModeRequest { device_id, mode };
34354 let cookie = self.send_reply_request(request);
34355 let res: futures::CheckedSendRequest<'this, Self, types::xinput::SetDeviceModeReply> =
34356 cookie.into();
34357 res
34358 }
34359 #[cfg(feature = "xinput")]
34360 fn xinput_select_extension_event<'this>(
34361 &'this mut self,
34362 window: types::xproto::Window,
34363 classes: impl AsRef<[types::EventClass]>,
34364 ) -> futures::SendRequest<'this, Self, ()> {
34365 let span = tracing::info_span!(
34366 "xinput_select_extension_event",
34367 window = ?window,
34368 );
34369 let request = types::xinput::SelectExtensionEventRequest {
34370 window,
34371 classes: Cow::Borrowed(classes.as_ref()),
34372 };
34373 let cookie = self.send_void_request(request, true).with_span(span);
34374 cookie
34375 }
34376 #[cfg(feature = "xinput")]
34377 fn xinput_select_extension_event_checked<'this>(
34378 &'this mut self,
34379 window: types::xproto::Window,
34380 classes: impl AsRef<[types::EventClass]>,
34381 ) -> futures::CheckedSendRequest<'this, Self, ()> {
34382 let request = types::xinput::SelectExtensionEventRequest {
34383 window,
34384 classes: Cow::Borrowed(classes.as_ref()),
34385 };
34386 let cookie = self.send_void_request(request, false);
34387 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
34388 res
34389 }
34390 #[cfg(feature = "xinput")]
34391 fn xinput_get_selected_extension_events<'this>(
34392 &'this mut self,
34393 window: types::xproto::Window,
34394 ) -> futures::SendRequest<'this, Self, types::xinput::GetSelectedExtensionEventsReply> {
34395 let span = tracing::info_span!(
34396 "xinput_get_selected_extension_events",
34397 window = ?window,
34398 );
34399 let request = types::xinput::GetSelectedExtensionEventsRequest { window };
34400 let cookie = self.send_reply_request(request).with_span(span);
34401 cookie
34402 }
34403 #[cfg(feature = "xinput")]
34404 fn xinput_get_selected_extension_events_immediate<'this>(
34405 &'this mut self,
34406 window: types::xproto::Window,
34407 ) -> futures::CheckedSendRequest<'this, Self, types::xinput::GetSelectedExtensionEventsReply>
34408 {
34409 let request = types::xinput::GetSelectedExtensionEventsRequest { window };
34410 let cookie = self.send_reply_request(request);
34411 let res: futures::CheckedSendRequest<
34412 'this,
34413 Self,
34414 types::xinput::GetSelectedExtensionEventsReply,
34415 > = cookie.into();
34416 res
34417 }
34418 #[cfg(feature = "xinput")]
34419 fn xinput_change_device_dont_propagate_list<'this>(
34420 &'this mut self,
34421 window: types::xproto::Window,
34422 mode: types::PropagateMode,
34423 classes: impl AsRef<[types::EventClass]>,
34424 ) -> futures::SendRequest<'this, Self, ()> {
34425 let span = tracing::info_span!(
34426 "xinput_change_device_dont_propagate_list",
34427 window = ?window,
34428 mode = ?mode,
34429 );
34430 let request = types::xinput::ChangeDeviceDontPropagateListRequest {
34431 window,
34432 mode,
34433 classes: Cow::Borrowed(classes.as_ref()),
34434 };
34435 let cookie = self.send_void_request(request, true).with_span(span);
34436 cookie
34437 }
34438 #[cfg(feature = "xinput")]
34439 fn xinput_change_device_dont_propagate_list_checked<'this>(
34440 &'this mut self,
34441 window: types::xproto::Window,
34442 mode: types::PropagateMode,
34443 classes: impl AsRef<[types::EventClass]>,
34444 ) -> futures::CheckedSendRequest<'this, Self, ()> {
34445 let request = types::xinput::ChangeDeviceDontPropagateListRequest {
34446 window,
34447 mode,
34448 classes: Cow::Borrowed(classes.as_ref()),
34449 };
34450 let cookie = self.send_void_request(request, false);
34451 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
34452 res
34453 }
34454 #[cfg(feature = "xinput")]
34455 fn xinput_get_device_dont_propagate_list<'this>(
34456 &'this mut self,
34457 window: types::xproto::Window,
34458 ) -> futures::SendRequest<'this, Self, types::xinput::GetDeviceDontPropagateListReply> {
34459 let span = tracing::info_span!(
34460 "xinput_get_device_dont_propagate_list",
34461 window = ?window,
34462 );
34463 let request = types::xinput::GetDeviceDontPropagateListRequest { window };
34464 let cookie = self.send_reply_request(request).with_span(span);
34465 cookie
34466 }
34467 #[cfg(feature = "xinput")]
34468 fn xinput_get_device_dont_propagate_list_immediate<'this>(
34469 &'this mut self,
34470 window: types::xproto::Window,
34471 ) -> futures::CheckedSendRequest<'this, Self, types::xinput::GetDeviceDontPropagateListReply>
34472 {
34473 let request = types::xinput::GetDeviceDontPropagateListRequest { window };
34474 let cookie = self.send_reply_request(request);
34475 let res: futures::CheckedSendRequest<
34476 'this,
34477 Self,
34478 types::xinput::GetDeviceDontPropagateListReply,
34479 > = cookie.into();
34480 res
34481 }
34482 #[cfg(feature = "xinput")]
34483 fn xinput_get_device_motion_events<'this>(
34484 &'this mut self,
34485 start: types::Timestamp,
34486 stop: impl Into<types::Time>,
34487 device_id: types::Card8,
34488 ) -> futures::SendRequest<'this, Self, types::xinput::GetDeviceMotionEventsReply> {
34489 let span = tracing::info_span!(
34490 "xinput_get_device_motion_events",
34491 start = ?start,
34492 device_id = ?device_id,
34493 );
34494 let request = types::xinput::GetDeviceMotionEventsRequest {
34495 start,
34496 stop: Into::<u32>::into(stop.into()) as _,
34497 device_id,
34498 };
34499 let cookie = self.send_reply_request(request).with_span(span);
34500 cookie
34501 }
34502 #[cfg(feature = "xinput")]
34503 fn xinput_get_device_motion_events_immediate<'this>(
34504 &'this mut self,
34505 start: types::Timestamp,
34506 stop: impl Into<types::Time>,
34507 device_id: types::Card8,
34508 ) -> futures::CheckedSendRequest<'this, Self, types::xinput::GetDeviceMotionEventsReply> {
34509 let request = types::xinput::GetDeviceMotionEventsRequest {
34510 start,
34511 stop: Into::<u32>::into(stop.into()) as _,
34512 device_id,
34513 };
34514 let cookie = self.send_reply_request(request);
34515 let res: futures::CheckedSendRequest<
34516 'this,
34517 Self,
34518 types::xinput::GetDeviceMotionEventsReply,
34519 > = cookie.into();
34520 res
34521 }
34522 #[cfg(feature = "xinput")]
34523 fn xinput_change_keyboard_device<'this>(
34524 &'this mut self,
34525 device_id: types::Card8,
34526 ) -> futures::SendRequest<'this, Self, types::xinput::ChangeKeyboardDeviceReply> {
34527 let span = tracing::info_span!(
34528 "xinput_change_keyboard_device",
34529 device_id = ?device_id,
34530 );
34531 let request = types::xinput::ChangeKeyboardDeviceRequest { device_id };
34532 let cookie = self.send_reply_request(request).with_span(span);
34533 cookie
34534 }
34535 #[cfg(feature = "xinput")]
34536 fn xinput_change_keyboard_device_immediate<'this>(
34537 &'this mut self,
34538 device_id: types::Card8,
34539 ) -> futures::CheckedSendRequest<'this, Self, types::xinput::ChangeKeyboardDeviceReply> {
34540 let request = types::xinput::ChangeKeyboardDeviceRequest { device_id };
34541 let cookie = self.send_reply_request(request);
34542 let res: futures::CheckedSendRequest<
34543 'this,
34544 Self,
34545 types::xinput::ChangeKeyboardDeviceReply,
34546 > = cookie.into();
34547 res
34548 }
34549 #[cfg(feature = "xinput")]
34550 fn xinput_change_pointer_device<'this>(
34551 &'this mut self,
34552 x_axis: types::Card8,
34553 y_axis: types::Card8,
34554 device_id: types::Card8,
34555 ) -> futures::SendRequest<'this, Self, types::xinput::ChangePointerDeviceReply> {
34556 let span = tracing::info_span!(
34557 "xinput_change_pointer_device",
34558 x_axis = ?x_axis,
34559 y_axis = ?y_axis,
34560 device_id = ?device_id,
34561 );
34562 let request = types::xinput::ChangePointerDeviceRequest {
34563 x_axis,
34564 y_axis,
34565 device_id,
34566 };
34567 let cookie = self.send_reply_request(request).with_span(span);
34568 cookie
34569 }
34570 #[cfg(feature = "xinput")]
34571 fn xinput_change_pointer_device_immediate<'this>(
34572 &'this mut self,
34573 x_axis: types::Card8,
34574 y_axis: types::Card8,
34575 device_id: types::Card8,
34576 ) -> futures::CheckedSendRequest<'this, Self, types::xinput::ChangePointerDeviceReply> {
34577 let request = types::xinput::ChangePointerDeviceRequest {
34578 x_axis,
34579 y_axis,
34580 device_id,
34581 };
34582 let cookie = self.send_reply_request(request);
34583 let res: futures::CheckedSendRequest<'this, Self, types::xinput::ChangePointerDeviceReply> =
34584 cookie.into();
34585 res
34586 }
34587 #[cfg(feature = "xinput")]
34588 fn xinput_grab_device<'this>(
34589 &'this mut self,
34590 grab_window: types::xproto::Window,
34591 time: impl Into<types::Time>,
34592 this_device_mode: types::GrabMode,
34593 other_device_mode: types::GrabMode,
34594 owner_events: types::Bool,
34595 device_id: types::Card8,
34596 classes: impl AsRef<[types::EventClass]>,
34597 ) -> futures::SendRequest<'this, Self, types::xinput::GrabDeviceReply> {
34598 let span = tracing::info_span!(
34599 "xinput_grab_device",
34600 grab_window = ?grab_window,
34601 this_device_mode = ?this_device_mode,
34602 other_device_mode = ?other_device_mode,
34603 owner_events = ?owner_events,
34604 device_id = ?device_id,
34605 );
34606 let request = types::xinput::GrabDeviceRequest {
34607 grab_window,
34608 time: Into::<u32>::into(time.into()) as _,
34609 this_device_mode,
34610 other_device_mode,
34611 owner_events,
34612 device_id,
34613 classes: Cow::Borrowed(classes.as_ref()),
34614 };
34615 let cookie = self.send_reply_request(request).with_span(span);
34616 cookie
34617 }
34618 #[cfg(feature = "xinput")]
34619 fn xinput_grab_device_immediate<'this>(
34620 &'this mut self,
34621 grab_window: types::xproto::Window,
34622 time: impl Into<types::Time>,
34623 this_device_mode: types::GrabMode,
34624 other_device_mode: types::GrabMode,
34625 owner_events: types::Bool,
34626 device_id: types::Card8,
34627 classes: impl AsRef<[types::EventClass]>,
34628 ) -> futures::CheckedSendRequest<'this, Self, types::xinput::GrabDeviceReply> {
34629 let request = types::xinput::GrabDeviceRequest {
34630 grab_window,
34631 time: Into::<u32>::into(time.into()) as _,
34632 this_device_mode,
34633 other_device_mode,
34634 owner_events,
34635 device_id,
34636 classes: Cow::Borrowed(classes.as_ref()),
34637 };
34638 let cookie = self.send_reply_request(request);
34639 let res: futures::CheckedSendRequest<'this, Self, types::xinput::GrabDeviceReply> =
34640 cookie.into();
34641 res
34642 }
34643 #[cfg(feature = "xinput")]
34644 fn xinput_ungrab_device<'this>(
34645 &'this mut self,
34646 time: impl Into<types::Time>,
34647 device_id: types::Card8,
34648 ) -> futures::SendRequest<'this, Self, ()> {
34649 let span = tracing::info_span!(
34650 "xinput_ungrab_device",
34651 device_id = ?device_id,
34652 );
34653 let request = types::xinput::UngrabDeviceRequest {
34654 time: Into::<u32>::into(time.into()) as _,
34655 device_id,
34656 };
34657 let cookie = self.send_void_request(request, true).with_span(span);
34658 cookie
34659 }
34660 #[cfg(feature = "xinput")]
34661 fn xinput_ungrab_device_checked<'this>(
34662 &'this mut self,
34663 time: impl Into<types::Time>,
34664 device_id: types::Card8,
34665 ) -> futures::CheckedSendRequest<'this, Self, ()> {
34666 let request = types::xinput::UngrabDeviceRequest {
34667 time: Into::<u32>::into(time.into()) as _,
34668 device_id,
34669 };
34670 let cookie = self.send_void_request(request, false);
34671 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
34672 res
34673 }
34674 #[cfg(feature = "xinput")]
34675 fn xinput_grab_device_key<'this>(
34676 &'this mut self,
34677 grab_window: types::xproto::Window,
34678 modifiers: impl Into<types::ModMask>,
34679 modifier_device: impl Into<types::ModifierDevice>,
34680 grabbed_device: types::Card8,
34681 key: impl Into<types::Grab>,
34682 this_device_mode: types::GrabMode,
34683 other_device_mode: types::GrabMode,
34684 owner_events: types::Bool,
34685 classes: impl AsRef<[types::EventClass]>,
34686 ) -> futures::SendRequest<'this, Self, ()> {
34687 let span = tracing::info_span!(
34688 "xinput_grab_device_key",
34689 grab_window = ?grab_window,
34690 grabbed_device = ?grabbed_device,
34691 this_device_mode = ?this_device_mode,
34692 other_device_mode = ?other_device_mode,
34693 owner_events = ?owner_events,
34694 );
34695 let request = types::xinput::GrabDeviceKeyRequest {
34696 grab_window,
34697 modifiers: Into::<u32>::into(modifiers.into()) as _,
34698 modifier_device: Into::<u32>::into(modifier_device.into()) as _,
34699 grabbed_device,
34700 key: Into::<u32>::into(key.into()) as _,
34701 this_device_mode,
34702 other_device_mode,
34703 owner_events,
34704 classes: Cow::Borrowed(classes.as_ref()),
34705 };
34706 let cookie = self.send_void_request(request, true).with_span(span);
34707 cookie
34708 }
34709 #[cfg(feature = "xinput")]
34710 fn xinput_grab_device_key_checked<'this>(
34711 &'this mut self,
34712 grab_window: types::xproto::Window,
34713 modifiers: impl Into<types::ModMask>,
34714 modifier_device: impl Into<types::ModifierDevice>,
34715 grabbed_device: types::Card8,
34716 key: impl Into<types::Grab>,
34717 this_device_mode: types::GrabMode,
34718 other_device_mode: types::GrabMode,
34719 owner_events: types::Bool,
34720 classes: impl AsRef<[types::EventClass]>,
34721 ) -> futures::CheckedSendRequest<'this, Self, ()> {
34722 let request = types::xinput::GrabDeviceKeyRequest {
34723 grab_window,
34724 modifiers: Into::<u32>::into(modifiers.into()) as _,
34725 modifier_device: Into::<u32>::into(modifier_device.into()) as _,
34726 grabbed_device,
34727 key: Into::<u32>::into(key.into()) as _,
34728 this_device_mode,
34729 other_device_mode,
34730 owner_events,
34731 classes: Cow::Borrowed(classes.as_ref()),
34732 };
34733 let cookie = self.send_void_request(request, false);
34734 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
34735 res
34736 }
34737 #[cfg(feature = "xinput")]
34738 fn xinput_ungrab_device_key<'this>(
34739 &'this mut self,
34740 grab_window: types::xproto::Window,
34741 modifiers: impl Into<types::ModMask>,
34742 modifier_device: impl Into<types::ModifierDevice>,
34743 key: impl Into<types::Grab>,
34744 grabbed_device: types::Card8,
34745 ) -> futures::SendRequest<'this, Self, ()> {
34746 let span = tracing::info_span!(
34747 "xinput_ungrab_device_key",
34748 grab_window = ?grab_window,
34749 grabbed_device = ?grabbed_device,
34750 );
34751 let request = types::xinput::UngrabDeviceKeyRequest {
34752 grab_window,
34753 modifiers: Into::<u32>::into(modifiers.into()) as _,
34754 modifier_device: Into::<u32>::into(modifier_device.into()) as _,
34755 key: Into::<u32>::into(key.into()) as _,
34756 grabbed_device,
34757 };
34758 let cookie = self.send_void_request(request, true).with_span(span);
34759 cookie
34760 }
34761 #[cfg(feature = "xinput")]
34762 fn xinput_ungrab_device_key_checked<'this>(
34763 &'this mut self,
34764 grab_window: types::xproto::Window,
34765 modifiers: impl Into<types::ModMask>,
34766 modifier_device: impl Into<types::ModifierDevice>,
34767 key: impl Into<types::Grab>,
34768 grabbed_device: types::Card8,
34769 ) -> futures::CheckedSendRequest<'this, Self, ()> {
34770 let request = types::xinput::UngrabDeviceKeyRequest {
34771 grab_window,
34772 modifiers: Into::<u32>::into(modifiers.into()) as _,
34773 modifier_device: Into::<u32>::into(modifier_device.into()) as _,
34774 key: Into::<u32>::into(key.into()) as _,
34775 grabbed_device,
34776 };
34777 let cookie = self.send_void_request(request, false);
34778 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
34779 res
34780 }
34781 #[cfg(feature = "xinput")]
34782 fn xinput_grab_device_button<'this>(
34783 &'this mut self,
34784 grab_window: types::xproto::Window,
34785 grabbed_device: types::Card8,
34786 modifier_device: impl Into<types::ModifierDevice>,
34787 modifiers: impl Into<types::ModMask>,
34788 this_device_mode: types::GrabMode,
34789 other_device_mode: types::GrabMode,
34790 button: impl Into<types::Grab>,
34791 owner_events: types::Bool,
34792 classes: impl AsRef<[types::EventClass]>,
34793 ) -> futures::SendRequest<'this, Self, ()> {
34794 let span = tracing::info_span!(
34795 "xinput_grab_device_button",
34796 grab_window = ?grab_window,
34797 grabbed_device = ?grabbed_device,
34798 this_device_mode = ?this_device_mode,
34799 other_device_mode = ?other_device_mode,
34800 owner_events = ?owner_events,
34801 );
34802 let request = types::xinput::GrabDeviceButtonRequest {
34803 grab_window,
34804 grabbed_device,
34805 modifier_device: Into::<u32>::into(modifier_device.into()) as _,
34806 modifiers: Into::<u32>::into(modifiers.into()) as _,
34807 this_device_mode,
34808 other_device_mode,
34809 button: Into::<u32>::into(button.into()) as _,
34810 owner_events,
34811 classes: Cow::Borrowed(classes.as_ref()),
34812 };
34813 let cookie = self.send_void_request(request, true).with_span(span);
34814 cookie
34815 }
34816 #[cfg(feature = "xinput")]
34817 fn xinput_grab_device_button_checked<'this>(
34818 &'this mut self,
34819 grab_window: types::xproto::Window,
34820 grabbed_device: types::Card8,
34821 modifier_device: impl Into<types::ModifierDevice>,
34822 modifiers: impl Into<types::ModMask>,
34823 this_device_mode: types::GrabMode,
34824 other_device_mode: types::GrabMode,
34825 button: impl Into<types::Grab>,
34826 owner_events: types::Bool,
34827 classes: impl AsRef<[types::EventClass]>,
34828 ) -> futures::CheckedSendRequest<'this, Self, ()> {
34829 let request = types::xinput::GrabDeviceButtonRequest {
34830 grab_window,
34831 grabbed_device,
34832 modifier_device: Into::<u32>::into(modifier_device.into()) as _,
34833 modifiers: Into::<u32>::into(modifiers.into()) as _,
34834 this_device_mode,
34835 other_device_mode,
34836 button: Into::<u32>::into(button.into()) as _,
34837 owner_events,
34838 classes: Cow::Borrowed(classes.as_ref()),
34839 };
34840 let cookie = self.send_void_request(request, false);
34841 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
34842 res
34843 }
34844 #[cfg(feature = "xinput")]
34845 fn xinput_ungrab_device_button<'this>(
34846 &'this mut self,
34847 grab_window: types::xproto::Window,
34848 modifiers: impl Into<types::ModMask>,
34849 modifier_device: impl Into<types::ModifierDevice>,
34850 button: impl Into<types::Grab>,
34851 grabbed_device: types::Card8,
34852 ) -> futures::SendRequest<'this, Self, ()> {
34853 let span = tracing::info_span!(
34854 "xinput_ungrab_device_button",
34855 grab_window = ?grab_window,
34856 grabbed_device = ?grabbed_device,
34857 );
34858 let request = types::xinput::UngrabDeviceButtonRequest {
34859 grab_window,
34860 modifiers: Into::<u32>::into(modifiers.into()) as _,
34861 modifier_device: Into::<u32>::into(modifier_device.into()) as _,
34862 button: Into::<u32>::into(button.into()) as _,
34863 grabbed_device,
34864 };
34865 let cookie = self.send_void_request(request, true).with_span(span);
34866 cookie
34867 }
34868 #[cfg(feature = "xinput")]
34869 fn xinput_ungrab_device_button_checked<'this>(
34870 &'this mut self,
34871 grab_window: types::xproto::Window,
34872 modifiers: impl Into<types::ModMask>,
34873 modifier_device: impl Into<types::ModifierDevice>,
34874 button: impl Into<types::Grab>,
34875 grabbed_device: types::Card8,
34876 ) -> futures::CheckedSendRequest<'this, Self, ()> {
34877 let request = types::xinput::UngrabDeviceButtonRequest {
34878 grab_window,
34879 modifiers: Into::<u32>::into(modifiers.into()) as _,
34880 modifier_device: Into::<u32>::into(modifier_device.into()) as _,
34881 button: Into::<u32>::into(button.into()) as _,
34882 grabbed_device,
34883 };
34884 let cookie = self.send_void_request(request, false);
34885 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
34886 res
34887 }
34888 #[cfg(feature = "xinput")]
34889 fn xinput_allow_device_events<'this>(
34890 &'this mut self,
34891 time: impl Into<types::Time>,
34892 mode: types::DeviceInputMode,
34893 device_id: types::Card8,
34894 ) -> futures::SendRequest<'this, Self, ()> {
34895 let span = tracing::info_span!(
34896 "xinput_allow_device_events",
34897 mode = ?mode,
34898 device_id = ?device_id,
34899 );
34900 let request = types::xinput::AllowDeviceEventsRequest {
34901 time: Into::<u32>::into(time.into()) as _,
34902 mode,
34903 device_id,
34904 };
34905 let cookie = self.send_void_request(request, true).with_span(span);
34906 cookie
34907 }
34908 #[cfg(feature = "xinput")]
34909 fn xinput_allow_device_events_checked<'this>(
34910 &'this mut self,
34911 time: impl Into<types::Time>,
34912 mode: types::DeviceInputMode,
34913 device_id: types::Card8,
34914 ) -> futures::CheckedSendRequest<'this, Self, ()> {
34915 let request = types::xinput::AllowDeviceEventsRequest {
34916 time: Into::<u32>::into(time.into()) as _,
34917 mode,
34918 device_id,
34919 };
34920 let cookie = self.send_void_request(request, false);
34921 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
34922 res
34923 }
34924 #[cfg(feature = "xinput")]
34925 fn xinput_get_device_focus<'this>(
34926 &'this mut self,
34927 device_id: types::Card8,
34928 ) -> futures::SendRequest<'this, Self, types::xinput::GetDeviceFocusReply> {
34929 let span = tracing::info_span!(
34930 "xinput_get_device_focus",
34931 device_id = ?device_id,
34932 );
34933 let request = types::xinput::GetDeviceFocusRequest { device_id };
34934 let cookie = self.send_reply_request(request).with_span(span);
34935 cookie
34936 }
34937 #[cfg(feature = "xinput")]
34938 fn xinput_get_device_focus_immediate<'this>(
34939 &'this mut self,
34940 device_id: types::Card8,
34941 ) -> futures::CheckedSendRequest<'this, Self, types::xinput::GetDeviceFocusReply> {
34942 let request = types::xinput::GetDeviceFocusRequest { device_id };
34943 let cookie = self.send_reply_request(request);
34944 let res: futures::CheckedSendRequest<'this, Self, types::xinput::GetDeviceFocusReply> =
34945 cookie.into();
34946 res
34947 }
34948 #[cfg(feature = "xinput")]
34949 fn xinput_set_device_focus<'this>(
34950 &'this mut self,
34951 focus: impl Into<types::InputFocus>,
34952 time: impl Into<types::Time>,
34953 revert_to: types::InputFocus,
34954 device_id: types::Card8,
34955 ) -> futures::SendRequest<'this, Self, ()> {
34956 let span = tracing::info_span!(
34957 "xinput_set_device_focus",
34958 revert_to = ?revert_to,
34959 device_id = ?device_id,
34960 );
34961 let request = types::xinput::SetDeviceFocusRequest {
34962 focus: Into::<u32>::into(focus.into()) as _,
34963 time: Into::<u32>::into(time.into()) as _,
34964 revert_to,
34965 device_id,
34966 };
34967 let cookie = self.send_void_request(request, true).with_span(span);
34968 cookie
34969 }
34970 #[cfg(feature = "xinput")]
34971 fn xinput_set_device_focus_checked<'this>(
34972 &'this mut self,
34973 focus: impl Into<types::InputFocus>,
34974 time: impl Into<types::Time>,
34975 revert_to: types::InputFocus,
34976 device_id: types::Card8,
34977 ) -> futures::CheckedSendRequest<'this, Self, ()> {
34978 let request = types::xinput::SetDeviceFocusRequest {
34979 focus: Into::<u32>::into(focus.into()) as _,
34980 time: Into::<u32>::into(time.into()) as _,
34981 revert_to,
34982 device_id,
34983 };
34984 let cookie = self.send_void_request(request, false);
34985 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
34986 res
34987 }
34988 #[cfg(feature = "xinput")]
34989 fn xinput_get_feedback_control<'this>(
34990 &'this mut self,
34991 device_id: types::Card8,
34992 ) -> futures::SendRequest<'this, Self, types::xinput::GetFeedbackControlReply> {
34993 let span = tracing::info_span!(
34994 "xinput_get_feedback_control",
34995 device_id = ?device_id,
34996 );
34997 let request = types::xinput::GetFeedbackControlRequest { device_id };
34998 let cookie = self.send_reply_request(request).with_span(span);
34999 cookie
35000 }
35001 #[cfg(feature = "xinput")]
35002 fn xinput_get_feedback_control_immediate<'this>(
35003 &'this mut self,
35004 device_id: types::Card8,
35005 ) -> futures::CheckedSendRequest<'this, Self, types::xinput::GetFeedbackControlReply> {
35006 let request = types::xinput::GetFeedbackControlRequest { device_id };
35007 let cookie = self.send_reply_request(request);
35008 let res: futures::CheckedSendRequest<'this, Self, types::xinput::GetFeedbackControlReply> =
35009 cookie.into();
35010 res
35011 }
35012 #[cfg(feature = "xinput")]
35013 fn xinput_change_feedback_control<'this>(
35014 &'this mut self,
35015 mask: impl Into<types::ChangeFeedbackControlMask>,
35016 device_id: types::Card8,
35017 feedback_id: types::Card8,
35018 feedback: types::FeedbackCtl,
35019 ) -> futures::SendRequest<'this, Self, ()> {
35020 let span = tracing::info_span!(
35021 "xinput_change_feedback_control",
35022 device_id = ?device_id,
35023 feedback_id = ?feedback_id,
35024 feedback = ?feedback,
35025 );
35026 let request = types::xinput::ChangeFeedbackControlRequest {
35027 mask: Into::<u32>::into(mask.into()) as _,
35028 device_id,
35029 feedback_id,
35030 feedback,
35031 };
35032 let cookie = self.send_void_request(request, true).with_span(span);
35033 cookie
35034 }
35035 #[cfg(feature = "xinput")]
35036 fn xinput_change_feedback_control_checked<'this>(
35037 &'this mut self,
35038 mask: impl Into<types::ChangeFeedbackControlMask>,
35039 device_id: types::Card8,
35040 feedback_id: types::Card8,
35041 feedback: types::FeedbackCtl,
35042 ) -> futures::CheckedSendRequest<'this, Self, ()> {
35043 let request = types::xinput::ChangeFeedbackControlRequest {
35044 mask: Into::<u32>::into(mask.into()) as _,
35045 device_id,
35046 feedback_id,
35047 feedback,
35048 };
35049 let cookie = self.send_void_request(request, false);
35050 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
35051 res
35052 }
35053 #[cfg(feature = "xinput")]
35054 fn xinput_get_device_key_mapping<'this>(
35055 &'this mut self,
35056 device_id: types::Card8,
35057 first_keycode: types::KeyCode,
35058 count: types::Card8,
35059 ) -> futures::SendRequest<'this, Self, types::xinput::GetDeviceKeyMappingReply> {
35060 let span = tracing::info_span!(
35061 "xinput_get_device_key_mapping",
35062 device_id = ?device_id,
35063 first_keycode = ?first_keycode,
35064 count = ?count,
35065 );
35066 let request = types::xinput::GetDeviceKeyMappingRequest {
35067 device_id,
35068 first_keycode,
35069 count,
35070 };
35071 let cookie = self.send_reply_request(request).with_span(span);
35072 cookie
35073 }
35074 #[cfg(feature = "xinput")]
35075 fn xinput_get_device_key_mapping_immediate<'this>(
35076 &'this mut self,
35077 device_id: types::Card8,
35078 first_keycode: types::KeyCode,
35079 count: types::Card8,
35080 ) -> futures::CheckedSendRequest<'this, Self, types::xinput::GetDeviceKeyMappingReply> {
35081 let request = types::xinput::GetDeviceKeyMappingRequest {
35082 device_id,
35083 first_keycode,
35084 count,
35085 };
35086 let cookie = self.send_reply_request(request);
35087 let res: futures::CheckedSendRequest<'this, Self, types::xinput::GetDeviceKeyMappingReply> =
35088 cookie.into();
35089 res
35090 }
35091 #[cfg(feature = "xinput")]
35092 fn xinput_change_device_key_mapping<'this>(
35093 &'this mut self,
35094 device_id: types::Card8,
35095 first_keycode: types::KeyCode,
35096 keysyms_per_keycode: types::Card8,
35097 keycode_count: types::Card8,
35098 keysyms: impl AsRef<[types::Keysym]>,
35099 ) -> futures::SendRequest<'this, Self, ()> {
35100 let span = tracing::info_span!(
35101 "xinput_change_device_key_mapping",
35102 device_id = ?device_id,
35103 first_keycode = ?first_keycode,
35104 keysyms_per_keycode = ?keysyms_per_keycode,
35105 keycode_count = ?keycode_count,
35106 );
35107 let request = types::xinput::ChangeDeviceKeyMappingRequest {
35108 device_id,
35109 first_keycode,
35110 keysyms_per_keycode,
35111 keycode_count,
35112 keysyms: Cow::Borrowed(keysyms.as_ref()),
35113 };
35114 let cookie = self.send_void_request(request, true).with_span(span);
35115 cookie
35116 }
35117 #[cfg(feature = "xinput")]
35118 fn xinput_change_device_key_mapping_checked<'this>(
35119 &'this mut self,
35120 device_id: types::Card8,
35121 first_keycode: types::KeyCode,
35122 keysyms_per_keycode: types::Card8,
35123 keycode_count: types::Card8,
35124 keysyms: impl AsRef<[types::Keysym]>,
35125 ) -> futures::CheckedSendRequest<'this, Self, ()> {
35126 let request = types::xinput::ChangeDeviceKeyMappingRequest {
35127 device_id,
35128 first_keycode,
35129 keysyms_per_keycode,
35130 keycode_count,
35131 keysyms: Cow::Borrowed(keysyms.as_ref()),
35132 };
35133 let cookie = self.send_void_request(request, false);
35134 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
35135 res
35136 }
35137 #[cfg(feature = "xinput")]
35138 fn xinput_get_device_modifier_mapping<'this>(
35139 &'this mut self,
35140 device_id: types::Card8,
35141 ) -> futures::SendRequest<'this, Self, types::xinput::GetDeviceModifierMappingReply> {
35142 let span = tracing::info_span!(
35143 "xinput_get_device_modifier_mapping",
35144 device_id = ?device_id,
35145 );
35146 let request = types::xinput::GetDeviceModifierMappingRequest { device_id };
35147 let cookie = self.send_reply_request(request).with_span(span);
35148 cookie
35149 }
35150 #[cfg(feature = "xinput")]
35151 fn xinput_get_device_modifier_mapping_immediate<'this>(
35152 &'this mut self,
35153 device_id: types::Card8,
35154 ) -> futures::CheckedSendRequest<'this, Self, types::xinput::GetDeviceModifierMappingReply>
35155 {
35156 let request = types::xinput::GetDeviceModifierMappingRequest { device_id };
35157 let cookie = self.send_reply_request(request);
35158 let res: futures::CheckedSendRequest<
35159 'this,
35160 Self,
35161 types::xinput::GetDeviceModifierMappingReply,
35162 > = cookie.into();
35163 res
35164 }
35165 #[cfg(feature = "xinput")]
35166 fn xinput_set_device_modifier_mapping<'this>(
35167 &'this mut self,
35168 device_id: types::Card8,
35169 keymaps: impl AsRef<[types::Card8]>,
35170 ) -> futures::SendRequest<'this, Self, types::xinput::SetDeviceModifierMappingReply> {
35171 let span = tracing::info_span!(
35172 "xinput_set_device_modifier_mapping",
35173 device_id = ?device_id,
35174 );
35175 let request = types::xinput::SetDeviceModifierMappingRequest {
35176 device_id,
35177 keymaps: Cow::Borrowed(keymaps.as_ref()),
35178 };
35179 let cookie = self.send_reply_request(request).with_span(span);
35180 cookie
35181 }
35182 #[cfg(feature = "xinput")]
35183 fn xinput_set_device_modifier_mapping_immediate<'this>(
35184 &'this mut self,
35185 device_id: types::Card8,
35186 keymaps: impl AsRef<[types::Card8]>,
35187 ) -> futures::CheckedSendRequest<'this, Self, types::xinput::SetDeviceModifierMappingReply>
35188 {
35189 let request = types::xinput::SetDeviceModifierMappingRequest {
35190 device_id,
35191 keymaps: Cow::Borrowed(keymaps.as_ref()),
35192 };
35193 let cookie = self.send_reply_request(request);
35194 let res: futures::CheckedSendRequest<
35195 'this,
35196 Self,
35197 types::xinput::SetDeviceModifierMappingReply,
35198 > = cookie.into();
35199 res
35200 }
35201 #[cfg(feature = "xinput")]
35202 fn xinput_get_device_button_mapping<'this>(
35203 &'this mut self,
35204 device_id: types::Card8,
35205 ) -> futures::SendRequest<'this, Self, types::xinput::GetDeviceButtonMappingReply> {
35206 let span = tracing::info_span!(
35207 "xinput_get_device_button_mapping",
35208 device_id = ?device_id,
35209 );
35210 let request = types::xinput::GetDeviceButtonMappingRequest { device_id };
35211 let cookie = self.send_reply_request(request).with_span(span);
35212 cookie
35213 }
35214 #[cfg(feature = "xinput")]
35215 fn xinput_get_device_button_mapping_immediate<'this>(
35216 &'this mut self,
35217 device_id: types::Card8,
35218 ) -> futures::CheckedSendRequest<'this, Self, types::xinput::GetDeviceButtonMappingReply> {
35219 let request = types::xinput::GetDeviceButtonMappingRequest { device_id };
35220 let cookie = self.send_reply_request(request);
35221 let res: futures::CheckedSendRequest<
35222 'this,
35223 Self,
35224 types::xinput::GetDeviceButtonMappingReply,
35225 > = cookie.into();
35226 res
35227 }
35228 #[cfg(feature = "xinput")]
35229 fn xinput_set_device_button_mapping<'this>(
35230 &'this mut self,
35231 device_id: types::Card8,
35232 map: impl AsRef<[types::Card8]>,
35233 ) -> futures::SendRequest<'this, Self, types::xinput::SetDeviceButtonMappingReply> {
35234 let span = tracing::info_span!(
35235 "xinput_set_device_button_mapping",
35236 device_id = ?device_id,
35237 );
35238 let request = types::xinput::SetDeviceButtonMappingRequest {
35239 device_id,
35240 map: Cow::Borrowed(map.as_ref()),
35241 };
35242 let cookie = self.send_reply_request(request).with_span(span);
35243 cookie
35244 }
35245 #[cfg(feature = "xinput")]
35246 fn xinput_set_device_button_mapping_immediate<'this>(
35247 &'this mut self,
35248 device_id: types::Card8,
35249 map: impl AsRef<[types::Card8]>,
35250 ) -> futures::CheckedSendRequest<'this, Self, types::xinput::SetDeviceButtonMappingReply> {
35251 let request = types::xinput::SetDeviceButtonMappingRequest {
35252 device_id,
35253 map: Cow::Borrowed(map.as_ref()),
35254 };
35255 let cookie = self.send_reply_request(request);
35256 let res: futures::CheckedSendRequest<
35257 'this,
35258 Self,
35259 types::xinput::SetDeviceButtonMappingReply,
35260 > = cookie.into();
35261 res
35262 }
35263 #[cfg(feature = "xinput")]
35264 fn xinput_query_device_state<'this>(
35265 &'this mut self,
35266 device_id: types::Card8,
35267 ) -> futures::SendRequest<'this, Self, types::xinput::QueryDeviceStateReply> {
35268 let span = tracing::info_span!(
35269 "xinput_query_device_state",
35270 device_id = ?device_id,
35271 );
35272 let request = types::xinput::QueryDeviceStateRequest { device_id };
35273 let cookie = self.send_reply_request(request).with_span(span);
35274 cookie
35275 }
35276 #[cfg(feature = "xinput")]
35277 fn xinput_query_device_state_immediate<'this>(
35278 &'this mut self,
35279 device_id: types::Card8,
35280 ) -> futures::CheckedSendRequest<'this, Self, types::xinput::QueryDeviceStateReply> {
35281 let request = types::xinput::QueryDeviceStateRequest { device_id };
35282 let cookie = self.send_reply_request(request);
35283 let res: futures::CheckedSendRequest<'this, Self, types::xinput::QueryDeviceStateReply> =
35284 cookie.into();
35285 res
35286 }
35287 #[cfg(feature = "xinput")]
35288 fn xinput_device_bell<'this>(
35289 &'this mut self,
35290 device_id: types::Card8,
35291 feedback_id: types::Card8,
35292 feedback_class: types::Card8,
35293 percent: types::Int8,
35294 ) -> futures::SendRequest<'this, Self, ()> {
35295 let span = tracing::info_span!(
35296 "xinput_device_bell",
35297 device_id = ?device_id,
35298 feedback_id = ?feedback_id,
35299 feedback_class = ?feedback_class,
35300 percent = ?percent,
35301 );
35302 let request = types::xinput::DeviceBellRequest {
35303 device_id,
35304 feedback_id,
35305 feedback_class,
35306 percent,
35307 };
35308 let cookie = self.send_void_request(request, true).with_span(span);
35309 cookie
35310 }
35311 #[cfg(feature = "xinput")]
35312 fn xinput_device_bell_checked<'this>(
35313 &'this mut self,
35314 device_id: types::Card8,
35315 feedback_id: types::Card8,
35316 feedback_class: types::Card8,
35317 percent: types::Int8,
35318 ) -> futures::CheckedSendRequest<'this, Self, ()> {
35319 let request = types::xinput::DeviceBellRequest {
35320 device_id,
35321 feedback_id,
35322 feedback_class,
35323 percent,
35324 };
35325 let cookie = self.send_void_request(request, false);
35326 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
35327 res
35328 }
35329 #[cfg(feature = "xinput")]
35330 fn xinput_set_device_valuators<'this>(
35331 &'this mut self,
35332 device_id: types::Card8,
35333 first_valuator: types::Card8,
35334 valuators: impl AsRef<[types::Int32]>,
35335 ) -> futures::SendRequest<'this, Self, types::xinput::SetDeviceValuatorsReply> {
35336 let span = tracing::info_span!(
35337 "xinput_set_device_valuators",
35338 device_id = ?device_id,
35339 first_valuator = ?first_valuator,
35340 );
35341 let request = types::xinput::SetDeviceValuatorsRequest {
35342 device_id,
35343 first_valuator,
35344 valuators: Cow::Borrowed(valuators.as_ref()),
35345 };
35346 let cookie = self.send_reply_request(request).with_span(span);
35347 cookie
35348 }
35349 #[cfg(feature = "xinput")]
35350 fn xinput_set_device_valuators_immediate<'this>(
35351 &'this mut self,
35352 device_id: types::Card8,
35353 first_valuator: types::Card8,
35354 valuators: impl AsRef<[types::Int32]>,
35355 ) -> futures::CheckedSendRequest<'this, Self, types::xinput::SetDeviceValuatorsReply> {
35356 let request = types::xinput::SetDeviceValuatorsRequest {
35357 device_id,
35358 first_valuator,
35359 valuators: Cow::Borrowed(valuators.as_ref()),
35360 };
35361 let cookie = self.send_reply_request(request);
35362 let res: futures::CheckedSendRequest<'this, Self, types::xinput::SetDeviceValuatorsReply> =
35363 cookie.into();
35364 res
35365 }
35366 #[cfg(feature = "xinput")]
35367 fn xinput_get_device_control<'this>(
35368 &'this mut self,
35369 control_id: types::DeviceControl,
35370 device_id: types::Card8,
35371 ) -> futures::SendRequest<'this, Self, types::xinput::GetDeviceControlReply> {
35372 let span = tracing::info_span!(
35373 "xinput_get_device_control",
35374 control_id = ?control_id,
35375 device_id = ?device_id,
35376 );
35377 let request = types::xinput::GetDeviceControlRequest {
35378 control_id,
35379 device_id,
35380 };
35381 let cookie = self.send_reply_request(request).with_span(span);
35382 cookie
35383 }
35384 #[cfg(feature = "xinput")]
35385 fn xinput_get_device_control_immediate<'this>(
35386 &'this mut self,
35387 control_id: types::DeviceControl,
35388 device_id: types::Card8,
35389 ) -> futures::CheckedSendRequest<'this, Self, types::xinput::GetDeviceControlReply> {
35390 let request = types::xinput::GetDeviceControlRequest {
35391 control_id,
35392 device_id,
35393 };
35394 let cookie = self.send_reply_request(request);
35395 let res: futures::CheckedSendRequest<'this, Self, types::xinput::GetDeviceControlReply> =
35396 cookie.into();
35397 res
35398 }
35399 #[cfg(feature = "xinput")]
35400 fn xinput_change_device_control<'this>(
35401 &'this mut self,
35402 control_id: types::DeviceControl,
35403 device_id: types::Card8,
35404 control: types::DeviceCtl,
35405 ) -> futures::SendRequest<'this, Self, types::xinput::ChangeDeviceControlReply> {
35406 let span = tracing::info_span!(
35407 "xinput_change_device_control",
35408 control_id = ?control_id,
35409 device_id = ?device_id,
35410 control = ?control,
35411 );
35412 let request = types::xinput::ChangeDeviceControlRequest {
35413 control_id,
35414 device_id,
35415 control,
35416 };
35417 let cookie = self.send_reply_request(request).with_span(span);
35418 cookie
35419 }
35420 #[cfg(feature = "xinput")]
35421 fn xinput_change_device_control_immediate<'this>(
35422 &'this mut self,
35423 control_id: types::DeviceControl,
35424 device_id: types::Card8,
35425 control: types::DeviceCtl,
35426 ) -> futures::CheckedSendRequest<'this, Self, types::xinput::ChangeDeviceControlReply> {
35427 let request = types::xinput::ChangeDeviceControlRequest {
35428 control_id,
35429 device_id,
35430 control,
35431 };
35432 let cookie = self.send_reply_request(request);
35433 let res: futures::CheckedSendRequest<'this, Self, types::xinput::ChangeDeviceControlReply> =
35434 cookie.into();
35435 res
35436 }
35437 #[cfg(feature = "xinput")]
35438 fn xinput_list_device_properties<'this>(
35439 &'this mut self,
35440 device_id: types::Card8,
35441 ) -> futures::SendRequest<'this, Self, types::xinput::ListDevicePropertiesReply> {
35442 let span = tracing::info_span!(
35443 "xinput_list_device_properties",
35444 device_id = ?device_id,
35445 );
35446 let request = types::xinput::ListDevicePropertiesRequest { device_id };
35447 let cookie = self.send_reply_request(request).with_span(span);
35448 cookie
35449 }
35450 #[cfg(feature = "xinput")]
35451 fn xinput_list_device_properties_immediate<'this>(
35452 &'this mut self,
35453 device_id: types::Card8,
35454 ) -> futures::CheckedSendRequest<'this, Self, types::xinput::ListDevicePropertiesReply> {
35455 let request = types::xinput::ListDevicePropertiesRequest { device_id };
35456 let cookie = self.send_reply_request(request);
35457 let res: futures::CheckedSendRequest<
35458 'this,
35459 Self,
35460 types::xinput::ListDevicePropertiesReply,
35461 > = cookie.into();
35462 res
35463 }
35464 #[cfg(feature = "xinput")]
35465 fn xinput_change_device_property<'this>(
35466 &'this mut self,
35467 property: types::Atom,
35468 type_: types::Atom,
35469 device_id: types::Card8,
35470 mode: types::PropMode,
35471 num_items: types::Card32,
35472 items: impl Borrow<types::xinput::ChangeDevicePropertyAux>,
35473 ) -> futures::SendRequest<'this, Self, ()> {
35474 let span = tracing::info_span!(
35475 "xinput_change_device_property",
35476 property = ?property,
35477 type_ = ?type_,
35478 device_id = ?device_id,
35479 mode = ?mode,
35480 num_items = ?num_items,
35481 );
35482 let request = types::xinput::ChangeDevicePropertyRequest {
35483 property,
35484 type_,
35485 device_id,
35486 mode,
35487 num_items,
35488 items: Cow::Borrowed(items.borrow()),
35489 };
35490 let cookie = self.send_void_request(request, true).with_span(span);
35491 cookie
35492 }
35493 #[cfg(feature = "xinput")]
35494 fn xinput_change_device_property_checked<'this>(
35495 &'this mut self,
35496 property: types::Atom,
35497 type_: types::Atom,
35498 device_id: types::Card8,
35499 mode: types::PropMode,
35500 num_items: types::Card32,
35501 items: impl Borrow<types::xinput::ChangeDevicePropertyAux>,
35502 ) -> futures::CheckedSendRequest<'this, Self, ()> {
35503 let request = types::xinput::ChangeDevicePropertyRequest {
35504 property,
35505 type_,
35506 device_id,
35507 mode,
35508 num_items,
35509 items: Cow::Borrowed(items.borrow()),
35510 };
35511 let cookie = self.send_void_request(request, false);
35512 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
35513 res
35514 }
35515 #[cfg(feature = "xinput")]
35516 fn xinput_delete_device_property<'this>(
35517 &'this mut self,
35518 property: types::Atom,
35519 device_id: types::Card8,
35520 ) -> futures::SendRequest<'this, Self, ()> {
35521 let span = tracing::info_span!(
35522 "xinput_delete_device_property",
35523 property = ?property,
35524 device_id = ?device_id,
35525 );
35526 let request = types::xinput::DeleteDevicePropertyRequest {
35527 property,
35528 device_id,
35529 };
35530 let cookie = self.send_void_request(request, true).with_span(span);
35531 cookie
35532 }
35533 #[cfg(feature = "xinput")]
35534 fn xinput_delete_device_property_checked<'this>(
35535 &'this mut self,
35536 property: types::Atom,
35537 device_id: types::Card8,
35538 ) -> futures::CheckedSendRequest<'this, Self, ()> {
35539 let request = types::xinput::DeleteDevicePropertyRequest {
35540 property,
35541 device_id,
35542 };
35543 let cookie = self.send_void_request(request, false);
35544 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
35545 res
35546 }
35547 #[cfg(feature = "xinput")]
35548 fn xinput_get_device_property<'this>(
35549 &'this mut self,
35550 property: types::Atom,
35551 type_: types::Atom,
35552 offset: types::Card32,
35553 len: types::Card32,
35554 device_id: types::Card8,
35555 delete: types::Bool,
35556 ) -> futures::SendRequest<'this, Self, types::xinput::GetDevicePropertyReply> {
35557 let span = tracing::info_span!(
35558 "xinput_get_device_property",
35559 property = ?property,
35560 type_ = ?type_,
35561 offset = ?offset,
35562 len = ?len,
35563 device_id = ?device_id,
35564 delete = ?delete,
35565 );
35566 let request = types::xinput::GetDevicePropertyRequest {
35567 property,
35568 type_,
35569 offset,
35570 len,
35571 device_id,
35572 delete,
35573 };
35574 let cookie = self.send_reply_request(request).with_span(span);
35575 cookie
35576 }
35577 #[cfg(feature = "xinput")]
35578 fn xinput_get_device_property_immediate<'this>(
35579 &'this mut self,
35580 property: types::Atom,
35581 type_: types::Atom,
35582 offset: types::Card32,
35583 len: types::Card32,
35584 device_id: types::Card8,
35585 delete: types::Bool,
35586 ) -> futures::CheckedSendRequest<'this, Self, types::xinput::GetDevicePropertyReply> {
35587 let request = types::xinput::GetDevicePropertyRequest {
35588 property,
35589 type_,
35590 offset,
35591 len,
35592 device_id,
35593 delete,
35594 };
35595 let cookie = self.send_reply_request(request);
35596 let res: futures::CheckedSendRequest<'this, Self, types::xinput::GetDevicePropertyReply> =
35597 cookie.into();
35598 res
35599 }
35600 #[cfg(feature = "xinput")]
35601 fn xinput_xi_query_pointer<'this>(
35602 &'this mut self,
35603 window: types::xproto::Window,
35604 deviceid: impl Into<types::Device>,
35605 ) -> futures::SendRequest<'this, Self, types::xinput::XIQueryPointerReply> {
35606 let span = tracing::info_span!(
35607 "xinput_xi_query_pointer",
35608 window = ?window,
35609 );
35610 let request = types::xinput::XIQueryPointerRequest {
35611 window,
35612 deviceid: Into::<u32>::into(deviceid.into()) as _,
35613 };
35614 let cookie = self.send_reply_request(request).with_span(span);
35615 cookie
35616 }
35617 #[cfg(feature = "xinput")]
35618 fn xinput_xi_query_pointer_immediate<'this>(
35619 &'this mut self,
35620 window: types::xproto::Window,
35621 deviceid: impl Into<types::Device>,
35622 ) -> futures::CheckedSendRequest<'this, Self, types::xinput::XIQueryPointerReply> {
35623 let request = types::xinput::XIQueryPointerRequest {
35624 window,
35625 deviceid: Into::<u32>::into(deviceid.into()) as _,
35626 };
35627 let cookie = self.send_reply_request(request);
35628 let res: futures::CheckedSendRequest<'this, Self, types::xinput::XIQueryPointerReply> =
35629 cookie.into();
35630 res
35631 }
35632 #[cfg(feature = "xinput")]
35633 fn xinput_xi_warp_pointer<'this>(
35634 &'this mut self,
35635 src_win: types::xproto::Window,
35636 dst_win: types::xproto::Window,
35637 src_x: types::Fp1616,
35638 src_y: types::Fp1616,
35639 src_width: types::Card16,
35640 src_height: types::Card16,
35641 dst_x: types::Fp1616,
35642 dst_y: types::Fp1616,
35643 deviceid: impl Into<types::Device>,
35644 ) -> futures::SendRequest<'this, Self, ()> {
35645 let span = tracing::info_span!(
35646 "xinput_xi_warp_pointer",
35647 src_win = ?src_win,
35648 dst_win = ?dst_win,
35649 src_x = ?src_x,
35650 src_y = ?src_y,
35651 src_width = ?src_width,
35652 src_height = ?src_height,
35653 dst_x = ?dst_x,
35654 dst_y = ?dst_y,
35655 );
35656 let request = types::xinput::XIWarpPointerRequest {
35657 src_win,
35658 dst_win,
35659 src_x,
35660 src_y,
35661 src_width,
35662 src_height,
35663 dst_x,
35664 dst_y,
35665 deviceid: Into::<u32>::into(deviceid.into()) as _,
35666 };
35667 let cookie = self.send_void_request(request, true).with_span(span);
35668 cookie
35669 }
35670 #[cfg(feature = "xinput")]
35671 fn xinput_xi_warp_pointer_checked<'this>(
35672 &'this mut self,
35673 src_win: types::xproto::Window,
35674 dst_win: types::xproto::Window,
35675 src_x: types::Fp1616,
35676 src_y: types::Fp1616,
35677 src_width: types::Card16,
35678 src_height: types::Card16,
35679 dst_x: types::Fp1616,
35680 dst_y: types::Fp1616,
35681 deviceid: impl Into<types::Device>,
35682 ) -> futures::CheckedSendRequest<'this, Self, ()> {
35683 let request = types::xinput::XIWarpPointerRequest {
35684 src_win,
35685 dst_win,
35686 src_x,
35687 src_y,
35688 src_width,
35689 src_height,
35690 dst_x,
35691 dst_y,
35692 deviceid: Into::<u32>::into(deviceid.into()) as _,
35693 };
35694 let cookie = self.send_void_request(request, false);
35695 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
35696 res
35697 }
35698 #[cfg(feature = "xinput")]
35699 fn xinput_xi_change_cursor<'this>(
35700 &'this mut self,
35701 window: types::xproto::Window,
35702 cursor: types::xproto::Cursor,
35703 deviceid: impl Into<types::Device>,
35704 ) -> futures::SendRequest<'this, Self, ()> {
35705 let span = tracing::info_span!(
35706 "xinput_xi_change_cursor",
35707 window = ?window,
35708 cursor = ?cursor,
35709 );
35710 let request = types::xinput::XIChangeCursorRequest {
35711 window,
35712 cursor,
35713 deviceid: Into::<u32>::into(deviceid.into()) as _,
35714 };
35715 let cookie = self.send_void_request(request, true).with_span(span);
35716 cookie
35717 }
35718 #[cfg(feature = "xinput")]
35719 fn xinput_xi_change_cursor_checked<'this>(
35720 &'this mut self,
35721 window: types::xproto::Window,
35722 cursor: types::xproto::Cursor,
35723 deviceid: impl Into<types::Device>,
35724 ) -> futures::CheckedSendRequest<'this, Self, ()> {
35725 let request = types::xinput::XIChangeCursorRequest {
35726 window,
35727 cursor,
35728 deviceid: Into::<u32>::into(deviceid.into()) as _,
35729 };
35730 let cookie = self.send_void_request(request, false);
35731 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
35732 res
35733 }
35734 #[cfg(feature = "xinput")]
35735 fn xinput_xi_change_hierarchy<'this>(
35736 &'this mut self,
35737 changes: impl AsRef<[types::HierarchyChange]>,
35738 ) -> futures::SendRequest<'this, Self, ()> {
35739 let span = tracing::info_span!("xinput_xi_change_hierarchy",);
35740 let request = types::xinput::XIChangeHierarchyRequest {
35741 changes: Cow::Borrowed(changes.as_ref()),
35742 };
35743 let cookie = self.send_void_request(request, true).with_span(span);
35744 cookie
35745 }
35746 #[cfg(feature = "xinput")]
35747 fn xinput_xi_change_hierarchy_checked<'this>(
35748 &'this mut self,
35749 changes: impl AsRef<[types::HierarchyChange]>,
35750 ) -> futures::CheckedSendRequest<'this, Self, ()> {
35751 let request = types::xinput::XIChangeHierarchyRequest {
35752 changes: Cow::Borrowed(changes.as_ref()),
35753 };
35754 let cookie = self.send_void_request(request, false);
35755 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
35756 res
35757 }
35758 #[cfg(feature = "xinput")]
35759 fn xinput_xi_set_client_pointer<'this>(
35760 &'this mut self,
35761 window: types::xproto::Window,
35762 deviceid: impl Into<types::Device>,
35763 ) -> futures::SendRequest<'this, Self, ()> {
35764 let span = tracing::info_span!(
35765 "xinput_xi_set_client_pointer",
35766 window = ?window,
35767 );
35768 let request = types::xinput::XISetClientPointerRequest {
35769 window,
35770 deviceid: Into::<u32>::into(deviceid.into()) as _,
35771 };
35772 let cookie = self.send_void_request(request, true).with_span(span);
35773 cookie
35774 }
35775 #[cfg(feature = "xinput")]
35776 fn xinput_xi_set_client_pointer_checked<'this>(
35777 &'this mut self,
35778 window: types::xproto::Window,
35779 deviceid: impl Into<types::Device>,
35780 ) -> futures::CheckedSendRequest<'this, Self, ()> {
35781 let request = types::xinput::XISetClientPointerRequest {
35782 window,
35783 deviceid: Into::<u32>::into(deviceid.into()) as _,
35784 };
35785 let cookie = self.send_void_request(request, false);
35786 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
35787 res
35788 }
35789 #[cfg(feature = "xinput")]
35790 fn xinput_xi_get_client_pointer<'this>(
35791 &'this mut self,
35792 window: types::xproto::Window,
35793 ) -> futures::SendRequest<'this, Self, types::xinput::XIGetClientPointerReply> {
35794 let span = tracing::info_span!(
35795 "xinput_xi_get_client_pointer",
35796 window = ?window,
35797 );
35798 let request = types::xinput::XIGetClientPointerRequest { window };
35799 let cookie = self.send_reply_request(request).with_span(span);
35800 cookie
35801 }
35802 #[cfg(feature = "xinput")]
35803 fn xinput_xi_get_client_pointer_immediate<'this>(
35804 &'this mut self,
35805 window: types::xproto::Window,
35806 ) -> futures::CheckedSendRequest<'this, Self, types::xinput::XIGetClientPointerReply> {
35807 let request = types::xinput::XIGetClientPointerRequest { window };
35808 let cookie = self.send_reply_request(request);
35809 let res: futures::CheckedSendRequest<'this, Self, types::xinput::XIGetClientPointerReply> =
35810 cookie.into();
35811 res
35812 }
35813 #[cfg(feature = "xinput")]
35814 fn xinput_xi_select_events<'this>(
35815 &'this mut self,
35816 window: types::xproto::Window,
35817 masks: impl AsRef<[types::xinput::EventMask]>,
35818 ) -> futures::SendRequest<'this, Self, ()> {
35819 let span = tracing::info_span!(
35820 "xinput_xi_select_events",
35821 window = ?window,
35822 );
35823 let request = types::xinput::XISelectEventsRequest {
35824 window,
35825 masks: Cow::Borrowed(masks.as_ref()),
35826 };
35827 let cookie = self.send_void_request(request, true).with_span(span);
35828 cookie
35829 }
35830 #[cfg(feature = "xinput")]
35831 fn xinput_xi_select_events_checked<'this>(
35832 &'this mut self,
35833 window: types::xproto::Window,
35834 masks: impl AsRef<[types::xinput::EventMask]>,
35835 ) -> futures::CheckedSendRequest<'this, Self, ()> {
35836 let request = types::xinput::XISelectEventsRequest {
35837 window,
35838 masks: Cow::Borrowed(masks.as_ref()),
35839 };
35840 let cookie = self.send_void_request(request, false);
35841 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
35842 res
35843 }
35844 #[cfg(feature = "xinput")]
35845 fn xinput_xi_query_version<'this>(
35846 &'this mut self,
35847 major_version: types::Card16,
35848 minor_version: types::Card16,
35849 ) -> futures::SendRequest<'this, Self, types::xinput::XIQueryVersionReply> {
35850 let span = tracing::info_span!(
35851 "xinput_xi_query_version",
35852 major_version = ?major_version,
35853 minor_version = ?minor_version,
35854 );
35855 let request = types::xinput::XIQueryVersionRequest {
35856 major_version,
35857 minor_version,
35858 };
35859 let cookie = self.send_reply_request(request).with_span(span);
35860 cookie
35861 }
35862 #[cfg(feature = "xinput")]
35863 fn xinput_xi_query_version_immediate<'this>(
35864 &'this mut self,
35865 major_version: types::Card16,
35866 minor_version: types::Card16,
35867 ) -> futures::CheckedSendRequest<'this, Self, types::xinput::XIQueryVersionReply> {
35868 let request = types::xinput::XIQueryVersionRequest {
35869 major_version,
35870 minor_version,
35871 };
35872 let cookie = self.send_reply_request(request);
35873 let res: futures::CheckedSendRequest<'this, Self, types::xinput::XIQueryVersionReply> =
35874 cookie.into();
35875 res
35876 }
35877 #[cfg(feature = "xinput")]
35878 fn xinput_xi_query_device<'this>(
35879 &'this mut self,
35880 deviceid: impl Into<types::Device>,
35881 ) -> futures::SendRequest<'this, Self, types::xinput::XIQueryDeviceReply> {
35882 let span = tracing::info_span!("xinput_xi_query_device",);
35883 let request = types::xinput::XIQueryDeviceRequest {
35884 deviceid: Into::<u32>::into(deviceid.into()) as _,
35885 };
35886 let cookie = self.send_reply_request(request).with_span(span);
35887 cookie
35888 }
35889 #[cfg(feature = "xinput")]
35890 fn xinput_xi_query_device_immediate<'this>(
35891 &'this mut self,
35892 deviceid: impl Into<types::Device>,
35893 ) -> futures::CheckedSendRequest<'this, Self, types::xinput::XIQueryDeviceReply> {
35894 let request = types::xinput::XIQueryDeviceRequest {
35895 deviceid: Into::<u32>::into(deviceid.into()) as _,
35896 };
35897 let cookie = self.send_reply_request(request);
35898 let res: futures::CheckedSendRequest<'this, Self, types::xinput::XIQueryDeviceReply> =
35899 cookie.into();
35900 res
35901 }
35902 #[cfg(feature = "xinput")]
35903 fn xinput_xi_set_focus<'this>(
35904 &'this mut self,
35905 window: types::xproto::Window,
35906 time: impl Into<types::Time>,
35907 deviceid: impl Into<types::Device>,
35908 ) -> futures::SendRequest<'this, Self, ()> {
35909 let span = tracing::info_span!(
35910 "xinput_xi_set_focus",
35911 window = ?window,
35912 );
35913 let request = types::xinput::XISetFocusRequest {
35914 window,
35915 time: Into::<u32>::into(time.into()) as _,
35916 deviceid: Into::<u32>::into(deviceid.into()) as _,
35917 };
35918 let cookie = self.send_void_request(request, true).with_span(span);
35919 cookie
35920 }
35921 #[cfg(feature = "xinput")]
35922 fn xinput_xi_set_focus_checked<'this>(
35923 &'this mut self,
35924 window: types::xproto::Window,
35925 time: impl Into<types::Time>,
35926 deviceid: impl Into<types::Device>,
35927 ) -> futures::CheckedSendRequest<'this, Self, ()> {
35928 let request = types::xinput::XISetFocusRequest {
35929 window,
35930 time: Into::<u32>::into(time.into()) as _,
35931 deviceid: Into::<u32>::into(deviceid.into()) as _,
35932 };
35933 let cookie = self.send_void_request(request, false);
35934 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
35935 res
35936 }
35937 #[cfg(feature = "xinput")]
35938 fn xinput_xi_get_focus<'this>(
35939 &'this mut self,
35940 deviceid: impl Into<types::Device>,
35941 ) -> futures::SendRequest<'this, Self, types::xinput::XIGetFocusReply> {
35942 let span = tracing::info_span!("xinput_xi_get_focus",);
35943 let request = types::xinput::XIGetFocusRequest {
35944 deviceid: Into::<u32>::into(deviceid.into()) as _,
35945 };
35946 let cookie = self.send_reply_request(request).with_span(span);
35947 cookie
35948 }
35949 #[cfg(feature = "xinput")]
35950 fn xinput_xi_get_focus_immediate<'this>(
35951 &'this mut self,
35952 deviceid: impl Into<types::Device>,
35953 ) -> futures::CheckedSendRequest<'this, Self, types::xinput::XIGetFocusReply> {
35954 let request = types::xinput::XIGetFocusRequest {
35955 deviceid: Into::<u32>::into(deviceid.into()) as _,
35956 };
35957 let cookie = self.send_reply_request(request);
35958 let res: futures::CheckedSendRequest<'this, Self, types::xinput::XIGetFocusReply> =
35959 cookie.into();
35960 res
35961 }
35962 #[cfg(feature = "xinput")]
35963 fn xinput_xi_grab_device<'this>(
35964 &'this mut self,
35965 window: types::xproto::Window,
35966 time: impl Into<types::Time>,
35967 cursor: types::xproto::Cursor,
35968 deviceid: impl Into<types::Device>,
35969 mode: types::GrabMode,
35970 paired_device_mode: types::GrabMode,
35971 owner_events: types::GrabOwner,
35972 mask: impl AsRef<[types::Card32]>,
35973 ) -> futures::SendRequest<'this, Self, types::xinput::XIGrabDeviceReply> {
35974 let span = tracing::info_span!(
35975 "xinput_xi_grab_device",
35976 window = ?window,
35977 cursor = ?cursor,
35978 mode = ?mode,
35979 paired_device_mode = ?paired_device_mode,
35980 owner_events = ?owner_events,
35981 );
35982 let request = types::xinput::XIGrabDeviceRequest {
35983 window,
35984 time: Into::<u32>::into(time.into()) as _,
35985 cursor,
35986 deviceid: Into::<u32>::into(deviceid.into()) as _,
35987 mode,
35988 paired_device_mode,
35989 owner_events,
35990 mask: Cow::Borrowed(mask.as_ref()),
35991 };
35992 let cookie = self.send_reply_request(request).with_span(span);
35993 cookie
35994 }
35995 #[cfg(feature = "xinput")]
35996 fn xinput_xi_grab_device_immediate<'this>(
35997 &'this mut self,
35998 window: types::xproto::Window,
35999 time: impl Into<types::Time>,
36000 cursor: types::xproto::Cursor,
36001 deviceid: impl Into<types::Device>,
36002 mode: types::GrabMode,
36003 paired_device_mode: types::GrabMode,
36004 owner_events: types::GrabOwner,
36005 mask: impl AsRef<[types::Card32]>,
36006 ) -> futures::CheckedSendRequest<'this, Self, types::xinput::XIGrabDeviceReply> {
36007 let request = types::xinput::XIGrabDeviceRequest {
36008 window,
36009 time: Into::<u32>::into(time.into()) as _,
36010 cursor,
36011 deviceid: Into::<u32>::into(deviceid.into()) as _,
36012 mode,
36013 paired_device_mode,
36014 owner_events,
36015 mask: Cow::Borrowed(mask.as_ref()),
36016 };
36017 let cookie = self.send_reply_request(request);
36018 let res: futures::CheckedSendRequest<'this, Self, types::xinput::XIGrabDeviceReply> =
36019 cookie.into();
36020 res
36021 }
36022 #[cfg(feature = "xinput")]
36023 fn xinput_xi_ungrab_device<'this>(
36024 &'this mut self,
36025 time: impl Into<types::Time>,
36026 deviceid: impl Into<types::Device>,
36027 ) -> futures::SendRequest<'this, Self, ()> {
36028 let span = tracing::info_span!("xinput_xi_ungrab_device",);
36029 let request = types::xinput::XIUngrabDeviceRequest {
36030 time: Into::<u32>::into(time.into()) as _,
36031 deviceid: Into::<u32>::into(deviceid.into()) as _,
36032 };
36033 let cookie = self.send_void_request(request, true).with_span(span);
36034 cookie
36035 }
36036 #[cfg(feature = "xinput")]
36037 fn xinput_xi_ungrab_device_checked<'this>(
36038 &'this mut self,
36039 time: impl Into<types::Time>,
36040 deviceid: impl Into<types::Device>,
36041 ) -> futures::CheckedSendRequest<'this, Self, ()> {
36042 let request = types::xinput::XIUngrabDeviceRequest {
36043 time: Into::<u32>::into(time.into()) as _,
36044 deviceid: Into::<u32>::into(deviceid.into()) as _,
36045 };
36046 let cookie = self.send_void_request(request, false);
36047 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
36048 res
36049 }
36050 #[cfg(feature = "xinput")]
36051 fn xinput_xi_allow_events<'this>(
36052 &'this mut self,
36053 time: impl Into<types::Time>,
36054 deviceid: impl Into<types::Device>,
36055 event_mode: types::EventMode,
36056 touchid: types::Card32,
36057 grab_window: types::xproto::Window,
36058 ) -> futures::SendRequest<'this, Self, ()> {
36059 let span = tracing::info_span!(
36060 "xinput_xi_allow_events",
36061 event_mode = ?event_mode,
36062 touchid = ?touchid,
36063 grab_window = ?grab_window,
36064 );
36065 let request = types::xinput::XIAllowEventsRequest {
36066 time: Into::<u32>::into(time.into()) as _,
36067 deviceid: Into::<u32>::into(deviceid.into()) as _,
36068 event_mode,
36069 touchid,
36070 grab_window,
36071 };
36072 let cookie = self.send_void_request(request, true).with_span(span);
36073 cookie
36074 }
36075 #[cfg(feature = "xinput")]
36076 fn xinput_xi_allow_events_checked<'this>(
36077 &'this mut self,
36078 time: impl Into<types::Time>,
36079 deviceid: impl Into<types::Device>,
36080 event_mode: types::EventMode,
36081 touchid: types::Card32,
36082 grab_window: types::xproto::Window,
36083 ) -> futures::CheckedSendRequest<'this, Self, ()> {
36084 let request = types::xinput::XIAllowEventsRequest {
36085 time: Into::<u32>::into(time.into()) as _,
36086 deviceid: Into::<u32>::into(deviceid.into()) as _,
36087 event_mode,
36088 touchid,
36089 grab_window,
36090 };
36091 let cookie = self.send_void_request(request, false);
36092 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
36093 res
36094 }
36095 #[cfg(feature = "xinput")]
36096 fn xinput_xi_passive_grab_device<'this>(
36097 &'this mut self,
36098 time: impl Into<types::Time>,
36099 grab_window: types::xproto::Window,
36100 cursor: types::xproto::Cursor,
36101 detail: types::Card32,
36102 deviceid: impl Into<types::Device>,
36103 grab_type: types::GrabType,
36104 grab_mode: types::GrabMode22,
36105 paired_device_mode: types::GrabMode,
36106 owner_events: types::GrabOwner,
36107 mask: impl AsRef<[types::Card32]>,
36108 modifiers: impl AsRef<[types::Card32]>,
36109 ) -> futures::SendRequest<'this, Self, types::xinput::XIPassiveGrabDeviceReply> {
36110 let span = tracing::info_span!(
36111 "xinput_xi_passive_grab_device",
36112 grab_window = ?grab_window,
36113 cursor = ?cursor,
36114 detail = ?detail,
36115 grab_type = ?grab_type,
36116 grab_mode = ?grab_mode,
36117 paired_device_mode = ?paired_device_mode,
36118 owner_events = ?owner_events,
36119 );
36120 let request = types::xinput::XIPassiveGrabDeviceRequest {
36121 time: Into::<u32>::into(time.into()) as _,
36122 grab_window,
36123 cursor,
36124 detail,
36125 deviceid: Into::<u32>::into(deviceid.into()) as _,
36126 grab_type,
36127 grab_mode,
36128 paired_device_mode,
36129 owner_events,
36130 mask: Cow::Borrowed(mask.as_ref()),
36131 modifiers: Cow::Borrowed(modifiers.as_ref()),
36132 };
36133 let cookie = self.send_reply_request(request).with_span(span);
36134 cookie
36135 }
36136 #[cfg(feature = "xinput")]
36137 fn xinput_xi_passive_grab_device_immediate<'this>(
36138 &'this mut self,
36139 time: impl Into<types::Time>,
36140 grab_window: types::xproto::Window,
36141 cursor: types::xproto::Cursor,
36142 detail: types::Card32,
36143 deviceid: impl Into<types::Device>,
36144 grab_type: types::GrabType,
36145 grab_mode: types::GrabMode22,
36146 paired_device_mode: types::GrabMode,
36147 owner_events: types::GrabOwner,
36148 mask: impl AsRef<[types::Card32]>,
36149 modifiers: impl AsRef<[types::Card32]>,
36150 ) -> futures::CheckedSendRequest<'this, Self, types::xinput::XIPassiveGrabDeviceReply> {
36151 let request = types::xinput::XIPassiveGrabDeviceRequest {
36152 time: Into::<u32>::into(time.into()) as _,
36153 grab_window,
36154 cursor,
36155 detail,
36156 deviceid: Into::<u32>::into(deviceid.into()) as _,
36157 grab_type,
36158 grab_mode,
36159 paired_device_mode,
36160 owner_events,
36161 mask: Cow::Borrowed(mask.as_ref()),
36162 modifiers: Cow::Borrowed(modifiers.as_ref()),
36163 };
36164 let cookie = self.send_reply_request(request);
36165 let res: futures::CheckedSendRequest<'this, Self, types::xinput::XIPassiveGrabDeviceReply> =
36166 cookie.into();
36167 res
36168 }
36169 #[cfg(feature = "xinput")]
36170 fn xinput_xi_passive_ungrab_device<'this>(
36171 &'this mut self,
36172 grab_window: types::xproto::Window,
36173 detail: types::Card32,
36174 deviceid: impl Into<types::Device>,
36175 grab_type: types::GrabType,
36176 modifiers: impl AsRef<[types::Card32]>,
36177 ) -> futures::SendRequest<'this, Self, ()> {
36178 let span = tracing::info_span!(
36179 "xinput_xi_passive_ungrab_device",
36180 grab_window = ?grab_window,
36181 detail = ?detail,
36182 grab_type = ?grab_type,
36183 );
36184 let request = types::xinput::XIPassiveUngrabDeviceRequest {
36185 grab_window,
36186 detail,
36187 deviceid: Into::<u32>::into(deviceid.into()) as _,
36188 grab_type,
36189 modifiers: Cow::Borrowed(modifiers.as_ref()),
36190 };
36191 let cookie = self.send_void_request(request, true).with_span(span);
36192 cookie
36193 }
36194 #[cfg(feature = "xinput")]
36195 fn xinput_xi_passive_ungrab_device_checked<'this>(
36196 &'this mut self,
36197 grab_window: types::xproto::Window,
36198 detail: types::Card32,
36199 deviceid: impl Into<types::Device>,
36200 grab_type: types::GrabType,
36201 modifiers: impl AsRef<[types::Card32]>,
36202 ) -> futures::CheckedSendRequest<'this, Self, ()> {
36203 let request = types::xinput::XIPassiveUngrabDeviceRequest {
36204 grab_window,
36205 detail,
36206 deviceid: Into::<u32>::into(deviceid.into()) as _,
36207 grab_type,
36208 modifiers: Cow::Borrowed(modifiers.as_ref()),
36209 };
36210 let cookie = self.send_void_request(request, false);
36211 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
36212 res
36213 }
36214 #[cfg(feature = "xinput")]
36215 fn xinput_xi_list_properties<'this>(
36216 &'this mut self,
36217 deviceid: impl Into<types::Device>,
36218 ) -> futures::SendRequest<'this, Self, types::xinput::XIListPropertiesReply> {
36219 let span = tracing::info_span!("xinput_xi_list_properties",);
36220 let request = types::xinput::XIListPropertiesRequest {
36221 deviceid: Into::<u32>::into(deviceid.into()) as _,
36222 };
36223 let cookie = self.send_reply_request(request).with_span(span);
36224 cookie
36225 }
36226 #[cfg(feature = "xinput")]
36227 fn xinput_xi_list_properties_immediate<'this>(
36228 &'this mut self,
36229 deviceid: impl Into<types::Device>,
36230 ) -> futures::CheckedSendRequest<'this, Self, types::xinput::XIListPropertiesReply> {
36231 let request = types::xinput::XIListPropertiesRequest {
36232 deviceid: Into::<u32>::into(deviceid.into()) as _,
36233 };
36234 let cookie = self.send_reply_request(request);
36235 let res: futures::CheckedSendRequest<'this, Self, types::xinput::XIListPropertiesReply> =
36236 cookie.into();
36237 res
36238 }
36239 #[cfg(feature = "xinput")]
36240 fn xinput_xi_change_property<'this>(
36241 &'this mut self,
36242 deviceid: impl Into<types::Device>,
36243 mode: types::PropMode,
36244 property: types::Atom,
36245 type_: types::Atom,
36246 num_items: types::Card32,
36247 items: impl Borrow<types::xinput::XIChangePropertyAux>,
36248 ) -> futures::SendRequest<'this, Self, ()> {
36249 let span = tracing::info_span!(
36250 "xinput_xi_change_property",
36251 mode = ?mode,
36252 property = ?property,
36253 type_ = ?type_,
36254 num_items = ?num_items,
36255 );
36256 let request = types::xinput::XIChangePropertyRequest {
36257 deviceid: Into::<u32>::into(deviceid.into()) as _,
36258 mode,
36259 property,
36260 type_,
36261 num_items,
36262 items: Cow::Borrowed(items.borrow()),
36263 };
36264 let cookie = self.send_void_request(request, true).with_span(span);
36265 cookie
36266 }
36267 #[cfg(feature = "xinput")]
36268 fn xinput_xi_change_property_checked<'this>(
36269 &'this mut self,
36270 deviceid: impl Into<types::Device>,
36271 mode: types::PropMode,
36272 property: types::Atom,
36273 type_: types::Atom,
36274 num_items: types::Card32,
36275 items: impl Borrow<types::xinput::XIChangePropertyAux>,
36276 ) -> futures::CheckedSendRequest<'this, Self, ()> {
36277 let request = types::xinput::XIChangePropertyRequest {
36278 deviceid: Into::<u32>::into(deviceid.into()) as _,
36279 mode,
36280 property,
36281 type_,
36282 num_items,
36283 items: Cow::Borrowed(items.borrow()),
36284 };
36285 let cookie = self.send_void_request(request, false);
36286 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
36287 res
36288 }
36289 #[cfg(feature = "xinput")]
36290 fn xinput_xi_delete_property<'this>(
36291 &'this mut self,
36292 deviceid: impl Into<types::Device>,
36293 property: types::Atom,
36294 ) -> futures::SendRequest<'this, Self, ()> {
36295 let span = tracing::info_span!(
36296 "xinput_xi_delete_property",
36297 property = ?property,
36298 );
36299 let request = types::xinput::XIDeletePropertyRequest {
36300 deviceid: Into::<u32>::into(deviceid.into()) as _,
36301 property,
36302 };
36303 let cookie = self.send_void_request(request, true).with_span(span);
36304 cookie
36305 }
36306 #[cfg(feature = "xinput")]
36307 fn xinput_xi_delete_property_checked<'this>(
36308 &'this mut self,
36309 deviceid: impl Into<types::Device>,
36310 property: types::Atom,
36311 ) -> futures::CheckedSendRequest<'this, Self, ()> {
36312 let request = types::xinput::XIDeletePropertyRequest {
36313 deviceid: Into::<u32>::into(deviceid.into()) as _,
36314 property,
36315 };
36316 let cookie = self.send_void_request(request, false);
36317 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
36318 res
36319 }
36320 #[cfg(feature = "xinput")]
36321 fn xinput_xi_get_property<'this>(
36322 &'this mut self,
36323 deviceid: impl Into<types::Device>,
36324 delete: types::Bool,
36325 property: types::Atom,
36326 type_: types::Atom,
36327 offset: types::Card32,
36328 len: types::Card32,
36329 ) -> futures::SendRequest<'this, Self, types::xinput::XIGetPropertyReply> {
36330 let span = tracing::info_span!(
36331 "xinput_xi_get_property",
36332 delete = ?delete,
36333 property = ?property,
36334 type_ = ?type_,
36335 offset = ?offset,
36336 len = ?len,
36337 );
36338 let request = types::xinput::XIGetPropertyRequest {
36339 deviceid: Into::<u32>::into(deviceid.into()) as _,
36340 delete,
36341 property,
36342 type_,
36343 offset,
36344 len,
36345 };
36346 let cookie = self.send_reply_request(request).with_span(span);
36347 cookie
36348 }
36349 #[cfg(feature = "xinput")]
36350 fn xinput_xi_get_property_immediate<'this>(
36351 &'this mut self,
36352 deviceid: impl Into<types::Device>,
36353 delete: types::Bool,
36354 property: types::Atom,
36355 type_: types::Atom,
36356 offset: types::Card32,
36357 len: types::Card32,
36358 ) -> futures::CheckedSendRequest<'this, Self, types::xinput::XIGetPropertyReply> {
36359 let request = types::xinput::XIGetPropertyRequest {
36360 deviceid: Into::<u32>::into(deviceid.into()) as _,
36361 delete,
36362 property,
36363 type_,
36364 offset,
36365 len,
36366 };
36367 let cookie = self.send_reply_request(request);
36368 let res: futures::CheckedSendRequest<'this, Self, types::xinput::XIGetPropertyReply> =
36369 cookie.into();
36370 res
36371 }
36372 #[cfg(feature = "xinput")]
36373 fn xinput_xi_get_selected_events<'this>(
36374 &'this mut self,
36375 window: types::xproto::Window,
36376 ) -> futures::SendRequest<'this, Self, types::xinput::XIGetSelectedEventsReply> {
36377 let span = tracing::info_span!(
36378 "xinput_xi_get_selected_events",
36379 window = ?window,
36380 );
36381 let request = types::xinput::XIGetSelectedEventsRequest { window };
36382 let cookie = self.send_reply_request(request).with_span(span);
36383 cookie
36384 }
36385 #[cfg(feature = "xinput")]
36386 fn xinput_xi_get_selected_events_immediate<'this>(
36387 &'this mut self,
36388 window: types::xproto::Window,
36389 ) -> futures::CheckedSendRequest<'this, Self, types::xinput::XIGetSelectedEventsReply> {
36390 let request = types::xinput::XIGetSelectedEventsRequest { window };
36391 let cookie = self.send_reply_request(request);
36392 let res: futures::CheckedSendRequest<'this, Self, types::xinput::XIGetSelectedEventsReply> =
36393 cookie.into();
36394 res
36395 }
36396 #[cfg(feature = "xinput")]
36397 fn xinput_xi_barrier_release_pointer<'this>(
36398 &'this mut self,
36399 barriers: impl AsRef<[types::BarrierReleasePointerInfo]>,
36400 ) -> futures::SendRequest<'this, Self, ()> {
36401 let span = tracing::info_span!("xinput_xi_barrier_release_pointer",);
36402 let request = types::xinput::XIBarrierReleasePointerRequest {
36403 barriers: Cow::Borrowed(barriers.as_ref()),
36404 };
36405 let cookie = self.send_void_request(request, true).with_span(span);
36406 cookie
36407 }
36408 #[cfg(feature = "xinput")]
36409 fn xinput_xi_barrier_release_pointer_checked<'this>(
36410 &'this mut self,
36411 barriers: impl AsRef<[types::BarrierReleasePointerInfo]>,
36412 ) -> futures::CheckedSendRequest<'this, Self, ()> {
36413 let request = types::xinput::XIBarrierReleasePointerRequest {
36414 barriers: Cow::Borrowed(barriers.as_ref()),
36415 };
36416 let cookie = self.send_void_request(request, false);
36417 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
36418 res
36419 }
36420 #[cfg(feature = "xinput")]
36421 fn xinput_send_extension_event<'this>(
36422 &'this mut self,
36423 destination: types::xproto::Window,
36424 device_id: types::Card8,
36425 propagate: types::Bool,
36426 events: impl AsRef<[types::EventForSend]>,
36427 classes: impl AsRef<[types::EventClass]>,
36428 ) -> futures::SendRequest<'this, Self, ()> {
36429 let span = tracing::info_span!(
36430 "xinput_send_extension_event",
36431 destination = ?destination,
36432 device_id = ?device_id,
36433 propagate = ?propagate,
36434 );
36435 let request = types::xinput::SendExtensionEventRequest {
36436 destination,
36437 device_id,
36438 propagate,
36439 events: Cow::Borrowed(events.as_ref()),
36440 classes: Cow::Borrowed(classes.as_ref()),
36441 };
36442 let cookie = self.send_void_request(request, true).with_span(span);
36443 cookie
36444 }
36445 #[cfg(feature = "xinput")]
36446 fn xinput_send_extension_event_checked<'this>(
36447 &'this mut self,
36448 destination: types::xproto::Window,
36449 device_id: types::Card8,
36450 propagate: types::Bool,
36451 events: impl AsRef<[types::EventForSend]>,
36452 classes: impl AsRef<[types::EventClass]>,
36453 ) -> futures::CheckedSendRequest<'this, Self, ()> {
36454 let request = types::xinput::SendExtensionEventRequest {
36455 destination,
36456 device_id,
36457 propagate,
36458 events: Cow::Borrowed(events.as_ref()),
36459 classes: Cow::Borrowed(classes.as_ref()),
36460 };
36461 let cookie = self.send_void_request(request, false);
36462 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
36463 res
36464 }
36465
36466 #[cfg(feature = "xkb")]
36467 fn xkb_use_extension<'this>(
36468 &'this mut self,
36469 wanted_major: types::Card16,
36470 wanted_minor: types::Card16,
36471 ) -> futures::SendRequest<'this, Self, types::xkb::UseExtensionReply> {
36472 let span = tracing::info_span!(
36473 "xkb_use_extension",
36474 wanted_major = ?wanted_major,
36475 wanted_minor = ?wanted_minor,
36476 );
36477 let request = types::xkb::UseExtensionRequest {
36478 wanted_major,
36479 wanted_minor,
36480 };
36481 let cookie = self.send_reply_request(request).with_span(span);
36482 cookie
36483 }
36484 #[cfg(feature = "xkb")]
36485 fn xkb_use_extension_immediate<'this>(
36486 &'this mut self,
36487 wanted_major: types::Card16,
36488 wanted_minor: types::Card16,
36489 ) -> futures::CheckedSendRequest<'this, Self, types::xkb::UseExtensionReply> {
36490 let request = types::xkb::UseExtensionRequest {
36491 wanted_major,
36492 wanted_minor,
36493 };
36494 let cookie = self.send_reply_request(request);
36495 let res: futures::CheckedSendRequest<'this, Self, types::xkb::UseExtensionReply> =
36496 cookie.into();
36497 res
36498 }
36499 #[cfg(feature = "xkb")]
36500 fn xkb_select_events<'this>(
36501 &'this mut self,
36502 device_spec: types::DeviceSpec,
36503 clear: impl Into<types::xkb::EventType>,
36504 select_all: impl Into<types::xkb::EventType>,
36505 affect_map: impl Into<types::MapPart>,
36506 map: impl Into<types::MapPart>,
36507 details: impl Borrow<types::xkb::SelectEventsAux>,
36508 ) -> futures::SendRequest<'this, Self, ()> {
36509 let span = tracing::info_span!(
36510 "xkb_select_events",
36511 device_spec = ?device_spec,
36512 );
36513 let request = types::xkb::SelectEventsRequest {
36514 device_spec,
36515 clear: Into::<u32>::into(clear.into()) as _,
36516 select_all: Into::<u32>::into(select_all.into()) as _,
36517 affect_map: Into::<u32>::into(affect_map.into()) as _,
36518 map: Into::<u32>::into(map.into()) as _,
36519 details: Cow::Borrowed(details.borrow()),
36520 };
36521 let cookie = self.send_void_request(request, true).with_span(span);
36522 cookie
36523 }
36524 #[cfg(feature = "xkb")]
36525 fn xkb_select_events_checked<'this>(
36526 &'this mut self,
36527 device_spec: types::DeviceSpec,
36528 clear: impl Into<types::xkb::EventType>,
36529 select_all: impl Into<types::xkb::EventType>,
36530 affect_map: impl Into<types::MapPart>,
36531 map: impl Into<types::MapPart>,
36532 details: impl Borrow<types::xkb::SelectEventsAux>,
36533 ) -> futures::CheckedSendRequest<'this, Self, ()> {
36534 let request = types::xkb::SelectEventsRequest {
36535 device_spec,
36536 clear: Into::<u32>::into(clear.into()) as _,
36537 select_all: Into::<u32>::into(select_all.into()) as _,
36538 affect_map: Into::<u32>::into(affect_map.into()) as _,
36539 map: Into::<u32>::into(map.into()) as _,
36540 details: Cow::Borrowed(details.borrow()),
36541 };
36542 let cookie = self.send_void_request(request, false);
36543 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
36544 res
36545 }
36546 #[cfg(feature = "xkb")]
36547 fn xkb_bell<'this>(
36548 &'this mut self,
36549 device_spec: types::DeviceSpec,
36550 bell_class: types::BellClassSpec,
36551 bell_id: types::IDSpec,
36552 percent: types::Int8,
36553 force_sound: types::Bool,
36554 event_only: types::Bool,
36555 pitch: types::Int16,
36556 duration: types::Int16,
36557 name: types::Atom,
36558 window: types::xproto::Window,
36559 ) -> futures::SendRequest<'this, Self, ()> {
36560 let span = tracing::info_span!(
36561 "xkb_bell",
36562 device_spec = ?device_spec,
36563 bell_class = ?bell_class,
36564 bell_id = ?bell_id,
36565 percent = ?percent,
36566 force_sound = ?force_sound,
36567 event_only = ?event_only,
36568 pitch = ?pitch,
36569 duration = ?duration,
36570 name = ?name,
36571 window = ?window,
36572 );
36573 let request = types::xkb::BellRequest {
36574 device_spec,
36575 bell_class,
36576 bell_id,
36577 percent,
36578 force_sound,
36579 event_only,
36580 pitch,
36581 duration,
36582 name,
36583 window,
36584 };
36585 let cookie = self.send_void_request(request, true).with_span(span);
36586 cookie
36587 }
36588 #[cfg(feature = "xkb")]
36589 fn xkb_bell_checked<'this>(
36590 &'this mut self,
36591 device_spec: types::DeviceSpec,
36592 bell_class: types::BellClassSpec,
36593 bell_id: types::IDSpec,
36594 percent: types::Int8,
36595 force_sound: types::Bool,
36596 event_only: types::Bool,
36597 pitch: types::Int16,
36598 duration: types::Int16,
36599 name: types::Atom,
36600 window: types::xproto::Window,
36601 ) -> futures::CheckedSendRequest<'this, Self, ()> {
36602 let request = types::xkb::BellRequest {
36603 device_spec,
36604 bell_class,
36605 bell_id,
36606 percent,
36607 force_sound,
36608 event_only,
36609 pitch,
36610 duration,
36611 name,
36612 window,
36613 };
36614 let cookie = self.send_void_request(request, false);
36615 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
36616 res
36617 }
36618 #[cfg(feature = "xkb")]
36619 fn xkb_get_state<'this>(
36620 &'this mut self,
36621 device_spec: types::DeviceSpec,
36622 ) -> futures::SendRequest<'this, Self, types::xkb::GetStateReply> {
36623 let span = tracing::info_span!(
36624 "xkb_get_state",
36625 device_spec = ?device_spec,
36626 );
36627 let request = types::xkb::GetStateRequest { device_spec };
36628 let cookie = self.send_reply_request(request).with_span(span);
36629 cookie
36630 }
36631 #[cfg(feature = "xkb")]
36632 fn xkb_get_state_immediate<'this>(
36633 &'this mut self,
36634 device_spec: types::DeviceSpec,
36635 ) -> futures::CheckedSendRequest<'this, Self, types::xkb::GetStateReply> {
36636 let request = types::xkb::GetStateRequest { device_spec };
36637 let cookie = self.send_reply_request(request);
36638 let res: futures::CheckedSendRequest<'this, Self, types::xkb::GetStateReply> =
36639 cookie.into();
36640 res
36641 }
36642 #[cfg(feature = "xkb")]
36643 fn xkb_latch_lock_state<'this>(
36644 &'this mut self,
36645 device_spec: types::DeviceSpec,
36646 affect_mod_locks: impl Into<types::ModMask>,
36647 mod_locks: impl Into<types::ModMask>,
36648 lock_group: types::Bool,
36649 group_lock: types::Group,
36650 affect_mod_latches: impl Into<types::ModMask>,
36651 latch_group: types::Bool,
36652 group_latch: types::Card16,
36653 ) -> futures::SendRequest<'this, Self, ()> {
36654 let span = tracing::info_span!(
36655 "xkb_latch_lock_state",
36656 device_spec = ?device_spec,
36657 lock_group = ?lock_group,
36658 group_lock = ?group_lock,
36659 latch_group = ?latch_group,
36660 group_latch = ?group_latch,
36661 );
36662 let request = types::xkb::LatchLockStateRequest {
36663 device_spec,
36664 affect_mod_locks: Into::<u32>::into(affect_mod_locks.into()) as _,
36665 mod_locks: Into::<u32>::into(mod_locks.into()) as _,
36666 lock_group,
36667 group_lock,
36668 affect_mod_latches: Into::<u32>::into(affect_mod_latches.into()) as _,
36669 latch_group,
36670 group_latch,
36671 };
36672 let cookie = self.send_void_request(request, true).with_span(span);
36673 cookie
36674 }
36675 #[cfg(feature = "xkb")]
36676 fn xkb_latch_lock_state_checked<'this>(
36677 &'this mut self,
36678 device_spec: types::DeviceSpec,
36679 affect_mod_locks: impl Into<types::ModMask>,
36680 mod_locks: impl Into<types::ModMask>,
36681 lock_group: types::Bool,
36682 group_lock: types::Group,
36683 affect_mod_latches: impl Into<types::ModMask>,
36684 latch_group: types::Bool,
36685 group_latch: types::Card16,
36686 ) -> futures::CheckedSendRequest<'this, Self, ()> {
36687 let request = types::xkb::LatchLockStateRequest {
36688 device_spec,
36689 affect_mod_locks: Into::<u32>::into(affect_mod_locks.into()) as _,
36690 mod_locks: Into::<u32>::into(mod_locks.into()) as _,
36691 lock_group,
36692 group_lock,
36693 affect_mod_latches: Into::<u32>::into(affect_mod_latches.into()) as _,
36694 latch_group,
36695 group_latch,
36696 };
36697 let cookie = self.send_void_request(request, false);
36698 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
36699 res
36700 }
36701 #[cfg(feature = "xkb")]
36702 fn xkb_get_controls<'this>(
36703 &'this mut self,
36704 device_spec: types::DeviceSpec,
36705 ) -> futures::SendRequest<'this, Self, types::xkb::GetControlsReply> {
36706 let span = tracing::info_span!(
36707 "xkb_get_controls",
36708 device_spec = ?device_spec,
36709 );
36710 let request = types::xkb::GetControlsRequest { device_spec };
36711 let cookie = self.send_reply_request(request).with_span(span);
36712 cookie
36713 }
36714 #[cfg(feature = "xkb")]
36715 fn xkb_get_controls_immediate<'this>(
36716 &'this mut self,
36717 device_spec: types::DeviceSpec,
36718 ) -> futures::CheckedSendRequest<'this, Self, types::xkb::GetControlsReply> {
36719 let request = types::xkb::GetControlsRequest { device_spec };
36720 let cookie = self.send_reply_request(request);
36721 let res: futures::CheckedSendRequest<'this, Self, types::xkb::GetControlsReply> =
36722 cookie.into();
36723 res
36724 }
36725 #[cfg(feature = "xkb")]
36726 fn xkb_set_controls<'this>(
36727 &'this mut self,
36728 device_spec: types::DeviceSpec,
36729 affect_internal_real_mods: impl Into<types::ModMask>,
36730 internal_real_mods: impl Into<types::ModMask>,
36731 affect_ignore_lock_real_mods: impl Into<types::ModMask>,
36732 ignore_lock_real_mods: impl Into<types::ModMask>,
36733 affect_internal_virtual_mods: impl Into<types::VMod>,
36734 internal_virtual_mods: impl Into<types::VMod>,
36735 affect_ignore_lock_virtual_mods: impl Into<types::VMod>,
36736 ignore_lock_virtual_mods: impl Into<types::VMod>,
36737 mouse_keys_dflt_btn: types::Card8,
36738 groups_wrap: types::Card8,
36739 access_x_options: impl Into<types::AXOption>,
36740 affect_enabled_controls: impl Into<types::BoolCtrl>,
36741 enabled_controls: impl Into<types::BoolCtrl>,
36742 change_controls: impl Into<types::Control>,
36743 repeat_delay: types::Card16,
36744 repeat_interval: types::Card16,
36745 slow_keys_delay: types::Card16,
36746 debounce_delay: types::Card16,
36747 mouse_keys_delay: types::Card16,
36748 mouse_keys_interval: types::Card16,
36749 mouse_keys_time_to_max: types::Card16,
36750 mouse_keys_max_speed: types::Card16,
36751 mouse_keys_curve: types::Int16,
36752 access_x_timeout: types::Card16,
36753 access_x_timeout_mask: impl Into<types::BoolCtrl>,
36754 access_x_timeout_values: impl Into<types::BoolCtrl>,
36755 access_x_timeout_options_mask: impl Into<types::AXOption>,
36756 access_x_timeout_options_values: impl Into<types::AXOption>,
36757 per_key_repeat: impl Borrow<[types::Card8; 32]>,
36758 ) -> futures::SendRequest<'this, Self, ()> {
36759 let span = tracing::info_span!(
36760 "xkb_set_controls",
36761 device_spec = ?device_spec,
36762 mouse_keys_dflt_btn = ?mouse_keys_dflt_btn,
36763 groups_wrap = ?groups_wrap,
36764 repeat_delay = ?repeat_delay,
36765 repeat_interval = ?repeat_interval,
36766 slow_keys_delay = ?slow_keys_delay,
36767 debounce_delay = ?debounce_delay,
36768 mouse_keys_delay = ?mouse_keys_delay,
36769 mouse_keys_interval = ?mouse_keys_interval,
36770 mouse_keys_time_to_max = ?mouse_keys_time_to_max,
36771 mouse_keys_max_speed = ?mouse_keys_max_speed,
36772 mouse_keys_curve = ?mouse_keys_curve,
36773 access_x_timeout = ?access_x_timeout,
36774 );
36775 let request = types::xkb::SetControlsRequest {
36776 device_spec,
36777 affect_internal_real_mods: Into::<u32>::into(affect_internal_real_mods.into()) as _,
36778 internal_real_mods: Into::<u32>::into(internal_real_mods.into()) as _,
36779 affect_ignore_lock_real_mods: Into::<u32>::into(affect_ignore_lock_real_mods.into())
36780 as _,
36781 ignore_lock_real_mods: Into::<u32>::into(ignore_lock_real_mods.into()) as _,
36782 affect_internal_virtual_mods: Into::<u32>::into(affect_internal_virtual_mods.into())
36783 as _,
36784 internal_virtual_mods: Into::<u32>::into(internal_virtual_mods.into()) as _,
36785 affect_ignore_lock_virtual_mods: Into::<u32>::into(
36786 affect_ignore_lock_virtual_mods.into(),
36787 ) as _,
36788 ignore_lock_virtual_mods: Into::<u32>::into(ignore_lock_virtual_mods.into()) as _,
36789 mouse_keys_dflt_btn,
36790 groups_wrap,
36791 access_x_options: Into::<u32>::into(access_x_options.into()) as _,
36792 affect_enabled_controls: Into::<u32>::into(affect_enabled_controls.into()) as _,
36793 enabled_controls: Into::<u32>::into(enabled_controls.into()) as _,
36794 change_controls: Into::<u32>::into(change_controls.into()) as _,
36795 repeat_delay,
36796 repeat_interval,
36797 slow_keys_delay,
36798 debounce_delay,
36799 mouse_keys_delay,
36800 mouse_keys_interval,
36801 mouse_keys_time_to_max,
36802 mouse_keys_max_speed,
36803 mouse_keys_curve,
36804 access_x_timeout,
36805 access_x_timeout_mask: Into::<u32>::into(access_x_timeout_mask.into()) as _,
36806 access_x_timeout_values: Into::<u32>::into(access_x_timeout_values.into()) as _,
36807 access_x_timeout_options_mask: Into::<u32>::into(access_x_timeout_options_mask.into())
36808 as _,
36809 access_x_timeout_options_values: Into::<u32>::into(
36810 access_x_timeout_options_values.into(),
36811 ) as _,
36812 per_key_repeat: Cow::Borrowed(per_key_repeat.borrow()),
36813 };
36814 let cookie = self.send_void_request(request, true).with_span(span);
36815 cookie
36816 }
36817 #[cfg(feature = "xkb")]
36818 fn xkb_set_controls_checked<'this>(
36819 &'this mut self,
36820 device_spec: types::DeviceSpec,
36821 affect_internal_real_mods: impl Into<types::ModMask>,
36822 internal_real_mods: impl Into<types::ModMask>,
36823 affect_ignore_lock_real_mods: impl Into<types::ModMask>,
36824 ignore_lock_real_mods: impl Into<types::ModMask>,
36825 affect_internal_virtual_mods: impl Into<types::VMod>,
36826 internal_virtual_mods: impl Into<types::VMod>,
36827 affect_ignore_lock_virtual_mods: impl Into<types::VMod>,
36828 ignore_lock_virtual_mods: impl Into<types::VMod>,
36829 mouse_keys_dflt_btn: types::Card8,
36830 groups_wrap: types::Card8,
36831 access_x_options: impl Into<types::AXOption>,
36832 affect_enabled_controls: impl Into<types::BoolCtrl>,
36833 enabled_controls: impl Into<types::BoolCtrl>,
36834 change_controls: impl Into<types::Control>,
36835 repeat_delay: types::Card16,
36836 repeat_interval: types::Card16,
36837 slow_keys_delay: types::Card16,
36838 debounce_delay: types::Card16,
36839 mouse_keys_delay: types::Card16,
36840 mouse_keys_interval: types::Card16,
36841 mouse_keys_time_to_max: types::Card16,
36842 mouse_keys_max_speed: types::Card16,
36843 mouse_keys_curve: types::Int16,
36844 access_x_timeout: types::Card16,
36845 access_x_timeout_mask: impl Into<types::BoolCtrl>,
36846 access_x_timeout_values: impl Into<types::BoolCtrl>,
36847 access_x_timeout_options_mask: impl Into<types::AXOption>,
36848 access_x_timeout_options_values: impl Into<types::AXOption>,
36849 per_key_repeat: impl Borrow<[types::Card8; 32]>,
36850 ) -> futures::CheckedSendRequest<'this, Self, ()> {
36851 let request = types::xkb::SetControlsRequest {
36852 device_spec,
36853 affect_internal_real_mods: Into::<u32>::into(affect_internal_real_mods.into()) as _,
36854 internal_real_mods: Into::<u32>::into(internal_real_mods.into()) as _,
36855 affect_ignore_lock_real_mods: Into::<u32>::into(affect_ignore_lock_real_mods.into())
36856 as _,
36857 ignore_lock_real_mods: Into::<u32>::into(ignore_lock_real_mods.into()) as _,
36858 affect_internal_virtual_mods: Into::<u32>::into(affect_internal_virtual_mods.into())
36859 as _,
36860 internal_virtual_mods: Into::<u32>::into(internal_virtual_mods.into()) as _,
36861 affect_ignore_lock_virtual_mods: Into::<u32>::into(
36862 affect_ignore_lock_virtual_mods.into(),
36863 ) as _,
36864 ignore_lock_virtual_mods: Into::<u32>::into(ignore_lock_virtual_mods.into()) as _,
36865 mouse_keys_dflt_btn,
36866 groups_wrap,
36867 access_x_options: Into::<u32>::into(access_x_options.into()) as _,
36868 affect_enabled_controls: Into::<u32>::into(affect_enabled_controls.into()) as _,
36869 enabled_controls: Into::<u32>::into(enabled_controls.into()) as _,
36870 change_controls: Into::<u32>::into(change_controls.into()) as _,
36871 repeat_delay,
36872 repeat_interval,
36873 slow_keys_delay,
36874 debounce_delay,
36875 mouse_keys_delay,
36876 mouse_keys_interval,
36877 mouse_keys_time_to_max,
36878 mouse_keys_max_speed,
36879 mouse_keys_curve,
36880 access_x_timeout,
36881 access_x_timeout_mask: Into::<u32>::into(access_x_timeout_mask.into()) as _,
36882 access_x_timeout_values: Into::<u32>::into(access_x_timeout_values.into()) as _,
36883 access_x_timeout_options_mask: Into::<u32>::into(access_x_timeout_options_mask.into())
36884 as _,
36885 access_x_timeout_options_values: Into::<u32>::into(
36886 access_x_timeout_options_values.into(),
36887 ) as _,
36888 per_key_repeat: Cow::Borrowed(per_key_repeat.borrow()),
36889 };
36890 let cookie = self.send_void_request(request, false);
36891 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
36892 res
36893 }
36894 #[cfg(feature = "xkb")]
36895 fn xkb_get_map<'this>(
36896 &'this mut self,
36897 device_spec: types::DeviceSpec,
36898 full: impl Into<types::MapPart>,
36899 partial: impl Into<types::MapPart>,
36900 first_type: types::Card8,
36901 n_types: types::Card8,
36902 first_key_sym: types::Keycode,
36903 n_key_syms: types::Card8,
36904 first_key_action: types::Keycode,
36905 n_key_actions: types::Card8,
36906 first_key_behavior: types::Keycode,
36907 n_key_behaviors: types::Card8,
36908 virtual_mods: impl Into<types::VMod>,
36909 first_key_explicit: types::Keycode,
36910 n_key_explicit: types::Card8,
36911 first_mod_map_key: types::Keycode,
36912 n_mod_map_keys: types::Card8,
36913 first_v_mod_map_key: types::Keycode,
36914 n_v_mod_map_keys: types::Card8,
36915 ) -> futures::SendRequest<'this, Self, types::xkb::GetMapReply> {
36916 let span = tracing::info_span!(
36917 "xkb_get_map",
36918 device_spec = ?device_spec,
36919 first_type = ?first_type,
36920 n_types = ?n_types,
36921 first_key_sym = ?first_key_sym,
36922 n_key_syms = ?n_key_syms,
36923 first_key_action = ?first_key_action,
36924 n_key_actions = ?n_key_actions,
36925 first_key_behavior = ?first_key_behavior,
36926 n_key_behaviors = ?n_key_behaviors,
36927 first_key_explicit = ?first_key_explicit,
36928 n_key_explicit = ?n_key_explicit,
36929 first_mod_map_key = ?first_mod_map_key,
36930 n_mod_map_keys = ?n_mod_map_keys,
36931 first_v_mod_map_key = ?first_v_mod_map_key,
36932 n_v_mod_map_keys = ?n_v_mod_map_keys,
36933 );
36934 let request = types::xkb::GetMapRequest {
36935 device_spec,
36936 full: Into::<u32>::into(full.into()) as _,
36937 partial: Into::<u32>::into(partial.into()) as _,
36938 first_type,
36939 n_types,
36940 first_key_sym,
36941 n_key_syms,
36942 first_key_action,
36943 n_key_actions,
36944 first_key_behavior,
36945 n_key_behaviors,
36946 virtual_mods: Into::<u32>::into(virtual_mods.into()) as _,
36947 first_key_explicit,
36948 n_key_explicit,
36949 first_mod_map_key,
36950 n_mod_map_keys,
36951 first_v_mod_map_key,
36952 n_v_mod_map_keys,
36953 };
36954 let cookie = self.send_reply_request(request).with_span(span);
36955 cookie
36956 }
36957 #[cfg(feature = "xkb")]
36958 fn xkb_get_map_immediate<'this>(
36959 &'this mut self,
36960 device_spec: types::DeviceSpec,
36961 full: impl Into<types::MapPart>,
36962 partial: impl Into<types::MapPart>,
36963 first_type: types::Card8,
36964 n_types: types::Card8,
36965 first_key_sym: types::Keycode,
36966 n_key_syms: types::Card8,
36967 first_key_action: types::Keycode,
36968 n_key_actions: types::Card8,
36969 first_key_behavior: types::Keycode,
36970 n_key_behaviors: types::Card8,
36971 virtual_mods: impl Into<types::VMod>,
36972 first_key_explicit: types::Keycode,
36973 n_key_explicit: types::Card8,
36974 first_mod_map_key: types::Keycode,
36975 n_mod_map_keys: types::Card8,
36976 first_v_mod_map_key: types::Keycode,
36977 n_v_mod_map_keys: types::Card8,
36978 ) -> futures::CheckedSendRequest<'this, Self, types::xkb::GetMapReply> {
36979 let request = types::xkb::GetMapRequest {
36980 device_spec,
36981 full: Into::<u32>::into(full.into()) as _,
36982 partial: Into::<u32>::into(partial.into()) as _,
36983 first_type,
36984 n_types,
36985 first_key_sym,
36986 n_key_syms,
36987 first_key_action,
36988 n_key_actions,
36989 first_key_behavior,
36990 n_key_behaviors,
36991 virtual_mods: Into::<u32>::into(virtual_mods.into()) as _,
36992 first_key_explicit,
36993 n_key_explicit,
36994 first_mod_map_key,
36995 n_mod_map_keys,
36996 first_v_mod_map_key,
36997 n_v_mod_map_keys,
36998 };
36999 let cookie = self.send_reply_request(request);
37000 let res: futures::CheckedSendRequest<'this, Self, types::xkb::GetMapReply> = cookie.into();
37001 res
37002 }
37003 #[cfg(feature = "xkb")]
37004 fn xkb_set_map<'this>(
37005 &'this mut self,
37006 device_spec: types::DeviceSpec,
37007 flags: impl Into<types::SetMapFlags>,
37008 min_key_code: types::Keycode,
37009 max_key_code: types::Keycode,
37010 first_type: types::Card8,
37011 n_types: types::Card8,
37012 first_key_sym: types::Keycode,
37013 n_key_syms: types::Card8,
37014 total_syms: types::Card16,
37015 first_key_action: types::Keycode,
37016 n_key_actions: types::Card8,
37017 total_actions: types::Card16,
37018 first_key_behavior: types::Keycode,
37019 n_key_behaviors: types::Card8,
37020 total_key_behaviors: types::Card8,
37021 first_key_explicit: types::Keycode,
37022 n_key_explicit: types::Card8,
37023 total_key_explicit: types::Card8,
37024 first_mod_map_key: types::Keycode,
37025 n_mod_map_keys: types::Card8,
37026 total_mod_map_keys: types::Card8,
37027 first_v_mod_map_key: types::Keycode,
37028 n_v_mod_map_keys: types::Card8,
37029 total_v_mod_map_keys: types::Card8,
37030 virtual_mods: impl Into<types::VMod>,
37031 values: impl Borrow<types::xkb::SetMapAux>,
37032 ) -> futures::SendRequest<'this, Self, ()> {
37033 let span = tracing::info_span!(
37034 "xkb_set_map",
37035 device_spec = ?device_spec,
37036 min_key_code = ?min_key_code,
37037 max_key_code = ?max_key_code,
37038 first_type = ?first_type,
37039 n_types = ?n_types,
37040 first_key_sym = ?first_key_sym,
37041 n_key_syms = ?n_key_syms,
37042 total_syms = ?total_syms,
37043 first_key_action = ?first_key_action,
37044 n_key_actions = ?n_key_actions,
37045 total_actions = ?total_actions,
37046 first_key_behavior = ?first_key_behavior,
37047 n_key_behaviors = ?n_key_behaviors,
37048 total_key_behaviors = ?total_key_behaviors,
37049 first_key_explicit = ?first_key_explicit,
37050 n_key_explicit = ?n_key_explicit,
37051 total_key_explicit = ?total_key_explicit,
37052 first_mod_map_key = ?first_mod_map_key,
37053 n_mod_map_keys = ?n_mod_map_keys,
37054 total_mod_map_keys = ?total_mod_map_keys,
37055 first_v_mod_map_key = ?first_v_mod_map_key,
37056 n_v_mod_map_keys = ?n_v_mod_map_keys,
37057 total_v_mod_map_keys = ?total_v_mod_map_keys,
37058 );
37059 let request = types::xkb::SetMapRequest {
37060 device_spec,
37061 flags: Into::<u32>::into(flags.into()) as _,
37062 min_key_code,
37063 max_key_code,
37064 first_type,
37065 n_types,
37066 first_key_sym,
37067 n_key_syms,
37068 total_syms,
37069 first_key_action,
37070 n_key_actions,
37071 total_actions,
37072 first_key_behavior,
37073 n_key_behaviors,
37074 total_key_behaviors,
37075 first_key_explicit,
37076 n_key_explicit,
37077 total_key_explicit,
37078 first_mod_map_key,
37079 n_mod_map_keys,
37080 total_mod_map_keys,
37081 first_v_mod_map_key,
37082 n_v_mod_map_keys,
37083 total_v_mod_map_keys,
37084 virtual_mods: Into::<u32>::into(virtual_mods.into()) as _,
37085 values: Cow::Borrowed(values.borrow()),
37086 };
37087 let cookie = self.send_void_request(request, true).with_span(span);
37088 cookie
37089 }
37090 #[cfg(feature = "xkb")]
37091 fn xkb_set_map_checked<'this>(
37092 &'this mut self,
37093 device_spec: types::DeviceSpec,
37094 flags: impl Into<types::SetMapFlags>,
37095 min_key_code: types::Keycode,
37096 max_key_code: types::Keycode,
37097 first_type: types::Card8,
37098 n_types: types::Card8,
37099 first_key_sym: types::Keycode,
37100 n_key_syms: types::Card8,
37101 total_syms: types::Card16,
37102 first_key_action: types::Keycode,
37103 n_key_actions: types::Card8,
37104 total_actions: types::Card16,
37105 first_key_behavior: types::Keycode,
37106 n_key_behaviors: types::Card8,
37107 total_key_behaviors: types::Card8,
37108 first_key_explicit: types::Keycode,
37109 n_key_explicit: types::Card8,
37110 total_key_explicit: types::Card8,
37111 first_mod_map_key: types::Keycode,
37112 n_mod_map_keys: types::Card8,
37113 total_mod_map_keys: types::Card8,
37114 first_v_mod_map_key: types::Keycode,
37115 n_v_mod_map_keys: types::Card8,
37116 total_v_mod_map_keys: types::Card8,
37117 virtual_mods: impl Into<types::VMod>,
37118 values: impl Borrow<types::xkb::SetMapAux>,
37119 ) -> futures::CheckedSendRequest<'this, Self, ()> {
37120 let request = types::xkb::SetMapRequest {
37121 device_spec,
37122 flags: Into::<u32>::into(flags.into()) as _,
37123 min_key_code,
37124 max_key_code,
37125 first_type,
37126 n_types,
37127 first_key_sym,
37128 n_key_syms,
37129 total_syms,
37130 first_key_action,
37131 n_key_actions,
37132 total_actions,
37133 first_key_behavior,
37134 n_key_behaviors,
37135 total_key_behaviors,
37136 first_key_explicit,
37137 n_key_explicit,
37138 total_key_explicit,
37139 first_mod_map_key,
37140 n_mod_map_keys,
37141 total_mod_map_keys,
37142 first_v_mod_map_key,
37143 n_v_mod_map_keys,
37144 total_v_mod_map_keys,
37145 virtual_mods: Into::<u32>::into(virtual_mods.into()) as _,
37146 values: Cow::Borrowed(values.borrow()),
37147 };
37148 let cookie = self.send_void_request(request, false);
37149 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
37150 res
37151 }
37152 #[cfg(feature = "xkb")]
37153 fn xkb_get_compat_map<'this>(
37154 &'this mut self,
37155 device_spec: types::DeviceSpec,
37156 groups: impl Into<types::SetOfGroup>,
37157 get_all_si: types::Bool,
37158 first_si: types::Card16,
37159 n_si: types::Card16,
37160 ) -> futures::SendRequest<'this, Self, types::xkb::GetCompatMapReply> {
37161 let span = tracing::info_span!(
37162 "xkb_get_compat_map",
37163 device_spec = ?device_spec,
37164 get_all_si = ?get_all_si,
37165 first_si = ?first_si,
37166 n_si = ?n_si,
37167 );
37168 let request = types::xkb::GetCompatMapRequest {
37169 device_spec,
37170 groups: Into::<u32>::into(groups.into()) as _,
37171 get_all_si,
37172 first_si,
37173 n_si,
37174 };
37175 let cookie = self.send_reply_request(request).with_span(span);
37176 cookie
37177 }
37178 #[cfg(feature = "xkb")]
37179 fn xkb_get_compat_map_immediate<'this>(
37180 &'this mut self,
37181 device_spec: types::DeviceSpec,
37182 groups: impl Into<types::SetOfGroup>,
37183 get_all_si: types::Bool,
37184 first_si: types::Card16,
37185 n_si: types::Card16,
37186 ) -> futures::CheckedSendRequest<'this, Self, types::xkb::GetCompatMapReply> {
37187 let request = types::xkb::GetCompatMapRequest {
37188 device_spec,
37189 groups: Into::<u32>::into(groups.into()) as _,
37190 get_all_si,
37191 first_si,
37192 n_si,
37193 };
37194 let cookie = self.send_reply_request(request);
37195 let res: futures::CheckedSendRequest<'this, Self, types::xkb::GetCompatMapReply> =
37196 cookie.into();
37197 res
37198 }
37199 #[cfg(feature = "xkb")]
37200 fn xkb_set_compat_map<'this>(
37201 &'this mut self,
37202 device_spec: types::DeviceSpec,
37203 recompute_actions: types::Bool,
37204 truncate_si: types::Bool,
37205 groups: impl Into<types::SetOfGroup>,
37206 first_si: types::Card16,
37207 si: impl AsRef<[types::SymInterpret]>,
37208 group_maps: impl AsRef<[types::ModDef]>,
37209 ) -> futures::SendRequest<'this, Self, ()> {
37210 let span = tracing::info_span!(
37211 "xkb_set_compat_map",
37212 device_spec = ?device_spec,
37213 recompute_actions = ?recompute_actions,
37214 truncate_si = ?truncate_si,
37215 first_si = ?first_si,
37216 );
37217 let request = types::xkb::SetCompatMapRequest {
37218 device_spec,
37219 recompute_actions,
37220 truncate_si,
37221 groups: Into::<u32>::into(groups.into()) as _,
37222 first_si,
37223 si: Cow::Borrowed(si.as_ref()),
37224 group_maps: Cow::Borrowed(group_maps.as_ref()),
37225 };
37226 let cookie = self.send_void_request(request, true).with_span(span);
37227 cookie
37228 }
37229 #[cfg(feature = "xkb")]
37230 fn xkb_set_compat_map_checked<'this>(
37231 &'this mut self,
37232 device_spec: types::DeviceSpec,
37233 recompute_actions: types::Bool,
37234 truncate_si: types::Bool,
37235 groups: impl Into<types::SetOfGroup>,
37236 first_si: types::Card16,
37237 si: impl AsRef<[types::SymInterpret]>,
37238 group_maps: impl AsRef<[types::ModDef]>,
37239 ) -> futures::CheckedSendRequest<'this, Self, ()> {
37240 let request = types::xkb::SetCompatMapRequest {
37241 device_spec,
37242 recompute_actions,
37243 truncate_si,
37244 groups: Into::<u32>::into(groups.into()) as _,
37245 first_si,
37246 si: Cow::Borrowed(si.as_ref()),
37247 group_maps: Cow::Borrowed(group_maps.as_ref()),
37248 };
37249 let cookie = self.send_void_request(request, false);
37250 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
37251 res
37252 }
37253 #[cfg(feature = "xkb")]
37254 fn xkb_get_indicator_state<'this>(
37255 &'this mut self,
37256 device_spec: types::DeviceSpec,
37257 ) -> futures::SendRequest<'this, Self, types::xkb::GetIndicatorStateReply> {
37258 let span = tracing::info_span!(
37259 "xkb_get_indicator_state",
37260 device_spec = ?device_spec,
37261 );
37262 let request = types::xkb::GetIndicatorStateRequest { device_spec };
37263 let cookie = self.send_reply_request(request).with_span(span);
37264 cookie
37265 }
37266 #[cfg(feature = "xkb")]
37267 fn xkb_get_indicator_state_immediate<'this>(
37268 &'this mut self,
37269 device_spec: types::DeviceSpec,
37270 ) -> futures::CheckedSendRequest<'this, Self, types::xkb::GetIndicatorStateReply> {
37271 let request = types::xkb::GetIndicatorStateRequest { device_spec };
37272 let cookie = self.send_reply_request(request);
37273 let res: futures::CheckedSendRequest<'this, Self, types::xkb::GetIndicatorStateReply> =
37274 cookie.into();
37275 res
37276 }
37277 #[cfg(feature = "xkb")]
37278 fn xkb_get_indicator_map<'this>(
37279 &'this mut self,
37280 device_spec: types::DeviceSpec,
37281 which: types::Card32,
37282 ) -> futures::SendRequest<'this, Self, types::xkb::GetIndicatorMapReply> {
37283 let span = tracing::info_span!(
37284 "xkb_get_indicator_map",
37285 device_spec = ?device_spec,
37286 which = ?which,
37287 );
37288 let request = types::xkb::GetIndicatorMapRequest { device_spec, which };
37289 let cookie = self.send_reply_request(request).with_span(span);
37290 cookie
37291 }
37292 #[cfg(feature = "xkb")]
37293 fn xkb_get_indicator_map_immediate<'this>(
37294 &'this mut self,
37295 device_spec: types::DeviceSpec,
37296 which: types::Card32,
37297 ) -> futures::CheckedSendRequest<'this, Self, types::xkb::GetIndicatorMapReply> {
37298 let request = types::xkb::GetIndicatorMapRequest { device_spec, which };
37299 let cookie = self.send_reply_request(request);
37300 let res: futures::CheckedSendRequest<'this, Self, types::xkb::GetIndicatorMapReply> =
37301 cookie.into();
37302 res
37303 }
37304 #[cfg(feature = "xkb")]
37305 fn xkb_set_indicator_map<'this>(
37306 &'this mut self,
37307 device_spec: types::DeviceSpec,
37308 which: types::Card32,
37309 maps: impl AsRef<[types::IndicatorMap]>,
37310 ) -> futures::SendRequest<'this, Self, ()> {
37311 let span = tracing::info_span!(
37312 "xkb_set_indicator_map",
37313 device_spec = ?device_spec,
37314 which = ?which,
37315 );
37316 let request = types::xkb::SetIndicatorMapRequest {
37317 device_spec,
37318 which,
37319 maps: Cow::Borrowed(maps.as_ref()),
37320 };
37321 let cookie = self.send_void_request(request, true).with_span(span);
37322 cookie
37323 }
37324 #[cfg(feature = "xkb")]
37325 fn xkb_set_indicator_map_checked<'this>(
37326 &'this mut self,
37327 device_spec: types::DeviceSpec,
37328 which: types::Card32,
37329 maps: impl AsRef<[types::IndicatorMap]>,
37330 ) -> futures::CheckedSendRequest<'this, Self, ()> {
37331 let request = types::xkb::SetIndicatorMapRequest {
37332 device_spec,
37333 which,
37334 maps: Cow::Borrowed(maps.as_ref()),
37335 };
37336 let cookie = self.send_void_request(request, false);
37337 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
37338 res
37339 }
37340 #[cfg(feature = "xkb")]
37341 fn xkb_get_named_indicator<'this>(
37342 &'this mut self,
37343 device_spec: types::DeviceSpec,
37344 led_class: types::LedClass,
37345 led_id: impl Into<types::ID>,
37346 indicator: types::Atom,
37347 ) -> futures::SendRequest<'this, Self, types::xkb::GetNamedIndicatorReply> {
37348 let span = tracing::info_span!(
37349 "xkb_get_named_indicator",
37350 device_spec = ?device_spec,
37351 led_class = ?led_class,
37352 indicator = ?indicator,
37353 );
37354 let request = types::xkb::GetNamedIndicatorRequest {
37355 device_spec,
37356 led_class,
37357 led_id: Into::<u32>::into(led_id.into()) as _,
37358 indicator,
37359 };
37360 let cookie = self.send_reply_request(request).with_span(span);
37361 cookie
37362 }
37363 #[cfg(feature = "xkb")]
37364 fn xkb_get_named_indicator_immediate<'this>(
37365 &'this mut self,
37366 device_spec: types::DeviceSpec,
37367 led_class: types::LedClass,
37368 led_id: impl Into<types::ID>,
37369 indicator: types::Atom,
37370 ) -> futures::CheckedSendRequest<'this, Self, types::xkb::GetNamedIndicatorReply> {
37371 let request = types::xkb::GetNamedIndicatorRequest {
37372 device_spec,
37373 led_class,
37374 led_id: Into::<u32>::into(led_id.into()) as _,
37375 indicator,
37376 };
37377 let cookie = self.send_reply_request(request);
37378 let res: futures::CheckedSendRequest<'this, Self, types::xkb::GetNamedIndicatorReply> =
37379 cookie.into();
37380 res
37381 }
37382 #[cfg(feature = "xkb")]
37383 fn xkb_set_named_indicator<'this>(
37384 &'this mut self,
37385 device_spec: types::DeviceSpec,
37386 led_class: types::LedClass,
37387 led_id: impl Into<types::ID>,
37388 indicator: types::Atom,
37389 set_state: types::Bool,
37390 on: types::Bool,
37391 set_map: types::Bool,
37392 create_map: types::Bool,
37393 map_flags: impl Into<types::IMFlag>,
37394 map_which_groups: impl Into<types::IMGroupsWhich>,
37395 map_groups: impl Into<types::SetOfGroups>,
37396 map_which_mods: impl Into<types::IMModsWhich>,
37397 map_real_mods: impl Into<types::ModMask>,
37398 map_vmods: impl Into<types::VMod>,
37399 map_ctrls: impl Into<types::BoolCtrl>,
37400 ) -> futures::SendRequest<'this, Self, ()> {
37401 let span = tracing::info_span!(
37402 "xkb_set_named_indicator",
37403 device_spec = ?device_spec,
37404 led_class = ?led_class,
37405 indicator = ?indicator,
37406 set_state = ?set_state,
37407 on = ?on,
37408 set_map = ?set_map,
37409 create_map = ?create_map,
37410 );
37411 let request = types::xkb::SetNamedIndicatorRequest {
37412 device_spec,
37413 led_class,
37414 led_id: Into::<u32>::into(led_id.into()) as _,
37415 indicator,
37416 set_state,
37417 on,
37418 set_map,
37419 create_map,
37420 map_flags: Into::<u32>::into(map_flags.into()) as _,
37421 map_which_groups: Into::<u32>::into(map_which_groups.into()) as _,
37422 map_groups: Into::<u32>::into(map_groups.into()) as _,
37423 map_which_mods: Into::<u32>::into(map_which_mods.into()) as _,
37424 map_real_mods: Into::<u32>::into(map_real_mods.into()) as _,
37425 map_vmods: Into::<u32>::into(map_vmods.into()) as _,
37426 map_ctrls: Into::<u32>::into(map_ctrls.into()) as _,
37427 };
37428 let cookie = self.send_void_request(request, true).with_span(span);
37429 cookie
37430 }
37431 #[cfg(feature = "xkb")]
37432 fn xkb_set_named_indicator_checked<'this>(
37433 &'this mut self,
37434 device_spec: types::DeviceSpec,
37435 led_class: types::LedClass,
37436 led_id: impl Into<types::ID>,
37437 indicator: types::Atom,
37438 set_state: types::Bool,
37439 on: types::Bool,
37440 set_map: types::Bool,
37441 create_map: types::Bool,
37442 map_flags: impl Into<types::IMFlag>,
37443 map_which_groups: impl Into<types::IMGroupsWhich>,
37444 map_groups: impl Into<types::SetOfGroups>,
37445 map_which_mods: impl Into<types::IMModsWhich>,
37446 map_real_mods: impl Into<types::ModMask>,
37447 map_vmods: impl Into<types::VMod>,
37448 map_ctrls: impl Into<types::BoolCtrl>,
37449 ) -> futures::CheckedSendRequest<'this, Self, ()> {
37450 let request = types::xkb::SetNamedIndicatorRequest {
37451 device_spec,
37452 led_class,
37453 led_id: Into::<u32>::into(led_id.into()) as _,
37454 indicator,
37455 set_state,
37456 on,
37457 set_map,
37458 create_map,
37459 map_flags: Into::<u32>::into(map_flags.into()) as _,
37460 map_which_groups: Into::<u32>::into(map_which_groups.into()) as _,
37461 map_groups: Into::<u32>::into(map_groups.into()) as _,
37462 map_which_mods: Into::<u32>::into(map_which_mods.into()) as _,
37463 map_real_mods: Into::<u32>::into(map_real_mods.into()) as _,
37464 map_vmods: Into::<u32>::into(map_vmods.into()) as _,
37465 map_ctrls: Into::<u32>::into(map_ctrls.into()) as _,
37466 };
37467 let cookie = self.send_void_request(request, false);
37468 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
37469 res
37470 }
37471 #[cfg(feature = "xkb")]
37472 fn xkb_get_names<'this>(
37473 &'this mut self,
37474 device_spec: types::DeviceSpec,
37475 which: impl Into<types::NameDetail>,
37476 ) -> futures::SendRequest<'this, Self, types::xkb::GetNamesReply> {
37477 let span = tracing::info_span!(
37478 "xkb_get_names",
37479 device_spec = ?device_spec,
37480 );
37481 let request = types::xkb::GetNamesRequest {
37482 device_spec,
37483 which: Into::<u32>::into(which.into()) as _,
37484 };
37485 let cookie = self.send_reply_request(request).with_span(span);
37486 cookie
37487 }
37488 #[cfg(feature = "xkb")]
37489 fn xkb_get_names_immediate<'this>(
37490 &'this mut self,
37491 device_spec: types::DeviceSpec,
37492 which: impl Into<types::NameDetail>,
37493 ) -> futures::CheckedSendRequest<'this, Self, types::xkb::GetNamesReply> {
37494 let request = types::xkb::GetNamesRequest {
37495 device_spec,
37496 which: Into::<u32>::into(which.into()) as _,
37497 };
37498 let cookie = self.send_reply_request(request);
37499 let res: futures::CheckedSendRequest<'this, Self, types::xkb::GetNamesReply> =
37500 cookie.into();
37501 res
37502 }
37503 #[cfg(feature = "xkb")]
37504 fn xkb_set_names<'this>(
37505 &'this mut self,
37506 device_spec: types::DeviceSpec,
37507 virtual_mods: impl Into<types::VMod>,
37508 first_type: types::Card8,
37509 n_types: types::Card8,
37510 first_kt_levelt: types::Card8,
37511 n_kt_levels: types::Card8,
37512 indicators: types::Card32,
37513 group_names: impl Into<types::SetOfGroup>,
37514 n_radio_groups: types::Card8,
37515 first_key: types::Keycode,
37516 n_keys: types::Card8,
37517 n_key_aliases: types::Card8,
37518 total_kt_level_names: types::Card16,
37519 values: impl Borrow<types::xkb::SetNamesAux>,
37520 ) -> futures::SendRequest<'this, Self, ()> {
37521 let span = tracing::info_span!(
37522 "xkb_set_names",
37523 device_spec = ?device_spec,
37524 first_type = ?first_type,
37525 n_types = ?n_types,
37526 first_kt_levelt = ?first_kt_levelt,
37527 n_kt_levels = ?n_kt_levels,
37528 indicators = ?indicators,
37529 n_radio_groups = ?n_radio_groups,
37530 first_key = ?first_key,
37531 n_keys = ?n_keys,
37532 n_key_aliases = ?n_key_aliases,
37533 total_kt_level_names = ?total_kt_level_names,
37534 );
37535 let request = types::xkb::SetNamesRequest {
37536 device_spec,
37537 virtual_mods: Into::<u32>::into(virtual_mods.into()) as _,
37538 first_type,
37539 n_types,
37540 first_kt_levelt,
37541 n_kt_levels,
37542 indicators,
37543 group_names: Into::<u32>::into(group_names.into()) as _,
37544 n_radio_groups,
37545 first_key,
37546 n_keys,
37547 n_key_aliases,
37548 total_kt_level_names,
37549 values: Cow::Borrowed(values.borrow()),
37550 };
37551 let cookie = self.send_void_request(request, true).with_span(span);
37552 cookie
37553 }
37554 #[cfg(feature = "xkb")]
37555 fn xkb_set_names_checked<'this>(
37556 &'this mut self,
37557 device_spec: types::DeviceSpec,
37558 virtual_mods: impl Into<types::VMod>,
37559 first_type: types::Card8,
37560 n_types: types::Card8,
37561 first_kt_levelt: types::Card8,
37562 n_kt_levels: types::Card8,
37563 indicators: types::Card32,
37564 group_names: impl Into<types::SetOfGroup>,
37565 n_radio_groups: types::Card8,
37566 first_key: types::Keycode,
37567 n_keys: types::Card8,
37568 n_key_aliases: types::Card8,
37569 total_kt_level_names: types::Card16,
37570 values: impl Borrow<types::xkb::SetNamesAux>,
37571 ) -> futures::CheckedSendRequest<'this, Self, ()> {
37572 let request = types::xkb::SetNamesRequest {
37573 device_spec,
37574 virtual_mods: Into::<u32>::into(virtual_mods.into()) as _,
37575 first_type,
37576 n_types,
37577 first_kt_levelt,
37578 n_kt_levels,
37579 indicators,
37580 group_names: Into::<u32>::into(group_names.into()) as _,
37581 n_radio_groups,
37582 first_key,
37583 n_keys,
37584 n_key_aliases,
37585 total_kt_level_names,
37586 values: Cow::Borrowed(values.borrow()),
37587 };
37588 let cookie = self.send_void_request(request, false);
37589 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
37590 res
37591 }
37592 #[cfg(feature = "xkb")]
37593 fn xkb_per_client_flags<'this>(
37594 &'this mut self,
37595 device_spec: types::DeviceSpec,
37596 change: impl Into<types::PerClientFlag>,
37597 value: impl Into<types::PerClientFlag>,
37598 ctrls_to_change: impl Into<types::BoolCtrl>,
37599 auto_ctrls: impl Into<types::BoolCtrl>,
37600 auto_ctrls_values: impl Into<types::BoolCtrl>,
37601 ) -> futures::SendRequest<'this, Self, types::xkb::PerClientFlagsReply> {
37602 let span = tracing::info_span!(
37603 "xkb_per_client_flags",
37604 device_spec = ?device_spec,
37605 );
37606 let request = types::xkb::PerClientFlagsRequest {
37607 device_spec,
37608 change: Into::<u32>::into(change.into()) as _,
37609 value: Into::<u32>::into(value.into()) as _,
37610 ctrls_to_change: Into::<u32>::into(ctrls_to_change.into()) as _,
37611 auto_ctrls: Into::<u32>::into(auto_ctrls.into()) as _,
37612 auto_ctrls_values: Into::<u32>::into(auto_ctrls_values.into()) as _,
37613 };
37614 let cookie = self.send_reply_request(request).with_span(span);
37615 cookie
37616 }
37617 #[cfg(feature = "xkb")]
37618 fn xkb_per_client_flags_immediate<'this>(
37619 &'this mut self,
37620 device_spec: types::DeviceSpec,
37621 change: impl Into<types::PerClientFlag>,
37622 value: impl Into<types::PerClientFlag>,
37623 ctrls_to_change: impl Into<types::BoolCtrl>,
37624 auto_ctrls: impl Into<types::BoolCtrl>,
37625 auto_ctrls_values: impl Into<types::BoolCtrl>,
37626 ) -> futures::CheckedSendRequest<'this, Self, types::xkb::PerClientFlagsReply> {
37627 let request = types::xkb::PerClientFlagsRequest {
37628 device_spec,
37629 change: Into::<u32>::into(change.into()) as _,
37630 value: Into::<u32>::into(value.into()) as _,
37631 ctrls_to_change: Into::<u32>::into(ctrls_to_change.into()) as _,
37632 auto_ctrls: Into::<u32>::into(auto_ctrls.into()) as _,
37633 auto_ctrls_values: Into::<u32>::into(auto_ctrls_values.into()) as _,
37634 };
37635 let cookie = self.send_reply_request(request);
37636 let res: futures::CheckedSendRequest<'this, Self, types::xkb::PerClientFlagsReply> =
37637 cookie.into();
37638 res
37639 }
37640 #[cfg(feature = "xkb")]
37641 fn xkb_list_components<'this>(
37642 &'this mut self,
37643 device_spec: types::DeviceSpec,
37644 max_names: types::Card16,
37645 ) -> futures::SendRequest<'this, Self, types::xkb::ListComponentsReply> {
37646 let span = tracing::info_span!(
37647 "xkb_list_components",
37648 device_spec = ?device_spec,
37649 max_names = ?max_names,
37650 );
37651 let request = types::xkb::ListComponentsRequest {
37652 device_spec,
37653 max_names,
37654 };
37655 let cookie = self.send_reply_request(request).with_span(span);
37656 cookie
37657 }
37658 #[cfg(feature = "xkb")]
37659 fn xkb_list_components_immediate<'this>(
37660 &'this mut self,
37661 device_spec: types::DeviceSpec,
37662 max_names: types::Card16,
37663 ) -> futures::CheckedSendRequest<'this, Self, types::xkb::ListComponentsReply> {
37664 let request = types::xkb::ListComponentsRequest {
37665 device_spec,
37666 max_names,
37667 };
37668 let cookie = self.send_reply_request(request);
37669 let res: futures::CheckedSendRequest<'this, Self, types::xkb::ListComponentsReply> =
37670 cookie.into();
37671 res
37672 }
37673 #[cfg(feature = "xkb")]
37674 fn xkb_get_kbd_by_name<'this>(
37675 &'this mut self,
37676 device_spec: types::DeviceSpec,
37677 need: impl Into<types::GBNDetail>,
37678 want: impl Into<types::GBNDetail>,
37679 load: types::Bool,
37680 ) -> futures::SendRequest<'this, Self, types::xkb::GetKbdByNameReply> {
37681 let span = tracing::info_span!(
37682 "xkb_get_kbd_by_name",
37683 device_spec = ?device_spec,
37684 load = ?load,
37685 );
37686 let request = types::xkb::GetKbdByNameRequest {
37687 device_spec,
37688 need: Into::<u32>::into(need.into()) as _,
37689 want: Into::<u32>::into(want.into()) as _,
37690 load,
37691 };
37692 let cookie = self.send_reply_request(request).with_span(span);
37693 cookie
37694 }
37695 #[cfg(feature = "xkb")]
37696 fn xkb_get_kbd_by_name_immediate<'this>(
37697 &'this mut self,
37698 device_spec: types::DeviceSpec,
37699 need: impl Into<types::GBNDetail>,
37700 want: impl Into<types::GBNDetail>,
37701 load: types::Bool,
37702 ) -> futures::CheckedSendRequest<'this, Self, types::xkb::GetKbdByNameReply> {
37703 let request = types::xkb::GetKbdByNameRequest {
37704 device_spec,
37705 need: Into::<u32>::into(need.into()) as _,
37706 want: Into::<u32>::into(want.into()) as _,
37707 load,
37708 };
37709 let cookie = self.send_reply_request(request);
37710 let res: futures::CheckedSendRequest<'this, Self, types::xkb::GetKbdByNameReply> =
37711 cookie.into();
37712 res
37713 }
37714 #[cfg(feature = "xkb")]
37715 fn xkb_get_device_info<'this>(
37716 &'this mut self,
37717 device_spec: types::DeviceSpec,
37718 wanted: impl Into<types::XIFeature>,
37719 all_buttons: types::Bool,
37720 first_button: types::Card8,
37721 n_buttons: types::Card8,
37722 led_class: types::LedClass,
37723 led_id: impl Into<types::ID>,
37724 ) -> futures::SendRequest<'this, Self, types::xkb::GetDeviceInfoReply> {
37725 let span = tracing::info_span!(
37726 "xkb_get_device_info",
37727 device_spec = ?device_spec,
37728 all_buttons = ?all_buttons,
37729 first_button = ?first_button,
37730 n_buttons = ?n_buttons,
37731 led_class = ?led_class,
37732 );
37733 let request = types::xkb::GetDeviceInfoRequest {
37734 device_spec,
37735 wanted: Into::<u32>::into(wanted.into()) as _,
37736 all_buttons,
37737 first_button,
37738 n_buttons,
37739 led_class,
37740 led_id: Into::<u32>::into(led_id.into()) as _,
37741 };
37742 let cookie = self.send_reply_request(request).with_span(span);
37743 cookie
37744 }
37745 #[cfg(feature = "xkb")]
37746 fn xkb_get_device_info_immediate<'this>(
37747 &'this mut self,
37748 device_spec: types::DeviceSpec,
37749 wanted: impl Into<types::XIFeature>,
37750 all_buttons: types::Bool,
37751 first_button: types::Card8,
37752 n_buttons: types::Card8,
37753 led_class: types::LedClass,
37754 led_id: impl Into<types::ID>,
37755 ) -> futures::CheckedSendRequest<'this, Self, types::xkb::GetDeviceInfoReply> {
37756 let request = types::xkb::GetDeviceInfoRequest {
37757 device_spec,
37758 wanted: Into::<u32>::into(wanted.into()) as _,
37759 all_buttons,
37760 first_button,
37761 n_buttons,
37762 led_class,
37763 led_id: Into::<u32>::into(led_id.into()) as _,
37764 };
37765 let cookie = self.send_reply_request(request);
37766 let res: futures::CheckedSendRequest<'this, Self, types::xkb::GetDeviceInfoReply> =
37767 cookie.into();
37768 res
37769 }
37770 #[cfg(feature = "xkb")]
37771 fn xkb_set_device_info<'this>(
37772 &'this mut self,
37773 device_spec: types::DeviceSpec,
37774 first_btn: types::Card8,
37775 change: impl Into<types::XIFeature>,
37776 btn_actions: impl AsRef<[types::Action]>,
37777 leds: impl AsRef<[types::DeviceLedInfo]>,
37778 ) -> futures::SendRequest<'this, Self, ()> {
37779 let span = tracing::info_span!(
37780 "xkb_set_device_info",
37781 device_spec = ?device_spec,
37782 first_btn = ?first_btn,
37783 );
37784 let request = types::xkb::SetDeviceInfoRequest {
37785 device_spec,
37786 first_btn,
37787 change: Into::<u32>::into(change.into()) as _,
37788 btn_actions: Cow::Borrowed(btn_actions.as_ref()),
37789 leds: Cow::Borrowed(leds.as_ref()),
37790 };
37791 let cookie = self.send_void_request(request, true).with_span(span);
37792 cookie
37793 }
37794 #[cfg(feature = "xkb")]
37795 fn xkb_set_device_info_checked<'this>(
37796 &'this mut self,
37797 device_spec: types::DeviceSpec,
37798 first_btn: types::Card8,
37799 change: impl Into<types::XIFeature>,
37800 btn_actions: impl AsRef<[types::Action]>,
37801 leds: impl AsRef<[types::DeviceLedInfo]>,
37802 ) -> futures::CheckedSendRequest<'this, Self, ()> {
37803 let request = types::xkb::SetDeviceInfoRequest {
37804 device_spec,
37805 first_btn,
37806 change: Into::<u32>::into(change.into()) as _,
37807 btn_actions: Cow::Borrowed(btn_actions.as_ref()),
37808 leds: Cow::Borrowed(leds.as_ref()),
37809 };
37810 let cookie = self.send_void_request(request, false);
37811 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
37812 res
37813 }
37814 #[cfg(feature = "xkb")]
37815 fn xkb_set_debugging_flags<'this>(
37816 &'this mut self,
37817 affect_flags: types::Card32,
37818 flags: types::Card32,
37819 affect_ctrls: types::Card32,
37820 ctrls: types::Card32,
37821 message: impl AsRef<[types::xkb::String8]>,
37822 ) -> futures::SendRequest<'this, Self, types::xkb::SetDebuggingFlagsReply> {
37823 let span = tracing::info_span!(
37824 "xkb_set_debugging_flags",
37825 affect_flags = ?affect_flags,
37826 flags = ?flags,
37827 affect_ctrls = ?affect_ctrls,
37828 ctrls = ?ctrls,
37829 );
37830 let request = types::xkb::SetDebuggingFlagsRequest {
37831 affect_flags,
37832 flags,
37833 affect_ctrls,
37834 ctrls,
37835 message: Cow::Borrowed(message.as_ref()),
37836 };
37837 let cookie = self.send_reply_request(request).with_span(span);
37838 cookie
37839 }
37840 #[cfg(feature = "xkb")]
37841 fn xkb_set_debugging_flags_immediate<'this>(
37842 &'this mut self,
37843 affect_flags: types::Card32,
37844 flags: types::Card32,
37845 affect_ctrls: types::Card32,
37846 ctrls: types::Card32,
37847 message: impl AsRef<[types::xkb::String8]>,
37848 ) -> futures::CheckedSendRequest<'this, Self, types::xkb::SetDebuggingFlagsReply> {
37849 let request = types::xkb::SetDebuggingFlagsRequest {
37850 affect_flags,
37851 flags,
37852 affect_ctrls,
37853 ctrls,
37854 message: Cow::Borrowed(message.as_ref()),
37855 };
37856 let cookie = self.send_reply_request(request);
37857 let res: futures::CheckedSendRequest<'this, Self, types::xkb::SetDebuggingFlagsReply> =
37858 cookie.into();
37859 res
37860 }
37861
37862 #[cfg(feature = "xprint")]
37863 fn xprint_print_query_version<'this>(
37864 &'this mut self,
37865 ) -> futures::SendRequest<'this, Self, types::xprint::PrintQueryVersionReply> {
37866 let span = tracing::info_span!("xprint_print_query_version",);
37867 let request = types::xprint::PrintQueryVersionRequest {};
37868 let cookie = self.send_reply_request(request).with_span(span);
37869 cookie
37870 }
37871 #[cfg(feature = "xprint")]
37872 fn xprint_print_query_version_immediate<'this>(
37873 &'this mut self,
37874 ) -> futures::CheckedSendRequest<'this, Self, types::xprint::PrintQueryVersionReply> {
37875 let request = types::xprint::PrintQueryVersionRequest {};
37876 let cookie = self.send_reply_request(request);
37877 let res: futures::CheckedSendRequest<'this, Self, types::xprint::PrintQueryVersionReply> =
37878 cookie.into();
37879 res
37880 }
37881 #[cfg(feature = "xprint")]
37882 fn xprint_print_get_printer_list<'this>(
37883 &'this mut self,
37884 printer_name: impl AsRef<[types::xprint::String8]>,
37885 locale: impl AsRef<[types::xprint::String8]>,
37886 ) -> futures::SendRequest<'this, Self, types::xprint::PrintGetPrinterListReply> {
37887 let span = tracing::info_span!("xprint_print_get_printer_list",);
37888 let request = types::xprint::PrintGetPrinterListRequest {
37889 printer_name: Cow::Borrowed(printer_name.as_ref()),
37890 locale: Cow::Borrowed(locale.as_ref()),
37891 };
37892 let cookie = self.send_reply_request(request).with_span(span);
37893 cookie
37894 }
37895 #[cfg(feature = "xprint")]
37896 fn xprint_print_get_printer_list_immediate<'this>(
37897 &'this mut self,
37898 printer_name: impl AsRef<[types::xprint::String8]>,
37899 locale: impl AsRef<[types::xprint::String8]>,
37900 ) -> futures::CheckedSendRequest<'this, Self, types::xprint::PrintGetPrinterListReply> {
37901 let request = types::xprint::PrintGetPrinterListRequest {
37902 printer_name: Cow::Borrowed(printer_name.as_ref()),
37903 locale: Cow::Borrowed(locale.as_ref()),
37904 };
37905 let cookie = self.send_reply_request(request);
37906 let res: futures::CheckedSendRequest<'this, Self, types::xprint::PrintGetPrinterListReply> =
37907 cookie.into();
37908 res
37909 }
37910 #[cfg(feature = "xprint")]
37911 fn xprint_print_rehash_printer_list<'this>(
37912 &'this mut self,
37913 ) -> futures::SendRequest<'this, Self, ()> {
37914 let span = tracing::info_span!("xprint_print_rehash_printer_list",);
37915 let request = types::xprint::PrintRehashPrinterListRequest {};
37916 let cookie = self.send_void_request(request, true).with_span(span);
37917 cookie
37918 }
37919 #[cfg(feature = "xprint")]
37920 fn xprint_print_rehash_printer_list_checked<'this>(
37921 &'this mut self,
37922 ) -> futures::CheckedSendRequest<'this, Self, ()> {
37923 let request = types::xprint::PrintRehashPrinterListRequest {};
37924 let cookie = self.send_void_request(request, false);
37925 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
37926 res
37927 }
37928 #[cfg(feature = "xprint")]
37929 fn xprint_create_context<'this>(
37930 &'this mut self,
37931 context_id: types::Card32,
37932 printer_name: impl AsRef<[types::xprint::String8]>,
37933 locale: impl AsRef<[types::xprint::String8]>,
37934 ) -> futures::SendRequest<'this, Self, ()> {
37935 let span = tracing::info_span!(
37936 "xprint_create_context",
37937 context_id = ?context_id,
37938 );
37939 let request = types::xprint::CreateContextRequest {
37940 context_id,
37941 printer_name: Cow::Borrowed(printer_name.as_ref()),
37942 locale: Cow::Borrowed(locale.as_ref()),
37943 };
37944 let cookie = self.send_void_request(request, true).with_span(span);
37945 cookie
37946 }
37947 #[cfg(feature = "xprint")]
37948 fn xprint_create_context_checked<'this>(
37949 &'this mut self,
37950 context_id: types::Card32,
37951 printer_name: impl AsRef<[types::xprint::String8]>,
37952 locale: impl AsRef<[types::xprint::String8]>,
37953 ) -> futures::CheckedSendRequest<'this, Self, ()> {
37954 let request = types::xprint::CreateContextRequest {
37955 context_id,
37956 printer_name: Cow::Borrowed(printer_name.as_ref()),
37957 locale: Cow::Borrowed(locale.as_ref()),
37958 };
37959 let cookie = self.send_void_request(request, false);
37960 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
37961 res
37962 }
37963 #[cfg(feature = "xprint")]
37964 fn xprint_print_set_context<'this>(
37965 &'this mut self,
37966 context: types::Card32,
37967 ) -> futures::SendRequest<'this, Self, ()> {
37968 let span = tracing::info_span!(
37969 "xprint_print_set_context",
37970 context = ?context,
37971 );
37972 let request = types::xprint::PrintSetContextRequest { context };
37973 let cookie = self.send_void_request(request, true).with_span(span);
37974 cookie
37975 }
37976 #[cfg(feature = "xprint")]
37977 fn xprint_print_set_context_checked<'this>(
37978 &'this mut self,
37979 context: types::Card32,
37980 ) -> futures::CheckedSendRequest<'this, Self, ()> {
37981 let request = types::xprint::PrintSetContextRequest { context };
37982 let cookie = self.send_void_request(request, false);
37983 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
37984 res
37985 }
37986 #[cfg(feature = "xprint")]
37987 fn xprint_print_get_context<'this>(
37988 &'this mut self,
37989 ) -> futures::SendRequest<'this, Self, types::xprint::PrintGetContextReply> {
37990 let span = tracing::info_span!("xprint_print_get_context",);
37991 let request = types::xprint::PrintGetContextRequest {};
37992 let cookie = self.send_reply_request(request).with_span(span);
37993 cookie
37994 }
37995 #[cfg(feature = "xprint")]
37996 fn xprint_print_get_context_immediate<'this>(
37997 &'this mut self,
37998 ) -> futures::CheckedSendRequest<'this, Self, types::xprint::PrintGetContextReply> {
37999 let request = types::xprint::PrintGetContextRequest {};
38000 let cookie = self.send_reply_request(request);
38001 let res: futures::CheckedSendRequest<'this, Self, types::xprint::PrintGetContextReply> =
38002 cookie.into();
38003 res
38004 }
38005 #[cfg(feature = "xprint")]
38006 fn xprint_print_destroy_context<'this>(
38007 &'this mut self,
38008 context: types::Card32,
38009 ) -> futures::SendRequest<'this, Self, ()> {
38010 let span = tracing::info_span!(
38011 "xprint_print_destroy_context",
38012 context = ?context,
38013 );
38014 let request = types::xprint::PrintDestroyContextRequest { context };
38015 let cookie = self.send_void_request(request, true).with_span(span);
38016 cookie
38017 }
38018 #[cfg(feature = "xprint")]
38019 fn xprint_print_destroy_context_checked<'this>(
38020 &'this mut self,
38021 context: types::Card32,
38022 ) -> futures::CheckedSendRequest<'this, Self, ()> {
38023 let request = types::xprint::PrintDestroyContextRequest { context };
38024 let cookie = self.send_void_request(request, false);
38025 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
38026 res
38027 }
38028 #[cfg(feature = "xprint")]
38029 fn xprint_print_get_screen_of_context<'this>(
38030 &'this mut self,
38031 ) -> futures::SendRequest<'this, Self, types::xprint::PrintGetScreenOfContextReply> {
38032 let span = tracing::info_span!("xprint_print_get_screen_of_context",);
38033 let request = types::xprint::PrintGetScreenOfContextRequest {};
38034 let cookie = self.send_reply_request(request).with_span(span);
38035 cookie
38036 }
38037 #[cfg(feature = "xprint")]
38038 fn xprint_print_get_screen_of_context_immediate<'this>(
38039 &'this mut self,
38040 ) -> futures::CheckedSendRequest<'this, Self, types::xprint::PrintGetScreenOfContextReply> {
38041 let request = types::xprint::PrintGetScreenOfContextRequest {};
38042 let cookie = self.send_reply_request(request);
38043 let res: futures::CheckedSendRequest<
38044 'this,
38045 Self,
38046 types::xprint::PrintGetScreenOfContextReply,
38047 > = cookie.into();
38048 res
38049 }
38050 #[cfg(feature = "xprint")]
38051 fn xprint_print_start_job<'this>(
38052 &'this mut self,
38053 output_mode: types::Card8,
38054 ) -> futures::SendRequest<'this, Self, ()> {
38055 let span = tracing::info_span!(
38056 "xprint_print_start_job",
38057 output_mode = ?output_mode,
38058 );
38059 let request = types::xprint::PrintStartJobRequest { output_mode };
38060 let cookie = self.send_void_request(request, true).with_span(span);
38061 cookie
38062 }
38063 #[cfg(feature = "xprint")]
38064 fn xprint_print_start_job_checked<'this>(
38065 &'this mut self,
38066 output_mode: types::Card8,
38067 ) -> futures::CheckedSendRequest<'this, Self, ()> {
38068 let request = types::xprint::PrintStartJobRequest { output_mode };
38069 let cookie = self.send_void_request(request, false);
38070 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
38071 res
38072 }
38073 #[cfg(feature = "xprint")]
38074 fn xprint_print_end_job<'this>(
38075 &'this mut self,
38076 cancel: types::Bool,
38077 ) -> futures::SendRequest<'this, Self, ()> {
38078 let span = tracing::info_span!(
38079 "xprint_print_end_job",
38080 cancel = ?cancel,
38081 );
38082 let request = types::xprint::PrintEndJobRequest { cancel };
38083 let cookie = self.send_void_request(request, true).with_span(span);
38084 cookie
38085 }
38086 #[cfg(feature = "xprint")]
38087 fn xprint_print_end_job_checked<'this>(
38088 &'this mut self,
38089 cancel: types::Bool,
38090 ) -> futures::CheckedSendRequest<'this, Self, ()> {
38091 let request = types::xprint::PrintEndJobRequest { cancel };
38092 let cookie = self.send_void_request(request, false);
38093 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
38094 res
38095 }
38096 #[cfg(feature = "xprint")]
38097 fn xprint_print_start_doc<'this>(
38098 &'this mut self,
38099 driver_mode: types::Card8,
38100 ) -> futures::SendRequest<'this, Self, ()> {
38101 let span = tracing::info_span!(
38102 "xprint_print_start_doc",
38103 driver_mode = ?driver_mode,
38104 );
38105 let request = types::xprint::PrintStartDocRequest { driver_mode };
38106 let cookie = self.send_void_request(request, true).with_span(span);
38107 cookie
38108 }
38109 #[cfg(feature = "xprint")]
38110 fn xprint_print_start_doc_checked<'this>(
38111 &'this mut self,
38112 driver_mode: types::Card8,
38113 ) -> futures::CheckedSendRequest<'this, Self, ()> {
38114 let request = types::xprint::PrintStartDocRequest { driver_mode };
38115 let cookie = self.send_void_request(request, false);
38116 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
38117 res
38118 }
38119 #[cfg(feature = "xprint")]
38120 fn xprint_print_end_doc<'this>(
38121 &'this mut self,
38122 cancel: types::Bool,
38123 ) -> futures::SendRequest<'this, Self, ()> {
38124 let span = tracing::info_span!(
38125 "xprint_print_end_doc",
38126 cancel = ?cancel,
38127 );
38128 let request = types::xprint::PrintEndDocRequest { cancel };
38129 let cookie = self.send_void_request(request, true).with_span(span);
38130 cookie
38131 }
38132 #[cfg(feature = "xprint")]
38133 fn xprint_print_end_doc_checked<'this>(
38134 &'this mut self,
38135 cancel: types::Bool,
38136 ) -> futures::CheckedSendRequest<'this, Self, ()> {
38137 let request = types::xprint::PrintEndDocRequest { cancel };
38138 let cookie = self.send_void_request(request, false);
38139 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
38140 res
38141 }
38142 #[cfg(feature = "xprint")]
38143 fn xprint_print_put_document_data<'this>(
38144 &'this mut self,
38145 drawable: types::xproto::Drawable,
38146 data: impl AsRef<[types::Byte]>,
38147 doc_format: impl AsRef<[types::xprint::String8]>,
38148 options: impl AsRef<[types::xprint::String8]>,
38149 ) -> futures::SendRequest<'this, Self, ()> {
38150 let span = tracing::info_span!(
38151 "xprint_print_put_document_data",
38152 drawable = ?drawable,
38153 );
38154 let request = types::xprint::PrintPutDocumentDataRequest {
38155 drawable,
38156 data: Cow::Borrowed(data.as_ref()),
38157 doc_format: Cow::Borrowed(doc_format.as_ref()),
38158 options: Cow::Borrowed(options.as_ref()),
38159 };
38160 let cookie = self.send_void_request(request, true).with_span(span);
38161 cookie
38162 }
38163 #[cfg(feature = "xprint")]
38164 fn xprint_print_put_document_data_checked<'this>(
38165 &'this mut self,
38166 drawable: types::xproto::Drawable,
38167 data: impl AsRef<[types::Byte]>,
38168 doc_format: impl AsRef<[types::xprint::String8]>,
38169 options: impl AsRef<[types::xprint::String8]>,
38170 ) -> futures::CheckedSendRequest<'this, Self, ()> {
38171 let request = types::xprint::PrintPutDocumentDataRequest {
38172 drawable,
38173 data: Cow::Borrowed(data.as_ref()),
38174 doc_format: Cow::Borrowed(doc_format.as_ref()),
38175 options: Cow::Borrowed(options.as_ref()),
38176 };
38177 let cookie = self.send_void_request(request, false);
38178 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
38179 res
38180 }
38181 #[cfg(feature = "xprint")]
38182 fn xprint_print_get_document_data<'this>(
38183 &'this mut self,
38184 context: types::Pcontext,
38185 max_bytes: types::Card32,
38186 ) -> futures::SendRequest<'this, Self, types::xprint::PrintGetDocumentDataReply> {
38187 let span = tracing::info_span!(
38188 "xprint_print_get_document_data",
38189 context = ?context,
38190 max_bytes = ?max_bytes,
38191 );
38192 let request = types::xprint::PrintGetDocumentDataRequest { context, max_bytes };
38193 let cookie = self.send_reply_request(request).with_span(span);
38194 cookie
38195 }
38196 #[cfg(feature = "xprint")]
38197 fn xprint_print_get_document_data_immediate<'this>(
38198 &'this mut self,
38199 context: types::Pcontext,
38200 max_bytes: types::Card32,
38201 ) -> futures::CheckedSendRequest<'this, Self, types::xprint::PrintGetDocumentDataReply> {
38202 let request = types::xprint::PrintGetDocumentDataRequest { context, max_bytes };
38203 let cookie = self.send_reply_request(request);
38204 let res: futures::CheckedSendRequest<
38205 'this,
38206 Self,
38207 types::xprint::PrintGetDocumentDataReply,
38208 > = cookie.into();
38209 res
38210 }
38211 #[cfg(feature = "xprint")]
38212 fn xprint_print_start_page<'this>(
38213 &'this mut self,
38214 window: types::xproto::Window,
38215 ) -> futures::SendRequest<'this, Self, ()> {
38216 let span = tracing::info_span!(
38217 "xprint_print_start_page",
38218 window = ?window,
38219 );
38220 let request = types::xprint::PrintStartPageRequest { window };
38221 let cookie = self.send_void_request(request, true).with_span(span);
38222 cookie
38223 }
38224 #[cfg(feature = "xprint")]
38225 fn xprint_print_start_page_checked<'this>(
38226 &'this mut self,
38227 window: types::xproto::Window,
38228 ) -> futures::CheckedSendRequest<'this, Self, ()> {
38229 let request = types::xprint::PrintStartPageRequest { window };
38230 let cookie = self.send_void_request(request, false);
38231 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
38232 res
38233 }
38234 #[cfg(feature = "xprint")]
38235 fn xprint_print_end_page<'this>(
38236 &'this mut self,
38237 cancel: types::Bool,
38238 ) -> futures::SendRequest<'this, Self, ()> {
38239 let span = tracing::info_span!(
38240 "xprint_print_end_page",
38241 cancel = ?cancel,
38242 );
38243 let request = types::xprint::PrintEndPageRequest { cancel };
38244 let cookie = self.send_void_request(request, true).with_span(span);
38245 cookie
38246 }
38247 #[cfg(feature = "xprint")]
38248 fn xprint_print_end_page_checked<'this>(
38249 &'this mut self,
38250 cancel: types::Bool,
38251 ) -> futures::CheckedSendRequest<'this, Self, ()> {
38252 let request = types::xprint::PrintEndPageRequest { cancel };
38253 let cookie = self.send_void_request(request, false);
38254 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
38255 res
38256 }
38257 #[cfg(feature = "xprint")]
38258 fn xprint_print_select_input<'this>(
38259 &'this mut self,
38260 context: types::Pcontext,
38261 event_mask: types::Card32,
38262 ) -> futures::SendRequest<'this, Self, ()> {
38263 let span = tracing::info_span!(
38264 "xprint_print_select_input",
38265 context = ?context,
38266 event_mask = ?event_mask,
38267 );
38268 let request = types::xprint::PrintSelectInputRequest {
38269 context,
38270 event_mask,
38271 };
38272 let cookie = self.send_void_request(request, true).with_span(span);
38273 cookie
38274 }
38275 #[cfg(feature = "xprint")]
38276 fn xprint_print_select_input_checked<'this>(
38277 &'this mut self,
38278 context: types::Pcontext,
38279 event_mask: types::Card32,
38280 ) -> futures::CheckedSendRequest<'this, Self, ()> {
38281 let request = types::xprint::PrintSelectInputRequest {
38282 context,
38283 event_mask,
38284 };
38285 let cookie = self.send_void_request(request, false);
38286 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
38287 res
38288 }
38289 #[cfg(feature = "xprint")]
38290 fn xprint_print_input_selected<'this>(
38291 &'this mut self,
38292 context: types::Pcontext,
38293 ) -> futures::SendRequest<'this, Self, types::xprint::PrintInputSelectedReply> {
38294 let span = tracing::info_span!(
38295 "xprint_print_input_selected",
38296 context = ?context,
38297 );
38298 let request = types::xprint::PrintInputSelectedRequest { context };
38299 let cookie = self.send_reply_request(request).with_span(span);
38300 cookie
38301 }
38302 #[cfg(feature = "xprint")]
38303 fn xprint_print_input_selected_immediate<'this>(
38304 &'this mut self,
38305 context: types::Pcontext,
38306 ) -> futures::CheckedSendRequest<'this, Self, types::xprint::PrintInputSelectedReply> {
38307 let request = types::xprint::PrintInputSelectedRequest { context };
38308 let cookie = self.send_reply_request(request);
38309 let res: futures::CheckedSendRequest<'this, Self, types::xprint::PrintInputSelectedReply> =
38310 cookie.into();
38311 res
38312 }
38313 #[cfg(feature = "xprint")]
38314 fn xprint_print_get_attributes<'this>(
38315 &'this mut self,
38316 context: types::Pcontext,
38317 pool: types::Card8,
38318 ) -> futures::SendRequest<'this, Self, types::xprint::PrintGetAttributesReply> {
38319 let span = tracing::info_span!(
38320 "xprint_print_get_attributes",
38321 context = ?context,
38322 pool = ?pool,
38323 );
38324 let request = types::xprint::PrintGetAttributesRequest { context, pool };
38325 let cookie = self.send_reply_request(request).with_span(span);
38326 cookie
38327 }
38328 #[cfg(feature = "xprint")]
38329 fn xprint_print_get_attributes_immediate<'this>(
38330 &'this mut self,
38331 context: types::Pcontext,
38332 pool: types::Card8,
38333 ) -> futures::CheckedSendRequest<'this, Self, types::xprint::PrintGetAttributesReply> {
38334 let request = types::xprint::PrintGetAttributesRequest { context, pool };
38335 let cookie = self.send_reply_request(request);
38336 let res: futures::CheckedSendRequest<'this, Self, types::xprint::PrintGetAttributesReply> =
38337 cookie.into();
38338 res
38339 }
38340 #[cfg(feature = "xprint")]
38341 fn xprint_print_get_one_attributes<'this>(
38342 &'this mut self,
38343 context: types::Pcontext,
38344 pool: types::Card8,
38345 name: impl AsRef<[types::xprint::String8]>,
38346 ) -> futures::SendRequest<'this, Self, types::xprint::PrintGetOneAttributesReply> {
38347 let span = tracing::info_span!(
38348 "xprint_print_get_one_attributes",
38349 context = ?context,
38350 pool = ?pool,
38351 );
38352 let request = types::xprint::PrintGetOneAttributesRequest {
38353 context,
38354 pool,
38355 name: Cow::Borrowed(name.as_ref()),
38356 };
38357 let cookie = self.send_reply_request(request).with_span(span);
38358 cookie
38359 }
38360 #[cfg(feature = "xprint")]
38361 fn xprint_print_get_one_attributes_immediate<'this>(
38362 &'this mut self,
38363 context: types::Pcontext,
38364 pool: types::Card8,
38365 name: impl AsRef<[types::xprint::String8]>,
38366 ) -> futures::CheckedSendRequest<'this, Self, types::xprint::PrintGetOneAttributesReply> {
38367 let request = types::xprint::PrintGetOneAttributesRequest {
38368 context,
38369 pool,
38370 name: Cow::Borrowed(name.as_ref()),
38371 };
38372 let cookie = self.send_reply_request(request);
38373 let res: futures::CheckedSendRequest<
38374 'this,
38375 Self,
38376 types::xprint::PrintGetOneAttributesReply,
38377 > = cookie.into();
38378 res
38379 }
38380 #[cfg(feature = "xprint")]
38381 fn xprint_print_set_attributes<'this>(
38382 &'this mut self,
38383 context: types::Pcontext,
38384 string_len: types::Card32,
38385 pool: types::Card8,
38386 rule: types::Card8,
38387 attributes: impl AsRef<[types::xprint::String8]>,
38388 ) -> futures::SendRequest<'this, Self, ()> {
38389 let span = tracing::info_span!(
38390 "xprint_print_set_attributes",
38391 context = ?context,
38392 string_len = ?string_len,
38393 pool = ?pool,
38394 rule = ?rule,
38395 );
38396 let request = types::xprint::PrintSetAttributesRequest {
38397 context,
38398 string_len,
38399 pool,
38400 rule,
38401 attributes: Cow::Borrowed(attributes.as_ref()),
38402 };
38403 let cookie = self.send_void_request(request, true).with_span(span);
38404 cookie
38405 }
38406 #[cfg(feature = "xprint")]
38407 fn xprint_print_set_attributes_checked<'this>(
38408 &'this mut self,
38409 context: types::Pcontext,
38410 string_len: types::Card32,
38411 pool: types::Card8,
38412 rule: types::Card8,
38413 attributes: impl AsRef<[types::xprint::String8]>,
38414 ) -> futures::CheckedSendRequest<'this, Self, ()> {
38415 let request = types::xprint::PrintSetAttributesRequest {
38416 context,
38417 string_len,
38418 pool,
38419 rule,
38420 attributes: Cow::Borrowed(attributes.as_ref()),
38421 };
38422 let cookie = self.send_void_request(request, false);
38423 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
38424 res
38425 }
38426 #[cfg(feature = "xprint")]
38427 fn xprint_print_get_page_dimensions<'this>(
38428 &'this mut self,
38429 context: types::Pcontext,
38430 ) -> futures::SendRequest<'this, Self, types::xprint::PrintGetPageDimensionsReply> {
38431 let span = tracing::info_span!(
38432 "xprint_print_get_page_dimensions",
38433 context = ?context,
38434 );
38435 let request = types::xprint::PrintGetPageDimensionsRequest { context };
38436 let cookie = self.send_reply_request(request).with_span(span);
38437 cookie
38438 }
38439 #[cfg(feature = "xprint")]
38440 fn xprint_print_get_page_dimensions_immediate<'this>(
38441 &'this mut self,
38442 context: types::Pcontext,
38443 ) -> futures::CheckedSendRequest<'this, Self, types::xprint::PrintGetPageDimensionsReply> {
38444 let request = types::xprint::PrintGetPageDimensionsRequest { context };
38445 let cookie = self.send_reply_request(request);
38446 let res: futures::CheckedSendRequest<
38447 'this,
38448 Self,
38449 types::xprint::PrintGetPageDimensionsReply,
38450 > = cookie.into();
38451 res
38452 }
38453 #[cfg(feature = "xprint")]
38454 fn xprint_print_query_screens<'this>(
38455 &'this mut self,
38456 ) -> futures::SendRequest<'this, Self, types::xprint::PrintQueryScreensReply> {
38457 let span = tracing::info_span!("xprint_print_query_screens",);
38458 let request = types::xprint::PrintQueryScreensRequest {};
38459 let cookie = self.send_reply_request(request).with_span(span);
38460 cookie
38461 }
38462 #[cfg(feature = "xprint")]
38463 fn xprint_print_query_screens_immediate<'this>(
38464 &'this mut self,
38465 ) -> futures::CheckedSendRequest<'this, Self, types::xprint::PrintQueryScreensReply> {
38466 let request = types::xprint::PrintQueryScreensRequest {};
38467 let cookie = self.send_reply_request(request);
38468 let res: futures::CheckedSendRequest<'this, Self, types::xprint::PrintQueryScreensReply> =
38469 cookie.into();
38470 res
38471 }
38472 #[cfg(feature = "xprint")]
38473 fn xprint_print_set_image_resolution<'this>(
38474 &'this mut self,
38475 context: types::Pcontext,
38476 image_resolution: types::Card16,
38477 ) -> futures::SendRequest<'this, Self, types::xprint::PrintSetImageResolutionReply> {
38478 let span = tracing::info_span!(
38479 "xprint_print_set_image_resolution",
38480 context = ?context,
38481 image_resolution = ?image_resolution,
38482 );
38483 let request = types::xprint::PrintSetImageResolutionRequest {
38484 context,
38485 image_resolution,
38486 };
38487 let cookie = self.send_reply_request(request).with_span(span);
38488 cookie
38489 }
38490 #[cfg(feature = "xprint")]
38491 fn xprint_print_set_image_resolution_immediate<'this>(
38492 &'this mut self,
38493 context: types::Pcontext,
38494 image_resolution: types::Card16,
38495 ) -> futures::CheckedSendRequest<'this, Self, types::xprint::PrintSetImageResolutionReply> {
38496 let request = types::xprint::PrintSetImageResolutionRequest {
38497 context,
38498 image_resolution,
38499 };
38500 let cookie = self.send_reply_request(request);
38501 let res: futures::CheckedSendRequest<
38502 'this,
38503 Self,
38504 types::xprint::PrintSetImageResolutionReply,
38505 > = cookie.into();
38506 res
38507 }
38508 #[cfg(feature = "xprint")]
38509 fn xprint_print_get_image_resolution<'this>(
38510 &'this mut self,
38511 context: types::Pcontext,
38512 ) -> futures::SendRequest<'this, Self, types::xprint::PrintGetImageResolutionReply> {
38513 let span = tracing::info_span!(
38514 "xprint_print_get_image_resolution",
38515 context = ?context,
38516 );
38517 let request = types::xprint::PrintGetImageResolutionRequest { context };
38518 let cookie = self.send_reply_request(request).with_span(span);
38519 cookie
38520 }
38521 #[cfg(feature = "xprint")]
38522 fn xprint_print_get_image_resolution_immediate<'this>(
38523 &'this mut self,
38524 context: types::Pcontext,
38525 ) -> futures::CheckedSendRequest<'this, Self, types::xprint::PrintGetImageResolutionReply> {
38526 let request = types::xprint::PrintGetImageResolutionRequest { context };
38527 let cookie = self.send_reply_request(request);
38528 let res: futures::CheckedSendRequest<
38529 'this,
38530 Self,
38531 types::xprint::PrintGetImageResolutionReply,
38532 > = cookie.into();
38533 res
38534 }
38535
38536 fn create_window<'this>(
38537 &'this mut self,
38538 depth: types::Card8,
38539 wid: types::xproto::Window,
38540 parent: types::xproto::Window,
38541 x: types::Int16,
38542 y: types::Int16,
38543 width: types::Card16,
38544 height: types::Card16,
38545 border_width: types::Card16,
38546 class: types::WindowClass,
38547 visual: types::Visualid,
38548 value_list: impl Borrow<types::xproto::CreateWindowAux>,
38549 ) -> futures::SendRequest<'this, Self, ()> {
38550 let span = tracing::info_span!(
38551 "create_window",
38552 depth = ?depth,
38553 wid = ?wid,
38554 parent = ?parent,
38555 x = ?x,
38556 y = ?y,
38557 width = ?width,
38558 height = ?height,
38559 border_width = ?border_width,
38560 class = ?class,
38561 visual = ?visual,
38562 );
38563 let request = types::xproto::CreateWindowRequest {
38564 depth,
38565 wid,
38566 parent,
38567 x,
38568 y,
38569 width,
38570 height,
38571 border_width,
38572 class,
38573 visual,
38574 value_list: Cow::Borrowed(value_list.borrow()),
38575 };
38576 let cookie = self.send_void_request(request, true).with_span(span);
38577 cookie
38578 }
38579 fn create_window_checked<'this>(
38580 &'this mut self,
38581 depth: types::Card8,
38582 wid: types::xproto::Window,
38583 parent: types::xproto::Window,
38584 x: types::Int16,
38585 y: types::Int16,
38586 width: types::Card16,
38587 height: types::Card16,
38588 border_width: types::Card16,
38589 class: types::WindowClass,
38590 visual: types::Visualid,
38591 value_list: impl Borrow<types::xproto::CreateWindowAux>,
38592 ) -> futures::CheckedSendRequest<'this, Self, ()> {
38593 let request = types::xproto::CreateWindowRequest {
38594 depth,
38595 wid,
38596 parent,
38597 x,
38598 y,
38599 width,
38600 height,
38601 border_width,
38602 class,
38603 visual,
38604 value_list: Cow::Borrowed(value_list.borrow()),
38605 };
38606 let cookie = self.send_void_request(request, false);
38607 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
38608 res
38609 }
38610 fn change_window_attributes<'this>(
38611 &'this mut self,
38612 window: types::xproto::Window,
38613 value_list: impl Borrow<types::xproto::ChangeWindowAttributesAux>,
38614 ) -> futures::SendRequest<'this, Self, ()> {
38615 let span = tracing::info_span!(
38616 "change_window_attributes",
38617 window = ?window,
38618 );
38619 let request = types::xproto::ChangeWindowAttributesRequest {
38620 window,
38621 value_list: Cow::Borrowed(value_list.borrow()),
38622 };
38623 let cookie = self.send_void_request(request, true).with_span(span);
38624 cookie
38625 }
38626 fn change_window_attributes_checked<'this>(
38627 &'this mut self,
38628 window: types::xproto::Window,
38629 value_list: impl Borrow<types::xproto::ChangeWindowAttributesAux>,
38630 ) -> futures::CheckedSendRequest<'this, Self, ()> {
38631 let request = types::xproto::ChangeWindowAttributesRequest {
38632 window,
38633 value_list: Cow::Borrowed(value_list.borrow()),
38634 };
38635 let cookie = self.send_void_request(request, false);
38636 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
38637 res
38638 }
38639 fn get_window_attributes<'this>(
38640 &'this mut self,
38641 window: types::xproto::Window,
38642 ) -> futures::SendRequest<'this, Self, types::xproto::GetWindowAttributesReply> {
38643 let span = tracing::info_span!(
38644 "get_window_attributes",
38645 window = ?window,
38646 );
38647 let request = types::xproto::GetWindowAttributesRequest { window };
38648 let cookie = self.send_reply_request(request).with_span(span);
38649 cookie
38650 }
38651 fn get_window_attributes_immediate<'this>(
38652 &'this mut self,
38653 window: types::xproto::Window,
38654 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::GetWindowAttributesReply> {
38655 let request = types::xproto::GetWindowAttributesRequest { window };
38656 let cookie = self.send_reply_request(request);
38657 let res: futures::CheckedSendRequest<'this, Self, types::xproto::GetWindowAttributesReply> =
38658 cookie.into();
38659 res
38660 }
38661 fn destroy_window<'this>(
38662 &'this mut self,
38663 window: types::xproto::Window,
38664 ) -> futures::SendRequest<'this, Self, ()> {
38665 let span = tracing::info_span!(
38666 "destroy_window",
38667 window = ?window,
38668 );
38669 let request = types::xproto::DestroyWindowRequest { window };
38670 let cookie = self.send_void_request(request, true).with_span(span);
38671 cookie
38672 }
38673 fn destroy_window_checked<'this>(
38674 &'this mut self,
38675 window: types::xproto::Window,
38676 ) -> futures::CheckedSendRequest<'this, Self, ()> {
38677 let request = types::xproto::DestroyWindowRequest { window };
38678 let cookie = self.send_void_request(request, false);
38679 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
38680 res
38681 }
38682 fn destroy_subwindows<'this>(
38683 &'this mut self,
38684 window: types::xproto::Window,
38685 ) -> futures::SendRequest<'this, Self, ()> {
38686 let span = tracing::info_span!(
38687 "destroy_subwindows",
38688 window = ?window,
38689 );
38690 let request = types::xproto::DestroySubwindowsRequest { window };
38691 let cookie = self.send_void_request(request, true).with_span(span);
38692 cookie
38693 }
38694 fn destroy_subwindows_checked<'this>(
38695 &'this mut self,
38696 window: types::xproto::Window,
38697 ) -> futures::CheckedSendRequest<'this, Self, ()> {
38698 let request = types::xproto::DestroySubwindowsRequest { window };
38699 let cookie = self.send_void_request(request, false);
38700 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
38701 res
38702 }
38703 fn change_save_set<'this>(
38704 &'this mut self,
38705 mode: types::SetMode,
38706 window: types::xproto::Window,
38707 ) -> futures::SendRequest<'this, Self, ()> {
38708 let span = tracing::info_span!(
38709 "change_save_set",
38710 mode = ?mode,
38711 window = ?window,
38712 );
38713 let request = types::xproto::ChangeSaveSetRequest { mode, window };
38714 let cookie = self.send_void_request(request, true).with_span(span);
38715 cookie
38716 }
38717 fn change_save_set_checked<'this>(
38718 &'this mut self,
38719 mode: types::SetMode,
38720 window: types::xproto::Window,
38721 ) -> futures::CheckedSendRequest<'this, Self, ()> {
38722 let request = types::xproto::ChangeSaveSetRequest { mode, window };
38723 let cookie = self.send_void_request(request, false);
38724 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
38725 res
38726 }
38727 fn reparent_window<'this>(
38728 &'this mut self,
38729 window: types::xproto::Window,
38730 parent: types::xproto::Window,
38731 x: types::Int16,
38732 y: types::Int16,
38733 ) -> futures::SendRequest<'this, Self, ()> {
38734 let span = tracing::info_span!(
38735 "reparent_window",
38736 window = ?window,
38737 parent = ?parent,
38738 x = ?x,
38739 y = ?y,
38740 );
38741 let request = types::xproto::ReparentWindowRequest {
38742 window,
38743 parent,
38744 x,
38745 y,
38746 };
38747 let cookie = self.send_void_request(request, true).with_span(span);
38748 cookie
38749 }
38750 fn reparent_window_checked<'this>(
38751 &'this mut self,
38752 window: types::xproto::Window,
38753 parent: types::xproto::Window,
38754 x: types::Int16,
38755 y: types::Int16,
38756 ) -> futures::CheckedSendRequest<'this, Self, ()> {
38757 let request = types::xproto::ReparentWindowRequest {
38758 window,
38759 parent,
38760 x,
38761 y,
38762 };
38763 let cookie = self.send_void_request(request, false);
38764 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
38765 res
38766 }
38767 fn map_window<'this>(
38768 &'this mut self,
38769 window: types::xproto::Window,
38770 ) -> futures::SendRequest<'this, Self, ()> {
38771 let span = tracing::info_span!(
38772 "map_window",
38773 window = ?window,
38774 );
38775 let request = types::xproto::MapWindowRequest { window };
38776 let cookie = self.send_void_request(request, true).with_span(span);
38777 cookie
38778 }
38779 fn map_window_checked<'this>(
38780 &'this mut self,
38781 window: types::xproto::Window,
38782 ) -> futures::CheckedSendRequest<'this, Self, ()> {
38783 let request = types::xproto::MapWindowRequest { window };
38784 let cookie = self.send_void_request(request, false);
38785 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
38786 res
38787 }
38788 fn map_subwindows<'this>(
38789 &'this mut self,
38790 window: types::xproto::Window,
38791 ) -> futures::SendRequest<'this, Self, ()> {
38792 let span = tracing::info_span!(
38793 "map_subwindows",
38794 window = ?window,
38795 );
38796 let request = types::xproto::MapSubwindowsRequest { window };
38797 let cookie = self.send_void_request(request, true).with_span(span);
38798 cookie
38799 }
38800 fn map_subwindows_checked<'this>(
38801 &'this mut self,
38802 window: types::xproto::Window,
38803 ) -> futures::CheckedSendRequest<'this, Self, ()> {
38804 let request = types::xproto::MapSubwindowsRequest { window };
38805 let cookie = self.send_void_request(request, false);
38806 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
38807 res
38808 }
38809 fn unmap_window<'this>(
38810 &'this mut self,
38811 window: types::xproto::Window,
38812 ) -> futures::SendRequest<'this, Self, ()> {
38813 let span = tracing::info_span!(
38814 "unmap_window",
38815 window = ?window,
38816 );
38817 let request = types::xproto::UnmapWindowRequest { window };
38818 let cookie = self.send_void_request(request, true).with_span(span);
38819 cookie
38820 }
38821 fn unmap_window_checked<'this>(
38822 &'this mut self,
38823 window: types::xproto::Window,
38824 ) -> futures::CheckedSendRequest<'this, Self, ()> {
38825 let request = types::xproto::UnmapWindowRequest { window };
38826 let cookie = self.send_void_request(request, false);
38827 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
38828 res
38829 }
38830 fn unmap_subwindows<'this>(
38831 &'this mut self,
38832 window: types::xproto::Window,
38833 ) -> futures::SendRequest<'this, Self, ()> {
38834 let span = tracing::info_span!(
38835 "unmap_subwindows",
38836 window = ?window,
38837 );
38838 let request = types::xproto::UnmapSubwindowsRequest { window };
38839 let cookie = self.send_void_request(request, true).with_span(span);
38840 cookie
38841 }
38842 fn unmap_subwindows_checked<'this>(
38843 &'this mut self,
38844 window: types::xproto::Window,
38845 ) -> futures::CheckedSendRequest<'this, Self, ()> {
38846 let request = types::xproto::UnmapSubwindowsRequest { window };
38847 let cookie = self.send_void_request(request, false);
38848 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
38849 res
38850 }
38851 fn configure_window<'this>(
38852 &'this mut self,
38853 window: types::xproto::Window,
38854 value_list: impl Borrow<types::xproto::ConfigureWindowAux>,
38855 ) -> futures::SendRequest<'this, Self, ()> {
38856 let span = tracing::info_span!(
38857 "configure_window",
38858 window = ?window,
38859 );
38860 let request = types::xproto::ConfigureWindowRequest {
38861 window,
38862 value_list: Cow::Borrowed(value_list.borrow()),
38863 };
38864 let cookie = self.send_void_request(request, true).with_span(span);
38865 cookie
38866 }
38867 fn configure_window_checked<'this>(
38868 &'this mut self,
38869 window: types::xproto::Window,
38870 value_list: impl Borrow<types::xproto::ConfigureWindowAux>,
38871 ) -> futures::CheckedSendRequest<'this, Self, ()> {
38872 let request = types::xproto::ConfigureWindowRequest {
38873 window,
38874 value_list: Cow::Borrowed(value_list.borrow()),
38875 };
38876 let cookie = self.send_void_request(request, false);
38877 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
38878 res
38879 }
38880 fn circulate_window<'this>(
38881 &'this mut self,
38882 direction: types::Circulate,
38883 window: types::xproto::Window,
38884 ) -> futures::SendRequest<'this, Self, ()> {
38885 let span = tracing::info_span!(
38886 "circulate_window",
38887 direction = ?direction,
38888 window = ?window,
38889 );
38890 let request = types::xproto::CirculateWindowRequest { direction, window };
38891 let cookie = self.send_void_request(request, true).with_span(span);
38892 cookie
38893 }
38894 fn circulate_window_checked<'this>(
38895 &'this mut self,
38896 direction: types::Circulate,
38897 window: types::xproto::Window,
38898 ) -> futures::CheckedSendRequest<'this, Self, ()> {
38899 let request = types::xproto::CirculateWindowRequest { direction, window };
38900 let cookie = self.send_void_request(request, false);
38901 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
38902 res
38903 }
38904 fn get_geometry<'this>(
38905 &'this mut self,
38906 drawable: types::xproto::Drawable,
38907 ) -> futures::SendRequest<'this, Self, types::xproto::GetGeometryReply> {
38908 let span = tracing::info_span!(
38909 "get_geometry",
38910 drawable = ?drawable,
38911 );
38912 let request = types::xproto::GetGeometryRequest { drawable };
38913 let cookie = self.send_reply_request(request).with_span(span);
38914 cookie
38915 }
38916 fn get_geometry_immediate<'this>(
38917 &'this mut self,
38918 drawable: types::xproto::Drawable,
38919 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::GetGeometryReply> {
38920 let request = types::xproto::GetGeometryRequest { drawable };
38921 let cookie = self.send_reply_request(request);
38922 let res: futures::CheckedSendRequest<'this, Self, types::xproto::GetGeometryReply> =
38923 cookie.into();
38924 res
38925 }
38926 fn query_tree<'this>(
38927 &'this mut self,
38928 window: types::xproto::Window,
38929 ) -> futures::SendRequest<'this, Self, types::xproto::QueryTreeReply> {
38930 let span = tracing::info_span!(
38931 "query_tree",
38932 window = ?window,
38933 );
38934 let request = types::xproto::QueryTreeRequest { window };
38935 let cookie = self.send_reply_request(request).with_span(span);
38936 cookie
38937 }
38938 fn query_tree_immediate<'this>(
38939 &'this mut self,
38940 window: types::xproto::Window,
38941 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::QueryTreeReply> {
38942 let request = types::xproto::QueryTreeRequest { window };
38943 let cookie = self.send_reply_request(request);
38944 let res: futures::CheckedSendRequest<'this, Self, types::xproto::QueryTreeReply> =
38945 cookie.into();
38946 res
38947 }
38948 fn intern_atom<'this>(
38949 &'this mut self,
38950 only_if_exists: types::Bool,
38951 name: impl AsRef<[types::Char]>,
38952 ) -> futures::SendRequest<'this, Self, types::xproto::InternAtomReply> {
38953 let span = tracing::info_span!(
38954 "intern_atom",
38955 only_if_exists = ?only_if_exists,
38956 );
38957 let request = types::xproto::InternAtomRequest {
38958 only_if_exists,
38959 name: Cow::Borrowed(name.as_ref()),
38960 };
38961 let cookie = self.send_reply_request(request).with_span(span);
38962 cookie
38963 }
38964 fn intern_atom_immediate<'this>(
38965 &'this mut self,
38966 only_if_exists: types::Bool,
38967 name: impl AsRef<[types::Char]>,
38968 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::InternAtomReply> {
38969 let request = types::xproto::InternAtomRequest {
38970 only_if_exists,
38971 name: Cow::Borrowed(name.as_ref()),
38972 };
38973 let cookie = self.send_reply_request(request);
38974 let res: futures::CheckedSendRequest<'this, Self, types::xproto::InternAtomReply> =
38975 cookie.into();
38976 res
38977 }
38978 fn get_atom_name<'this>(
38979 &'this mut self,
38980 atom: types::Atom,
38981 ) -> futures::SendRequest<'this, Self, types::xproto::GetAtomNameReply> {
38982 let span = tracing::info_span!(
38983 "get_atom_name",
38984 atom = ?atom,
38985 );
38986 let request = types::xproto::GetAtomNameRequest { atom };
38987 let cookie = self.send_reply_request(request).with_span(span);
38988 cookie
38989 }
38990 fn get_atom_name_immediate<'this>(
38991 &'this mut self,
38992 atom: types::Atom,
38993 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::GetAtomNameReply> {
38994 let request = types::xproto::GetAtomNameRequest { atom };
38995 let cookie = self.send_reply_request(request);
38996 let res: futures::CheckedSendRequest<'this, Self, types::xproto::GetAtomNameReply> =
38997 cookie.into();
38998 res
38999 }
39000 fn change_property<'this>(
39001 &'this mut self,
39002 mode: types::PropMode,
39003 window: types::xproto::Window,
39004 property: types::Atom,
39005 type_: types::Atom,
39006 format: types::Card8,
39007 data_len: types::Card32,
39008 data: &(impl crate::Void + ?Sized),
39009 ) -> futures::SendRequest<'this, Self, ()> {
39010 let span = tracing::info_span!(
39011 "change_property",
39012 mode = ?mode,
39013 window = ?window,
39014 property = ?property,
39015 type_ = ?type_,
39016 format = ?format,
39017 data_len = ?data_len,
39018 );
39019 let request = types::xproto::ChangePropertyRequest {
39020 mode,
39021 window,
39022 property,
39023 type_,
39024 format,
39025 data_len,
39026 data: Cow::Borrowed(data.bytes()),
39027 };
39028 let cookie = self.send_void_request(request, true).with_span(span);
39029 cookie
39030 }
39031 fn change_property_checked<'this>(
39032 &'this mut self,
39033 mode: types::PropMode,
39034 window: types::xproto::Window,
39035 property: types::Atom,
39036 type_: types::Atom,
39037 format: types::Card8,
39038 data_len: types::Card32,
39039 data: &(impl crate::Void + ?Sized),
39040 ) -> futures::CheckedSendRequest<'this, Self, ()> {
39041 let request = types::xproto::ChangePropertyRequest {
39042 mode,
39043 window,
39044 property,
39045 type_,
39046 format,
39047 data_len,
39048 data: Cow::Borrowed(data.bytes()),
39049 };
39050 let cookie = self.send_void_request(request, false);
39051 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
39052 res
39053 }
39054 fn delete_property<'this>(
39055 &'this mut self,
39056 window: types::xproto::Window,
39057 property: types::Atom,
39058 ) -> futures::SendRequest<'this, Self, ()> {
39059 let span = tracing::info_span!(
39060 "delete_property",
39061 window = ?window,
39062 property = ?property,
39063 );
39064 let request = types::xproto::DeletePropertyRequest { window, property };
39065 let cookie = self.send_void_request(request, true).with_span(span);
39066 cookie
39067 }
39068 fn delete_property_checked<'this>(
39069 &'this mut self,
39070 window: types::xproto::Window,
39071 property: types::Atom,
39072 ) -> futures::CheckedSendRequest<'this, Self, ()> {
39073 let request = types::xproto::DeletePropertyRequest { window, property };
39074 let cookie = self.send_void_request(request, false);
39075 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
39076 res
39077 }
39078 fn get_property<'this>(
39079 &'this mut self,
39080 delete: types::Bool,
39081 window: types::xproto::Window,
39082 property: types::Atom,
39083 type_: impl Into<types::GetPropertyType>,
39084 long_offset: types::Card32,
39085 long_length: types::Card32,
39086 ) -> futures::SendRequest<'this, Self, types::xproto::GetPropertyReply> {
39087 let span = tracing::info_span!(
39088 "get_property",
39089 delete = ?delete,
39090 window = ?window,
39091 property = ?property,
39092 long_offset = ?long_offset,
39093 long_length = ?long_length,
39094 );
39095 let request = types::xproto::GetPropertyRequest {
39096 delete,
39097 window,
39098 property,
39099 type_: Into::<u32>::into(type_.into()) as _,
39100 long_offset,
39101 long_length,
39102 };
39103 let cookie = self.send_reply_request(request).with_span(span);
39104 cookie
39105 }
39106 fn get_property_immediate<'this>(
39107 &'this mut self,
39108 delete: types::Bool,
39109 window: types::xproto::Window,
39110 property: types::Atom,
39111 type_: impl Into<types::GetPropertyType>,
39112 long_offset: types::Card32,
39113 long_length: types::Card32,
39114 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::GetPropertyReply> {
39115 let request = types::xproto::GetPropertyRequest {
39116 delete,
39117 window,
39118 property,
39119 type_: Into::<u32>::into(type_.into()) as _,
39120 long_offset,
39121 long_length,
39122 };
39123 let cookie = self.send_reply_request(request);
39124 let res: futures::CheckedSendRequest<'this, Self, types::xproto::GetPropertyReply> =
39125 cookie.into();
39126 res
39127 }
39128 fn list_properties<'this>(
39129 &'this mut self,
39130 window: types::xproto::Window,
39131 ) -> futures::SendRequest<'this, Self, types::xproto::ListPropertiesReply> {
39132 let span = tracing::info_span!(
39133 "list_properties",
39134 window = ?window,
39135 );
39136 let request = types::xproto::ListPropertiesRequest { window };
39137 let cookie = self.send_reply_request(request).with_span(span);
39138 cookie
39139 }
39140 fn list_properties_immediate<'this>(
39141 &'this mut self,
39142 window: types::xproto::Window,
39143 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::ListPropertiesReply> {
39144 let request = types::xproto::ListPropertiesRequest { window };
39145 let cookie = self.send_reply_request(request);
39146 let res: futures::CheckedSendRequest<'this, Self, types::xproto::ListPropertiesReply> =
39147 cookie.into();
39148 res
39149 }
39150 fn set_selection_owner<'this>(
39151 &'this mut self,
39152 owner: impl Into<types::xproto::Window>,
39153 selection: types::Atom,
39154 time: impl Into<types::Time>,
39155 ) -> futures::SendRequest<'this, Self, ()> {
39156 let span = tracing::info_span!(
39157 "set_selection_owner",
39158 selection = ?selection,
39159 );
39160 let request = types::xproto::SetSelectionOwnerRequest {
39161 owner: Into::<u32>::into(owner.into()) as _,
39162 selection,
39163 time: Into::<u32>::into(time.into()) as _,
39164 };
39165 let cookie = self.send_void_request(request, true).with_span(span);
39166 cookie
39167 }
39168 fn set_selection_owner_checked<'this>(
39169 &'this mut self,
39170 owner: impl Into<types::xproto::Window>,
39171 selection: types::Atom,
39172 time: impl Into<types::Time>,
39173 ) -> futures::CheckedSendRequest<'this, Self, ()> {
39174 let request = types::xproto::SetSelectionOwnerRequest {
39175 owner: Into::<u32>::into(owner.into()) as _,
39176 selection,
39177 time: Into::<u32>::into(time.into()) as _,
39178 };
39179 let cookie = self.send_void_request(request, false);
39180 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
39181 res
39182 }
39183 fn get_selection_owner<'this>(
39184 &'this mut self,
39185 selection: types::Atom,
39186 ) -> futures::SendRequest<'this, Self, types::xproto::GetSelectionOwnerReply> {
39187 let span = tracing::info_span!(
39188 "get_selection_owner",
39189 selection = ?selection,
39190 );
39191 let request = types::xproto::GetSelectionOwnerRequest { selection };
39192 let cookie = self.send_reply_request(request).with_span(span);
39193 cookie
39194 }
39195 fn get_selection_owner_immediate<'this>(
39196 &'this mut self,
39197 selection: types::Atom,
39198 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::GetSelectionOwnerReply> {
39199 let request = types::xproto::GetSelectionOwnerRequest { selection };
39200 let cookie = self.send_reply_request(request);
39201 let res: futures::CheckedSendRequest<'this, Self, types::xproto::GetSelectionOwnerReply> =
39202 cookie.into();
39203 res
39204 }
39205 fn convert_selection<'this>(
39206 &'this mut self,
39207 requestor: types::xproto::Window,
39208 selection: types::Atom,
39209 target: types::Atom,
39210 property: impl Into<types::Atom>,
39211 time: impl Into<types::Time>,
39212 ) -> futures::SendRequest<'this, Self, ()> {
39213 let span = tracing::info_span!(
39214 "convert_selection",
39215 requestor = ?requestor,
39216 selection = ?selection,
39217 target = ?target,
39218 );
39219 let request = types::xproto::ConvertSelectionRequest {
39220 requestor,
39221 selection,
39222 target,
39223 property: Into::<u32>::into(property.into()) as _,
39224 time: Into::<u32>::into(time.into()) as _,
39225 };
39226 let cookie = self.send_void_request(request, true).with_span(span);
39227 cookie
39228 }
39229 fn convert_selection_checked<'this>(
39230 &'this mut self,
39231 requestor: types::xproto::Window,
39232 selection: types::Atom,
39233 target: types::Atom,
39234 property: impl Into<types::Atom>,
39235 time: impl Into<types::Time>,
39236 ) -> futures::CheckedSendRequest<'this, Self, ()> {
39237 let request = types::xproto::ConvertSelectionRequest {
39238 requestor,
39239 selection,
39240 target,
39241 property: Into::<u32>::into(property.into()) as _,
39242 time: Into::<u32>::into(time.into()) as _,
39243 };
39244 let cookie = self.send_void_request(request, false);
39245 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
39246 res
39247 }
39248 fn send_event<'this>(
39249 &'this mut self,
39250 propagate: types::Bool,
39251 destination: impl Into<types::SendEventDest>,
39252 event_mask: impl Into<types::xproto::EventMask>,
39253 event: impl Borrow<[types::Char; 32]>,
39254 ) -> futures::SendRequest<'this, Self, ()> {
39255 let span = tracing::info_span!(
39256 "send_event",
39257 propagate = ?propagate,
39258 );
39259 let request = types::xproto::SendEventRequest {
39260 propagate,
39261 destination: Into::<u32>::into(destination.into()) as _,
39262 event_mask: Into::<u32>::into(event_mask.into()) as _,
39263 event: Cow::Borrowed(event.borrow()),
39264 };
39265 let cookie = self.send_void_request(request, true).with_span(span);
39266 cookie
39267 }
39268 fn send_event_checked<'this>(
39269 &'this mut self,
39270 propagate: types::Bool,
39271 destination: impl Into<types::SendEventDest>,
39272 event_mask: impl Into<types::xproto::EventMask>,
39273 event: impl Borrow<[types::Char; 32]>,
39274 ) -> futures::CheckedSendRequest<'this, Self, ()> {
39275 let request = types::xproto::SendEventRequest {
39276 propagate,
39277 destination: Into::<u32>::into(destination.into()) as _,
39278 event_mask: Into::<u32>::into(event_mask.into()) as _,
39279 event: Cow::Borrowed(event.borrow()),
39280 };
39281 let cookie = self.send_void_request(request, false);
39282 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
39283 res
39284 }
39285 fn grab_pointer<'this>(
39286 &'this mut self,
39287 owner_events: types::Bool,
39288 grab_window: types::xproto::Window,
39289 event_mask: impl Into<types::xproto::EventMask>,
39290 pointer_mode: types::GrabMode,
39291 keyboard_mode: types::GrabMode,
39292 confine_to: impl Into<types::xproto::Window>,
39293 cursor: impl Into<types::xproto::Cursor>,
39294 time: impl Into<types::Time>,
39295 ) -> futures::SendRequest<'this, Self, types::xproto::GrabPointerReply> {
39296 let span = tracing::info_span!(
39297 "grab_pointer",
39298 owner_events = ?owner_events,
39299 grab_window = ?grab_window,
39300 pointer_mode = ?pointer_mode,
39301 keyboard_mode = ?keyboard_mode,
39302 );
39303 let request = types::xproto::GrabPointerRequest {
39304 owner_events,
39305 grab_window,
39306 event_mask: Into::<u32>::into(event_mask.into()) as _,
39307 pointer_mode,
39308 keyboard_mode,
39309 confine_to: Into::<u32>::into(confine_to.into()) as _,
39310 cursor: Into::<u32>::into(cursor.into()) as _,
39311 time: Into::<u32>::into(time.into()) as _,
39312 };
39313 let cookie = self.send_reply_request(request).with_span(span);
39314 cookie
39315 }
39316 fn grab_pointer_immediate<'this>(
39317 &'this mut self,
39318 owner_events: types::Bool,
39319 grab_window: types::xproto::Window,
39320 event_mask: impl Into<types::xproto::EventMask>,
39321 pointer_mode: types::GrabMode,
39322 keyboard_mode: types::GrabMode,
39323 confine_to: impl Into<types::xproto::Window>,
39324 cursor: impl Into<types::xproto::Cursor>,
39325 time: impl Into<types::Time>,
39326 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::GrabPointerReply> {
39327 let request = types::xproto::GrabPointerRequest {
39328 owner_events,
39329 grab_window,
39330 event_mask: Into::<u32>::into(event_mask.into()) as _,
39331 pointer_mode,
39332 keyboard_mode,
39333 confine_to: Into::<u32>::into(confine_to.into()) as _,
39334 cursor: Into::<u32>::into(cursor.into()) as _,
39335 time: Into::<u32>::into(time.into()) as _,
39336 };
39337 let cookie = self.send_reply_request(request);
39338 let res: futures::CheckedSendRequest<'this, Self, types::xproto::GrabPointerReply> =
39339 cookie.into();
39340 res
39341 }
39342 fn ungrab_pointer<'this>(
39343 &'this mut self,
39344 time: impl Into<types::Time>,
39345 ) -> futures::SendRequest<'this, Self, ()> {
39346 let span = tracing::info_span!("ungrab_pointer",);
39347 let request = types::xproto::UngrabPointerRequest {
39348 time: Into::<u32>::into(time.into()) as _,
39349 };
39350 let cookie = self.send_void_request(request, true).with_span(span);
39351 cookie
39352 }
39353 fn ungrab_pointer_checked<'this>(
39354 &'this mut self,
39355 time: impl Into<types::Time>,
39356 ) -> futures::CheckedSendRequest<'this, Self, ()> {
39357 let request = types::xproto::UngrabPointerRequest {
39358 time: Into::<u32>::into(time.into()) as _,
39359 };
39360 let cookie = self.send_void_request(request, false);
39361 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
39362 res
39363 }
39364 fn grab_button<'this>(
39365 &'this mut self,
39366 owner_events: types::Bool,
39367 grab_window: types::xproto::Window,
39368 event_mask: impl Into<types::xproto::EventMask>,
39369 pointer_mode: types::GrabMode,
39370 keyboard_mode: types::GrabMode,
39371 confine_to: impl Into<types::xproto::Window>,
39372 cursor: impl Into<types::xproto::Cursor>,
39373 button: types::ButtonIndex,
39374 modifiers: impl Into<types::ModMask>,
39375 ) -> futures::SendRequest<'this, Self, ()> {
39376 let span = tracing::info_span!(
39377 "grab_button",
39378 owner_events = ?owner_events,
39379 grab_window = ?grab_window,
39380 pointer_mode = ?pointer_mode,
39381 keyboard_mode = ?keyboard_mode,
39382 button = ?button,
39383 );
39384 let request = types::xproto::GrabButtonRequest {
39385 owner_events,
39386 grab_window,
39387 event_mask: Into::<u32>::into(event_mask.into()) as _,
39388 pointer_mode,
39389 keyboard_mode,
39390 confine_to: Into::<u32>::into(confine_to.into()) as _,
39391 cursor: Into::<u32>::into(cursor.into()) as _,
39392 button,
39393 modifiers: Into::<u32>::into(modifiers.into()) as _,
39394 };
39395 let cookie = self.send_void_request(request, true).with_span(span);
39396 cookie
39397 }
39398 fn grab_button_checked<'this>(
39399 &'this mut self,
39400 owner_events: types::Bool,
39401 grab_window: types::xproto::Window,
39402 event_mask: impl Into<types::xproto::EventMask>,
39403 pointer_mode: types::GrabMode,
39404 keyboard_mode: types::GrabMode,
39405 confine_to: impl Into<types::xproto::Window>,
39406 cursor: impl Into<types::xproto::Cursor>,
39407 button: types::ButtonIndex,
39408 modifiers: impl Into<types::ModMask>,
39409 ) -> futures::CheckedSendRequest<'this, Self, ()> {
39410 let request = types::xproto::GrabButtonRequest {
39411 owner_events,
39412 grab_window,
39413 event_mask: Into::<u32>::into(event_mask.into()) as _,
39414 pointer_mode,
39415 keyboard_mode,
39416 confine_to: Into::<u32>::into(confine_to.into()) as _,
39417 cursor: Into::<u32>::into(cursor.into()) as _,
39418 button,
39419 modifiers: Into::<u32>::into(modifiers.into()) as _,
39420 };
39421 let cookie = self.send_void_request(request, false);
39422 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
39423 res
39424 }
39425 fn ungrab_button<'this>(
39426 &'this mut self,
39427 button: types::ButtonIndex,
39428 grab_window: types::xproto::Window,
39429 modifiers: impl Into<types::ModMask>,
39430 ) -> futures::SendRequest<'this, Self, ()> {
39431 let span = tracing::info_span!(
39432 "ungrab_button",
39433 button = ?button,
39434 grab_window = ?grab_window,
39435 );
39436 let request = types::xproto::UngrabButtonRequest {
39437 button,
39438 grab_window,
39439 modifiers: Into::<u32>::into(modifiers.into()) as _,
39440 };
39441 let cookie = self.send_void_request(request, true).with_span(span);
39442 cookie
39443 }
39444 fn ungrab_button_checked<'this>(
39445 &'this mut self,
39446 button: types::ButtonIndex,
39447 grab_window: types::xproto::Window,
39448 modifiers: impl Into<types::ModMask>,
39449 ) -> futures::CheckedSendRequest<'this, Self, ()> {
39450 let request = types::xproto::UngrabButtonRequest {
39451 button,
39452 grab_window,
39453 modifiers: Into::<u32>::into(modifiers.into()) as _,
39454 };
39455 let cookie = self.send_void_request(request, false);
39456 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
39457 res
39458 }
39459 fn change_active_pointer_grab<'this>(
39460 &'this mut self,
39461 cursor: impl Into<types::xproto::Cursor>,
39462 time: impl Into<types::Time>,
39463 event_mask: impl Into<types::xproto::EventMask>,
39464 ) -> futures::SendRequest<'this, Self, ()> {
39465 let span = tracing::info_span!("change_active_pointer_grab",);
39466 let request = types::xproto::ChangeActivePointerGrabRequest {
39467 cursor: Into::<u32>::into(cursor.into()) as _,
39468 time: Into::<u32>::into(time.into()) as _,
39469 event_mask: Into::<u32>::into(event_mask.into()) as _,
39470 };
39471 let cookie = self.send_void_request(request, true).with_span(span);
39472 cookie
39473 }
39474 fn change_active_pointer_grab_checked<'this>(
39475 &'this mut self,
39476 cursor: impl Into<types::xproto::Cursor>,
39477 time: impl Into<types::Time>,
39478 event_mask: impl Into<types::xproto::EventMask>,
39479 ) -> futures::CheckedSendRequest<'this, Self, ()> {
39480 let request = types::xproto::ChangeActivePointerGrabRequest {
39481 cursor: Into::<u32>::into(cursor.into()) as _,
39482 time: Into::<u32>::into(time.into()) as _,
39483 event_mask: Into::<u32>::into(event_mask.into()) as _,
39484 };
39485 let cookie = self.send_void_request(request, false);
39486 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
39487 res
39488 }
39489 fn grab_keyboard<'this>(
39490 &'this mut self,
39491 owner_events: types::Bool,
39492 grab_window: types::xproto::Window,
39493 time: impl Into<types::Time>,
39494 pointer_mode: types::GrabMode,
39495 keyboard_mode: types::GrabMode,
39496 ) -> futures::SendRequest<'this, Self, types::xproto::GrabKeyboardReply> {
39497 let span = tracing::info_span!(
39498 "grab_keyboard",
39499 owner_events = ?owner_events,
39500 grab_window = ?grab_window,
39501 pointer_mode = ?pointer_mode,
39502 keyboard_mode = ?keyboard_mode,
39503 );
39504 let request = types::xproto::GrabKeyboardRequest {
39505 owner_events,
39506 grab_window,
39507 time: Into::<u32>::into(time.into()) as _,
39508 pointer_mode,
39509 keyboard_mode,
39510 };
39511 let cookie = self.send_reply_request(request).with_span(span);
39512 cookie
39513 }
39514 fn grab_keyboard_immediate<'this>(
39515 &'this mut self,
39516 owner_events: types::Bool,
39517 grab_window: types::xproto::Window,
39518 time: impl Into<types::Time>,
39519 pointer_mode: types::GrabMode,
39520 keyboard_mode: types::GrabMode,
39521 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::GrabKeyboardReply> {
39522 let request = types::xproto::GrabKeyboardRequest {
39523 owner_events,
39524 grab_window,
39525 time: Into::<u32>::into(time.into()) as _,
39526 pointer_mode,
39527 keyboard_mode,
39528 };
39529 let cookie = self.send_reply_request(request);
39530 let res: futures::CheckedSendRequest<'this, Self, types::xproto::GrabKeyboardReply> =
39531 cookie.into();
39532 res
39533 }
39534 fn ungrab_keyboard<'this>(
39535 &'this mut self,
39536 time: impl Into<types::Time>,
39537 ) -> futures::SendRequest<'this, Self, ()> {
39538 let span = tracing::info_span!("ungrab_keyboard",);
39539 let request = types::xproto::UngrabKeyboardRequest {
39540 time: Into::<u32>::into(time.into()) as _,
39541 };
39542 let cookie = self.send_void_request(request, true).with_span(span);
39543 cookie
39544 }
39545 fn ungrab_keyboard_checked<'this>(
39546 &'this mut self,
39547 time: impl Into<types::Time>,
39548 ) -> futures::CheckedSendRequest<'this, Self, ()> {
39549 let request = types::xproto::UngrabKeyboardRequest {
39550 time: Into::<u32>::into(time.into()) as _,
39551 };
39552 let cookie = self.send_void_request(request, false);
39553 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
39554 res
39555 }
39556 fn grab_key<'this>(
39557 &'this mut self,
39558 owner_events: types::Bool,
39559 grab_window: types::xproto::Window,
39560 modifiers: impl Into<types::ModMask>,
39561 key: impl Into<types::Grab>,
39562 pointer_mode: types::GrabMode,
39563 keyboard_mode: types::GrabMode,
39564 ) -> futures::SendRequest<'this, Self, ()> {
39565 let span = tracing::info_span!(
39566 "grab_key",
39567 owner_events = ?owner_events,
39568 grab_window = ?grab_window,
39569 pointer_mode = ?pointer_mode,
39570 keyboard_mode = ?keyboard_mode,
39571 );
39572 let request = types::xproto::GrabKeyRequest {
39573 owner_events,
39574 grab_window,
39575 modifiers: Into::<u32>::into(modifiers.into()) as _,
39576 key: Into::<u32>::into(key.into()) as _,
39577 pointer_mode,
39578 keyboard_mode,
39579 };
39580 let cookie = self.send_void_request(request, true).with_span(span);
39581 cookie
39582 }
39583 fn grab_key_checked<'this>(
39584 &'this mut self,
39585 owner_events: types::Bool,
39586 grab_window: types::xproto::Window,
39587 modifiers: impl Into<types::ModMask>,
39588 key: impl Into<types::Grab>,
39589 pointer_mode: types::GrabMode,
39590 keyboard_mode: types::GrabMode,
39591 ) -> futures::CheckedSendRequest<'this, Self, ()> {
39592 let request = types::xproto::GrabKeyRequest {
39593 owner_events,
39594 grab_window,
39595 modifiers: Into::<u32>::into(modifiers.into()) as _,
39596 key: Into::<u32>::into(key.into()) as _,
39597 pointer_mode,
39598 keyboard_mode,
39599 };
39600 let cookie = self.send_void_request(request, false);
39601 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
39602 res
39603 }
39604 fn ungrab_key<'this>(
39605 &'this mut self,
39606 key: impl Into<types::Grab>,
39607 grab_window: types::xproto::Window,
39608 modifiers: impl Into<types::ModMask>,
39609 ) -> futures::SendRequest<'this, Self, ()> {
39610 let span = tracing::info_span!(
39611 "ungrab_key",
39612 grab_window = ?grab_window,
39613 );
39614 let request = types::xproto::UngrabKeyRequest {
39615 key: Into::<u32>::into(key.into()) as _,
39616 grab_window,
39617 modifiers: Into::<u32>::into(modifiers.into()) as _,
39618 };
39619 let cookie = self.send_void_request(request, true).with_span(span);
39620 cookie
39621 }
39622 fn ungrab_key_checked<'this>(
39623 &'this mut self,
39624 key: impl Into<types::Grab>,
39625 grab_window: types::xproto::Window,
39626 modifiers: impl Into<types::ModMask>,
39627 ) -> futures::CheckedSendRequest<'this, Self, ()> {
39628 let request = types::xproto::UngrabKeyRequest {
39629 key: Into::<u32>::into(key.into()) as _,
39630 grab_window,
39631 modifiers: Into::<u32>::into(modifiers.into()) as _,
39632 };
39633 let cookie = self.send_void_request(request, false);
39634 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
39635 res
39636 }
39637 fn allow_events<'this>(
39638 &'this mut self,
39639 mode: types::Allow,
39640 time: impl Into<types::Time>,
39641 ) -> futures::SendRequest<'this, Self, ()> {
39642 let span = tracing::info_span!(
39643 "allow_events",
39644 mode = ?mode,
39645 );
39646 let request = types::xproto::AllowEventsRequest {
39647 mode,
39648 time: Into::<u32>::into(time.into()) as _,
39649 };
39650 let cookie = self.send_void_request(request, true).with_span(span);
39651 cookie
39652 }
39653 fn allow_events_checked<'this>(
39654 &'this mut self,
39655 mode: types::Allow,
39656 time: impl Into<types::Time>,
39657 ) -> futures::CheckedSendRequest<'this, Self, ()> {
39658 let request = types::xproto::AllowEventsRequest {
39659 mode,
39660 time: Into::<u32>::into(time.into()) as _,
39661 };
39662 let cookie = self.send_void_request(request, false);
39663 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
39664 res
39665 }
39666 fn grab_server<'this>(&'this mut self) -> futures::SendRequest<'this, Self, ()> {
39667 let span = tracing::info_span!("grab_server",);
39668 let request = types::xproto::GrabServerRequest {};
39669 let cookie = self.send_void_request(request, true).with_span(span);
39670 cookie
39671 }
39672 fn grab_server_checked<'this>(&'this mut self) -> futures::CheckedSendRequest<'this, Self, ()> {
39673 let request = types::xproto::GrabServerRequest {};
39674 let cookie = self.send_void_request(request, false);
39675 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
39676 res
39677 }
39678 fn ungrab_server<'this>(&'this mut self) -> futures::SendRequest<'this, Self, ()> {
39679 let span = tracing::info_span!("ungrab_server",);
39680 let request = types::xproto::UngrabServerRequest {};
39681 let cookie = self.send_void_request(request, true).with_span(span);
39682 cookie
39683 }
39684 fn ungrab_server_checked<'this>(
39685 &'this mut self,
39686 ) -> futures::CheckedSendRequest<'this, Self, ()> {
39687 let request = types::xproto::UngrabServerRequest {};
39688 let cookie = self.send_void_request(request, false);
39689 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
39690 res
39691 }
39692 fn query_pointer<'this>(
39693 &'this mut self,
39694 window: types::xproto::Window,
39695 ) -> futures::SendRequest<'this, Self, types::xproto::QueryPointerReply> {
39696 let span = tracing::info_span!(
39697 "query_pointer",
39698 window = ?window,
39699 );
39700 let request = types::xproto::QueryPointerRequest { window };
39701 let cookie = self.send_reply_request(request).with_span(span);
39702 cookie
39703 }
39704 fn query_pointer_immediate<'this>(
39705 &'this mut self,
39706 window: types::xproto::Window,
39707 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::QueryPointerReply> {
39708 let request = types::xproto::QueryPointerRequest { window };
39709 let cookie = self.send_reply_request(request);
39710 let res: futures::CheckedSendRequest<'this, Self, types::xproto::QueryPointerReply> =
39711 cookie.into();
39712 res
39713 }
39714 fn get_motion_events<'this>(
39715 &'this mut self,
39716 window: types::xproto::Window,
39717 start: impl Into<types::Time>,
39718 stop: impl Into<types::Time>,
39719 ) -> futures::SendRequest<'this, Self, types::xproto::GetMotionEventsReply> {
39720 let span = tracing::info_span!(
39721 "get_motion_events",
39722 window = ?window,
39723 );
39724 let request = types::xproto::GetMotionEventsRequest {
39725 window,
39726 start: Into::<u32>::into(start.into()) as _,
39727 stop: Into::<u32>::into(stop.into()) as _,
39728 };
39729 let cookie = self.send_reply_request(request).with_span(span);
39730 cookie
39731 }
39732 fn get_motion_events_immediate<'this>(
39733 &'this mut self,
39734 window: types::xproto::Window,
39735 start: impl Into<types::Time>,
39736 stop: impl Into<types::Time>,
39737 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::GetMotionEventsReply> {
39738 let request = types::xproto::GetMotionEventsRequest {
39739 window,
39740 start: Into::<u32>::into(start.into()) as _,
39741 stop: Into::<u32>::into(stop.into()) as _,
39742 };
39743 let cookie = self.send_reply_request(request);
39744 let res: futures::CheckedSendRequest<'this, Self, types::xproto::GetMotionEventsReply> =
39745 cookie.into();
39746 res
39747 }
39748 fn translate_coordinates<'this>(
39749 &'this mut self,
39750 src_window: types::xproto::Window,
39751 dst_window: types::xproto::Window,
39752 src_x: types::Int16,
39753 src_y: types::Int16,
39754 ) -> futures::SendRequest<'this, Self, types::xproto::TranslateCoordinatesReply> {
39755 let span = tracing::info_span!(
39756 "translate_coordinates",
39757 src_window = ?src_window,
39758 dst_window = ?dst_window,
39759 src_x = ?src_x,
39760 src_y = ?src_y,
39761 );
39762 let request = types::xproto::TranslateCoordinatesRequest {
39763 src_window,
39764 dst_window,
39765 src_x,
39766 src_y,
39767 };
39768 let cookie = self.send_reply_request(request).with_span(span);
39769 cookie
39770 }
39771 fn translate_coordinates_immediate<'this>(
39772 &'this mut self,
39773 src_window: types::xproto::Window,
39774 dst_window: types::xproto::Window,
39775 src_x: types::Int16,
39776 src_y: types::Int16,
39777 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::TranslateCoordinatesReply> {
39778 let request = types::xproto::TranslateCoordinatesRequest {
39779 src_window,
39780 dst_window,
39781 src_x,
39782 src_y,
39783 };
39784 let cookie = self.send_reply_request(request);
39785 let res: futures::CheckedSendRequest<
39786 'this,
39787 Self,
39788 types::xproto::TranslateCoordinatesReply,
39789 > = cookie.into();
39790 res
39791 }
39792 fn warp_pointer<'this>(
39793 &'this mut self,
39794 src_window: impl Into<types::xproto::Window>,
39795 dst_window: impl Into<types::xproto::Window>,
39796 src_x: types::Int16,
39797 src_y: types::Int16,
39798 src_width: types::Card16,
39799 src_height: types::Card16,
39800 dst_x: types::Int16,
39801 dst_y: types::Int16,
39802 ) -> futures::SendRequest<'this, Self, ()> {
39803 let span = tracing::info_span!(
39804 "warp_pointer",
39805 src_x = ?src_x,
39806 src_y = ?src_y,
39807 src_width = ?src_width,
39808 src_height = ?src_height,
39809 dst_x = ?dst_x,
39810 dst_y = ?dst_y,
39811 );
39812 let request = types::xproto::WarpPointerRequest {
39813 src_window: Into::<u32>::into(src_window.into()) as _,
39814 dst_window: Into::<u32>::into(dst_window.into()) as _,
39815 src_x,
39816 src_y,
39817 src_width,
39818 src_height,
39819 dst_x,
39820 dst_y,
39821 };
39822 let cookie = self.send_void_request(request, true).with_span(span);
39823 cookie
39824 }
39825 fn warp_pointer_checked<'this>(
39826 &'this mut self,
39827 src_window: impl Into<types::xproto::Window>,
39828 dst_window: impl Into<types::xproto::Window>,
39829 src_x: types::Int16,
39830 src_y: types::Int16,
39831 src_width: types::Card16,
39832 src_height: types::Card16,
39833 dst_x: types::Int16,
39834 dst_y: types::Int16,
39835 ) -> futures::CheckedSendRequest<'this, Self, ()> {
39836 let request = types::xproto::WarpPointerRequest {
39837 src_window: Into::<u32>::into(src_window.into()) as _,
39838 dst_window: Into::<u32>::into(dst_window.into()) as _,
39839 src_x,
39840 src_y,
39841 src_width,
39842 src_height,
39843 dst_x,
39844 dst_y,
39845 };
39846 let cookie = self.send_void_request(request, false);
39847 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
39848 res
39849 }
39850 fn set_input_focus<'this>(
39851 &'this mut self,
39852 revert_to: types::InputFocus,
39853 focus: impl Into<types::InputFocus>,
39854 time: impl Into<types::Time>,
39855 ) -> futures::SendRequest<'this, Self, ()> {
39856 let span = tracing::info_span!(
39857 "set_input_focus",
39858 revert_to = ?revert_to,
39859 );
39860 let request = types::xproto::SetInputFocusRequest {
39861 revert_to,
39862 focus: Into::<u32>::into(focus.into()) as _,
39863 time: Into::<u32>::into(time.into()) as _,
39864 };
39865 let cookie = self.send_void_request(request, true).with_span(span);
39866 cookie
39867 }
39868 fn set_input_focus_checked<'this>(
39869 &'this mut self,
39870 revert_to: types::InputFocus,
39871 focus: impl Into<types::InputFocus>,
39872 time: impl Into<types::Time>,
39873 ) -> futures::CheckedSendRequest<'this, Self, ()> {
39874 let request = types::xproto::SetInputFocusRequest {
39875 revert_to,
39876 focus: Into::<u32>::into(focus.into()) as _,
39877 time: Into::<u32>::into(time.into()) as _,
39878 };
39879 let cookie = self.send_void_request(request, false);
39880 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
39881 res
39882 }
39883 fn get_input_focus<'this>(
39884 &'this mut self,
39885 ) -> futures::SendRequest<'this, Self, types::xproto::GetInputFocusReply> {
39886 let span = tracing::info_span!("get_input_focus",);
39887 let request = types::xproto::GetInputFocusRequest {};
39888 let cookie = self.send_reply_request(request).with_span(span);
39889 cookie
39890 }
39891 fn get_input_focus_immediate<'this>(
39892 &'this mut self,
39893 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::GetInputFocusReply> {
39894 let request = types::xproto::GetInputFocusRequest {};
39895 let cookie = self.send_reply_request(request);
39896 let res: futures::CheckedSendRequest<'this, Self, types::xproto::GetInputFocusReply> =
39897 cookie.into();
39898 res
39899 }
39900 fn query_keymap<'this>(
39901 &'this mut self,
39902 ) -> futures::SendRequest<'this, Self, types::xproto::QueryKeymapReply> {
39903 let span = tracing::info_span!("query_keymap",);
39904 let request = types::xproto::QueryKeymapRequest {};
39905 let cookie = self.send_reply_request(request).with_span(span);
39906 cookie
39907 }
39908 fn query_keymap_immediate<'this>(
39909 &'this mut self,
39910 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::QueryKeymapReply> {
39911 let request = types::xproto::QueryKeymapRequest {};
39912 let cookie = self.send_reply_request(request);
39913 let res: futures::CheckedSendRequest<'this, Self, types::xproto::QueryKeymapReply> =
39914 cookie.into();
39915 res
39916 }
39917 fn open_font<'this>(
39918 &'this mut self,
39919 fid: types::Font,
39920 name: impl AsRef<[types::Char]>,
39921 ) -> futures::SendRequest<'this, Self, ()> {
39922 let span = tracing::info_span!(
39923 "open_font",
39924 fid = ?fid,
39925 );
39926 let request = types::xproto::OpenFontRequest {
39927 fid,
39928 name: Cow::Borrowed(name.as_ref()),
39929 };
39930 let cookie = self.send_void_request(request, true).with_span(span);
39931 cookie
39932 }
39933 fn open_font_checked<'this>(
39934 &'this mut self,
39935 fid: types::Font,
39936 name: impl AsRef<[types::Char]>,
39937 ) -> futures::CheckedSendRequest<'this, Self, ()> {
39938 let request = types::xproto::OpenFontRequest {
39939 fid,
39940 name: Cow::Borrowed(name.as_ref()),
39941 };
39942 let cookie = self.send_void_request(request, false);
39943 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
39944 res
39945 }
39946 fn close_font<'this>(
39947 &'this mut self,
39948 font: types::Font,
39949 ) -> futures::SendRequest<'this, Self, ()> {
39950 let span = tracing::info_span!(
39951 "close_font",
39952 font = ?font,
39953 );
39954 let request = types::xproto::CloseFontRequest { font };
39955 let cookie = self.send_void_request(request, true).with_span(span);
39956 cookie
39957 }
39958 fn close_font_checked<'this>(
39959 &'this mut self,
39960 font: types::Font,
39961 ) -> futures::CheckedSendRequest<'this, Self, ()> {
39962 let request = types::xproto::CloseFontRequest { font };
39963 let cookie = self.send_void_request(request, false);
39964 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
39965 res
39966 }
39967 fn query_font<'this>(
39968 &'this mut self,
39969 font: types::Fontable,
39970 ) -> futures::SendRequest<'this, Self, types::xproto::QueryFontReply> {
39971 let span = tracing::info_span!(
39972 "query_font",
39973 font = ?font,
39974 );
39975 let request = types::xproto::QueryFontRequest { font };
39976 let cookie = self.send_reply_request(request).with_span(span);
39977 cookie
39978 }
39979 fn query_font_immediate<'this>(
39980 &'this mut self,
39981 font: types::Fontable,
39982 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::QueryFontReply> {
39983 let request = types::xproto::QueryFontRequest { font };
39984 let cookie = self.send_reply_request(request);
39985 let res: futures::CheckedSendRequest<'this, Self, types::xproto::QueryFontReply> =
39986 cookie.into();
39987 res
39988 }
39989 fn query_text_extents<'this>(
39990 &'this mut self,
39991 font: types::Fontable,
39992 string: impl AsRef<[types::Char2b]>,
39993 ) -> futures::SendRequest<'this, Self, types::xproto::QueryTextExtentsReply> {
39994 let span = tracing::info_span!(
39995 "query_text_extents",
39996 font = ?font,
39997 );
39998 let request = types::xproto::QueryTextExtentsRequest {
39999 font,
40000 string: Cow::Borrowed(string.as_ref()),
40001 };
40002 let cookie = self.send_reply_request(request).with_span(span);
40003 cookie
40004 }
40005 fn query_text_extents_immediate<'this>(
40006 &'this mut self,
40007 font: types::Fontable,
40008 string: impl AsRef<[types::Char2b]>,
40009 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::QueryTextExtentsReply> {
40010 let request = types::xproto::QueryTextExtentsRequest {
40011 font,
40012 string: Cow::Borrowed(string.as_ref()),
40013 };
40014 let cookie = self.send_reply_request(request);
40015 let res: futures::CheckedSendRequest<'this, Self, types::xproto::QueryTextExtentsReply> =
40016 cookie.into();
40017 res
40018 }
40019 fn list_fonts<'this>(
40020 &'this mut self,
40021 max_names: types::Card16,
40022 pattern: impl AsRef<[types::Char]>,
40023 ) -> futures::SendRequest<'this, Self, types::xproto::ListFontsReply> {
40024 let span = tracing::info_span!(
40025 "list_fonts",
40026 max_names = ?max_names,
40027 );
40028 let request = types::xproto::ListFontsRequest {
40029 max_names,
40030 pattern: Cow::Borrowed(pattern.as_ref()),
40031 };
40032 let cookie = self.send_reply_request(request).with_span(span);
40033 cookie
40034 }
40035 fn list_fonts_immediate<'this>(
40036 &'this mut self,
40037 max_names: types::Card16,
40038 pattern: impl AsRef<[types::Char]>,
40039 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::ListFontsReply> {
40040 let request = types::xproto::ListFontsRequest {
40041 max_names,
40042 pattern: Cow::Borrowed(pattern.as_ref()),
40043 };
40044 let cookie = self.send_reply_request(request);
40045 let res: futures::CheckedSendRequest<'this, Self, types::xproto::ListFontsReply> =
40046 cookie.into();
40047 res
40048 }
40049 fn list_fonts_with_info<'this>(
40050 &'this mut self,
40051 max_names: types::Card16,
40052 pattern: impl AsRef<[types::Char]>,
40053 ) -> futures::SendRequest<'this, Self, types::xproto::ListFontsWithInfoReply> {
40054 let span = tracing::info_span!(
40055 "list_fonts_with_info",
40056 max_names = ?max_names,
40057 );
40058 let request = types::xproto::ListFontsWithInfoRequest {
40059 max_names,
40060 pattern: Cow::Borrowed(pattern.as_ref()),
40061 };
40062 let cookie = self.send_reply_request(request).with_span(span);
40063 cookie
40064 }
40065 fn list_fonts_with_info_immediate<'this>(
40066 &'this mut self,
40067 max_names: types::Card16,
40068 pattern: impl AsRef<[types::Char]>,
40069 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::ListFontsWithInfoReply> {
40070 let request = types::xproto::ListFontsWithInfoRequest {
40071 max_names,
40072 pattern: Cow::Borrowed(pattern.as_ref()),
40073 };
40074 let cookie = self.send_reply_request(request);
40075 let res: futures::CheckedSendRequest<'this, Self, types::xproto::ListFontsWithInfoReply> =
40076 cookie.into();
40077 res
40078 }
40079 fn set_font_path<'this>(
40080 &'this mut self,
40081 font: impl AsRef<[types::Str]>,
40082 ) -> futures::SendRequest<'this, Self, ()> {
40083 let span = tracing::info_span!("set_font_path",);
40084 let request = types::xproto::SetFontPathRequest {
40085 font: Cow::Borrowed(font.as_ref()),
40086 };
40087 let cookie = self.send_void_request(request, true).with_span(span);
40088 cookie
40089 }
40090 fn set_font_path_checked<'this>(
40091 &'this mut self,
40092 font: impl AsRef<[types::Str]>,
40093 ) -> futures::CheckedSendRequest<'this, Self, ()> {
40094 let request = types::xproto::SetFontPathRequest {
40095 font: Cow::Borrowed(font.as_ref()),
40096 };
40097 let cookie = self.send_void_request(request, false);
40098 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
40099 res
40100 }
40101 fn get_font_path<'this>(
40102 &'this mut self,
40103 ) -> futures::SendRequest<'this, Self, types::xproto::GetFontPathReply> {
40104 let span = tracing::info_span!("get_font_path",);
40105 let request = types::xproto::GetFontPathRequest {};
40106 let cookie = self.send_reply_request(request).with_span(span);
40107 cookie
40108 }
40109 fn get_font_path_immediate<'this>(
40110 &'this mut self,
40111 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::GetFontPathReply> {
40112 let request = types::xproto::GetFontPathRequest {};
40113 let cookie = self.send_reply_request(request);
40114 let res: futures::CheckedSendRequest<'this, Self, types::xproto::GetFontPathReply> =
40115 cookie.into();
40116 res
40117 }
40118 fn create_pixmap<'this>(
40119 &'this mut self,
40120 depth: types::Card8,
40121 pid: types::xproto::Pixmap,
40122 drawable: types::xproto::Drawable,
40123 width: types::Card16,
40124 height: types::Card16,
40125 ) -> futures::SendRequest<'this, Self, ()> {
40126 let span = tracing::info_span!(
40127 "create_pixmap",
40128 depth = ?depth,
40129 pid = ?pid,
40130 drawable = ?drawable,
40131 width = ?width,
40132 height = ?height,
40133 );
40134 let request = types::xproto::CreatePixmapRequest {
40135 depth,
40136 pid,
40137 drawable,
40138 width,
40139 height,
40140 };
40141 let cookie = self.send_void_request(request, true).with_span(span);
40142 cookie
40143 }
40144 fn create_pixmap_checked<'this>(
40145 &'this mut self,
40146 depth: types::Card8,
40147 pid: types::xproto::Pixmap,
40148 drawable: types::xproto::Drawable,
40149 width: types::Card16,
40150 height: types::Card16,
40151 ) -> futures::CheckedSendRequest<'this, Self, ()> {
40152 let request = types::xproto::CreatePixmapRequest {
40153 depth,
40154 pid,
40155 drawable,
40156 width,
40157 height,
40158 };
40159 let cookie = self.send_void_request(request, false);
40160 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
40161 res
40162 }
40163 fn free_pixmap<'this>(
40164 &'this mut self,
40165 pixmap: types::xproto::Pixmap,
40166 ) -> futures::SendRequest<'this, Self, ()> {
40167 let span = tracing::info_span!(
40168 "free_pixmap",
40169 pixmap = ?pixmap,
40170 );
40171 let request = types::xproto::FreePixmapRequest { pixmap };
40172 let cookie = self.send_void_request(request, true).with_span(span);
40173 cookie
40174 }
40175 fn free_pixmap_checked<'this>(
40176 &'this mut self,
40177 pixmap: types::xproto::Pixmap,
40178 ) -> futures::CheckedSendRequest<'this, Self, ()> {
40179 let request = types::xproto::FreePixmapRequest { pixmap };
40180 let cookie = self.send_void_request(request, false);
40181 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
40182 res
40183 }
40184 fn create_gc<'this>(
40185 &'this mut self,
40186 cid: types::Gcontext,
40187 drawable: types::xproto::Drawable,
40188 value_list: impl Borrow<types::xproto::CreateGCAux>,
40189 ) -> futures::SendRequest<'this, Self, ()> {
40190 let span = tracing::info_span!(
40191 "create_gc",
40192 cid = ?cid,
40193 drawable = ?drawable,
40194 );
40195 let request = types::xproto::CreateGCRequest {
40196 cid,
40197 drawable,
40198 value_list: Cow::Borrowed(value_list.borrow()),
40199 };
40200 let cookie = self.send_void_request(request, true).with_span(span);
40201 cookie
40202 }
40203 fn create_gc_checked<'this>(
40204 &'this mut self,
40205 cid: types::Gcontext,
40206 drawable: types::xproto::Drawable,
40207 value_list: impl Borrow<types::xproto::CreateGCAux>,
40208 ) -> futures::CheckedSendRequest<'this, Self, ()> {
40209 let request = types::xproto::CreateGCRequest {
40210 cid,
40211 drawable,
40212 value_list: Cow::Borrowed(value_list.borrow()),
40213 };
40214 let cookie = self.send_void_request(request, false);
40215 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
40216 res
40217 }
40218 fn change_gc<'this>(
40219 &'this mut self,
40220 gc: types::Gcontext,
40221 value_list: impl Borrow<types::xproto::ChangeGCAux>,
40222 ) -> futures::SendRequest<'this, Self, ()> {
40223 let span = tracing::info_span!(
40224 "change_gc",
40225 gc = ?gc,
40226 );
40227 let request = types::xproto::ChangeGCRequest {
40228 gc,
40229 value_list: Cow::Borrowed(value_list.borrow()),
40230 };
40231 let cookie = self.send_void_request(request, true).with_span(span);
40232 cookie
40233 }
40234 fn change_gc_checked<'this>(
40235 &'this mut self,
40236 gc: types::Gcontext,
40237 value_list: impl Borrow<types::xproto::ChangeGCAux>,
40238 ) -> futures::CheckedSendRequest<'this, Self, ()> {
40239 let request = types::xproto::ChangeGCRequest {
40240 gc,
40241 value_list: Cow::Borrowed(value_list.borrow()),
40242 };
40243 let cookie = self.send_void_request(request, false);
40244 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
40245 res
40246 }
40247 fn copy_gc<'this>(
40248 &'this mut self,
40249 src_gc: types::Gcontext,
40250 dst_gc: types::Gcontext,
40251 value_mask: impl Into<types::xproto::GC>,
40252 ) -> futures::SendRequest<'this, Self, ()> {
40253 let span = tracing::info_span!(
40254 "copy_gc",
40255 src_gc = ?src_gc,
40256 dst_gc = ?dst_gc,
40257 );
40258 let request = types::xproto::CopyGCRequest {
40259 src_gc,
40260 dst_gc,
40261 value_mask: Into::<u32>::into(value_mask.into()) as _,
40262 };
40263 let cookie = self.send_void_request(request, true).with_span(span);
40264 cookie
40265 }
40266 fn copy_gc_checked<'this>(
40267 &'this mut self,
40268 src_gc: types::Gcontext,
40269 dst_gc: types::Gcontext,
40270 value_mask: impl Into<types::xproto::GC>,
40271 ) -> futures::CheckedSendRequest<'this, Self, ()> {
40272 let request = types::xproto::CopyGCRequest {
40273 src_gc,
40274 dst_gc,
40275 value_mask: Into::<u32>::into(value_mask.into()) as _,
40276 };
40277 let cookie = self.send_void_request(request, false);
40278 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
40279 res
40280 }
40281 fn set_dashes<'this>(
40282 &'this mut self,
40283 gc: types::Gcontext,
40284 dash_offset: types::Card16,
40285 dashes: impl AsRef<[types::Card8]>,
40286 ) -> futures::SendRequest<'this, Self, ()> {
40287 let span = tracing::info_span!(
40288 "set_dashes",
40289 gc = ?gc,
40290 dash_offset = ?dash_offset,
40291 );
40292 let request = types::xproto::SetDashesRequest {
40293 gc,
40294 dash_offset,
40295 dashes: Cow::Borrowed(dashes.as_ref()),
40296 };
40297 let cookie = self.send_void_request(request, true).with_span(span);
40298 cookie
40299 }
40300 fn set_dashes_checked<'this>(
40301 &'this mut self,
40302 gc: types::Gcontext,
40303 dash_offset: types::Card16,
40304 dashes: impl AsRef<[types::Card8]>,
40305 ) -> futures::CheckedSendRequest<'this, Self, ()> {
40306 let request = types::xproto::SetDashesRequest {
40307 gc,
40308 dash_offset,
40309 dashes: Cow::Borrowed(dashes.as_ref()),
40310 };
40311 let cookie = self.send_void_request(request, false);
40312 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
40313 res
40314 }
40315 fn set_clip_rectangles<'this>(
40316 &'this mut self,
40317 ordering: types::ClipOrdering,
40318 gc: types::Gcontext,
40319 clip_x_origin: types::Int16,
40320 clip_y_origin: types::Int16,
40321 rectangles: impl AsRef<[types::Rectangle]>,
40322 ) -> futures::SendRequest<'this, Self, ()> {
40323 let span = tracing::info_span!(
40324 "set_clip_rectangles",
40325 ordering = ?ordering,
40326 gc = ?gc,
40327 clip_x_origin = ?clip_x_origin,
40328 clip_y_origin = ?clip_y_origin,
40329 );
40330 let request = types::xproto::SetClipRectanglesRequest {
40331 ordering,
40332 gc,
40333 clip_x_origin,
40334 clip_y_origin,
40335 rectangles: Cow::Borrowed(rectangles.as_ref()),
40336 };
40337 let cookie = self.send_void_request(request, true).with_span(span);
40338 cookie
40339 }
40340 fn set_clip_rectangles_checked<'this>(
40341 &'this mut self,
40342 ordering: types::ClipOrdering,
40343 gc: types::Gcontext,
40344 clip_x_origin: types::Int16,
40345 clip_y_origin: types::Int16,
40346 rectangles: impl AsRef<[types::Rectangle]>,
40347 ) -> futures::CheckedSendRequest<'this, Self, ()> {
40348 let request = types::xproto::SetClipRectanglesRequest {
40349 ordering,
40350 gc,
40351 clip_x_origin,
40352 clip_y_origin,
40353 rectangles: Cow::Borrowed(rectangles.as_ref()),
40354 };
40355 let cookie = self.send_void_request(request, false);
40356 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
40357 res
40358 }
40359 fn free_gc<'this>(
40360 &'this mut self,
40361 gc: types::Gcontext,
40362 ) -> futures::SendRequest<'this, Self, ()> {
40363 let span = tracing::info_span!(
40364 "free_gc",
40365 gc = ?gc,
40366 );
40367 let request = types::xproto::FreeGCRequest { gc };
40368 let cookie = self.send_void_request(request, true).with_span(span);
40369 cookie
40370 }
40371 fn free_gc_checked<'this>(
40372 &'this mut self,
40373 gc: types::Gcontext,
40374 ) -> futures::CheckedSendRequest<'this, Self, ()> {
40375 let request = types::xproto::FreeGCRequest { gc };
40376 let cookie = self.send_void_request(request, false);
40377 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
40378 res
40379 }
40380 fn clear_area<'this>(
40381 &'this mut self,
40382 exposures: types::Bool,
40383 window: types::xproto::Window,
40384 x: types::Int16,
40385 y: types::Int16,
40386 width: types::Card16,
40387 height: types::Card16,
40388 ) -> futures::SendRequest<'this, Self, ()> {
40389 let span = tracing::info_span!(
40390 "clear_area",
40391 exposures = ?exposures,
40392 window = ?window,
40393 x = ?x,
40394 y = ?y,
40395 width = ?width,
40396 height = ?height,
40397 );
40398 let request = types::xproto::ClearAreaRequest {
40399 exposures,
40400 window,
40401 x,
40402 y,
40403 width,
40404 height,
40405 };
40406 let cookie = self.send_void_request(request, true).with_span(span);
40407 cookie
40408 }
40409 fn clear_area_checked<'this>(
40410 &'this mut self,
40411 exposures: types::Bool,
40412 window: types::xproto::Window,
40413 x: types::Int16,
40414 y: types::Int16,
40415 width: types::Card16,
40416 height: types::Card16,
40417 ) -> futures::CheckedSendRequest<'this, Self, ()> {
40418 let request = types::xproto::ClearAreaRequest {
40419 exposures,
40420 window,
40421 x,
40422 y,
40423 width,
40424 height,
40425 };
40426 let cookie = self.send_void_request(request, false);
40427 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
40428 res
40429 }
40430 fn copy_area<'this>(
40431 &'this mut self,
40432 src_drawable: types::xproto::Drawable,
40433 dst_drawable: types::xproto::Drawable,
40434 gc: types::Gcontext,
40435 src_x: types::Int16,
40436 src_y: types::Int16,
40437 dst_x: types::Int16,
40438 dst_y: types::Int16,
40439 width: types::Card16,
40440 height: types::Card16,
40441 ) -> futures::SendRequest<'this, Self, ()> {
40442 let span = tracing::info_span!(
40443 "copy_area",
40444 src_drawable = ?src_drawable,
40445 dst_drawable = ?dst_drawable,
40446 gc = ?gc,
40447 src_x = ?src_x,
40448 src_y = ?src_y,
40449 dst_x = ?dst_x,
40450 dst_y = ?dst_y,
40451 width = ?width,
40452 height = ?height,
40453 );
40454 let request = types::xproto::CopyAreaRequest {
40455 src_drawable,
40456 dst_drawable,
40457 gc,
40458 src_x,
40459 src_y,
40460 dst_x,
40461 dst_y,
40462 width,
40463 height,
40464 };
40465 let cookie = self.send_void_request(request, true).with_span(span);
40466 cookie
40467 }
40468 fn copy_area_checked<'this>(
40469 &'this mut self,
40470 src_drawable: types::xproto::Drawable,
40471 dst_drawable: types::xproto::Drawable,
40472 gc: types::Gcontext,
40473 src_x: types::Int16,
40474 src_y: types::Int16,
40475 dst_x: types::Int16,
40476 dst_y: types::Int16,
40477 width: types::Card16,
40478 height: types::Card16,
40479 ) -> futures::CheckedSendRequest<'this, Self, ()> {
40480 let request = types::xproto::CopyAreaRequest {
40481 src_drawable,
40482 dst_drawable,
40483 gc,
40484 src_x,
40485 src_y,
40486 dst_x,
40487 dst_y,
40488 width,
40489 height,
40490 };
40491 let cookie = self.send_void_request(request, false);
40492 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
40493 res
40494 }
40495 fn copy_plane<'this>(
40496 &'this mut self,
40497 src_drawable: types::xproto::Drawable,
40498 dst_drawable: types::xproto::Drawable,
40499 gc: types::Gcontext,
40500 src_x: types::Int16,
40501 src_y: types::Int16,
40502 dst_x: types::Int16,
40503 dst_y: types::Int16,
40504 width: types::Card16,
40505 height: types::Card16,
40506 bit_plane: types::Card32,
40507 ) -> futures::SendRequest<'this, Self, ()> {
40508 let span = tracing::info_span!(
40509 "copy_plane",
40510 src_drawable = ?src_drawable,
40511 dst_drawable = ?dst_drawable,
40512 gc = ?gc,
40513 src_x = ?src_x,
40514 src_y = ?src_y,
40515 dst_x = ?dst_x,
40516 dst_y = ?dst_y,
40517 width = ?width,
40518 height = ?height,
40519 bit_plane = ?bit_plane,
40520 );
40521 let request = types::xproto::CopyPlaneRequest {
40522 src_drawable,
40523 dst_drawable,
40524 gc,
40525 src_x,
40526 src_y,
40527 dst_x,
40528 dst_y,
40529 width,
40530 height,
40531 bit_plane,
40532 };
40533 let cookie = self.send_void_request(request, true).with_span(span);
40534 cookie
40535 }
40536 fn copy_plane_checked<'this>(
40537 &'this mut self,
40538 src_drawable: types::xproto::Drawable,
40539 dst_drawable: types::xproto::Drawable,
40540 gc: types::Gcontext,
40541 src_x: types::Int16,
40542 src_y: types::Int16,
40543 dst_x: types::Int16,
40544 dst_y: types::Int16,
40545 width: types::Card16,
40546 height: types::Card16,
40547 bit_plane: types::Card32,
40548 ) -> futures::CheckedSendRequest<'this, Self, ()> {
40549 let request = types::xproto::CopyPlaneRequest {
40550 src_drawable,
40551 dst_drawable,
40552 gc,
40553 src_x,
40554 src_y,
40555 dst_x,
40556 dst_y,
40557 width,
40558 height,
40559 bit_plane,
40560 };
40561 let cookie = self.send_void_request(request, false);
40562 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
40563 res
40564 }
40565 fn poly_point<'this>(
40566 &'this mut self,
40567 coordinate_mode: types::CoordMode,
40568 drawable: types::xproto::Drawable,
40569 gc: types::Gcontext,
40570 points: impl AsRef<[types::Point]>,
40571 ) -> futures::SendRequest<'this, Self, ()> {
40572 let span = tracing::info_span!(
40573 "poly_point",
40574 coordinate_mode = ?coordinate_mode,
40575 drawable = ?drawable,
40576 gc = ?gc,
40577 );
40578 let request = types::xproto::PolyPointRequest {
40579 coordinate_mode,
40580 drawable,
40581 gc,
40582 points: Cow::Borrowed(points.as_ref()),
40583 };
40584 let cookie = self.send_void_request(request, true).with_span(span);
40585 cookie
40586 }
40587 fn poly_point_checked<'this>(
40588 &'this mut self,
40589 coordinate_mode: types::CoordMode,
40590 drawable: types::xproto::Drawable,
40591 gc: types::Gcontext,
40592 points: impl AsRef<[types::Point]>,
40593 ) -> futures::CheckedSendRequest<'this, Self, ()> {
40594 let request = types::xproto::PolyPointRequest {
40595 coordinate_mode,
40596 drawable,
40597 gc,
40598 points: Cow::Borrowed(points.as_ref()),
40599 };
40600 let cookie = self.send_void_request(request, false);
40601 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
40602 res
40603 }
40604 fn poly_line<'this>(
40605 &'this mut self,
40606 coordinate_mode: types::CoordMode,
40607 drawable: types::xproto::Drawable,
40608 gc: types::Gcontext,
40609 points: impl AsRef<[types::Point]>,
40610 ) -> futures::SendRequest<'this, Self, ()> {
40611 let span = tracing::info_span!(
40612 "poly_line",
40613 coordinate_mode = ?coordinate_mode,
40614 drawable = ?drawable,
40615 gc = ?gc,
40616 );
40617 let request = types::xproto::PolyLineRequest {
40618 coordinate_mode,
40619 drawable,
40620 gc,
40621 points: Cow::Borrowed(points.as_ref()),
40622 };
40623 let cookie = self.send_void_request(request, true).with_span(span);
40624 cookie
40625 }
40626 fn poly_line_checked<'this>(
40627 &'this mut self,
40628 coordinate_mode: types::CoordMode,
40629 drawable: types::xproto::Drawable,
40630 gc: types::Gcontext,
40631 points: impl AsRef<[types::Point]>,
40632 ) -> futures::CheckedSendRequest<'this, Self, ()> {
40633 let request = types::xproto::PolyLineRequest {
40634 coordinate_mode,
40635 drawable,
40636 gc,
40637 points: Cow::Borrowed(points.as_ref()),
40638 };
40639 let cookie = self.send_void_request(request, false);
40640 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
40641 res
40642 }
40643 fn poly_segment<'this>(
40644 &'this mut self,
40645 drawable: types::xproto::Drawable,
40646 gc: types::Gcontext,
40647 segments: impl AsRef<[types::Segment]>,
40648 ) -> futures::SendRequest<'this, Self, ()> {
40649 let span = tracing::info_span!(
40650 "poly_segment",
40651 drawable = ?drawable,
40652 gc = ?gc,
40653 );
40654 let request = types::xproto::PolySegmentRequest {
40655 drawable,
40656 gc,
40657 segments: Cow::Borrowed(segments.as_ref()),
40658 };
40659 let cookie = self.send_void_request(request, true).with_span(span);
40660 cookie
40661 }
40662 fn poly_segment_checked<'this>(
40663 &'this mut self,
40664 drawable: types::xproto::Drawable,
40665 gc: types::Gcontext,
40666 segments: impl AsRef<[types::Segment]>,
40667 ) -> futures::CheckedSendRequest<'this, Self, ()> {
40668 let request = types::xproto::PolySegmentRequest {
40669 drawable,
40670 gc,
40671 segments: Cow::Borrowed(segments.as_ref()),
40672 };
40673 let cookie = self.send_void_request(request, false);
40674 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
40675 res
40676 }
40677 fn poly_rectangle<'this>(
40678 &'this mut self,
40679 drawable: types::xproto::Drawable,
40680 gc: types::Gcontext,
40681 rectangles: impl AsRef<[types::Rectangle]>,
40682 ) -> futures::SendRequest<'this, Self, ()> {
40683 let span = tracing::info_span!(
40684 "poly_rectangle",
40685 drawable = ?drawable,
40686 gc = ?gc,
40687 );
40688 let request = types::xproto::PolyRectangleRequest {
40689 drawable,
40690 gc,
40691 rectangles: Cow::Borrowed(rectangles.as_ref()),
40692 };
40693 let cookie = self.send_void_request(request, true).with_span(span);
40694 cookie
40695 }
40696 fn poly_rectangle_checked<'this>(
40697 &'this mut self,
40698 drawable: types::xproto::Drawable,
40699 gc: types::Gcontext,
40700 rectangles: impl AsRef<[types::Rectangle]>,
40701 ) -> futures::CheckedSendRequest<'this, Self, ()> {
40702 let request = types::xproto::PolyRectangleRequest {
40703 drawable,
40704 gc,
40705 rectangles: Cow::Borrowed(rectangles.as_ref()),
40706 };
40707 let cookie = self.send_void_request(request, false);
40708 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
40709 res
40710 }
40711 fn poly_arc<'this>(
40712 &'this mut self,
40713 drawable: types::xproto::Drawable,
40714 gc: types::Gcontext,
40715 arcs: impl AsRef<[types::Arc]>,
40716 ) -> futures::SendRequest<'this, Self, ()> {
40717 let span = tracing::info_span!(
40718 "poly_arc",
40719 drawable = ?drawable,
40720 gc = ?gc,
40721 );
40722 let request = types::xproto::PolyArcRequest {
40723 drawable,
40724 gc,
40725 arcs: Cow::Borrowed(arcs.as_ref()),
40726 };
40727 let cookie = self.send_void_request(request, true).with_span(span);
40728 cookie
40729 }
40730 fn poly_arc_checked<'this>(
40731 &'this mut self,
40732 drawable: types::xproto::Drawable,
40733 gc: types::Gcontext,
40734 arcs: impl AsRef<[types::Arc]>,
40735 ) -> futures::CheckedSendRequest<'this, Self, ()> {
40736 let request = types::xproto::PolyArcRequest {
40737 drawable,
40738 gc,
40739 arcs: Cow::Borrowed(arcs.as_ref()),
40740 };
40741 let cookie = self.send_void_request(request, false);
40742 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
40743 res
40744 }
40745 fn fill_poly<'this>(
40746 &'this mut self,
40747 drawable: types::xproto::Drawable,
40748 gc: types::Gcontext,
40749 shape: types::PolyShape,
40750 coordinate_mode: types::CoordMode,
40751 points: impl AsRef<[types::Point]>,
40752 ) -> futures::SendRequest<'this, Self, ()> {
40753 let span = tracing::info_span!(
40754 "fill_poly",
40755 drawable = ?drawable,
40756 gc = ?gc,
40757 shape = ?shape,
40758 coordinate_mode = ?coordinate_mode,
40759 );
40760 let request = types::xproto::FillPolyRequest {
40761 drawable,
40762 gc,
40763 shape,
40764 coordinate_mode,
40765 points: Cow::Borrowed(points.as_ref()),
40766 };
40767 let cookie = self.send_void_request(request, true).with_span(span);
40768 cookie
40769 }
40770 fn fill_poly_checked<'this>(
40771 &'this mut self,
40772 drawable: types::xproto::Drawable,
40773 gc: types::Gcontext,
40774 shape: types::PolyShape,
40775 coordinate_mode: types::CoordMode,
40776 points: impl AsRef<[types::Point]>,
40777 ) -> futures::CheckedSendRequest<'this, Self, ()> {
40778 let request = types::xproto::FillPolyRequest {
40779 drawable,
40780 gc,
40781 shape,
40782 coordinate_mode,
40783 points: Cow::Borrowed(points.as_ref()),
40784 };
40785 let cookie = self.send_void_request(request, false);
40786 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
40787 res
40788 }
40789 fn poly_fill_rectangle<'this>(
40790 &'this mut self,
40791 drawable: types::xproto::Drawable,
40792 gc: types::Gcontext,
40793 rectangles: impl AsRef<[types::Rectangle]>,
40794 ) -> futures::SendRequest<'this, Self, ()> {
40795 let span = tracing::info_span!(
40796 "poly_fill_rectangle",
40797 drawable = ?drawable,
40798 gc = ?gc,
40799 );
40800 let request = types::xproto::PolyFillRectangleRequest {
40801 drawable,
40802 gc,
40803 rectangles: Cow::Borrowed(rectangles.as_ref()),
40804 };
40805 let cookie = self.send_void_request(request, true).with_span(span);
40806 cookie
40807 }
40808 fn poly_fill_rectangle_checked<'this>(
40809 &'this mut self,
40810 drawable: types::xproto::Drawable,
40811 gc: types::Gcontext,
40812 rectangles: impl AsRef<[types::Rectangle]>,
40813 ) -> futures::CheckedSendRequest<'this, Self, ()> {
40814 let request = types::xproto::PolyFillRectangleRequest {
40815 drawable,
40816 gc,
40817 rectangles: Cow::Borrowed(rectangles.as_ref()),
40818 };
40819 let cookie = self.send_void_request(request, false);
40820 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
40821 res
40822 }
40823 fn poly_fill_arc<'this>(
40824 &'this mut self,
40825 drawable: types::xproto::Drawable,
40826 gc: types::Gcontext,
40827 arcs: impl AsRef<[types::Arc]>,
40828 ) -> futures::SendRequest<'this, Self, ()> {
40829 let span = tracing::info_span!(
40830 "poly_fill_arc",
40831 drawable = ?drawable,
40832 gc = ?gc,
40833 );
40834 let request = types::xproto::PolyFillArcRequest {
40835 drawable,
40836 gc,
40837 arcs: Cow::Borrowed(arcs.as_ref()),
40838 };
40839 let cookie = self.send_void_request(request, true).with_span(span);
40840 cookie
40841 }
40842 fn poly_fill_arc_checked<'this>(
40843 &'this mut self,
40844 drawable: types::xproto::Drawable,
40845 gc: types::Gcontext,
40846 arcs: impl AsRef<[types::Arc]>,
40847 ) -> futures::CheckedSendRequest<'this, Self, ()> {
40848 let request = types::xproto::PolyFillArcRequest {
40849 drawable,
40850 gc,
40851 arcs: Cow::Borrowed(arcs.as_ref()),
40852 };
40853 let cookie = self.send_void_request(request, false);
40854 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
40855 res
40856 }
40857 fn put_image<'this>(
40858 &'this mut self,
40859 format: types::ImageFormat,
40860 drawable: types::xproto::Drawable,
40861 gc: types::Gcontext,
40862 width: types::Card16,
40863 height: types::Card16,
40864 dst_x: types::Int16,
40865 dst_y: types::Int16,
40866 left_pad: types::Card8,
40867 depth: types::Card8,
40868 data: impl AsRef<[types::Byte]>,
40869 ) -> futures::SendRequest<'this, Self, ()> {
40870 let span = tracing::info_span!(
40871 "put_image",
40872 format = ?format,
40873 drawable = ?drawable,
40874 gc = ?gc,
40875 width = ?width,
40876 height = ?height,
40877 dst_x = ?dst_x,
40878 dst_y = ?dst_y,
40879 left_pad = ?left_pad,
40880 depth = ?depth,
40881 );
40882 let request = types::xproto::PutImageRequest {
40883 format,
40884 drawable,
40885 gc,
40886 width,
40887 height,
40888 dst_x,
40889 dst_y,
40890 left_pad,
40891 depth,
40892 data: Cow::Borrowed(data.as_ref()),
40893 };
40894 let cookie = self.send_void_request(request, true).with_span(span);
40895 cookie
40896 }
40897 fn put_image_checked<'this>(
40898 &'this mut self,
40899 format: types::ImageFormat,
40900 drawable: types::xproto::Drawable,
40901 gc: types::Gcontext,
40902 width: types::Card16,
40903 height: types::Card16,
40904 dst_x: types::Int16,
40905 dst_y: types::Int16,
40906 left_pad: types::Card8,
40907 depth: types::Card8,
40908 data: impl AsRef<[types::Byte]>,
40909 ) -> futures::CheckedSendRequest<'this, Self, ()> {
40910 let request = types::xproto::PutImageRequest {
40911 format,
40912 drawable,
40913 gc,
40914 width,
40915 height,
40916 dst_x,
40917 dst_y,
40918 left_pad,
40919 depth,
40920 data: Cow::Borrowed(data.as_ref()),
40921 };
40922 let cookie = self.send_void_request(request, false);
40923 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
40924 res
40925 }
40926 fn get_image<'this>(
40927 &'this mut self,
40928 format: types::ImageFormat,
40929 drawable: types::xproto::Drawable,
40930 x: types::Int16,
40931 y: types::Int16,
40932 width: types::Card16,
40933 height: types::Card16,
40934 plane_mask: types::Card32,
40935 ) -> futures::SendRequest<'this, Self, types::xproto::GetImageReply> {
40936 let span = tracing::info_span!(
40937 "get_image",
40938 format = ?format,
40939 drawable = ?drawable,
40940 x = ?x,
40941 y = ?y,
40942 width = ?width,
40943 height = ?height,
40944 plane_mask = ?plane_mask,
40945 );
40946 let request = types::xproto::GetImageRequest {
40947 format,
40948 drawable,
40949 x,
40950 y,
40951 width,
40952 height,
40953 plane_mask,
40954 };
40955 let cookie = self.send_reply_request(request).with_span(span);
40956 cookie
40957 }
40958 fn get_image_immediate<'this>(
40959 &'this mut self,
40960 format: types::ImageFormat,
40961 drawable: types::xproto::Drawable,
40962 x: types::Int16,
40963 y: types::Int16,
40964 width: types::Card16,
40965 height: types::Card16,
40966 plane_mask: types::Card32,
40967 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::GetImageReply> {
40968 let request = types::xproto::GetImageRequest {
40969 format,
40970 drawable,
40971 x,
40972 y,
40973 width,
40974 height,
40975 plane_mask,
40976 };
40977 let cookie = self.send_reply_request(request);
40978 let res: futures::CheckedSendRequest<'this, Self, types::xproto::GetImageReply> =
40979 cookie.into();
40980 res
40981 }
40982 fn poly_text8<'this>(
40983 &'this mut self,
40984 drawable: types::xproto::Drawable,
40985 gc: types::Gcontext,
40986 x: types::Int16,
40987 y: types::Int16,
40988 items: impl AsRef<[types::Byte]>,
40989 ) -> futures::SendRequest<'this, Self, ()> {
40990 let span = tracing::info_span!(
40991 "poly_text8",
40992 drawable = ?drawable,
40993 gc = ?gc,
40994 x = ?x,
40995 y = ?y,
40996 );
40997 let request = types::xproto::PolyText8Request {
40998 drawable,
40999 gc,
41000 x,
41001 y,
41002 items: Cow::Borrowed(items.as_ref()),
41003 };
41004 let cookie = self.send_void_request(request, true).with_span(span);
41005 cookie
41006 }
41007 fn poly_text8_checked<'this>(
41008 &'this mut self,
41009 drawable: types::xproto::Drawable,
41010 gc: types::Gcontext,
41011 x: types::Int16,
41012 y: types::Int16,
41013 items: impl AsRef<[types::Byte]>,
41014 ) -> futures::CheckedSendRequest<'this, Self, ()> {
41015 let request = types::xproto::PolyText8Request {
41016 drawable,
41017 gc,
41018 x,
41019 y,
41020 items: Cow::Borrowed(items.as_ref()),
41021 };
41022 let cookie = self.send_void_request(request, false);
41023 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
41024 res
41025 }
41026 fn poly_text16<'this>(
41027 &'this mut self,
41028 drawable: types::xproto::Drawable,
41029 gc: types::Gcontext,
41030 x: types::Int16,
41031 y: types::Int16,
41032 items: impl AsRef<[types::Byte]>,
41033 ) -> futures::SendRequest<'this, Self, ()> {
41034 let span = tracing::info_span!(
41035 "poly_text16",
41036 drawable = ?drawable,
41037 gc = ?gc,
41038 x = ?x,
41039 y = ?y,
41040 );
41041 let request = types::xproto::PolyText16Request {
41042 drawable,
41043 gc,
41044 x,
41045 y,
41046 items: Cow::Borrowed(items.as_ref()),
41047 };
41048 let cookie = self.send_void_request(request, true).with_span(span);
41049 cookie
41050 }
41051 fn poly_text16_checked<'this>(
41052 &'this mut self,
41053 drawable: types::xproto::Drawable,
41054 gc: types::Gcontext,
41055 x: types::Int16,
41056 y: types::Int16,
41057 items: impl AsRef<[types::Byte]>,
41058 ) -> futures::CheckedSendRequest<'this, Self, ()> {
41059 let request = types::xproto::PolyText16Request {
41060 drawable,
41061 gc,
41062 x,
41063 y,
41064 items: Cow::Borrowed(items.as_ref()),
41065 };
41066 let cookie = self.send_void_request(request, false);
41067 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
41068 res
41069 }
41070 fn image_text8<'this>(
41071 &'this mut self,
41072 drawable: types::xproto::Drawable,
41073 gc: types::Gcontext,
41074 x: types::Int16,
41075 y: types::Int16,
41076 string: impl AsRef<[types::Char]>,
41077 ) -> futures::SendRequest<'this, Self, ()> {
41078 let span = tracing::info_span!(
41079 "image_text8",
41080 drawable = ?drawable,
41081 gc = ?gc,
41082 x = ?x,
41083 y = ?y,
41084 );
41085 let request = types::xproto::ImageText8Request {
41086 drawable,
41087 gc,
41088 x,
41089 y,
41090 string: Cow::Borrowed(string.as_ref()),
41091 };
41092 let cookie = self.send_void_request(request, true).with_span(span);
41093 cookie
41094 }
41095 fn image_text8_checked<'this>(
41096 &'this mut self,
41097 drawable: types::xproto::Drawable,
41098 gc: types::Gcontext,
41099 x: types::Int16,
41100 y: types::Int16,
41101 string: impl AsRef<[types::Char]>,
41102 ) -> futures::CheckedSendRequest<'this, Self, ()> {
41103 let request = types::xproto::ImageText8Request {
41104 drawable,
41105 gc,
41106 x,
41107 y,
41108 string: Cow::Borrowed(string.as_ref()),
41109 };
41110 let cookie = self.send_void_request(request, false);
41111 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
41112 res
41113 }
41114 fn image_text16<'this>(
41115 &'this mut self,
41116 drawable: types::xproto::Drawable,
41117 gc: types::Gcontext,
41118 x: types::Int16,
41119 y: types::Int16,
41120 string: impl AsRef<[types::Char2b]>,
41121 ) -> futures::SendRequest<'this, Self, ()> {
41122 let span = tracing::info_span!(
41123 "image_text16",
41124 drawable = ?drawable,
41125 gc = ?gc,
41126 x = ?x,
41127 y = ?y,
41128 );
41129 let request = types::xproto::ImageText16Request {
41130 drawable,
41131 gc,
41132 x,
41133 y,
41134 string: Cow::Borrowed(string.as_ref()),
41135 };
41136 let cookie = self.send_void_request(request, true).with_span(span);
41137 cookie
41138 }
41139 fn image_text16_checked<'this>(
41140 &'this mut self,
41141 drawable: types::xproto::Drawable,
41142 gc: types::Gcontext,
41143 x: types::Int16,
41144 y: types::Int16,
41145 string: impl AsRef<[types::Char2b]>,
41146 ) -> futures::CheckedSendRequest<'this, Self, ()> {
41147 let request = types::xproto::ImageText16Request {
41148 drawable,
41149 gc,
41150 x,
41151 y,
41152 string: Cow::Borrowed(string.as_ref()),
41153 };
41154 let cookie = self.send_void_request(request, false);
41155 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
41156 res
41157 }
41158 fn create_colormap<'this>(
41159 &'this mut self,
41160 alloc: types::ColormapAlloc,
41161 mid: types::Colormap,
41162 window: types::xproto::Window,
41163 visual: types::Visualid,
41164 ) -> futures::SendRequest<'this, Self, ()> {
41165 let span = tracing::info_span!(
41166 "create_colormap",
41167 alloc = ?alloc,
41168 mid = ?mid,
41169 window = ?window,
41170 visual = ?visual,
41171 );
41172 let request = types::xproto::CreateColormapRequest {
41173 alloc,
41174 mid,
41175 window,
41176 visual,
41177 };
41178 let cookie = self.send_void_request(request, true).with_span(span);
41179 cookie
41180 }
41181 fn create_colormap_checked<'this>(
41182 &'this mut self,
41183 alloc: types::ColormapAlloc,
41184 mid: types::Colormap,
41185 window: types::xproto::Window,
41186 visual: types::Visualid,
41187 ) -> futures::CheckedSendRequest<'this, Self, ()> {
41188 let request = types::xproto::CreateColormapRequest {
41189 alloc,
41190 mid,
41191 window,
41192 visual,
41193 };
41194 let cookie = self.send_void_request(request, false);
41195 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
41196 res
41197 }
41198 fn free_colormap<'this>(
41199 &'this mut self,
41200 cmap: types::Colormap,
41201 ) -> futures::SendRequest<'this, Self, ()> {
41202 let span = tracing::info_span!(
41203 "free_colormap",
41204 cmap = ?cmap,
41205 );
41206 let request = types::xproto::FreeColormapRequest { cmap };
41207 let cookie = self.send_void_request(request, true).with_span(span);
41208 cookie
41209 }
41210 fn free_colormap_checked<'this>(
41211 &'this mut self,
41212 cmap: types::Colormap,
41213 ) -> futures::CheckedSendRequest<'this, Self, ()> {
41214 let request = types::xproto::FreeColormapRequest { cmap };
41215 let cookie = self.send_void_request(request, false);
41216 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
41217 res
41218 }
41219 fn copy_colormap_and_free<'this>(
41220 &'this mut self,
41221 mid: types::Colormap,
41222 src_cmap: types::Colormap,
41223 ) -> futures::SendRequest<'this, Self, ()> {
41224 let span = tracing::info_span!(
41225 "copy_colormap_and_free",
41226 mid = ?mid,
41227 src_cmap = ?src_cmap,
41228 );
41229 let request = types::xproto::CopyColormapAndFreeRequest { mid, src_cmap };
41230 let cookie = self.send_void_request(request, true).with_span(span);
41231 cookie
41232 }
41233 fn copy_colormap_and_free_checked<'this>(
41234 &'this mut self,
41235 mid: types::Colormap,
41236 src_cmap: types::Colormap,
41237 ) -> futures::CheckedSendRequest<'this, Self, ()> {
41238 let request = types::xproto::CopyColormapAndFreeRequest { mid, src_cmap };
41239 let cookie = self.send_void_request(request, false);
41240 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
41241 res
41242 }
41243 fn install_colormap<'this>(
41244 &'this mut self,
41245 cmap: types::Colormap,
41246 ) -> futures::SendRequest<'this, Self, ()> {
41247 let span = tracing::info_span!(
41248 "install_colormap",
41249 cmap = ?cmap,
41250 );
41251 let request = types::xproto::InstallColormapRequest { cmap };
41252 let cookie = self.send_void_request(request, true).with_span(span);
41253 cookie
41254 }
41255 fn install_colormap_checked<'this>(
41256 &'this mut self,
41257 cmap: types::Colormap,
41258 ) -> futures::CheckedSendRequest<'this, Self, ()> {
41259 let request = types::xproto::InstallColormapRequest { cmap };
41260 let cookie = self.send_void_request(request, false);
41261 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
41262 res
41263 }
41264 fn uninstall_colormap<'this>(
41265 &'this mut self,
41266 cmap: types::Colormap,
41267 ) -> futures::SendRequest<'this, Self, ()> {
41268 let span = tracing::info_span!(
41269 "uninstall_colormap",
41270 cmap = ?cmap,
41271 );
41272 let request = types::xproto::UninstallColormapRequest { cmap };
41273 let cookie = self.send_void_request(request, true).with_span(span);
41274 cookie
41275 }
41276 fn uninstall_colormap_checked<'this>(
41277 &'this mut self,
41278 cmap: types::Colormap,
41279 ) -> futures::CheckedSendRequest<'this, Self, ()> {
41280 let request = types::xproto::UninstallColormapRequest { cmap };
41281 let cookie = self.send_void_request(request, false);
41282 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
41283 res
41284 }
41285 fn list_installed_colormaps<'this>(
41286 &'this mut self,
41287 window: types::xproto::Window,
41288 ) -> futures::SendRequest<'this, Self, types::xproto::ListInstalledColormapsReply> {
41289 let span = tracing::info_span!(
41290 "list_installed_colormaps",
41291 window = ?window,
41292 );
41293 let request = types::xproto::ListInstalledColormapsRequest { window };
41294 let cookie = self.send_reply_request(request).with_span(span);
41295 cookie
41296 }
41297 fn list_installed_colormaps_immediate<'this>(
41298 &'this mut self,
41299 window: types::xproto::Window,
41300 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::ListInstalledColormapsReply> {
41301 let request = types::xproto::ListInstalledColormapsRequest { window };
41302 let cookie = self.send_reply_request(request);
41303 let res: futures::CheckedSendRequest<
41304 'this,
41305 Self,
41306 types::xproto::ListInstalledColormapsReply,
41307 > = cookie.into();
41308 res
41309 }
41310 fn alloc_color<'this>(
41311 &'this mut self,
41312 cmap: types::Colormap,
41313 red: types::Card16,
41314 green: types::Card16,
41315 blue: types::Card16,
41316 ) -> futures::SendRequest<'this, Self, types::xproto::AllocColorReply> {
41317 let span = tracing::info_span!(
41318 "alloc_color",
41319 cmap = ?cmap,
41320 red = ?red,
41321 green = ?green,
41322 blue = ?blue,
41323 );
41324 let request = types::xproto::AllocColorRequest {
41325 cmap,
41326 red,
41327 green,
41328 blue,
41329 };
41330 let cookie = self.send_reply_request(request).with_span(span);
41331 cookie
41332 }
41333 fn alloc_color_immediate<'this>(
41334 &'this mut self,
41335 cmap: types::Colormap,
41336 red: types::Card16,
41337 green: types::Card16,
41338 blue: types::Card16,
41339 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::AllocColorReply> {
41340 let request = types::xproto::AllocColorRequest {
41341 cmap,
41342 red,
41343 green,
41344 blue,
41345 };
41346 let cookie = self.send_reply_request(request);
41347 let res: futures::CheckedSendRequest<'this, Self, types::xproto::AllocColorReply> =
41348 cookie.into();
41349 res
41350 }
41351 fn alloc_named_color<'this>(
41352 &'this mut self,
41353 cmap: types::Colormap,
41354 name: impl AsRef<[types::Char]>,
41355 ) -> futures::SendRequest<'this, Self, types::xproto::AllocNamedColorReply> {
41356 let span = tracing::info_span!(
41357 "alloc_named_color",
41358 cmap = ?cmap,
41359 );
41360 let request = types::xproto::AllocNamedColorRequest {
41361 cmap,
41362 name: Cow::Borrowed(name.as_ref()),
41363 };
41364 let cookie = self.send_reply_request(request).with_span(span);
41365 cookie
41366 }
41367 fn alloc_named_color_immediate<'this>(
41368 &'this mut self,
41369 cmap: types::Colormap,
41370 name: impl AsRef<[types::Char]>,
41371 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::AllocNamedColorReply> {
41372 let request = types::xproto::AllocNamedColorRequest {
41373 cmap,
41374 name: Cow::Borrowed(name.as_ref()),
41375 };
41376 let cookie = self.send_reply_request(request);
41377 let res: futures::CheckedSendRequest<'this, Self, types::xproto::AllocNamedColorReply> =
41378 cookie.into();
41379 res
41380 }
41381 fn alloc_color_cells<'this>(
41382 &'this mut self,
41383 contiguous: types::Bool,
41384 cmap: types::Colormap,
41385 colors: types::Card16,
41386 planes: types::Card16,
41387 ) -> futures::SendRequest<'this, Self, types::xproto::AllocColorCellsReply> {
41388 let span = tracing::info_span!(
41389 "alloc_color_cells",
41390 contiguous = ?contiguous,
41391 cmap = ?cmap,
41392 colors = ?colors,
41393 planes = ?planes,
41394 );
41395 let request = types::xproto::AllocColorCellsRequest {
41396 contiguous,
41397 cmap,
41398 colors,
41399 planes,
41400 };
41401 let cookie = self.send_reply_request(request).with_span(span);
41402 cookie
41403 }
41404 fn alloc_color_cells_immediate<'this>(
41405 &'this mut self,
41406 contiguous: types::Bool,
41407 cmap: types::Colormap,
41408 colors: types::Card16,
41409 planes: types::Card16,
41410 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::AllocColorCellsReply> {
41411 let request = types::xproto::AllocColorCellsRequest {
41412 contiguous,
41413 cmap,
41414 colors,
41415 planes,
41416 };
41417 let cookie = self.send_reply_request(request);
41418 let res: futures::CheckedSendRequest<'this, Self, types::xproto::AllocColorCellsReply> =
41419 cookie.into();
41420 res
41421 }
41422 fn alloc_color_planes<'this>(
41423 &'this mut self,
41424 contiguous: types::Bool,
41425 cmap: types::Colormap,
41426 colors: types::Card16,
41427 reds: types::Card16,
41428 greens: types::Card16,
41429 blues: types::Card16,
41430 ) -> futures::SendRequest<'this, Self, types::xproto::AllocColorPlanesReply> {
41431 let span = tracing::info_span!(
41432 "alloc_color_planes",
41433 contiguous = ?contiguous,
41434 cmap = ?cmap,
41435 colors = ?colors,
41436 reds = ?reds,
41437 greens = ?greens,
41438 blues = ?blues,
41439 );
41440 let request = types::xproto::AllocColorPlanesRequest {
41441 contiguous,
41442 cmap,
41443 colors,
41444 reds,
41445 greens,
41446 blues,
41447 };
41448 let cookie = self.send_reply_request(request).with_span(span);
41449 cookie
41450 }
41451 fn alloc_color_planes_immediate<'this>(
41452 &'this mut self,
41453 contiguous: types::Bool,
41454 cmap: types::Colormap,
41455 colors: types::Card16,
41456 reds: types::Card16,
41457 greens: types::Card16,
41458 blues: types::Card16,
41459 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::AllocColorPlanesReply> {
41460 let request = types::xproto::AllocColorPlanesRequest {
41461 contiguous,
41462 cmap,
41463 colors,
41464 reds,
41465 greens,
41466 blues,
41467 };
41468 let cookie = self.send_reply_request(request);
41469 let res: futures::CheckedSendRequest<'this, Self, types::xproto::AllocColorPlanesReply> =
41470 cookie.into();
41471 res
41472 }
41473 fn free_colors<'this>(
41474 &'this mut self,
41475 cmap: types::Colormap,
41476 plane_mask: types::Card32,
41477 pixels: impl AsRef<[types::Card32]>,
41478 ) -> futures::SendRequest<'this, Self, ()> {
41479 let span = tracing::info_span!(
41480 "free_colors",
41481 cmap = ?cmap,
41482 plane_mask = ?plane_mask,
41483 );
41484 let request = types::xproto::FreeColorsRequest {
41485 cmap,
41486 plane_mask,
41487 pixels: Cow::Borrowed(pixels.as_ref()),
41488 };
41489 let cookie = self.send_void_request(request, true).with_span(span);
41490 cookie
41491 }
41492 fn free_colors_checked<'this>(
41493 &'this mut self,
41494 cmap: types::Colormap,
41495 plane_mask: types::Card32,
41496 pixels: impl AsRef<[types::Card32]>,
41497 ) -> futures::CheckedSendRequest<'this, Self, ()> {
41498 let request = types::xproto::FreeColorsRequest {
41499 cmap,
41500 plane_mask,
41501 pixels: Cow::Borrowed(pixels.as_ref()),
41502 };
41503 let cookie = self.send_void_request(request, false);
41504 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
41505 res
41506 }
41507 fn store_colors<'this>(
41508 &'this mut self,
41509 cmap: types::Colormap,
41510 items: impl AsRef<[types::Coloritem]>,
41511 ) -> futures::SendRequest<'this, Self, ()> {
41512 let span = tracing::info_span!(
41513 "store_colors",
41514 cmap = ?cmap,
41515 );
41516 let request = types::xproto::StoreColorsRequest {
41517 cmap,
41518 items: Cow::Borrowed(items.as_ref()),
41519 };
41520 let cookie = self.send_void_request(request, true).with_span(span);
41521 cookie
41522 }
41523 fn store_colors_checked<'this>(
41524 &'this mut self,
41525 cmap: types::Colormap,
41526 items: impl AsRef<[types::Coloritem]>,
41527 ) -> futures::CheckedSendRequest<'this, Self, ()> {
41528 let request = types::xproto::StoreColorsRequest {
41529 cmap,
41530 items: Cow::Borrowed(items.as_ref()),
41531 };
41532 let cookie = self.send_void_request(request, false);
41533 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
41534 res
41535 }
41536 fn store_named_color<'this>(
41537 &'this mut self,
41538 flags: impl Into<types::ColorFlag>,
41539 cmap: types::Colormap,
41540 pixel: types::Card32,
41541 name: impl AsRef<[types::Char]>,
41542 ) -> futures::SendRequest<'this, Self, ()> {
41543 let span = tracing::info_span!(
41544 "store_named_color",
41545 cmap = ?cmap,
41546 pixel = ?pixel,
41547 );
41548 let request = types::xproto::StoreNamedColorRequest {
41549 flags: Into::<u32>::into(flags.into()) as _,
41550 cmap,
41551 pixel,
41552 name: Cow::Borrowed(name.as_ref()),
41553 };
41554 let cookie = self.send_void_request(request, true).with_span(span);
41555 cookie
41556 }
41557 fn store_named_color_checked<'this>(
41558 &'this mut self,
41559 flags: impl Into<types::ColorFlag>,
41560 cmap: types::Colormap,
41561 pixel: types::Card32,
41562 name: impl AsRef<[types::Char]>,
41563 ) -> futures::CheckedSendRequest<'this, Self, ()> {
41564 let request = types::xproto::StoreNamedColorRequest {
41565 flags: Into::<u32>::into(flags.into()) as _,
41566 cmap,
41567 pixel,
41568 name: Cow::Borrowed(name.as_ref()),
41569 };
41570 let cookie = self.send_void_request(request, false);
41571 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
41572 res
41573 }
41574 fn query_colors<'this>(
41575 &'this mut self,
41576 cmap: types::Colormap,
41577 pixels: impl AsRef<[types::Card32]>,
41578 ) -> futures::SendRequest<'this, Self, types::xproto::QueryColorsReply> {
41579 let span = tracing::info_span!(
41580 "query_colors",
41581 cmap = ?cmap,
41582 );
41583 let request = types::xproto::QueryColorsRequest {
41584 cmap,
41585 pixels: Cow::Borrowed(pixels.as_ref()),
41586 };
41587 let cookie = self.send_reply_request(request).with_span(span);
41588 cookie
41589 }
41590 fn query_colors_immediate<'this>(
41591 &'this mut self,
41592 cmap: types::Colormap,
41593 pixels: impl AsRef<[types::Card32]>,
41594 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::QueryColorsReply> {
41595 let request = types::xproto::QueryColorsRequest {
41596 cmap,
41597 pixels: Cow::Borrowed(pixels.as_ref()),
41598 };
41599 let cookie = self.send_reply_request(request);
41600 let res: futures::CheckedSendRequest<'this, Self, types::xproto::QueryColorsReply> =
41601 cookie.into();
41602 res
41603 }
41604 fn lookup_color<'this>(
41605 &'this mut self,
41606 cmap: types::Colormap,
41607 name: impl AsRef<[types::Char]>,
41608 ) -> futures::SendRequest<'this, Self, types::xproto::LookupColorReply> {
41609 let span = tracing::info_span!(
41610 "lookup_color",
41611 cmap = ?cmap,
41612 );
41613 let request = types::xproto::LookupColorRequest {
41614 cmap,
41615 name: Cow::Borrowed(name.as_ref()),
41616 };
41617 let cookie = self.send_reply_request(request).with_span(span);
41618 cookie
41619 }
41620 fn lookup_color_immediate<'this>(
41621 &'this mut self,
41622 cmap: types::Colormap,
41623 name: impl AsRef<[types::Char]>,
41624 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::LookupColorReply> {
41625 let request = types::xproto::LookupColorRequest {
41626 cmap,
41627 name: Cow::Borrowed(name.as_ref()),
41628 };
41629 let cookie = self.send_reply_request(request);
41630 let res: futures::CheckedSendRequest<'this, Self, types::xproto::LookupColorReply> =
41631 cookie.into();
41632 res
41633 }
41634 fn create_cursor<'this>(
41635 &'this mut self,
41636 cid: types::xproto::Cursor,
41637 source: types::xproto::Pixmap,
41638 mask: impl Into<types::xproto::Pixmap>,
41639 fore_red: types::Card16,
41640 fore_green: types::Card16,
41641 fore_blue: types::Card16,
41642 back_red: types::Card16,
41643 back_green: types::Card16,
41644 back_blue: types::Card16,
41645 x: types::Card16,
41646 y: types::Card16,
41647 ) -> futures::SendRequest<'this, Self, ()> {
41648 let span = tracing::info_span!(
41649 "create_cursor",
41650 cid = ?cid,
41651 source = ?source,
41652 fore_red = ?fore_red,
41653 fore_green = ?fore_green,
41654 fore_blue = ?fore_blue,
41655 back_red = ?back_red,
41656 back_green = ?back_green,
41657 back_blue = ?back_blue,
41658 x = ?x,
41659 y = ?y,
41660 );
41661 let request = types::xproto::CreateCursorRequest {
41662 cid,
41663 source,
41664 mask: Into::<u32>::into(mask.into()) as _,
41665 fore_red,
41666 fore_green,
41667 fore_blue,
41668 back_red,
41669 back_green,
41670 back_blue,
41671 x,
41672 y,
41673 };
41674 let cookie = self.send_void_request(request, true).with_span(span);
41675 cookie
41676 }
41677 fn create_cursor_checked<'this>(
41678 &'this mut self,
41679 cid: types::xproto::Cursor,
41680 source: types::xproto::Pixmap,
41681 mask: impl Into<types::xproto::Pixmap>,
41682 fore_red: types::Card16,
41683 fore_green: types::Card16,
41684 fore_blue: types::Card16,
41685 back_red: types::Card16,
41686 back_green: types::Card16,
41687 back_blue: types::Card16,
41688 x: types::Card16,
41689 y: types::Card16,
41690 ) -> futures::CheckedSendRequest<'this, Self, ()> {
41691 let request = types::xproto::CreateCursorRequest {
41692 cid,
41693 source,
41694 mask: Into::<u32>::into(mask.into()) as _,
41695 fore_red,
41696 fore_green,
41697 fore_blue,
41698 back_red,
41699 back_green,
41700 back_blue,
41701 x,
41702 y,
41703 };
41704 let cookie = self.send_void_request(request, false);
41705 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
41706 res
41707 }
41708 fn create_glyph_cursor<'this>(
41709 &'this mut self,
41710 cid: types::xproto::Cursor,
41711 source_font: types::Font,
41712 mask_font: impl Into<types::Font>,
41713 source_char: types::Card16,
41714 mask_char: types::Card16,
41715 fore_red: types::Card16,
41716 fore_green: types::Card16,
41717 fore_blue: types::Card16,
41718 back_red: types::Card16,
41719 back_green: types::Card16,
41720 back_blue: types::Card16,
41721 ) -> futures::SendRequest<'this, Self, ()> {
41722 let span = tracing::info_span!(
41723 "create_glyph_cursor",
41724 cid = ?cid,
41725 source_font = ?source_font,
41726 source_char = ?source_char,
41727 mask_char = ?mask_char,
41728 fore_red = ?fore_red,
41729 fore_green = ?fore_green,
41730 fore_blue = ?fore_blue,
41731 back_red = ?back_red,
41732 back_green = ?back_green,
41733 back_blue = ?back_blue,
41734 );
41735 let request = types::xproto::CreateGlyphCursorRequest {
41736 cid,
41737 source_font,
41738 mask_font: Into::<u32>::into(mask_font.into()) as _,
41739 source_char,
41740 mask_char,
41741 fore_red,
41742 fore_green,
41743 fore_blue,
41744 back_red,
41745 back_green,
41746 back_blue,
41747 };
41748 let cookie = self.send_void_request(request, true).with_span(span);
41749 cookie
41750 }
41751 fn create_glyph_cursor_checked<'this>(
41752 &'this mut self,
41753 cid: types::xproto::Cursor,
41754 source_font: types::Font,
41755 mask_font: impl Into<types::Font>,
41756 source_char: types::Card16,
41757 mask_char: types::Card16,
41758 fore_red: types::Card16,
41759 fore_green: types::Card16,
41760 fore_blue: types::Card16,
41761 back_red: types::Card16,
41762 back_green: types::Card16,
41763 back_blue: types::Card16,
41764 ) -> futures::CheckedSendRequest<'this, Self, ()> {
41765 let request = types::xproto::CreateGlyphCursorRequest {
41766 cid,
41767 source_font,
41768 mask_font: Into::<u32>::into(mask_font.into()) as _,
41769 source_char,
41770 mask_char,
41771 fore_red,
41772 fore_green,
41773 fore_blue,
41774 back_red,
41775 back_green,
41776 back_blue,
41777 };
41778 let cookie = self.send_void_request(request, false);
41779 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
41780 res
41781 }
41782 fn free_cursor<'this>(
41783 &'this mut self,
41784 cursor: types::xproto::Cursor,
41785 ) -> futures::SendRequest<'this, Self, ()> {
41786 let span = tracing::info_span!(
41787 "free_cursor",
41788 cursor = ?cursor,
41789 );
41790 let request = types::xproto::FreeCursorRequest { cursor };
41791 let cookie = self.send_void_request(request, true).with_span(span);
41792 cookie
41793 }
41794 fn free_cursor_checked<'this>(
41795 &'this mut self,
41796 cursor: types::xproto::Cursor,
41797 ) -> futures::CheckedSendRequest<'this, Self, ()> {
41798 let request = types::xproto::FreeCursorRequest { cursor };
41799 let cookie = self.send_void_request(request, false);
41800 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
41801 res
41802 }
41803 fn recolor_cursor<'this>(
41804 &'this mut self,
41805 cursor: types::xproto::Cursor,
41806 fore_red: types::Card16,
41807 fore_green: types::Card16,
41808 fore_blue: types::Card16,
41809 back_red: types::Card16,
41810 back_green: types::Card16,
41811 back_blue: types::Card16,
41812 ) -> futures::SendRequest<'this, Self, ()> {
41813 let span = tracing::info_span!(
41814 "recolor_cursor",
41815 cursor = ?cursor,
41816 fore_red = ?fore_red,
41817 fore_green = ?fore_green,
41818 fore_blue = ?fore_blue,
41819 back_red = ?back_red,
41820 back_green = ?back_green,
41821 back_blue = ?back_blue,
41822 );
41823 let request = types::xproto::RecolorCursorRequest {
41824 cursor,
41825 fore_red,
41826 fore_green,
41827 fore_blue,
41828 back_red,
41829 back_green,
41830 back_blue,
41831 };
41832 let cookie = self.send_void_request(request, true).with_span(span);
41833 cookie
41834 }
41835 fn recolor_cursor_checked<'this>(
41836 &'this mut self,
41837 cursor: types::xproto::Cursor,
41838 fore_red: types::Card16,
41839 fore_green: types::Card16,
41840 fore_blue: types::Card16,
41841 back_red: types::Card16,
41842 back_green: types::Card16,
41843 back_blue: types::Card16,
41844 ) -> futures::CheckedSendRequest<'this, Self, ()> {
41845 let request = types::xproto::RecolorCursorRequest {
41846 cursor,
41847 fore_red,
41848 fore_green,
41849 fore_blue,
41850 back_red,
41851 back_green,
41852 back_blue,
41853 };
41854 let cookie = self.send_void_request(request, false);
41855 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
41856 res
41857 }
41858 fn query_best_size<'this>(
41859 &'this mut self,
41860 class: types::QueryShapeOf,
41861 drawable: types::xproto::Drawable,
41862 width: types::Card16,
41863 height: types::Card16,
41864 ) -> futures::SendRequest<'this, Self, types::xproto::QueryBestSizeReply> {
41865 let span = tracing::info_span!(
41866 "query_best_size",
41867 class = ?class,
41868 drawable = ?drawable,
41869 width = ?width,
41870 height = ?height,
41871 );
41872 let request = types::xproto::QueryBestSizeRequest {
41873 class,
41874 drawable,
41875 width,
41876 height,
41877 };
41878 let cookie = self.send_reply_request(request).with_span(span);
41879 cookie
41880 }
41881 fn query_best_size_immediate<'this>(
41882 &'this mut self,
41883 class: types::QueryShapeOf,
41884 drawable: types::xproto::Drawable,
41885 width: types::Card16,
41886 height: types::Card16,
41887 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::QueryBestSizeReply> {
41888 let request = types::xproto::QueryBestSizeRequest {
41889 class,
41890 drawable,
41891 width,
41892 height,
41893 };
41894 let cookie = self.send_reply_request(request);
41895 let res: futures::CheckedSendRequest<'this, Self, types::xproto::QueryBestSizeReply> =
41896 cookie.into();
41897 res
41898 }
41899 fn query_extension<'this>(
41900 &'this mut self,
41901 name: impl AsRef<[types::Char]>,
41902 ) -> futures::SendRequest<'this, Self, types::xproto::QueryExtensionReply> {
41903 let span = tracing::info_span!("query_extension",);
41904 let request = types::xproto::QueryExtensionRequest {
41905 name: Cow::Borrowed(name.as_ref()),
41906 };
41907 let cookie = self.send_reply_request(request).with_span(span);
41908 cookie
41909 }
41910 fn query_extension_immediate<'this>(
41911 &'this mut self,
41912 name: impl AsRef<[types::Char]>,
41913 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::QueryExtensionReply> {
41914 let request = types::xproto::QueryExtensionRequest {
41915 name: Cow::Borrowed(name.as_ref()),
41916 };
41917 let cookie = self.send_reply_request(request);
41918 let res: futures::CheckedSendRequest<'this, Self, types::xproto::QueryExtensionReply> =
41919 cookie.into();
41920 res
41921 }
41922 fn list_extensions<'this>(
41923 &'this mut self,
41924 ) -> futures::SendRequest<'this, Self, types::xproto::ListExtensionsReply> {
41925 let span = tracing::info_span!("list_extensions",);
41926 let request = types::xproto::ListExtensionsRequest {};
41927 let cookie = self.send_reply_request(request).with_span(span);
41928 cookie
41929 }
41930 fn list_extensions_immediate<'this>(
41931 &'this mut self,
41932 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::ListExtensionsReply> {
41933 let request = types::xproto::ListExtensionsRequest {};
41934 let cookie = self.send_reply_request(request);
41935 let res: futures::CheckedSendRequest<'this, Self, types::xproto::ListExtensionsReply> =
41936 cookie.into();
41937 res
41938 }
41939 fn change_keyboard_mapping<'this>(
41940 &'this mut self,
41941 keycode_count: types::Card8,
41942 first_keycode: types::Keycode,
41943 keysyms_per_keycode: types::Card8,
41944 keysyms: impl AsRef<[types::Keysym]>,
41945 ) -> futures::SendRequest<'this, Self, ()> {
41946 let span = tracing::info_span!(
41947 "change_keyboard_mapping",
41948 keycode_count = ?keycode_count,
41949 first_keycode = ?first_keycode,
41950 keysyms_per_keycode = ?keysyms_per_keycode,
41951 );
41952 let request = types::xproto::ChangeKeyboardMappingRequest {
41953 keycode_count,
41954 first_keycode,
41955 keysyms_per_keycode,
41956 keysyms: Cow::Borrowed(keysyms.as_ref()),
41957 };
41958 let cookie = self.send_void_request(request, true).with_span(span);
41959 cookie
41960 }
41961 fn change_keyboard_mapping_checked<'this>(
41962 &'this mut self,
41963 keycode_count: types::Card8,
41964 first_keycode: types::Keycode,
41965 keysyms_per_keycode: types::Card8,
41966 keysyms: impl AsRef<[types::Keysym]>,
41967 ) -> futures::CheckedSendRequest<'this, Self, ()> {
41968 let request = types::xproto::ChangeKeyboardMappingRequest {
41969 keycode_count,
41970 first_keycode,
41971 keysyms_per_keycode,
41972 keysyms: Cow::Borrowed(keysyms.as_ref()),
41973 };
41974 let cookie = self.send_void_request(request, false);
41975 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
41976 res
41977 }
41978 fn get_keyboard_mapping<'this>(
41979 &'this mut self,
41980 first_keycode: types::Keycode,
41981 count: types::Card8,
41982 ) -> futures::SendRequest<'this, Self, types::xproto::GetKeyboardMappingReply> {
41983 let span = tracing::info_span!(
41984 "get_keyboard_mapping",
41985 first_keycode = ?first_keycode,
41986 count = ?count,
41987 );
41988 let request = types::xproto::GetKeyboardMappingRequest {
41989 first_keycode,
41990 count,
41991 };
41992 let cookie = self.send_reply_request(request).with_span(span);
41993 cookie
41994 }
41995 fn get_keyboard_mapping_immediate<'this>(
41996 &'this mut self,
41997 first_keycode: types::Keycode,
41998 count: types::Card8,
41999 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::GetKeyboardMappingReply> {
42000 let request = types::xproto::GetKeyboardMappingRequest {
42001 first_keycode,
42002 count,
42003 };
42004 let cookie = self.send_reply_request(request);
42005 let res: futures::CheckedSendRequest<'this, Self, types::xproto::GetKeyboardMappingReply> =
42006 cookie.into();
42007 res
42008 }
42009 fn change_keyboard_control<'this>(
42010 &'this mut self,
42011 value_list: impl Borrow<types::xproto::ChangeKeyboardControlAux>,
42012 ) -> futures::SendRequest<'this, Self, ()> {
42013 let span = tracing::info_span!("change_keyboard_control",);
42014 let request = types::xproto::ChangeKeyboardControlRequest {
42015 value_list: Cow::Borrowed(value_list.borrow()),
42016 };
42017 let cookie = self.send_void_request(request, true).with_span(span);
42018 cookie
42019 }
42020 fn change_keyboard_control_checked<'this>(
42021 &'this mut self,
42022 value_list: impl Borrow<types::xproto::ChangeKeyboardControlAux>,
42023 ) -> futures::CheckedSendRequest<'this, Self, ()> {
42024 let request = types::xproto::ChangeKeyboardControlRequest {
42025 value_list: Cow::Borrowed(value_list.borrow()),
42026 };
42027 let cookie = self.send_void_request(request, false);
42028 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
42029 res
42030 }
42031 fn get_keyboard_control<'this>(
42032 &'this mut self,
42033 ) -> futures::SendRequest<'this, Self, types::xproto::GetKeyboardControlReply> {
42034 let span = tracing::info_span!("get_keyboard_control",);
42035 let request = types::xproto::GetKeyboardControlRequest {};
42036 let cookie = self.send_reply_request(request).with_span(span);
42037 cookie
42038 }
42039 fn get_keyboard_control_immediate<'this>(
42040 &'this mut self,
42041 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::GetKeyboardControlReply> {
42042 let request = types::xproto::GetKeyboardControlRequest {};
42043 let cookie = self.send_reply_request(request);
42044 let res: futures::CheckedSendRequest<'this, Self, types::xproto::GetKeyboardControlReply> =
42045 cookie.into();
42046 res
42047 }
42048 fn bell<'this>(&'this mut self, percent: types::Int8) -> futures::SendRequest<'this, Self, ()> {
42049 let span = tracing::info_span!(
42050 "bell",
42051 percent = ?percent,
42052 );
42053 let request = types::xproto::BellRequest { percent };
42054 let cookie = self.send_void_request(request, true).with_span(span);
42055 cookie
42056 }
42057 fn bell_checked<'this>(
42058 &'this mut self,
42059 percent: types::Int8,
42060 ) -> futures::CheckedSendRequest<'this, Self, ()> {
42061 let request = types::xproto::BellRequest { percent };
42062 let cookie = self.send_void_request(request, false);
42063 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
42064 res
42065 }
42066 fn change_pointer_control<'this>(
42067 &'this mut self,
42068 acceleration_numerator: types::Int16,
42069 acceleration_denominator: types::Int16,
42070 threshold: types::Int16,
42071 do_acceleration: types::Bool,
42072 do_threshold: types::Bool,
42073 ) -> futures::SendRequest<'this, Self, ()> {
42074 let span = tracing::info_span!(
42075 "change_pointer_control",
42076 acceleration_numerator = ?acceleration_numerator,
42077 acceleration_denominator = ?acceleration_denominator,
42078 threshold = ?threshold,
42079 do_acceleration = ?do_acceleration,
42080 do_threshold = ?do_threshold,
42081 );
42082 let request = types::xproto::ChangePointerControlRequest {
42083 acceleration_numerator,
42084 acceleration_denominator,
42085 threshold,
42086 do_acceleration,
42087 do_threshold,
42088 };
42089 let cookie = self.send_void_request(request, true).with_span(span);
42090 cookie
42091 }
42092 fn change_pointer_control_checked<'this>(
42093 &'this mut self,
42094 acceleration_numerator: types::Int16,
42095 acceleration_denominator: types::Int16,
42096 threshold: types::Int16,
42097 do_acceleration: types::Bool,
42098 do_threshold: types::Bool,
42099 ) -> futures::CheckedSendRequest<'this, Self, ()> {
42100 let request = types::xproto::ChangePointerControlRequest {
42101 acceleration_numerator,
42102 acceleration_denominator,
42103 threshold,
42104 do_acceleration,
42105 do_threshold,
42106 };
42107 let cookie = self.send_void_request(request, false);
42108 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
42109 res
42110 }
42111 fn get_pointer_control<'this>(
42112 &'this mut self,
42113 ) -> futures::SendRequest<'this, Self, types::xproto::GetPointerControlReply> {
42114 let span = tracing::info_span!("get_pointer_control",);
42115 let request = types::xproto::GetPointerControlRequest {};
42116 let cookie = self.send_reply_request(request).with_span(span);
42117 cookie
42118 }
42119 fn get_pointer_control_immediate<'this>(
42120 &'this mut self,
42121 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::GetPointerControlReply> {
42122 let request = types::xproto::GetPointerControlRequest {};
42123 let cookie = self.send_reply_request(request);
42124 let res: futures::CheckedSendRequest<'this, Self, types::xproto::GetPointerControlReply> =
42125 cookie.into();
42126 res
42127 }
42128 fn set_screen_saver<'this>(
42129 &'this mut self,
42130 timeout: types::Int16,
42131 interval: types::Int16,
42132 prefer_blanking: types::Blanking,
42133 allow_exposures: types::Exposures,
42134 ) -> futures::SendRequest<'this, Self, ()> {
42135 let span = tracing::info_span!(
42136 "set_screen_saver",
42137 timeout = ?timeout,
42138 interval = ?interval,
42139 prefer_blanking = ?prefer_blanking,
42140 allow_exposures = ?allow_exposures,
42141 );
42142 let request = types::xproto::SetScreenSaverRequest {
42143 timeout,
42144 interval,
42145 prefer_blanking,
42146 allow_exposures,
42147 };
42148 let cookie = self.send_void_request(request, true).with_span(span);
42149 cookie
42150 }
42151 fn set_screen_saver_checked<'this>(
42152 &'this mut self,
42153 timeout: types::Int16,
42154 interval: types::Int16,
42155 prefer_blanking: types::Blanking,
42156 allow_exposures: types::Exposures,
42157 ) -> futures::CheckedSendRequest<'this, Self, ()> {
42158 let request = types::xproto::SetScreenSaverRequest {
42159 timeout,
42160 interval,
42161 prefer_blanking,
42162 allow_exposures,
42163 };
42164 let cookie = self.send_void_request(request, false);
42165 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
42166 res
42167 }
42168 fn get_screen_saver<'this>(
42169 &'this mut self,
42170 ) -> futures::SendRequest<'this, Self, types::xproto::GetScreenSaverReply> {
42171 let span = tracing::info_span!("get_screen_saver",);
42172 let request = types::xproto::GetScreenSaverRequest {};
42173 let cookie = self.send_reply_request(request).with_span(span);
42174 cookie
42175 }
42176 fn get_screen_saver_immediate<'this>(
42177 &'this mut self,
42178 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::GetScreenSaverReply> {
42179 let request = types::xproto::GetScreenSaverRequest {};
42180 let cookie = self.send_reply_request(request);
42181 let res: futures::CheckedSendRequest<'this, Self, types::xproto::GetScreenSaverReply> =
42182 cookie.into();
42183 res
42184 }
42185 fn change_hosts<'this>(
42186 &'this mut self,
42187 mode: types::HostMode,
42188 family: types::Family,
42189 address: impl AsRef<[types::Byte]>,
42190 ) -> futures::SendRequest<'this, Self, ()> {
42191 let span = tracing::info_span!(
42192 "change_hosts",
42193 mode = ?mode,
42194 family = ?family,
42195 );
42196 let request = types::xproto::ChangeHostsRequest {
42197 mode,
42198 family,
42199 address: Cow::Borrowed(address.as_ref()),
42200 };
42201 let cookie = self.send_void_request(request, true).with_span(span);
42202 cookie
42203 }
42204 fn change_hosts_checked<'this>(
42205 &'this mut self,
42206 mode: types::HostMode,
42207 family: types::Family,
42208 address: impl AsRef<[types::Byte]>,
42209 ) -> futures::CheckedSendRequest<'this, Self, ()> {
42210 let request = types::xproto::ChangeHostsRequest {
42211 mode,
42212 family,
42213 address: Cow::Borrowed(address.as_ref()),
42214 };
42215 let cookie = self.send_void_request(request, false);
42216 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
42217 res
42218 }
42219 fn list_hosts<'this>(
42220 &'this mut self,
42221 ) -> futures::SendRequest<'this, Self, types::xproto::ListHostsReply> {
42222 let span = tracing::info_span!("list_hosts",);
42223 let request = types::xproto::ListHostsRequest {};
42224 let cookie = self.send_reply_request(request).with_span(span);
42225 cookie
42226 }
42227 fn list_hosts_immediate<'this>(
42228 &'this mut self,
42229 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::ListHostsReply> {
42230 let request = types::xproto::ListHostsRequest {};
42231 let cookie = self.send_reply_request(request);
42232 let res: futures::CheckedSendRequest<'this, Self, types::xproto::ListHostsReply> =
42233 cookie.into();
42234 res
42235 }
42236 fn set_access_control<'this>(
42237 &'this mut self,
42238 mode: types::AccessControl,
42239 ) -> futures::SendRequest<'this, Self, ()> {
42240 let span = tracing::info_span!(
42241 "set_access_control",
42242 mode = ?mode,
42243 );
42244 let request = types::xproto::SetAccessControlRequest { mode };
42245 let cookie = self.send_void_request(request, true).with_span(span);
42246 cookie
42247 }
42248 fn set_access_control_checked<'this>(
42249 &'this mut self,
42250 mode: types::AccessControl,
42251 ) -> futures::CheckedSendRequest<'this, Self, ()> {
42252 let request = types::xproto::SetAccessControlRequest { mode };
42253 let cookie = self.send_void_request(request, false);
42254 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
42255 res
42256 }
42257 fn set_close_down_mode<'this>(
42258 &'this mut self,
42259 mode: types::CloseDown,
42260 ) -> futures::SendRequest<'this, Self, ()> {
42261 let span = tracing::info_span!(
42262 "set_close_down_mode",
42263 mode = ?mode,
42264 );
42265 let request = types::xproto::SetCloseDownModeRequest { mode };
42266 let cookie = self.send_void_request(request, true).with_span(span);
42267 cookie
42268 }
42269 fn set_close_down_mode_checked<'this>(
42270 &'this mut self,
42271 mode: types::CloseDown,
42272 ) -> futures::CheckedSendRequest<'this, Self, ()> {
42273 let request = types::xproto::SetCloseDownModeRequest { mode };
42274 let cookie = self.send_void_request(request, false);
42275 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
42276 res
42277 }
42278 fn kill_client<'this>(
42279 &'this mut self,
42280 resource: impl Into<types::Kill>,
42281 ) -> futures::SendRequest<'this, Self, ()> {
42282 let span = tracing::info_span!("kill_client",);
42283 let request = types::xproto::KillClientRequest {
42284 resource: Into::<u32>::into(resource.into()) as _,
42285 };
42286 let cookie = self.send_void_request(request, true).with_span(span);
42287 cookie
42288 }
42289 fn kill_client_checked<'this>(
42290 &'this mut self,
42291 resource: impl Into<types::Kill>,
42292 ) -> futures::CheckedSendRequest<'this, Self, ()> {
42293 let request = types::xproto::KillClientRequest {
42294 resource: Into::<u32>::into(resource.into()) as _,
42295 };
42296 let cookie = self.send_void_request(request, false);
42297 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
42298 res
42299 }
42300 fn rotate_properties<'this>(
42301 &'this mut self,
42302 window: types::xproto::Window,
42303 delta: types::Int16,
42304 atoms: impl AsRef<[types::Atom]>,
42305 ) -> futures::SendRequest<'this, Self, ()> {
42306 let span = tracing::info_span!(
42307 "rotate_properties",
42308 window = ?window,
42309 delta = ?delta,
42310 );
42311 let request = types::xproto::RotatePropertiesRequest {
42312 window,
42313 delta,
42314 atoms: Cow::Borrowed(atoms.as_ref()),
42315 };
42316 let cookie = self.send_void_request(request, true).with_span(span);
42317 cookie
42318 }
42319 fn rotate_properties_checked<'this>(
42320 &'this mut self,
42321 window: types::xproto::Window,
42322 delta: types::Int16,
42323 atoms: impl AsRef<[types::Atom]>,
42324 ) -> futures::CheckedSendRequest<'this, Self, ()> {
42325 let request = types::xproto::RotatePropertiesRequest {
42326 window,
42327 delta,
42328 atoms: Cow::Borrowed(atoms.as_ref()),
42329 };
42330 let cookie = self.send_void_request(request, false);
42331 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
42332 res
42333 }
42334 fn force_screen_saver<'this>(
42335 &'this mut self,
42336 mode: types::ScreenSaver,
42337 ) -> futures::SendRequest<'this, Self, ()> {
42338 let span = tracing::info_span!(
42339 "force_screen_saver",
42340 mode = ?mode,
42341 );
42342 let request = types::xproto::ForceScreenSaverRequest { mode };
42343 let cookie = self.send_void_request(request, true).with_span(span);
42344 cookie
42345 }
42346 fn force_screen_saver_checked<'this>(
42347 &'this mut self,
42348 mode: types::ScreenSaver,
42349 ) -> futures::CheckedSendRequest<'this, Self, ()> {
42350 let request = types::xproto::ForceScreenSaverRequest { mode };
42351 let cookie = self.send_void_request(request, false);
42352 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
42353 res
42354 }
42355 fn set_pointer_mapping<'this>(
42356 &'this mut self,
42357 map: impl AsRef<[types::Card8]>,
42358 ) -> futures::SendRequest<'this, Self, types::xproto::SetPointerMappingReply> {
42359 let span = tracing::info_span!("set_pointer_mapping",);
42360 let request = types::xproto::SetPointerMappingRequest {
42361 map: Cow::Borrowed(map.as_ref()),
42362 };
42363 let cookie = self.send_reply_request(request).with_span(span);
42364 cookie
42365 }
42366 fn set_pointer_mapping_immediate<'this>(
42367 &'this mut self,
42368 map: impl AsRef<[types::Card8]>,
42369 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::SetPointerMappingReply> {
42370 let request = types::xproto::SetPointerMappingRequest {
42371 map: Cow::Borrowed(map.as_ref()),
42372 };
42373 let cookie = self.send_reply_request(request);
42374 let res: futures::CheckedSendRequest<'this, Self, types::xproto::SetPointerMappingReply> =
42375 cookie.into();
42376 res
42377 }
42378 fn get_pointer_mapping<'this>(
42379 &'this mut self,
42380 ) -> futures::SendRequest<'this, Self, types::xproto::GetPointerMappingReply> {
42381 let span = tracing::info_span!("get_pointer_mapping",);
42382 let request = types::xproto::GetPointerMappingRequest {};
42383 let cookie = self.send_reply_request(request).with_span(span);
42384 cookie
42385 }
42386 fn get_pointer_mapping_immediate<'this>(
42387 &'this mut self,
42388 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::GetPointerMappingReply> {
42389 let request = types::xproto::GetPointerMappingRequest {};
42390 let cookie = self.send_reply_request(request);
42391 let res: futures::CheckedSendRequest<'this, Self, types::xproto::GetPointerMappingReply> =
42392 cookie.into();
42393 res
42394 }
42395 fn set_modifier_mapping<'this>(
42396 &'this mut self,
42397 keycodes: impl AsRef<[types::Keycode]>,
42398 ) -> futures::SendRequest<'this, Self, types::xproto::SetModifierMappingReply> {
42399 let span = tracing::info_span!("set_modifier_mapping",);
42400 let request = types::xproto::SetModifierMappingRequest {
42401 keycodes: Cow::Borrowed(keycodes.as_ref()),
42402 };
42403 let cookie = self.send_reply_request(request).with_span(span);
42404 cookie
42405 }
42406 fn set_modifier_mapping_immediate<'this>(
42407 &'this mut self,
42408 keycodes: impl AsRef<[types::Keycode]>,
42409 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::SetModifierMappingReply> {
42410 let request = types::xproto::SetModifierMappingRequest {
42411 keycodes: Cow::Borrowed(keycodes.as_ref()),
42412 };
42413 let cookie = self.send_reply_request(request);
42414 let res: futures::CheckedSendRequest<'this, Self, types::xproto::SetModifierMappingReply> =
42415 cookie.into();
42416 res
42417 }
42418 fn get_modifier_mapping<'this>(
42419 &'this mut self,
42420 ) -> futures::SendRequest<'this, Self, types::xproto::GetModifierMappingReply> {
42421 let span = tracing::info_span!("get_modifier_mapping",);
42422 let request = types::xproto::GetModifierMappingRequest {};
42423 let cookie = self.send_reply_request(request).with_span(span);
42424 cookie
42425 }
42426 fn get_modifier_mapping_immediate<'this>(
42427 &'this mut self,
42428 ) -> futures::CheckedSendRequest<'this, Self, types::xproto::GetModifierMappingReply> {
42429 let request = types::xproto::GetModifierMappingRequest {};
42430 let cookie = self.send_reply_request(request);
42431 let res: futures::CheckedSendRequest<'this, Self, types::xproto::GetModifierMappingReply> =
42432 cookie.into();
42433 res
42434 }
42435 fn no_operation<'this>(&'this mut self) -> futures::SendRequest<'this, Self, ()> {
42436 let span = tracing::info_span!("no_operation",);
42437 let request = types::xproto::NoOperationRequest {};
42438 let cookie = self.send_void_request(request, true).with_span(span);
42439 cookie
42440 }
42441 fn no_operation_checked<'this>(
42442 &'this mut self,
42443 ) -> futures::CheckedSendRequest<'this, Self, ()> {
42444 let request = types::xproto::NoOperationRequest {};
42445 let cookie = self.send_void_request(request, false);
42446 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
42447 res
42448 }
42449
42450 #[cfg(feature = "xselinux")]
42451 fn xselinux_query_version<'this>(
42452 &'this mut self,
42453 client_major: types::Card8,
42454 client_minor: types::Card8,
42455 ) -> futures::SendRequest<'this, Self, types::xselinux::QueryVersionReply> {
42456 let span = tracing::info_span!(
42457 "xselinux_query_version",
42458 client_major = ?client_major,
42459 client_minor = ?client_minor,
42460 );
42461 let request = types::xselinux::QueryVersionRequest {
42462 client_major,
42463 client_minor,
42464 };
42465 let cookie = self.send_reply_request(request).with_span(span);
42466 cookie
42467 }
42468 #[cfg(feature = "xselinux")]
42469 fn xselinux_query_version_immediate<'this>(
42470 &'this mut self,
42471 client_major: types::Card8,
42472 client_minor: types::Card8,
42473 ) -> futures::CheckedSendRequest<'this, Self, types::xselinux::QueryVersionReply> {
42474 let request = types::xselinux::QueryVersionRequest {
42475 client_major,
42476 client_minor,
42477 };
42478 let cookie = self.send_reply_request(request);
42479 let res: futures::CheckedSendRequest<'this, Self, types::xselinux::QueryVersionReply> =
42480 cookie.into();
42481 res
42482 }
42483 #[cfg(feature = "xselinux")]
42484 fn xselinux_set_device_create_context<'this>(
42485 &'this mut self,
42486 context: impl AsRef<[types::Char]>,
42487 ) -> futures::SendRequest<'this, Self, ()> {
42488 let span = tracing::info_span!("xselinux_set_device_create_context",);
42489 let request = types::xselinux::SetDeviceCreateContextRequest {
42490 context: Cow::Borrowed(context.as_ref()),
42491 };
42492 let cookie = self.send_void_request(request, true).with_span(span);
42493 cookie
42494 }
42495 #[cfg(feature = "xselinux")]
42496 fn xselinux_set_device_create_context_checked<'this>(
42497 &'this mut self,
42498 context: impl AsRef<[types::Char]>,
42499 ) -> futures::CheckedSendRequest<'this, Self, ()> {
42500 let request = types::xselinux::SetDeviceCreateContextRequest {
42501 context: Cow::Borrowed(context.as_ref()),
42502 };
42503 let cookie = self.send_void_request(request, false);
42504 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
42505 res
42506 }
42507 #[cfg(feature = "xselinux")]
42508 fn xselinux_get_device_create_context<'this>(
42509 &'this mut self,
42510 ) -> futures::SendRequest<'this, Self, types::xselinux::GetDeviceCreateContextReply> {
42511 let span = tracing::info_span!("xselinux_get_device_create_context",);
42512 let request = types::xselinux::GetDeviceCreateContextRequest {};
42513 let cookie = self.send_reply_request(request).with_span(span);
42514 cookie
42515 }
42516 #[cfg(feature = "xselinux")]
42517 fn xselinux_get_device_create_context_immediate<'this>(
42518 &'this mut self,
42519 ) -> futures::CheckedSendRequest<'this, Self, types::xselinux::GetDeviceCreateContextReply>
42520 {
42521 let request = types::xselinux::GetDeviceCreateContextRequest {};
42522 let cookie = self.send_reply_request(request);
42523 let res: futures::CheckedSendRequest<
42524 'this,
42525 Self,
42526 types::xselinux::GetDeviceCreateContextReply,
42527 > = cookie.into();
42528 res
42529 }
42530 #[cfg(feature = "xselinux")]
42531 fn xselinux_set_device_context<'this>(
42532 &'this mut self,
42533 device: types::Card32,
42534 context: impl AsRef<[types::Char]>,
42535 ) -> futures::SendRequest<'this, Self, ()> {
42536 let span = tracing::info_span!(
42537 "xselinux_set_device_context",
42538 device = ?device,
42539 );
42540 let request = types::xselinux::SetDeviceContextRequest {
42541 device,
42542 context: Cow::Borrowed(context.as_ref()),
42543 };
42544 let cookie = self.send_void_request(request, true).with_span(span);
42545 cookie
42546 }
42547 #[cfg(feature = "xselinux")]
42548 fn xselinux_set_device_context_checked<'this>(
42549 &'this mut self,
42550 device: types::Card32,
42551 context: impl AsRef<[types::Char]>,
42552 ) -> futures::CheckedSendRequest<'this, Self, ()> {
42553 let request = types::xselinux::SetDeviceContextRequest {
42554 device,
42555 context: Cow::Borrowed(context.as_ref()),
42556 };
42557 let cookie = self.send_void_request(request, false);
42558 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
42559 res
42560 }
42561 #[cfg(feature = "xselinux")]
42562 fn xselinux_get_device_context<'this>(
42563 &'this mut self,
42564 device: types::Card32,
42565 ) -> futures::SendRequest<'this, Self, types::xselinux::GetDeviceContextReply> {
42566 let span = tracing::info_span!(
42567 "xselinux_get_device_context",
42568 device = ?device,
42569 );
42570 let request = types::xselinux::GetDeviceContextRequest { device };
42571 let cookie = self.send_reply_request(request).with_span(span);
42572 cookie
42573 }
42574 #[cfg(feature = "xselinux")]
42575 fn xselinux_get_device_context_immediate<'this>(
42576 &'this mut self,
42577 device: types::Card32,
42578 ) -> futures::CheckedSendRequest<'this, Self, types::xselinux::GetDeviceContextReply> {
42579 let request = types::xselinux::GetDeviceContextRequest { device };
42580 let cookie = self.send_reply_request(request);
42581 let res: futures::CheckedSendRequest<'this, Self, types::xselinux::GetDeviceContextReply> =
42582 cookie.into();
42583 res
42584 }
42585 #[cfg(feature = "xselinux")]
42586 fn xselinux_set_window_create_context<'this>(
42587 &'this mut self,
42588 context: impl AsRef<[types::Char]>,
42589 ) -> futures::SendRequest<'this, Self, ()> {
42590 let span = tracing::info_span!("xselinux_set_window_create_context",);
42591 let request = types::xselinux::SetWindowCreateContextRequest {
42592 context: Cow::Borrowed(context.as_ref()),
42593 };
42594 let cookie = self.send_void_request(request, true).with_span(span);
42595 cookie
42596 }
42597 #[cfg(feature = "xselinux")]
42598 fn xselinux_set_window_create_context_checked<'this>(
42599 &'this mut self,
42600 context: impl AsRef<[types::Char]>,
42601 ) -> futures::CheckedSendRequest<'this, Self, ()> {
42602 let request = types::xselinux::SetWindowCreateContextRequest {
42603 context: Cow::Borrowed(context.as_ref()),
42604 };
42605 let cookie = self.send_void_request(request, false);
42606 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
42607 res
42608 }
42609 #[cfg(feature = "xselinux")]
42610 fn xselinux_get_window_create_context<'this>(
42611 &'this mut self,
42612 ) -> futures::SendRequest<'this, Self, types::xselinux::GetWindowCreateContextReply> {
42613 let span = tracing::info_span!("xselinux_get_window_create_context",);
42614 let request = types::xselinux::GetWindowCreateContextRequest {};
42615 let cookie = self.send_reply_request(request).with_span(span);
42616 cookie
42617 }
42618 #[cfg(feature = "xselinux")]
42619 fn xselinux_get_window_create_context_immediate<'this>(
42620 &'this mut self,
42621 ) -> futures::CheckedSendRequest<'this, Self, types::xselinux::GetWindowCreateContextReply>
42622 {
42623 let request = types::xselinux::GetWindowCreateContextRequest {};
42624 let cookie = self.send_reply_request(request);
42625 let res: futures::CheckedSendRequest<
42626 'this,
42627 Self,
42628 types::xselinux::GetWindowCreateContextReply,
42629 > = cookie.into();
42630 res
42631 }
42632 #[cfg(feature = "xselinux")]
42633 fn xselinux_get_window_context<'this>(
42634 &'this mut self,
42635 window: types::xproto::Window,
42636 ) -> futures::SendRequest<'this, Self, types::xselinux::GetWindowContextReply> {
42637 let span = tracing::info_span!(
42638 "xselinux_get_window_context",
42639 window = ?window,
42640 );
42641 let request = types::xselinux::GetWindowContextRequest { window };
42642 let cookie = self.send_reply_request(request).with_span(span);
42643 cookie
42644 }
42645 #[cfg(feature = "xselinux")]
42646 fn xselinux_get_window_context_immediate<'this>(
42647 &'this mut self,
42648 window: types::xproto::Window,
42649 ) -> futures::CheckedSendRequest<'this, Self, types::xselinux::GetWindowContextReply> {
42650 let request = types::xselinux::GetWindowContextRequest { window };
42651 let cookie = self.send_reply_request(request);
42652 let res: futures::CheckedSendRequest<'this, Self, types::xselinux::GetWindowContextReply> =
42653 cookie.into();
42654 res
42655 }
42656 #[cfg(feature = "xselinux")]
42657 fn xselinux_set_property_create_context<'this>(
42658 &'this mut self,
42659 context: impl AsRef<[types::Char]>,
42660 ) -> futures::SendRequest<'this, Self, ()> {
42661 let span = tracing::info_span!("xselinux_set_property_create_context",);
42662 let request = types::xselinux::SetPropertyCreateContextRequest {
42663 context: Cow::Borrowed(context.as_ref()),
42664 };
42665 let cookie = self.send_void_request(request, true).with_span(span);
42666 cookie
42667 }
42668 #[cfg(feature = "xselinux")]
42669 fn xselinux_set_property_create_context_checked<'this>(
42670 &'this mut self,
42671 context: impl AsRef<[types::Char]>,
42672 ) -> futures::CheckedSendRequest<'this, Self, ()> {
42673 let request = types::xselinux::SetPropertyCreateContextRequest {
42674 context: Cow::Borrowed(context.as_ref()),
42675 };
42676 let cookie = self.send_void_request(request, false);
42677 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
42678 res
42679 }
42680 #[cfg(feature = "xselinux")]
42681 fn xselinux_get_property_create_context<'this>(
42682 &'this mut self,
42683 ) -> futures::SendRequest<'this, Self, types::xselinux::GetPropertyCreateContextReply> {
42684 let span = tracing::info_span!("xselinux_get_property_create_context",);
42685 let request = types::xselinux::GetPropertyCreateContextRequest {};
42686 let cookie = self.send_reply_request(request).with_span(span);
42687 cookie
42688 }
42689 #[cfg(feature = "xselinux")]
42690 fn xselinux_get_property_create_context_immediate<'this>(
42691 &'this mut self,
42692 ) -> futures::CheckedSendRequest<'this, Self, types::xselinux::GetPropertyCreateContextReply>
42693 {
42694 let request = types::xselinux::GetPropertyCreateContextRequest {};
42695 let cookie = self.send_reply_request(request);
42696 let res: futures::CheckedSendRequest<
42697 'this,
42698 Self,
42699 types::xselinux::GetPropertyCreateContextReply,
42700 > = cookie.into();
42701 res
42702 }
42703 #[cfg(feature = "xselinux")]
42704 fn xselinux_set_property_use_context<'this>(
42705 &'this mut self,
42706 context: impl AsRef<[types::Char]>,
42707 ) -> futures::SendRequest<'this, Self, ()> {
42708 let span = tracing::info_span!("xselinux_set_property_use_context",);
42709 let request = types::xselinux::SetPropertyUseContextRequest {
42710 context: Cow::Borrowed(context.as_ref()),
42711 };
42712 let cookie = self.send_void_request(request, true).with_span(span);
42713 cookie
42714 }
42715 #[cfg(feature = "xselinux")]
42716 fn xselinux_set_property_use_context_checked<'this>(
42717 &'this mut self,
42718 context: impl AsRef<[types::Char]>,
42719 ) -> futures::CheckedSendRequest<'this, Self, ()> {
42720 let request = types::xselinux::SetPropertyUseContextRequest {
42721 context: Cow::Borrowed(context.as_ref()),
42722 };
42723 let cookie = self.send_void_request(request, false);
42724 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
42725 res
42726 }
42727 #[cfg(feature = "xselinux")]
42728 fn xselinux_get_property_use_context<'this>(
42729 &'this mut self,
42730 ) -> futures::SendRequest<'this, Self, types::xselinux::GetPropertyUseContextReply> {
42731 let span = tracing::info_span!("xselinux_get_property_use_context",);
42732 let request = types::xselinux::GetPropertyUseContextRequest {};
42733 let cookie = self.send_reply_request(request).with_span(span);
42734 cookie
42735 }
42736 #[cfg(feature = "xselinux")]
42737 fn xselinux_get_property_use_context_immediate<'this>(
42738 &'this mut self,
42739 ) -> futures::CheckedSendRequest<'this, Self, types::xselinux::GetPropertyUseContextReply> {
42740 let request = types::xselinux::GetPropertyUseContextRequest {};
42741 let cookie = self.send_reply_request(request);
42742 let res: futures::CheckedSendRequest<
42743 'this,
42744 Self,
42745 types::xselinux::GetPropertyUseContextReply,
42746 > = cookie.into();
42747 res
42748 }
42749 #[cfg(feature = "xselinux")]
42750 fn xselinux_get_property_context<'this>(
42751 &'this mut self,
42752 window: types::xproto::Window,
42753 property: types::Atom,
42754 ) -> futures::SendRequest<'this, Self, types::xselinux::GetPropertyContextReply> {
42755 let span = tracing::info_span!(
42756 "xselinux_get_property_context",
42757 window = ?window,
42758 property = ?property,
42759 );
42760 let request = types::xselinux::GetPropertyContextRequest { window, property };
42761 let cookie = self.send_reply_request(request).with_span(span);
42762 cookie
42763 }
42764 #[cfg(feature = "xselinux")]
42765 fn xselinux_get_property_context_immediate<'this>(
42766 &'this mut self,
42767 window: types::xproto::Window,
42768 property: types::Atom,
42769 ) -> futures::CheckedSendRequest<'this, Self, types::xselinux::GetPropertyContextReply> {
42770 let request = types::xselinux::GetPropertyContextRequest { window, property };
42771 let cookie = self.send_reply_request(request);
42772 let res: futures::CheckedSendRequest<
42773 'this,
42774 Self,
42775 types::xselinux::GetPropertyContextReply,
42776 > = cookie.into();
42777 res
42778 }
42779 #[cfg(feature = "xselinux")]
42780 fn xselinux_get_property_data_context<'this>(
42781 &'this mut self,
42782 window: types::xproto::Window,
42783 property: types::Atom,
42784 ) -> futures::SendRequest<'this, Self, types::xselinux::GetPropertyDataContextReply> {
42785 let span = tracing::info_span!(
42786 "xselinux_get_property_data_context",
42787 window = ?window,
42788 property = ?property,
42789 );
42790 let request = types::xselinux::GetPropertyDataContextRequest { window, property };
42791 let cookie = self.send_reply_request(request).with_span(span);
42792 cookie
42793 }
42794 #[cfg(feature = "xselinux")]
42795 fn xselinux_get_property_data_context_immediate<'this>(
42796 &'this mut self,
42797 window: types::xproto::Window,
42798 property: types::Atom,
42799 ) -> futures::CheckedSendRequest<'this, Self, types::xselinux::GetPropertyDataContextReply>
42800 {
42801 let request = types::xselinux::GetPropertyDataContextRequest { window, property };
42802 let cookie = self.send_reply_request(request);
42803 let res: futures::CheckedSendRequest<
42804 'this,
42805 Self,
42806 types::xselinux::GetPropertyDataContextReply,
42807 > = cookie.into();
42808 res
42809 }
42810 #[cfg(feature = "xselinux")]
42811 fn xselinux_list_properties<'this>(
42812 &'this mut self,
42813 window: types::xproto::Window,
42814 ) -> futures::SendRequest<'this, Self, types::xselinux::ListPropertiesReply> {
42815 let span = tracing::info_span!(
42816 "xselinux_list_properties",
42817 window = ?window,
42818 );
42819 let request = types::xselinux::ListPropertiesRequest { window };
42820 let cookie = self.send_reply_request(request).with_span(span);
42821 cookie
42822 }
42823 #[cfg(feature = "xselinux")]
42824 fn xselinux_list_properties_immediate<'this>(
42825 &'this mut self,
42826 window: types::xproto::Window,
42827 ) -> futures::CheckedSendRequest<'this, Self, types::xselinux::ListPropertiesReply> {
42828 let request = types::xselinux::ListPropertiesRequest { window };
42829 let cookie = self.send_reply_request(request);
42830 let res: futures::CheckedSendRequest<'this, Self, types::xselinux::ListPropertiesReply> =
42831 cookie.into();
42832 res
42833 }
42834 #[cfg(feature = "xselinux")]
42835 fn xselinux_set_selection_create_context<'this>(
42836 &'this mut self,
42837 context: impl AsRef<[types::Char]>,
42838 ) -> futures::SendRequest<'this, Self, ()> {
42839 let span = tracing::info_span!("xselinux_set_selection_create_context",);
42840 let request = types::xselinux::SetSelectionCreateContextRequest {
42841 context: Cow::Borrowed(context.as_ref()),
42842 };
42843 let cookie = self.send_void_request(request, true).with_span(span);
42844 cookie
42845 }
42846 #[cfg(feature = "xselinux")]
42847 fn xselinux_set_selection_create_context_checked<'this>(
42848 &'this mut self,
42849 context: impl AsRef<[types::Char]>,
42850 ) -> futures::CheckedSendRequest<'this, Self, ()> {
42851 let request = types::xselinux::SetSelectionCreateContextRequest {
42852 context: Cow::Borrowed(context.as_ref()),
42853 };
42854 let cookie = self.send_void_request(request, false);
42855 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
42856 res
42857 }
42858 #[cfg(feature = "xselinux")]
42859 fn xselinux_get_selection_create_context<'this>(
42860 &'this mut self,
42861 ) -> futures::SendRequest<'this, Self, types::xselinux::GetSelectionCreateContextReply> {
42862 let span = tracing::info_span!("xselinux_get_selection_create_context",);
42863 let request = types::xselinux::GetSelectionCreateContextRequest {};
42864 let cookie = self.send_reply_request(request).with_span(span);
42865 cookie
42866 }
42867 #[cfg(feature = "xselinux")]
42868 fn xselinux_get_selection_create_context_immediate<'this>(
42869 &'this mut self,
42870 ) -> futures::CheckedSendRequest<'this, Self, types::xselinux::GetSelectionCreateContextReply>
42871 {
42872 let request = types::xselinux::GetSelectionCreateContextRequest {};
42873 let cookie = self.send_reply_request(request);
42874 let res: futures::CheckedSendRequest<
42875 'this,
42876 Self,
42877 types::xselinux::GetSelectionCreateContextReply,
42878 > = cookie.into();
42879 res
42880 }
42881 #[cfg(feature = "xselinux")]
42882 fn xselinux_set_selection_use_context<'this>(
42883 &'this mut self,
42884 context: impl AsRef<[types::Char]>,
42885 ) -> futures::SendRequest<'this, Self, ()> {
42886 let span = tracing::info_span!("xselinux_set_selection_use_context",);
42887 let request = types::xselinux::SetSelectionUseContextRequest {
42888 context: Cow::Borrowed(context.as_ref()),
42889 };
42890 let cookie = self.send_void_request(request, true).with_span(span);
42891 cookie
42892 }
42893 #[cfg(feature = "xselinux")]
42894 fn xselinux_set_selection_use_context_checked<'this>(
42895 &'this mut self,
42896 context: impl AsRef<[types::Char]>,
42897 ) -> futures::CheckedSendRequest<'this, Self, ()> {
42898 let request = types::xselinux::SetSelectionUseContextRequest {
42899 context: Cow::Borrowed(context.as_ref()),
42900 };
42901 let cookie = self.send_void_request(request, false);
42902 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
42903 res
42904 }
42905 #[cfg(feature = "xselinux")]
42906 fn xselinux_get_selection_use_context<'this>(
42907 &'this mut self,
42908 ) -> futures::SendRequest<'this, Self, types::xselinux::GetSelectionUseContextReply> {
42909 let span = tracing::info_span!("xselinux_get_selection_use_context",);
42910 let request = types::xselinux::GetSelectionUseContextRequest {};
42911 let cookie = self.send_reply_request(request).with_span(span);
42912 cookie
42913 }
42914 #[cfg(feature = "xselinux")]
42915 fn xselinux_get_selection_use_context_immediate<'this>(
42916 &'this mut self,
42917 ) -> futures::CheckedSendRequest<'this, Self, types::xselinux::GetSelectionUseContextReply>
42918 {
42919 let request = types::xselinux::GetSelectionUseContextRequest {};
42920 let cookie = self.send_reply_request(request);
42921 let res: futures::CheckedSendRequest<
42922 'this,
42923 Self,
42924 types::xselinux::GetSelectionUseContextReply,
42925 > = cookie.into();
42926 res
42927 }
42928 #[cfg(feature = "xselinux")]
42929 fn xselinux_get_selection_context<'this>(
42930 &'this mut self,
42931 selection: types::Atom,
42932 ) -> futures::SendRequest<'this, Self, types::xselinux::GetSelectionContextReply> {
42933 let span = tracing::info_span!(
42934 "xselinux_get_selection_context",
42935 selection = ?selection,
42936 );
42937 let request = types::xselinux::GetSelectionContextRequest { selection };
42938 let cookie = self.send_reply_request(request).with_span(span);
42939 cookie
42940 }
42941 #[cfg(feature = "xselinux")]
42942 fn xselinux_get_selection_context_immediate<'this>(
42943 &'this mut self,
42944 selection: types::Atom,
42945 ) -> futures::CheckedSendRequest<'this, Self, types::xselinux::GetSelectionContextReply> {
42946 let request = types::xselinux::GetSelectionContextRequest { selection };
42947 let cookie = self.send_reply_request(request);
42948 let res: futures::CheckedSendRequest<
42949 'this,
42950 Self,
42951 types::xselinux::GetSelectionContextReply,
42952 > = cookie.into();
42953 res
42954 }
42955 #[cfg(feature = "xselinux")]
42956 fn xselinux_get_selection_data_context<'this>(
42957 &'this mut self,
42958 selection: types::Atom,
42959 ) -> futures::SendRequest<'this, Self, types::xselinux::GetSelectionDataContextReply> {
42960 let span = tracing::info_span!(
42961 "xselinux_get_selection_data_context",
42962 selection = ?selection,
42963 );
42964 let request = types::xselinux::GetSelectionDataContextRequest { selection };
42965 let cookie = self.send_reply_request(request).with_span(span);
42966 cookie
42967 }
42968 #[cfg(feature = "xselinux")]
42969 fn xselinux_get_selection_data_context_immediate<'this>(
42970 &'this mut self,
42971 selection: types::Atom,
42972 ) -> futures::CheckedSendRequest<'this, Self, types::xselinux::GetSelectionDataContextReply>
42973 {
42974 let request = types::xselinux::GetSelectionDataContextRequest { selection };
42975 let cookie = self.send_reply_request(request);
42976 let res: futures::CheckedSendRequest<
42977 'this,
42978 Self,
42979 types::xselinux::GetSelectionDataContextReply,
42980 > = cookie.into();
42981 res
42982 }
42983 #[cfg(feature = "xselinux")]
42984 fn xselinux_list_selections<'this>(
42985 &'this mut self,
42986 ) -> futures::SendRequest<'this, Self, types::xselinux::ListSelectionsReply> {
42987 let span = tracing::info_span!("xselinux_list_selections",);
42988 let request = types::xselinux::ListSelectionsRequest {};
42989 let cookie = self.send_reply_request(request).with_span(span);
42990 cookie
42991 }
42992 #[cfg(feature = "xselinux")]
42993 fn xselinux_list_selections_immediate<'this>(
42994 &'this mut self,
42995 ) -> futures::CheckedSendRequest<'this, Self, types::xselinux::ListSelectionsReply> {
42996 let request = types::xselinux::ListSelectionsRequest {};
42997 let cookie = self.send_reply_request(request);
42998 let res: futures::CheckedSendRequest<'this, Self, types::xselinux::ListSelectionsReply> =
42999 cookie.into();
43000 res
43001 }
43002 #[cfg(feature = "xselinux")]
43003 fn xselinux_get_client_context<'this>(
43004 &'this mut self,
43005 resource: types::Card32,
43006 ) -> futures::SendRequest<'this, Self, types::xselinux::GetClientContextReply> {
43007 let span = tracing::info_span!(
43008 "xselinux_get_client_context",
43009 resource = ?resource,
43010 );
43011 let request = types::xselinux::GetClientContextRequest { resource };
43012 let cookie = self.send_reply_request(request).with_span(span);
43013 cookie
43014 }
43015 #[cfg(feature = "xselinux")]
43016 fn xselinux_get_client_context_immediate<'this>(
43017 &'this mut self,
43018 resource: types::Card32,
43019 ) -> futures::CheckedSendRequest<'this, Self, types::xselinux::GetClientContextReply> {
43020 let request = types::xselinux::GetClientContextRequest { resource };
43021 let cookie = self.send_reply_request(request);
43022 let res: futures::CheckedSendRequest<'this, Self, types::xselinux::GetClientContextReply> =
43023 cookie.into();
43024 res
43025 }
43026
43027 #[cfg(feature = "xtest")]
43028 fn xtest_get_version<'this>(
43029 &'this mut self,
43030 major_version: types::Card8,
43031 minor_version: types::Card16,
43032 ) -> futures::SendRequest<'this, Self, types::xtest::GetVersionReply> {
43033 let span = tracing::info_span!(
43034 "xtest_get_version",
43035 major_version = ?major_version,
43036 minor_version = ?minor_version,
43037 );
43038 let request = types::xtest::GetVersionRequest {
43039 major_version,
43040 minor_version,
43041 };
43042 let cookie = self.send_reply_request(request).with_span(span);
43043 cookie
43044 }
43045 #[cfg(feature = "xtest")]
43046 fn xtest_get_version_immediate<'this>(
43047 &'this mut self,
43048 major_version: types::Card8,
43049 minor_version: types::Card16,
43050 ) -> futures::CheckedSendRequest<'this, Self, types::xtest::GetVersionReply> {
43051 let request = types::xtest::GetVersionRequest {
43052 major_version,
43053 minor_version,
43054 };
43055 let cookie = self.send_reply_request(request);
43056 let res: futures::CheckedSendRequest<'this, Self, types::xtest::GetVersionReply> =
43057 cookie.into();
43058 res
43059 }
43060 #[cfg(feature = "xtest")]
43061 fn xtest_compare_cursor<'this>(
43062 &'this mut self,
43063 window: types::xproto::Window,
43064 cursor: types::xproto::Cursor,
43065 ) -> futures::SendRequest<'this, Self, types::xtest::CompareCursorReply> {
43066 let span = tracing::info_span!(
43067 "xtest_compare_cursor",
43068 window = ?window,
43069 cursor = ?cursor,
43070 );
43071 let request = types::xtest::CompareCursorRequest { window, cursor };
43072 let cookie = self.send_reply_request(request).with_span(span);
43073 cookie
43074 }
43075 #[cfg(feature = "xtest")]
43076 fn xtest_compare_cursor_immediate<'this>(
43077 &'this mut self,
43078 window: types::xproto::Window,
43079 cursor: types::xproto::Cursor,
43080 ) -> futures::CheckedSendRequest<'this, Self, types::xtest::CompareCursorReply> {
43081 let request = types::xtest::CompareCursorRequest { window, cursor };
43082 let cookie = self.send_reply_request(request);
43083 let res: futures::CheckedSendRequest<'this, Self, types::xtest::CompareCursorReply> =
43084 cookie.into();
43085 res
43086 }
43087 #[cfg(feature = "xtest")]
43088 fn xtest_fake_input<'this>(
43089 &'this mut self,
43090 type_: types::Byte,
43091 detail: types::Byte,
43092 time: types::Card32,
43093 root: types::xproto::Window,
43094 root_x: types::Int16,
43095 root_y: types::Int16,
43096 deviceid: types::Card8,
43097 ) -> futures::SendRequest<'this, Self, ()> {
43098 let span = tracing::info_span!(
43099 "xtest_fake_input",
43100 type_ = ?type_,
43101 detail = ?detail,
43102 time = ?time,
43103 root = ?root,
43104 root_x = ?root_x,
43105 root_y = ?root_y,
43106 deviceid = ?deviceid,
43107 );
43108 let request = types::xtest::FakeInputRequest {
43109 type_,
43110 detail,
43111 time,
43112 root,
43113 root_x,
43114 root_y,
43115 deviceid,
43116 };
43117 let cookie = self.send_void_request(request, true).with_span(span);
43118 cookie
43119 }
43120 #[cfg(feature = "xtest")]
43121 fn xtest_fake_input_checked<'this>(
43122 &'this mut self,
43123 type_: types::Byte,
43124 detail: types::Byte,
43125 time: types::Card32,
43126 root: types::xproto::Window,
43127 root_x: types::Int16,
43128 root_y: types::Int16,
43129 deviceid: types::Card8,
43130 ) -> futures::CheckedSendRequest<'this, Self, ()> {
43131 let request = types::xtest::FakeInputRequest {
43132 type_,
43133 detail,
43134 time,
43135 root,
43136 root_x,
43137 root_y,
43138 deviceid,
43139 };
43140 let cookie = self.send_void_request(request, false);
43141 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
43142 res
43143 }
43144 #[cfg(feature = "xtest")]
43145 fn xtest_grab_control<'this>(
43146 &'this mut self,
43147 impervious: types::Bool,
43148 ) -> futures::SendRequest<'this, Self, ()> {
43149 let span = tracing::info_span!(
43150 "xtest_grab_control",
43151 impervious = ?impervious,
43152 );
43153 let request = types::xtest::GrabControlRequest { impervious };
43154 let cookie = self.send_void_request(request, true).with_span(span);
43155 cookie
43156 }
43157 #[cfg(feature = "xtest")]
43158 fn xtest_grab_control_checked<'this>(
43159 &'this mut self,
43160 impervious: types::Bool,
43161 ) -> futures::CheckedSendRequest<'this, Self, ()> {
43162 let request = types::xtest::GrabControlRequest { impervious };
43163 let cookie = self.send_void_request(request, false);
43164 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
43165 res
43166 }
43167
43168 #[cfg(feature = "xv")]
43169 fn xv_query_extension<'this>(
43170 &'this mut self,
43171 ) -> futures::SendRequest<'this, Self, types::xv::QueryExtensionReply> {
43172 let span = tracing::info_span!("xv_query_extension",);
43173 let request = types::xv::QueryExtensionRequest {};
43174 let cookie = self.send_reply_request(request).with_span(span);
43175 cookie
43176 }
43177 #[cfg(feature = "xv")]
43178 fn xv_query_extension_immediate<'this>(
43179 &'this mut self,
43180 ) -> futures::CheckedSendRequest<'this, Self, types::xv::QueryExtensionReply> {
43181 let request = types::xv::QueryExtensionRequest {};
43182 let cookie = self.send_reply_request(request);
43183 let res: futures::CheckedSendRequest<'this, Self, types::xv::QueryExtensionReply> =
43184 cookie.into();
43185 res
43186 }
43187 #[cfg(feature = "xv")]
43188 fn xv_query_adaptors<'this>(
43189 &'this mut self,
43190 window: types::xproto::Window,
43191 ) -> futures::SendRequest<'this, Self, types::xv::QueryAdaptorsReply> {
43192 let span = tracing::info_span!(
43193 "xv_query_adaptors",
43194 window = ?window,
43195 );
43196 let request = types::xv::QueryAdaptorsRequest { window };
43197 let cookie = self.send_reply_request(request).with_span(span);
43198 cookie
43199 }
43200 #[cfg(feature = "xv")]
43201 fn xv_query_adaptors_immediate<'this>(
43202 &'this mut self,
43203 window: types::xproto::Window,
43204 ) -> futures::CheckedSendRequest<'this, Self, types::xv::QueryAdaptorsReply> {
43205 let request = types::xv::QueryAdaptorsRequest { window };
43206 let cookie = self.send_reply_request(request);
43207 let res: futures::CheckedSendRequest<'this, Self, types::xv::QueryAdaptorsReply> =
43208 cookie.into();
43209 res
43210 }
43211 #[cfg(feature = "xv")]
43212 fn xv_query_encodings<'this>(
43213 &'this mut self,
43214 port: types::Port,
43215 ) -> futures::SendRequest<'this, Self, types::xv::QueryEncodingsReply> {
43216 let span = tracing::info_span!(
43217 "xv_query_encodings",
43218 port = ?port,
43219 );
43220 let request = types::xv::QueryEncodingsRequest { port };
43221 let cookie = self.send_reply_request(request).with_span(span);
43222 cookie
43223 }
43224 #[cfg(feature = "xv")]
43225 fn xv_query_encodings_immediate<'this>(
43226 &'this mut self,
43227 port: types::Port,
43228 ) -> futures::CheckedSendRequest<'this, Self, types::xv::QueryEncodingsReply> {
43229 let request = types::xv::QueryEncodingsRequest { port };
43230 let cookie = self.send_reply_request(request);
43231 let res: futures::CheckedSendRequest<'this, Self, types::xv::QueryEncodingsReply> =
43232 cookie.into();
43233 res
43234 }
43235 #[cfg(feature = "xv")]
43236 fn xv_grab_port<'this>(
43237 &'this mut self,
43238 port: types::Port,
43239 time: impl Into<types::Time>,
43240 ) -> futures::SendRequest<'this, Self, types::xv::GrabPortReply> {
43241 let span = tracing::info_span!(
43242 "xv_grab_port",
43243 port = ?port,
43244 );
43245 let request = types::xv::GrabPortRequest {
43246 port,
43247 time: Into::<u32>::into(time.into()) as _,
43248 };
43249 let cookie = self.send_reply_request(request).with_span(span);
43250 cookie
43251 }
43252 #[cfg(feature = "xv")]
43253 fn xv_grab_port_immediate<'this>(
43254 &'this mut self,
43255 port: types::Port,
43256 time: impl Into<types::Time>,
43257 ) -> futures::CheckedSendRequest<'this, Self, types::xv::GrabPortReply> {
43258 let request = types::xv::GrabPortRequest {
43259 port,
43260 time: Into::<u32>::into(time.into()) as _,
43261 };
43262 let cookie = self.send_reply_request(request);
43263 let res: futures::CheckedSendRequest<'this, Self, types::xv::GrabPortReply> = cookie.into();
43264 res
43265 }
43266 #[cfg(feature = "xv")]
43267 fn xv_ungrab_port<'this>(
43268 &'this mut self,
43269 port: types::Port,
43270 time: impl Into<types::Time>,
43271 ) -> futures::SendRequest<'this, Self, ()> {
43272 let span = tracing::info_span!(
43273 "xv_ungrab_port",
43274 port = ?port,
43275 );
43276 let request = types::xv::UngrabPortRequest {
43277 port,
43278 time: Into::<u32>::into(time.into()) as _,
43279 };
43280 let cookie = self.send_void_request(request, true).with_span(span);
43281 cookie
43282 }
43283 #[cfg(feature = "xv")]
43284 fn xv_ungrab_port_checked<'this>(
43285 &'this mut self,
43286 port: types::Port,
43287 time: impl Into<types::Time>,
43288 ) -> futures::CheckedSendRequest<'this, Self, ()> {
43289 let request = types::xv::UngrabPortRequest {
43290 port,
43291 time: Into::<u32>::into(time.into()) as _,
43292 };
43293 let cookie = self.send_void_request(request, false);
43294 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
43295 res
43296 }
43297 #[cfg(feature = "xv")]
43298 fn xv_put_video<'this>(
43299 &'this mut self,
43300 port: types::Port,
43301 drawable: types::xproto::Drawable,
43302 gc: types::Gcontext,
43303 vid_x: types::Int16,
43304 vid_y: types::Int16,
43305 vid_w: types::Card16,
43306 vid_h: types::Card16,
43307 drw_x: types::Int16,
43308 drw_y: types::Int16,
43309 drw_w: types::Card16,
43310 drw_h: types::Card16,
43311 ) -> futures::SendRequest<'this, Self, ()> {
43312 let span = tracing::info_span!(
43313 "xv_put_video",
43314 port = ?port,
43315 drawable = ?drawable,
43316 gc = ?gc,
43317 vid_x = ?vid_x,
43318 vid_y = ?vid_y,
43319 vid_w = ?vid_w,
43320 vid_h = ?vid_h,
43321 drw_x = ?drw_x,
43322 drw_y = ?drw_y,
43323 drw_w = ?drw_w,
43324 drw_h = ?drw_h,
43325 );
43326 let request = types::xv::PutVideoRequest {
43327 port,
43328 drawable,
43329 gc,
43330 vid_x,
43331 vid_y,
43332 vid_w,
43333 vid_h,
43334 drw_x,
43335 drw_y,
43336 drw_w,
43337 drw_h,
43338 };
43339 let cookie = self.send_void_request(request, true).with_span(span);
43340 cookie
43341 }
43342 #[cfg(feature = "xv")]
43343 fn xv_put_video_checked<'this>(
43344 &'this mut self,
43345 port: types::Port,
43346 drawable: types::xproto::Drawable,
43347 gc: types::Gcontext,
43348 vid_x: types::Int16,
43349 vid_y: types::Int16,
43350 vid_w: types::Card16,
43351 vid_h: types::Card16,
43352 drw_x: types::Int16,
43353 drw_y: types::Int16,
43354 drw_w: types::Card16,
43355 drw_h: types::Card16,
43356 ) -> futures::CheckedSendRequest<'this, Self, ()> {
43357 let request = types::xv::PutVideoRequest {
43358 port,
43359 drawable,
43360 gc,
43361 vid_x,
43362 vid_y,
43363 vid_w,
43364 vid_h,
43365 drw_x,
43366 drw_y,
43367 drw_w,
43368 drw_h,
43369 };
43370 let cookie = self.send_void_request(request, false);
43371 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
43372 res
43373 }
43374 #[cfg(feature = "xv")]
43375 fn xv_put_still<'this>(
43376 &'this mut self,
43377 port: types::Port,
43378 drawable: types::xproto::Drawable,
43379 gc: types::Gcontext,
43380 vid_x: types::Int16,
43381 vid_y: types::Int16,
43382 vid_w: types::Card16,
43383 vid_h: types::Card16,
43384 drw_x: types::Int16,
43385 drw_y: types::Int16,
43386 drw_w: types::Card16,
43387 drw_h: types::Card16,
43388 ) -> futures::SendRequest<'this, Self, ()> {
43389 let span = tracing::info_span!(
43390 "xv_put_still",
43391 port = ?port,
43392 drawable = ?drawable,
43393 gc = ?gc,
43394 vid_x = ?vid_x,
43395 vid_y = ?vid_y,
43396 vid_w = ?vid_w,
43397 vid_h = ?vid_h,
43398 drw_x = ?drw_x,
43399 drw_y = ?drw_y,
43400 drw_w = ?drw_w,
43401 drw_h = ?drw_h,
43402 );
43403 let request = types::xv::PutStillRequest {
43404 port,
43405 drawable,
43406 gc,
43407 vid_x,
43408 vid_y,
43409 vid_w,
43410 vid_h,
43411 drw_x,
43412 drw_y,
43413 drw_w,
43414 drw_h,
43415 };
43416 let cookie = self.send_void_request(request, true).with_span(span);
43417 cookie
43418 }
43419 #[cfg(feature = "xv")]
43420 fn xv_put_still_checked<'this>(
43421 &'this mut self,
43422 port: types::Port,
43423 drawable: types::xproto::Drawable,
43424 gc: types::Gcontext,
43425 vid_x: types::Int16,
43426 vid_y: types::Int16,
43427 vid_w: types::Card16,
43428 vid_h: types::Card16,
43429 drw_x: types::Int16,
43430 drw_y: types::Int16,
43431 drw_w: types::Card16,
43432 drw_h: types::Card16,
43433 ) -> futures::CheckedSendRequest<'this, Self, ()> {
43434 let request = types::xv::PutStillRequest {
43435 port,
43436 drawable,
43437 gc,
43438 vid_x,
43439 vid_y,
43440 vid_w,
43441 vid_h,
43442 drw_x,
43443 drw_y,
43444 drw_w,
43445 drw_h,
43446 };
43447 let cookie = self.send_void_request(request, false);
43448 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
43449 res
43450 }
43451 #[cfg(feature = "xv")]
43452 fn xv_get_video<'this>(
43453 &'this mut self,
43454 port: types::Port,
43455 drawable: types::xproto::Drawable,
43456 gc: types::Gcontext,
43457 vid_x: types::Int16,
43458 vid_y: types::Int16,
43459 vid_w: types::Card16,
43460 vid_h: types::Card16,
43461 drw_x: types::Int16,
43462 drw_y: types::Int16,
43463 drw_w: types::Card16,
43464 drw_h: types::Card16,
43465 ) -> futures::SendRequest<'this, Self, ()> {
43466 let span = tracing::info_span!(
43467 "xv_get_video",
43468 port = ?port,
43469 drawable = ?drawable,
43470 gc = ?gc,
43471 vid_x = ?vid_x,
43472 vid_y = ?vid_y,
43473 vid_w = ?vid_w,
43474 vid_h = ?vid_h,
43475 drw_x = ?drw_x,
43476 drw_y = ?drw_y,
43477 drw_w = ?drw_w,
43478 drw_h = ?drw_h,
43479 );
43480 let request = types::xv::GetVideoRequest {
43481 port,
43482 drawable,
43483 gc,
43484 vid_x,
43485 vid_y,
43486 vid_w,
43487 vid_h,
43488 drw_x,
43489 drw_y,
43490 drw_w,
43491 drw_h,
43492 };
43493 let cookie = self.send_void_request(request, true).with_span(span);
43494 cookie
43495 }
43496 #[cfg(feature = "xv")]
43497 fn xv_get_video_checked<'this>(
43498 &'this mut self,
43499 port: types::Port,
43500 drawable: types::xproto::Drawable,
43501 gc: types::Gcontext,
43502 vid_x: types::Int16,
43503 vid_y: types::Int16,
43504 vid_w: types::Card16,
43505 vid_h: types::Card16,
43506 drw_x: types::Int16,
43507 drw_y: types::Int16,
43508 drw_w: types::Card16,
43509 drw_h: types::Card16,
43510 ) -> futures::CheckedSendRequest<'this, Self, ()> {
43511 let request = types::xv::GetVideoRequest {
43512 port,
43513 drawable,
43514 gc,
43515 vid_x,
43516 vid_y,
43517 vid_w,
43518 vid_h,
43519 drw_x,
43520 drw_y,
43521 drw_w,
43522 drw_h,
43523 };
43524 let cookie = self.send_void_request(request, false);
43525 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
43526 res
43527 }
43528 #[cfg(feature = "xv")]
43529 fn xv_get_still<'this>(
43530 &'this mut self,
43531 port: types::Port,
43532 drawable: types::xproto::Drawable,
43533 gc: types::Gcontext,
43534 vid_x: types::Int16,
43535 vid_y: types::Int16,
43536 vid_w: types::Card16,
43537 vid_h: types::Card16,
43538 drw_x: types::Int16,
43539 drw_y: types::Int16,
43540 drw_w: types::Card16,
43541 drw_h: types::Card16,
43542 ) -> futures::SendRequest<'this, Self, ()> {
43543 let span = tracing::info_span!(
43544 "xv_get_still",
43545 port = ?port,
43546 drawable = ?drawable,
43547 gc = ?gc,
43548 vid_x = ?vid_x,
43549 vid_y = ?vid_y,
43550 vid_w = ?vid_w,
43551 vid_h = ?vid_h,
43552 drw_x = ?drw_x,
43553 drw_y = ?drw_y,
43554 drw_w = ?drw_w,
43555 drw_h = ?drw_h,
43556 );
43557 let request = types::xv::GetStillRequest {
43558 port,
43559 drawable,
43560 gc,
43561 vid_x,
43562 vid_y,
43563 vid_w,
43564 vid_h,
43565 drw_x,
43566 drw_y,
43567 drw_w,
43568 drw_h,
43569 };
43570 let cookie = self.send_void_request(request, true).with_span(span);
43571 cookie
43572 }
43573 #[cfg(feature = "xv")]
43574 fn xv_get_still_checked<'this>(
43575 &'this mut self,
43576 port: types::Port,
43577 drawable: types::xproto::Drawable,
43578 gc: types::Gcontext,
43579 vid_x: types::Int16,
43580 vid_y: types::Int16,
43581 vid_w: types::Card16,
43582 vid_h: types::Card16,
43583 drw_x: types::Int16,
43584 drw_y: types::Int16,
43585 drw_w: types::Card16,
43586 drw_h: types::Card16,
43587 ) -> futures::CheckedSendRequest<'this, Self, ()> {
43588 let request = types::xv::GetStillRequest {
43589 port,
43590 drawable,
43591 gc,
43592 vid_x,
43593 vid_y,
43594 vid_w,
43595 vid_h,
43596 drw_x,
43597 drw_y,
43598 drw_w,
43599 drw_h,
43600 };
43601 let cookie = self.send_void_request(request, false);
43602 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
43603 res
43604 }
43605 #[cfg(feature = "xv")]
43606 fn xv_stop_video<'this>(
43607 &'this mut self,
43608 port: types::Port,
43609 drawable: types::xproto::Drawable,
43610 ) -> futures::SendRequest<'this, Self, ()> {
43611 let span = tracing::info_span!(
43612 "xv_stop_video",
43613 port = ?port,
43614 drawable = ?drawable,
43615 );
43616 let request = types::xv::StopVideoRequest { port, drawable };
43617 let cookie = self.send_void_request(request, true).with_span(span);
43618 cookie
43619 }
43620 #[cfg(feature = "xv")]
43621 fn xv_stop_video_checked<'this>(
43622 &'this mut self,
43623 port: types::Port,
43624 drawable: types::xproto::Drawable,
43625 ) -> futures::CheckedSendRequest<'this, Self, ()> {
43626 let request = types::xv::StopVideoRequest { port, drawable };
43627 let cookie = self.send_void_request(request, false);
43628 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
43629 res
43630 }
43631 #[cfg(feature = "xv")]
43632 fn xv_select_video_notify<'this>(
43633 &'this mut self,
43634 drawable: types::xproto::Drawable,
43635 onoff: types::Bool,
43636 ) -> futures::SendRequest<'this, Self, ()> {
43637 let span = tracing::info_span!(
43638 "xv_select_video_notify",
43639 drawable = ?drawable,
43640 onoff = ?onoff,
43641 );
43642 let request = types::xv::SelectVideoNotifyRequest { drawable, onoff };
43643 let cookie = self.send_void_request(request, true).with_span(span);
43644 cookie
43645 }
43646 #[cfg(feature = "xv")]
43647 fn xv_select_video_notify_checked<'this>(
43648 &'this mut self,
43649 drawable: types::xproto::Drawable,
43650 onoff: types::Bool,
43651 ) -> futures::CheckedSendRequest<'this, Self, ()> {
43652 let request = types::xv::SelectVideoNotifyRequest { drawable, onoff };
43653 let cookie = self.send_void_request(request, false);
43654 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
43655 res
43656 }
43657 #[cfg(feature = "xv")]
43658 fn xv_select_port_notify<'this>(
43659 &'this mut self,
43660 port: types::Port,
43661 onoff: types::Bool,
43662 ) -> futures::SendRequest<'this, Self, ()> {
43663 let span = tracing::info_span!(
43664 "xv_select_port_notify",
43665 port = ?port,
43666 onoff = ?onoff,
43667 );
43668 let request = types::xv::SelectPortNotifyRequest { port, onoff };
43669 let cookie = self.send_void_request(request, true).with_span(span);
43670 cookie
43671 }
43672 #[cfg(feature = "xv")]
43673 fn xv_select_port_notify_checked<'this>(
43674 &'this mut self,
43675 port: types::Port,
43676 onoff: types::Bool,
43677 ) -> futures::CheckedSendRequest<'this, Self, ()> {
43678 let request = types::xv::SelectPortNotifyRequest { port, onoff };
43679 let cookie = self.send_void_request(request, false);
43680 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
43681 res
43682 }
43683 #[cfg(feature = "xv")]
43684 fn xv_query_best_size<'this>(
43685 &'this mut self,
43686 port: types::Port,
43687 vid_w: types::Card16,
43688 vid_h: types::Card16,
43689 drw_w: types::Card16,
43690 drw_h: types::Card16,
43691 motion: types::Bool,
43692 ) -> futures::SendRequest<'this, Self, types::xv::QueryBestSizeReply> {
43693 let span = tracing::info_span!(
43694 "xv_query_best_size",
43695 port = ?port,
43696 vid_w = ?vid_w,
43697 vid_h = ?vid_h,
43698 drw_w = ?drw_w,
43699 drw_h = ?drw_h,
43700 motion = ?motion,
43701 );
43702 let request = types::xv::QueryBestSizeRequest {
43703 port,
43704 vid_w,
43705 vid_h,
43706 drw_w,
43707 drw_h,
43708 motion,
43709 };
43710 let cookie = self.send_reply_request(request).with_span(span);
43711 cookie
43712 }
43713 #[cfg(feature = "xv")]
43714 fn xv_query_best_size_immediate<'this>(
43715 &'this mut self,
43716 port: types::Port,
43717 vid_w: types::Card16,
43718 vid_h: types::Card16,
43719 drw_w: types::Card16,
43720 drw_h: types::Card16,
43721 motion: types::Bool,
43722 ) -> futures::CheckedSendRequest<'this, Self, types::xv::QueryBestSizeReply> {
43723 let request = types::xv::QueryBestSizeRequest {
43724 port,
43725 vid_w,
43726 vid_h,
43727 drw_w,
43728 drw_h,
43729 motion,
43730 };
43731 let cookie = self.send_reply_request(request);
43732 let res: futures::CheckedSendRequest<'this, Self, types::xv::QueryBestSizeReply> =
43733 cookie.into();
43734 res
43735 }
43736 #[cfg(feature = "xv")]
43737 fn xv_set_port_attribute<'this>(
43738 &'this mut self,
43739 port: types::Port,
43740 attribute: types::Atom,
43741 value: types::Int32,
43742 ) -> futures::SendRequest<'this, Self, ()> {
43743 let span = tracing::info_span!(
43744 "xv_set_port_attribute",
43745 port = ?port,
43746 attribute = ?attribute,
43747 value = ?value,
43748 );
43749 let request = types::xv::SetPortAttributeRequest {
43750 port,
43751 attribute,
43752 value,
43753 };
43754 let cookie = self.send_void_request(request, true).with_span(span);
43755 cookie
43756 }
43757 #[cfg(feature = "xv")]
43758 fn xv_set_port_attribute_checked<'this>(
43759 &'this mut self,
43760 port: types::Port,
43761 attribute: types::Atom,
43762 value: types::Int32,
43763 ) -> futures::CheckedSendRequest<'this, Self, ()> {
43764 let request = types::xv::SetPortAttributeRequest {
43765 port,
43766 attribute,
43767 value,
43768 };
43769 let cookie = self.send_void_request(request, false);
43770 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
43771 res
43772 }
43773 #[cfg(feature = "xv")]
43774 fn xv_get_port_attribute<'this>(
43775 &'this mut self,
43776 port: types::Port,
43777 attribute: types::Atom,
43778 ) -> futures::SendRequest<'this, Self, types::xv::GetPortAttributeReply> {
43779 let span = tracing::info_span!(
43780 "xv_get_port_attribute",
43781 port = ?port,
43782 attribute = ?attribute,
43783 );
43784 let request = types::xv::GetPortAttributeRequest { port, attribute };
43785 let cookie = self.send_reply_request(request).with_span(span);
43786 cookie
43787 }
43788 #[cfg(feature = "xv")]
43789 fn xv_get_port_attribute_immediate<'this>(
43790 &'this mut self,
43791 port: types::Port,
43792 attribute: types::Atom,
43793 ) -> futures::CheckedSendRequest<'this, Self, types::xv::GetPortAttributeReply> {
43794 let request = types::xv::GetPortAttributeRequest { port, attribute };
43795 let cookie = self.send_reply_request(request);
43796 let res: futures::CheckedSendRequest<'this, Self, types::xv::GetPortAttributeReply> =
43797 cookie.into();
43798 res
43799 }
43800 #[cfg(feature = "xv")]
43801 fn xv_query_port_attributes<'this>(
43802 &'this mut self,
43803 port: types::Port,
43804 ) -> futures::SendRequest<'this, Self, types::xv::QueryPortAttributesReply> {
43805 let span = tracing::info_span!(
43806 "xv_query_port_attributes",
43807 port = ?port,
43808 );
43809 let request = types::xv::QueryPortAttributesRequest { port };
43810 let cookie = self.send_reply_request(request).with_span(span);
43811 cookie
43812 }
43813 #[cfg(feature = "xv")]
43814 fn xv_query_port_attributes_immediate<'this>(
43815 &'this mut self,
43816 port: types::Port,
43817 ) -> futures::CheckedSendRequest<'this, Self, types::xv::QueryPortAttributesReply> {
43818 let request = types::xv::QueryPortAttributesRequest { port };
43819 let cookie = self.send_reply_request(request);
43820 let res: futures::CheckedSendRequest<'this, Self, types::xv::QueryPortAttributesReply> =
43821 cookie.into();
43822 res
43823 }
43824 #[cfg(feature = "xv")]
43825 fn xv_list_image_formats<'this>(
43826 &'this mut self,
43827 port: types::Port,
43828 ) -> futures::SendRequest<'this, Self, types::xv::ListImageFormatsReply> {
43829 let span = tracing::info_span!(
43830 "xv_list_image_formats",
43831 port = ?port,
43832 );
43833 let request = types::xv::ListImageFormatsRequest { port };
43834 let cookie = self.send_reply_request(request).with_span(span);
43835 cookie
43836 }
43837 #[cfg(feature = "xv")]
43838 fn xv_list_image_formats_immediate<'this>(
43839 &'this mut self,
43840 port: types::Port,
43841 ) -> futures::CheckedSendRequest<'this, Self, types::xv::ListImageFormatsReply> {
43842 let request = types::xv::ListImageFormatsRequest { port };
43843 let cookie = self.send_reply_request(request);
43844 let res: futures::CheckedSendRequest<'this, Self, types::xv::ListImageFormatsReply> =
43845 cookie.into();
43846 res
43847 }
43848 #[cfg(feature = "xv")]
43849 fn xv_query_image_attributes<'this>(
43850 &'this mut self,
43851 port: types::Port,
43852 id: types::Card32,
43853 width: types::Card16,
43854 height: types::Card16,
43855 ) -> futures::SendRequest<'this, Self, types::xv::QueryImageAttributesReply> {
43856 let span = tracing::info_span!(
43857 "xv_query_image_attributes",
43858 port = ?port,
43859 id = ?id,
43860 width = ?width,
43861 height = ?height,
43862 );
43863 let request = types::xv::QueryImageAttributesRequest {
43864 port,
43865 id,
43866 width,
43867 height,
43868 };
43869 let cookie = self.send_reply_request(request).with_span(span);
43870 cookie
43871 }
43872 #[cfg(feature = "xv")]
43873 fn xv_query_image_attributes_immediate<'this>(
43874 &'this mut self,
43875 port: types::Port,
43876 id: types::Card32,
43877 width: types::Card16,
43878 height: types::Card16,
43879 ) -> futures::CheckedSendRequest<'this, Self, types::xv::QueryImageAttributesReply> {
43880 let request = types::xv::QueryImageAttributesRequest {
43881 port,
43882 id,
43883 width,
43884 height,
43885 };
43886 let cookie = self.send_reply_request(request);
43887 let res: futures::CheckedSendRequest<'this, Self, types::xv::QueryImageAttributesReply> =
43888 cookie.into();
43889 res
43890 }
43891 #[cfg(feature = "xv")]
43892 fn xv_put_image<'this>(
43893 &'this mut self,
43894 port: types::Port,
43895 drawable: types::xproto::Drawable,
43896 gc: types::Gcontext,
43897 id: types::Card32,
43898 src_x: types::Int16,
43899 src_y: types::Int16,
43900 src_w: types::Card16,
43901 src_h: types::Card16,
43902 drw_x: types::Int16,
43903 drw_y: types::Int16,
43904 drw_w: types::Card16,
43905 drw_h: types::Card16,
43906 width: types::Card16,
43907 height: types::Card16,
43908 data: impl AsRef<[types::Card8]>,
43909 ) -> futures::SendRequest<'this, Self, ()> {
43910 let span = tracing::info_span!(
43911 "xv_put_image",
43912 port = ?port,
43913 drawable = ?drawable,
43914 gc = ?gc,
43915 id = ?id,
43916 src_x = ?src_x,
43917 src_y = ?src_y,
43918 src_w = ?src_w,
43919 src_h = ?src_h,
43920 drw_x = ?drw_x,
43921 drw_y = ?drw_y,
43922 drw_w = ?drw_w,
43923 drw_h = ?drw_h,
43924 width = ?width,
43925 height = ?height,
43926 );
43927 let request = types::xv::PutImageRequest {
43928 port,
43929 drawable,
43930 gc,
43931 id,
43932 src_x,
43933 src_y,
43934 src_w,
43935 src_h,
43936 drw_x,
43937 drw_y,
43938 drw_w,
43939 drw_h,
43940 width,
43941 height,
43942 data: Cow::Borrowed(data.as_ref()),
43943 };
43944 let cookie = self.send_void_request(request, true).with_span(span);
43945 cookie
43946 }
43947 #[cfg(feature = "xv")]
43948 fn xv_put_image_checked<'this>(
43949 &'this mut self,
43950 port: types::Port,
43951 drawable: types::xproto::Drawable,
43952 gc: types::Gcontext,
43953 id: types::Card32,
43954 src_x: types::Int16,
43955 src_y: types::Int16,
43956 src_w: types::Card16,
43957 src_h: types::Card16,
43958 drw_x: types::Int16,
43959 drw_y: types::Int16,
43960 drw_w: types::Card16,
43961 drw_h: types::Card16,
43962 width: types::Card16,
43963 height: types::Card16,
43964 data: impl AsRef<[types::Card8]>,
43965 ) -> futures::CheckedSendRequest<'this, Self, ()> {
43966 let request = types::xv::PutImageRequest {
43967 port,
43968 drawable,
43969 gc,
43970 id,
43971 src_x,
43972 src_y,
43973 src_w,
43974 src_h,
43975 drw_x,
43976 drw_y,
43977 drw_w,
43978 drw_h,
43979 width,
43980 height,
43981 data: Cow::Borrowed(data.as_ref()),
43982 };
43983 let cookie = self.send_void_request(request, false);
43984 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
43985 res
43986 }
43987 #[cfg(feature = "xv")]
43988 fn xv_shm_put_image<'this>(
43989 &'this mut self,
43990 port: types::Port,
43991 drawable: types::xproto::Drawable,
43992 gc: types::Gcontext,
43993 shmseg: types::Seg,
43994 id: types::Card32,
43995 offset: types::Card32,
43996 src_x: types::Int16,
43997 src_y: types::Int16,
43998 src_w: types::Card16,
43999 src_h: types::Card16,
44000 drw_x: types::Int16,
44001 drw_y: types::Int16,
44002 drw_w: types::Card16,
44003 drw_h: types::Card16,
44004 width: types::Card16,
44005 height: types::Card16,
44006 send_event: types::Card8,
44007 ) -> futures::SendRequest<'this, Self, ()> {
44008 let span = tracing::info_span!(
44009 "xv_shm_put_image",
44010 port = ?port,
44011 drawable = ?drawable,
44012 gc = ?gc,
44013 shmseg = ?shmseg,
44014 id = ?id,
44015 offset = ?offset,
44016 src_x = ?src_x,
44017 src_y = ?src_y,
44018 src_w = ?src_w,
44019 src_h = ?src_h,
44020 drw_x = ?drw_x,
44021 drw_y = ?drw_y,
44022 drw_w = ?drw_w,
44023 drw_h = ?drw_h,
44024 width = ?width,
44025 height = ?height,
44026 send_event = ?send_event,
44027 );
44028 let request = types::xv::ShmPutImageRequest {
44029 port,
44030 drawable,
44031 gc,
44032 shmseg,
44033 id,
44034 offset,
44035 src_x,
44036 src_y,
44037 src_w,
44038 src_h,
44039 drw_x,
44040 drw_y,
44041 drw_w,
44042 drw_h,
44043 width,
44044 height,
44045 send_event,
44046 };
44047 let cookie = self.send_void_request(request, true).with_span(span);
44048 cookie
44049 }
44050 #[cfg(feature = "xv")]
44051 fn xv_shm_put_image_checked<'this>(
44052 &'this mut self,
44053 port: types::Port,
44054 drawable: types::xproto::Drawable,
44055 gc: types::Gcontext,
44056 shmseg: types::Seg,
44057 id: types::Card32,
44058 offset: types::Card32,
44059 src_x: types::Int16,
44060 src_y: types::Int16,
44061 src_w: types::Card16,
44062 src_h: types::Card16,
44063 drw_x: types::Int16,
44064 drw_y: types::Int16,
44065 drw_w: types::Card16,
44066 drw_h: types::Card16,
44067 width: types::Card16,
44068 height: types::Card16,
44069 send_event: types::Card8,
44070 ) -> futures::CheckedSendRequest<'this, Self, ()> {
44071 let request = types::xv::ShmPutImageRequest {
44072 port,
44073 drawable,
44074 gc,
44075 shmseg,
44076 id,
44077 offset,
44078 src_x,
44079 src_y,
44080 src_w,
44081 src_h,
44082 drw_x,
44083 drw_y,
44084 drw_w,
44085 drw_h,
44086 width,
44087 height,
44088 send_event,
44089 };
44090 let cookie = self.send_void_request(request, false);
44091 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
44092 res
44093 }
44094
44095 #[cfg(feature = "xvmc")]
44096 fn xvmc_query_version<'this>(
44097 &'this mut self,
44098 ) -> futures::SendRequest<'this, Self, types::xvmc::QueryVersionReply> {
44099 let span = tracing::info_span!("xvmc_query_version",);
44100 let request = types::xvmc::QueryVersionRequest {};
44101 let cookie = self.send_reply_request(request).with_span(span);
44102 cookie
44103 }
44104 #[cfg(feature = "xvmc")]
44105 fn xvmc_query_version_immediate<'this>(
44106 &'this mut self,
44107 ) -> futures::CheckedSendRequest<'this, Self, types::xvmc::QueryVersionReply> {
44108 let request = types::xvmc::QueryVersionRequest {};
44109 let cookie = self.send_reply_request(request);
44110 let res: futures::CheckedSendRequest<'this, Self, types::xvmc::QueryVersionReply> =
44111 cookie.into();
44112 res
44113 }
44114 #[cfg(feature = "xvmc")]
44115 fn xvmc_list_surface_types<'this>(
44116 &'this mut self,
44117 port_id: types::Port,
44118 ) -> futures::SendRequest<'this, Self, types::xvmc::ListSurfaceTypesReply> {
44119 let span = tracing::info_span!(
44120 "xvmc_list_surface_types",
44121 port_id = ?port_id,
44122 );
44123 let request = types::xvmc::ListSurfaceTypesRequest { port_id };
44124 let cookie = self.send_reply_request(request).with_span(span);
44125 cookie
44126 }
44127 #[cfg(feature = "xvmc")]
44128 fn xvmc_list_surface_types_immediate<'this>(
44129 &'this mut self,
44130 port_id: types::Port,
44131 ) -> futures::CheckedSendRequest<'this, Self, types::xvmc::ListSurfaceTypesReply> {
44132 let request = types::xvmc::ListSurfaceTypesRequest { port_id };
44133 let cookie = self.send_reply_request(request);
44134 let res: futures::CheckedSendRequest<'this, Self, types::xvmc::ListSurfaceTypesReply> =
44135 cookie.into();
44136 res
44137 }
44138 #[cfg(feature = "xvmc")]
44139 fn xvmc_create_context<'this>(
44140 &'this mut self,
44141 context_id: types::xvmc::Context,
44142 port_id: types::Port,
44143 surface_id: types::Surface,
44144 width: types::Card16,
44145 height: types::Card16,
44146 flags: types::Card32,
44147 ) -> futures::SendRequest<'this, Self, types::xvmc::CreateContextReply> {
44148 let span = tracing::info_span!(
44149 "xvmc_create_context",
44150 context_id = ?context_id,
44151 port_id = ?port_id,
44152 surface_id = ?surface_id,
44153 width = ?width,
44154 height = ?height,
44155 flags = ?flags,
44156 );
44157 let request = types::xvmc::CreateContextRequest {
44158 context_id,
44159 port_id,
44160 surface_id,
44161 width,
44162 height,
44163 flags,
44164 };
44165 let cookie = self.send_reply_request(request).with_span(span);
44166 cookie
44167 }
44168 #[cfg(feature = "xvmc")]
44169 fn xvmc_create_context_immediate<'this>(
44170 &'this mut self,
44171 context_id: types::xvmc::Context,
44172 port_id: types::Port,
44173 surface_id: types::Surface,
44174 width: types::Card16,
44175 height: types::Card16,
44176 flags: types::Card32,
44177 ) -> futures::CheckedSendRequest<'this, Self, types::xvmc::CreateContextReply> {
44178 let request = types::xvmc::CreateContextRequest {
44179 context_id,
44180 port_id,
44181 surface_id,
44182 width,
44183 height,
44184 flags,
44185 };
44186 let cookie = self.send_reply_request(request);
44187 let res: futures::CheckedSendRequest<'this, Self, types::xvmc::CreateContextReply> =
44188 cookie.into();
44189 res
44190 }
44191 #[cfg(feature = "xvmc")]
44192 fn xvmc_destroy_context<'this>(
44193 &'this mut self,
44194 context_id: types::xvmc::Context,
44195 ) -> futures::SendRequest<'this, Self, ()> {
44196 let span = tracing::info_span!(
44197 "xvmc_destroy_context",
44198 context_id = ?context_id,
44199 );
44200 let request = types::xvmc::DestroyContextRequest { context_id };
44201 let cookie = self.send_void_request(request, true).with_span(span);
44202 cookie
44203 }
44204 #[cfg(feature = "xvmc")]
44205 fn xvmc_destroy_context_checked<'this>(
44206 &'this mut self,
44207 context_id: types::xvmc::Context,
44208 ) -> futures::CheckedSendRequest<'this, Self, ()> {
44209 let request = types::xvmc::DestroyContextRequest { context_id };
44210 let cookie = self.send_void_request(request, false);
44211 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
44212 res
44213 }
44214 #[cfg(feature = "xvmc")]
44215 fn xvmc_create_surface<'this>(
44216 &'this mut self,
44217 surface_id: types::Surface,
44218 context_id: types::xvmc::Context,
44219 ) -> futures::SendRequest<'this, Self, types::xvmc::CreateSurfaceReply> {
44220 let span = tracing::info_span!(
44221 "xvmc_create_surface",
44222 surface_id = ?surface_id,
44223 context_id = ?context_id,
44224 );
44225 let request = types::xvmc::CreateSurfaceRequest {
44226 surface_id,
44227 context_id,
44228 };
44229 let cookie = self.send_reply_request(request).with_span(span);
44230 cookie
44231 }
44232 #[cfg(feature = "xvmc")]
44233 fn xvmc_create_surface_immediate<'this>(
44234 &'this mut self,
44235 surface_id: types::Surface,
44236 context_id: types::xvmc::Context,
44237 ) -> futures::CheckedSendRequest<'this, Self, types::xvmc::CreateSurfaceReply> {
44238 let request = types::xvmc::CreateSurfaceRequest {
44239 surface_id,
44240 context_id,
44241 };
44242 let cookie = self.send_reply_request(request);
44243 let res: futures::CheckedSendRequest<'this, Self, types::xvmc::CreateSurfaceReply> =
44244 cookie.into();
44245 res
44246 }
44247 #[cfg(feature = "xvmc")]
44248 fn xvmc_destroy_surface<'this>(
44249 &'this mut self,
44250 surface_id: types::Surface,
44251 ) -> futures::SendRequest<'this, Self, ()> {
44252 let span = tracing::info_span!(
44253 "xvmc_destroy_surface",
44254 surface_id = ?surface_id,
44255 );
44256 let request = types::xvmc::DestroySurfaceRequest { surface_id };
44257 let cookie = self.send_void_request(request, true).with_span(span);
44258 cookie
44259 }
44260 #[cfg(feature = "xvmc")]
44261 fn xvmc_destroy_surface_checked<'this>(
44262 &'this mut self,
44263 surface_id: types::Surface,
44264 ) -> futures::CheckedSendRequest<'this, Self, ()> {
44265 let request = types::xvmc::DestroySurfaceRequest { surface_id };
44266 let cookie = self.send_void_request(request, false);
44267 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
44268 res
44269 }
44270 #[cfg(feature = "xvmc")]
44271 fn xvmc_create_subpicture<'this>(
44272 &'this mut self,
44273 subpicture_id: types::Subpicture,
44274 context: types::xvmc::Context,
44275 xvimage_id: types::Card32,
44276 width: types::Card16,
44277 height: types::Card16,
44278 ) -> futures::SendRequest<'this, Self, types::xvmc::CreateSubpictureReply> {
44279 let span = tracing::info_span!(
44280 "xvmc_create_subpicture",
44281 subpicture_id = ?subpicture_id,
44282 context = ?context,
44283 xvimage_id = ?xvimage_id,
44284 width = ?width,
44285 height = ?height,
44286 );
44287 let request = types::xvmc::CreateSubpictureRequest {
44288 subpicture_id,
44289 context,
44290 xvimage_id,
44291 width,
44292 height,
44293 };
44294 let cookie = self.send_reply_request(request).with_span(span);
44295 cookie
44296 }
44297 #[cfg(feature = "xvmc")]
44298 fn xvmc_create_subpicture_immediate<'this>(
44299 &'this mut self,
44300 subpicture_id: types::Subpicture,
44301 context: types::xvmc::Context,
44302 xvimage_id: types::Card32,
44303 width: types::Card16,
44304 height: types::Card16,
44305 ) -> futures::CheckedSendRequest<'this, Self, types::xvmc::CreateSubpictureReply> {
44306 let request = types::xvmc::CreateSubpictureRequest {
44307 subpicture_id,
44308 context,
44309 xvimage_id,
44310 width,
44311 height,
44312 };
44313 let cookie = self.send_reply_request(request);
44314 let res: futures::CheckedSendRequest<'this, Self, types::xvmc::CreateSubpictureReply> =
44315 cookie.into();
44316 res
44317 }
44318 #[cfg(feature = "xvmc")]
44319 fn xvmc_destroy_subpicture<'this>(
44320 &'this mut self,
44321 subpicture_id: types::Subpicture,
44322 ) -> futures::SendRequest<'this, Self, ()> {
44323 let span = tracing::info_span!(
44324 "xvmc_destroy_subpicture",
44325 subpicture_id = ?subpicture_id,
44326 );
44327 let request = types::xvmc::DestroySubpictureRequest { subpicture_id };
44328 let cookie = self.send_void_request(request, true).with_span(span);
44329 cookie
44330 }
44331 #[cfg(feature = "xvmc")]
44332 fn xvmc_destroy_subpicture_checked<'this>(
44333 &'this mut self,
44334 subpicture_id: types::Subpicture,
44335 ) -> futures::CheckedSendRequest<'this, Self, ()> {
44336 let request = types::xvmc::DestroySubpictureRequest { subpicture_id };
44337 let cookie = self.send_void_request(request, false);
44338 let res: futures::CheckedSendRequest<'this, Self, ()> = cookie.into();
44339 res
44340 }
44341 #[cfg(feature = "xvmc")]
44342 fn xvmc_list_subpicture_types<'this>(
44343 &'this mut self,
44344 port_id: types::Port,
44345 surface_id: types::Surface,
44346 ) -> futures::SendRequest<'this, Self, types::xvmc::ListSubpictureTypesReply> {
44347 let span = tracing::info_span!(
44348 "xvmc_list_subpicture_types",
44349 port_id = ?port_id,
44350 surface_id = ?surface_id,
44351 );
44352 let request = types::xvmc::ListSubpictureTypesRequest {
44353 port_id,
44354 surface_id,
44355 };
44356 let cookie = self.send_reply_request(request).with_span(span);
44357 cookie
44358 }
44359 #[cfg(feature = "xvmc")]
44360 fn xvmc_list_subpicture_types_immediate<'this>(
44361 &'this mut self,
44362 port_id: types::Port,
44363 surface_id: types::Surface,
44364 ) -> futures::CheckedSendRequest<'this, Self, types::xvmc::ListSubpictureTypesReply> {
44365 let request = types::xvmc::ListSubpictureTypesRequest {
44366 port_id,
44367 surface_id,
44368 };
44369 let cookie = self.send_reply_request(request);
44370 let res: futures::CheckedSendRequest<'this, Self, types::xvmc::ListSubpictureTypesReply> =
44371 cookie.into();
44372 res
44373 }
44374}
44375
44376impl<D: Display + ?Sized> DisplayFunctionsExt for D {}
44377
44378#[cfg(feature = "async")]
44379impl<D: AsyncDisplay + ?Sized> AsyncDisplayFunctionsExt for D {}
44380
44381mod __private {
44382 use crate::display::Display;
44383
44384 pub trait Sealed {
44385 fn __sealed_trait_marker() {}
44386 }
44387
44388 impl<D: Display + ?Sized> Sealed for D {}
44389
44390 cfg_async! {
44391 use crate::display::AsyncDisplay;
44392
44393 pub trait Sealed2 {
44394 fn __sealed_trait_marker() {}
44395 }
44396
44397 impl<D: AsyncDisplay + ?Sized> Sealed2 for D {}
44398 }
44399}
44400
44401#[allow(dead_code, unused_imports)]
44402mod types {
44403 pub(crate) type Card8 = u8;
44404 pub(crate) type Card16 = u16;
44405 pub(crate) type Card32 = u32;
44406 pub(crate) type Card64 = u64;
44407 pub(crate) type Bool = bool;
44408 pub(crate) type Char = u8;
44409 pub(crate) type Byte = u8;
44410 pub(crate) type Int8 = i8;
44411 pub(crate) type Int16 = i16;
44412 pub(crate) type Int32 = i32;
44413 pub(crate) type Float = f32;
44414 pub(crate) type Double = f64;
44415 pub(crate) type Void = u8;
44416
44417 pub(crate) use crate::protocol::bigreq::{self, *};
44418 #[cfg(feature = "composite")]
44419 pub(crate) use crate::protocol::composite::{self, *};
44420 #[cfg(feature = "damage")]
44421 pub(crate) use crate::protocol::damage::{self, *};
44422 #[cfg(feature = "dpms")]
44423 pub(crate) use crate::protocol::dpms::{self, *};
44424 #[cfg(feature = "dri2")]
44425 pub(crate) use crate::protocol::dri2::{self, *};
44426 #[cfg(feature = "dri3")]
44427 pub(crate) use crate::protocol::dri3::{self, *};
44428 pub(crate) use crate::protocol::ge::{self, *};
44429 #[cfg(feature = "glx")]
44430 pub(crate) use crate::protocol::glx::{self, *};
44431 #[cfg(feature = "present")]
44432 pub(crate) use crate::protocol::present::{self, *};
44433 #[cfg(feature = "randr")]
44434 pub(crate) use crate::protocol::randr::{self, *};
44435 #[cfg(feature = "record")]
44436 pub(crate) use crate::protocol::record::{self, *};
44437 #[cfg(feature = "render")]
44438 pub(crate) use crate::protocol::render::{self, *};
44439 #[cfg(feature = "res")]
44440 pub(crate) use crate::protocol::res::{self, *};
44441 #[cfg(feature = "screensaver")]
44442 pub(crate) use crate::protocol::screensaver::{self, *};
44443 #[cfg(feature = "shape")]
44444 pub(crate) use crate::protocol::shape::{self, *};
44445 #[cfg(feature = "shm")]
44446 pub(crate) use crate::protocol::shm::{self, *};
44447 #[cfg(feature = "sync")]
44448 pub(crate) use crate::protocol::sync::{self, *};
44449 pub(crate) use crate::protocol::xc_misc::{self, *};
44450 #[cfg(feature = "xevie")]
44451 pub(crate) use crate::protocol::xevie::{self, *};
44452 #[cfg(feature = "xf86dri")]
44453 pub(crate) use crate::protocol::xf86dri::{self, *};
44454 #[cfg(feature = "xf86vidmode")]
44455 pub(crate) use crate::protocol::xf86vidmode::{self, *};
44456 #[cfg(feature = "xfixes")]
44457 pub(crate) use crate::protocol::xfixes::{self, *};
44458 #[cfg(feature = "xinerama")]
44459 pub(crate) use crate::protocol::xinerama::{self, *};
44460 #[cfg(feature = "xinput")]
44461 pub(crate) use crate::protocol::xinput::{self, *};
44462 #[cfg(feature = "xkb")]
44463 pub(crate) use crate::protocol::xkb::{self, *};
44464 #[cfg(feature = "xprint")]
44465 pub(crate) use crate::protocol::xprint::{self, *};
44466 pub(crate) use crate::protocol::xproto::{self, *};
44467 #[cfg(feature = "xselinux")]
44468 pub(crate) use crate::protocol::xselinux::{self, *};
44469 #[cfg(feature = "xtest")]
44470 pub(crate) use crate::protocol::xtest::{self, *};
44471 #[cfg(feature = "xv")]
44472 pub(crate) use crate::protocol::xv::{self, *};
44473 #[cfg(feature = "xvmc")]
44474 pub(crate) use crate::protocol::xvmc::{self, *};
44475 pub(crate) use crate::Fd;
44476}