[HN Gopher] Rubywm: An X11 window manager in pure Ruby
       ___________________________________________________________________
        
       Rubywm: An X11 window manager in pure Ruby
        
       Author : Kerrick
       Score  : 147 points
       Date   : 2025-01-31 03:51 UTC (1 days ago)
        
 (HTM) web link (github.com)
 (TXT) w3m dump (github.com)
        
       | nucleogenesis wrote:
       | This looks rad - I'm getting grumpy at i3 so I'd love to replace
       | it.
       | 
       | Have you used it with multiple monitors by chance?
       | 
       | Thanks for sharing!
        
         | hulitu wrote:
         | tl;dr "It currently does not do anything to facilitate working
         | on multiple monitors, as in my current setup I'm only using a
         | single monitor for my Linux machine."
        
           | vidarh wrote:
           | I'm the author, and that's still true. I'd be open to
           | addressing it, but it's not currently a priority for me to
           | work on. I'm moving soon - if my new office gives me space
           | for a second monitor that may change ;)
        
             | nucleogenesis wrote:
             | Two monitor life is a good life but it's the part of my i3
             | config that's most annoying. I guess idk exactly what I
             | want but I know I don't want to fiddle and fight with my i3
             | config lol
        
         | gazunklenut wrote:
         | https://wiki.archlinux.org/title/Comparison_of_tiling_window...
         | 
         | You're spoilt for choice really...
        
           | talldayo wrote:
           | Just as good a time as any to give Sway a try.
        
             | nucleogenesis wrote:
             | Wayland bugs out on my machine so it's X11 for life (or at
             | least maybe until I get a different GPU or something idk).
             | 
             | But isn't sway a drop in replacement for i3? Or does it
             | make life easier with some additional functionality or
             | features?
        
           | nucleogenesis wrote:
           | Spoilt for the choice of which wm I want to invest a bunch of
           | time figuring out.
           | 
           | Thanks for the link in any case, I just gotta spend some time
           | one of these weekends getting whatever I end up using working
           | smoothly
        
         | neilv wrote:
         | If you want tiling, but i3 requires too much manual work, you
         | might like the more managed layouts that are the default in
         | XMonad: https://xmonad.org/
         | 
         | XMonad works fine with multiple monitors. Each monitor displays
         | one of the many virtual desktops. The normal keys for desktops
         | and for windows work pretty intuitively with multiple monitors.
        
           | marxisttemp wrote:
           | Or start from the start and give dwm a try.
        
         | somat wrote:
         | I am not sure what you want out of I3, but if it is "i3
         | configuration is too complicated" might I suggest spectrwm. I
         | like it because it hits that sweet spot for a tilling WM
         | between "more configurable than dwm" and "less configurable
         | than i3"
         | 
         | https://github.com/conformal/spectrwm
         | 
         | Plus I find it handles multiple monitors well.
        
           | nucleogenesis wrote:
           | Much appreciated, I'll give it a look
        
         | vidarh wrote:
         | I'm the author, and beware that it's still very much "raw".
         | It's extremely minimalist, and I've not even tried to make it
         | feature-complete, that includes not even testing on multiple
         | monitors.
         | 
         | It _is_ the wm I use daily, but I also know where to look if it
         | crashes or otherwise misbehaves.
         | 
         | It definitely has bugs - there's something Chrome does when the
         | file open dialog window opens that makes it sometimes fail to
         | refresh unless I resize it that I haven't bothered tracking
         | down, for example.
        
           | vidarh wrote:
           | Also to add that personally, I moved from i3 to bspwm first,
           | and you might be happier with bspwm than mine in its current
           | state (but thoughtful PR's are welcome)
           | 
           | I had basically two motivations to write my own: 1) because I
           | could, 2) because bspwm - at least at the time had a couple
           | of quirks I disliked: a) if I ran a file manager, it'd open
           | on all the desktops, b) it took a hack that wasn't very
           | satisfying to get one desktop to be floating while the others
           | were tiled. Those were minor, and so if I hadn't already been
           | working on extending X11 bindings for Ruby for my other Ruby
           | projects I probably would've stayed on bspwm, but since my
           | usage was also very simple, I figured I'd see how long I'd
           | last, and I got close enough within a few days to decide it
           | was viable to keep using my own instead of trying to fix
           | bspwm.
           | 
           | My tolerance level for weird quirks _that I 'm in control of_
           | is very high, though. It feels very different when its your
           | own bugs :)
        
             | nucleogenesis wrote:
             | > My tolerance level for weird quirks that I'm in control
             | of is very high, though.
             | 
             | Likewise for me and the idea that I could hack at it in
             | Ruby is making trying it out very tempting. If I test it on
             | multiple monitors I'll let ya know if it works and if it
             | doesn't I might try to find time on the weekends to work it
             | out and submit a patch.
             | 
             | I'm basically committed to not using Wayland so it wouldn't
             | hurt me to learn more about how X11 actually works lol.
             | 
             | Thanks for your thorough and thoughtful reply!
        
         | lupusreal wrote:
         | Have you tried awesomewm? Tbh I never really understood why i3
         | is so popular and few people seem to mention awesome.
        
           | nucleogenesis wrote:
           | I first tried awesomewm the last time I wiped and reinstalled
           | a new Linux and it crashed my X session. I gave it an hour or
           | so and reluctantly went back to i3. Maybe I should give it
           | another look :)
        
       | vidarh wrote:
       | I'm the author. This was discussed on HN a year ago too:
       | 
       | https://news.ycombinator.com/item?id=39087609
       | 
       | Note that the warnings still apply. I have used it continuously
       | since, and there are a few bugs here and there but it mostly
       | works _for my use_ which is very basic, and does e.g. not involve
       | more than a single monitor.
        
       | Alifatisk wrote:
       | What a unexpected yet exciting project
        
         | vidarh wrote:
         | Most of my Ruby use is unexpected ;) I don't like Rails, and
         | while I do lots of web dev in Ruby, I think line for line I've
         | written more non-web related Ruby code than web apps.
         | 
         | If you like it, note the X binding is also pure Ruby. Though
         | incomplete it covers most of the important stuff, including
         | enough of XRender to let my (pure Ruby, but translated from a C
         | project) font renderer use it (not used by the wm, but used by
         | my terminal; I really need to clean up the terminal enough to
         | be comfortable pushing the current version of to Github)
        
       | Toutouxc wrote:
       | I know very little about window managers, but I know a bit about
       | Ruby, so... Does this have any performance implications?
        
         | vidarh wrote:
         | Nothing noticeable. X11 wm's receive high-level events, such as
         | windows opening, closing etc., they're not in-band for anything
         | computationally heavy unlike e.g. Wayland compositors.
        
       | amelius wrote:
       | Build your own window manager in Python:
       | 
       | https://monroeclinton.com/build-your-own-window-manager/
       | 
       | By the way, it is much easier to develop and test these things
       | using VNC, so running an X server in a separate window.
        
         | kevin_thibedeau wrote:
         | You can just use Xephyr or Xnest.
        
       | IshKebab wrote:
       | Diabolical.
        
       | bsnnkv wrote:
       | I love seeing tiling window managers in unexpected languages as
       | someone who is mostly know for maintaining a twm!
       | 
       | I recently also became aware of a tiling window manager written
       | in Janet which I'm sure will be a hit with Emacs and lisp
       | fans![1]
       | 
       | [1]: https://agentkilo.itch.io/jwno/devlog/871672/scroll-jwno-
       | scr...
        
         | tmtvl wrote:
         | I think Emacs and Lisp fans will prefer EXWM or Stumpwm.
         | Although I am an Emacs and Lisp fan, but I don't like tiling
         | window managers so I use Awesome with all tags set to floating.
        
           | eadmund wrote:
           | StumpWM supports both tiling _and_ stacking windows. The
           | latter are not great, but good enough when needed.
        
       | RomanPushkin wrote:
       | X11 Ruby manager choices are contributing disproportionately to
       | climate change
        
         | RomanPushkin wrote:
         | it was sarcasm
        
       ___________________________________________________________________
       (page generated 2025-02-01 08:01 UTC)