Running Qtile as a Wayland Compositor
Some functionality may not yet be implemented in the Wayland compositor. Please see the Wayland To Do List discussion for the current state of development. Also checkout the unresolved Wayland-specific issues and troubleshooting for tips on how to debug Wayland problems.
Note
We currently support wlroots>=0.17.0,<0.18.0 and pywlroots>=0.17.0,<0.18.0.
Backend-Specific Configuration
If you want your config file to work with different backends but want some options set differently per backend, you can check the name of the current backend in your config as follows:
from libqtile import qtile
if qtile.core.name == "x11":
term = "urxvt"
elif qtile.core.name == "wayland":
term = "foot"
Running X11-Only Programs
Qtile supports XWayland but requires that wlroots and pywlroots were built with XWayland support, and that XWayland is installed on the system from startup. XWayland will be started the first time it is needed.
XWayland windows sometimes don't receive mouse events
There is currently a known bug (https://github.com/qtile/qtile/issues/3675) which causes pointer events (hover/click/scroll) to propagate to the wrong window when switching focus.
Input Device Configuration
InputConfig
- class libqtile.backend.wayland.InputConfig(**config: Any)[source]
This is used to configure input devices. An instance of this class represents one set of settings that can be applied to an input device.
To use this, define a dictionary called
wl_input_rules
in your config. The keys are used to match input devices, and the values are instances of this class with the desired settings. For example:from libqtile.backend.wayland import InputConfig wl_input_rules = { "1267:12377:ELAN1300:00 04F3:3059 Touchpad": InputConfig(left_handed=True), "*": InputConfig(left_handed=True, pointer_accel=True), "type:keyboard": InputConfig(kb_options="ctrl:nocaps,compose:ralt"), }
When a input device is being configured, the most specific matching key in the dictionary is found and the corresponding settings are used to configure the device. Unique identifiers are chosen first, then
"type:X"
, then"*"
.The command
qtile cmd-obj -o core -f get_inputs
can be used to get information about connected devices, including their identifiers.Options default to
None
, leave a device's default settings intact. For information on what each option does, see the documenation for libinput: https://wayland.freedesktop.org/libinput/doc/latest/configuration.html. Note that devices often only support a subset of settings.This tries to mirror how Sway configures libinput devices. For more information check out sway-input(5): https://man.archlinux.org/man/sway-input.5#LIBINPUT_CONFIGURATION
Keyboards, managed by xkbcommon, are configured with the options prefixed by
kb_
. X11's helpful XKB guide may be useful for figuring out the syntax for some of these settings.Configuration options
key
default
description
accel_profile
None
'adaptive'
or'flat'
click_method
None
'none'
,'button_areas'
or'clickfinger'
drag
None
True
orFalse
drag_lock
None
True
orFalse
dwt
None
True or False
kb_layout
None
Keyboard layout i.e.
XKB_DEFAULT_LAYOUT
kb_options
None
Keyboard options i.e.
XKB_DEFAULT_OPTIONS
kb_repeat_delay
600
Keyboard delay in milliseconds before repeating
kb_repeat_rate
25
Keyboard key repeats made per second
kb_variant
None
Keyboard variant i.e.
XKB_DEFAULT_VARIANT
left_handed
None
True
orFalse
middle_emulation
None
True
orFalse
natural_scroll
None
True
orFalse
pointer_accel
None
A
float
between -1 and 1.scroll_button
None
'disable'
, 'Button[1-3,8,9]' or a keycodescroll_method
None
'none'
,'two_finger'
,'edge'
, or'on_button_down'
tap
None
True
orFalse
tap_button_map
None
'lrm'
or'lmr'
If you want to change keyboard configuration during runtime, you can use the core's set_keymap command (see below).
Core Commands
See the Wayland backend section in the API Commands documentation.