package wayland
Pure OCaml Wayland protocol library
Install
Dune Dependency
Authors
Maintainers
Sources
wayland-2.1.tbz
sha256=0ffb53958954f1ed4ef874a122c071a9cf3de77ae341b963eb7b513d8028f3c1
sha512=e391b91b4161ada44339bb97b0acf40a0ef3d3c8f62a114333a61155b70288b31b5904492ebbf187bad957849ff6e1df172d014f46ffc33db7140fa833449f5c
doc/src/wayland.protocols/wlr_layer_shell_unstable_v1_proto.ml.html
Source file wlr_layer_shell_unstable_v1_proto.ml
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214
(* This file was generated automatically by wayland-scanner-ocaml *) open struct module Proxy = Wayland.Proxy module Iface_reg = Wayland.Iface_reg module Metadata = Wayland.Metadata end module Zwlr_layer_shell_v1 = struct type t = [`Zwlr_layer_shell_v1] type _ Metadata.ty += T : [`Zwlr_layer_shell_v1] Metadata.ty type versions = [`V1 | `V2 | `V3 | `V4 | `V5] let interface = "zwlr_layer_shell_v1" let version = 5l module Error = struct type t = | Role : t | Invalid_layer : t | Already_constructed : t let to_int32 = function | Role -> 0l | Invalid_layer -> 1l | Already_constructed -> 2l let of_int32 = function | 0l -> Role | 1l -> Invalid_layer | 2l -> Already_constructed | x -> Fmt.failwith "Invalid error enum value %ld" x end (** Available layers for surfaces. These values indicate which layers a surface can be rendered in. They are ordered by z depth, bottom-most first. Traditional shell surfaces will typically be rendered between the bottom and top layers. Fullscreen shell surfaces are typically rendered at the top layer. Multiple surfaces can share a single layer, and ordering within a single layer is undefined. *) module Layer = struct type t = | Background : t | Bottom : t | Top : t | Overlay : t let to_int32 = function | Background -> 0l | Bottom -> 1l | Top -> 2l | Overlay -> 3l let of_int32 = function | 0l -> Background | 1l -> Bottom | 2l -> Top | 3l -> Overlay | x -> Fmt.failwith "Invalid layer enum value %ld" x end let requests = function | 0 -> "get_layer_surface", ["id", `New_ID (Some "zwlr_layer_surface_v1"); "surface", `Object (Some "wl_surface"); "output", `Object (Some "wl_output"); "layer", `Uint; "namespace", `String] | 1 -> "destroy", [] | i -> Proxy.unknown_request i, [] let events = function | i -> Proxy.unknown_event i, [] end let () = Iface_reg.register (module Zwlr_layer_shell_v1) module Zwlr_layer_surface_v1 = struct type t = [`Zwlr_layer_surface_v1] type _ Metadata.ty += T : [`Zwlr_layer_surface_v1] Metadata.ty type versions = [`V1 | `V2 | `V3 | `V4 | `V5] let interface = "zwlr_layer_surface_v1" let version = 5l (** Types of keyboard interaction possible for a layer shell surface. Types of keyboard interaction possible for layer shell surfaces. The rationale for this is twofold: (1) some applications are not interested in keyboard events and not allowing them to be focused can improve the desktop experience; (2) some applications will want to take exclusive keyboard focus. *) module Keyboard_interactivity = struct type t = | None : t (** No keyboard focus is possible. This value indicates that this surface is not interested in keyboard events and the compositor should never assign it the keyboard focus. This is the default value, set for newly created layer shell surfaces. This is useful for e.g. desktop widgets that display information or only have interaction with non-keyboard input devices. *) | Exclusive : t (** Request exclusive keyboard focus. Request exclusive keyboard focus if this surface is above the shell surface layer. For the top and overlay layers, the seat will always give exclusive keyboard focus to the top-most layer which has keyboard interactivity set to exclusive. If this layer contains multiple surfaces with keyboard interactivity set to exclusive, the compositor determines the one receiving keyboard events in an implementation- defined manner. In this case, no guarantee is made when this surface will receive keyboard focus (if ever). For the bottom and background layers, the compositor is allowed to use normal focus semantics. This setting is mainly intended for applications that need to ensure they receive all keyboard events, such as a lock screen or a password prompt. *) | On_demand : t (** Request regular keyboard focus semantics. This requests the compositor to allow this surface to be focused and unfocused by the user in an implementation-defined manner. The user should be able to unfocus this surface even regardless of the layer it is on. Typically, the compositor will want to use its normal mechanism to manage keyboard focus between layer shell surfaces with this setting and regular toplevels on the desktop layer (e.g. click to focus). Nevertheless, it is possible for a compositor to require a special interaction to focus or unfocus layer shell surfaces (e.g. requiring a click even if focus follows the mouse normally, or providing a keybinding to switch focus between layers). This setting is mainly intended for desktop shell components (e.g. panels) that allow keyboard interaction. Using this option can allow implementing a desktop shell that can be fully usable without the mouse. *) let to_int32 = function | None -> 0l | Exclusive -> 1l | On_demand -> 2l let of_int32 = function | 0l -> None | 1l -> Exclusive | 2l -> On_demand | x -> Fmt.failwith "Invalid keyboard_interactivity enum value %ld" x end module Error = struct type t = | Invalid_surface_state : t | Invalid_size : t | Invalid_anchor : t | Invalid_keyboard_interactivity : t | Invalid_exclusive_edge : t let to_int32 = function | Invalid_surface_state -> 0l | Invalid_size -> 1l | Invalid_anchor -> 2l | Invalid_keyboard_interactivity -> 3l | Invalid_exclusive_edge -> 4l let of_int32 = function | 0l -> Invalid_surface_state | 1l -> Invalid_size | 2l -> Invalid_anchor | 3l -> Invalid_keyboard_interactivity | 4l -> Invalid_exclusive_edge | x -> Fmt.failwith "Invalid error enum value %ld" x end module Anchor = struct type t = int32 let top = 1l let bottom = 2l let left = 4l let right = 8l let to_int32 = Fun.id let of_int32 = Fun.id end let requests = function | 0 -> "set_size", ["width", `Uint; "height", `Uint] | 1 -> "set_anchor", ["anchor", `Uint] | 2 -> "set_exclusive_zone", ["zone", `Int] | 3 -> "set_margin", ["top", `Int; "right", `Int; "bottom", `Int; "left", `Int] | 4 -> "set_keyboard_interactivity", ["keyboard_interactivity", `Uint] | 5 -> "get_popup", ["popup", `Object (Some "xdg_popup")] | 6 -> "ack_configure", ["serial", `Uint] | 7 -> "destroy", [] | 8 -> "set_layer", ["layer", `Uint] | 9 -> "set_exclusive_edge", ["edge", `Uint] | i -> Proxy.unknown_request i, [] let events = function | 0 -> "configure", ["serial", `Uint; "width", `Uint; "height", `Uint] | 1 -> "closed", [] | i -> Proxy.unknown_event i, [] end let () = Iface_reg.register (module Zwlr_layer_surface_v1)
sectionYPositions = computeSectionYPositions($el), 10)"
x-init="setTimeout(() => sectionYPositions = computeSectionYPositions($el), 10)"
>