Wayland++  0.2.6
C++ Bindings for Wayland
wayland-client-protocol-extra.cpp
1 #include <wayland-client-protocol-extra.hpp>
2 
3 using namespace wayland;
4 using namespace detail;
5 
6 const wl_interface* presentation_interface_destroy_request[0] = {
7 };
8 
9 const wl_interface* presentation_interface_feedback_request[2] = {
10  &surface_interface,
11  &presentation_feedback_interface,
12 };
13 
14 const wl_interface* presentation_interface_clock_id_event[1] = {
15  nullptr,
16 };
17 
18 const wl_message presentation_interface_requests[2] = {
19  {
20  "destroy",
21  "",
22  presentation_interface_destroy_request,
23  },
24  {
25  "feedback",
26  "on",
27  presentation_interface_feedback_request,
28  },
29 };
30 
31 const wl_message presentation_interface_events[1] = {
32  {
33  "clock_id",
34  "u",
35  presentation_interface_clock_id_event,
36  },
37 };
38 
39 const wl_interface wayland::detail::presentation_interface =
40  {
41  "wp_presentation",
42  1,
43  2,
44  presentation_interface_requests,
45  1,
46  presentation_interface_events,
47  };
48 
49 const wl_interface* presentation_feedback_interface_sync_output_event[1] = {
50  &output_interface,
51 };
52 
53 const wl_interface* presentation_feedback_interface_presented_event[7] = {
54  nullptr,
55  nullptr,
56  nullptr,
57  nullptr,
58  nullptr,
59  nullptr,
60  nullptr,
61 };
62 
63 const wl_interface* presentation_feedback_interface_discarded_event[0] = {
64 };
65 
66 const wl_message presentation_feedback_interface_requests[0] = {
67 };
68 
69 const wl_message presentation_feedback_interface_events[3] = {
70  {
71  "sync_output",
72  "o",
73  presentation_feedback_interface_sync_output_event,
74  },
75  {
76  "presented",
77  "uuuuuuu",
78  presentation_feedback_interface_presented_event,
79  },
80  {
81  "discarded",
82  "",
83  presentation_feedback_interface_discarded_event,
84  },
85 };
86 
87 const wl_interface wayland::detail::presentation_feedback_interface =
88  {
89  "wp_presentation_feedback",
90  1,
91  0,
92  presentation_feedback_interface_requests,
93  3,
94  presentation_feedback_interface_events,
95  };
96 
97 const wl_interface* viewporter_interface_destroy_request[0] = {
98 };
99 
100 const wl_interface* viewporter_interface_get_viewport_request[2] = {
101  &viewport_interface,
102  &surface_interface,
103 };
104 
105 const wl_message viewporter_interface_requests[2] = {
106  {
107  "destroy",
108  "",
109  viewporter_interface_destroy_request,
110  },
111  {
112  "get_viewport",
113  "no",
114  viewporter_interface_get_viewport_request,
115  },
116 };
117 
118 const wl_message viewporter_interface_events[0] = {
119 };
120 
121 const wl_interface wayland::detail::viewporter_interface =
122  {
123  "wp_viewporter",
124  1,
125  2,
126  viewporter_interface_requests,
127  0,
128  viewporter_interface_events,
129  };
130 
131 const wl_interface* viewport_interface_destroy_request[0] = {
132 };
133 
134 const wl_interface* viewport_interface_set_source_request[4] = {
135  nullptr,
136  nullptr,
137  nullptr,
138  nullptr,
139 };
140 
141 const wl_interface* viewport_interface_set_destination_request[2] = {
142  nullptr,
143  nullptr,
144 };
145 
146 const wl_message viewport_interface_requests[3] = {
147  {
148  "destroy",
149  "",
150  viewport_interface_destroy_request,
151  },
152  {
153  "set_source",
154  "ffff",
155  viewport_interface_set_source_request,
156  },
157  {
158  "set_destination",
159  "ii",
160  viewport_interface_set_destination_request,
161  },
162 };
163 
164 const wl_message viewport_interface_events[0] = {
165 };
166 
167 const wl_interface wayland::detail::viewport_interface =
168  {
169  "wp_viewport",
170  1,
171  3,
172  viewport_interface_requests,
173  0,
174  viewport_interface_events,
175  };
176 
177 const wl_interface* xdg_wm_base_interface_destroy_request[0] = {
178 };
179 
180 const wl_interface* xdg_wm_base_interface_create_positioner_request[1] = {
181  &xdg_positioner_interface,
182 };
183 
184 const wl_interface* xdg_wm_base_interface_get_xdg_surface_request[2] = {
185  &xdg_surface_interface,
186  &surface_interface,
187 };
188 
189 const wl_interface* xdg_wm_base_interface_pong_request[1] = {
190  nullptr,
191 };
192 
193 const wl_interface* xdg_wm_base_interface_ping_event[1] = {
194  nullptr,
195 };
196 
197 const wl_message xdg_wm_base_interface_requests[4] = {
198  {
199  "destroy",
200  "",
201  xdg_wm_base_interface_destroy_request,
202  },
203  {
204  "create_positioner",
205  "n",
206  xdg_wm_base_interface_create_positioner_request,
207  },
208  {
209  "get_xdg_surface",
210  "no",
211  xdg_wm_base_interface_get_xdg_surface_request,
212  },
213  {
214  "pong",
215  "u",
216  xdg_wm_base_interface_pong_request,
217  },
218 };
219 
220 const wl_message xdg_wm_base_interface_events[1] = {
221  {
222  "ping",
223  "u",
224  xdg_wm_base_interface_ping_event,
225  },
226 };
227 
228 const wl_interface wayland::detail::xdg_wm_base_interface =
229  {
230  "xdg_wm_base",
231  2,
232  4,
233  xdg_wm_base_interface_requests,
234  1,
235  xdg_wm_base_interface_events,
236  };
237 
238 const wl_interface* xdg_positioner_interface_destroy_request[0] = {
239 };
240 
241 const wl_interface* xdg_positioner_interface_set_size_request[2] = {
242  nullptr,
243  nullptr,
244 };
245 
246 const wl_interface* xdg_positioner_interface_set_anchor_rect_request[4] = {
247  nullptr,
248  nullptr,
249  nullptr,
250  nullptr,
251 };
252 
253 const wl_interface* xdg_positioner_interface_set_anchor_request[1] = {
254  nullptr,
255 };
256 
257 const wl_interface* xdg_positioner_interface_set_gravity_request[1] = {
258  nullptr,
259 };
260 
261 const wl_interface* xdg_positioner_interface_set_constraint_adjustment_request[1] = {
262  nullptr,
263 };
264 
265 const wl_interface* xdg_positioner_interface_set_offset_request[2] = {
266  nullptr,
267  nullptr,
268 };
269 
270 const wl_message xdg_positioner_interface_requests[7] = {
271  {
272  "destroy",
273  "",
274  xdg_positioner_interface_destroy_request,
275  },
276  {
277  "set_size",
278  "ii",
279  xdg_positioner_interface_set_size_request,
280  },
281  {
282  "set_anchor_rect",
283  "iiii",
284  xdg_positioner_interface_set_anchor_rect_request,
285  },
286  {
287  "set_anchor",
288  "u",
289  xdg_positioner_interface_set_anchor_request,
290  },
291  {
292  "set_gravity",
293  "u",
294  xdg_positioner_interface_set_gravity_request,
295  },
296  {
297  "set_constraint_adjustment",
298  "u",
299  xdg_positioner_interface_set_constraint_adjustment_request,
300  },
301  {
302  "set_offset",
303  "ii",
304  xdg_positioner_interface_set_offset_request,
305  },
306 };
307 
308 const wl_message xdg_positioner_interface_events[0] = {
309 };
310 
311 const wl_interface wayland::detail::xdg_positioner_interface =
312  {
313  "xdg_positioner",
314  2,
315  7,
316  xdg_positioner_interface_requests,
317  0,
318  xdg_positioner_interface_events,
319  };
320 
321 const wl_interface* xdg_surface_interface_destroy_request[0] = {
322 };
323 
324 const wl_interface* xdg_surface_interface_get_toplevel_request[1] = {
325  &xdg_toplevel_interface,
326 };
327 
328 const wl_interface* xdg_surface_interface_get_popup_request[3] = {
329  &xdg_popup_interface,
330  &xdg_surface_interface,
331  &xdg_positioner_interface,
332 };
333 
334 const wl_interface* xdg_surface_interface_set_window_geometry_request[4] = {
335  nullptr,
336  nullptr,
337  nullptr,
338  nullptr,
339 };
340 
341 const wl_interface* xdg_surface_interface_ack_configure_request[1] = {
342  nullptr,
343 };
344 
345 const wl_interface* xdg_surface_interface_configure_event[1] = {
346  nullptr,
347 };
348 
349 const wl_message xdg_surface_interface_requests[5] = {
350  {
351  "destroy",
352  "",
353  xdg_surface_interface_destroy_request,
354  },
355  {
356  "get_toplevel",
357  "n",
358  xdg_surface_interface_get_toplevel_request,
359  },
360  {
361  "get_popup",
362  "n?oo",
363  xdg_surface_interface_get_popup_request,
364  },
365  {
366  "set_window_geometry",
367  "iiii",
368  xdg_surface_interface_set_window_geometry_request,
369  },
370  {
371  "ack_configure",
372  "u",
373  xdg_surface_interface_ack_configure_request,
374  },
375 };
376 
377 const wl_message xdg_surface_interface_events[1] = {
378  {
379  "configure",
380  "u",
381  xdg_surface_interface_configure_event,
382  },
383 };
384 
385 const wl_interface wayland::detail::xdg_surface_interface =
386  {
387  "xdg_surface",
388  2,
389  5,
390  xdg_surface_interface_requests,
391  1,
392  xdg_surface_interface_events,
393  };
394 
395 const wl_interface* xdg_toplevel_interface_destroy_request[0] = {
396 };
397 
398 const wl_interface* xdg_toplevel_interface_set_parent_request[1] = {
399  &xdg_toplevel_interface,
400 };
401 
402 const wl_interface* xdg_toplevel_interface_set_title_request[1] = {
403  nullptr,
404 };
405 
406 const wl_interface* xdg_toplevel_interface_set_app_id_request[1] = {
407  nullptr,
408 };
409 
410 const wl_interface* xdg_toplevel_interface_show_window_menu_request[4] = {
411  &seat_interface,
412  nullptr,
413  nullptr,
414  nullptr,
415 };
416 
417 const wl_interface* xdg_toplevel_interface_move_request[2] = {
418  &seat_interface,
419  nullptr,
420 };
421 
422 const wl_interface* xdg_toplevel_interface_resize_request[3] = {
423  &seat_interface,
424  nullptr,
425  nullptr,
426 };
427 
428 const wl_interface* xdg_toplevel_interface_set_max_size_request[2] = {
429  nullptr,
430  nullptr,
431 };
432 
433 const wl_interface* xdg_toplevel_interface_set_min_size_request[2] = {
434  nullptr,
435  nullptr,
436 };
437 
438 const wl_interface* xdg_toplevel_interface_set_maximized_request[0] = {
439 };
440 
441 const wl_interface* xdg_toplevel_interface_unset_maximized_request[0] = {
442 };
443 
444 const wl_interface* xdg_toplevel_interface_set_fullscreen_request[1] = {
445  &output_interface,
446 };
447 
448 const wl_interface* xdg_toplevel_interface_unset_fullscreen_request[0] = {
449 };
450 
451 const wl_interface* xdg_toplevel_interface_set_minimized_request[0] = {
452 };
453 
454 const wl_interface* xdg_toplevel_interface_configure_event[3] = {
455  nullptr,
456  nullptr,
457  nullptr,
458 };
459 
460 const wl_interface* xdg_toplevel_interface_close_event[0] = {
461 };
462 
463 const wl_message xdg_toplevel_interface_requests[14] = {
464  {
465  "destroy",
466  "",
467  xdg_toplevel_interface_destroy_request,
468  },
469  {
470  "set_parent",
471  "?o",
472  xdg_toplevel_interface_set_parent_request,
473  },
474  {
475  "set_title",
476  "s",
477  xdg_toplevel_interface_set_title_request,
478  },
479  {
480  "set_app_id",
481  "s",
482  xdg_toplevel_interface_set_app_id_request,
483  },
484  {
485  "show_window_menu",
486  "ouii",
487  xdg_toplevel_interface_show_window_menu_request,
488  },
489  {
490  "move",
491  "ou",
492  xdg_toplevel_interface_move_request,
493  },
494  {
495  "resize",
496  "ouu",
497  xdg_toplevel_interface_resize_request,
498  },
499  {
500  "set_max_size",
501  "ii",
502  xdg_toplevel_interface_set_max_size_request,
503  },
504  {
505  "set_min_size",
506  "ii",
507  xdg_toplevel_interface_set_min_size_request,
508  },
509  {
510  "set_maximized",
511  "",
512  xdg_toplevel_interface_set_maximized_request,
513  },
514  {
515  "unset_maximized",
516  "",
517  xdg_toplevel_interface_unset_maximized_request,
518  },
519  {
520  "set_fullscreen",
521  "?o",
522  xdg_toplevel_interface_set_fullscreen_request,
523  },
524  {
525  "unset_fullscreen",
526  "",
527  xdg_toplevel_interface_unset_fullscreen_request,
528  },
529  {
530  "set_minimized",
531  "",
532  xdg_toplevel_interface_set_minimized_request,
533  },
534 };
535 
536 const wl_message xdg_toplevel_interface_events[2] = {
537  {
538  "configure",
539  "iia",
540  xdg_toplevel_interface_configure_event,
541  },
542  {
543  "close",
544  "",
545  xdg_toplevel_interface_close_event,
546  },
547 };
548 
549 const wl_interface wayland::detail::xdg_toplevel_interface =
550  {
551  "xdg_toplevel",
552  2,
553  14,
554  xdg_toplevel_interface_requests,
555  2,
556  xdg_toplevel_interface_events,
557  };
558 
559 const wl_interface* xdg_popup_interface_destroy_request[0] = {
560 };
561 
562 const wl_interface* xdg_popup_interface_grab_request[2] = {
563  &seat_interface,
564  nullptr,
565 };
566 
567 const wl_interface* xdg_popup_interface_configure_event[4] = {
568  nullptr,
569  nullptr,
570  nullptr,
571  nullptr,
572 };
573 
574 const wl_interface* xdg_popup_interface_popup_done_event[0] = {
575 };
576 
577 const wl_message xdg_popup_interface_requests[2] = {
578  {
579  "destroy",
580  "",
581  xdg_popup_interface_destroy_request,
582  },
583  {
584  "grab",
585  "ou",
586  xdg_popup_interface_grab_request,
587  },
588 };
589 
590 const wl_message xdg_popup_interface_events[2] = {
591  {
592  "configure",
593  "iiii",
594  xdg_popup_interface_configure_event,
595  },
596  {
597  "popup_done",
598  "",
599  xdg_popup_interface_popup_done_event,
600  },
601 };
602 
603 const wl_interface wayland::detail::xdg_popup_interface =
604  {
605  "xdg_popup",
606  2,
607  2,
608  xdg_popup_interface_requests,
609  2,
610  xdg_popup_interface_events,
611  };
612 
613 presentation_t::presentation_t(const proxy_t &p)
614  : proxy_t(p)
615 {
616  if(proxy_has_object() && get_wrapper_type() == wrapper_type::standard)
617  {
618  set_events(std::shared_ptr<detail::events_base_t>(new events_t), dispatcher);
619  set_destroy_opcode(0u);
620  }
621  interface = &presentation_interface;
622  copy_constructor = [] (const proxy_t &p) -> proxy_t
623  { return presentation_t(p); };
624 }
625 
626 presentation_t::presentation_t()
627 {
628  interface = &presentation_interface;
629  copy_constructor = [] (const proxy_t &p) -> proxy_t
630  { return presentation_t(p); };
631 }
632 
633 presentation_t::presentation_t(wp_presentation *p, wrapper_type t)
634  : proxy_t(reinterpret_cast<wl_proxy*> (p), t){
635  if(proxy_has_object() && get_wrapper_type() == wrapper_type::standard)
636  {
637  set_events(std::shared_ptr<detail::events_base_t>(new events_t), dispatcher);
638  set_destroy_opcode(0u);
639  }
640  interface = &presentation_interface;
641  copy_constructor = [] (const proxy_t &p) -> proxy_t
642  { return presentation_t(p); };
643 }
644 
645 presentation_t::presentation_t(proxy_t const &wrapped_proxy, construct_proxy_wrapper_tag /*unused*/)
646  : proxy_t(wrapped_proxy, construct_proxy_wrapper_tag()){
647  interface = &presentation_interface;
648  copy_constructor = [] (const proxy_t &p) -> proxy_t
649  { return presentation_t(p); };
650 }
651 
652 presentation_t presentation_t::proxy_create_wrapper()
653 {
654  return {*this, construct_proxy_wrapper_tag()};
655 }
656 
657 const std::string presentation_t::interface_name = "wp_presentation";
658 
659 presentation_t::operator wp_presentation*() const
660 {
661  return reinterpret_cast<wp_presentation*> (c_ptr());
662 }
663 
665 {
666  proxy_t p = marshal_constructor(1u, &presentation_feedback_interface, surface.proxy_has_object() ? reinterpret_cast<wl_object*>(surface.c_ptr()) : nullptr, nullptr);
667  return presentation_feedback_t(p);
668 }
669 
670 std::function<void(uint32_t)> &presentation_t::on_clock_id()
671 {
672  return std::static_pointer_cast<events_t>(get_events())->clock_id;
673 }
674 
675 int presentation_t::dispatcher(uint32_t opcode, std::vector<any> args, std::shared_ptr<detail::events_base_t> e)
676 {
677  std::shared_ptr<events_t> events = std::static_pointer_cast<events_t>(e);
678  switch(opcode)
679  {
680  case 0:
681  if(events->clock_id) events->clock_id(args[0].get<uint32_t>());
682  break;
683  }
684  return 0;
685 }
686 
687 
688 presentation_feedback_t::presentation_feedback_t(const proxy_t &p)
689  : proxy_t(p)
690 {
692  {
693  set_events(std::shared_ptr<detail::events_base_t>(new events_t), dispatcher);
694  }
695  interface = &presentation_feedback_interface;
696  copy_constructor = [] (const proxy_t &p) -> proxy_t
697  { return presentation_feedback_t(p); };
698 }
699 
700 presentation_feedback_t::presentation_feedback_t()
701 {
702  interface = &presentation_feedback_interface;
703  copy_constructor = [] (const proxy_t &p) -> proxy_t
704  { return presentation_feedback_t(p); };
705 }
706 
707 presentation_feedback_t::presentation_feedback_t(wp_presentation_feedback *p, wrapper_type t)
708  : proxy_t(reinterpret_cast<wl_proxy*> (p), t){
710  {
711  set_events(std::shared_ptr<detail::events_base_t>(new events_t), dispatcher);
712  }
713  interface = &presentation_feedback_interface;
714  copy_constructor = [] (const proxy_t &p) -> proxy_t
715  { return presentation_feedback_t(p); };
716 }
717 
718 presentation_feedback_t::presentation_feedback_t(proxy_t const &wrapped_proxy, construct_proxy_wrapper_tag /*unused*/)
719  : proxy_t(wrapped_proxy, construct_proxy_wrapper_tag()){
720  interface = &presentation_feedback_interface;
721  copy_constructor = [] (const proxy_t &p) -> proxy_t
722  { return presentation_feedback_t(p); };
723 }
724 
725 presentation_feedback_t presentation_feedback_t::proxy_create_wrapper()
726 {
727  return {*this, construct_proxy_wrapper_tag()};
728 }
729 
730 const std::string presentation_feedback_t::interface_name = "wp_presentation_feedback";
731 
732 presentation_feedback_t::operator wp_presentation_feedback*() const
733 {
734  return reinterpret_cast<wp_presentation_feedback*> (c_ptr());
735 }
736 
738 {
739  return std::static_pointer_cast<events_t>(get_events())->sync_output;
740 }
741 
742 std::function<void(uint32_t, uint32_t, uint32_t, uint32_t, uint32_t, uint32_t, presentation_feedback_kind)> &presentation_feedback_t::on_presented()
743 {
744  return std::static_pointer_cast<events_t>(get_events())->presented;
745 }
746 
748 {
749  return std::static_pointer_cast<events_t>(get_events())->discarded;
750 }
751 
752 int presentation_feedback_t::dispatcher(uint32_t opcode, std::vector<any> args, std::shared_ptr<detail::events_base_t> e)
753 {
754  std::shared_ptr<events_t> events = std::static_pointer_cast<events_t>(e);
755  switch(opcode)
756  {
757  case 0:
758  if(events->sync_output) events->sync_output(output_t(args[0].get<proxy_t>()));
759  break;
760  case 1:
761  if(events->presented) events->presented(args[0].get<uint32_t>(), args[1].get<uint32_t>(), args[2].get<uint32_t>(), args[3].get<uint32_t>(), args[4].get<uint32_t>(), args[5].get<uint32_t>(), presentation_feedback_kind(args[6].get<uint32_t>()));
762  break;
763  case 2:
764  if(events->discarded) events->discarded();
765  break;
766  }
767  return 0;
768 }
769 const bitfield<4, 1> presentation_feedback_kind::vsync{0x1};
770 const bitfield<4, 1> presentation_feedback_kind::hw_clock{0x2};
771 const bitfield<4, 1> presentation_feedback_kind::hw_completion{0x4};
772 const bitfield<4, 1> presentation_feedback_kind::zero_copy{0x8};
773 
774 
775 viewporter_t::viewporter_t(const proxy_t &p)
776  : proxy_t(p)
777 {
779  {
780  set_events(std::shared_ptr<detail::events_base_t>(new events_t), dispatcher);
781  set_destroy_opcode(0u);
782  }
783  interface = &viewporter_interface;
784  copy_constructor = [] (const proxy_t &p) -> proxy_t
785  { return viewporter_t(p); };
786 }
787 
788 viewporter_t::viewporter_t()
789 {
790  interface = &viewporter_interface;
791  copy_constructor = [] (const proxy_t &p) -> proxy_t
792  { return viewporter_t(p); };
793 }
794 
795 viewporter_t::viewporter_t(wp_viewporter *p, wrapper_type t)
796  : proxy_t(reinterpret_cast<wl_proxy*> (p), t){
798  {
799  set_events(std::shared_ptr<detail::events_base_t>(new events_t), dispatcher);
800  set_destroy_opcode(0u);
801  }
802  interface = &viewporter_interface;
803  copy_constructor = [] (const proxy_t &p) -> proxy_t
804  { return viewporter_t(p); };
805 }
806 
807 viewporter_t::viewporter_t(proxy_t const &wrapped_proxy, construct_proxy_wrapper_tag /*unused*/)
808  : proxy_t(wrapped_proxy, construct_proxy_wrapper_tag()){
809  interface = &viewporter_interface;
810  copy_constructor = [] (const proxy_t &p) -> proxy_t
811  { return viewporter_t(p); };
812 }
813 
814 viewporter_t viewporter_t::proxy_create_wrapper()
815 {
816  return {*this, construct_proxy_wrapper_tag()};
817 }
818 
819 const std::string viewporter_t::interface_name = "wp_viewporter";
820 
821 viewporter_t::operator wp_viewporter*() const
822 {
823  return reinterpret_cast<wp_viewporter*> (c_ptr());
824 }
825 
827 {
828  proxy_t p = marshal_constructor(1u, &viewport_interface, nullptr, surface.proxy_has_object() ? reinterpret_cast<wl_object*>(surface.c_ptr()) : nullptr);
829  return viewport_t(p);
830 }
831 
832 int viewporter_t::dispatcher(uint32_t opcode, std::vector<any> args, std::shared_ptr<detail::events_base_t> e)
833 {
834  return 0;
835 }
836 
837 
838 viewport_t::viewport_t(const proxy_t &p)
839  : proxy_t(p)
840 {
842  {
843  set_events(std::shared_ptr<detail::events_base_t>(new events_t), dispatcher);
844  set_destroy_opcode(0u);
845  }
846  interface = &viewport_interface;
847  copy_constructor = [] (const proxy_t &p) -> proxy_t
848  { return viewport_t(p); };
849 }
850 
851 viewport_t::viewport_t()
852 {
853  interface = &viewport_interface;
854  copy_constructor = [] (const proxy_t &p) -> proxy_t
855  { return viewport_t(p); };
856 }
857 
858 viewport_t::viewport_t(wp_viewport *p, wrapper_type t)
859  : proxy_t(reinterpret_cast<wl_proxy*> (p), t){
861  {
862  set_events(std::shared_ptr<detail::events_base_t>(new events_t), dispatcher);
863  set_destroy_opcode(0u);
864  }
865  interface = &viewport_interface;
866  copy_constructor = [] (const proxy_t &p) -> proxy_t
867  { return viewport_t(p); };
868 }
869 
870 viewport_t::viewport_t(proxy_t const &wrapped_proxy, construct_proxy_wrapper_tag /*unused*/)
871  : proxy_t(wrapped_proxy, construct_proxy_wrapper_tag()){
872  interface = &viewport_interface;
873  copy_constructor = [] (const proxy_t &p) -> proxy_t
874  { return viewport_t(p); };
875 }
876 
877 viewport_t viewport_t::proxy_create_wrapper()
878 {
879  return {*this, construct_proxy_wrapper_tag()};
880 }
881 
882 const std::string viewport_t::interface_name = "wp_viewport";
883 
884 viewport_t::operator wp_viewport*() const
885 {
886  return reinterpret_cast<wp_viewport*> (c_ptr());
887 }
888 
889 void viewport_t::set_source(double x, double y, double width, double height)
890 {
891  marshal(1u, x, y, width, height);
892 }
893 
894 void viewport_t::set_destination(int32_t width, int32_t height)
895 {
896  marshal(2u, width, height);
897 }
898 
899 int viewport_t::dispatcher(uint32_t opcode, std::vector<any> args, std::shared_ptr<detail::events_base_t> e)
900 {
901  return 0;
902 }
903 
904 
905 xdg_wm_base_t::xdg_wm_base_t(const proxy_t &p)
906  : proxy_t(p)
907 {
909  {
910  set_events(std::shared_ptr<detail::events_base_t>(new events_t), dispatcher);
911  set_destroy_opcode(0u);
912  }
913  interface = &xdg_wm_base_interface;
914  copy_constructor = [] (const proxy_t &p) -> proxy_t
915  { return xdg_wm_base_t(p); };
916 }
917 
918 xdg_wm_base_t::xdg_wm_base_t()
919 {
920  interface = &xdg_wm_base_interface;
921  copy_constructor = [] (const proxy_t &p) -> proxy_t
922  { return xdg_wm_base_t(p); };
923 }
924 
925 xdg_wm_base_t::xdg_wm_base_t(xdg_wm_base *p, wrapper_type t)
926  : proxy_t(reinterpret_cast<wl_proxy*> (p), t){
928  {
929  set_events(std::shared_ptr<detail::events_base_t>(new events_t), dispatcher);
930  set_destroy_opcode(0u);
931  }
932  interface = &xdg_wm_base_interface;
933  copy_constructor = [] (const proxy_t &p) -> proxy_t
934  { return xdg_wm_base_t(p); };
935 }
936 
937 xdg_wm_base_t::xdg_wm_base_t(proxy_t const &wrapped_proxy, construct_proxy_wrapper_tag /*unused*/)
938  : proxy_t(wrapped_proxy, construct_proxy_wrapper_tag()){
939  interface = &xdg_wm_base_interface;
940  copy_constructor = [] (const proxy_t &p) -> proxy_t
941  { return xdg_wm_base_t(p); };
942 }
943 
944 xdg_wm_base_t xdg_wm_base_t::proxy_create_wrapper()
945 {
946  return {*this, construct_proxy_wrapper_tag()};
947 }
948 
949 const std::string xdg_wm_base_t::interface_name = "xdg_wm_base";
950 
951 xdg_wm_base_t::operator xdg_wm_base*() const
952 {
953  return reinterpret_cast<xdg_wm_base*> (c_ptr());
954 }
955 
957 {
958  proxy_t p = marshal_constructor(1u, &xdg_positioner_interface, nullptr);
959  return xdg_positioner_t(p);
960 }
961 
963 {
964  proxy_t p = marshal_constructor(2u, &xdg_surface_interface, nullptr, surface.proxy_has_object() ? reinterpret_cast<wl_object*>(surface.c_ptr()) : nullptr);
965  return xdg_surface_t(p);
966 }
967 
968 void xdg_wm_base_t::pong(uint32_t serial)
969 {
970  marshal(3u, serial);
971 }
972 
973 std::function<void(uint32_t)> &xdg_wm_base_t::on_ping()
974 {
975  return std::static_pointer_cast<events_t>(get_events())->ping;
976 }
977 
978 int xdg_wm_base_t::dispatcher(uint32_t opcode, std::vector<any> args, std::shared_ptr<detail::events_base_t> e)
979 {
980  std::shared_ptr<events_t> events = std::static_pointer_cast<events_t>(e);
981  switch(opcode)
982  {
983  case 0:
984  if(events->ping) events->ping(args[0].get<uint32_t>());
985  break;
986  }
987  return 0;
988 }
989 
990 
991 xdg_positioner_t::xdg_positioner_t(const proxy_t &p)
992  : proxy_t(p)
993 {
995  {
996  set_events(std::shared_ptr<detail::events_base_t>(new events_t), dispatcher);
997  set_destroy_opcode(0u);
998  }
999  interface = &xdg_positioner_interface;
1000  copy_constructor = [] (const proxy_t &p) -> proxy_t
1001  { return xdg_positioner_t(p); };
1002 }
1003 
1004 xdg_positioner_t::xdg_positioner_t()
1005 {
1006  interface = &xdg_positioner_interface;
1007  copy_constructor = [] (const proxy_t &p) -> proxy_t
1008  { return xdg_positioner_t(p); };
1009 }
1010 
1011 xdg_positioner_t::xdg_positioner_t(xdg_positioner *p, wrapper_type t)
1012  : proxy_t(reinterpret_cast<wl_proxy*> (p), t){
1014  {
1015  set_events(std::shared_ptr<detail::events_base_t>(new events_t), dispatcher);
1016  set_destroy_opcode(0u);
1017  }
1018  interface = &xdg_positioner_interface;
1019  copy_constructor = [] (const proxy_t &p) -> proxy_t
1020  { return xdg_positioner_t(p); };
1021 }
1022 
1023 xdg_positioner_t::xdg_positioner_t(proxy_t const &wrapped_proxy, construct_proxy_wrapper_tag /*unused*/)
1024  : proxy_t(wrapped_proxy, construct_proxy_wrapper_tag()){
1025  interface = &xdg_positioner_interface;
1026  copy_constructor = [] (const proxy_t &p) -> proxy_t
1027  { return xdg_positioner_t(p); };
1028 }
1029 
1030 xdg_positioner_t xdg_positioner_t::proxy_create_wrapper()
1031 {
1032  return {*this, construct_proxy_wrapper_tag()};
1033 }
1034 
1035 const std::string xdg_positioner_t::interface_name = "xdg_positioner";
1036 
1037 xdg_positioner_t::operator xdg_positioner*() const
1038 {
1039  return reinterpret_cast<xdg_positioner*> (c_ptr());
1040 }
1041 
1042 void xdg_positioner_t::set_size(int32_t width, int32_t height)
1043 {
1044  marshal(1u, width, height);
1045 }
1046 
1047 void xdg_positioner_t::set_anchor_rect(int32_t x, int32_t y, int32_t width, int32_t height)
1048 {
1049  marshal(2u, x, y, width, height);
1050 }
1051 
1052 void xdg_positioner_t::set_anchor(xdg_positioner_anchor anchor)
1053 {
1054  marshal(3u, static_cast<uint32_t>(anchor));
1055 }
1056 
1057 void xdg_positioner_t::set_gravity(xdg_positioner_gravity gravity)
1058 {
1059  marshal(4u, static_cast<uint32_t>(gravity));
1060 }
1061 
1063 {
1064  marshal(5u, static_cast<uint32_t>(constraint_adjustment));
1065 }
1066 
1067 void xdg_positioner_t::set_offset(int32_t x, int32_t y)
1068 {
1069  marshal(6u, x, y);
1070 }
1071 
1072 int xdg_positioner_t::dispatcher(uint32_t opcode, std::vector<any> args, std::shared_ptr<detail::events_base_t> e)
1073 {
1074  return 0;
1075 }
1076 
1077 
1078 
1079 const bitfield<6, 8> xdg_positioner_constraint_adjustment::none{0};
1080 const bitfield<6, 8> xdg_positioner_constraint_adjustment::slide_x{1};
1081 const bitfield<6, 8> xdg_positioner_constraint_adjustment::slide_y{2};
1082 const bitfield<6, 8> xdg_positioner_constraint_adjustment::flip_x{4};
1083 const bitfield<6, 8> xdg_positioner_constraint_adjustment::flip_y{8};
1084 const bitfield<6, 8> xdg_positioner_constraint_adjustment::resize_x{16};
1085 const bitfield<6, 8> xdg_positioner_constraint_adjustment::resize_y{32};
1086 
1087 
1088 xdg_surface_t::xdg_surface_t(const proxy_t &p)
1089  : proxy_t(p)
1090 {
1092  {
1093  set_events(std::shared_ptr<detail::events_base_t>(new events_t), dispatcher);
1094  set_destroy_opcode(0u);
1095  }
1096  interface = &xdg_surface_interface;
1097  copy_constructor = [] (const proxy_t &p) -> proxy_t
1098  { return xdg_surface_t(p); };
1099 }
1100 
1101 xdg_surface_t::xdg_surface_t()
1102 {
1103  interface = &xdg_surface_interface;
1104  copy_constructor = [] (const proxy_t &p) -> proxy_t
1105  { return xdg_surface_t(p); };
1106 }
1107 
1108 xdg_surface_t::xdg_surface_t(xdg_surface *p, wrapper_type t)
1109  : proxy_t(reinterpret_cast<wl_proxy*> (p), t){
1111  {
1112  set_events(std::shared_ptr<detail::events_base_t>(new events_t), dispatcher);
1113  set_destroy_opcode(0u);
1114  }
1115  interface = &xdg_surface_interface;
1116  copy_constructor = [] (const proxy_t &p) -> proxy_t
1117  { return xdg_surface_t(p); };
1118 }
1119 
1120 xdg_surface_t::xdg_surface_t(proxy_t const &wrapped_proxy, construct_proxy_wrapper_tag /*unused*/)
1121  : proxy_t(wrapped_proxy, construct_proxy_wrapper_tag()){
1122  interface = &xdg_surface_interface;
1123  copy_constructor = [] (const proxy_t &p) -> proxy_t
1124  { return xdg_surface_t(p); };
1125 }
1126 
1127 xdg_surface_t xdg_surface_t::proxy_create_wrapper()
1128 {
1129  return {*this, construct_proxy_wrapper_tag()};
1130 }
1131 
1132 const std::string xdg_surface_t::interface_name = "xdg_surface";
1133 
1134 xdg_surface_t::operator xdg_surface*() const
1135 {
1136  return reinterpret_cast<xdg_surface*> (c_ptr());
1137 }
1138 
1140 {
1141  proxy_t p = marshal_constructor(1u, &xdg_toplevel_interface, nullptr);
1142  return xdg_toplevel_t(p);
1143 }
1144 
1146 {
1147  proxy_t p = marshal_constructor(2u, &xdg_popup_interface, nullptr, parent.proxy_has_object() ? reinterpret_cast<wl_object*>(parent.c_ptr()) : nullptr, positioner.proxy_has_object() ? reinterpret_cast<wl_object*>(positioner.c_ptr()) : nullptr);
1148  return xdg_popup_t(p);
1149 }
1150 
1151 void xdg_surface_t::set_window_geometry(int32_t x, int32_t y, int32_t width, int32_t height)
1152 {
1153  marshal(3u, x, y, width, height);
1154 }
1155 
1156 void xdg_surface_t::ack_configure(uint32_t serial)
1157 {
1158  marshal(4u, serial);
1159 }
1160 
1161 std::function<void(uint32_t)> &xdg_surface_t::on_configure()
1162 {
1163  return std::static_pointer_cast<events_t>(get_events())->configure;
1164 }
1165 
1166 int xdg_surface_t::dispatcher(uint32_t opcode, std::vector<any> args, std::shared_ptr<detail::events_base_t> e)
1167 {
1168  std::shared_ptr<events_t> events = std::static_pointer_cast<events_t>(e);
1169  switch(opcode)
1170  {
1171  case 0:
1172  if(events->configure) events->configure(args[0].get<uint32_t>());
1173  break;
1174  }
1175  return 0;
1176 }
1177 
1178 
1179 xdg_toplevel_t::xdg_toplevel_t(const proxy_t &p)
1180  : proxy_t(p)
1181 {
1183  {
1184  set_events(std::shared_ptr<detail::events_base_t>(new events_t), dispatcher);
1185  set_destroy_opcode(0u);
1186  }
1187  interface = &xdg_toplevel_interface;
1188  copy_constructor = [] (const proxy_t &p) -> proxy_t
1189  { return xdg_toplevel_t(p); };
1190 }
1191 
1192 xdg_toplevel_t::xdg_toplevel_t()
1193 {
1194  interface = &xdg_toplevel_interface;
1195  copy_constructor = [] (const proxy_t &p) -> proxy_t
1196  { return xdg_toplevel_t(p); };
1197 }
1198 
1199 xdg_toplevel_t::xdg_toplevel_t(xdg_toplevel *p, wrapper_type t)
1200  : proxy_t(reinterpret_cast<wl_proxy*> (p), t){
1202  {
1203  set_events(std::shared_ptr<detail::events_base_t>(new events_t), dispatcher);
1204  set_destroy_opcode(0u);
1205  }
1206  interface = &xdg_toplevel_interface;
1207  copy_constructor = [] (const proxy_t &p) -> proxy_t
1208  { return xdg_toplevel_t(p); };
1209 }
1210 
1211 xdg_toplevel_t::xdg_toplevel_t(proxy_t const &wrapped_proxy, construct_proxy_wrapper_tag /*unused*/)
1212  : proxy_t(wrapped_proxy, construct_proxy_wrapper_tag()){
1213  interface = &xdg_toplevel_interface;
1214  copy_constructor = [] (const proxy_t &p) -> proxy_t
1215  { return xdg_toplevel_t(p); };
1216 }
1217 
1218 xdg_toplevel_t xdg_toplevel_t::proxy_create_wrapper()
1219 {
1220  return {*this, construct_proxy_wrapper_tag()};
1221 }
1222 
1223 const std::string xdg_toplevel_t::interface_name = "xdg_toplevel";
1224 
1225 xdg_toplevel_t::operator xdg_toplevel*() const
1226 {
1227  return reinterpret_cast<xdg_toplevel*> (c_ptr());
1228 }
1229 
1231 {
1232  marshal(1u, parent.proxy_has_object() ? reinterpret_cast<wl_object*>(parent.c_ptr()) : nullptr);
1233 }
1234 
1235 void xdg_toplevel_t::set_title(std::string title)
1236 {
1237  marshal(2u, title);
1238 }
1239 
1240 void xdg_toplevel_t::set_app_id(std::string app_id)
1241 {
1242  marshal(3u, app_id);
1243 }
1244 
1245 void xdg_toplevel_t::show_window_menu(seat_t seat, uint32_t serial, int32_t x, int32_t y)
1246 {
1247  marshal(4u, seat.proxy_has_object() ? reinterpret_cast<wl_object*>(seat.c_ptr()) : nullptr, serial, x, y);
1248 }
1249 
1250 void xdg_toplevel_t::move(seat_t seat, uint32_t serial)
1251 {
1252  marshal(5u, seat.proxy_has_object() ? reinterpret_cast<wl_object*>(seat.c_ptr()) : nullptr, serial);
1253 }
1254 
1255 void xdg_toplevel_t::resize(seat_t seat, uint32_t serial, xdg_toplevel_resize_edge edges)
1256 {
1257  marshal(6u, seat.proxy_has_object() ? reinterpret_cast<wl_object*>(seat.c_ptr()) : nullptr, serial, static_cast<uint32_t>(edges));
1258 }
1259 
1260 void xdg_toplevel_t::set_max_size(int32_t width, int32_t height)
1261 {
1262  marshal(7u, width, height);
1263 }
1264 
1265 void xdg_toplevel_t::set_min_size(int32_t width, int32_t height)
1266 {
1267  marshal(8u, width, height);
1268 }
1269 
1271 {
1272  marshal(9u);
1273 }
1274 
1276 {
1277  marshal(10u);
1278 }
1279 
1281 {
1282  marshal(11u, output.proxy_has_object() ? reinterpret_cast<wl_object*>(output.c_ptr()) : nullptr);
1283 }
1284 
1286 {
1287  marshal(12u);
1288 }
1289 
1291 {
1292  marshal(13u);
1293 }
1294 
1295 std::function<void(int32_t, int32_t, array_t)> &xdg_toplevel_t::on_configure()
1296 {
1297  return std::static_pointer_cast<events_t>(get_events())->configure;
1298 }
1299 
1300 std::function<void()> &xdg_toplevel_t::on_close()
1301 {
1302  return std::static_pointer_cast<events_t>(get_events())->close;
1303 }
1304 
1305 int xdg_toplevel_t::dispatcher(uint32_t opcode, std::vector<any> args, std::shared_ptr<detail::events_base_t> e)
1306 {
1307  std::shared_ptr<events_t> events = std::static_pointer_cast<events_t>(e);
1308  switch(opcode)
1309  {
1310  case 0:
1311  if(events->configure) events->configure(args[0].get<int32_t>(), args[1].get<int32_t>(), args[2].get<array_t>());
1312  break;
1313  case 1:
1314  if(events->close) events->close();
1315  break;
1316  }
1317  return 0;
1318 }
1319 const bitfield<4, 10> xdg_toplevel_resize_edge::none{0};
1320 const bitfield<4, 10> xdg_toplevel_resize_edge::top{1};
1321 const bitfield<4, 10> xdg_toplevel_resize_edge::bottom{2};
1322 const bitfield<4, 10> xdg_toplevel_resize_edge::left{4};
1323 const bitfield<4, 10> xdg_toplevel_resize_edge::top_left{5};
1324 const bitfield<4, 10> xdg_toplevel_resize_edge::bottom_left{6};
1325 const bitfield<4, 10> xdg_toplevel_resize_edge::right{8};
1326 const bitfield<4, 10> xdg_toplevel_resize_edge::top_right{9};
1327 const bitfield<4, 10> xdg_toplevel_resize_edge::bottom_right{10};
1328 
1329 
1330 
1331 xdg_popup_t::xdg_popup_t(const proxy_t &p)
1332  : proxy_t(p)
1333 {
1335  {
1336  set_events(std::shared_ptr<detail::events_base_t>(new events_t), dispatcher);
1337  set_destroy_opcode(0u);
1338  }
1339  interface = &xdg_popup_interface;
1340  copy_constructor = [] (const proxy_t &p) -> proxy_t
1341  { return xdg_popup_t(p); };
1342 }
1343 
1344 xdg_popup_t::xdg_popup_t()
1345 {
1346  interface = &xdg_popup_interface;
1347  copy_constructor = [] (const proxy_t &p) -> proxy_t
1348  { return xdg_popup_t(p); };
1349 }
1350 
1351 xdg_popup_t::xdg_popup_t(xdg_popup *p, wrapper_type t)
1352  : proxy_t(reinterpret_cast<wl_proxy*> (p), t){
1354  {
1355  set_events(std::shared_ptr<detail::events_base_t>(new events_t), dispatcher);
1356  set_destroy_opcode(0u);
1357  }
1358  interface = &xdg_popup_interface;
1359  copy_constructor = [] (const proxy_t &p) -> proxy_t
1360  { return xdg_popup_t(p); };
1361 }
1362 
1363 xdg_popup_t::xdg_popup_t(proxy_t const &wrapped_proxy, construct_proxy_wrapper_tag /*unused*/)
1364  : proxy_t(wrapped_proxy, construct_proxy_wrapper_tag()){
1365  interface = &xdg_popup_interface;
1366  copy_constructor = [] (const proxy_t &p) -> proxy_t
1367  { return xdg_popup_t(p); };
1368 }
1369 
1370 xdg_popup_t xdg_popup_t::proxy_create_wrapper()
1371 {
1372  return {*this, construct_proxy_wrapper_tag()};
1373 }
1374 
1375 const std::string xdg_popup_t::interface_name = "xdg_popup";
1376 
1377 xdg_popup_t::operator xdg_popup*() const
1378 {
1379  return reinterpret_cast<xdg_popup*> (c_ptr());
1380 }
1381 
1382 void xdg_popup_t::grab(seat_t seat, uint32_t serial)
1383 {
1384  marshal(1u, seat.proxy_has_object() ? reinterpret_cast<wl_object*>(seat.c_ptr()) : nullptr, serial);
1385 }
1386 
1387 std::function<void(int32_t, int32_t, int32_t, int32_t)> &xdg_popup_t::on_configure()
1388 {
1389  return std::static_pointer_cast<events_t>(get_events())->configure;
1390 }
1391 
1392 std::function<void()> &xdg_popup_t::on_popup_done()
1393 {
1394  return std::static_pointer_cast<events_t>(get_events())->popup_done;
1395 }
1396 
1397 int xdg_popup_t::dispatcher(uint32_t opcode, std::vector<any> args, std::shared_ptr<detail::events_base_t> e)
1398 {
1399  std::shared_ptr<events_t> events = std::static_pointer_cast<events_t>(e);
1400  switch(opcode)
1401  {
1402  case 0:
1403  if(events->configure) events->configure(args[0].get<int32_t>(), args[1].get<int32_t>(), args[2].get<int32_t>(), args[3].get<int32_t>());
1404  break;
1405  case 1:
1406  if(events->popup_done) events->popup_done();
1407  break;
1408  }
1409  return 0;
1410 }
1411 
1412 
1413 
wayland::presentation_feedback_kind::hw_clock
static const detail::bitfield< 4, 1 > hw_clock
hardware provided the presentation timestamp
Definition: wayland-client-protocol-extra.hpp:334
wayland::presentation_feedback_t
presentation time feedback event
Definition: wayland-client-protocol-extra.hpp:186
wayland::xdg_wm_base_t::pong
void pong(uint32_t serial)
respond to a ping event
Definition: wayland-client-protocol-extra.cpp:968
wayland::xdg_toplevel_t::set_app_id
void set_app_id(std::string app_id)
set application ID
Definition: wayland-client-protocol-extra.cpp:1240
wayland::presentation_feedback_t::on_discarded
std::function< void()> & on_discarded()
the content update was not displayed
Definition: wayland-client-protocol-extra.cpp:747
wayland::proxy_t::get_wrapper_type
wrapper_type get_wrapper_type() const
Get the type of a proxy object.
Definition: wayland-client.hpp:288
wayland::xdg_wm_base_t::get_xdg_surface
xdg_surface_t get_xdg_surface(surface_t surface)
create a shell surface from a surface
Definition: wayland-client-protocol-extra.cpp:962
wayland::presentation_t::on_clock_id
std::function< void(uint32_t)> & on_clock_id()
clock ID for timestamps
Definition: wayland-client-protocol-extra.cpp:670
wayland::proxy_t::wrapper_type::standard
wayland::presentation_feedback_kind::hw_completion
static const detail::bitfield< 4, 1 > hw_completion
hardware signalled the start of the presentation
Definition: wayland-client-protocol-extra.hpp:336
wayland::xdg_positioner_t::set_size
void set_size(int32_t width, int32_t height)
set the size of the to-be positioned rectangle
Definition: wayland-client-protocol-extra.cpp:1042
wayland::presentation_feedback_kind
bitmask of flags in presented event
Definition: wayland-client-protocol-extra.hpp:325
wayland::xdg_popup_t
short-lived, popup surfaces for menus
Definition: wayland-client-protocol-extra.hpp:1702
wayland::xdg_toplevel_t::unset_fullscreen
void unset_fullscreen()
unset the window as fullscreen
Definition: wayland-client-protocol-extra.cpp:1285
wayland::xdg_toplevel_t::set_min_size
void set_min_size(int32_t width, int32_t height)
set the minimum size
Definition: wayland-client-protocol-extra.cpp:1265
wayland::presentation_t
timed presentation related wl_surface requests
Definition: wayland-client-protocol-extra.hpp:75
wayland::xdg_positioner_t::set_offset
void set_offset(int32_t x, int32_t y)
set surface position offset
Definition: wayland-client-protocol-extra.cpp:1067
wayland::xdg_toplevel_t::set_maximized
void set_maximized()
maximize the window
Definition: wayland-client-protocol-extra.cpp:1270
wayland::presentation_feedback_kind::zero_copy
static const detail::bitfield< 4, 1 > zero_copy
presentation was done zero-copy
Definition: wayland-client-protocol-extra.hpp:338
wayland::xdg_surface_t
desktop user interface surface base interface
Definition: wayland-client-protocol-extra.hpp:959
wayland::xdg_toplevel_t::show_window_menu
void show_window_menu(seat_t seat, uint32_t serial, int32_t x, int32_t y)
show the window menu
Definition: wayland-client-protocol-extra.cpp:1245
wayland::proxy_t::proxy_has_object
bool proxy_has_object() const
Check whether this wrapper actually wraps an object.
wayland::xdg_toplevel_t::resize
void resize(seat_t seat, uint32_t serial, xdg_toplevel_resize_edge edges)
start an interactive resize
Definition: wayland-client-protocol-extra.cpp:1255
wayland::xdg_positioner_t::set_gravity
void set_gravity(xdg_positioner_gravity gravity)
set child surface gravity
Definition: wayland-client-protocol-extra.cpp:1057
wayland::xdg_toplevel_resize_edge
edge values for resizing
Definition: wayland-client-protocol-extra.hpp:1623
wayland::xdg_positioner_t::set_anchor_rect
void set_anchor_rect(int32_t x, int32_t y, int32_t width, int32_t height)
set the anchor rectangle within the parent surface
Definition: wayland-client-protocol-extra.cpp:1047
wayland::xdg_toplevel_t::set_max_size
void set_max_size(int32_t width, int32_t height)
set the maximum size
Definition: wayland-client-protocol-extra.cpp:1260
wayland::xdg_toplevel_t::set_parent
void set_parent(xdg_toplevel_t parent)
set the parent of this surface
Definition: wayland-client-protocol-extra.cpp:1230
wayland::xdg_toplevel_t::set_minimized
void set_minimized()
set the window as minimized
Definition: wayland-client-protocol-extra.cpp:1290
wayland::surface_t
an onscreen surface
Definition: wayland-client-protocol.hpp:1898
wayland::xdg_positioner_t
child surface positioner
Definition: wayland-client-protocol-extra.hpp:698
wayland::proxy_t
Represents a protocol object on the client side.
Definition: wayland-client.hpp:98
wayland::xdg_surface_t::on_configure
std::function< void(uint32_t)> & on_configure()
suggest a surface change
Definition: wayland-client-protocol-extra.cpp:1161
wayland::xdg_popup_t::grab
void grab(seat_t seat, uint32_t serial)
make the popup take an explicit grab
Definition: wayland-client-protocol-extra.cpp:1382
wayland::presentation_t::feedback
presentation_feedback_t feedback(surface_t surface)
request presentation feedback information
Definition: wayland-client-protocol-extra.cpp:664
wayland::xdg_toplevel_t::on_close
std::function< void()> & on_close()
surface wants to be closed
Definition: wayland-client-protocol-extra.cpp:1300
wayland::xdg_toplevel_t::on_configure
std::function< void(int32_t, int32_t, array_t)> & on_configure()
suggest a surface change
Definition: wayland-client-protocol-extra.cpp:1295
wayland::viewport_t::set_source
void set_source(double x, double y, double width, double height)
set the source rectangle for cropping
Definition: wayland-client-protocol-extra.cpp:889
wayland::viewport_t::set_destination
void set_destination(int32_t width, int32_t height)
set the surface size for scaling
Definition: wayland-client-protocol-extra.cpp:894
wayland::xdg_toplevel_t::set_title
void set_title(std::string title)
set surface title
Definition: wayland-client-protocol-extra.cpp:1235
wayland::proxy_t::c_ptr
wl_proxy * c_ptr() const
Get a pointer to the underlying C struct.
wayland::xdg_surface_t::get_toplevel
xdg_toplevel_t get_toplevel()
assign the xdg_toplevel surface role
Definition: wayland-client-protocol-extra.cpp:1139
wayland::xdg_toplevel_t::move
void move(seat_t seat, uint32_t serial)
start an interactive move
Definition: wayland-client-protocol-extra.cpp:1250
wayland::xdg_toplevel_t
toplevel surface
Definition: wayland-client-protocol-extra.hpp:1143
wayland::xdg_surface_t::set_window_geometry
void set_window_geometry(int32_t x, int32_t y, int32_t width, int32_t height)
set the new window geometry
Definition: wayland-client-protocol-extra.cpp:1151
wayland::presentation_feedback_t::on_sync_output
std::function< void(output_t)> & on_sync_output()
presentation synchronized to this output
Definition: wayland-client-protocol-extra.cpp:737
wayland::xdg_positioner_t::set_constraint_adjustment
void set_constraint_adjustment(xdg_positioner_constraint_adjustment constraint_adjustment)
set the adjustment to be done when constrained
Definition: wayland-client-protocol-extra.cpp:1062
wayland::seat_t
group of input devices
Definition: wayland-client-protocol.hpp:2334
wayland::xdg_positioner_constraint_adjustment
constraint adjustments
Definition: wayland-client-protocol-extra.hpp:900
wayland::xdg_toplevel_t::set_fullscreen
void set_fullscreen(output_t output)
set the window as fullscreen on an output
Definition: wayland-client-protocol-extra.cpp:1280
wayland::xdg_popup_t::on_configure
std::function< void(int32_t, int32_t, int32_t, int32_t)> & on_configure()
configure the popup surface
Definition: wayland-client-protocol-extra.cpp:1387
wayland::xdg_surface_t::ack_configure
void ack_configure(uint32_t serial)
ack a configure event
Definition: wayland-client-protocol-extra.cpp:1156
wayland::xdg_popup_t::on_popup_done
std::function< void()> & on_popup_done()
popup interaction is done
Definition: wayland-client-protocol-extra.cpp:1392
wayland::xdg_positioner_t::set_anchor
void set_anchor(xdg_positioner_anchor anchor)
set anchor rectangle anchor
Definition: wayland-client-protocol-extra.cpp:1052
wayland::viewporter_t::get_viewport
viewport_t get_viewport(surface_t surface)
extend surface interface for crop and scale
Definition: wayland-client-protocol-extra.cpp:826
wayland::xdg_toplevel_t::unset_maximized
void unset_maximized()
unmaximize the window
Definition: wayland-client-protocol-extra.cpp:1275
wayland::xdg_wm_base_t
create desktop-style surfaces
Definition: wayland-client-protocol-extra.hpp:564
wayland::presentation_feedback_t::on_presented
std::function< void(uint32_t, uint32_t, uint32_t, uint32_t, uint32_t, uint32_t, presentation_feedback_kind)> & on_presented()
the content update was displayed
Definition: wayland-client-protocol-extra.cpp:742
wayland::viewport_t
crop and scale interface to a wl_surface
Definition: wayland-client-protocol-extra.hpp:467
wayland::xdg_wm_base_t::on_ping
std::function< void(uint32_t)> & on_ping()
check if the client is alive
Definition: wayland-client-protocol-extra.cpp:973
wayland::viewporter_t
surface cropping and scaling
Definition: wayland-client-protocol-extra.hpp:352
wayland::presentation_feedback_kind::vsync
static const detail::bitfield< 4, 1 > vsync
presentation was vsync'd
Definition: wayland-client-protocol-extra.hpp:332
wayland::xdg_surface_t::get_popup
xdg_popup_t get_popup(xdg_surface_t parent, xdg_positioner_t positioner)
assign the xdg_popup surface role
Definition: wayland-client-protocol-extra.cpp:1145
wayland::output_t
compositor output region
Definition: wayland-client-protocol.hpp:3250
wayland::xdg_wm_base_t::create_positioner
xdg_positioner_t create_positioner()
create a positioner object
Definition: wayland-client-protocol-extra.cpp:956