In case you don't understand the problem here, an emacs instance can be split into multiple "windows" and there are emacs key bindings to create and destroy these windows, move the "focus" from one window to another, resize the windows, etc. For many of us, this was our introduction to a tiling window manager experience before we'd ever heard of tiling window managers.
When we switched to using a tiling window manager for all our windows, we ran into a muscle memory problem. We were used to jumping between emacs windows/buffers using C-x o and C-x b and then without thinking about it we'd try and use the same keys to jump between i3/sway windows and of course it doesn't work. Or vice versa, trying to use i3/sway shortcuts to switch emacs windows/buffers.
To try and solve this problem I've been using less emacs windows and more i3/sway windows, so I can just use i3/sway keybindings everywhere, but emacs puts up some resistance to that. I like this approach
Ooo this is nice. I may have to try to get this working with my personal setup using Emacs and Sway.
My long term vision is to make an Emacs implementation that is compatible only in philosophy. It would use Guile instead of Elisp, default to bindings that are more familiar to people coming from more modern systems, and would be built from the beginning with concurrency and graphics in mind. For now it remains a dream though.
I have to mainly drive Windows 11 for work reasons so I use komorebi for a tiling window manager (highly recommended btw). I bet the ideas in this post can be applied in that environment too, gotta try it now, great idea
Unrelated, but me and Gemini just invented "C-x 4" for multiscreens.
(defun my-external-readonly-split ()
"Open the current file in an external xfce4-terminal as read-only."
(interactive)
(if buffer-file-name
(start-process "xfce-terminal-split" nil
"xfce4-terminal" "-x" "emacs" "-nw"
"--eval" "(find-file-read-only (pop command-line-args-left))"
buffer-file-name)
(message "Current buffer is not visiting a file!")))
(global-set-key (kbd "C-x 4") 'my-external-readonly-split)I've started using ewm to get this kind of unification between emacs window management and non-emacs window management.
I did the same integration with an Erlang daemon. All relevant key presses are sent to it and based on the current focused application the daemon does different things. I built an Erlang library i3_IPC to listen for events and send commands to Sway.
I just use super(win key)/hyper (bound to capslock) for i3-related commands and leave emacs to its own devices with normal binds
Ah no video it action??
Very interesting though. I don’t always read entire posts on blogs but this one I did. Lisp looks really interesting.
Unrelated to the content of the article, but I absolutely hate the lack of capitalisation.
Side note: I am really enjoying HN today with the set of stories with personal hacks like this i3-emacs integration, someone's desk setup, someone's writer-deck laptop install, the kinda hilarious but also hecka geeky thermal ttrpg thingamabob, and the 16 byte wake up demo. Fun geeky stuff that isn't AI,and I love AI, but it ain't everything.