├── .editorconfig
├── .gitignore
├── .gitmodules
├── .prettierignore
├── .prettierrc.json
├── LICENSE
├── README.md
├── netlify.toml
├── package.json
├── protocols
└── external
│ ├── agl-screenshooter.xml
│ ├── agl-shell-desktop.xml
│ ├── agl-shell.xml
│ ├── aura-output-management.xml
│ ├── aura-shell.xml
│ ├── chrome-color-management.xml
│ ├── gtk-shell.xml
│ ├── input-method-unstable-v2.xml
│ ├── mir-shell-unstable-v1.xml
│ ├── nvidia-eglstream-controller.xml
│ ├── nvidia-eglstream.xml
│ ├── overlay-prioritizer.xml
│ ├── surface-augmenter.xml
│ ├── tizen-extension.xml
│ ├── virtual-keyboard-unstable-v1.xml
│ └── wayland-drm.xml
├── public
├── android-chrome-192x192.png
├── android-chrome-512x512.png
├── apple-touch-icon.png
├── browserconfig.xml
├── favicon-16x16.png
├── favicon-32x32.png
├── favicon.ico
├── index.html
├── logo.svg
├── logos
│ ├── Steam_Deck.svg
│ ├── cosmic.svg
│ ├── deepin.svg
│ ├── gnome.svg
│ ├── hyprland.svg
│ ├── kde.svg
│ ├── labwc.svg
│ ├── louvre.svg
│ ├── mir.svg
│ ├── sway.svg
│ ├── wayfire.svg
│ └── weston.svg
├── manifest.json
├── mstile-144x144.png
├── mstile-150x150.png
├── mstile-310x150.png
├── mstile-310x310.png
├── mstile-70x70.png
├── robots.txt
└── safari-pinned-tab.svg
├── scripts
├── bin
│ ├── print-protocol-registry-items.ts
│ ├── regenerate-protocols-data.ts
│ └── render-static-html.tsx
└── lib
│ └── utils.ts
├── src
├── App.test.tsx
├── App.tsx
├── analytics
│ └── plausible.ts
├── components
│ ├── WaylandArg.tsx
│ ├── WaylandCompositors.tsx
│ ├── WaylandCopyright.tsx
│ ├── WaylandDataTable.tsx
│ ├── WaylandDescription.tsx
│ ├── WaylandEntry.tsx
│ ├── WaylandEnum.tsx
│ ├── WaylandEvent.tsx
│ ├── WaylandInterface.tsx
│ ├── WaylandProtocol.tsx
│ ├── WaylandRequest.tsx
│ ├── breadcrumbs
│ │ └── Breadcrumbs.tsx
│ ├── common
│ │ ├── hooks-utils.ts
│ │ ├── index.ts
│ │ ├── utils.ts
│ │ └── wayland-protocol-icons.ts
│ ├── content
│ │ ├── Badge.tsx
│ │ ├── ProtocolBadge.tsx
│ │ └── WaylandElementSignature.tsx
│ ├── layout
│ │ ├── Footer.tsx
│ │ ├── Header.tsx
│ │ ├── Logo.tsx
│ │ ├── MultiColumnLayout.tsx
│ │ ├── ScrollToTop.tsx
│ │ └── overlays
│ │ │ ├── OutlineOverlay.tsx
│ │ │ ├── OverlayBackground.tsx
│ │ │ └── SidebarOverlay.tsx
│ ├── outline
│ │ ├── WaylandInterfaceOutline.tsx
│ │ └── WaylandProtocolOutline.tsx
│ └── sidebar-navigation
│ │ ├── SidebarNavLink.tsx
│ │ └── WaylandProtocolLinks.tsx
├── config
│ └── index.ts
├── data
│ ├── compositor-registry.ts
│ ├── compositors
│ │ ├── README.md
│ │ ├── cage.json
│ │ ├── cosmic.json
│ │ ├── gamescope.json
│ │ ├── hyprland.json
│ │ ├── jay.json
│ │ ├── kwin.json
│ │ ├── labwc.json
│ │ ├── louvre.json
│ │ ├── mir.json
│ │ ├── mutter.json
│ │ ├── niri.json
│ │ ├── sway.json
│ │ ├── treeland.json
│ │ ├── wayfire.json
│ │ └── weston.json
│ ├── protocol-registry.ts
│ └── protocols
│ │ ├── agl-screenshooter.json
│ │ ├── agl-shell-desktop.json
│ │ ├── agl-shell.json
│ │ ├── alpha-modifier-v1.json
│ │ ├── aura-output-management.json
│ │ ├── aura-shell.json
│ │ ├── chrome-color-management.json
│ │ ├── color-management-v1.json
│ │ ├── commit-timing-v1.json
│ │ ├── content-type-v1.json
│ │ ├── cosmic-image-source-unstable-v1.json
│ │ ├── cosmic-output-management-unstable-v1.json
│ │ ├── cosmic-screencopy-unstable-v1.json
│ │ ├── cosmic-screencopy-unstable-v2.json
│ │ ├── cosmic-toplevel-info-unstable-v1.json
│ │ ├── cosmic-toplevel-management-unstable-v1.json
│ │ ├── cosmic-workspace-unstable-v1.json
│ │ ├── cursor-shape-v1.json
│ │ ├── drm-lease-v1.json
│ │ ├── ext-data-control-v1.json
│ │ ├── ext-foreign-toplevel-list-v1.json
│ │ ├── ext-idle-notify-v1.json
│ │ ├── ext-image-capture-source-v1.json
│ │ ├── ext-image-copy-capture-v1.json
│ │ ├── ext-session-lock-v1.json
│ │ ├── ext-transient-seat-v1.json
│ │ ├── ext-workspace-v1.json
│ │ ├── fifo-v1.json
│ │ ├── fractional-scale-v1.json
│ │ ├── fullscreen-shell-unstable-v1.json
│ │ ├── gtk-shell.json
│ │ ├── hyprland-ctm-control-v1.json
│ │ ├── hyprland-focus-grab-v1.json
│ │ ├── hyprland-global-shortcuts-v1.json
│ │ ├── hyprland-lock-notify-v1.json
│ │ ├── hyprland-surface-v1.json
│ │ ├── hyprland-toplevel-export-v1.json
│ │ ├── hyprland-toplevel-mapping-v1.json
│ │ ├── idle-inhibit-unstable-v1.json
│ │ ├── input-method-unstable-v1.json
│ │ ├── input-method-unstable-v2.json
│ │ ├── input-timestamps-unstable-v1.json
│ │ ├── ivi-application.json
│ │ ├── ivi-hmi-controller.json
│ │ ├── kde-appmenu.json
│ │ ├── kde-blur.json
│ │ ├── kde-contrast.json
│ │ ├── kde-dpms.json
│ │ ├── kde-external-brightness-v1.json
│ │ ├── kde-fake-input.json
│ │ ├── kde-idle.json
│ │ ├── kde-keystate.json
│ │ ├── kde-lockscreen-overlay-v1.json
│ │ ├── kde-output-device-v2.json
│ │ ├── kde-output-management-v2.json
│ │ ├── kde-output-management.json
│ │ ├── kde-output-order-v1.json
│ │ ├── kde-outputdevice.json
│ │ ├── kde-plasma-shell.json
│ │ ├── kde-plasma-virtual-desktop.json
│ │ ├── kde-plasma-window-management.json
│ │ ├── kde-primary-output-v1.json
│ │ ├── kde-screen-edge-v1.json
│ │ ├── kde-server-decoration-palette.json
│ │ ├── kde-server-decoration.json
│ │ ├── kde-shadow.json
│ │ ├── kde-slide.json
│ │ ├── kde-zkde-screencast-unstable-v1.json
│ │ ├── keyboard-shortcuts-inhibit-unstable-v1.json
│ │ ├── linux-dmabuf-unstable-v1.json
│ │ ├── linux-dmabuf-v1.json
│ │ ├── linux-drm-syncobj-v1.json
│ │ ├── linux-explicit-synchronization-unstable-v1.json
│ │ ├── mir-shell-unstable-v1.json
│ │ ├── nvidia-eglstream-controller.json
│ │ ├── nvidia-eglstream.json
│ │ ├── overlay-prioritizer.json
│ │ ├── pointer-constraints-unstable-v1.json
│ │ ├── pointer-gestures-unstable-v1.json
│ │ ├── presentation-time.json
│ │ ├── primary-selection-unstable-v1.json
│ │ ├── relative-pointer-unstable-v1.json
│ │ ├── security-context-v1.json
│ │ ├── single-pixel-buffer-v1.json
│ │ ├── surface-augmenter.json
│ │ ├── tablet-unstable-v2.json
│ │ ├── tablet-v2.json
│ │ ├── tearing-control-v1.json
│ │ ├── text-cursor-position.json
│ │ ├── text-input-unstable-v3.json
│ │ ├── tizen-extension.json
│ │ ├── treeland-capture-unstable-v1.json
│ │ ├── treeland-dde-shell-v1.json
│ │ ├── treeland-foreign-toplevel-manager-v1.json
│ │ ├── treeland-output-manager-v1.json
│ │ ├── treeland-personalization-manager-v1.json
│ │ ├── treeland-shortcut-manager-v1.json
│ │ ├── treeland-virtual-output-manager-v1.json
│ │ ├── treeland-wallpaper-color-v1.json
│ │ ├── treeland-window-management-v1.json
│ │ ├── viewporter.json
│ │ ├── virtual-keyboard-unstable-v1.json
│ │ ├── wayland-drm.json
│ │ ├── wayland.json
│ │ ├── weston-content-protection.json
│ │ ├── weston-debug.json
│ │ ├── weston-desktop-shell.json
│ │ ├── weston-direct-display.json
│ │ ├── weston-output-capture.json
│ │ ├── weston-test.json
│ │ ├── weston-touch-calibration.json
│ │ ├── wlr-data-control-unstable-v1.json
│ │ ├── wlr-export-dmabuf-unstable-v1.json
│ │ ├── wlr-foreign-toplevel-management-unstable-v1.json
│ │ ├── wlr-gamma-control-unstable-v1.json
│ │ ├── wlr-input-inhibitor-unstable-v1.json
│ │ ├── wlr-layer-shell-unstable-v1.json
│ │ ├── wlr-output-management-unstable-v1.json
│ │ ├── wlr-output-power-management-unstable-v1.json
│ │ ├── wlr-screencopy-unstable-v1.json
│ │ ├── wlr-virtual-pointer-unstable-v1.json
│ │ ├── xdg-activation-v1.json
│ │ ├── xdg-decoration-unstable-v1.json
│ │ ├── xdg-dialog-v1.json
│ │ ├── xdg-foreign-unstable-v2.json
│ │ ├── xdg-output-unstable-v1.json
│ │ ├── xdg-shell.json
│ │ ├── xdg-system-bell-v1.json
│ │ ├── xdg-toplevel-drag-v1.json
│ │ ├── xdg-toplevel-icon-v1.json
│ │ ├── xdg-toplevel-tag-v1.json
│ │ ├── xwayland-keyboard-grab-unstable-v1.json
│ │ └── xwayland-shell-v1.json
├── gitlab-api
│ └── index.ts
├── index.css
├── index.tsx
├── lib
│ └── xml-protocol-transformers.ts
├── logo.svg
├── model
│ ├── protocol-source-link-builder.ts
│ ├── wayland-protocol-metadata.ts
│ └── wayland.ts
├── pages
│ ├── 404.tsx
│ ├── GitLab.tsx
│ └── Homepage.tsx
├── react-app-env.d.ts
├── reportWebVitals.ts
└── setupTests.ts
├── tailwind.config.js
├── tsconfig.json
├── tsconfig.scripts.json
└── yarn.lock
/.editorconfig:
--------------------------------------------------------------------------------
1 | root=true
2 |
3 | [*]
4 | indent_style = space
5 | indent_size = 4
6 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files.
2 |
3 | # dependencies
4 | /node_modules
5 | /.pnp
6 | .pnp.js
7 |
8 | # testing
9 | /coverage
10 |
11 | # production
12 | /build
13 |
14 | # misc
15 | .DS_Store
16 | .env.local
17 | .env.development.local
18 | .env.test.local
19 | .env.production.local
20 |
21 | npm-debug.log*
22 | yarn-debug.log*
23 | yarn-error.log*
24 |
--------------------------------------------------------------------------------
/.gitmodules:
--------------------------------------------------------------------------------
1 | [submodule "protocols/wayland"]
2 | path = protocols/wayland
3 | url = https://gitlab.freedesktop.org/wayland/wayland-protocols.git
4 | [submodule "protocols/wlr"]
5 | path = protocols/wlr
6 | url = https://gitlab.freedesktop.org/wlroots/wlr-protocols.git
7 | [submodule "protocols/kde"]
8 | path = protocols/kde
9 | url = https://invent.kde.org/libraries/plasma-wayland-protocols.git
10 | [submodule "protocols/weston"]
11 | path = protocols/weston
12 | url = https://gitlab.freedesktop.org/wayland/weston.git
13 | [submodule "protocols/libwayland"]
14 | path = protocols/libwayland
15 | url = https://gitlab.freedesktop.org/wayland/wayland.git
16 | [submodule "protocols/hyprland"]
17 | path = protocols/hyprland
18 | url = https://github.com/hyprwm/hyprland-protocols.git
19 | [submodule "protocols/treeland"]
20 | path = protocols/treeland
21 | url = https://github.com/linuxdeepin/treeland-protocols.git
22 |
--------------------------------------------------------------------------------
/.prettierignore:
--------------------------------------------------------------------------------
1 | /protocols/
2 | /src/data/protocols/
3 | /src/data/compositors/
4 | /build/
5 |
--------------------------------------------------------------------------------
/.prettierrc.json:
--------------------------------------------------------------------------------
1 | {
2 | "tabWidth": 4,
3 | "semi": false,
4 | "singleQuote": true
5 | }
6 |
--------------------------------------------------------------------------------
/LICENSE:
--------------------------------------------------------------------------------
1 | MIT License
2 |
3 | Copyright (c) 2025 Valentin Hăloiu
4 |
5 | Permission is hereby granted, free of charge, to any person obtaining a copy
6 | of this software and associated documentation files (the "Software"), to deal
7 | in the Software without restriction, including without limitation the rights
8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9 | copies of the Software, and to permit persons to whom the Software is
10 | furnished to do so, subject to the following conditions:
11 |
12 | The above copyright notice and this permission notice shall be included in all
13 | copies or substantial portions of the Software.
14 |
15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21 | SOFTWARE.
22 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # Wayland Explorer
2 |
3 | Easily browse and read Wayland protocols documentation.
4 |
5 | ## Motivation for this project
6 |
7 | Wayland protocols are published as XML files. While the [core Wayland protocol](https://gitlab.freedesktop.org/wayland/wayland/-/blob/main/protocol/wayland.xml) specification is also available in HTML format for reading [online](https://wayland.freedesktop.org/docs/html/apa.html), that's not the case for all the [other](https://gitlab.freedesktop.org/wayland/wayland-protocols/-/tree/main/unstable) [Wayland](https://gitlab.freedesktop.org/wayland/wayland-protocols/-/tree/main/stable) [protocols](https://gitlab.freedesktop.org/wlroots/wlr-protocols/-/tree/master/unstable) which are not part of the core protocol.
8 |
9 | This project attempts to fill this gap by parsing the XML protocol files and converting them to HTML in order to make it easy to browse and read them on the web.
10 |
11 | ## Technologies
12 |
13 | Built with :sparkling_heart: using React, [Tailwind UI](https://tailwindui.com/components) and [vscode-codicons](https://github.com/microsoft/vscode-codicons).
14 |
15 | ## Disclaimer
16 |
17 | This project has no affiliation with the official Wayland project.
18 |
--------------------------------------------------------------------------------
/netlify.toml:
--------------------------------------------------------------------------------
1 | [build.environment]
2 | NODE_VERSION = "14"
3 |
4 | [[redirects]]
5 | from = "/api/event"
6 | to = "https://plausible.io/api/event"
7 | status = 200
8 |
9 | [[redirects]]
10 | from = "/"
11 | to = "/protocols/"
12 |
13 | [[redirects]]
14 | from = "/protocols/kde-screencast"
15 | to = "/protocols/kde-zkde-screencast-unstable-v1"
16 |
17 | [[redirects]]
18 | from = "/protocols/linux-dmabuf-unstable-v1"
19 | to = "/protocols/linux-dmabuf-v1"
20 |
21 | [[redirects]]
22 | from = "/protocols/tablet-unstable-v2"
23 | to = "/protocols/tablet-v2"
24 |
25 | [[redirects]]
26 | from = "/protocols/wayland-protocols/*"
27 | to = "/protocols/wayland-protocols-gitlab.html"
28 | status = 200
29 | force = true
30 |
31 | [[redirects]]
32 | from = "/protocols/*"
33 | to = "/protocols/404.html"
34 | status = 404
35 |
--------------------------------------------------------------------------------
/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "wayland-explorer",
3 | "description": "Wayland protocol explorer",
4 | "version": "0.1.0",
5 | "private": true,
6 | "license": "MIT",
7 | "homepage": "/protocols",
8 | "dependencies": {
9 | "@headlessui/react": "^1.4.1",
10 | "@vscode/codicons": "^0.0.21",
11 | "fast-xml-parser": "^4.5.0",
12 | "plausible-tracker": "^0.3.1",
13 | "react": "^17.0.2",
14 | "react-dom": "^17.0.2",
15 | "react-scripts": "5.0.0",
16 | "web-vitals": "^2.1.0",
17 | "wouter": "^2.7.4"
18 | },
19 | "scripts": {
20 | "start": "react-scripts start",
21 | "build": "env BUILD_PATH=build/protocols react-scripts build",
22 | "postbuild": "ts-node --project=./tsconfig.scripts.json ./scripts/bin/render-static-html.tsx",
23 | "test": "react-scripts test",
24 | "regenerate-protocols": "ts-node --project=./tsconfig.scripts.json ./scripts/bin/regenerate-protocols-data.ts",
25 | "print-registry": "ts-node --project=./tsconfig.scripts.json ./scripts/bin/print-protocol-registry-items.ts",
26 | "eject": "react-scripts eject"
27 | },
28 | "eslintConfig": {
29 | "extends": [
30 | "react-app",
31 | "react-app/jest"
32 | ]
33 | },
34 | "browserslist": {
35 | "production": [
36 | ">0.2%",
37 | "not dead",
38 | "not op_mini all"
39 | ],
40 | "development": [
41 | "last 1 chrome version",
42 | "last 1 firefox version",
43 | "last 1 safari version"
44 | ]
45 | },
46 | "husky": {
47 | "hooks": {
48 | "pre-commit": "lint-staged"
49 | }
50 | },
51 | "lint-staged": {
52 | "src/**/*.{js,jsx,ts,tsx,json,css,scss,md}": [
53 | "prettier --write"
54 | ]
55 | },
56 | "devDependencies": {
57 | "@testing-library/jest-dom": "^5.11.4",
58 | "@testing-library/react": "^12.0.0",
59 | "@testing-library/user-event": "^13.2.1",
60 | "@types/html-minifier": "^4.0.0",
61 | "@types/jest": "^27.0.1",
62 | "@types/node": "^16.7.10",
63 | "@types/react": "^17.0.0",
64 | "@types/react-dom": "^17.0.0",
65 | "autoprefixer": "^10.4.2",
66 | "html-minifier": "^4.0.0",
67 | "husky": "^7.0.2",
68 | "lint-staged": "^12.3.1",
69 | "postcss": "^8.4.5",
70 | "prettier": "^2.3.2",
71 | "tailwind-scrollbar": "^1.3.1",
72 | "tailwindcss": "^3.0.16",
73 | "ts-node": "^10.2.1",
74 | "typescript": "^4.4.2"
75 | }
76 | }
77 |
--------------------------------------------------------------------------------
/protocols/external/agl-screenshooter.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | Copyright © 2020 Collabora. Ltd,
6 |
7 | Permission is hereby granted, free of charge, to any person obtaining a
8 | copy of this software and associated documentation files (the "Software"),
9 | to deal in the Software without restriction, including without limitation
10 | the rights to use, copy, modify, merge, publish, distribute, sublicense,
11 | and/or sell copies of the Software, and to permit persons to whom the
12 | Software is furnished to do so, subject to the following conditions:
13 |
14 | The above copyright notice and this permission notice (including the next
15 | paragraph) shall be included in all copies or substantial portions of the
16 | Software.
17 |
18 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
19 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
20 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
21 | THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
22 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
23 | FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
24 | DEALINGS IN THE SOFTWARE.
25 |
26 |
27 |
28 |
29 | agl compositor extension that performs a screenshot of the output, which
30 | is represented by a 'wl_output' object.
31 |
32 | A client would call 'take_shot' request and wait until the compositor
33 | finishes to write the data to a wayland buffer, moment in which signals
34 | back the client with the help of the 'done' event. Clients should wait
35 | until the 'done' event is received, if they want to take another
36 | screenshot, or take another screnshot of a different output.
37 |
38 | The client must provide a wl_shm-based wl_buffer of the correct size when
39 | taking a shot. The compositor will write the shot into the wl_buffer and then
40 | send the 'done' event that signals completion of writing the data.
41 |
42 | Once the compositor has finished to transfer the data back into the supplied
43 | wayland buffer, the client should be able to transfer it to a popular
44 | file format on the disk.
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 | Takes a screenshot of the wayland output represented by a 'wl_output'
56 | object. Clients should first retrieve it using global registry, as well
57 | as the 'wl_shm' object in order to create a wayland buffer type of
58 | object ('wl_buffer').
59 |
60 | Clients can derive the stride and size from the 'wl_output' object, and
61 | later on use those when creating shm-based 'wl_buffer', as well as supplying
62 | the pixel format.
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 | Even sent back to notify client 'take_shot' request has completed.
72 |
73 |
74 |
75 |
76 |
77 |
78 | Destroys the 'weston_screenshooter' interface.
79 |
80 |
81 |
82 |
83 |
84 |
85 |
--------------------------------------------------------------------------------
/protocols/external/gtk-shell.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | gtk_shell is a protocol extension providing additional features for
6 | clients implementing it.
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 |
--------------------------------------------------------------------------------
/public/android-chrome-192x192.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vially/wayland-explorer/40253a7719f14f401329f526fbce8d46f55a482b/public/android-chrome-192x192.png
--------------------------------------------------------------------------------
/public/android-chrome-512x512.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vially/wayland-explorer/40253a7719f14f401329f526fbce8d46f55a482b/public/android-chrome-512x512.png
--------------------------------------------------------------------------------
/public/apple-touch-icon.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vially/wayland-explorer/40253a7719f14f401329f526fbce8d46f55a482b/public/apple-touch-icon.png
--------------------------------------------------------------------------------
/public/browserconfig.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | #da532c
7 |
8 |
9 |
10 |
--------------------------------------------------------------------------------
/public/favicon-16x16.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vially/wayland-explorer/40253a7719f14f401329f526fbce8d46f55a482b/public/favicon-16x16.png
--------------------------------------------------------------------------------
/public/favicon-32x32.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vially/wayland-explorer/40253a7719f14f401329f526fbce8d46f55a482b/public/favicon-32x32.png
--------------------------------------------------------------------------------
/public/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vially/wayland-explorer/40253a7719f14f401329f526fbce8d46f55a482b/public/favicon.ico
--------------------------------------------------------------------------------
/public/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
13 |
14 |
18 |
19 |
28 |
29 | Wayland Explorer
30 |
31 |
32 |
44 |
45 |
55 |
56 |
--------------------------------------------------------------------------------
/public/logo.svg:
--------------------------------------------------------------------------------
1 |
2 |
77 |
--------------------------------------------------------------------------------
/public/logos/Steam_Deck.svg:
--------------------------------------------------------------------------------
1 |
2 |
6 |
--------------------------------------------------------------------------------
/public/logos/cosmic.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
57 |
--------------------------------------------------------------------------------
/public/logos/deepin.svg:
--------------------------------------------------------------------------------
1 |
2 |
45 |
--------------------------------------------------------------------------------
/public/logos/gnome.svg:
--------------------------------------------------------------------------------
1 |
2 |
12 |
--------------------------------------------------------------------------------
/public/logos/hyprland.svg:
--------------------------------------------------------------------------------
1 |
4 |
--------------------------------------------------------------------------------
/public/logos/labwc.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
51 |
--------------------------------------------------------------------------------
/public/logos/louvre.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
27 |
--------------------------------------------------------------------------------
/public/logos/mir.svg:
--------------------------------------------------------------------------------
1 |
2 |
--------------------------------------------------------------------------------
/public/logos/sway.svg:
--------------------------------------------------------------------------------
1 |
2 |
4 |
34 |
--------------------------------------------------------------------------------
/public/logos/wayfire.svg:
--------------------------------------------------------------------------------
1 |
2 |
4 |
55 |
--------------------------------------------------------------------------------
/public/manifest.json:
--------------------------------------------------------------------------------
1 | {
2 | "short_name": "Wayland Explorer",
3 | "name": "Wayland Protocol Explorer",
4 | "icons": [
5 | {
6 | "src": "favicon.ico",
7 | "sizes": "64x64 32x32 24x24 16x16",
8 | "type": "image/x-icon"
9 | },
10 | {
11 | "src": "android-chrome-192x192.png",
12 | "type": "image/png",
13 | "sizes": "192x192"
14 | },
15 | {
16 | "src": "android-chrome-512x512.png",
17 | "type": "image/png",
18 | "sizes": "512x512"
19 | }
20 | ],
21 | "start_url": ".",
22 | "display": "standalone",
23 | "theme_color": "#000000",
24 | "background_color": "#ffffff"
25 | }
26 |
--------------------------------------------------------------------------------
/public/mstile-144x144.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vially/wayland-explorer/40253a7719f14f401329f526fbce8d46f55a482b/public/mstile-144x144.png
--------------------------------------------------------------------------------
/public/mstile-150x150.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vially/wayland-explorer/40253a7719f14f401329f526fbce8d46f55a482b/public/mstile-150x150.png
--------------------------------------------------------------------------------
/public/mstile-310x150.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vially/wayland-explorer/40253a7719f14f401329f526fbce8d46f55a482b/public/mstile-310x150.png
--------------------------------------------------------------------------------
/public/mstile-310x310.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vially/wayland-explorer/40253a7719f14f401329f526fbce8d46f55a482b/public/mstile-310x310.png
--------------------------------------------------------------------------------
/public/mstile-70x70.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vially/wayland-explorer/40253a7719f14f401329f526fbce8d46f55a482b/public/mstile-70x70.png
--------------------------------------------------------------------------------
/public/robots.txt:
--------------------------------------------------------------------------------
1 | # https://www.robotstxt.org/robotstxt.html
2 | User-agent: *
3 | Disallow:
4 |
--------------------------------------------------------------------------------
/public/safari-pinned-tab.svg:
--------------------------------------------------------------------------------
1 |
2 |
4 |
31 |
--------------------------------------------------------------------------------
/scripts/bin/print-protocol-registry-items.ts:
--------------------------------------------------------------------------------
1 | import path from 'path'
2 | import { findXMLFiles } from '../lib/utils'
3 |
4 | const relativeProtocolDirs = [
5 | path.join('protocols', 'wayland', 'stable'),
6 | path.join('protocols', 'wayland', 'unstable'),
7 | path.join('protocols', 'wlr', 'unstable'),
8 | ]
9 |
10 | const protocolItemFor =
11 | (source: string, stability: string) =>
12 | (protocolXmlFile: string): string => {
13 | const protocolId = path.basename(protocolXmlFile, '.xml')
14 | return `
15 | {
16 | id: '${protocolId}',
17 | name: '',
18 | source: WaylandProtocolSource.${source},
19 | stability: WaylandProtocolStability.${stability},
20 | protocol: require('./protocols/${protocolId}.json'),
21 | },`
22 | }
23 |
24 | async function main() {
25 | const protocolDirs = relativeProtocolDirs.map((waylandDir) =>
26 | path.resolve(__dirname, '../../', waylandDir)
27 | )
28 |
29 | const [waylandStableFiles, waylandUnstableFiles, wlrUnstableFiles] =
30 | await Promise.all(protocolDirs.map(findXMLFiles))
31 |
32 | const protocolItems = [
33 | protocolItemFor('WaylandCore', 'Stable')('wayland.xml'),
34 | ...waylandStableFiles.map(
35 | protocolItemFor('WaylandProtocols', 'Stable')
36 | ),
37 | ...waylandUnstableFiles.map(
38 | protocolItemFor('WaylandProtocols', 'Unstable')
39 | ),
40 | ...wlrUnstableFiles.map(protocolItemFor('WlrProtocols', 'Unstable')),
41 | ].join('')
42 |
43 | console.log(
44 | `const protocols: WaylandProtocolRegistryItem[] = [${protocolItems}\n]`
45 | )
46 | }
47 |
48 | main()
49 |
--------------------------------------------------------------------------------
/scripts/bin/render-static-html.tsx:
--------------------------------------------------------------------------------
1 | import * as fs from 'fs/promises'
2 | import { minify } from 'html-minifier'
3 | import * as path from 'path'
4 | import { renderToString } from 'react-dom/server'
5 | import { Router } from 'wouter'
6 | import staticLocationHook from 'wouter/static-location'
7 | import App from '../../src/App'
8 | import { waylandProtocolRegistry } from '../../src/data/protocol-registry'
9 |
10 | const buildDir = path.resolve(__dirname, '../../build/protocols')
11 |
12 | interface StaticPageDescriptor {
13 | routerPath: string
14 | fileName: string
15 | pageTitle: string
16 | }
17 |
18 | async function main() {
19 | const indexHTMLPlaceholder = await readIndexHTML()
20 |
21 | const renderPage = async (page: StaticPageDescriptor) => {
22 | await renderAndWriteHTML(indexHTMLPlaceholder, page)
23 | console.log(`✔ ${page.routerPath} rendered`)
24 | }
25 |
26 | await Promise.all(allPageDescriptors().map(renderPage))
27 | }
28 |
29 | function allPageDescriptors(): StaticPageDescriptor[] {
30 | const staticPages: StaticPageDescriptor[] = [
31 | {
32 | routerPath: '/',
33 | fileName: 'index.html',
34 | pageTitle: 'Wayland Protocol Documentation | Wayland Explorer',
35 | },
36 | {
37 | routerPath: '/404',
38 | fileName: '404.html',
39 | pageTitle: '404 - Page not found',
40 | },
41 | {
42 | routerPath: '/wayland-protocols/0',
43 | fileName: 'wayland-protocols-gitlab.html',
44 | pageTitle: 'Git',
45 | },
46 | ]
47 |
48 | const protocolPages: StaticPageDescriptor[] =
49 | waylandProtocolRegistry.protocols.map((protocol) => ({
50 | routerPath: `/${protocol.id}`,
51 | fileName: `${protocol.id}.html`,
52 | pageTitle: `${protocol.name} protocol | Wayland Explorer`,
53 | }))
54 |
55 | return [...staticPages, ...protocolPages]
56 | }
57 |
58 | async function renderAndWriteHTML(
59 | indexHTML: string,
60 | { routerPath, fileName, pageTitle }: StaticPageDescriptor
61 | ): Promise {
62 | const contentHTML = renderToString(
63 |
64 |
65 |
66 | )
67 |
68 | const html = injectContentIntoHTML(contentHTML, pageTitle, indexHTML)
69 | await fs.writeFile(path.join(buildDir, fileName), html)
70 | }
71 |
72 | async function readIndexHTML(): Promise {
73 | const htmlFilePath = path.join(buildDir, 'index.html')
74 | return fs.readFile(htmlFilePath, { encoding: 'utf-8' })
75 | }
76 |
77 | function injectContentIntoHTML(
78 | contentHTML: string,
79 | pageTitle: string,
80 | indexHTMLPlaceholder: string
81 | ): string {
82 | const minifiedContentHTML = minify(contentHTML, {
83 | collapseWhitespace: true,
84 | })
85 | const contentPlaceholder = ''
86 | const contentReplacement = `${minifiedContentHTML}
`
87 |
88 | const titlePlaceholder = 'Wayland Explorer'
89 | const titleReplacement = `${pageTitle}`
90 |
91 | return indexHTMLPlaceholder
92 | .replace(titlePlaceholder, titleReplacement)
93 | .replace(contentPlaceholder, contentReplacement)
94 | }
95 |
96 | main()
97 |
--------------------------------------------------------------------------------
/scripts/lib/utils.ts:
--------------------------------------------------------------------------------
1 | import { existsSync, promises as fs } from 'fs'
2 | import path from 'path'
3 |
4 | export function coerceArray(value: T | T[]): T[] {
5 | if (value === null || value === undefined) return []
6 |
7 | return Array.isArray(value) ? value : [value]
8 | }
9 |
10 | export async function findXMLFiles(rootDirectory: string): Promise {
11 | if (!existsSync(rootDirectory)) {
12 | return []
13 | }
14 |
15 | const files = await fs.readdir(rootDirectory)
16 |
17 | const xmlFiles = await Promise.all(
18 | files.map(async (baseName): Promise => {
19 | const fileName = path.join(rootDirectory, baseName)
20 | const stat = await fs.lstat(fileName)
21 | if (stat.isDirectory()) {
22 | return findXMLFiles(fileName)
23 | } else if (fileName.endsWith('.xml')) {
24 | return [fileName]
25 | }
26 | return []
27 | })
28 | )
29 |
30 | return xmlFiles.flat()
31 | }
32 |
33 | export function protocolIdFor(srcFileName: string): string {
34 | let baseName = path.basename(srcFileName, '.xml')
35 |
36 | // Strip `org-` prefix from some KDE protocol file names (e.g.:
37 | // `org-kde-plasma-virtual-desktop`)
38 | if (
39 | path.dirname(srcFileName).endsWith('/kde/src/protocols') &&
40 | baseName.startsWith('org-kde-')
41 | ) {
42 | baseName = baseName.substring('org-'.length)
43 | }
44 |
45 | // Add `kde-` prefix to KDE protocol file names to avoid potential future name clashes
46 | const prefix =
47 | path.dirname(srcFileName).endsWith('/kde/src/protocols') &&
48 | !baseName.startsWith('kde-')
49 | ? 'kde-'
50 | : ''
51 |
52 | return `${prefix}${baseName}`
53 | }
54 |
--------------------------------------------------------------------------------
/src/App.test.tsx:
--------------------------------------------------------------------------------
1 | import React from 'react'
2 | import { render, screen } from '@testing-library/react'
3 | import App from './App'
4 |
5 | test('renders learn react link', () => {
6 | render()
7 | const linkElement = screen.getByText(/learn react/i)
8 | expect(linkElement).toBeInTheDocument()
9 | })
10 |
--------------------------------------------------------------------------------
/src/App.tsx:
--------------------------------------------------------------------------------
1 | import { useRoute } from 'wouter'
2 | import { useAnalytics } from './analytics/plausible'
3 | import { MultiColumnLayout } from './components/layout/MultiColumnLayout'
4 | import { WaylandProtocolOutline } from './components/outline/WaylandProtocolOutline'
5 | import { WaylandProtocol } from './components/WaylandProtocol'
6 | import { waylandProtocolRegistry } from './data/protocol-registry'
7 | import { NotFound } from './pages/404'
8 | import { Homepage } from './pages/Homepage'
9 | import { GitLab, GitLabMrList } from './pages/GitLab'
10 |
11 | function App() {
12 | let contentView =
13 | let outlineView = null
14 |
15 | const [isGitlabMrList] = useRoute<{ iid: string }>('/wayland-protocols')
16 | const [isGitlab, gitlabParams] = useRoute<{ iid: string }>(
17 | '/wayland-protocols/:iid'
18 | )
19 |
20 | const [match, params] = useRoute<{ protocolId: string }>('/:protocolId')
21 | const isHomepage = !match && !isGitlab
22 |
23 | useAnalytics().trackPageview()
24 |
25 | if (isGitlabMrList) {
26 | return
27 | } else if (isGitlab && gitlabParams?.iid) {
28 | return
29 | } else if (match && params?.protocolId) {
30 | const protocolWithMetadata = match
31 | ? waylandProtocolRegistry.getProtocolWithMetadata(params.protocolId)
32 | : null
33 |
34 | contentView = protocolWithMetadata ? (
35 |
39 | ) : (
40 |
41 | )
42 |
43 | outlineView = protocolWithMetadata ? (
44 |
45 | ) : null
46 | }
47 |
48 | return (
49 |
50 | {contentView}
51 |
52 | )
53 | }
54 |
55 | export default App
56 |
--------------------------------------------------------------------------------
/src/analytics/plausible.ts:
--------------------------------------------------------------------------------
1 | import Plausible from 'plausible-tracker'
2 | import { appConfig } from '../config'
3 |
4 | export interface AnalyticsTracker {
5 | trackPageview: () => void
6 | }
7 |
8 | const noopTracker: AnalyticsTracker = { trackPageview: () => {} }
9 |
10 | let currentTracker: AnalyticsTracker = noopTracker
11 |
12 | export function setupAnalytics() {
13 | const enabled =
14 | process.env.NODE_ENV === 'production' &&
15 | !localStorage.getItem('plausible_ignore')
16 |
17 | currentTracker = enabled
18 | ? Plausible({ apiHost: appConfig.analyticsDomain })
19 | : noopTracker
20 | }
21 |
22 | export function useAnalytics(): AnalyticsTracker {
23 | return currentTracker
24 | }
25 |
--------------------------------------------------------------------------------
/src/components/WaylandArg.tsx:
--------------------------------------------------------------------------------
1 | import {
2 | WaylandArgModel,
3 | WaylandEnumModel,
4 | WaylandEventModel,
5 | WaylandRequestModel,
6 | } from './common'
7 | import { buildHashPathFor } from './common/utils'
8 | import { WaylandColorTheme as colors } from './common/wayland-protocol-icons'
9 |
10 | export const WaylandArg: React.FC<{
11 | element: WaylandArgModel
12 | interfaceName: string
13 | parentElement: WaylandRequestModel | WaylandEventModel | WaylandEnumModel
14 | }> = ({ element, interfaceName, parentElement }) => (
15 |
16 |
23 | {element.name}
24 |
25 | : {element.argType}
26 | {element.interface && (
27 |
28 | {'<'}
29 |
33 | {element.interface}
34 |
35 | {'>'}
36 |
37 | )}
38 | {element.enum && (
39 |
40 | {'<'}
41 |
46 | {'>'}
47 |
48 | )}
49 |
50 | )
51 |
52 | const ArgEnum: React.FC<{
53 | interfaceName: string
54 | argEnum: string
55 | protocol?: string
56 | }> = ({ argEnum, interfaceName, protocol }) => {
57 | let enumName = argEnum
58 | if (enumName.includes('.')) {
59 | ;[interfaceName, enumName] = enumName.split('.')
60 | }
61 |
62 | return (
63 |
64 | {interfaceName}.
65 | {enumName}
66 |
67 | )
68 | }
69 |
--------------------------------------------------------------------------------
/src/components/WaylandCopyright.tsx:
--------------------------------------------------------------------------------
1 | import { WaylandCopyrightModel, WaylandElementProps } from './common'
2 |
3 | export const WaylandCopyright: React.FC<
4 | WaylandElementProps
5 | > = ({ element }) => (
6 |
7 |
13 | {element.text?.split('\n\n').map((text, index) => (
14 |
15 | {text}
16 |
17 | ))}
18 |
19 | )
20 |
--------------------------------------------------------------------------------
/src/components/WaylandDescription.tsx:
--------------------------------------------------------------------------------
1 | import React from 'react'
2 | import { WaylandDescriptionModel, WaylandElementProps } from './common'
3 |
4 | export const WaylandDescription: React.FC<
5 | WaylandElementProps
6 | > = ({ element }) => (
7 |
8 | {element.summary && (
9 |
10 | {element.summary}
11 |
12 | )}
13 |
14 | {element.text && (
15 |
16 | {splitText(element.text)}
17 |
18 | )}
19 |
20 | )
21 |
22 | function splitText(description: string) {
23 | const out = []
24 | let listItems = null
25 | let matches = description.split(/((?:^|\n+)(?:[*-] )|\n\n)/);
26 | let paragraphGap = undefined
27 | let isListItem = false
28 | for (let i = 0; i < matches.length; i++) {
29 | let chunk = matches[i]
30 | if (i % 2) {
31 | paragraphGap = chunk.startsWith('\n\n') ? 'mt-3' : undefined
32 | isListItem = chunk.endsWith(' ')
33 | } else {
34 | if (isListItem) {
35 | listItems ??= []
36 | listItems.push({chunk})
37 | } else {
38 | if (listItems !== null) {
39 | out.push()
40 | listItems = null
41 | }
42 | out.push({chunk}
)
43 | }
44 | }
45 | }
46 | return out
47 | }
48 |
--------------------------------------------------------------------------------
/src/components/WaylandEntry.tsx:
--------------------------------------------------------------------------------
1 | import {
2 | WaylandElementProps,
3 | WaylandEntryModel,
4 | WaylandEnumModel,
5 | } from './common'
6 |
7 | export const WaylandEntry: React.FC<
8 | WaylandElementProps & {
9 | interfaceName: string
10 | enumElement: WaylandEnumModel
11 | }
12 | > = ({ element, enumElement, interfaceName }) => (
13 |
18 | {element.name}
19 |
20 | )
21 |
--------------------------------------------------------------------------------
/src/components/WaylandEnum.tsx:
--------------------------------------------------------------------------------
1 | import React from 'react'
2 | import { WaylandDataTable } from './WaylandDataTable'
3 | import { WaylandDescription } from './WaylandDescription'
4 | import { WaylandElementProps, WaylandEnumModel } from './common'
5 | import { WaylandColorTheme as colors } from './common/wayland-protocol-icons'
6 | import { Badge } from './content/Badge'
7 | import { WaylandElementSignature } from './content/WaylandElementSignature'
8 |
9 | export const WaylandEnum: React.FC<
10 | WaylandElementProps & { interfaceName: string }
11 | > = ({ element, interfaceName }) => (
12 |
13 |
42 |
43 |
47 |
48 | {!!element.entries?.length && (
49 |
54 | )}
55 |
56 | {element.description && (
57 |
58 | )}
59 |
60 | )
61 |
--------------------------------------------------------------------------------
/src/components/WaylandEvent.tsx:
--------------------------------------------------------------------------------
1 | import React from 'react'
2 | import { WaylandDataTable } from './WaylandDataTable'
3 | import { WaylandDescription } from './WaylandDescription'
4 | import { WaylandElementProps, WaylandEventModel } from './common'
5 | import { WaylandColorTheme as colors } from './common/wayland-protocol-icons'
6 | import { Badge } from './content/Badge'
7 | import { WaylandElementSignature } from './content/WaylandElementSignature'
8 |
9 | export const WaylandEvent: React.FC<
10 | WaylandElementProps & { interfaceName: string }
11 | > = ({ element, interfaceName }) => (
12 |
13 |
14 |
20 |
21 |
22 |
23 | {interfaceName}::
24 |
25 | {element.name}
26 |
27 |
28 | {(element.eventType || element.since) && (
29 |
30 | {element.deprecatedSince && (
31 |
36 | Deprecated since {element.deprecatedSince}
37 |
38 | )}
39 | {element.eventType && (
40 |
41 | Type: {element.eventType}
42 |
43 | )}
44 | {element.since && since {element.since}}
45 |
46 | )}
47 |
48 |
49 |
53 |
54 | {!!element.args?.length && (
55 |
60 | )}
61 |
62 | {element.description && (
63 |
64 | )}
65 |
66 | )
67 |
--------------------------------------------------------------------------------
/src/components/WaylandInterface.tsx:
--------------------------------------------------------------------------------
1 | import { WaylandDeprecationItem } from '../model/wayland-protocol-metadata'
2 | import { WaylandElementProps, WaylandInterfaceModel } from './common'
3 | import { WaylandColorTheme as colors } from './common/wayland-protocol-icons'
4 | import { Badge } from './content/Badge'
5 | import { WaylandDescription } from './WaylandDescription'
6 | import { WaylandEnum } from './WaylandEnum'
7 | import { WaylandEvent } from './WaylandEvent'
8 | import { WaylandRequest } from './WaylandRequest'
9 |
10 | export const WaylandInterface: React.FC<
11 | WaylandElementProps & {
12 | deprecated?: WaylandDeprecationItem
13 | }
14 | > = ({ element, deprecated }) => (
15 |
16 |
17 |
30 |
31 |
32 | {deprecated ? (
33 |
39 | Deprecated
40 |
41 | ) : (
42 | <>>
43 | )}
44 | version {element.version}
45 |
46 |
47 |
48 | {element.description ? (
49 |
50 |
51 |
52 | ) : (
53 |
54 | )}
55 |
56 |
57 | {element.requests?.map((request, index) => (
58 |
63 | ))}
64 | {element.events?.map((event, index) => (
65 |
70 | ))}
71 | {element.enums?.map((childElement, index) => (
72 |
77 | ))}
78 |
79 |
80 | )
81 |
--------------------------------------------------------------------------------
/src/components/WaylandProtocol.tsx:
--------------------------------------------------------------------------------
1 | import { WaylandProtocolMetadata } from '../model/wayland-protocol-metadata'
2 | import { WaylandBreadcrumbs } from './breadcrumbs/Breadcrumbs'
3 | import { WaylandProtocolModel } from './common'
4 | import { usePageTitle } from './common/hooks-utils'
5 | import { WaylandCopyright } from './WaylandCopyright'
6 | import { WaylandDescription } from './WaylandDescription'
7 | import { WaylandInterface } from './WaylandInterface'
8 | import { WaylandCompositors } from './WaylandCompositors'
9 |
10 | export const WaylandProtocol: React.FC<{
11 | element: WaylandProtocolModel
12 | metadata: WaylandProtocolMetadata
13 | }> = ({ element, metadata }) => {
14 | usePageTitle(`${metadata.name} protocol`)
15 |
16 | const get_deprecation = (name: string) => {
17 | const deprecated = metadata.deprecated ? metadata.deprecated : []
18 | return deprecated.find((item) => item.name === name)
19 | }
20 |
21 | return (
22 |
23 |
24 |
25 |
26 | {metadata.name}
27 |
28 |
29 |
30 |
31 |
32 | {element.description && (
33 |
34 |
35 |
36 | )}
37 |
38 | {element.interfaces.map((childElement, index) => (
39 |
40 |
44 |
45 |
46 | ))}
47 |
48 | {element.copyright && (
49 |
50 | )}
51 |
52 | )
53 | }
54 |
--------------------------------------------------------------------------------
/src/components/WaylandRequest.tsx:
--------------------------------------------------------------------------------
1 | import { WaylandElementProps, WaylandRequestModel } from './common'
2 | import { WaylandColorTheme as colors } from './common/wayland-protocol-icons'
3 | import { Badge } from './content/Badge'
4 | import { WaylandElementSignature } from './content/WaylandElementSignature'
5 | import { WaylandDataTable } from './WaylandDataTable'
6 | import { WaylandDescription } from './WaylandDescription'
7 |
8 | export const WaylandRequest: React.FC<
9 | WaylandElementProps & { interfaceName: string }
10 | > = ({ element, interfaceName }) => (
11 |
12 |
13 |
19 |
20 |
21 |
22 | {interfaceName}::
23 |
24 | {element.name}
25 |
26 |
27 | {(element.requestType || element.since) && (
28 |
29 | {element.deprecatedSince && (
30 |
35 | Deprecated since {element.deprecatedSince}
36 |
37 | )}
38 | {element.requestType && (
39 |
40 | Type: {element.requestType}
41 |
42 | )}
43 | {element.since && since {element.since}}
44 |
45 | )}
46 |
47 |
48 |
52 |
53 | {!!element.args?.length && (
54 |
59 | )}
60 |
61 | {element.description && (
62 |
63 | )}
64 |
65 | )
66 |
--------------------------------------------------------------------------------
/src/components/breadcrumbs/Breadcrumbs.tsx:
--------------------------------------------------------------------------------
1 | import React from 'react'
2 | import {
3 | kdeProtocolsWithHardcodedPrefix,
4 | urlForWaylandProtocol,
5 | urlForWaylandProtocolSource,
6 | urlForWaylandProtocolStability,
7 | } from '../../model/protocol-source-link-builder'
8 | import {
9 | WaylandProtocolMetadata,
10 | WaylandProtocolSource,
11 | } from '../../model/wayland-protocol-metadata'
12 |
13 | const SolidChevronRight: React.FC<{ className: string }> = ({ className }) => {
14 | // Heroicon name: solid/chevron-right
15 | return (
16 |
29 | )
30 | }
31 |
32 | export const BreadcrumbSection: React.FC<{
33 | children?: React.ReactNode
34 | href?: string
35 | }> = ({ children, href }) =>
36 | href ? (
37 |
43 | {children}
44 |
45 | ) : (
46 | {children}
47 | )
48 |
49 | export const WaylandBreadcrumbs: React.FC<{
50 | metadata: WaylandProtocolMetadata
51 | }> = ({ metadata }) => {
52 | const xmlFileBaseName =
53 | metadata.source === WaylandProtocolSource.KDEProtocols &&
54 | !kdeProtocolsWithHardcodedPrefix.includes(metadata.id)
55 | ? metadata.id.substring(4)
56 | : metadata.id
57 |
58 | const source =
59 | metadata.source === WaylandProtocolSource.External ? (
60 | external
61 | ) : (
62 |
65 | {metadata.source}
66 |
67 | )
68 |
69 | const stability = metadata.source !== WaylandProtocolSource.WaylandCore &&
70 | metadata.source !== WaylandProtocolSource.External && (
71 |
72 | {metadata.stability}
73 |
74 | )
75 |
76 | return (
77 |
78 | {source}
79 | {stability}
80 |
81 | {xmlFileBaseName}.xml
82 |
83 |
84 | )
85 | }
86 |
87 | export const Breadcrumbs: React.FC<{ children?: React.ReactNode }> = ({
88 | children,
89 | }) => {
90 | return (
91 |
109 | )
110 | }
111 |
--------------------------------------------------------------------------------
/src/components/common/hooks-utils.ts:
--------------------------------------------------------------------------------
1 | import { useEffect } from 'react'
2 |
3 | const addBodyClass = (className: string) =>
4 | document.body.classList.add(className)
5 |
6 | const removeBodyClass = (className: string) =>
7 | document.body.classList.remove(className)
8 |
9 | export function useBodyClass(className: string) {
10 | useEffect(() => {
11 | // Set up
12 | addBodyClass(className)
13 |
14 | // Clean up
15 | return () => removeBodyClass(className)
16 | }, [className])
17 | }
18 |
19 | export function usePageTitle(title: string) {
20 | useEffect(() => {
21 | document.title = `${title} | Wayland Explorer`
22 | }, [title])
23 | }
24 |
--------------------------------------------------------------------------------
/src/components/common/index.ts:
--------------------------------------------------------------------------------
1 | import {
2 | WaylandArg,
3 | WaylandCopyright,
4 | WaylandDescription,
5 | WaylandElement,
6 | WaylandEntry,
7 | WaylandEnum,
8 | WaylandEvent,
9 | WaylandInterface,
10 | WaylandProtocol,
11 | WaylandRequest,
12 | } from '../../model/wayland'
13 |
14 | export interface WaylandElementProps {
15 | element: T
16 | }
17 |
18 | // Aliases to avoid collisions with the component names
19 | export type WaylandProtocolModel = WaylandProtocol
20 | export type WaylandCopyrightModel = WaylandCopyright
21 | export type WaylandDescriptionModel = WaylandDescription
22 | export type WaylandInterfaceModel = WaylandInterface
23 | export type WaylandRequestModel = WaylandRequest
24 | export type WaylandEventModel = WaylandEvent
25 | export type WaylandEnumModel = WaylandEnum
26 | export type WaylandEntryModel = WaylandEntry
27 | export type WaylandArgModel = WaylandArg
28 |
--------------------------------------------------------------------------------
/src/components/common/utils.ts:
--------------------------------------------------------------------------------
1 | import {
2 | WaylandArg,
3 | WaylandEntry,
4 | WaylandEnum,
5 | WaylandEvent,
6 | WaylandRequest,
7 | } from '../../model/wayland'
8 |
9 | export function buildHashPathFor(
10 | interfaceName: string,
11 | parentElement: WaylandEvent | WaylandRequest | WaylandEnum,
12 | arg: WaylandArg | WaylandEntry,
13 | options?: { includeHashSymbol: boolean }
14 | ): string {
15 | return `${options?.includeHashSymbol ? '#' : ''}${interfaceName}:${
16 | parentElement.type
17 | }:${parentElement.name}:${arg.type}:${arg.name}`
18 | }
19 |
--------------------------------------------------------------------------------
/src/components/common/wayland-protocol-icons.ts:
--------------------------------------------------------------------------------
1 | import { WaylandElementType } from '../../model/wayland'
2 |
3 | export interface WaylandElementUIConfig {
4 | icon: string
5 | color: string
6 | }
7 |
8 | export enum WaylandColorTheme {
9 | Interface = 'text-blue-500',
10 | Request = 'text-pink-500',
11 | Event = 'text-emerald-500',
12 | Enum = 'text-orange-500',
13 | Entry = 'text-orange-50',
14 | }
15 |
16 | const waylandIcons: Record = {
17 | [WaylandElementType.Protocol]: { icon: '', color: '' },
18 | [WaylandElementType.Interface]: {
19 | icon: 'interface',
20 | color: WaylandColorTheme.Interface,
21 | },
22 | [WaylandElementType.Request]: {
23 | icon: 'method',
24 | color: WaylandColorTheme.Request,
25 | },
26 | [WaylandElementType.Event]: {
27 | icon: 'event',
28 | color: WaylandColorTheme.Event,
29 | },
30 | [WaylandElementType.Enum]: { icon: 'enum', color: WaylandColorTheme.Enum },
31 | [WaylandElementType.Entry]: { icon: '', color: WaylandColorTheme.Entry },
32 | [WaylandElementType.Arg]: { icon: '', color: '' },
33 | [WaylandElementType.Copyright]: { icon: '', color: '' },
34 | [WaylandElementType.Description]: { icon: '', color: '' },
35 | }
36 |
37 | export const waylandElementConfigFor = (
38 | elementType: WaylandElementType
39 | ): WaylandElementUIConfig => waylandIcons[elementType]
40 |
--------------------------------------------------------------------------------
/src/components/content/Badge.tsx:
--------------------------------------------------------------------------------
1 | export const Badge: React.FC<{
2 | bgColor?: string
3 | textColor?: string
4 | fontWeigth?: string
5 | title?: string
6 | children?: React.ReactNode
7 | }> = ({ children, bgColor, textColor, fontWeigth, title }) => (
8 |
14 | {children}
15 |
16 | )
17 |
--------------------------------------------------------------------------------
/src/components/content/ProtocolBadge.tsx:
--------------------------------------------------------------------------------
1 | import React from 'react'
2 | import {
3 | WaylandProtocolMetadata,
4 | WaylandProtocolSource,
5 | WaylandProtocolStability,
6 | } from '../../model/wayland-protocol-metadata'
7 | import { Badge } from './Badge'
8 |
9 | interface BadgeTheme {
10 | textColor: string
11 | backgroundColor: string
12 | }
13 |
14 | const coreBadgeTheme: BadgeTheme = {
15 | textColor: 'text-green-800',
16 | backgroundColor: 'bg-green-100',
17 | }
18 |
19 | const waylandProtocolsStableBadgeTheme: BadgeTheme = {
20 | textColor: 'text-blue-800',
21 | backgroundColor: 'bg-blue-100',
22 | }
23 |
24 | const waylandProtocolsUnstableBadgeTheme: BadgeTheme = {
25 | textColor: 'text-pink-800',
26 | backgroundColor: 'bg-pink-100',
27 | }
28 |
29 | const wlrProtocolsUnstableBadgeTheme: BadgeTheme = {
30 | textColor: 'text-red-800',
31 | backgroundColor: 'bg-red-100',
32 | }
33 |
34 | const kdeProtocolsUnstableBadgeTheme: BadgeTheme = {
35 | textColor: 'text-purple-800',
36 | backgroundColor: 'bg-purple-100',
37 | }
38 |
39 | const hyprlandProtocolsUnstableBadgeTheme: BadgeTheme = {
40 | textColor: 'text-sky-800',
41 | backgroundColor: 'bg-sky-100',
42 | }
43 |
44 | const cosmicProtocolsUnstableBadgeTheme: BadgeTheme = {
45 | textColor: 'text-amber-800',
46 | backgroundColor: 'bg-red-100',
47 | }
48 |
49 | const westonProtocolsUnstableBadgeTheme: BadgeTheme = {
50 | textColor: 'text-yellow-800',
51 | backgroundColor: 'bg-yellow-100',
52 | }
53 |
54 | const treelandProtocolsUnstableBadgeTheme: BadgeTheme = {
55 | textColor: 'text-cyan-800',
56 | backgroundColor: 'bg-cyan-100',
57 | }
58 |
59 | const externalProtocolsBadgeTheme: BadgeTheme = {
60 | textColor: 'text-gray-800',
61 | backgroundColor: 'bg-gray-100',
62 | }
63 |
64 | function badgeThemeFor(
65 | source: WaylandProtocolSource,
66 | stability: WaylandProtocolStability
67 | ): BadgeTheme {
68 | if (source === WaylandProtocolSource.WaylandCore) {
69 | return coreBadgeTheme
70 | } else if (source === WaylandProtocolSource.WaylandProtocols) {
71 | return stability === WaylandProtocolStability.Stable
72 | ? waylandProtocolsStableBadgeTheme
73 | : waylandProtocolsUnstableBadgeTheme
74 | } else if (source === WaylandProtocolSource.WlrProtocols) {
75 | return wlrProtocolsUnstableBadgeTheme
76 | } else if (source === WaylandProtocolSource.KDEProtocols) {
77 | return kdeProtocolsUnstableBadgeTheme
78 | } else if (source === WaylandProtocolSource.HyprlandProtocols) {
79 | return hyprlandProtocolsUnstableBadgeTheme
80 | } else if (source === WaylandProtocolSource.CosmicProtocols) {
81 | return cosmicProtocolsUnstableBadgeTheme
82 | } else if (source === WaylandProtocolSource.WestonProtocols) {
83 | return westonProtocolsUnstableBadgeTheme
84 | } else if (source === WaylandProtocolSource.TreelandProtocols) {
85 | return treelandProtocolsUnstableBadgeTheme
86 | } else {
87 | return externalProtocolsBadgeTheme
88 | }
89 | }
90 |
91 | export const ProtocolBadge: React.FC<{ protocol: WaylandProtocolMetadata }> = ({
92 | protocol,
93 | }) => {
94 | const theme = badgeThemeFor(protocol.source, protocol.stability)
95 | return (
96 |
97 | {protocol.source === WaylandProtocolSource.WaylandCore
98 | ? 'core'
99 | : protocol.source === WaylandProtocolSource.WlrProtocols
100 | ? 'wlr'
101 | : protocol.source === WaylandProtocolSource.KDEProtocols
102 | ? 'kde'
103 | : protocol.source === WaylandProtocolSource.HyprlandProtocols
104 | ? 'hyprland'
105 | : protocol.source === WaylandProtocolSource.CosmicProtocols
106 | ? 'cosmic'
107 | : protocol.source === WaylandProtocolSource.WestonProtocols
108 | ? 'weston'
109 | : protocol.source === WaylandProtocolSource.TreelandProtocols
110 | ? 'treeland'
111 | : protocol.source === WaylandProtocolSource.External
112 | ? 'external'
113 | : protocol.stability}
114 |
115 | )
116 | }
117 |
--------------------------------------------------------------------------------
/src/components/content/WaylandElementSignature.tsx:
--------------------------------------------------------------------------------
1 | import React from 'react'
2 | import { isWaylandEnumElement, WaylandElementType } from '../../model/wayland'
3 | import {
4 | WaylandEnumModel,
5 | WaylandEventModel,
6 | WaylandRequestModel,
7 | } from '../common'
8 | import { waylandElementConfigFor } from '../common/wayland-protocol-icons'
9 | import { WaylandArg } from '../WaylandArg'
10 | import { WaylandEntry } from '../WaylandEntry'
11 |
12 | export const WaylandElementSignature: React.FC<{
13 | element: WaylandRequestModel | WaylandEventModel | WaylandEnumModel
14 | interfaceName: string
15 | }> = ({ element, interfaceName }) => (
16 |
17 |
18 | {element.name}
19 | {isWaylandEnumElement(element) ? (
20 |
21 | {' { '}
22 | {element.entries?.map((entry, index) => (
23 |
24 |
29 | {index !== element.entries!.length - 1 && ', '}
30 |
31 | ))}
32 | {' } '}
33 |
34 | ) : (
35 |
36 | (
37 | {element.args.map((childElement, index) => (
38 |
39 |
44 | {index !== element.args!.length - 1 && ', '}
45 |
46 | ))}
47 | )
48 |
49 | )}
50 |
51 |
52 | )
53 |
54 | const colorFor = (elementType: WaylandElementType): string =>
55 | elementType === WaylandElementType.Event
56 | ? 'text-emerald-300'
57 | : waylandElementConfigFor(elementType).color
58 |
--------------------------------------------------------------------------------
/src/components/layout/Footer.tsx:
--------------------------------------------------------------------------------
1 | import React from 'react'
2 | import { Link } from 'wouter'
3 |
4 | export const Footer: React.FC = () => (
5 |
66 | )
67 |
--------------------------------------------------------------------------------
/src/components/layout/Header.tsx:
--------------------------------------------------------------------------------
1 | import React from 'react'
2 | import { Logo } from './Logo'
3 |
4 | export const Header: React.FC<{
5 | showOutlineButton: boolean
6 | setIsSidebarOpen: (open: boolean) => void
7 | setIsOutlineOpen: (open: boolean) => void
8 | }> = ({ setIsSidebarOpen, setIsOutlineOpen, showOutlineButton }) => (
9 |
65 | )
66 |
--------------------------------------------------------------------------------
/src/components/layout/Logo.tsx:
--------------------------------------------------------------------------------
1 | import { Link } from 'wouter'
2 |
3 | export const Logo: React.FC = () => (
4 |
5 |
6 |
7 |
11 | Wayland Explorer
12 |
13 |
14 |
15 | )
16 |
--------------------------------------------------------------------------------
/src/components/layout/MultiColumnLayout.tsx:
--------------------------------------------------------------------------------
1 | import React, { useState } from 'react'
2 | import { WaylandProtocolLinks } from '../sidebar-navigation/WaylandProtocolLinks'
3 | import { Footer } from './Footer'
4 | import { Header } from './Header'
5 | import { Logo } from './Logo'
6 | import { OutlineOverlay } from './overlays/OutlineOverlay'
7 | import { SidebarOverlay } from './overlays/SidebarOverlay'
8 | import { ScrollToTop } from './ScrollToTop'
9 |
10 | export const MultiColumnLayout: React.FC<{
11 | hideSidebar?: boolean
12 | outlineView?: React.ReactNode
13 | children?: React.ReactNode
14 | }> = ({ outlineView, hideSidebar, children }) => {
15 | const [isSidebarOpen, setIsSidebarOpen] = useState(false)
16 | const [isOutlineOpen, setIsOutlineOpen] = useState(false)
17 |
18 | return (
19 |
20 |
21 |
22 |
23 |
24 | {outlineView}
25 |
26 |
27 |
32 |
33 |
38 |
43 |
54 |
55 |
64 | {children}
65 |
66 |
67 | {outlineView && (
68 |
76 | )}
77 |
78 |
79 |
80 |
81 | )
82 | }
83 |
--------------------------------------------------------------------------------
/src/components/layout/ScrollToTop.tsx:
--------------------------------------------------------------------------------
1 | import { useEffect } from 'react'
2 | import { useLocation } from 'wouter'
3 |
4 | export const ScrollToTop = () => {
5 | const [pathname] = useLocation()
6 |
7 | useEffect(() => {
8 | if (window.location.hash === '') {
9 | window.scrollTo(0, 0)
10 | }
11 | }, [pathname])
12 |
13 | return null
14 | }
15 |
--------------------------------------------------------------------------------
/src/components/layout/overlays/OutlineOverlay.tsx:
--------------------------------------------------------------------------------
1 | import { Transition } from '@headlessui/react'
2 | import React from 'react'
3 | import { OverlayBackground } from './OverlayBackground'
4 |
5 | export const OutlineOverlay: React.FC<{
6 | open: boolean
7 | setIsOpen: (open: boolean) => void
8 | children?: React.ReactNode
9 | }> = ({ open, setIsOpen, children }) => (
10 |
11 |
17 |
18 |
19 |
20 |
21 |
30 |
39 |
61 |
62 |
63 |
64 |
68 | Outline
69 |
70 |
71 |
setIsOpen(false)}
74 | >
75 | {children}
76 |
77 |
78 |
79 |
80 |
81 |
82 |
83 | )
84 |
--------------------------------------------------------------------------------
/src/components/layout/overlays/OverlayBackground.tsx:
--------------------------------------------------------------------------------
1 | import { Transition } from '@headlessui/react'
2 | import { useBodyClass } from '../../common/hooks-utils'
3 |
4 | export function OverlayBackground() {
5 | useBodyClass('overflow-hidden')
6 |
7 | return (
8 |
18 | )
19 | }
20 |
--------------------------------------------------------------------------------
/src/components/layout/overlays/SidebarOverlay.tsx:
--------------------------------------------------------------------------------
1 | import { Transition } from '@headlessui/react'
2 | import React from 'react'
3 | import { Logo } from '../Logo'
4 | import { OverlayBackground } from './OverlayBackground'
5 |
6 | export const SidebarOverlay: React.FC<{
7 | open: boolean
8 | setIsOpen: (open: boolean) => void
9 | children?: React.ReactNode
10 | }> = ({ open, setIsOpen, children }) => (
11 |
12 | {/* Off-canvas menu for mobile, show/hide based on off-canvas menu state. */}
13 |
18 |
19 |
20 | {/* Off-canvas menu, show/hide based on off-canvas menu state. */}
21 |
30 | {/* Close button, show/hide based on off-canvas menu state. */}
31 |
40 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
78 |
79 |
80 |
81 |
82 | {/* Dummy element to force sidebar to shrink to fit close icon */}
83 |
84 |
85 |
86 | )
87 |
--------------------------------------------------------------------------------
/src/components/outline/WaylandInterfaceOutline.tsx:
--------------------------------------------------------------------------------
1 | import {
2 | WaylandElementProps,
3 | WaylandEnumModel,
4 | WaylandEventModel,
5 | WaylandInterfaceModel,
6 | WaylandRequestModel,
7 | } from '../common'
8 | import { waylandElementConfigFor } from '../common/wayland-protocol-icons'
9 |
10 | export const WaylandInterfaceOutline: React.FC<
11 | WaylandElementProps
12 | > = ({ element }) => {
13 | const { requests = [], events = [], enums = [] } = element
14 | const children = [...requests, ...events, ...enums]
15 | const { icon, color } = waylandElementConfigFor(element.type)
16 |
17 | return (
18 |
35 | )
36 | }
37 |
38 | const WaylandInterfaceChildOutline: React.FC<
39 | WaylandElementProps<
40 | WaylandRequestModel | WaylandEventModel | WaylandEnumModel
41 | > & {
42 | interfaceElement: WaylandInterfaceModel
43 | }
44 | > = ({ element, interfaceElement }) => {
45 | const { color, icon } = waylandElementConfigFor(element.type)
46 | return (
47 |
57 | )
58 | }
59 |
--------------------------------------------------------------------------------
/src/components/outline/WaylandProtocolOutline.tsx:
--------------------------------------------------------------------------------
1 | import { WaylandElementProps, WaylandProtocolModel } from '../common'
2 | import { WaylandInterfaceOutline } from './WaylandInterfaceOutline'
3 |
4 | export const WaylandProtocolOutline: React.FC<
5 | WaylandElementProps
6 | > = ({ element }) => (
7 |
8 | {element.interfaces.map((childElement, index) => (
9 |
10 | ))}
11 |
21 | {element.copyright && (
22 |
32 | )}
33 |
34 | )
35 |
--------------------------------------------------------------------------------
/src/components/sidebar-navigation/SidebarNavLink.tsx:
--------------------------------------------------------------------------------
1 | import React from 'react'
2 | import { Link, useRoute } from 'wouter'
3 |
4 | export const SidebarNavLink: React.FC<{
5 | href: string
6 | title?: string
7 | children?: React.ReactNode
8 | }> = (props) => {
9 | const [isActive] = useRoute(props.href)
10 |
11 | return (
12 |
13 |
22 | {props.children}
23 |
24 |
25 | )
26 | }
27 |
--------------------------------------------------------------------------------
/src/config/index.ts:
--------------------------------------------------------------------------------
1 | export const appConfig = {
2 | domain: 'wayland.app',
3 | analyticsDomain: 'https://wayland.app',
4 | }
5 |
--------------------------------------------------------------------------------
/src/data/compositor-registry.ts:
--------------------------------------------------------------------------------
1 | export interface CompositorGlobalInfo {
2 | interface: string
3 | version: number
4 | }
5 |
6 | export interface CompositorInfo {
7 | generationTimestamp: number
8 | version: string | null
9 | globals: CompositorGlobalInfo[]
10 | }
11 |
12 | export interface CompositorRegistryItem {
13 | id: string
14 | name: string
15 | icon?: string
16 | info: CompositorInfo
17 | }
18 |
19 | export const compositorRegistry: CompositorRegistryItem[] = [
20 | {
21 | id: 'mutter',
22 | name: 'Mutter',
23 | icon: 'gnome',
24 | info: require('./compositors/mutter.json'),
25 | },
26 | {
27 | id: 'kwin',
28 | name: 'KWin',
29 | icon: 'kde',
30 | info: require('./compositors/kwin.json'),
31 | },
32 | {
33 | id: 'sway',
34 | name: 'Sway',
35 | icon: 'sway',
36 | info: require('./compositors/sway.json'),
37 | },
38 | {
39 | id: 'cosmic',
40 | name: 'COSMIC',
41 | icon: 'cosmic',
42 | info: require('./compositors/cosmic.json'),
43 | },
44 | {
45 | id: 'hyprland',
46 | name: 'Hyprland',
47 | icon: 'hyprland',
48 | info: require('./compositors/hyprland.json'),
49 | },
50 | {
51 | id: 'niri',
52 | name: 'niri',
53 | info: require('./compositors/niri.json'),
54 | },
55 | {
56 | id: 'weston',
57 | name: 'Weston',
58 | icon: 'weston',
59 | info: require('./compositors/weston.json'),
60 | },
61 | {
62 | id: 'labwc',
63 | name: 'Labwc',
64 | icon: 'labwc',
65 | info: require('./compositors/labwc.json'),
66 | },
67 | {
68 | id: 'cage',
69 | name: 'Cage',
70 | info: require('./compositors/cage.json'),
71 | },
72 | {
73 | id: 'wayfire',
74 | name: 'Wayfire',
75 | icon: 'wayfire',
76 | info: require('./compositors/wayfire.json'),
77 | },
78 | {
79 | id: 'gamescope',
80 | name: 'GameScope',
81 | icon: 'Steam_Deck',
82 | info: require('./compositors/gamescope.json'),
83 | },
84 | {
85 | id: 'jay',
86 | name: 'Jay',
87 | info: require('./compositors/jay.json'),
88 | },
89 | {
90 | id: 'mir',
91 | name: 'Mir',
92 | icon: 'mir',
93 | info: require('./compositors/mir.json'),
94 | },
95 | {
96 | id: 'treeland',
97 | name: 'Treeland',
98 | icon: 'deepin',
99 | info: require('./compositors/treeland.json'),
100 | },
101 | {
102 | id: 'louvre',
103 | name: 'Louvre',
104 | icon: 'louvre',
105 | info: require('./compositors/louvre.json'),
106 | },
107 | ]
108 |
--------------------------------------------------------------------------------
/src/data/compositors/README.md:
--------------------------------------------------------------------------------
1 | # Regenerating or adding new files
2 |
3 | These files are generated via [`wlprobe`](https://github.com/PolyMeilex/wlprobe), a tool similar to `wayland-info` but [with JSON support](https://gitlab.freedesktop.org/wayland/wayland-utils/-/issues/2). Refer to its README for usage instructions.
4 |
--------------------------------------------------------------------------------
/src/data/compositors/cage.json:
--------------------------------------------------------------------------------
1 | {
2 | "generationTimestamp": 1743265802644,
3 | "version": "0.2.0",
4 | "globals": [
5 | {
6 | "interface": "ext_idle_notifier_v1",
7 | "version": 1
8 | },
9 | {
10 | "interface": "org_kde_kwin_server_decoration_manager",
11 | "version": 1
12 | },
13 | {
14 | "interface": "wl_compositor",
15 | "version": 6
16 | },
17 | {
18 | "interface": "wl_data_device_manager",
19 | "version": 3
20 | },
21 | {
22 | "interface": "wl_output",
23 | "version": 4
24 | },
25 | {
26 | "interface": "wl_seat",
27 | "version": 9
28 | },
29 | {
30 | "interface": "wl_shm",
31 | "version": 2
32 | },
33 | {
34 | "interface": "wl_subcompositor",
35 | "version": 1
36 | },
37 | {
38 | "interface": "wp_presentation",
39 | "version": 1
40 | },
41 | {
42 | "interface": "wp_single_pixel_buffer_manager_v1",
43 | "version": 1
44 | },
45 | {
46 | "interface": "wp_viewporter",
47 | "version": 1
48 | },
49 | {
50 | "interface": "xdg_wm_base",
51 | "version": 4
52 | },
53 | {
54 | "interface": "xwayland_shell_v1",
55 | "version": 1
56 | },
57 | {
58 | "interface": "zwlr_export_dmabuf_manager_v1",
59 | "version": 1
60 | },
61 | {
62 | "interface": "zwlr_gamma_control_manager_v1",
63 | "version": 1
64 | },
65 | {
66 | "interface": "zwlr_output_manager_v1",
67 | "version": 4
68 | },
69 | {
70 | "interface": "zwlr_screencopy_manager_v1",
71 | "version": 3
72 | },
73 | {
74 | "interface": "zwlr_virtual_pointer_manager_v1",
75 | "version": 2
76 | },
77 | {
78 | "interface": "zwp_idle_inhibit_manager_v1",
79 | "version": 1
80 | },
81 | {
82 | "interface": "zwp_linux_dmabuf_v1",
83 | "version": 4
84 | },
85 | {
86 | "interface": "zwp_primary_selection_device_manager_v1",
87 | "version": 1
88 | },
89 | {
90 | "interface": "zwp_relative_pointer_manager_v1",
91 | "version": 1
92 | },
93 | {
94 | "interface": "zwp_virtual_keyboard_manager_v1",
95 | "version": 1
96 | },
97 | {
98 | "interface": "zxdg_decoration_manager_v1",
99 | "version": 1
100 | },
101 | {
102 | "interface": "zxdg_output_manager_v1",
103 | "version": 3
104 | }
105 | ]
106 | }
107 |
--------------------------------------------------------------------------------
/src/data/compositors/gamescope.json:
--------------------------------------------------------------------------------
1 | {
2 | "generationTimestamp": 1730471003624,
3 | "version": "3.15.14",
4 | "globals": [
5 | {
6 | "interface": "gamescope_control",
7 | "version": 3
8 | },
9 | {
10 | "interface": "gamescope_input_method_manager",
11 | "version": 3
12 | },
13 | {
14 | "interface": "gamescope_pipewire",
15 | "version": 1
16 | },
17 | {
18 | "interface": "gamescope_private",
19 | "version": 1
20 | },
21 | {
22 | "interface": "gamescope_reshade",
23 | "version": 1
24 | },
25 | {
26 | "interface": "gamescope_swapchain_factory_v2",
27 | "version": 1
28 | },
29 | {
30 | "interface": "gamescope_xwayland",
31 | "version": 1
32 | },
33 | {
34 | "interface": "wl_compositor",
35 | "version": 5
36 | },
37 | {
38 | "interface": "wl_drm",
39 | "version": 2
40 | },
41 | {
42 | "interface": "wl_output",
43 | "version": 4
44 | },
45 | {
46 | "interface": "wl_seat",
47 | "version": 9
48 | },
49 | {
50 | "interface": "wl_shm",
51 | "version": 2
52 | },
53 | {
54 | "interface": "wp_linux_drm_syncobj_manager_v1",
55 | "version": 1
56 | },
57 | {
58 | "interface": "wp_presentation",
59 | "version": 1
60 | },
61 | {
62 | "interface": "xdg_wm_base",
63 | "version": 3
64 | },
65 | {
66 | "interface": "zwlr_layer_shell_v1",
67 | "version": 4
68 | },
69 | {
70 | "interface": "zwp_linux_dmabuf_v1",
71 | "version": 4
72 | },
73 | {
74 | "interface": "zwp_pointer_constraints_v1",
75 | "version": 1
76 | },
77 | {
78 | "interface": "zwp_relative_pointer_manager_v1",
79 | "version": 1
80 | }
81 | ]
82 | }
83 |
--------------------------------------------------------------------------------
/src/data/compositors/louvre.json:
--------------------------------------------------------------------------------
1 | {
2 | "generationTimestamp": 1738178000142,
3 | "version": "2.14.1",
4 | "globals": [
5 | {
6 | "interface": "ext_foreign_toplevel_image_capture_source_manager_v1",
7 | "version": 1
8 | },
9 | {
10 | "interface": "ext_foreign_toplevel_list_v1",
11 | "version": 1
12 | },
13 | {
14 | "interface": "ext_idle_notifier_v1",
15 | "version": 1
16 | },
17 | {
18 | "interface": "ext_output_image_capture_source_manager_v1",
19 | "version": 1
20 | },
21 | {
22 | "interface": "ext_session_lock_manager_v1",
23 | "version": 1
24 | },
25 | {
26 | "interface": "wl_compositor",
27 | "version": 6
28 | },
29 | {
30 | "interface": "wl_data_device_manager",
31 | "version": 3
32 | },
33 | {
34 | "interface": "wl_drm",
35 | "version": 2
36 | },
37 | {
38 | "interface": "wp_drm_lease_device_v1",
39 | "version": 1
40 | },
41 | {
42 | "interface": "wl_eglstream_display",
43 | "version": 1
44 | },
45 | {
46 | "interface": "wl_output",
47 | "version": 4
48 | },
49 | {
50 | "interface": "wl_seat",
51 | "version": 9
52 | },
53 | {
54 | "interface": "wl_shm",
55 | "version": 2
56 | },
57 | {
58 | "interface": "wl_subcompositor",
59 | "version": 1
60 | },
61 | {
62 | "interface": "wp_content_type_manager_v1",
63 | "version": 1
64 | },
65 | {
66 | "interface": "wp_fractional_scale_manager_v1",
67 | "version": 1
68 | },
69 | {
70 | "interface": "wp_presentation",
71 | "version": 1
72 | },
73 | {
74 | "interface": "wp_single_pixel_buffer_manager_v1",
75 | "version": 1
76 | },
77 | {
78 | "interface": "wp_tearing_control_manager_v1",
79 | "version": 1
80 | },
81 | {
82 | "interface": "wp_viewporter",
83 | "version": 1
84 | },
85 | {
86 | "interface": "xdg_activation_v1",
87 | "version": 1
88 | },
89 | {
90 | "interface": "xdg_wm_base",
91 | "version": 6
92 | },
93 | {
94 | "interface": "zwlr_foreign_toplevel_manager_v1",
95 | "version": 3
96 | },
97 | {
98 | "interface": "zwlr_gamma_control_manager_v1",
99 | "version": 1
100 | },
101 | {
102 | "interface": "zwlr_layer_shell_v1",
103 | "version": 5
104 | },
105 | {
106 | "interface": "zwp_linux_dmabuf_v1",
107 | "version": 5
108 | },
109 | {
110 | "interface": "zwlr_output_manager_v1",
111 | "version": 4
112 | },
113 | {
114 | "interface": "zwlr_screencopy_manager_v1",
115 | "version": 3
116 | },
117 | {
118 | "interface": "zwp_idle_inhibit_manager_v1",
119 | "version": 1
120 | },
121 | {
122 | "interface": "zwp_pointer_constraints_v1",
123 | "version": 1
124 | },
125 | {
126 | "interface": "zwp_pointer_gestures_v1",
127 | "version": 3
128 | },
129 | {
130 | "interface": "zwp_relative_pointer_manager_v1",
131 | "version": 1
132 | },
133 | {
134 | "interface": "zxdg_decoration_manager_v1",
135 | "version": 1
136 | },
137 | {
138 | "interface": "zxdg_output_manager_v1",
139 | "version": 3
140 | }
141 | ]
142 | }
143 |
--------------------------------------------------------------------------------
/src/data/compositors/mir.json:
--------------------------------------------------------------------------------
1 | {
2 | "generationTimestamp": 1733165065880,
3 | "version": "2.19",
4 | "globals": [
5 | {
6 | "interface": "ext_session_lock_manager_v1",
7 | "version": 1
8 | },
9 | {
10 | "interface": "mir_shell_v1",
11 | "version": 1
12 | },
13 | {
14 | "interface": "wl_compositor",
15 | "version": 4
16 | },
17 | {
18 | "interface": "wl_data_device_manager",
19 | "version": 3
20 | },
21 | {
22 | "interface": "wl_drm",
23 | "version": 2
24 | },
25 | {
26 | "interface": "wl_output",
27 | "version": 4
28 | },
29 | {
30 | "interface": "wl_seat",
31 | "version": 8
32 | },
33 | {
34 | "interface": "wl_shell",
35 | "version": 1
36 | },
37 | {
38 | "interface": "wl_shm",
39 | "version": 1
40 | },
41 | {
42 | "interface": "wl_subcompositor",
43 | "version": 1
44 | },
45 | {
46 | "interface": "wp_fractional_scale_manager_v1",
47 | "version": 1
48 | },
49 | {
50 | "interface": "wp_viewporter",
51 | "version": 1
52 | },
53 | {
54 | "interface": "xdg_activation_v1",
55 | "version": 1
56 | },
57 | {
58 | "interface": "xdg_wm_base",
59 | "version": 5
60 | },
61 | {
62 | "interface": "zwlr_foreign_toplevel_manager_v1",
63 | "version": 2
64 | },
65 | {
66 | "interface": "zwlr_layer_shell_v1",
67 | "version": 4
68 | },
69 | {
70 | "interface": "zwlr_screencopy_manager_v1",
71 | "version": 3
72 | },
73 | {
74 | "interface": "zwlr_virtual_pointer_manager_v1",
75 | "version": 2
76 | },
77 | {
78 | "interface": "zwp_idle_inhibit_manager_v1",
79 | "version": 1
80 | },
81 | {
82 | "interface": "zwp_input_method_manager_v2",
83 | "version": 1
84 | },
85 | {
86 | "interface": "zwp_input_method_v1",
87 | "version": 1
88 | },
89 | {
90 | "interface": "zwp_input_panel_v1",
91 | "version": 1
92 | },
93 | {
94 | "interface": "zwp_linux_dmabuf_v1",
95 | "version": 3
96 | },
97 | {
98 | "interface": "zwp_pointer_constraints_v1",
99 | "version": 1
100 | },
101 | {
102 | "interface": "zwp_primary_selection_device_manager_v1",
103 | "version": 1
104 | },
105 | {
106 | "interface": "zwp_relative_pointer_manager_v1",
107 | "version": 1
108 | },
109 | {
110 | "interface": "zwp_text_input_manager_v1",
111 | "version": 1
112 | },
113 | {
114 | "interface": "zwp_text_input_manager_v2",
115 | "version": 1
116 | },
117 | {
118 | "interface": "zwp_text_input_manager_v3",
119 | "version": 1
120 | },
121 | {
122 | "interface": "zwp_virtual_keyboard_manager_v1",
123 | "version": 1
124 | },
125 | {
126 | "interface": "zxdg_decoration_manager_v1",
127 | "version": 1
128 | },
129 | {
130 | "interface": "zxdg_output_manager_v1",
131 | "version": 3
132 | },
133 | {
134 | "interface": "zxdg_shell_v6",
135 | "version": 1
136 | }
137 | ]
138 | }
139 |
--------------------------------------------------------------------------------
/src/data/compositors/mutter.json:
--------------------------------------------------------------------------------
1 | {
2 | "generationTimestamp": 1742778979007,
3 | "version": "48.0",
4 | "globals": [
5 | {
6 | "interface": "gtk_shell1",
7 | "version": 6
8 | },
9 | {
10 | "interface": "wl_compositor",
11 | "version": 6
12 | },
13 | {
14 | "interface": "wl_data_device_manager",
15 | "version": 3
16 | },
17 | {
18 | "interface": "wl_drm",
19 | "version": 2
20 | },
21 | {
22 | "interface": "wl_output",
23 | "version": 4
24 | },
25 | {
26 | "interface": "wl_seat",
27 | "version": 8
28 | },
29 | {
30 | "interface": "wl_shm",
31 | "version": 2
32 | },
33 | {
34 | "interface": "wl_subcompositor",
35 | "version": 1
36 | },
37 | {
38 | "interface": "wp_color_manager_v1",
39 | "version": 1
40 | },
41 | {
42 | "interface": "wp_commit_timing_manager_v1",
43 | "version": 1
44 | },
45 | {
46 | "interface": "wp_cursor_shape_manager_v1",
47 | "version": 2
48 | },
49 | {
50 | "interface": "wp_drm_lease_device_v1",
51 | "version": 1
52 | },
53 | {
54 | "interface": "wp_drm_lease_device_v1",
55 | "version": 1
56 | },
57 | {
58 | "interface": "wp_fifo_manager_v1",
59 | "version": 1
60 | },
61 | {
62 | "interface": "wp_fractional_scale_manager_v1",
63 | "version": 1
64 | },
65 | {
66 | "interface": "wp_linux_drm_syncobj_manager_v1",
67 | "version": 1
68 | },
69 | {
70 | "interface": "wp_presentation",
71 | "version": 2
72 | },
73 | {
74 | "interface": "wp_single_pixel_buffer_manager_v1",
75 | "version": 1
76 | },
77 | {
78 | "interface": "wp_viewporter",
79 | "version": 1
80 | },
81 | {
82 | "interface": "xdg_activation_v1",
83 | "version": 1
84 | },
85 | {
86 | "interface": "xdg_system_bell_v1",
87 | "version": 1
88 | },
89 | {
90 | "interface": "xdg_toplevel_drag_manager_v1",
91 | "version": 1
92 | },
93 | {
94 | "interface": "xdg_wm_base",
95 | "version": 6
96 | },
97 | {
98 | "interface": "xdg_wm_dialog_v1",
99 | "version": 1
100 | },
101 | {
102 | "interface": "xx_session_manager_v1",
103 | "version": 1
104 | },
105 | {
106 | "interface": "zwp_idle_inhibit_manager_v1",
107 | "version": 1
108 | },
109 | {
110 | "interface": "zwp_keyboard_shortcuts_inhibit_manager_v1",
111 | "version": 1
112 | },
113 | {
114 | "interface": "zwp_linux_dmabuf_v1",
115 | "version": 5
116 | },
117 | {
118 | "interface": "zwp_pointer_constraints_v1",
119 | "version": 1
120 | },
121 | {
122 | "interface": "zwp_pointer_gestures_v1",
123 | "version": 3
124 | },
125 | {
126 | "interface": "zwp_primary_selection_device_manager_v1",
127 | "version": 1
128 | },
129 | {
130 | "interface": "zwp_relative_pointer_manager_v1",
131 | "version": 1
132 | },
133 | {
134 | "interface": "zwp_tablet_manager_v2",
135 | "version": 1
136 | },
137 | {
138 | "interface": "zwp_text_input_manager_v3",
139 | "version": 1
140 | },
141 | {
142 | "interface": "zxdg_exporter_v1",
143 | "version": 1
144 | },
145 | {
146 | "interface": "zxdg_exporter_v2",
147 | "version": 1
148 | },
149 | {
150 | "interface": "zxdg_importer_v1",
151 | "version": 1
152 | },
153 | {
154 | "interface": "zxdg_importer_v2",
155 | "version": 1
156 | },
157 | {
158 | "interface": "zxdg_output_manager_v1",
159 | "version": 3
160 | }
161 | ]
162 | }
163 |
--------------------------------------------------------------------------------
/src/data/compositors/niri.json:
--------------------------------------------------------------------------------
1 | {
2 | "generationTimestamp": 1740336770862,
3 | "version": "25.02",
4 | "globals": [
5 | {
6 | "interface": "ext_data_control_manager_v1",
7 | "version": 1
8 | },
9 | {
10 | "interface": "ext_idle_notifier_v1",
11 | "version": 2
12 | },
13 | {
14 | "interface": "ext_session_lock_manager_v1",
15 | "version": 1
16 | },
17 | {
18 | "interface": "mutter_x11_interop",
19 | "version": 1
20 | },
21 | {
22 | "interface": "org_kde_kwin_server_decoration_manager",
23 | "version": 1
24 | },
25 | {
26 | "interface": "wl_compositor",
27 | "version": 6
28 | },
29 | {
30 | "interface": "wl_data_device_manager",
31 | "version": 3
32 | },
33 | {
34 | "interface": "wl_drm",
35 | "version": 2
36 | },
37 | {
38 | "interface": "wl_output",
39 | "version": 4
40 | },
41 | {
42 | "interface": "wl_output",
43 | "version": 4
44 | },
45 | {
46 | "interface": "wl_seat",
47 | "version": 9
48 | },
49 | {
50 | "interface": "wl_shm",
51 | "version": 2
52 | },
53 | {
54 | "interface": "wl_subcompositor",
55 | "version": 1
56 | },
57 | {
58 | "interface": "wp_cursor_shape_manager_v1",
59 | "version": 1
60 | },
61 | {
62 | "interface": "wp_drm_lease_device_v1",
63 | "version": 1
64 | },
65 | {
66 | "interface": "wp_fractional_scale_manager_v1",
67 | "version": 1
68 | },
69 | {
70 | "interface": "wp_presentation",
71 | "version": 2
72 | },
73 | {
74 | "interface": "wp_security_context_manager_v1",
75 | "version": 1
76 | },
77 | {
78 | "interface": "wp_viewporter",
79 | "version": 1
80 | },
81 | {
82 | "interface": "xdg_activation_v1",
83 | "version": 1
84 | },
85 | {
86 | "interface": "xdg_wm_base",
87 | "version": 6
88 | },
89 | {
90 | "interface": "zwlr_data_control_manager_v1",
91 | "version": 2
92 | },
93 | {
94 | "interface": "zwlr_foreign_toplevel_manager_v1",
95 | "version": 3
96 | },
97 | {
98 | "interface": "zwlr_gamma_control_manager_v1",
99 | "version": 1
100 | },
101 | {
102 | "interface": "zwlr_layer_shell_v1",
103 | "version": 4
104 | },
105 | {
106 | "interface": "zwlr_output_manager_v1",
107 | "version": 4
108 | },
109 | {
110 | "interface": "zwlr_screencopy_manager_v1",
111 | "version": 3
112 | },
113 | {
114 | "interface": "zwlr_virtual_pointer_manager_v1",
115 | "version": 2
116 | },
117 | {
118 | "interface": "zwp_idle_inhibit_manager_v1",
119 | "version": 1
120 | },
121 | {
122 | "interface": "zwp_input_method_manager_v2",
123 | "version": 1
124 | },
125 | {
126 | "interface": "zwp_keyboard_shortcuts_inhibit_manager_v1",
127 | "version": 1
128 | },
129 | {
130 | "interface": "zwp_linux_dmabuf_v1",
131 | "version": 5
132 | },
133 | {
134 | "interface": "zwp_pointer_constraints_v1",
135 | "version": 1
136 | },
137 | {
138 | "interface": "zwp_pointer_gestures_v1",
139 | "version": 3
140 | },
141 | {
142 | "interface": "zwp_primary_selection_device_manager_v1",
143 | "version": 1
144 | },
145 | {
146 | "interface": "zwp_relative_pointer_manager_v1",
147 | "version": 1
148 | },
149 | {
150 | "interface": "zwp_tablet_manager_v2",
151 | "version": 1
152 | },
153 | {
154 | "interface": "zwp_text_input_manager_v3",
155 | "version": 1
156 | },
157 | {
158 | "interface": "zwp_virtual_keyboard_manager_v1",
159 | "version": 1
160 | },
161 | {
162 | "interface": "zxdg_decoration_manager_v1",
163 | "version": 1
164 | },
165 | {
166 | "interface": "zxdg_exporter_v2",
167 | "version": 1
168 | },
169 | {
170 | "interface": "zxdg_importer_v2",
171 | "version": 1
172 | },
173 | {
174 | "interface": "zxdg_output_manager_v1",
175 | "version": 3
176 | }
177 | ]
178 | }
179 |
--------------------------------------------------------------------------------
/src/data/compositors/treeland.json:
--------------------------------------------------------------------------------
1 | {
2 | "generationTimestamp": 1743070480786,
3 | "version": "0.5.20",
4 | "globals": [
5 | {
6 | "interface": "ext_idle_notifier_v1",
7 | "version": 1
8 | },
9 | {
10 | "interface": "treeland_capture_manager_v1",
11 | "version": 1
12 | },
13 | {
14 | "interface": "treeland_dde_shell_manager_v1",
15 | "version": 1
16 | },
17 | {
18 | "interface": "treeland_foreign_toplevel_manager_v1",
19 | "version": 1
20 | },
21 | {
22 | "interface": "treeland_output_manager_v1",
23 | "version": 1
24 | },
25 | {
26 | "interface": "treeland_personalization_manager_v1",
27 | "version": 1
28 | },
29 | {
30 | "interface": "treeland_shortcut_manager_v1",
31 | "version": 1
32 | },
33 | {
34 | "interface": "treeland_virtual_output_manager_v1",
35 | "version": 1
36 | },
37 | {
38 | "interface": "treeland_wallpaper_color_manager_v1",
39 | "version": 1
40 | },
41 | {
42 | "interface": "treeland_window_management_v1",
43 | "version": 1
44 | },
45 | {
46 | "interface": "wl_compositor",
47 | "version": 6
48 | },
49 | {
50 | "interface": "wl_data_device_manager",
51 | "version": 3
52 | },
53 | {
54 | "interface": "wl_output",
55 | "version": 4
56 | },
57 | {
58 | "interface": "wl_seat",
59 | "version": 9
60 | },
61 | {
62 | "interface": "wl_shm",
63 | "version": 2
64 | },
65 | {
66 | "interface": "wl_subcompositor",
67 | "version": 1
68 | },
69 | {
70 | "interface": "wp_cursor_shape_manager_v1",
71 | "version": 1
72 | },
73 | {
74 | "interface": "wp_fractional_scale_manager_v1",
75 | "version": 1
76 | },
77 | {
78 | "interface": "wp_viewporter",
79 | "version": 1
80 | },
81 | {
82 | "interface": "xdg_wm_base",
83 | "version": 5
84 | },
85 | {
86 | "interface": "zwlr_data_control_manager_v1",
87 | "version": 2
88 | },
89 | {
90 | "interface": "zwlr_foreign_toplevel_manager_v1",
91 | "version": 3
92 | },
93 | {
94 | "interface": "zwlr_gamma_control_manager_v1",
95 | "version": 1
96 | },
97 | {
98 | "interface": "zwlr_layer_shell_v1",
99 | "version": 4
100 | },
101 | {
102 | "interface": "zwlr_output_manager_v1",
103 | "version": 4
104 | },
105 | {
106 | "interface": "zwlr_output_power_manager_v1",
107 | "version": 1
108 | },
109 | {
110 | "interface": "zwlr_screencopy_manager_v1",
111 | "version": 3
112 | },
113 | {
114 | "interface": "zwp_idle_inhibit_manager_v1",
115 | "version": 1
116 | },
117 | {
118 | "interface": "zwp_input_method_manager_v2",
119 | "version": 1
120 | },
121 | {
122 | "interface": "zwp_linux_dmabuf_v1",
123 | "version": 4
124 | },
125 | {
126 | "interface": "zwp_pointer_gestures_v1",
127 | "version": 3
128 | },
129 | {
130 | "interface": "zwp_primary_selection_device_manager_v1",
131 | "version": 1
132 | },
133 | {
134 | "interface": "zwp_text_input_manager_v1",
135 | "version": 1
136 | },
137 | {
138 | "interface": "zwp_text_input_manager_v2",
139 | "version": 1
140 | },
141 | {
142 | "interface": "zwp_text_input_manager_v3",
143 | "version": 1
144 | },
145 | {
146 | "interface": "zwp_virtual_keyboard_manager_v1",
147 | "version": 1
148 | },
149 | {
150 | "interface": "zxdg_decoration_manager_v1",
151 | "version": 1
152 | },
153 | {
154 | "interface": "zxdg_output_manager_v1",
155 | "version": 3
156 | }
157 | ]
158 | }
159 |
160 |
--------------------------------------------------------------------------------
/src/data/compositors/wayfire.json:
--------------------------------------------------------------------------------
1 | {
2 | "generationTimestamp": 1739631863414,
3 | "version": "0.9.0",
4 | "globals": [
5 | {
6 | "interface": "ext_idle_notifier_v1",
7 | "version": 1
8 | },
9 | {
10 | "interface": "ext_session_lock_manager_v1",
11 | "version": 1
12 | },
13 | {
14 | "interface": "gtk_shell1",
15 | "version": 3
16 | },
17 | {
18 | "interface": "org_kde_kwin_server_decoration_manager",
19 | "version": 1
20 | },
21 | {
22 | "interface": "wl_compositor",
23 | "version": 6
24 | },
25 | {
26 | "interface": "wl_data_device_manager",
27 | "version": 3
28 | },
29 | {
30 | "interface": "wl_output",
31 | "version": 4
32 | },
33 | {
34 | "interface": "wl_seat",
35 | "version": 9
36 | },
37 | {
38 | "interface": "wl_shm",
39 | "version": 2
40 | },
41 | {
42 | "interface": "wl_subcompositor",
43 | "version": 1
44 | },
45 | {
46 | "interface": "wp_drm_lease_device_v1",
47 | "version": 1
48 | },
49 | {
50 | "interface": "wp_fractional_scale_manager_v1",
51 | "version": 1
52 | },
53 | {
54 | "interface": "wp_presentation",
55 | "version": 1
56 | },
57 | {
58 | "interface": "wp_single_pixel_buffer_manager_v1",
59 | "version": 1
60 | },
61 | {
62 | "interface": "wp_viewporter",
63 | "version": 1
64 | },
65 | {
66 | "interface": "xdg_activation_v1",
67 | "version": 1
68 | },
69 | {
70 | "interface": "xdg_wm_base",
71 | "version": 6
72 | },
73 | {
74 | "interface": "xwayland_shell_v1",
75 | "version": 1
76 | },
77 | {
78 | "interface": "zwf_shell_manager_v2",
79 | "version": 2
80 | },
81 | {
82 | "interface": "zwlr_data_control_manager_v1",
83 | "version": 2
84 | },
85 | {
86 | "interface": "zwlr_export_dmabuf_manager_v1",
87 | "version": 1
88 | },
89 | {
90 | "interface": "zwlr_foreign_toplevel_manager_v1",
91 | "version": 3
92 | },
93 | {
94 | "interface": "zwlr_gamma_control_manager_v1",
95 | "version": 1
96 | },
97 | {
98 | "interface": "zwlr_layer_shell_v1",
99 | "version": 4
100 | },
101 | {
102 | "interface": "zwlr_output_manager_v1",
103 | "version": 4
104 | },
105 | {
106 | "interface": "zwlr_output_power_manager_v1",
107 | "version": 1
108 | },
109 | {
110 | "interface": "zwlr_screencopy_manager_v1",
111 | "version": 3
112 | },
113 | {
114 | "interface": "zwlr_virtual_pointer_manager_v1",
115 | "version": 2
116 | },
117 | {
118 | "interface": "zwp_idle_inhibit_manager_v1",
119 | "version": 1
120 | },
121 | {
122 | "interface": "zwp_keyboard_shortcuts_inhibit_manager_v1",
123 | "version": 1
124 | },
125 | {
126 | "interface": "zwp_linux_dmabuf_v1",
127 | "version": 4
128 | },
129 | {
130 | "interface": "zwp_pointer_constraints_v1",
131 | "version": 1
132 | },
133 | {
134 | "interface": "zwp_pointer_gestures_v1",
135 | "version": 3
136 | },
137 | {
138 | "interface": "zwp_primary_selection_device_manager_v1",
139 | "version": 1
140 | },
141 | {
142 | "interface": "zwp_relative_pointer_manager_v1",
143 | "version": 1
144 | },
145 | {
146 | "interface": "zwp_tablet_manager_v2",
147 | "version": 1
148 | },
149 | {
150 | "interface": "zwp_virtual_keyboard_manager_v1",
151 | "version": 1
152 | },
153 | {
154 | "interface": "zxdg_decoration_manager_v1",
155 | "version": 1
156 | },
157 | {
158 | "interface": "zxdg_exporter_v1",
159 | "version": 1
160 | },
161 | {
162 | "interface": "zxdg_exporter_v2",
163 | "version": 1
164 | },
165 | {
166 | "interface": "zxdg_importer_v1",
167 | "version": 1
168 | },
169 | {
170 | "interface": "zxdg_importer_v2",
171 | "version": 1
172 | },
173 | {
174 | "interface": "zxdg_output_manager_v1",
175 | "version": 3
176 | }
177 | ]
178 | }
179 |
--------------------------------------------------------------------------------
/src/data/compositors/weston.json:
--------------------------------------------------------------------------------
1 | {
2 | "generationTimestamp": 1737939500990,
3 | "version": "14",
4 | "globals": [
5 | {
6 | "interface": "weston_capture_v1",
7 | "version": 1
8 | },
9 | {
10 | "interface": "weston_desktop_shell",
11 | "version": 1
12 | },
13 | {
14 | "interface": "wl_compositor",
15 | "version": 5
16 | },
17 | {
18 | "interface": "wl_data_device_manager",
19 | "version": 3
20 | },
21 | {
22 | "interface": "wl_drm",
23 | "version": 2
24 | },
25 | {
26 | "interface": "wl_output",
27 | "version": 4
28 | },
29 | {
30 | "interface": "wl_seat",
31 | "version": 7
32 | },
33 | {
34 | "interface": "wl_shm",
35 | "version": 2
36 | },
37 | {
38 | "interface": "wl_subcompositor",
39 | "version": 1
40 | },
41 | {
42 | "interface": "wp_presentation",
43 | "version": 1
44 | },
45 | {
46 | "interface": "wp_single_pixel_buffer_manager_v1",
47 | "version": 1
48 | },
49 | {
50 | "interface": "wp_tearing_control_manager_v1",
51 | "version": 1
52 | },
53 | {
54 | "interface": "wp_viewporter",
55 | "version": 1
56 | },
57 | {
58 | "interface": "xdg_wm_base",
59 | "version": 5
60 | },
61 | {
62 | "interface": "zwp_input_method_v1",
63 | "version": 1
64 | },
65 | {
66 | "interface": "zwp_input_panel_v1",
67 | "version": 1
68 | },
69 | {
70 | "interface": "zwp_input_timestamps_manager_v1",
71 | "version": 1
72 | },
73 | {
74 | "interface": "zwp_linux_dmabuf_v1",
75 | "version": 5
76 | },
77 | {
78 | "interface": "zwp_pointer_constraints_v1",
79 | "version": 1
80 | },
81 | {
82 | "interface": "zwp_relative_pointer_manager_v1",
83 | "version": 1
84 | },
85 | {
86 | "interface": "zwp_text_input_manager_v1",
87 | "version": 1
88 | },
89 | {
90 | "interface": "zxdg_output_manager_v1",
91 | "version": 2
92 | }
93 | ]
94 | }
95 |
--------------------------------------------------------------------------------
/src/data/protocols/kde-appmenu.json:
--------------------------------------------------------------------------------
1 | {
2 | "type": "protocol",
3 | "name": "appmenu",
4 | "copyright": {
5 | "type": "copyright",
6 | "text": "\nSPDX-FileCopyrightText: 2017 David Edmundson\n\nSPDX-License-Identifier: LGPL-2.1-or-later\n"
7 | },
8 | "interfaces": [
9 | {
10 | "type": "interface",
11 | "name": "org_kde_kwin_appmenu_manager",
12 | "version": "2",
13 | "description": {
14 | "type": "description",
15 | "text": "This interface allows a client to link a window (or wl_surface) to an com.canonical.dbusmenu\ninterface registered on DBus.",
16 | "summary": "appmenu dbus address interface"
17 | },
18 | "requests": [
19 | {
20 | "type": "request",
21 | "name": "create",
22 | "args": [
23 | {
24 | "type": "arg",
25 | "name": "id",
26 | "argType": "new_id",
27 | "interface": "org_kde_kwin_appmenu"
28 | },
29 | {
30 | "type": "arg",
31 | "name": "surface",
32 | "argType": "object",
33 | "interface": "wl_surface",
34 | "protocol": "wayland"
35 | }
36 | ]
37 | },
38 | {
39 | "type": "request",
40 | "name": "release",
41 | "requestType": "destructor",
42 | "since": "2",
43 | "description": {
44 | "type": "description",
45 | "summary": "destroy the org_kde_kwin_appmenu_manager object"
46 | },
47 | "args": []
48 | }
49 | ],
50 | "events": [],
51 | "enums": []
52 | },
53 | {
54 | "type": "interface",
55 | "name": "org_kde_kwin_appmenu",
56 | "version": "2",
57 | "description": {
58 | "type": "description",
59 | "text": "The DBus service name and object path where the appmenu interface is present\nThe object should be registered on the session bus before sending this request.\nIf not applicable, clients should remove this object.",
60 | "summary": "appmenu dbus address interface"
61 | },
62 | "requests": [
63 | {
64 | "type": "request",
65 | "name": "set_address",
66 | "description": {
67 | "type": "description",
68 | "text": "Set or update the service name and object path.\nStrings should be formatted in Latin-1 matching the relevant DBus specifications.",
69 | "summary": "initialise or update the location of the AppMenu interface"
70 | },
71 | "args": [
72 | {
73 | "type": "arg",
74 | "name": "service_name",
75 | "argType": "string"
76 | },
77 | {
78 | "type": "arg",
79 | "name": "object_path",
80 | "argType": "string"
81 | }
82 | ]
83 | },
84 | {
85 | "type": "request",
86 | "name": "release",
87 | "requestType": "destructor",
88 | "description": {
89 | "type": "description",
90 | "summary": "release the appmenu object"
91 | },
92 | "args": []
93 | }
94 | ],
95 | "events": [],
96 | "enums": []
97 | }
98 | ]
99 | }
100 |
--------------------------------------------------------------------------------
/src/data/protocols/kde-blur.json:
--------------------------------------------------------------------------------
1 | {
2 | "type": "protocol",
3 | "name": "blur",
4 | "copyright": {
5 | "type": "copyright",
6 | "text": "\nSPDX-FileCopyrightText: 2015 Martin Gräßlin\nSPDX-FileCopyrightText: 2015 Marco Martin\n\nSPDX-License-Identifier: LGPL-2.1-or-later\n"
7 | },
8 | "interfaces": [
9 | {
10 | "type": "interface",
11 | "name": "org_kde_kwin_blur_manager",
12 | "version": "1",
13 | "requests": [
14 | {
15 | "type": "request",
16 | "name": "create",
17 | "args": [
18 | {
19 | "type": "arg",
20 | "name": "id",
21 | "argType": "new_id",
22 | "interface": "org_kde_kwin_blur"
23 | },
24 | {
25 | "type": "arg",
26 | "name": "surface",
27 | "argType": "object",
28 | "interface": "wl_surface",
29 | "protocol": "wayland"
30 | }
31 | ]
32 | },
33 | {
34 | "type": "request",
35 | "name": "unset",
36 | "args": [
37 | {
38 | "type": "arg",
39 | "name": "surface",
40 | "argType": "object",
41 | "interface": "wl_surface",
42 | "protocol": "wayland"
43 | }
44 | ]
45 | }
46 | ],
47 | "events": [],
48 | "enums": []
49 | },
50 | {
51 | "type": "interface",
52 | "name": "org_kde_kwin_blur",
53 | "version": "1",
54 | "requests": [
55 | {
56 | "type": "request",
57 | "name": "commit",
58 | "args": []
59 | },
60 | {
61 | "type": "request",
62 | "name": "set_region",
63 | "args": [
64 | {
65 | "type": "arg",
66 | "name": "region",
67 | "argType": "object",
68 | "interface": "wl_region",
69 | "allowNull": "true",
70 | "protocol": "wayland"
71 | }
72 | ]
73 | },
74 | {
75 | "type": "request",
76 | "name": "release",
77 | "requestType": "destructor",
78 | "description": {
79 | "type": "description",
80 | "summary": "release the blur object"
81 | },
82 | "args": []
83 | }
84 | ],
85 | "events": [],
86 | "enums": []
87 | }
88 | ]
89 | }
90 |
--------------------------------------------------------------------------------
/src/data/protocols/kde-idle.json:
--------------------------------------------------------------------------------
1 | {
2 | "type": "protocol",
3 | "name": "idle",
4 | "copyright": {
5 | "type": "copyright",
6 | "text": "\nSPDX-FileCopyrightText: 2015 Martin Gräßlin\n\nSPDX-License-Identifier: LGPL-2.1-or-later\n"
7 | },
8 | "interfaces": [
9 | {
10 | "type": "interface",
11 | "name": "org_kde_kwin_idle",
12 | "version": "1",
13 | "description": {
14 | "type": "description",
15 | "text": "This interface allows to monitor user idle time on a given seat. The interface\nallows to register timers which trigger after no user activity was registered\non the seat for a given interval. It notifies when user activity resumes.\n\nThis is useful for applications wanting to perform actions when the user is not\ninteracting with the system, e.g. chat applications setting the user as away, power\nmanagement features to dim screen, etc..",
16 | "summary": "User idle time manager"
17 | },
18 | "requests": [
19 | {
20 | "type": "request",
21 | "name": "get_idle_timeout",
22 | "args": [
23 | {
24 | "type": "arg",
25 | "name": "id",
26 | "argType": "new_id",
27 | "interface": "org_kde_kwin_idle_timeout"
28 | },
29 | {
30 | "type": "arg",
31 | "name": "seat",
32 | "argType": "object",
33 | "interface": "wl_seat",
34 | "protocol": "wayland"
35 | },
36 | {
37 | "type": "arg",
38 | "name": "timeout",
39 | "argType": "uint",
40 | "summary": "The idle timeout in msec"
41 | }
42 | ]
43 | }
44 | ],
45 | "events": [],
46 | "enums": []
47 | },
48 | {
49 | "type": "interface",
50 | "name": "org_kde_kwin_idle_timeout",
51 | "version": "1",
52 | "requests": [
53 | {
54 | "type": "request",
55 | "name": "release",
56 | "requestType": "destructor",
57 | "description": {
58 | "type": "description",
59 | "summary": "release the timeout object"
60 | },
61 | "args": []
62 | },
63 | {
64 | "type": "request",
65 | "name": "simulate_user_activity",
66 | "description": {
67 | "type": "description",
68 | "summary": "Simulates user activity for this timeout, behaves just like real user activity on the seat"
69 | },
70 | "args": []
71 | }
72 | ],
73 | "events": [
74 | {
75 | "type": "event",
76 | "name": "idle",
77 | "description": {
78 | "type": "description",
79 | "summary": "Triggered when there has not been any user activity in the requested idle time interval"
80 | },
81 | "args": []
82 | },
83 | {
84 | "type": "event",
85 | "name": "resumed",
86 | "description": {
87 | "type": "description",
88 | "summary": "Triggered on the first user activity after an idle event"
89 | },
90 | "args": []
91 | }
92 | ],
93 | "enums": []
94 | }
95 | ]
96 | }
97 |
--------------------------------------------------------------------------------
/src/data/protocols/kde-keystate.json:
--------------------------------------------------------------------------------
1 | {
2 | "type": "protocol",
3 | "name": "keystate",
4 | "copyright": {
5 | "type": "copyright",
6 | "text": "\nSPDX-FileCopyrightText: 2019 Aleix Pol Gonzalez \n\nSPDX-License-Identifier: LGPL-2.1-or-later\n"
7 | },
8 | "interfaces": [
9 | {
10 | "type": "interface",
11 | "name": "org_kde_kwin_keystate",
12 | "version": "5",
13 | "description": {
14 | "type": "description",
15 | "text": "Keeps track of the states of the different keys that have a state attached to it.",
16 | "summary": "Key States"
17 | },
18 | "requests": [
19 | {
20 | "type": "request",
21 | "name": "fetchStates",
22 | "args": []
23 | },
24 | {
25 | "type": "request",
26 | "name": "destroy",
27 | "requestType": "destructor",
28 | "since": "4",
29 | "args": []
30 | }
31 | ],
32 | "events": [
33 | {
34 | "type": "event",
35 | "name": "stateChanged",
36 | "description": {
37 | "type": "description",
38 | "summary": "Updates the state for a said key"
39 | },
40 | "args": [
41 | {
42 | "type": "arg",
43 | "name": "key",
44 | "argType": "uint"
45 | },
46 | {
47 | "type": "arg",
48 | "name": "state",
49 | "argType": "uint"
50 | }
51 | ]
52 | }
53 | ],
54 | "enums": [
55 | {
56 | "type": "enum",
57 | "name": "key",
58 | "bitfield": false,
59 | "entries": [
60 | {
61 | "type": "entry",
62 | "name": "capslock",
63 | "value": "0"
64 | },
65 | {
66 | "type": "entry",
67 | "name": "numlock",
68 | "value": "1"
69 | },
70 | {
71 | "type": "entry",
72 | "name": "scrolllock",
73 | "value": "2"
74 | },
75 | {
76 | "type": "entry",
77 | "name": "alt",
78 | "value": "3",
79 | "since": "5"
80 | },
81 | {
82 | "type": "entry",
83 | "name": "control",
84 | "value": "4",
85 | "since": "5"
86 | },
87 | {
88 | "type": "entry",
89 | "name": "shift",
90 | "value": "5",
91 | "since": "5"
92 | },
93 | {
94 | "type": "entry",
95 | "name": "meta",
96 | "value": "6",
97 | "since": "5"
98 | },
99 | {
100 | "type": "entry",
101 | "name": "altgr",
102 | "value": "7",
103 | "since": "5"
104 | }
105 | ]
106 | },
107 | {
108 | "type": "enum",
109 | "name": "state",
110 | "bitfield": false,
111 | "entries": [
112 | {
113 | "type": "entry",
114 | "name": "unlocked",
115 | "value": "0"
116 | },
117 | {
118 | "type": "entry",
119 | "name": "latched",
120 | "value": "1"
121 | },
122 | {
123 | "type": "entry",
124 | "name": "locked",
125 | "value": "2"
126 | },
127 | {
128 | "type": "entry",
129 | "name": "pressed",
130 | "value": "3",
131 | "since": "5"
132 | }
133 | ]
134 | }
135 | ]
136 | }
137 | ]
138 | }
139 |
--------------------------------------------------------------------------------
/src/data/protocols/kde-lockscreen-overlay-v1.json:
--------------------------------------------------------------------------------
1 | {
2 | "type": "protocol",
3 | "name": "kde_lockscreen_overlay_v1",
4 | "copyright": {
5 | "type": "copyright",
6 | "text": "\nSPDX-FileCopyrightText: 2022 Aleix Pol Gonzalez \n\nSPDX-License-Identifier: LGPL-2.1-or-later\n"
7 | },
8 | "interfaces": [
9 | {
10 | "type": "interface",
11 | "name": "kde_lockscreen_overlay_v1",
12 | "version": "1",
13 | "description": {
14 | "type": "description",
15 | "text": "Allows a client to request a surface to be visible when the system is locked.\n\nThis is meant to be used for specific high urgency cases like phone calls or alarms.\n\nWarning! The protocol described in this file is a desktop environment\nimplementation detail. Regular clients must not use this protocol.\nBackward incompatible changes may be added without bumping the major\nversion of the extension.",
16 | "summary": "Allow surfaces over the lockscreen"
17 | },
18 | "requests": [
19 | {
20 | "type": "request",
21 | "name": "allow",
22 | "description": {
23 | "type": "description",
24 | "text": "Informs the compositor that the surface could be shown when the screen is locked. This request should be called while the surface is unmapped.",
25 | "summary": "Tell about which surface could be raised above the lockscreen"
26 | },
27 | "args": [
28 | {
29 | "type": "arg",
30 | "name": "surface",
31 | "argType": "object",
32 | "interface": "wl_surface",
33 | "protocol": "wayland"
34 | }
35 | ]
36 | },
37 | {
38 | "type": "request",
39 | "name": "destroy",
40 | "requestType": "destructor",
41 | "description": {
42 | "type": "description",
43 | "text": "This won't affect the surface previously marked with the allow request.",
44 | "summary": "Destroy the kde_lockscreen_overlay_v1"
45 | },
46 | "args": []
47 | }
48 | ],
49 | "events": [],
50 | "enums": [
51 | {
52 | "type": "enum",
53 | "name": "error",
54 | "bitfield": false,
55 | "entries": [
56 | {
57 | "type": "entry",
58 | "name": "invalid_surface_state",
59 | "value": "0",
60 | "summary": "the client provided an invalid surface state"
61 | }
62 | ]
63 | }
64 | ]
65 | }
66 | ]
67 | }
68 |
--------------------------------------------------------------------------------
/src/data/protocols/kde-output-order-v1.json:
--------------------------------------------------------------------------------
1 | {
2 | "type": "protocol",
3 | "name": "kde_output_order_v1",
4 | "copyright": {
5 | "type": "copyright",
6 | "text": "\nSPDX-FileCopyrightText: 2022 Xaver Hugl \n\nSPDX-License-Identifier: MIT-CMU\n"
7 | },
8 | "interfaces": [
9 | {
10 | "type": "interface",
11 | "name": "kde_output_order_v1",
12 | "version": "1",
13 | "description": {
14 | "type": "description",
15 | "text": "Announce the order in which desktop environment components should be placed on outputs.\nThe compositor will send the list of outputs when the global is bound and whenever there is a change.\n\nWarning! The protocol described in this file is a desktop environment\nimplementation detail. Regular clients must not use this protocol.\nBackward incompatible changes may be added without bumping the major\nversion of the extension.",
16 | "summary": "announce order of outputs"
17 | },
18 | "requests": [
19 | {
20 | "type": "request",
21 | "name": "destroy",
22 | "requestType": "destructor",
23 | "description": {
24 | "type": "description",
25 | "summary": "Destroy the output order notifier."
26 | },
27 | "args": []
28 | }
29 | ],
30 | "events": [
31 | {
32 | "type": "event",
33 | "name": "output",
34 | "description": {
35 | "type": "description",
36 | "text": "Specifies the output identified by their wl_output.name.",
37 | "summary": "output name"
38 | },
39 | "args": [
40 | {
41 | "type": "arg",
42 | "name": "output_name",
43 | "argType": "string",
44 | "summary": "the name of the output"
45 | }
46 | ]
47 | },
48 | {
49 | "type": "event",
50 | "name": "done",
51 | "description": {
52 | "type": "description",
53 | "text": "Specifies that the output list is complete. On the next output event, a new list begins.",
54 | "summary": "done"
55 | },
56 | "args": []
57 | }
58 | ],
59 | "enums": []
60 | }
61 | ]
62 | }
63 |
--------------------------------------------------------------------------------
/src/data/protocols/kde-primary-output-v1.json:
--------------------------------------------------------------------------------
1 | {
2 | "type": "protocol",
3 | "name": "kde_primary_output_v1",
4 | "copyright": {
5 | "type": "copyright",
6 | "text": "\nSPDX-FileCopyrightText: 2021 Aleix Pol Gonzalez \n\nSPDX-License-Identifier: MIT-CMU\n"
7 | },
8 | "interfaces": [
9 | {
10 | "type": "interface",
11 | "name": "kde_primary_output_v1",
12 | "version": "2",
13 | "description": {
14 | "type": "description",
15 | "text": "Protocol for telling which is the primary display among the selection\nof enabled outputs.\n\nWarning! The protocol described in this file is a desktop environment\nimplementation detail. Regular clients must not use this protocol.\nBackward incompatible changes may be added without bumping the major\nversion of the extension.",
16 | "summary": "expose which is the primary display"
17 | },
18 | "requests": [
19 | {
20 | "type": "request",
21 | "name": "destroy",
22 | "requestType": "destructor",
23 | "since": "2",
24 | "description": {
25 | "type": "description",
26 | "summary": "Destroy the primary output notifier."
27 | },
28 | "args": []
29 | }
30 | ],
31 | "events": [
32 | {
33 | "type": "event",
34 | "name": "primary_output",
35 | "description": {
36 | "type": "description",
37 | "text": "Specifies which output is the primary one identified by their uuid. See kde_output_device_v2 uuid event for more information about it.",
38 | "summary": "Provide the current primary output's name"
39 | },
40 | "args": [
41 | {
42 | "type": "arg",
43 | "name": "output_name",
44 | "argType": "string",
45 | "summary": "the name of the output"
46 | }
47 | ]
48 | }
49 | ],
50 | "enums": []
51 | }
52 | ]
53 | }
54 |
--------------------------------------------------------------------------------
/src/data/protocols/kde-server-decoration-palette.json:
--------------------------------------------------------------------------------
1 | {
2 | "type": "protocol",
3 | "name": "server_decoration_palette",
4 | "copyright": {
5 | "type": "copyright",
6 | "text": "\nSPDX-FileCopyrightText: 2017 David Edmundson\n\nSPDX-License-Identifier: LGPL-2.1-or-later\n"
7 | },
8 | "interfaces": [
9 | {
10 | "type": "interface",
11 | "name": "org_kde_kwin_server_decoration_palette_manager",
12 | "version": "1",
13 | "description": {
14 | "type": "description",
15 | "text": "This interface allows a client to alter the palette of a server side decoration.",
16 | "summary": "server side decoration palette manager interface"
17 | },
18 | "requests": [
19 | {
20 | "type": "request",
21 | "name": "create",
22 | "args": [
23 | {
24 | "type": "arg",
25 | "name": "id",
26 | "argType": "new_id",
27 | "interface": "org_kde_kwin_server_decoration_palette"
28 | },
29 | {
30 | "type": "arg",
31 | "name": "surface",
32 | "argType": "object",
33 | "interface": "wl_surface",
34 | "protocol": "wayland"
35 | }
36 | ]
37 | }
38 | ],
39 | "events": [],
40 | "enums": []
41 | },
42 | {
43 | "type": "interface",
44 | "name": "org_kde_kwin_server_decoration_palette",
45 | "version": "1",
46 | "description": {
47 | "type": "description",
48 | "text": "This interface allows a client to alter the palette of a server side decoration.",
49 | "summary": "server side decoration palette interface"
50 | },
51 | "requests": [
52 | {
53 | "type": "request",
54 | "name": "set_palette",
55 | "description": {
56 | "type": "description",
57 | "text": "Color scheme that should be applied to the window decoration.\nAbsolute file path, or name of palette in the user's config directory.\nThe server may choose not to follow the requested style.",
58 | "summary": "Set a on the server side window decoration"
59 | },
60 | "args": [
61 | {
62 | "type": "arg",
63 | "name": "palette",
64 | "argType": "string",
65 | "summary": "Absolute file path, or name of palette in the user's config directory"
66 | }
67 | ]
68 | },
69 | {
70 | "type": "request",
71 | "name": "release",
72 | "requestType": "destructor",
73 | "description": {
74 | "type": "description",
75 | "summary": "release the palette object"
76 | },
77 | "args": []
78 | }
79 | ],
80 | "events": [],
81 | "enums": []
82 | }
83 | ]
84 | }
85 |
--------------------------------------------------------------------------------
/src/data/protocols/kde-slide.json:
--------------------------------------------------------------------------------
1 | {
2 | "type": "protocol",
3 | "name": "slide",
4 | "copyright": {
5 | "type": "copyright",
6 | "text": "\nSPDX-FileCopyrightText: 2015 Martin Gräßlin\nSPDX-FileCopyrightText: 2015 Marco Martin\n\nSPDX-License-Identifier: LGPL-2.1-or-later\n"
7 | },
8 | "interfaces": [
9 | {
10 | "type": "interface",
11 | "name": "org_kde_kwin_slide_manager",
12 | "version": "1",
13 | "requests": [
14 | {
15 | "type": "request",
16 | "name": "create",
17 | "args": [
18 | {
19 | "type": "arg",
20 | "name": "id",
21 | "argType": "new_id",
22 | "interface": "org_kde_kwin_slide"
23 | },
24 | {
25 | "type": "arg",
26 | "name": "surface",
27 | "argType": "object",
28 | "interface": "wl_surface",
29 | "protocol": "wayland"
30 | }
31 | ]
32 | },
33 | {
34 | "type": "request",
35 | "name": "unset",
36 | "args": [
37 | {
38 | "type": "arg",
39 | "name": "surface",
40 | "argType": "object",
41 | "interface": "wl_surface",
42 | "protocol": "wayland"
43 | }
44 | ]
45 | }
46 | ],
47 | "events": [],
48 | "enums": []
49 | },
50 | {
51 | "type": "interface",
52 | "name": "org_kde_kwin_slide",
53 | "version": "1",
54 | "description": {
55 | "type": "description",
56 | "text": "Ask the compositor to move the surface from a location to another\nwith a slide animation.\n\nThe from argument provides a clue about where the slide animation\nbegins, offset is the distance from screen edge to begin the animation.",
57 | "summary": "slide a surface from a location to another"
58 | },
59 | "requests": [
60 | {
61 | "type": "request",
62 | "name": "commit",
63 | "args": []
64 | },
65 | {
66 | "type": "request",
67 | "name": "set_location",
68 | "args": [
69 | {
70 | "type": "arg",
71 | "name": "location",
72 | "argType": "uint"
73 | }
74 | ]
75 | },
76 | {
77 | "type": "request",
78 | "name": "set_offset",
79 | "args": [
80 | {
81 | "type": "arg",
82 | "name": "offset",
83 | "argType": "int"
84 | }
85 | ]
86 | },
87 | {
88 | "type": "request",
89 | "name": "release",
90 | "requestType": "destructor",
91 | "description": {
92 | "type": "description",
93 | "summary": "release the slide object"
94 | },
95 | "args": []
96 | }
97 | ],
98 | "events": [],
99 | "enums": [
100 | {
101 | "type": "enum",
102 | "name": "location",
103 | "bitfield": false,
104 | "entries": [
105 | {
106 | "type": "entry",
107 | "name": "left",
108 | "value": "0"
109 | },
110 | {
111 | "type": "entry",
112 | "name": "top",
113 | "value": "1"
114 | },
115 | {
116 | "type": "entry",
117 | "name": "right",
118 | "value": "2"
119 | },
120 | {
121 | "type": "entry",
122 | "name": "bottom",
123 | "value": "3"
124 | }
125 | ]
126 | }
127 | ]
128 | }
129 | ]
130 | }
131 |
--------------------------------------------------------------------------------
/src/data/protocols/single-pixel-buffer-v1.json:
--------------------------------------------------------------------------------
1 | {
2 | "type": "protocol",
3 | "name": "single_pixel_buffer_v1",
4 | "copyright": {
5 | "type": "copyright",
6 | "text": "Copyright © 2022 Simon Ser\n\nPermission is hereby granted, free of charge, to any person obtaining a\ncopy of this software and associated documentation files (the \"Software\"),\nto deal in the Software without restriction, including without limitation\nthe rights to use, copy, modify, merge, publish, distribute, sublicense,\nand/or sell copies of the Software, and to permit persons to whom the\nSoftware is furnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice (including the next\nparagraph) shall be included in all copies or substantial portions of the\nSoftware.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL\nTHE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\nFROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER\nDEALINGS IN THE SOFTWARE."
7 | },
8 | "description": {
9 | "type": "description",
10 | "text": "This protocol extension allows clients to create single-pixel buffers.\n\nCompositors supporting this protocol extension should also support the\nviewporter protocol extension. Clients may use viewporter to scale a\nsingle-pixel buffer to a desired size.\n\nWarning! The protocol described in this file is currently in the testing\nphase. Backward compatible changes may be added together with the\ncorresponding interface version bump. Backward incompatible changes can\nonly be done by creating a new major version of the extension.",
11 | "summary": "single pixel buffer factory"
12 | },
13 | "interfaces": [
14 | {
15 | "type": "interface",
16 | "name": "wp_single_pixel_buffer_manager_v1",
17 | "version": "1",
18 | "description": {
19 | "type": "description",
20 | "text": "The wp_single_pixel_buffer_manager_v1 interface is a factory for\nsingle-pixel buffers.",
21 | "summary": "global factory for single-pixel buffers"
22 | },
23 | "requests": [
24 | {
25 | "type": "request",
26 | "name": "destroy",
27 | "requestType": "destructor",
28 | "description": {
29 | "type": "description",
30 | "text": "Destroy the wp_single_pixel_buffer_manager_v1 object.\n\nThe child objects created via this interface are unaffected.",
31 | "summary": "destroy the manager"
32 | },
33 | "args": []
34 | },
35 | {
36 | "type": "request",
37 | "name": "create_u32_rgba_buffer",
38 | "description": {
39 | "type": "description",
40 | "text": "Create a single-pixel buffer from four 32-bit RGBA values.\n\nUnless specified in another protocol extension, the RGBA values use\npre-multiplied alpha.\n\nThe width and height of the buffer are 1.",
41 | "summary": "create a 1×1 buffer from 32-bit RGBA values"
42 | },
43 | "args": [
44 | {
45 | "type": "arg",
46 | "name": "id",
47 | "argType": "new_id",
48 | "interface": "wl_buffer",
49 | "protocol": "wayland"
50 | },
51 | {
52 | "type": "arg",
53 | "name": "r",
54 | "argType": "uint",
55 | "summary": "value of the buffer's red channel"
56 | },
57 | {
58 | "type": "arg",
59 | "name": "g",
60 | "argType": "uint",
61 | "summary": "value of the buffer's green channel"
62 | },
63 | {
64 | "type": "arg",
65 | "name": "b",
66 | "argType": "uint",
67 | "summary": "value of the buffer's blue channel"
68 | },
69 | {
70 | "type": "arg",
71 | "name": "a",
72 | "argType": "uint",
73 | "summary": "value of the buffer's alpha channel"
74 | }
75 | ]
76 | }
77 | ],
78 | "events": [],
79 | "enums": []
80 | }
81 | ]
82 | }
83 |
--------------------------------------------------------------------------------
/src/data/protocols/text-cursor-position.json:
--------------------------------------------------------------------------------
1 | {
2 | "type": "protocol",
3 | "name": "text_cursor_position",
4 | "interfaces": [
5 | {
6 | "type": "interface",
7 | "name": "text_cursor_position",
8 | "version": "1",
9 | "requests": [
10 | {
11 | "type": "request",
12 | "name": "notify",
13 | "args": [
14 | {
15 | "type": "arg",
16 | "name": "surface",
17 | "argType": "object",
18 | "interface": "wl_surface",
19 | "protocol": "wayland"
20 | },
21 | {
22 | "type": "arg",
23 | "name": "x",
24 | "argType": "fixed"
25 | },
26 | {
27 | "type": "arg",
28 | "name": "y",
29 | "argType": "fixed"
30 | }
31 | ]
32 | }
33 | ],
34 | "events": [],
35 | "enums": []
36 | }
37 | ]
38 | }
39 |
--------------------------------------------------------------------------------
/src/data/protocols/treeland-output-manager-v1.json:
--------------------------------------------------------------------------------
1 | {
2 | "type": "protocol",
3 | "name": "treeland_output_manager_v1",
4 | "copyright": {
5 | "type": "copyright",
6 | "text": "\nSPDX-FileCopyrightText: 2024 UnionTech Software Technology Co., Ltd.\nSPDX-License-Identifier: MIT\n"
7 | },
8 | "interfaces": [
9 | {
10 | "type": "interface",
11 | "name": "treeland_output_manager_v1",
12 | "version": "1",
13 | "description": {
14 | "type": "description",
15 | "text": "Protocol for telling which is the primary display among the selection of enabled\noutputs.",
16 | "summary": "expose which is the primary display"
17 | },
18 | "requests": [
19 | {
20 | "type": "request",
21 | "name": "set_primary_output",
22 | "since": "1",
23 | "description": {
24 | "type": "description",
25 | "summary": "Select which primary output to use"
26 | },
27 | "args": [
28 | {
29 | "type": "arg",
30 | "name": "output",
31 | "argType": "string",
32 | "allowNull": "false"
33 | }
34 | ]
35 | },
36 | {
37 | "type": "request",
38 | "name": "destroy",
39 | "requestType": "destructor",
40 | "since": "1",
41 | "description": {
42 | "type": "description",
43 | "summary": "Destroy the primary output notifier."
44 | },
45 | "args": []
46 | }
47 | ],
48 | "events": [
49 | {
50 | "type": "event",
51 | "name": "primary_output",
52 | "description": {
53 | "type": "description",
54 | "text": "Specifies which output is the primary one identified by their name.",
55 | "summary": "Provide the current primary output's name"
56 | },
57 | "args": [
58 | {
59 | "type": "arg",
60 | "name": "output_name",
61 | "argType": "string",
62 | "summary": "the name of the output"
63 | }
64 | ]
65 | }
66 | ],
67 | "enums": []
68 | }
69 | ]
70 | }
71 |
--------------------------------------------------------------------------------
/src/data/protocols/treeland-shortcut-manager-v1.json:
--------------------------------------------------------------------------------
1 | {
2 | "type": "protocol",
3 | "name": "treeland_shortcut_manager_v1",
4 | "copyright": {
5 | "type": "copyright",
6 | "text": "\nSPDX-FileCopyrightText: 2024 UnionTech Software Technology Co., Ltd.\nSPDX-License-Identifier: MIT\n"
7 | },
8 | "interfaces": [
9 | {
10 | "type": "interface",
11 | "name": "treeland_shortcut_manager_v1",
12 | "version": "1",
13 | "description": {
14 | "type": "description",
15 | "text": "This interface allows a client to get some shell's info.\n\nWarning! The protocol described in this file is currently in the testing\nphase. Backward compatible changes may be added together with the\ncorresponding interface version bump. Backward incompatible changes can\nonly be done by creating a new major version of the extension.",
16 | "summary": "shortcut manager"
17 | },
18 | "requests": [
19 | {
20 | "type": "request",
21 | "name": "register_shortcut_context",
22 | "description": {
23 | "type": "description",
24 | "text": "The format of the shortcut key is 'Modify+Key', such as 'Ctrl+Alt+T'.\nIf the format is wrong, the synthesizer will give a \"format error\". If the shortcut\nkey is already registered,\nthe compositor will give a \"register error\" and issue a destruction to the context.",
25 | "summary": "register shortcut key"
26 | },
27 | "args": [
28 | {
29 | "type": "arg",
30 | "name": "key",
31 | "argType": "string"
32 | },
33 | {
34 | "type": "arg",
35 | "name": "id",
36 | "argType": "new_id",
37 | "interface": "treeland_shortcut_context_v1"
38 | }
39 | ]
40 | }
41 | ],
42 | "events": [],
43 | "enums": []
44 | },
45 | {
46 | "type": "interface",
47 | "name": "treeland_shortcut_context_v1",
48 | "version": "1",
49 | "description": {
50 | "type": "description",
51 | "text": "This interface allows a client to listen a shortcut action.\n\nWarning! The protocol described in this file is currently in the testing\nphase. Backward compatible changes may be added together with the\ncorresponding interface version bump. Backward incompatible changes can\nonly be done by creating a new major version of the extension.",
52 | "summary": "client shortcut context"
53 | },
54 | "requests": [
55 | {
56 | "type": "request",
57 | "name": "destroy",
58 | "requestType": "destructor",
59 | "description": {
60 | "type": "description",
61 | "text": "Destroy the context object.",
62 | "summary": "destroy the context object"
63 | },
64 | "args": []
65 | }
66 | ],
67 | "events": [
68 | {
69 | "type": "event",
70 | "name": "shortcut",
71 | "args": []
72 | }
73 | ],
74 | "enums": [
75 | {
76 | "type": "enum",
77 | "name": "error",
78 | "bitfield": false,
79 | "entries": [
80 | {
81 | "type": "entry",
82 | "name": "register_failed",
83 | "value": "1",
84 | "summary": "shortcut register failed"
85 | }
86 | ]
87 | }
88 | ]
89 | }
90 | ]
91 | }
92 |
--------------------------------------------------------------------------------
/src/data/protocols/treeland-wallpaper-color-v1.json:
--------------------------------------------------------------------------------
1 | {
2 | "type": "protocol",
3 | "name": "treeland_wallpaper_color_v1",
4 | "copyright": {
5 | "type": "copyright",
6 | "text": "\nSPDX-FileCopyrightText: 2024 UnionTech Software Technology Co., Ltd.\nSPDX-License-Identifier: MIT\n"
7 | },
8 | "interfaces": [
9 | {
10 | "type": "interface",
11 | "name": "treeland_wallpaper_color_manager_v1",
12 | "version": "1",
13 | "requests": [
14 | {
15 | "type": "request",
16 | "name": "watch",
17 | "description": {
18 | "type": "description",
19 | "text": "Monitor the wallpaper color of a given screen.",
20 | "summary": "watch wallpaper color"
21 | },
22 | "args": [
23 | {
24 | "type": "arg",
25 | "name": "output",
26 | "argType": "string",
27 | "summary": "system output name"
28 | }
29 | ]
30 | },
31 | {
32 | "type": "request",
33 | "name": "unwatch",
34 | "description": {
35 | "type": "description",
36 | "text": "Stop monitor the wallpaper color for the given screen.",
37 | "summary": "unwatch wallpaper color"
38 | },
39 | "args": [
40 | {
41 | "type": "arg",
42 | "name": "output",
43 | "argType": "string",
44 | "summary": "system output name"
45 | }
46 | ]
47 | },
48 | {
49 | "type": "request",
50 | "name": "destroy",
51 | "requestType": "destructor",
52 | "description": {
53 | "type": "description",
54 | "text": "The client no longer cares about wallpaper_color.",
55 | "summary": "destroy the context object"
56 | },
57 | "args": []
58 | }
59 | ],
60 | "events": [
61 | {
62 | "type": "event",
63 | "name": "output_color",
64 | "description": {
65 | "type": "description",
66 | "text": "Tell the client that the wallpaper color of the screen it is monitoring has changed.\nThis event will also be sent immediately when the client requests a watch.",
67 | "summary": "output color changed"
68 | },
69 | "args": [
70 | {
71 | "type": "arg",
72 | "name": "output",
73 | "argType": "string",
74 | "summary": "system output name"
75 | },
76 | {
77 | "type": "arg",
78 | "name": "isdark",
79 | "argType": "uint"
80 | }
81 | ]
82 | }
83 | ],
84 | "enums": []
85 | }
86 | ]
87 | }
88 |
--------------------------------------------------------------------------------
/src/data/protocols/treeland-window-management-v1.json:
--------------------------------------------------------------------------------
1 | {
2 | "type": "protocol",
3 | "name": "treeland_window_management_v1",
4 | "copyright": {
5 | "type": "copyright",
6 | "text": "\nSPDX-FileCopyrightText: 2024 UnionTech Software Technology Co., Ltd.\nSPDX-License-Identifier: MIT\n"
7 | },
8 | "interfaces": [
9 | {
10 | "type": "interface",
11 | "name": "treeland_window_management_v1",
12 | "version": "1",
13 | "description": {
14 | "type": "description",
15 | "text": "This interface manages application windows.\nIt provides requests to show and hide the desktop and emits\nan event every time a window is created so that the client can\nuse it to manage the window.\n\nOnly one client can bind this interface at a time.",
16 | "summary": "application windows management"
17 | },
18 | "requests": [
19 | {
20 | "type": "request",
21 | "name": "set_desktop",
22 | "description": {
23 | "type": "description",
24 | "text": "Tell the compositor to show/hide the desktop.",
25 | "summary": "show/hide the desktop"
26 | },
27 | "args": [
28 | {
29 | "type": "arg",
30 | "name": "state",
31 | "argType": "uint",
32 | "summary": "requested state"
33 | }
34 | ]
35 | },
36 | {
37 | "type": "request",
38 | "name": "destroy",
39 | "requestType": "destructor",
40 | "description": {
41 | "type": "description",
42 | "summary": "destroy the window manager object"
43 | },
44 | "args": []
45 | }
46 | ],
47 | "events": [
48 | {
49 | "type": "event",
50 | "name": "show_desktop",
51 | "description": {
52 | "type": "description",
53 | "text": "This event will be sent whenever the show desktop mode changes. E.g. when it is\nentered\nor left.\n\nOn binding the interface the current state is sent.",
54 | "summary": "notify the client when the show desktop mode is entered/left"
55 | },
56 | "args": [
57 | {
58 | "type": "arg",
59 | "name": "state",
60 | "argType": "uint",
61 | "summary": "new state"
62 | }
63 | ]
64 | }
65 | ],
66 | "enums": [
67 | {
68 | "type": "enum",
69 | "name": "desktop_state",
70 | "bitfield": false,
71 | "entries": [
72 | {
73 | "type": "entry",
74 | "name": "normal",
75 | "value": "0"
76 | },
77 | {
78 | "type": "entry",
79 | "name": "show",
80 | "value": "1"
81 | },
82 | {
83 | "type": "entry",
84 | "name": "preview_show",
85 | "value": "2"
86 | }
87 | ]
88 | }
89 | ]
90 | }
91 | ]
92 | }
93 |
--------------------------------------------------------------------------------
/src/data/protocols/weston-direct-display.json:
--------------------------------------------------------------------------------
1 | {
2 | "type": "protocol",
3 | "name": "weston_direct_display",
4 | "copyright": {
5 | "type": "copyright",
6 | "text": "Copyright © 2019 Collabora Ltd.\n\nPermission is hereby granted, free of charge, to any person obtaining a\ncopy of this software and associated documentation files (the \"Software\"),\nto deal in the Software without restriction, including without limitation\nthe rights to use, copy, modify, merge, publish, distribute, sublicense,\nand/or sell copies of the Software, and to permit persons to whom the\nSoftware is furnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice (including the next\nparagraph) shall be included in all copies or substantial portions of the\nSoftware.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL\nTHE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\nFROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER\nDEALINGS IN THE SOFTWARE."
7 | },
8 | "interfaces": [
9 | {
10 | "type": "interface",
11 | "name": "weston_direct_display_v1",
12 | "version": "1",
13 | "description": {
14 | "type": "description",
15 | "text": "Weston extension to instruct the compositor to avoid any import\nof the dmabuf created by 'linux-dmabuf' protocol other than the display\ncontroller.\n\nCompositors are already going to use direct scan-out as much as possible but\nthere's no assurance that while doing so, they won't first import the dmabuf\nin to the GPU. This extension assures the client that the compositor will\nnever attempt to import in to the GPU and pass it directly to the display\ncontroller.\n\nClients can make use of this extension to pass the dmabuf buffer to the\ndisplay controller, potentially increasing the performance and lowering the\nbandwidth usage.\n\nLastly, clients can make use of this extension in tandem with content-protection\none thus avoiding any GPU interaction and providing a secure-content path.\nAlso, in some cases, the memory where dmabuf are allocated are in specially\ncrafted memory zone which would be seen as an illegal memory access when the\nGPU will attempt to read it.\n\nWARNING: This interface by design might break screenshoting functionality\nas compositing might be involved while doing that. Also, do note, that in\ncase the dmabufer provided can't be imported by KMS, the client connection\nwill be terminated.\n\nWARNING: This extension requires 'linux-dmabuf' protocol and\n'zwp_linux_buffer_params_v1' be already created by 'zwp_linux_buffer_v1'.",
16 | "summary": "weston direct display"
17 | },
18 | "requests": [
19 | {
20 | "type": "request",
21 | "name": "enable",
22 | "description": {
23 | "type": "description",
24 | "text": "This request tells the compositor not to import the dmabuf to the GPU\nin order to bypass it entirely, such that the buffer will be directly\nscanned-out by the display controller. If HW is not capable/or there\naren't any available resources to directly scan-out the buffer, a\nplaceholder should be installed in-place by the compositor. The\ncompositor may perform checks on the dmabuf and refuse to create a\nwl_buffer if the dmabuf seems unusable for being used directly.\n\nAssumes that 'zwp_linux_buffer_params_v1' was already created\nby 'zwp_linux_dmabuf_v1_create_params'.",
25 | "summary": "forward buffer to display controller"
26 | },
27 | "args": [
28 | {
29 | "type": "arg",
30 | "name": "dmabuf",
31 | "argType": "object",
32 | "summary": "enable direct-display for dmabuf buffer",
33 | "interface": "zwp_linux_buffer_params_v1",
34 | "protocol": "linux-dmabuf-v1"
35 | }
36 | ]
37 | },
38 | {
39 | "type": "request",
40 | "name": "destroy",
41 | "requestType": "destructor",
42 | "description": {
43 | "type": "description",
44 | "text": "Destroys the factory object, but does not affect any other objects.",
45 | "summary": "destroy factory object"
46 | },
47 | "args": []
48 | }
49 | ],
50 | "events": [],
51 | "enums": []
52 | }
53 | ]
54 | }
55 |
--------------------------------------------------------------------------------
/src/data/protocols/wlr-input-inhibitor-unstable-v1.json:
--------------------------------------------------------------------------------
1 | {
2 | "type": "protocol",
3 | "name": "wlr_input_inhibit_unstable_v1",
4 | "copyright": {
5 | "type": "copyright",
6 | "text": "Copyright © 2018 Drew DeVault\n\nPermission to use, copy, modify, distribute, and sell this\nsoftware and its documentation for any purpose is hereby granted\nwithout fee, provided that the above copyright notice appear in\nall copies and that both that copyright notice and this permission\nnotice appear in supporting documentation, and that the name of\nthe copyright holders not be used in advertising or publicity\npertaining to distribution of the software without specific,\nwritten prior permission. The copyright holders make no\nrepresentations about the suitability of this software for any\npurpose. It is provided \"as is\" without express or implied\nwarranty.\n\nTHE COPYRIGHT HOLDERS DISCLAIM ALL WARRANTIES WITH REGARD TO THIS\nSOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND\nFITNESS, IN NO EVENT SHALL THE COPYRIGHT HOLDERS BE LIABLE FOR ANY\nSPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES\nWHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN\nAN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,\nARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF\nTHIS SOFTWARE."
7 | },
8 | "interfaces": [
9 | {
10 | "type": "interface",
11 | "name": "zwlr_input_inhibit_manager_v1",
12 | "version": "1",
13 | "description": {
14 | "type": "description",
15 | "text": "Clients can use this interface to prevent input events from being sent to\nany surfaces but its own, which is useful for example in lock screen\nsoftware. It is assumed that access to this interface will be locked down\nto whitelisted clients by the compositor.\n\nNote! This protocol is deprecated and not intended for production use.\nFor screen lockers, use the ext-session-lock-v1 protocol.",
16 | "summary": "inhibits input events to other clients"
17 | },
18 | "requests": [
19 | {
20 | "type": "request",
21 | "name": "get_inhibitor",
22 | "description": {
23 | "type": "description",
24 | "text": "Activates the input inhibitor. As long as the inhibitor is active, the\ncompositor will not send input events to other clients.",
25 | "summary": "inhibit input to other clients"
26 | },
27 | "args": [
28 | {
29 | "type": "arg",
30 | "name": "id",
31 | "argType": "new_id",
32 | "interface": "zwlr_input_inhibitor_v1"
33 | }
34 | ]
35 | }
36 | ],
37 | "events": [],
38 | "enums": [
39 | {
40 | "type": "enum",
41 | "name": "error",
42 | "bitfield": false,
43 | "entries": [
44 | {
45 | "type": "entry",
46 | "name": "already_inhibited",
47 | "value": "0",
48 | "summary": "an input inhibitor is already in use on the compositor"
49 | }
50 | ]
51 | }
52 | ]
53 | },
54 | {
55 | "type": "interface",
56 | "name": "zwlr_input_inhibitor_v1",
57 | "version": "1",
58 | "description": {
59 | "type": "description",
60 | "text": "While this resource exists, input to clients other than the owner of the\ninhibitor resource will not receive input events. Any client which\npreviously had focus will receive a leave event and will not be given\nfocus again. The client that owns this resource will receive all input\nevents normally. The compositor will also disable all of its own input\nprocessing (such as keyboard shortcuts) while the inhibitor is active.\n\nThe compositor may continue to send input events to selected clients,\nsuch as an on-screen keyboard (via the input-method protocol).",
61 | "summary": "inhibits input to other clients"
62 | },
63 | "requests": [
64 | {
65 | "type": "request",
66 | "name": "destroy",
67 | "requestType": "destructor",
68 | "description": {
69 | "type": "description",
70 | "text": "Destroy the inhibitor and allow other clients to receive input.",
71 | "summary": "destroy the input inhibitor object"
72 | },
73 | "args": []
74 | }
75 | ],
76 | "events": [],
77 | "enums": []
78 | }
79 | ]
80 | }
81 |
--------------------------------------------------------------------------------
/src/data/protocols/xdg-system-bell-v1.json:
--------------------------------------------------------------------------------
1 | {
2 | "type": "protocol",
3 | "name": "xdg_system_bell_v1",
4 | "copyright": {
5 | "type": "copyright",
6 | "text": "Copyright © 2016, 2023 Red Hat\n\nPermission is hereby granted, free of charge, to any person obtaining a\ncopy of this software and associated documentation files (the \"Software\"),\nto deal in the Software without restriction, including without limitation\nthe rights to use, copy, modify, merge, publish, distribute, sublicense,\nand/or sell copies of the Software, and to permit persons to whom the\nSoftware is furnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice (including the next\nparagraph) shall be included in all copies or substantial portions of the\nSoftware.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL\nTHE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\nFROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER\nDEALINGS IN THE SOFTWARE."
7 | },
8 | "interfaces": [
9 | {
10 | "type": "interface",
11 | "name": "xdg_system_bell_v1",
12 | "version": "1",
13 | "description": {
14 | "type": "description",
15 | "text": "This global interface enables clients to ring the system bell.\n\nWarning! The protocol described in this file is currently in the testing\nphase. Backward compatible changes may be added together with the\ncorresponding interface version bump. Backward incompatible changes can\nonly be done by creating a new major version of the extension.",
16 | "summary": "system bell"
17 | },
18 | "requests": [
19 | {
20 | "type": "request",
21 | "name": "destroy",
22 | "requestType": "destructor",
23 | "description": {
24 | "type": "description",
25 | "text": "Notify that the object will no longer be used.",
26 | "summary": "destroy the system bell object"
27 | },
28 | "args": []
29 | },
30 | {
31 | "type": "request",
32 | "name": "ring",
33 | "description": {
34 | "type": "description",
35 | "text": "This requests rings the system bell on behalf of a client. How ringing\nthe bell is implemented is up to the compositor. It may be an audible\nsound, a visual feedback of some kind, or any other thing including\nnothing.\n\nThe passed surface should correspond to a toplevel like surface role,\nor be null, meaning the client doesn't have a particular toplevel it\nwants to associate the bell ringing with. See the xdg-shell protocol\nextension for a toplevel like surface role.",
36 | "summary": "ring the system bell"
37 | },
38 | "args": [
39 | {
40 | "type": "arg",
41 | "name": "surface",
42 | "argType": "object",
43 | "summary": "associated surface",
44 | "interface": "wl_surface",
45 | "allowNull": "true",
46 | "protocol": "wayland"
47 | }
48 | ]
49 | }
50 | ],
51 | "events": [],
52 | "enums": []
53 | }
54 | ]
55 | }
56 |
--------------------------------------------------------------------------------
/src/gitlab-api/index.ts:
--------------------------------------------------------------------------------
1 | import {
2 | WaylandElementType,
3 | WaylandProtocol as WaylandProtocolModel,
4 | } from '../model/wayland'
5 | import {
6 | transformXMLElement,
7 | xmlParser,
8 | } from '../lib/xml-protocol-transformers'
9 |
10 | export interface GitLabFile {
11 | name: string
12 | webPath: string
13 | path: string
14 | protocol: WaylandProtocolModel
15 | }
16 |
17 | export interface GitLabMergeRequest {
18 | iid: number
19 | title: string
20 | diffStats: { path: string }[]
21 | diffHeadSha: string
22 | }
23 |
24 | export interface GitLabPaginationInfo {
25 | endCursor: string
26 | hasNextPage: boolean
27 | }
28 |
29 | export interface GetMergeRequestsResponse {
30 | pageInfo: GitLabPaginationInfo
31 | mrs: GitLabMergeRequest[]
32 | }
33 |
34 | async function callGraphQl(query: string): Promise {
35 | const body = JSON.stringify({ query })
36 | return await fetch('https://gitlab.freedesktop.org/api/graphql', {
37 | method: 'post',
38 | body,
39 | headers: new Headers({
40 | 'Content-Type': 'application/json',
41 | 'Content-Length': body.length.toString(),
42 | }),
43 | })
44 | }
45 |
46 | function xml_filter({ path }: { path: string }) {
47 | return path.endsWith('.xml')
48 | }
49 |
50 | export async function getMergeRequestFiles(
51 | mr: GitLabMergeRequest
52 | ): Promise {
53 | const paths = mr.diffStats.map(({ path }) => path)
54 | const response = await callGraphQl(`{
55 | project(fullPath: "wayland/wayland-protocols") {
56 | repository {
57 | blobs(ref: "${mr.diffHeadSha}", paths: ${JSON.stringify(paths)}) {
58 | nodes {
59 | name
60 | webPath
61 | path
62 | rawBlob
63 | }
64 | }
65 | }
66 | }
67 | }`)
68 |
69 | const nodes: {
70 | name: string
71 | webPath: string
72 | path: string
73 | rawBlob: string
74 | }[] = (await response.json()).data.project.repository.blobs.nodes
75 |
76 | return nodes.reduce((out, node) => {
77 | const xmlData = xmlParser.parse(node.rawBlob)
78 | const protocol = transformXMLElement(
79 | xmlData['protocol'],
80 | WaylandElementType.Protocol
81 | )
82 |
83 | if (protocol !== undefined) {
84 | out.push({
85 | name: node.name,
86 | webPath: node.webPath,
87 | path: node.path,
88 | protocol,
89 | })
90 | }
91 |
92 | return out
93 | }, [])
94 | }
95 |
96 | export async function getMergeRequests(
97 | after: string | undefined
98 | ): Promise {
99 | const after_arg = after ? `after: "${after}"` : ''
100 | const response = await callGraphQl(`{
101 | project(fullPath: "wayland/wayland-protocols") {
102 | mergeRequests ( state: opened first: 20 ${after_arg} ) {
103 | pageInfo {
104 | endCursor
105 | hasNextPage
106 | }
107 | nodes {
108 | iid
109 | title
110 | diffHeadSha
111 | diffStats { path }
112 | }
113 | }
114 | }
115 | }`)
116 |
117 | const json = await response.json()
118 | const mergeRequests = json.data.project.mergeRequests
119 | const nodes: GitLabMergeRequest[] = mergeRequests.nodes
120 | const mrs = nodes
121 | .map((node) => {
122 | node.diffStats = node.diffStats.filter(xml_filter)
123 | return node
124 | })
125 | .filter((node) => node.diffStats.length > 0)
126 |
127 | return {
128 | pageInfo: mergeRequests.pageInfo,
129 | mrs,
130 | }
131 | }
132 |
133 | export async function getMergeRequest(
134 | iid: string
135 | ): Promise {
136 | const response = await callGraphQl(`{
137 | project(fullPath: "wayland/wayland-protocols") {
138 | mergeRequest ( iid: "${iid}" ) {
139 | iid
140 | title
141 | diffHeadSha
142 | diffStats { path }
143 | }
144 | }
145 | }`)
146 |
147 | const raw_json = await response.json()
148 | const mergeRequest: GitLabMergeRequest = raw_json.data.project.mergeRequest
149 | mergeRequest.diffStats = mergeRequest.diffStats.filter(xml_filter)
150 | return mergeRequest
151 | }
152 |
--------------------------------------------------------------------------------
/src/index.css:
--------------------------------------------------------------------------------
1 | @tailwind base;
2 | @tailwind components;
3 | @tailwind utilities;
4 |
--------------------------------------------------------------------------------
/src/index.tsx:
--------------------------------------------------------------------------------
1 | import React from 'react'
2 | import { hydrate, render } from 'react-dom'
3 | import '@vscode/codicons/dist/codicon.css'
4 | import { Router } from 'wouter'
5 | import { setupAnalytics } from './analytics/plausible'
6 | import App from './App'
7 | import './index.css'
8 | import reportWebVitals from './reportWebVitals'
9 |
10 | setupAnalytics()
11 |
12 | const hydrateOrRender = process.env.NODE_ENV === 'production' ? hydrate : render
13 |
14 | hydrateOrRender(
15 |
16 |
17 |
18 |
19 | ,
20 | document.getElementById('root')
21 | )
22 |
23 | // If you want to start measuring performance in your app, pass a function
24 | // to log results (for example: reportWebVitals(console.log))
25 | // or send to an analytics endpoint. Learn more: https://bit.ly/CRA-vitals
26 | reportWebVitals()
27 |
--------------------------------------------------------------------------------
/src/logo.svg:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/src/model/wayland-protocol-metadata.ts:
--------------------------------------------------------------------------------
1 | export enum WaylandProtocolStability {
2 | Stable = 'stable',
3 | Staging = 'staging',
4 | Unstable = 'unstable',
5 | }
6 |
7 | export enum WaylandProtocolSource {
8 | WaylandCore = 'core',
9 | WaylandProtocols = 'wayland-protocols',
10 | WlrProtocols = 'wlr-protocols',
11 | KDEProtocols = 'kde-protocols',
12 | HyprlandProtocols = 'hyprland-protocols',
13 | CosmicProtocols = 'cosmic-protocols',
14 | WestonProtocols = 'weston-protocols',
15 | TreelandProtocols ='treeland-protocols',
16 | External = 'external',
17 | }
18 |
19 | export interface WaylandDeprecationItem {
20 | name: string
21 | reason: string
22 | }
23 |
24 | export interface WaylandProtocolMetadata {
25 | id: string
26 | name: string
27 | source: WaylandProtocolSource
28 | stability: WaylandProtocolStability
29 | externalUrl?: string
30 | deprecated?: WaylandDeprecationItem[]
31 | }
32 |
--------------------------------------------------------------------------------
/src/model/wayland.ts:
--------------------------------------------------------------------------------
1 | export enum WaylandElementType {
2 | Protocol = 'protocol',
3 | Copyright = 'copyright',
4 | Interface = 'interface',
5 | Request = 'request',
6 | Event = 'event',
7 | Enum = 'enum',
8 | Entry = 'entry',
9 | Arg = 'arg',
10 | Description = 'description',
11 | }
12 |
13 | export interface WaylandProtocol {
14 | type: WaylandElementType.Protocol
15 | name: string
16 | copyright?: WaylandCopyright
17 | description?: WaylandDescription
18 | interfaces: WaylandInterface[]
19 | }
20 |
21 | export interface WaylandCopyright {
22 | type: WaylandElementType.Copyright
23 | text: string
24 | }
25 |
26 | export interface WaylandDescription {
27 | type: WaylandElementType.Description
28 | text: string
29 | summary?: string
30 | }
31 |
32 | export interface WaylandInterface {
33 | type: WaylandElementType.Interface
34 | name: string
35 | version: string
36 | description?: WaylandDescription
37 | requests?: WaylandRequest[]
38 | events?: WaylandEvent[]
39 | enums?: WaylandEnum[]
40 | }
41 |
42 | export interface WaylandRequest {
43 | type: WaylandElementType.Request
44 | name: string
45 | requestType?: string
46 | since?: string
47 | deprecatedSince?: string
48 | description?: WaylandDescription
49 | args: WaylandArg[]
50 | }
51 |
52 | export interface WaylandEvent {
53 | type: WaylandElementType.Event
54 | name: string
55 | eventType?: string
56 | since?: string
57 | deprecatedSince?: string
58 | description?: WaylandDescription
59 | args: WaylandArg[]
60 | }
61 |
62 | export interface WaylandEnum {
63 | type: WaylandElementType.Enum
64 | name: string
65 | since?: string
66 | bitfield?: boolean
67 | description?: WaylandDescription
68 | entries?: WaylandEntry[]
69 | }
70 |
71 | export interface WaylandEntry {
72 | type: WaylandElementType.Entry
73 | name: string
74 | value: string
75 | summary?: string
76 | since?: string
77 | deprecatedSince?: string
78 | description?: WaylandDescription
79 | }
80 |
81 | export interface WaylandArg {
82 | type: WaylandElementType.Arg
83 | name: string
84 | argType: WaylandArgType
85 | summary?: string
86 | interface?: string
87 | allowNull?: boolean
88 | enum?: string
89 | description?: WaylandDescription
90 | // Only set when different from current protocol, used for linking cross-protocol argument types
91 | protocol?: string
92 | }
93 |
94 | export enum WaylandArgType {
95 | NewId = 'new_id',
96 | Int = 'int',
97 | UInt = 'uint',
98 | FD = 'fd',
99 | String = 'string',
100 | Object = 'object',
101 | }
102 |
103 | export type WaylandElement =
104 | | WaylandProtocol
105 | | WaylandCopyright
106 | | WaylandDescription
107 | | WaylandInterface
108 | | WaylandRequest
109 | | WaylandEvent
110 | | WaylandEnum
111 | | WaylandEntry
112 | | WaylandArg
113 |
114 | export const isWaylandArgElement = (
115 | element: WaylandElement
116 | ): element is WaylandArg => element.type === WaylandElementType.Arg
117 |
118 | export const isWaylandEntryElement = (
119 | element: WaylandElement
120 | ): element is WaylandEntry => element.type === WaylandElementType.Entry
121 |
122 | export const isWaylandEnumElement = (
123 | element: WaylandElement
124 | ): element is WaylandEnum => element.type === WaylandElementType.Enum
125 |
--------------------------------------------------------------------------------
/src/pages/404.tsx:
--------------------------------------------------------------------------------
1 | import { Link } from 'wouter'
2 | import { usePageTitle } from '../components/common/hooks-utils'
3 |
4 | export const NotFound: React.FC = () => {
5 | usePageTitle('404 - Page not found')
6 |
7 | return (
8 |
9 |
10 | 404 - Page not found
11 |
12 |
13 |
14 | Return to homepage
15 |
16 |
17 |
18 | )
19 | }
20 |
--------------------------------------------------------------------------------
/src/react-app-env.d.ts:
--------------------------------------------------------------------------------
1 | ///
2 |
--------------------------------------------------------------------------------
/src/reportWebVitals.ts:
--------------------------------------------------------------------------------
1 | import { ReportHandler } from 'web-vitals'
2 |
3 | const reportWebVitals = (onPerfEntry?: ReportHandler) => {
4 | if (onPerfEntry && onPerfEntry instanceof Function) {
5 | import('web-vitals').then(
6 | ({ getCLS, getFID, getFCP, getLCP, getTTFB }) => {
7 | getCLS(onPerfEntry)
8 | getFID(onPerfEntry)
9 | getFCP(onPerfEntry)
10 | getLCP(onPerfEntry)
11 | getTTFB(onPerfEntry)
12 | }
13 | )
14 | }
15 | }
16 |
17 | export default reportWebVitals
18 |
--------------------------------------------------------------------------------
/src/setupTests.ts:
--------------------------------------------------------------------------------
1 | // jest-dom adds custom jest matchers for asserting on DOM nodes.
2 | // allows you to do things like:
3 | // expect(element).toHaveTextContent(/react/i)
4 | // learn more: https://github.com/testing-library/jest-dom
5 | import '@testing-library/jest-dom'
6 |
--------------------------------------------------------------------------------
/tailwind.config.js:
--------------------------------------------------------------------------------
1 | const colors = require('tailwindcss/colors')
2 | const defaultTheme = require('tailwindcss/defaultTheme')
3 |
4 | module.exports = {
5 | content: ['./src/**/*.{js,jsx,ts,tsx}', './public/index.html'],
6 | theme: {
7 | extend: {
8 | colors: { gray: colors.zinc },
9 | },
10 | fontFamily: {
11 | sans: ['Inter var', ...defaultTheme.fontFamily.sans],
12 | serif: [...defaultTheme.fontFamily.serif],
13 | mono: [...defaultTheme.fontFamily.mono],
14 | },
15 | },
16 | plugins: [require('tailwind-scrollbar')],
17 | }
18 |
--------------------------------------------------------------------------------
/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "compilerOptions": {
3 | "target": "es5",
4 | "lib": ["dom", "dom.iterable", "esnext"],
5 | "allowJs": true,
6 | "skipLibCheck": true,
7 | "esModuleInterop": true,
8 | "allowSyntheticDefaultImports": true,
9 | "strict": true,
10 | "forceConsistentCasingInFileNames": true,
11 | "noFallthroughCasesInSwitch": true,
12 | "module": "esnext",
13 | "moduleResolution": "node",
14 | "resolveJsonModule": true,
15 | "isolatedModules": true,
16 | "noEmit": true,
17 | "jsx": "react-jsx"
18 | },
19 | "include": ["src"]
20 | }
21 |
--------------------------------------------------------------------------------
/tsconfig.scripts.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": "./tsconfig.json",
3 | "compilerOptions": {
4 | "composite": true,
5 | "module": "CommonJS",
6 | "lib": ["es2019", "DOM"]
7 | },
8 | "include": ["src", "scripts"]
9 | }
10 |
--------------------------------------------------------------------------------