parasurv@webspace ~ $

Blog: [Site updates] [Linux] [Free Software] [Culture] [Health] [Watches] Learning: [Emacs Journal] [Linux Wiki] Personal: [Contact] [About me]

Shorts: [Microblog] [Linkblog] Important: [Read] [Watch] [Listen] Other pages: [Old games stuff]

Window manager independent swallowing and other things

Date: 2020-06-21

I love dwm right now, but I had one patch that I want so badly, yet I couldn't apply. I tried different versions, nothing could make it work. It's the swallow patch, that Luke Smith made popular on youtube.

However I accidently found a solution, not even searching for one, on reddit.

I tried this version, and it works well.

It called swallow, because when you start a video from terminal (with the command devour), it basically swallows your terminal in place of the video. Normally it would just open up the video window beside the terminal video, which can make things crowded if you are using a tiling window manager.

After installing it, I made a bash alias for it, so far only for mpv, video player and sxiv image viewer. It works fast.

EDIT: it looks like even DistroTube talked about swallowing windows very recently (I put up this post after midnight, and saw this video only in the morning) and he talks about the same program I discovered too!

I also finally made scrot work, so I can now take screenshots. I added this to my config.h file:

{ 0,                       XK_Print, spawn,          SHCMD("exec scrot -q 100 '%Y-%m-%d-%H-%M-%S.png' -e 'mv $f $m ~/Screenshots/'") },

With this I can take a fullscreen shot and move it to my Screenshots directory in HOME. If you don't use dwm, you can still copy the command (without exec).

And I could apply another dwm patch, which adds a master window right in the center of my screen, it also has a floating version. Both can be useful for different stuff. I experimented watching twitch in mpv and using chat with irssi.

I also switched to left windows key as my modkey, instead of alt. In this way I can use shortcuts I couldn't before, like mod+x, because alt+x is used in Emacs. For a while I could make right control as windows key work, but for some reason I frakked it up, and now it's gone. I used setxkbmap, but now it doesn't work, and I don't know why.

This is day 32 for #100DaysToOffload, where we write about different things on our personal blogs. Join the project or just read the blogs (we have RSS and coookiez!).

Hosted on Neocities and created with Emacs, the world best text editor, operating system. This website doesn't track you. I don't use any javascript or other scripts. I don't store any information about the visitors. It's just pure old fashioned HTML. Some parts of the site is not up-to-date design wise. I may or may not update them in the future. I don't really support mobile stuff, but I bet if you disable the little CSS I have, you can read the site perfectly.