Hacker News new | past | comments | ask | show | jobs | submit login
Show HN: Xlambda – A window manager extensible in Guile (github.com/kori)
67 points by lmilon on June 30, 2019 | hide | past | favorite | 22 comments



Related projects to look at for ideas, and a handhelds opportunity...

Scwm is an old but interesting X window manager using Scheme: https://en.wikipedia.org/wiki/Scwm

Rwind is a more recent related project, in Racket (a big Scheme variant), and probably needs a developer to build higher-level features: https://pkgs.racket-lang.org/package/rwind

Although it's in Haskell rather than a Scheme, Xmonad has been solid as a daily driver, and presumably is worth looking at for a relatively modern WM implementation (compared to trying to figure out the whats and whys of how Fvwm works): https://en.wikipedia.org/wiki/Xmonad

Also the popular tiling window manager i3, and how its Wayland drop-in, Sway, work: https://en.wikipedia.org/wiki/I3_(window_manager)

If you make a Guile-based WM that does a good job of smartphone-like one-app-displayed-at-a-time window management (like the old Matchbox WM did), with status bar and popup keyboard, then I would like to use it on GNU/Linux handhelds, and might be tempted to switch the entire project from Racket to Guile: https://www.neilvandyke.org/postmarketos/


Yeah, I've seen scwm, I figured it was too old to try and adapt for today.

I haven't heard of Rwind! I used Racket mainly, before this, so it's definitely interesting to me. I'll definitely look into that.

Xmonad is one of my favorite projects and Xlambda is a reference to its name :D

I usually use one-app-at-a-time window management, so I'll want to make sure that sort of setup is very comfortable.

Also, wow! Your project of combining PostmarketOS and Racket is amazing!

A reason why I didn't use Racket for Xlambda is because the FFI wasn't as easy to figure out as Guile's was. Otherwise, I would have gone with Racket.


If you can do Xlambda with Guile, that's probably preferable to doing it with Racket, for purposes such as getting it into GNU/Linux distros. This is exactly one of the kinds of purposes for which Guile was intended. I'm also very happy to see the recent energy put into Guile, including your project.


Ideally it would be amazing to have Xlambda be a good fit for GuixSD, as I really like that project.

Also, same! Guile (and Scheme, in general) are growing in popularity a lot and it makes me really happy.


There's also https://stumpwm.github.io/ , based on SBCL if you're into that.


FYI: Footwm is my little window manager written in Chez scheme. It draws one window at a time and supports EWMH status bars like tint2. https://github.com/akce/footwm-chez


Wouldn't hurt to have a demo video. How easy is this to actually use as a WM, and is it any different to say EXWM?


I'll record a demo this week! I wouldn't recommend trying it as a standalone window manager right now. Maybe by V3 it should be usable. I don't know much about EXWM, but I would guess the fact it uses Guile affords different powers than using Elisp.


Honest question: is there a major difference? I thought they were just dialects of lisp (guile is technically scheme, but isn't scheme just a descendant of lisp?)? I figured they might have slightly different syntax and that's it.


There are differences in how you'd use them. Scheme is very focused on a minimal core and extension through macros and similar constructs, whereas, as far as I know (nb: I don't use emacs) Elisp has a lot of pre-built constructs that are used far more.

Also, Guile being the implementation chosen is not incidental, the GNU project is moving towards Guile as an extension language everywhere (The big example here would be GuixSD).


I'd say that since the readme says this is an experimental WM to understand what's needed for a WM the point of the UX is moot, at the moment.

This doesn't seem like a user-oriented thing.


It definitely is user-oriented! I'm dogfooding this as I develop it, so I'm trying to make it as comfortable as possible.

It is very "experimental" right now because it's such an early release, but that should change as time goes on.


I stand corrected. That's great to hear!


You might be interested in a similar project from a (quite) long time ago: Not A Window Manager

  http://web.mit.edu/nawm/www/


Why did you not use guile-wm https://github.com/mwitmer/guile-wm?

I love the idea of a wm calculus I hope that it comes to life somehow.

What I can recommend you to look at, not sure it is very on-topic, is related to layouting is cassowary and constraint-based layout systems, autolayout is one of them, along the browser layout engine like css grid and flexbox.

A question to finish: what do you think of https://github.com/paperwm/PaperWM?


I wrote about why I didn't go with guile-wm here: https://lobste.rs/s/ssl8wx/xlambda_v1_released_window_manage...

Reproduced below: I actually have a pretty good reason for doing so, libwm already had most of the functionality I needed (I had used wmutils in the past, and that’s where I got most of my ideas for this project. (You can see the end result of me modifying the basic wmutils scripts here: https://github.com/kori/wm), and it was small enough that extending it with Guile would be the fastest way to get a working prototype, and it would help me learn about how to use its FFI, which is actually very important, too, because I plan to integrate Guile with other software I use!

I'll definitely look into all kinds of layouts. I think it's important to be as flexible as possible, when it comes to a window manager.

PaperWM seems nice, I like the idea of a scrollable window manager, I think it's a great idea for touchscreens, not so much for the standard keyboard+mouse combo, though.


Since X is now officially deprecated, we're gonna need a Wayland compositor version of this.


The moment I come across a well-behaved Wayland version of Xmonad, I'll switch personal systems from Xmonad/Xorg and work systems from Unity/default Ubuntu (Wayland-based) to it. They are very, very powerful tools (Lisp/Scheme/Haskell based WMs).



>X is now officially deprecated

Can you provide a source on this? I can’t seem to find it with a cursory DDG search.


https://www.phoronix.com/scan.php?page=news_item&px=X.Org-Ma...

(I don't know if it's officially deprecated, but here's a related article)


That’s very interesting. I wonder if the community will pick up the slack when Red Hat stops supporting X, or if they’ll all move in favor of Wayland. I would expect a split between the two at first, with a slow transition to mostly Wayland as it gets optimized to run well on older hardware.




Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: