| protocols | everything! | |
| src | Remove duplicate line | |
| t | everything! | |
| mtwm.asd | asd: following River's lead, let's make codeberg the canonical forge | |
| README.org | Add link to cl-xkbcommon dependency | |
mtwm
A(n attempt at a) Wayland window manager in Common Lisp, for the River compositor.
Don't get too excited yet, because:
Status
Hugely work-in-progress and not really worth looking at right now. It connects to River but doesn't do anything other than that yet. But SoonTM, hopefully.
"mtwm" is just the working name for this project until I come up with a better one. Especially if it's tree-related, in tribute to StumpWM.
Usage
Setting up mtwm
Before you can start mtwm, you will need to ensure its dependencies are installed:
- SBCL (mtwm has not yet been tested on any other Lisp implementation)
- River (obviously)
- asdf-generated-system
- cl-wayland-client
- xkbcommon
Since asdf-generated-system and cl-wayland-client are not available on Quicklisp (yet?), you will need to manually clone their repos into your Quicklisp local-projects directory. The other Lisp systems that mtwm requires will be installed automatically if you have Quicklisp installed and set up.
Starting mtwm
To start mtwm:
-
Start River:
WAYLAND_DEBUG=1 river -log-level debug - Start your Lisp.
-
Load the mtwm ASDF system:
(ql:quickload 'mtwm) - Run
(mtwm:main). - Be amazed that nothing notable happens, other than the following output that tells you that mtwm has connected to River:
Connecting to Wayland... Connected! Entering event loop... New seat Manage start Render start
Generating the protocol bindings
You probably won't need to generate the River protocol bindings yourself, since this has already been done, the results of which are included in this repository, in src/protocols. They are loaded and used automatically when you load and run mtwm.
However, if you do need to (re)generate the Common Lisp bindings for River's protocols, the procedure is:
- Clone mtwm to your Quicklisp local-projects directory (if you haven't already).
- Clone cl-wayland-client to your Quicklisp local-projects directory.
-
From inside the
mtwmdirectory, start SBCL, loading the generate-bindings.lisp script and running itsgeneratefunction:sbcl --load 'src/scripts/generate-bindings.lisp' --eval '(mtwm/generator:generate)' --quit
Future
Things to be done in the future.
- generate-bindings.lisp: use
asdf:performoncom.andrewsoutar.cl-wayland-client.generatorto generate the bindings, rather than callinggenerate-from-xml(it's an internal symbol, so we probably shouldn't be touching it).
Community
mtwm's repository is hosted both on codeberg and github. There is a Matrix room (#mtwm:struct.ws) and an IRC channel (#mtwm on irc.libera.chat) (with a bridge between them).
Please feel free to help in any way you want and are able to. Suggestions, feature requests, bug reports, documentation, and pull requests are all welcome. Assistance is definitely appreciated since I'm not (yet) very familiar with Wayland, nor even with using SBCL's foreign function interface.
Similar
Other projects that are similar, related, or relevant to mtwm.
River
The Wayland compositor that mtwm is built upon. River does the compositing; mtwm defines the window management, keybindings, etc.
StumpWM
The Common Lisp window manager for X. My window manager of choice, and one that I will be taking a lot of inspiration from for this project.
Mahogany
A wlroots-based Wayland compositor and window manager written in Common Lisp. A very cool project that I'm keeping an eye on, and may end up deciding to use instead of mtwm in the future. But the idea of separating the compositor and window manager as River does seems like it will significantly reduce the amount of work needed to create a CL-based Wayland desktop, and thus may be worth doing. Hence mtwm.
Ulubis
A (now defunct?) attempt at a Wayland compositor in Common Lisp. Unfortunately, there has been no development activity in over 6 years.
SDB
The StumpWM debugger; a (Mc)CLIM-based graphical debugger for StumpWM. I didn't have much luck with it, so I ended up removing it from my StumpWM config, but it's a cool project, and maybe could be retrofit into mtwm and/or Mahogany in the future.