 Emacs, it's more than a text editor, right? It's its own environment unto itself. You can actually log in to Emacs and use it as a window manager. All you need to do is install the exwm plugin. Exwm stands for the Emacs exwm manager. Once you have that particular plugin installed, you know, just create a exsessions file where the executable executes Emacs and you just log in to Emacs as your window manager. The same way you would log into i3 or exmonet or DWM or awesome or whatever, you log in into Emacs and it's your window manager. And it's a very easy to learn window manager because assuming you already know Emacs, which I mean, why would you use exwm if you didn't know how to use Emacs? But if you're an Emacs user, the controls and everything, I mean, you're basically just living inside Emacs. So there's not really a whole lot of new stuff to learn. And, you know, I made a video about setting up exwm within DOOM Emacs a few weeks back. And the little bit of time that I played with that, it was comfy, I'm not gonna lie. I felt right at home in exwm immediately. But I was a little concerned because it's still just Emacs full screen as your window manager and can it really replace a proper tiling window manager? Can it really replace something like exmonet, which has really become my preferred window manager here lately? You know, can I get my work done and live in exwm? Well, the only way to find out is to give it a try. And that's really all this is today. This is a test run. I'm recording right now in OBS inside exwm and I just wanna see how things go. But I will go ahead and show you guys my config and I'll talk a little bit about DOOM Emacs and about exwm especially. And let me go ahead and show you my desktop. So when you log into exwm, all you're logging into is Emacs. In my case, DOOM Emacs. Now it's full screen, takes up the entire screen and that is your desktop, right? That's your window manager. I have a triple monitor system, so I actually have DOOM Emacs full screen on all three screens. And right now I have OBS on my far right monitor. OBS is running inside of Emacs buffer. So if I go to this middle monitor here, and let me make sure I have focus. If I do super and the ampersign, I will get a run prompt. So that's super shift seven on the keyboard. And you see, I get a dollar sign and a cursor and I could launch something from here. Maybe I wanna launch, I don't know, cute browser. And I can even hit tab and complete it. So you can get the tab complete functionality built into it, which is kinda cool. And I have a key binding here to quickly do a vertical split. Super V is what I'm using, but you can set that to anything. And inside this split over here, you can see the buffer is actually still a cute browser buffer because that's what I opened it from the cute browser buffer over here. So it's the same kind of buffer, which I will tell you that because this is not really an Emacs buffer, this is a cute browser buffer now. Some of my Emacs commands won't work. For example, say I wanted to open up a recent file. Well, inside doom Emacs, space LR would get you that functionality, but it does nothing here because I'm in a cute browser. And cute browser, as soon as I hit space, space has a different functionality inside the browser, right? Space is just a space because you can actually type text like in this form here. So I can't just have space, you know, be like a leader key or anything. There's some tricks to getting EXWM to work because you have to treat all your Emacs buffers one way and you have to treat all your X window buffers a different way because you can't use a lot of the same bindings because there's conflicts. For example, control F in Emacs does a lot of things, right? Control F in a web browser does something completely different. That's typically the hot key for searching, for finding something inside the page. And that's an example of conflicting key bindings, conflicting hot keys. It will confuse the window manager. Which control F were you trying to do? The one that moves forward inside Emacs or were you trying to do control F or find something in this web page? I don't know what you're doing, so I can't really... So you do have to spend some time with the config file to make sure that you have all your key bindings squared away. Now I could launch another program in this empty split here and I could do the super shift seven here, the super ampersign and run something like PC man Fium if I wanted to. But I don't really like that standard default prompt. What I would like to do is have Dmenu installed because Dmenu is what I use in all of my window managers, especially tiling window managers. And you can't really use Dmenu inside Emacs. Oh, but yes you can. There is actually a plugin called dmenu.el or elisp, right? It's just a elisp plugin and it emulates Dmenu's behavior. The Dmenu underscore run command from the traditional Dmenu package. So if I run Dmenu here, as I've already got this installed, I'm just gonna do a meta X and then type Dmenu. And you see I get this Dmenu like prompt down here. And that actually remembers some of my latest commands, PC man Fium, I guess was the last thing I had ran from Dmenu. So let me go ahead and launch it. And you see now I have cute browser and a split. I have PC man Fium and a split. If I wanna change focus between the windows, right now obviously I'm focused on PC man Fium, but if I do a super HJKL, the VemMotion keys. So if I do super L, I'll move focus to the right window. And you see cute browsers highlighted here. So I'm actually in this window. If I do super H, I will move back over to PC man Fium. And if I had windows above or below, I could do super J and K for down and up. I also added some functionality where I can also move the windows in the stack. So if I do super shift J and K, I could super shift J moves that window down, super shift L will move it back to the right, super shift H will move it over to the left, et cetera. So super shift HJKL changes the positions of the windows. Just super HJKL changes the focus, which window has focus. These are not the default key bindings for EXWM. I made these my key bindings because I wanted more traditional tiling when window manager like key bindings because the super HJKL stuff for the motion is standard and pretty much every tiling window manager. So I wanted that inside EXWM. Same thing with super shift HJKL for moving the windows. I wanted that. And for all of my configs, you know, in my tiling window managers, I use super shift C to close a window. So I still have that functionality here, super shift C. Super shift C again to close this window actually won't work, but I will do it. So you can see that it will give me an error that says I can't delete the last workspace. You actually have to kill this entire buffer. I have super shift B to kill the buffer. And once I do that, the go is still here too. I'll go ahead and kill that buffer and we're back to the DOOM Emacs start screen. So let me do a space FR here in DOOM Emacs to open a recent file. I'm gonna open my DOOM Emacs config. Let me zoom in here so you can see. And my DOOM Emacs config is starting to get rather lengthy, but if you look for the heading titled exwm, let me click on that and we'll go to that section of the config. And I try to leave comments here so you guys can see what I'm doing. I even included a nice little table of all the commands that I have key binded. And of course, what the key binding I am currently using for those commands. And to install exwm, I left you guys a note here. All you need to do is install exwm in your package manager inside Emacs. Those of you using DOOM Emacs, what you need to do is go to the packages.el file. So let me search for packages.el and zoom in here. And DOOM Emacs makes installing plugins very easy. All you need to do is list everything extra in this file. And this is all the plugins I want to be installed that are not already installed in DOOM Emacs. And you can see package right here, package exclamation point space exwm. And DOOM Emacs will install that for me. Same thing with Dmenu. That's how I got the Dmenu installed as well. So you put those in packages.el and then you run a DOOM sync and it will rebuild DOOM Emacs with these particular packages installed for you. Now let me go back to my config.org and I will show you the relevant code that makes what I'm doing so far work. The first thing you need to do is you have to require a few modules, right? You have to require exwm because you can't use exwm until you actually add it to your config. So require exwm and then you also wanna require exwm-config. This is the default configuration for exwm and then you need to add this line here exwm-config-default. And then some extra stuff you may or may not need. I would like a sys tray inside DOOM Emacs here for exwm rather. So I require exwm-system tray and then up under that exwm-system-enable enables the system tray. It puts a system tray right up underneath the mode line. So this empty line down here will have a sys tray. I actually don't have it working at the moment but I can correct that. So let me go to Dmenu and I'm gonna launch my session, LX Session. And then once I do that, you see I have a system tray down here. And right now I just have the network manager, I have the OBS icon and I have a NextCloud syncing as well. Now let me go ahead and get back to my buffer list. So let me, I actually have to do meta X and then I buffer to get back to my buffer list because I was in a LX Session buffer. So my standard Emacs key bindings did not work. I'm gonna explain why here in just a second. But let me get through the requirements here. So other than requiring exwm-exwm-config and exwm-system tray, I'm also requiring exwm-rander. So if you run a ex-rander in your terminal, it gives you your current monitor names and the possible screen resolutions that you could set those monitors to. It's kind of the same thing as running ex-rander in the terminal and it basically allows me to do multi monitors in exwm because once I enable render, you see exwm-rander-enable, then I add this hook and I just copied this from I think the Emacs wiki and you run this command ex-rander nil and then this command here which is exactly the command and then the output from the ex-rander command from the terminal. And that's how I got this. I just ran ex-rander in a terminal and I got that my three monitors were display port dash zero, display port dash one and HDMI dash A dash zero. That's the names of my monitors. And then I said, what display resolution I want? I want 1920 by 1080 on all of them. The positions are different. So the far left monitor position is zero by zero, right? Middle monitor's position is 1920 by zero because it needs to be shifted over 1920 pixels because it's the middle monitor. And the third one of course would be 3840 by zero. You could change the rotation if you needed to. I did not. You need to set one as the primary monitor. And I set that to the middle monitor which in my case is the one called display port dash one and going down a little further through the config you see I have this section where I set Q and then I set various things including exwm-workspace-number. How many work spaces do I want? I want 10. And if I do in my case super W I can switch to a workspace and I have zero through nine. The first workspace is actually zero. That's a little weird because in every other tiling window manager I've ever used the first workspace is actually just one. So super one to go to the first workspace not in exwm super one would actually go to the second workspace super zero goes to the first workspace. So let me quit out of that. So control G will always quit you out of something inside Emacs if you get into a command that you want to just cancel and you don't want to complete it. The most important part of the config and the one that's going to be the most time consuming because you're going to have to spend some time on it and really think about some things because you're going to have to have different key bindings for different stuff because your Emacs buffers, your standard Emacs buffers are going to accept all of your Emacs key bindings but when you open an ex-window buffer when you open Firefox and PC Man Fm or OBS or whatever it is, your standard ex-window graphical applications, none of your Emacs bindings are going to work in those graphical applications because for example, control F inside Emacs does something, right? Control F inside Firefox does something too. It doesn't do the same thing though. So you're going to have all these conflicting key bindings or these key bindings basically that don't even work. So you're going to have to think about that a little bit and inside EXWM you really can have three lists of key bindings. The most important one probably is the one that you see most of my key bindings are in is the EXWM-input-global-keys. So these key bindings should work everywhere. These are global key bindings that no matter what kind of buffer I am in, this key binding will work and it's an ex-window that's in that buffer. If it happened to use that key binding, oh well, I'm overriding it. I don't want you to use that key binding for something. I want this key binding to always do this. For example, no matter what buffer I'm in, the super ampersign should always give me the run prompt, right? That should work inside of Emacs buffer, which it does. That should also work inside ex-window buffer, say Firefox for example. So I always have the ability to bring up a run prompt. So that's very important. That's why you add it to the input-global-keys list. Now, there's two other lists here. There's the input-prefix-keys list. What this does is this gives some key bindings where anytime I do the prefix meta-x, I want you to always make that work inside Emacs. I don't, for some reason there is a ex-window that uses meta-x for something. No, no, meta-x should always pass that command onto Emacs so I could actually do meta-x and then run a program for example. I also added meta-colon here. Meta-colon is typically these default key binding for evaluating an expression, a elispic expression inside Emacs. I just wanted to make sure I always had those in case I needed them because those are kind of important things, right? Being able to run a Emacs command with meta-x especially, make sure that's listed as an input-prefix-key. Then you also have a section for input-simulation-keys. So this is an area where, you know, I simulate a different key binding than the one I'm actually typing. For example, I mentioned Control-F. It does one thing in Emacs, but Control-F and graphical application is typically the shortcut key for searching for something or finding something in the page, such as in your browser or in your GUI text editors. So, you know, you're gonna have conflicts with Control-F. Control-F is not going to work inside Firefox, for example. And that's the reason I figured out what input-simulation-keys were is if I hit Control-F in Firefox, it does nothing. Well, it'll accept Super-F, though. So if I do Super-F and bind that to where Super-F is really the same functionality as Control-F, Super-F inside Firefox runs the Control-F command, which is find something in this page. So that is why you have three different sets of key bindings. Other than that, you know, I added all my standard key bindings. Everything I was using inside Xmonad and all some in DWM, you know, is the same motion keys for changing focus, the same keys for moving windows around, same keys for opening up, for example, a terminal. So if I do Super-Enter, it will open up a terminal for me, but it's a little bit different in Emacs because it's gonna open it in the buffer you happen to be in, but this launches the e-shell inside this buffer. If I wanted that to launch in a different way or in a different split or whatever, I could do a split, I could do Super-V for a vertical split, I could do Super-S for a horizontal split, I believe. Now I did Super-Z for horizontal split. There it is. And then from here, if I wanted to change buffers, I mean, I could, well, let me escape to get into normal mode. And then I could go through my buffer list and get back into whatever I wanted to get into here. I guess I'll do my config.org and let's do something different on this. Let me run a LS command. CD into the home directory, we'll run a LS. And if I wanted to move these windows around, for example, right now, I'm in the left-hand window, let me escape to make sure I'm in normal mode. And then I could do Super-Shift and then L moves that over to the right. Super-Shift-J moves it down. Super-Shift-H moves it back over to the left. Super-Shift-C will close. Super-Shift-C will close. And Super-Shift-C will not close this one because it's the last window in the workspace. It will complain. But again, I have a key binding to kill the buffer. Super-Shift-B would kill the buffer. And I could keep killing the buffer until I kill everything that is running. I'm gonna have some problems with the E-shell here because it's gonna require confirmation. Well, I have a ton of buffers open. I had to Super-Shift-B about 15 times to kill all those buffers. And just quickly, for those of you wondering how the multi-monitor situation looks, you know, here's the three monitors. You can see on my third monitor have OBS open in a split and I have PC-MAN FM open in a split. And I adjusted the width of the split because I really need most of the screen taken up by OBS. I don't need to see PC-MAN FM. The only reason I have PC-MAN FM open while recording is I wanna make sure that the files, when I hit Start Recording, I wanna make sure a new file appears. You know, it just visually, it makes me happy to actually see the file created because sometimes you'll hit Start Recording and you think you started the recording and you didn't and you talk for 10, 15 minutes, you know, in one clip and then realize, oh, crap, I didn't record any of that. So pro tip, any of you guys that are gonna start, you know, doing any kind of video content on something like YouTube or library, yeah. Visually, it's nice to have a file manager open while you're recording just to make sure every time you hit Start Recording, look over at your file manager and make sure you see that file created and make sure it appears in the list. Otherwise, you could talk forever and then realize, hey, I didn't record any of that. One thing I didn't talk about is floating windows. You actually can float windows in side EXWM. So let me open up a graphical program here. So give me just a second. And I'll launch PCman FM. If I wanted to float it, I believe I did Super F to float a window, yes. So it's now not, you know, taking up the full screen there. You can see I can actually adjust it. I'm just using the super key and the mouse, kind of like you do in most Tiling Window Managers. Same thing to drag it. I just hit Super and then drag it with the mouse, although you can see graphically. You know, it's a little different because you have the border, you know, moving, but the window is not moving until I release it and then it appears there. It also has a mode line in it, you know, the Emacs mode line. Now I can toggle the mode line on and off because I added a key binding for it. If I think a Super M is what I binded that to, yeah, Super M toggles the mode line on and off and that works in any Emacs buffer, you know, that would work on any window. I think to put that back into frame, if I do Super F again, yeah, it toggles floating off and it forces that back into, you know, a standard Emacs buffer there. So is this gonna be my window manager going forward? Is Emacs gonna become DT's standard default window manager? I don't know about that as far as the long term, but I am gonna live in it for a couple of weeks here. I just wanna try it out, right? I just wanna see how well it works, just to see if it's usable. And I think it already is. I mean, I was able to record this video. I'm watching the OBS preview. Everything seems to work. The one thing I will say about Emacs and EXWM is Emacs is single threaded. It's not multi threaded. So using it as your window manager, you do have to understand that it won't be the fastest thing. You know, if you're doing stuff that's really heavy resource intensive work, I will say, I do notice EXWM does hang sometimes. You know, it will hang for a second or two on some things. It will slow down. But I'm gonna try it out for a little while and see how well, you know, just say, YouTube content creator is able to get on doing their work inside EXWM. Now, before I go, I need to thank a few special people. I need to thank Devon, Fran, Gabe, Corbinion, Mitchell, Akami, Arch 5530, Chris, Chuck, Donnie, Dylan, Gregory, Lewis, Paul, PicVM, Scott and Willie. They are the producers of the show. They are my highest tiered patrons over on Patreon. Without these guys, this look into Doomy Max and EXWM would not have been possible. The show is also brought to you by each and every one of these names. All these names you're seeing on the screen. These are all my supporters over on Patreon because DistroTube, this channel, sponsored by you guys, the community. I wouldn't be able to do this without you guys. And if you're not currently subscribed to DistroTube on Patreon, I hope you consider it. All right, guys, peace.