add config
This commit is contained in:
parent
81c4c5d8b9
commit
290eab3e66
2 changed files with 216 additions and 124 deletions
170
config.def.h
170
config.def.h
|
|
@ -1,5 +1,7 @@
|
||||||
/* See LICENSE file for copyright and license details. */
|
/* See LICENSE file for copyright and license details. */
|
||||||
|
|
||||||
|
#include <X11/XF86keysym.h>
|
||||||
|
|
||||||
/* appearance */
|
/* appearance */
|
||||||
static const unsigned int borderpx = 1; /* border pixel of windows */
|
static const unsigned int borderpx = 1; /* border pixel of windows */
|
||||||
static const unsigned int snap = 32; /* snap pixel */
|
static const unsigned int snap = 32; /* snap pixel */
|
||||||
|
|
@ -24,7 +26,7 @@ static const char col_cyan[] = "#005577";
|
||||||
static const char *colors[][3] = {
|
static const char *colors[][3] = {
|
||||||
/* fg bg border */
|
/* fg bg border */
|
||||||
[SchemeNorm] = { col_gray3, col_gray1, col_gray2 },
|
[SchemeNorm] = { col_gray3, col_gray1, col_gray2 },
|
||||||
[SchemeSel] = { col_gray4, col_cyan, col_cyan },
|
[SchemeSel] = { col_gray4, col_gray2, col_cyan },
|
||||||
};
|
};
|
||||||
|
|
||||||
/* tagging */
|
/* tagging */
|
||||||
|
|
@ -84,70 +86,114 @@ static const Layout layouts[] = {
|
||||||
/* commands */
|
/* commands */
|
||||||
#define TERM_CMD "wezterm", "-e"
|
#define TERM_CMD "wezterm", "-e"
|
||||||
#define TERM(cmd) { .v = (const char*[]){ TERM_CMD, cmd, NULL } }
|
#define TERM(cmd) { .v = (const char*[]){ TERM_CMD, cmd, NULL } }
|
||||||
static char dmenumon[2] = "0"; /* component of dmenucmd, manipulated in spawn() */
|
static char dmenumon[2] = "0"; /* component of dmenucmd, manipulated in spawn() */
|
||||||
static const char *dmenucmd[] = { "rofi", "-dpi", "1", "-show", "drun", NULL };
|
static const char *dmenucmd[] = { "rofi", "-dpi", "1", "-show", "drun", NULL };
|
||||||
static const char *calccmd[] = { "rofi", "-dpi", "1", "-show", "calc", "-modi", "calc", "-no-show-match", "-no-sort", "-kb-accept-custom", "Return", "-kb-accept-entry", "Control+Return", "-calc-command", "wl-copy {result}", "-theme", "~/.config/rofi/calc.rasi", NULL};
|
static const char *calccmd[] = { "rofi", "-dpi", "1", "-show", "calc", "-modi", "calc", "-no-show-match", "-no-sort", "-kb-accept-custom", "Return", "-kb-accept-entry", "Control+Return", "-calc-command", "wl-copy {result}", "-theme", "~/.config/rofi/calc.rasi", NULL};
|
||||||
static const char *clipboardcmd[] = { "rofi", "-dpi", "1", "-modi", "clipboard:~/bin/cliphist-rofi-img", "-show", "clipboard", "-show-icons", "-theme", "~/.config/rofi/clipboard.rasi", NULL };
|
static const char *clipboardcmd[] = { "rofi", "-dpi", "1", "-modi", "clipboard:~/bin/cliphist-rofi-img", "-show", "clipboard", "-show-icons", "-theme", "~/.config/rofi/clipboard.rasi", NULL };
|
||||||
static const char *termcmd[] = { "wezterm", "-e", NULL };
|
static const char *termcmd[] = { "wezterm", "-e", NULL };
|
||||||
|
static const char *volmicmutecmd[] = { "/usr/bin/pactl", "set-source-mute", "@DEFAULT_SOURCE@", "toggle", NULL };
|
||||||
|
static const char *volsoundmutecmd[] = { "/usr/bin/wpctl", "set-mute", "@DEFAULT_AUDIO_SINK@", "toggle", NULL };
|
||||||
|
static const char *voldecreasecmd[] = { "/usr/bin/wpctl", "set-volume", "-l", "1.0", "@DEFAULT_AUDIO_SINK@", "5%-", NULL };
|
||||||
|
static const char *volincreasecmd[] = { "/usr/bin/wpctl", "set-volume", "-l", "1.0", "@DEFAULT_AUDIO_SINK@", "5%+", NULL };
|
||||||
|
// brightness
|
||||||
|
static const char *increasebrightnesscmd[] = { "/usr/bin/brightnessctl", "s", "+10%", NULL };
|
||||||
|
static const char *decreasebrightnesscmd[] = { "/usr/bin/brightnessctl", "s", "10%-", NULL };
|
||||||
|
// media
|
||||||
|
static const char *mediaplaypausecmd[] = { "/usr/bin/playerctl", "play-pause", NULL };
|
||||||
|
// static const char *mediaplay[] = { "/usr/bin/playerctl", "play", NULL };
|
||||||
|
// static const char *mediapause[] = { "/usr/bin/playerctl", "pause", NULL };
|
||||||
|
static const char *mediaplaynextcmd[] = { "/usr/bin/playerctl", "next", NULL };
|
||||||
|
static const char *mediaplayprevcmd[] = { "/usr/bin/playerctl", "previous", NULL };
|
||||||
|
|
||||||
static const Key keys[] = {
|
static const Key keys[] = {
|
||||||
/* modifier key function argument */
|
/* modifier key function argument */
|
||||||
{ MODKEY, XK_space, spawn, {.v = dmenucmd } },
|
{ MODKEY, XK_space, spawn, {.v = dmenucmd } },
|
||||||
{ MODKEY, XK_Return, spawn, {.v = termcmd } },
|
{ MODKEY, XK_Return, spawn, {.v = termcmd } },
|
||||||
{ MODKEY, XK_b, togglebar, {0} },
|
{ MODKEY, XK_b, togglebar, {0} },
|
||||||
{ MODKEY|ShiftMask, XK_space, spawn, {.v = calccmd } },
|
{ MODKEY|ShiftMask, XK_space, spawn, {.v = calccmd } },
|
||||||
// { MODKEY, XK_j, focusstack, {.i = +1 } },
|
// { MODKEY, XK_j, focusstack, {.i = +1 } },
|
||||||
// { MODKEY, XK_k, focusstack, {.i = -1 } },
|
// { MODKEY, XK_k, focusstack, {.i = -1 } },
|
||||||
{ MODKEY, XK_h, focusdir, {.i = 0 } },
|
{ MODKEY, XK_h, focusdir, {.i = 0 } },
|
||||||
{ MODKEY, XK_l, focusdir, {.i = 1 } },
|
{ MODKEY, XK_l, focusdir, {.i = 1 } },
|
||||||
{ MODKEY, XK_k, focusdir, {.i = 2 } },
|
{ MODKEY, XK_k, focusdir, {.i = 2 } },
|
||||||
{ MODKEY, XK_j, focusdir, {.i = 3 } },
|
{ MODKEY, XK_j, focusdir, {.i = 3 } },
|
||||||
{ MODKEY, XK_i, incnmaster, {.i = +1 } },
|
{ MODKEY, XK_i, incnmaster, {.i = +1 } },
|
||||||
{ MODKEY, XK_d, incnmaster, {.i = -1 } },
|
{ MODKEY, XK_d, incnmaster, {.i = -1 } },
|
||||||
{ MODKEY|ShiftMask, XK_h, setmfact, {.f = -0.05} },
|
{ MODKEY|ShiftMask, XK_h, setmfact, {.f = -0.05} },
|
||||||
{ MODKEY|ShiftMask, XK_l, setmfact, {.f = +0.05} },
|
{ MODKEY|ShiftMask, XK_l, setmfact, {.f = +0.05} },
|
||||||
{ MODKEY, XK_Tab, zoom, {0} },
|
{ MODKEY, XK_Tab, zoom, {0} },
|
||||||
{ MODKEY|ShiftMask, XK_Tab, view, {0} },
|
{ MODKEY|ShiftMask, XK_Tab, view, {0} },
|
||||||
{ MODKEY|Mod1Mask, XK_u, incrgaps, {.i = +1 } },
|
{ MODKEY|Mod1Mask, XK_u, incrgaps, {.i = +1 } },
|
||||||
{ MODKEY|Mod1Mask|ShiftMask, XK_u, incrgaps, {.i = -1 } },
|
{ MODKEY|Mod1Mask|ShiftMask, XK_u, incrgaps, {.i = -1 } },
|
||||||
{ MODKEY|Mod1Mask, XK_i, incrigaps, {.i = +1 } },
|
{ MODKEY|Mod1Mask, XK_i, incrigaps, {.i = +1 } },
|
||||||
{ MODKEY|Mod1Mask|ShiftMask, XK_i, incrigaps, {.i = -1 } },
|
{ MODKEY|Mod1Mask|ShiftMask, XK_i, incrigaps, {.i = -1 } },
|
||||||
{ MODKEY|Mod1Mask, XK_o, incrogaps, {.i = +1 } },
|
{ MODKEY|Mod1Mask, XK_o, incrogaps, {.i = +1 } },
|
||||||
{ MODKEY|Mod1Mask|ShiftMask, XK_o, incrogaps, {.i = -1 } },
|
{ MODKEY|Mod1Mask|ShiftMask, XK_o, incrogaps, {.i = -1 } },
|
||||||
{ MODKEY|Mod1Mask, XK_6, incrihgaps, {.i = +1 } },
|
{ MODKEY|Mod1Mask, XK_6, incrihgaps, {.i = +1 } },
|
||||||
{ MODKEY|Mod1Mask|ShiftMask, XK_6, incrihgaps, {.i = -1 } },
|
{ MODKEY|Mod1Mask|ShiftMask, XK_6, incrihgaps, {.i = -1 } },
|
||||||
{ MODKEY|Mod1Mask, XK_7, incrivgaps, {.i = +1 } },
|
{ MODKEY|Mod1Mask, XK_7, incrivgaps, {.i = +1 } },
|
||||||
{ MODKEY|Mod1Mask|ShiftMask, XK_7, incrivgaps, {.i = -1 } },
|
{ MODKEY|Mod1Mask|ShiftMask, XK_7, incrivgaps, {.i = -1 } },
|
||||||
{ MODKEY|Mod1Mask, XK_8, incrohgaps, {.i = +1 } },
|
{ MODKEY|Mod1Mask, XK_8, incrohgaps, {.i = +1 } },
|
||||||
{ MODKEY|Mod1Mask|ShiftMask, XK_8, incrohgaps, {.i = -1 } },
|
{ MODKEY|Mod1Mask|ShiftMask, XK_8, incrohgaps, {.i = -1 } },
|
||||||
{ MODKEY|Mod1Mask, XK_9, incrovgaps, {.i = +1 } },
|
{ MODKEY|Mod1Mask, XK_9, incrovgaps, {.i = +1 } },
|
||||||
{ MODKEY|Mod1Mask|ShiftMask, XK_9, incrovgaps, {.i = -1 } },
|
{ MODKEY|Mod1Mask|ShiftMask, XK_9, incrovgaps, {.i = -1 } },
|
||||||
{ MODKEY|Mod1Mask, XK_0, togglegaps, {0} },
|
{ MODKEY|Mod1Mask, XK_0, togglegaps, {0} },
|
||||||
{ MODKEY|Mod1Mask|ShiftMask, XK_0, defaultgaps, {0} },
|
{ MODKEY|Mod1Mask|ShiftMask, XK_0, defaultgaps, {0} },
|
||||||
{ MODKEY|ShiftMask, XK_q, killclient, {0} },
|
{ MODKEY|ShiftMask, XK_q, killclient, {0} },
|
||||||
{ MODKEY, XK_e, setlayout, {.v = &layouts[0]} },
|
{ MODKEY, XK_e, setlayout, {.v = &layouts[0]} },
|
||||||
{ MODKEY, XK_t, setlayout, {.v = &layouts[1]} },
|
{ MODKEY, XK_t, setlayout, {.v = &layouts[1]} },
|
||||||
{ MODKEY, XK_p, setlayout, {.v = &layouts[2]} },
|
{ MODKEY, XK_p, setlayout, {.v = &layouts[2]} },
|
||||||
{ MODKEY|ShiftMask, XK_p, togglefloating, {0} },
|
{ MODKEY|ShiftMask, XK_p, togglefloating, {0} },
|
||||||
{ MODKEY, XK_grave, view, {.ui = ~0 } },
|
{ MODKEY, XK_grave, view, {.ui = ~0 } },
|
||||||
{ MODKEY|ShiftMask, XK_grave, tag, {.ui = ~0 } },
|
{ MODKEY|ShiftMask, XK_grave, tag, {.ui = ~0 } },
|
||||||
{ MODKEY, XK_comma, focusmon, {.i = -1 } },
|
{ MODKEY, XK_comma, focusmon, {.i = -1 } },
|
||||||
{ MODKEY, XK_period, focusmon, {.i = +1 } },
|
{ MODKEY, XK_period, focusmon, {.i = +1 } },
|
||||||
{ MODKEY|ShiftMask, XK_comma, tagmon, {.i = -1 } },
|
{ MODKEY|ShiftMask, XK_comma, tagmon, {.i = -1 } },
|
||||||
{ MODKEY|ShiftMask, XK_period, tagmon, {.i = +1 } },
|
{ MODKEY|ShiftMask, XK_period, tagmon, {.i = +1 } },
|
||||||
TAGKEYS( XK_1, 0)
|
TAGKEYS( XK_1, 0)
|
||||||
TAGKEYS( XK_2, 1)
|
TAGKEYS( XK_2, 1)
|
||||||
TAGKEYS( XK_3, 2)
|
TAGKEYS( XK_3, 2)
|
||||||
TAGKEYS( XK_4, 3)
|
TAGKEYS( XK_4, 3)
|
||||||
TAGKEYS( XK_5, 4)
|
TAGKEYS( XK_5, 4)
|
||||||
TAGKEYS( XK_6, 5)
|
TAGKEYS( XK_6, 5)
|
||||||
TAGKEYS( XK_7, 6)
|
TAGKEYS( XK_7, 6)
|
||||||
TAGKEYS( XK_8, 7)
|
TAGKEYS( XK_8, 7)
|
||||||
TAGKEYS( XK_9, 8)
|
TAGKEYS( XK_9, 8)
|
||||||
TAGKEYS( XK_0, 9)
|
TAGKEYS( XK_0, 9)
|
||||||
|
|
||||||
|
|
||||||
|
// volume
|
||||||
|
{ 0, XF86XK_AudioMicMute, spawn, {.v = volmicmutecmd } },
|
||||||
|
{ 0, XF86XK_AudioMute, spawn, {.v = volsoundmutecmd } },
|
||||||
|
{ 0, XF86XK_AudioLowerVolume, spawn, {.v = voldecreasecmd } },
|
||||||
|
{ 0, XF86XK_AudioRaiseVolume, spawn, {.v = volincreasecmd } },
|
||||||
|
|
||||||
|
// media
|
||||||
|
{ 0, XF86XK_AudioPlay, spawn, {.v = mediaplaypausecmd } },
|
||||||
|
{ 0, XF86XK_AudioPause, spawn, {.v = mediaplaypausecmd } },
|
||||||
|
{ 0, XF86XK_AudioNext, spawn, {.v = mediaplaynextcmd } },
|
||||||
|
{ 0, XF86XK_AudioPrev, spawn, {.v = mediaplayprevcmd } },
|
||||||
|
|
||||||
|
// brightness
|
||||||
|
{ 0, XF86XK_MonBrightnessUp, spawn, {.v = increasebrightnesscmd } },
|
||||||
|
{ 0, XF86XK_MonBrightnessDown, spawn, {.v = decreasebrightnesscmd } },
|
||||||
|
|
||||||
|
|
||||||
|
// screenshot
|
||||||
|
{ MODKEY, XK_o, spawn, SHCMD("/usr/bin/maim -s ~/Screenshots/$(date +%Y-%m-%d-%H-%M-%S).png") },
|
||||||
|
{ MODKEY|ShiftMask, XK_o, spawn, SHCMD("/usr/bin/maim -s | /usr/bin/xclip -selection clipboard -t image/png") },
|
||||||
|
{ 0, XK_Print, spawn, SHCMD("/usr/bin/maim -s ~/Screenshots/$(date +%Y-%m-%d-%H-%M-%S).png") },
|
||||||
|
|
||||||
|
// others
|
||||||
|
{ MODKEY, XK_m, spawn, TERM("neomutt") },
|
||||||
|
{ MODKEY, XK_b, spawn, TERM("yazi") },
|
||||||
|
{ MODKEY, XK_semicolon, spawn, TERM("btop") },
|
||||||
|
{ 0, XK_F12, spawn, SHCMD("~/bin/dwm-man") },
|
||||||
|
|
||||||
|
|
||||||
// { MODKEY|ShiftMask, XK_q, quit, {0} },
|
// { MODKEY|ShiftMask, XK_q, quit, {0} },
|
||||||
{ MODKEY|ShiftMask, XK_r, spawn, SHCMD("dinitctl restart wm") },
|
{ MODKEY|ShiftMask, XK_r, spawn, SHCMD("dinitctl restart wm") },
|
||||||
{ MODKEY|ShiftMask, XK_e, spawn, SHCMD("killall dinit") },
|
{ MODKEY|ShiftMask, XK_e, spawn, SHCMD("killall dinit") },
|
||||||
};
|
};
|
||||||
|
|
||||||
/* button definitions */
|
/* button definitions */
|
||||||
|
|
|
||||||
170
config.h
170
config.h
|
|
@ -1,5 +1,7 @@
|
||||||
/* See LICENSE file for copyright and license details. */
|
/* See LICENSE file for copyright and license details. */
|
||||||
|
|
||||||
|
#include <X11/XF86keysym.h>
|
||||||
|
|
||||||
/* appearance */
|
/* appearance */
|
||||||
static const unsigned int borderpx = 1; /* border pixel of windows */
|
static const unsigned int borderpx = 1; /* border pixel of windows */
|
||||||
static const unsigned int snap = 32; /* snap pixel */
|
static const unsigned int snap = 32; /* snap pixel */
|
||||||
|
|
@ -24,7 +26,7 @@ static const char col_cyan[] = "#005577";
|
||||||
static const char *colors[][3] = {
|
static const char *colors[][3] = {
|
||||||
/* fg bg border */
|
/* fg bg border */
|
||||||
[SchemeNorm] = { col_gray3, col_gray1, col_gray2 },
|
[SchemeNorm] = { col_gray3, col_gray1, col_gray2 },
|
||||||
[SchemeSel] = { col_gray4, col_cyan, col_cyan },
|
[SchemeSel] = { col_gray4, col_gray2, col_cyan },
|
||||||
};
|
};
|
||||||
|
|
||||||
/* tagging */
|
/* tagging */
|
||||||
|
|
@ -84,70 +86,114 @@ static const Layout layouts[] = {
|
||||||
/* commands */
|
/* commands */
|
||||||
#define TERM_CMD "wezterm", "-e"
|
#define TERM_CMD "wezterm", "-e"
|
||||||
#define TERM(cmd) { .v = (const char*[]){ TERM_CMD, cmd, NULL } }
|
#define TERM(cmd) { .v = (const char*[]){ TERM_CMD, cmd, NULL } }
|
||||||
static char dmenumon[2] = "0"; /* component of dmenucmd, manipulated in spawn() */
|
static char dmenumon[2] = "0"; /* component of dmenucmd, manipulated in spawn() */
|
||||||
static const char *dmenucmd[] = { "rofi", "-dpi", "1", "-show", "drun", NULL };
|
static const char *dmenucmd[] = { "rofi", "-dpi", "1", "-show", "drun", NULL };
|
||||||
static const char *calccmd[] = { "rofi", "-dpi", "1", "-show", "calc", "-modi", "calc", "-no-show-match", "-no-sort", "-kb-accept-custom", "Return", "-kb-accept-entry", "Control+Return", "-calc-command", "wl-copy {result}", "-theme", "~/.config/rofi/calc.rasi", NULL};
|
static const char *calccmd[] = { "rofi", "-dpi", "1", "-show", "calc", "-modi", "calc", "-no-show-match", "-no-sort", "-kb-accept-custom", "Return", "-kb-accept-entry", "Control+Return", "-calc-command", "wl-copy {result}", "-theme", "~/.config/rofi/calc.rasi", NULL};
|
||||||
static const char *clipboardcmd[] = { "rofi", "-dpi", "1", "-modi", "clipboard:~/bin/cliphist-rofi-img", "-show", "clipboard", "-show-icons", "-theme", "~/.config/rofi/clipboard.rasi", NULL };
|
static const char *clipboardcmd[] = { "rofi", "-dpi", "1", "-modi", "clipboard:~/bin/cliphist-rofi-img", "-show", "clipboard", "-show-icons", "-theme", "~/.config/rofi/clipboard.rasi", NULL };
|
||||||
static const char *termcmd[] = { "wezterm", "-e", NULL };
|
static const char *termcmd[] = { "wezterm", "-e", NULL };
|
||||||
|
static const char *volmicmutecmd[] = { "/usr/bin/pactl", "set-source-mute", "@DEFAULT_SOURCE@", "toggle", NULL };
|
||||||
|
static const char *volsoundmutecmd[] = { "/usr/bin/wpctl", "set-mute", "@DEFAULT_AUDIO_SINK@", "toggle", NULL };
|
||||||
|
static const char *voldecreasecmd[] = { "/usr/bin/wpctl", "set-volume", "-l", "1.0", "@DEFAULT_AUDIO_SINK@", "5%-", NULL };
|
||||||
|
static const char *volincreasecmd[] = { "/usr/bin/wpctl", "set-volume", "-l", "1.0", "@DEFAULT_AUDIO_SINK@", "5%+", NULL };
|
||||||
|
// brightness
|
||||||
|
static const char *increasebrightnesscmd[] = { "/usr/bin/brightnessctl", "s", "+10%", NULL };
|
||||||
|
static const char *decreasebrightnesscmd[] = { "/usr/bin/brightnessctl", "s", "10%-", NULL };
|
||||||
|
// media
|
||||||
|
static const char *mediaplaypausecmd[] = { "/usr/bin/playerctl", "play-pause", NULL };
|
||||||
|
// static const char *mediaplay[] = { "/usr/bin/playerctl", "play", NULL };
|
||||||
|
// static const char *mediapause[] = { "/usr/bin/playerctl", "pause", NULL };
|
||||||
|
static const char *mediaplaynextcmd[] = { "/usr/bin/playerctl", "next", NULL };
|
||||||
|
static const char *mediaplayprevcmd[] = { "/usr/bin/playerctl", "previous", NULL };
|
||||||
|
|
||||||
static const Key keys[] = {
|
static const Key keys[] = {
|
||||||
/* modifier key function argument */
|
/* modifier key function argument */
|
||||||
{ MODKEY, XK_space, spawn, {.v = dmenucmd } },
|
{ MODKEY, XK_space, spawn, {.v = dmenucmd } },
|
||||||
{ MODKEY, XK_Return, spawn, {.v = termcmd } },
|
{ MODKEY, XK_Return, spawn, {.v = termcmd } },
|
||||||
{ MODKEY, XK_b, togglebar, {0} },
|
{ MODKEY, XK_b, togglebar, {0} },
|
||||||
{ MODKEY|ShiftMask, XK_space, spawn, {.v = calccmd } },
|
{ MODKEY|ShiftMask, XK_space, spawn, {.v = calccmd } },
|
||||||
// { MODKEY, XK_j, focusstack, {.i = +1 } },
|
// { MODKEY, XK_j, focusstack, {.i = +1 } },
|
||||||
// { MODKEY, XK_k, focusstack, {.i = -1 } },
|
// { MODKEY, XK_k, focusstack, {.i = -1 } },
|
||||||
{ MODKEY, XK_h, focusdir, {.i = 0 } },
|
{ MODKEY, XK_h, focusdir, {.i = 0 } },
|
||||||
{ MODKEY, XK_l, focusdir, {.i = 1 } },
|
{ MODKEY, XK_l, focusdir, {.i = 1 } },
|
||||||
{ MODKEY, XK_k, focusdir, {.i = 2 } },
|
{ MODKEY, XK_k, focusdir, {.i = 2 } },
|
||||||
{ MODKEY, XK_j, focusdir, {.i = 3 } },
|
{ MODKEY, XK_j, focusdir, {.i = 3 } },
|
||||||
{ MODKEY, XK_i, incnmaster, {.i = +1 } },
|
{ MODKEY, XK_i, incnmaster, {.i = +1 } },
|
||||||
{ MODKEY, XK_d, incnmaster, {.i = -1 } },
|
{ MODKEY, XK_d, incnmaster, {.i = -1 } },
|
||||||
{ MODKEY|ShiftMask, XK_h, setmfact, {.f = -0.05} },
|
{ MODKEY|ShiftMask, XK_h, setmfact, {.f = -0.05} },
|
||||||
{ MODKEY|ShiftMask, XK_l, setmfact, {.f = +0.05} },
|
{ MODKEY|ShiftMask, XK_l, setmfact, {.f = +0.05} },
|
||||||
{ MODKEY, XK_Tab, zoom, {0} },
|
{ MODKEY, XK_Tab, zoom, {0} },
|
||||||
{ MODKEY|ShiftMask, XK_Tab, view, {0} },
|
{ MODKEY|ShiftMask, XK_Tab, view, {0} },
|
||||||
{ MODKEY|Mod1Mask, XK_u, incrgaps, {.i = +1 } },
|
{ MODKEY|Mod1Mask, XK_u, incrgaps, {.i = +1 } },
|
||||||
{ MODKEY|Mod1Mask|ShiftMask, XK_u, incrgaps, {.i = -1 } },
|
{ MODKEY|Mod1Mask|ShiftMask, XK_u, incrgaps, {.i = -1 } },
|
||||||
{ MODKEY|Mod1Mask, XK_i, incrigaps, {.i = +1 } },
|
{ MODKEY|Mod1Mask, XK_i, incrigaps, {.i = +1 } },
|
||||||
{ MODKEY|Mod1Mask|ShiftMask, XK_i, incrigaps, {.i = -1 } },
|
{ MODKEY|Mod1Mask|ShiftMask, XK_i, incrigaps, {.i = -1 } },
|
||||||
{ MODKEY|Mod1Mask, XK_o, incrogaps, {.i = +1 } },
|
{ MODKEY|Mod1Mask, XK_o, incrogaps, {.i = +1 } },
|
||||||
{ MODKEY|Mod1Mask|ShiftMask, XK_o, incrogaps, {.i = -1 } },
|
{ MODKEY|Mod1Mask|ShiftMask, XK_o, incrogaps, {.i = -1 } },
|
||||||
{ MODKEY|Mod1Mask, XK_6, incrihgaps, {.i = +1 } },
|
{ MODKEY|Mod1Mask, XK_6, incrihgaps, {.i = +1 } },
|
||||||
{ MODKEY|Mod1Mask|ShiftMask, XK_6, incrihgaps, {.i = -1 } },
|
{ MODKEY|Mod1Mask|ShiftMask, XK_6, incrihgaps, {.i = -1 } },
|
||||||
{ MODKEY|Mod1Mask, XK_7, incrivgaps, {.i = +1 } },
|
{ MODKEY|Mod1Mask, XK_7, incrivgaps, {.i = +1 } },
|
||||||
{ MODKEY|Mod1Mask|ShiftMask, XK_7, incrivgaps, {.i = -1 } },
|
{ MODKEY|Mod1Mask|ShiftMask, XK_7, incrivgaps, {.i = -1 } },
|
||||||
{ MODKEY|Mod1Mask, XK_8, incrohgaps, {.i = +1 } },
|
{ MODKEY|Mod1Mask, XK_8, incrohgaps, {.i = +1 } },
|
||||||
{ MODKEY|Mod1Mask|ShiftMask, XK_8, incrohgaps, {.i = -1 } },
|
{ MODKEY|Mod1Mask|ShiftMask, XK_8, incrohgaps, {.i = -1 } },
|
||||||
{ MODKEY|Mod1Mask, XK_9, incrovgaps, {.i = +1 } },
|
{ MODKEY|Mod1Mask, XK_9, incrovgaps, {.i = +1 } },
|
||||||
{ MODKEY|Mod1Mask|ShiftMask, XK_9, incrovgaps, {.i = -1 } },
|
{ MODKEY|Mod1Mask|ShiftMask, XK_9, incrovgaps, {.i = -1 } },
|
||||||
{ MODKEY|Mod1Mask, XK_0, togglegaps, {0} },
|
{ MODKEY|Mod1Mask, XK_0, togglegaps, {0} },
|
||||||
{ MODKEY|Mod1Mask|ShiftMask, XK_0, defaultgaps, {0} },
|
{ MODKEY|Mod1Mask|ShiftMask, XK_0, defaultgaps, {0} },
|
||||||
{ MODKEY|ShiftMask, XK_q, killclient, {0} },
|
{ MODKEY|ShiftMask, XK_q, killclient, {0} },
|
||||||
{ MODKEY, XK_e, setlayout, {.v = &layouts[0]} },
|
{ MODKEY, XK_e, setlayout, {.v = &layouts[0]} },
|
||||||
{ MODKEY, XK_t, setlayout, {.v = &layouts[1]} },
|
{ MODKEY, XK_t, setlayout, {.v = &layouts[1]} },
|
||||||
{ MODKEY, XK_p, setlayout, {.v = &layouts[2]} },
|
{ MODKEY, XK_p, setlayout, {.v = &layouts[2]} },
|
||||||
{ MODKEY|ShiftMask, XK_p, togglefloating, {0} },
|
{ MODKEY|ShiftMask, XK_p, togglefloating, {0} },
|
||||||
{ MODKEY, XK_grave, view, {.ui = ~0 } },
|
{ MODKEY, XK_grave, view, {.ui = ~0 } },
|
||||||
{ MODKEY|ShiftMask, XK_grave, tag, {.ui = ~0 } },
|
{ MODKEY|ShiftMask, XK_grave, tag, {.ui = ~0 } },
|
||||||
{ MODKEY, XK_comma, focusmon, {.i = -1 } },
|
{ MODKEY, XK_comma, focusmon, {.i = -1 } },
|
||||||
{ MODKEY, XK_period, focusmon, {.i = +1 } },
|
{ MODKEY, XK_period, focusmon, {.i = +1 } },
|
||||||
{ MODKEY|ShiftMask, XK_comma, tagmon, {.i = -1 } },
|
{ MODKEY|ShiftMask, XK_comma, tagmon, {.i = -1 } },
|
||||||
{ MODKEY|ShiftMask, XK_period, tagmon, {.i = +1 } },
|
{ MODKEY|ShiftMask, XK_period, tagmon, {.i = +1 } },
|
||||||
TAGKEYS( XK_1, 0)
|
TAGKEYS( XK_1, 0)
|
||||||
TAGKEYS( XK_2, 1)
|
TAGKEYS( XK_2, 1)
|
||||||
TAGKEYS( XK_3, 2)
|
TAGKEYS( XK_3, 2)
|
||||||
TAGKEYS( XK_4, 3)
|
TAGKEYS( XK_4, 3)
|
||||||
TAGKEYS( XK_5, 4)
|
TAGKEYS( XK_5, 4)
|
||||||
TAGKEYS( XK_6, 5)
|
TAGKEYS( XK_6, 5)
|
||||||
TAGKEYS( XK_7, 6)
|
TAGKEYS( XK_7, 6)
|
||||||
TAGKEYS( XK_8, 7)
|
TAGKEYS( XK_8, 7)
|
||||||
TAGKEYS( XK_9, 8)
|
TAGKEYS( XK_9, 8)
|
||||||
TAGKEYS( XK_0, 9)
|
TAGKEYS( XK_0, 9)
|
||||||
|
|
||||||
|
|
||||||
|
// volume
|
||||||
|
{ 0, XF86XK_AudioMicMute, spawn, {.v = volmicmutecmd } },
|
||||||
|
{ 0, XF86XK_AudioMute, spawn, {.v = volsoundmutecmd } },
|
||||||
|
{ 0, XF86XK_AudioLowerVolume, spawn, {.v = voldecreasecmd } },
|
||||||
|
{ 0, XF86XK_AudioRaiseVolume, spawn, {.v = volincreasecmd } },
|
||||||
|
|
||||||
|
// media
|
||||||
|
{ 0, XF86XK_AudioPlay, spawn, {.v = mediaplaypausecmd } },
|
||||||
|
{ 0, XF86XK_AudioPause, spawn, {.v = mediaplaypausecmd } },
|
||||||
|
{ 0, XF86XK_AudioNext, spawn, {.v = mediaplaynextcmd } },
|
||||||
|
{ 0, XF86XK_AudioPrev, spawn, {.v = mediaplayprevcmd } },
|
||||||
|
|
||||||
|
// brightness
|
||||||
|
{ 0, XF86XK_MonBrightnessUp, spawn, {.v = increasebrightnesscmd } },
|
||||||
|
{ 0, XF86XK_MonBrightnessDown, spawn, {.v = decreasebrightnesscmd } },
|
||||||
|
|
||||||
|
|
||||||
|
// screenshot
|
||||||
|
{ MODKEY, XK_o, spawn, SHCMD("/usr/bin/maim -s ~/Screenshots/$(date +%Y-%m-%d-%H-%M-%S).png") },
|
||||||
|
{ MODKEY|ShiftMask, XK_o, spawn, SHCMD("/usr/bin/maim -s | /usr/bin/xclip -selection clipboard -t image/png") },
|
||||||
|
{ 0, XK_Print, spawn, SHCMD("/usr/bin/maim -s ~/Screenshots/$(date +%Y-%m-%d-%H-%M-%S).png") },
|
||||||
|
|
||||||
|
// others
|
||||||
|
{ MODKEY, XK_m, spawn, TERM("neomutt") },
|
||||||
|
{ MODKEY, XK_b, spawn, TERM("yazi") },
|
||||||
|
{ MODKEY, XK_semicolon, spawn, TERM("btop") },
|
||||||
|
{ 0, XK_F12, spawn, SHCMD("~/bin/dwm-man") },
|
||||||
|
|
||||||
|
|
||||||
// { MODKEY|ShiftMask, XK_q, quit, {0} },
|
// { MODKEY|ShiftMask, XK_q, quit, {0} },
|
||||||
{ MODKEY|ShiftMask, XK_r, spawn, SHCMD("dinitctl restart wm") },
|
{ MODKEY|ShiftMask, XK_r, spawn, SHCMD("dinitctl restart wm") },
|
||||||
{ MODKEY|ShiftMask, XK_e, spawn, SHCMD("killall dinit") },
|
{ MODKEY|ShiftMask, XK_e, spawn, SHCMD("killall dinit") },
|
||||||
};
|
};
|
||||||
|
|
||||||
/* button definitions */
|
/* button definitions */
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue