3025 shaares
i3ipc-python is a library for controlling i3 window manager and sway. i3 users can use this library to create their own plugin scripts to customize their desktop or integrate i3 into other applications. With this library, you can query the state of the window manager, listen to events, and send commands to i3 to perform window manager actions such as focusing or closing windows.
The main entry point into the features of the library is the Connection class. This class manages a Unix socket connection to the ipc interface exposed by the window manager. By default, the Connection will attempt to connect to the running instance of i3 by using information present in the environment or the running X11 display.