KWayland

wayland-xdg-shell-v5-client-protocol.h
1 /*
2  * This file is *NOT* autogenerated.
3  * It contains XDGShellV5 with method names modified to be not clashing with XDG stable
4  * Strings inside the sent protocol remain the same
5  */
6 #ifndef ZXDG_SHELL_V5_UNSTABLE_V5_CLIENT_PROTOCOL_H
7 #define ZXDG_SHELL_V5_UNSTABLE_V5_CLIENT_PROTOCOL_H
8 
9 #include <stdint.h>
10 #include <stddef.h>
11 #include "wayland-client.h"
12 
13 #ifdef __cplusplus
14 extern "C" {
15 #endif
16 
34 struct wl_output;
35 struct wl_seat;
36 struct wl_surface;
37 
38 struct xdg_surface;
39 struct xdg_popup;
40 struct xdg_shell;
41 
61 extern const struct wl_interface zxdg_shell_v5_interface;
111 extern const struct wl_interface zxdg_surface_v5_interface;
225 extern const struct wl_interface zxdg_popup_v5_interface;
226 
227 #ifndef ZXDG_SHELL_V5_VERSION_ENUM
228 #define ZXDG_SHELL_V5_VERSION_ENUM
229 
238 enum zxdg_shell_v5_version {
243 };
244 #endif /* ZXDG_SHELL_V5_VERSION_ENUM */
245 
246 #ifndef ZXDG_SHELL_V5_ERROR_ENUM
247 #define ZXDG_SHELL_V5_ERROR_ENUM
248 enum zxdg_shell_v5_error {
252  ZXDG_SHELL_V5_ERROR_ROLE = 0,
256  ZXDG_SHELL_V5_ERROR_DEFUNCT_SURFACES = 1,
260  ZXDG_SHELL_V5_ERROR_NOT_THE_TOPMOST_POPUP = 2,
264  ZXDG_SHELL_V5_ERROR_INVALID_POPUP_PARENT = 3,
265 };
266 #endif /* ZXDG_SHELL_V5_ERROR_ENUM */
267 
272 struct zxdg_shell_v5_listener {
289  void (*ping)(void *data,
290  struct xdg_shell *xdg_shell,
291  uint32_t serial);
292 };
293 
297 static inline int
298 zxdg_shell_v5_add_listener(struct xdg_shell *xdg_shell,
299  const struct zxdg_shell_v5_listener *listener, void *data)
300 {
301  return wl_proxy_add_listener((struct wl_proxy *) xdg_shell,
302  (void (**)(void)) listener, data);
303 }
304 
305 #define ZXDG_SHELL_V5_DESTROY 0
306 #define ZXDG_SHELL_V5_USE_UNSTABLE_VERSION 1
307 #define ZXDG_SHELL_V5_GET_ZXDG_SURFACE_V5 2
308 #define ZXDG_SHELL_V5_GET_ZXDG_POPUP_V5 3
309 #define ZXDG_SHELL_V5_PONG 4
310 
314 #define ZXDG_SHELL_V5_PING_SINCE_VERSION 1
315 
319 #define ZXDG_SHELL_V5_DESTROY_SINCE_VERSION 1
320 
323 #define ZXDG_SHELL_V5_USE_UNSTABLE_VERSION_SINCE_VERSION 1
324 
327 #define ZXDG_SHELL_V5_GET_ZXDG_SURFACE_V5_SINCE_VERSION 1
328 
331 #define ZXDG_SHELL_V5_GET_ZXDG_POPUP_V5_SINCE_VERSION 1
332 
335 #define ZXDG_SHELL_V5_PONG_SINCE_VERSION 1
336 
338 static inline void
339 zxdg_shell_v5_set_user_data(struct xdg_shell *xdg_shell, void *user_data)
340 {
341  wl_proxy_set_user_data((struct wl_proxy *) xdg_shell, user_data);
342 }
343 
345 static inline void *
346 zxdg_shell_v5_get_user_data(struct xdg_shell *xdg_shell)
347 {
348  return wl_proxy_get_user_data((struct wl_proxy *) xdg_shell);
349 }
350 
351 static inline uint32_t
352 zxdg_shell_v5_get_version(struct xdg_shell *xdg_shell)
353 {
354  return wl_proxy_get_version((struct wl_proxy *) xdg_shell);
355 }
356 
366 static inline void
367 zxdg_shell_v5_destroy(struct xdg_shell *xdg_shell)
368 {
369  wl_proxy_marshal((struct wl_proxy *) xdg_shell,
370  ZXDG_SHELL_V5_DESTROY);
371 
372  wl_proxy_destroy((struct wl_proxy *) xdg_shell);
373 }
374 
384 static inline void
385 zxdg_shell_v5_use_unstable_version(struct xdg_shell *xdg_shell, int32_t version)
386 {
387  wl_proxy_marshal((struct wl_proxy *) xdg_shell,
388  ZXDG_SHELL_V5_USE_UNSTABLE_VERSION, version);
389 }
390 
403 static inline struct xdg_surface *
404 zxdg_shell_v5_get_xdg_surface(struct xdg_shell *xdg_shell, struct wl_surface *surface)
405 {
406  struct wl_proxy *id;
407 
408  id = wl_proxy_marshal_constructor((struct wl_proxy *) xdg_shell,
409  ZXDG_SHELL_V5_GET_ZXDG_SURFACE_V5, &zxdg_surface_v5_interface, NULL, surface);
410 
411  return (struct xdg_surface *) id;
412 }
413 
429 static inline struct xdg_popup *
430 zxdg_shell_v5_get_xdg_popup(struct xdg_shell *xdg_shell, struct wl_surface *surface, struct wl_surface *parent, struct wl_seat *seat, uint32_t serial, int32_t x, int32_t y)
431 {
432  struct wl_proxy *id;
433 
434  id = wl_proxy_marshal_constructor((struct wl_proxy *) xdg_shell,
435  ZXDG_SHELL_V5_GET_ZXDG_POPUP_V5, &zxdg_popup_v5_interface, NULL, surface, parent, seat, serial, x, y);
436 
437  return (struct xdg_popup *) id;
438 }
439 
446 static inline void
447 zxdg_shell_v5_pong(struct xdg_shell *xdg_shell, uint32_t serial)
448 {
449  wl_proxy_marshal((struct wl_proxy *) xdg_shell,
450  ZXDG_SHELL_V5_PONG, serial);
451 }
452 
453 #ifndef ZXDG_SURFACE_V5_RESIZE_EDGE_ENUM
454 #define ZXDG_SURFACE_V5_RESIZE_EDGE_ENUM
455 
462 enum zxdg_surface_v5_resize_edge {
463  ZXDG_SURFACE_V5_RESIZE_EDGE_NONE = 0,
464  ZXDG_SURFACE_V5_RESIZE_EDGE_TOP = 1,
465  ZXDG_SURFACE_V5_RESIZE_EDGE_BOTTOM = 2,
466  ZXDG_SURFACE_V5_RESIZE_EDGE_LEFT = 4,
467  ZXDG_SURFACE_V5_RESIZE_EDGE_TOP_LEFT = 5,
468  ZXDG_SURFACE_V5_RESIZE_EDGE_BOTTOM_LEFT = 6,
469  ZXDG_SURFACE_V5_RESIZE_EDGE_RIGHT = 8,
470  ZXDG_SURFACE_V5_RESIZE_EDGE_TOP_RIGHT = 9,
471  ZXDG_SURFACE_V5_RESIZE_EDGE_BOTTOM_RIGHT = 10,
472 };
473 #endif /* ZXDG_SURFACE_V5_RESIZE_EDGE_ENUM */
474 
475 #ifndef ZXDG_SURFACE_V5_STATE_ENUM
476 #define ZXDG_SURFACE_V5_STATE_ENUM
477 
485 enum zxdg_surface_v5_state {
502 };
503 #endif /* ZXDG_SURFACE_V5_STATE_ENUM */
504 
509 struct zxdg_surface_v5_listener {
539  void (*configure)(void *data,
540  struct xdg_surface *xdg_surface,
541  int32_t width,
542  int32_t height,
543  struct wl_array *states,
544  uint32_t serial);
557  void (*close)(void *data,
558  struct xdg_surface *xdg_surface);
559 };
560 
564 static inline int
565 zxdg_surface_v5_add_listener(struct xdg_surface *xdg_surface,
566  const struct zxdg_surface_v5_listener *listener, void *data)
567 {
568  return wl_proxy_add_listener((struct wl_proxy *) xdg_surface,
569  (void (**)(void)) listener, data);
570 }
571 
572 #define ZXDG_SURFACE_V5_DESTROY 0
573 #define ZXDG_SURFACE_V5_SET_PARENT 1
574 #define ZXDG_SURFACE_V5_SET_TITLE 2
575 #define ZXDG_SURFACE_V5_SET_APP_ID 3
576 #define ZXDG_SURFACE_V5_SHOW_WINDOW_MENU 4
577 #define ZXDG_SURFACE_V5_MOVE 5
578 #define ZXDG_SURFACE_V5_RESIZE 6
579 #define ZXDG_SURFACE_V5_ACK_CONFIGURE 7
580 #define ZXDG_SURFACE_V5_SET_WINDOW_GEOMETRY 8
581 #define ZXDG_SURFACE_V5_SET_MAXIMIZED 9
582 #define ZXDG_SURFACE_V5_UNSET_MAXIMIZED 10
583 #define ZXDG_SURFACE_V5_SET_FULLSCREEN 11
584 #define ZXDG_SURFACE_V5_UNSET_FULLSCREEN 12
585 #define ZXDG_SURFACE_V5_SET_MINIMIZED 13
586 
590 #define ZXDG_SURFACE_V5_CONFIGURE_SINCE_VERSION 1
591 
594 #define ZXDG_SURFACE_V5_CLOSE_SINCE_VERSION 1
595 
599 #define ZXDG_SURFACE_V5_DESTROY_SINCE_VERSION 1
600 
603 #define ZXDG_SURFACE_V5_SET_PARENT_SINCE_VERSION 1
604 
607 #define ZXDG_SURFACE_V5_SET_TITLE_SINCE_VERSION 1
608 
611 #define ZXDG_SURFACE_V5_SET_APP_ID_SINCE_VERSION 1
612 
615 #define ZXDG_SURFACE_V5_SHOW_WINDOW_MENU_SINCE_VERSION 1
616 
619 #define ZXDG_SURFACE_V5_MOVE_SINCE_VERSION 1
620 
623 #define ZXDG_SURFACE_V5_RESIZE_SINCE_VERSION 1
624 
627 #define ZXDG_SURFACE_V5_ACK_CONFIGURE_SINCE_VERSION 1
628 
631 #define ZXDG_SURFACE_V5_SET_WINDOW_GEOMETRY_SINCE_VERSION 1
632 
635 #define ZXDG_SURFACE_V5_SET_MAXIMIZED_SINCE_VERSION 1
636 
639 #define ZXDG_SURFACE_V5_UNSET_MAXIMIZED_SINCE_VERSION 1
640 
643 #define ZXDG_SURFACE_V5_SET_FULLSCREEN_SINCE_VERSION 1
644 
647 #define ZXDG_SURFACE_V5_UNSET_FULLSCREEN_SINCE_VERSION 1
648 
651 #define ZXDG_SURFACE_V5_SET_MINIMIZED_SINCE_VERSION 1
652 
654 static inline void
655 zxdg_surface_v5_set_user_data(struct xdg_surface *xdg_surface, void *user_data)
656 {
657  wl_proxy_set_user_data((struct wl_proxy *) xdg_surface, user_data);
658 }
659 
661 static inline void *
662 zxdg_surface_v5_get_user_data(struct xdg_surface *xdg_surface)
663 {
664  return wl_proxy_get_user_data((struct wl_proxy *) xdg_surface);
665 }
666 
667 static inline uint32_t
668 zxdg_surface_v5_get_version(struct xdg_surface *xdg_surface)
669 {
670  return wl_proxy_get_version((struct wl_proxy *) xdg_surface);
671 }
672 
680 static inline void
681 zxdg_surface_v5_destroy(struct xdg_surface *xdg_surface)
682 {
683  wl_proxy_marshal((struct wl_proxy *) xdg_surface,
684  ZXDG_SURFACE_V5_DESTROY);
685 
686  wl_proxy_destroy((struct wl_proxy *) xdg_surface);
687 }
688 
700 static inline void
701 zxdg_surface_v5_set_parent(struct xdg_surface *xdg_surface, struct xdg_surface *parent)
702 {
703  wl_proxy_marshal((struct wl_proxy *) xdg_surface,
704  ZXDG_SURFACE_V5_SET_PARENT, parent);
705 }
706 
718 static inline void
719 zxdg_surface_v5_set_title(struct xdg_surface *xdg_surface, const char *title)
720 {
721  wl_proxy_marshal((struct wl_proxy *) xdg_surface,
722  ZXDG_SURFACE_V5_SET_TITLE, title);
723 }
724 
749 static inline void
750 zxdg_surface_v5_set_app_id(struct xdg_surface *xdg_surface, const char *app_id)
751 {
752  wl_proxy_marshal((struct wl_proxy *) xdg_surface,
753  ZXDG_SURFACE_V5_SET_APP_ID, app_id);
754 }
755 
771 static inline void
772 zxdg_surface_v5_show_window_menu(struct xdg_surface *xdg_surface, struct wl_seat *seat, uint32_t serial, int32_t x, int32_t y)
773 {
774  wl_proxy_marshal((struct wl_proxy *) xdg_surface,
775  ZXDG_SURFACE_V5_SHOW_WINDOW_MENU, seat, serial, x, y);
776 }
777 
798 static inline void
799 zxdg_surface_v5_move(struct xdg_surface *xdg_surface, struct wl_seat *seat, uint32_t serial)
800 {
801  wl_proxy_marshal((struct wl_proxy *) xdg_surface,
802  ZXDG_SURFACE_V5_MOVE, seat, serial);
803 }
804 
839 static inline void
840 zxdg_surface_v5_resize(struct xdg_surface *xdg_surface, struct wl_seat *seat, uint32_t serial, uint32_t edges)
841 {
842  wl_proxy_marshal((struct wl_proxy *) xdg_surface,
843  ZXDG_SURFACE_V5_RESIZE, seat, serial, edges);
844 }
845 
869 static inline void
870 zxdg_surface_v5_ack_configure(struct xdg_surface *xdg_surface, uint32_t serial)
871 {
872  wl_proxy_marshal((struct wl_proxy *) xdg_surface,
873  ZXDG_SURFACE_V5_ACK_CONFIGURE, serial);
874 }
875 
905 static inline void
906 zxdg_surface_v5_set_window_geometry(struct xdg_surface *xdg_surface, int32_t x, int32_t y, int32_t width, int32_t height)
907 {
908  wl_proxy_marshal((struct wl_proxy *) xdg_surface,
909  ZXDG_SURFACE_V5_SET_WINDOW_GEOMETRY, x, y, width, height);
910 }
911 
932 static inline void
933 zxdg_surface_v5_set_maximized(struct xdg_surface *xdg_surface)
934 {
935  wl_proxy_marshal((struct wl_proxy *) xdg_surface,
936  ZXDG_SURFACE_V5_SET_MAXIMIZED);
937 }
938 
960 static inline void
961 zxdg_surface_v5_unset_maximized(struct xdg_surface *xdg_surface)
962 {
963  wl_proxy_marshal((struct wl_proxy *) xdg_surface,
964  ZXDG_SURFACE_V5_UNSET_MAXIMIZED);
965 }
966 
980 static inline void
981 zxdg_surface_v5_set_fullscreen(struct xdg_surface *xdg_surface, struct wl_output *output)
982 {
983  wl_proxy_marshal((struct wl_proxy *) xdg_surface,
984  ZXDG_SURFACE_V5_SET_FULLSCREEN, output);
985 }
986 
990 static inline void
991 zxdg_surface_v5_unset_fullscreen(struct xdg_surface *xdg_surface)
992 {
993  wl_proxy_marshal((struct wl_proxy *) xdg_surface,
994  ZXDG_SURFACE_V5_UNSET_FULLSCREEN);
995 }
996 
1009 static inline void
1010 zxdg_surface_v5_set_minimized(struct xdg_surface *xdg_surface)
1011 {
1012  wl_proxy_marshal((struct wl_proxy *) xdg_surface,
1013  ZXDG_SURFACE_V5_SET_MINIMIZED);
1014 }
1015 
1020 struct zxdg_popup_v5_listener {
1028  void (*popup_done)(void *data,
1029  struct xdg_popup *xdg_popup);
1030 };
1031 
1035 static inline int
1036 zxdg_popup_v5_add_listener(struct xdg_popup *xdg_popup,
1037  const struct zxdg_popup_v5_listener *listener, void *data)
1038 {
1039  return wl_proxy_add_listener((struct wl_proxy *) xdg_popup,
1040  (void (**)(void)) listener, data);
1041 }
1042 
1043 #define ZXDG_POPUP_V5_DESTROY 0
1044 
1048 #define ZXDG_POPUP_V5_POPUP_DONE_SINCE_VERSION 1
1049 
1053 #define ZXDG_POPUP_V5_DESTROY_SINCE_VERSION 1
1054 
1056 static inline void
1057 zxdg_popup_v5_set_user_data(struct xdg_popup *xdg_popup, void *user_data)
1058 {
1059  wl_proxy_set_user_data((struct wl_proxy *) xdg_popup, user_data);
1060 }
1061 
1063 static inline void *
1064 zxdg_popup_v5_get_user_data(struct xdg_popup *xdg_popup)
1065 {
1066  return wl_proxy_get_user_data((struct wl_proxy *) xdg_popup);
1067 }
1068 
1069 static inline uint32_t
1070 zxdg_popup_v5_get_version(struct xdg_popup *xdg_popup)
1071 {
1072  return wl_proxy_get_version((struct wl_proxy *) xdg_popup);
1073 }
1074 
1084 static inline void
1085 zxdg_popup_v5_destroy(struct xdg_popup *xdg_popup)
1086 {
1087  wl_proxy_marshal((struct wl_proxy *) xdg_popup,
1088  ZXDG_POPUP_V5_DESTROY);
1089 
1090  wl_proxy_destroy((struct wl_proxy *) xdg_popup);
1091 }
1092 
1093 #ifdef __cplusplus
1094 }
1095 #endif
1096 
1097 #endif
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Fri Aug 7 2020 22:48:20 by doxygen 1.8.11 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.