Since urxvt and termite now look very similar to each other (except for
transparency), and since images do not play nicely in tmux / transparent
windows, it makes sense to separate tasks between the two.
Since launch.sh calculates all the bar values for us (as well as bspwm
settings), we can simply store the top_padding value in the user's cache
directory, then reference that number within sxhkd.
This way, if the top_padding value is changed through launch.sh, editing
sxhkdrc manually isn't needed, and the config file doesn't need to be
reloaded.
I don't think I've ever used these keybinds after I learned about
holding the left mouse button to move windows and holding the right
mouse button to resize them.
If you don't have access to a mouse, you probably don't need to resize
windows anyway, and certainly not float them. tmux is still an option,
and the preselect ratio option of bspc is still there.
Ultimately, since sxhkd just runs shell commands, you can resize windows
through a terminal or shell script as well.
This commit also removes the "switch to previous node" keybind, since
an option like that changes often and may behave unexpectedly if
another node is focused with the cursor.
I tried to do this before, but couldn't figure it out. Now that I
understand more about how windows in X11 work, and now that I know more
about shell scripting, writing this functionality became trivial to do.
There is a shorthand syntax offered by sxhkd that helps us make our
config files more compact. I avoided this syntax at first since I was
new to the software, but now that I've used bspc, sxhkd, and the shell
enough, the shorthand syntax is more concise and easier to read.
I once tried to simplify bspwm terminology back when I started using the
WM. Although it helped me use bspwm in the short term, there were some
things I was still confused about (for example, I did not know the
difference between a node with the fullscreen state and desktop with the
monocle layout).
This commit fixes that.
There is no need to check for whether or not a certain mode is set,
since bspc has a feature that automatically uses the previous mode if
the same mode was detected.
Also, "monocle" is a desktop layout, not a node mode. And modes are
states, not modes. I confused the terminology quite a bit when I was
starting out with bspwm (maybe to make the transition easier?) but now
that I've used it long enough, I feel comfortable using the proper
terminology. All future bspwm-related commits should (hopefully) contain
the proper wording.
I don't know why I couldn't implement it before, but now that I know
more about shell scripting, I know that this works. There's an even
better solution I found in the bspc man pages, which will be covered
in the next commit.
Instead of manually changing every instance where a program could run to
use the config in the cache directory, and instead of copying files
every time pywal is updated, it makes sense to create symbolic links for
these files instead.
This ensures that the right settings are used even without knowing the
passed parameters.
Since tmux is such a useful program, and since we don't need to worry
about images in termite, it makes sense to start all termite windows
with tmux. This lets us use any and all termite sessions in urxvt as
needed.
Before pkill would try to terminate the script since it had "dunst" in
its name. This is the solution for that, and it also makes adding new
commands in the future easier.
Termite works exceptionally well as a transparent terminal, so I'll just
let termite focus on true color, transparency, and displaying emoji
while urxvt focuses on universal theme changing and images in the
terminal.
There doesn't seem to be a terminal out there (yet) that handles both of
these things in all the software I want, so this compromise is good
enough.
Rofi is "a window switcher, application launcher, and dmenu
replacement". It lets you search for and access certain
information at any given time, making it very useful.