diff options
| author | LM-LCL <hello@exaltedelite.club> | 2025-01-16 22:19:37 +0100 |
|---|---|---|
| committer | LM-LCL <hello@exaltedelite.club> | 2025-01-16 22:19:37 +0100 |
| commit | 2d37c0f00a9ecd33bb0830ffa78f5cc0398ac276 (patch) | |
| tree | 119e77069990177dbfa615e32f8c96423f8612fa | |
| parent | 333ebf684b8d2f36140a281f6204103ab57624f9 (diff) | |
Select mouse prtsc support
| -rw-r--r-- | config.def.h | 35 | ||||
| -rw-r--r-- | config.h | 35 |
2 files changed, 38 insertions, 32 deletions
diff --git a/config.def.h b/config.def.h index 8237f9b..82b55ed 100644 --- a/config.def.h +++ b/config.def.h @@ -78,10 +78,11 @@ static const Layout layouts[] = { /* commands */ static char dmenumon[2] = "0"; /* component of dmenucmd, manipulated in spawn() */ -static const char *dmenucmd[] = { "dmenu_run", "-m", dmenumon, "-fn", dmenufont, "-nb", col_gray1, "-nf", col_white, "-sb", col_gray2, "-sf", col_white, NULL }; -static const char *termcmd[] = { "st", NULL }; +static const char *dmenucmd[] = { "dmenu_run", "-m", dmenumon, "-fn", dmenufont, "-nb", col_gray1, "-nf", col_white, "-sb", col_gray2, "-sf", col_white, NULL }; +static const char *termcmd[] = { "st", NULL }; static const char *dmenutab[] = { "alt-tab" }; static const char *prtsccmd[] = { "prtsc" }; +static const char *prtscfcmd[] = { "prtscf" }; #include "movestack.c" static const Key keys[] = { @@ -128,19 +129,21 @@ static const Key keys[] = { /* button definitions */ /* click can be ClkTagBar, ClkLtSymbol, ClkStatusText, ClkWinTitle, ClkClientWin, or ClkRootWin */ static const Button buttons[] = { - /* click event mask button function argument */ - { ClkRootWin, 0, Button2, spawn, {.v = prtsccmd} }, - { ClkClientWin, 0, Button2, spawn, {.v = prtsccmd} }, - { ClkLtSymbol, 0, Button1, setlayout, {0} }, - { ClkLtSymbol, 0, Button3, setlayout, {.v = &layouts[2]} }, - { ClkWinTitle, 0, Button2, zoom, {0} }, - { ClkStatusText, 0, Button2, spawn, {.v = termcmd} }, - { ClkClientWin, MODKEY, Button1, movemouse, {0} }, - { ClkClientWin, MODKEY, Button2, togglefloating, {0} }, - { ClkClientWin, MODKEY, Button3, resizemouse, {0} }, - { ClkTagBar, 0, Button1, view, {0} }, - { ClkTagBar, 0, Button3, toggleview, {0} }, - { ClkTagBar, MODKEY, Button1, tag, {0} }, - { ClkTagBar, MODKEY, Button3, toggletag, {0} }, + /* click event mask button function argument */ + { ClkRootWin, 0, Button2, spawn, {.v = prtsccmd} }, + { ClkClientWin, 0, Button2, spawn, {.v = prtsccmd} }, + { ClkRootWin, MODKEY|ShiftMask, Button2, spawn, {.v = prtscfcmd} }, + { ClkClientWin, MODKEY|ShiftMask, Button2, spawn, {.v = prtscfcmd} }, + { ClkLtSymbol, 0, Button1, setlayout, {0} }, + { ClkLtSymbol, 0, Button3, setlayout, {.v = &layouts[2]} }, + { ClkWinTitle, 0, Button2, zoom, {0} }, + { ClkStatusText, 0, Button2, spawn, {.v = termcmd} }, + { ClkClientWin, MODKEY, Button1, movemouse, {0} }, + { ClkClientWin, MODKEY, Button2, togglefloating, {0} }, + { ClkClientWin, MODKEY, Button3, resizemouse, {0} }, + { ClkTagBar, 0, Button1, view, {0} }, + { ClkTagBar, 0, Button3, toggleview, {0} }, + { ClkTagBar, MODKEY, Button1, tag, {0} }, + { ClkTagBar, MODKEY, Button3, toggletag, {0} }, }; @@ -78,10 +78,11 @@ static const Layout layouts[] = { /* commands */ static char dmenumon[2] = "0"; /* component of dmenucmd, manipulated in spawn() */ -static const char *dmenucmd[] = { "dmenu_run", "-m", dmenumon, "-fn", dmenufont, "-nb", col_gray1, "-nf", col_white, "-sb", col_gray2, "-sf", col_white, NULL }; -static const char *termcmd[] = { "st", NULL }; +static const char *dmenucmd[] = { "dmenu_run", "-m", dmenumon, "-fn", dmenufont, "-nb", col_gray1, "-nf", col_white, "-sb", col_gray2, "-sf", col_white, NULL }; +static const char *termcmd[] = { "st", NULL }; static const char *dmenutab[] = { "alt-tab" }; static const char *prtsccmd[] = { "prtsc" }; +static const char *prtscfcmd[] = { "prtscf" }; #include "movestack.c" static const Key keys[] = { @@ -128,19 +129,21 @@ static const Key keys[] = { /* button definitions */ /* click can be ClkTagBar, ClkLtSymbol, ClkStatusText, ClkWinTitle, ClkClientWin, or ClkRootWin */ static const Button buttons[] = { - /* click event mask button function argument */ - { ClkRootWin, 0, Button2, spawn, {.v = prtsccmd} }, - { ClkClientWin, 0, Button2, spawn, {.v = prtsccmd} }, - { ClkLtSymbol, 0, Button1, setlayout, {0} }, - { ClkLtSymbol, 0, Button3, setlayout, {.v = &layouts[2]} }, - { ClkWinTitle, 0, Button2, zoom, {0} }, - { ClkStatusText, 0, Button2, spawn, {.v = termcmd} }, - { ClkClientWin, MODKEY, Button1, movemouse, {0} }, - { ClkClientWin, MODKEY, Button2, togglefloating, {0} }, - { ClkClientWin, MODKEY, Button3, resizemouse, {0} }, - { ClkTagBar, 0, Button1, view, {0} }, - { ClkTagBar, 0, Button3, toggleview, {0} }, - { ClkTagBar, MODKEY, Button1, tag, {0} }, - { ClkTagBar, MODKEY, Button3, toggletag, {0} }, + /* click event mask button function argument */ + { ClkRootWin, 0, Button2, spawn, {.v = prtsccmd} }, + { ClkClientWin, 0, Button2, spawn, {.v = prtsccmd} }, + { ClkRootWin, MODKEY|ShiftMask, Button2, spawn, {.v = prtscfcmd} }, + { ClkClientWin, MODKEY|ShiftMask, Button2, spawn, {.v = prtscfcmd} }, + { ClkLtSymbol, 0, Button1, setlayout, {0} }, + { ClkLtSymbol, 0, Button3, setlayout, {.v = &layouts[2]} }, + { ClkWinTitle, 0, Button2, zoom, {0} }, + { ClkStatusText, 0, Button2, spawn, {.v = termcmd} }, + { ClkClientWin, MODKEY, Button1, movemouse, {0} }, + { ClkClientWin, MODKEY, Button2, togglefloating, {0} }, + { ClkClientWin, MODKEY, Button3, resizemouse, {0} }, + { ClkTagBar, 0, Button1, view, {0} }, + { ClkTagBar, 0, Button3, toggleview, {0} }, + { ClkTagBar, MODKEY, Button1, tag, {0} }, + { ClkTagBar, MODKEY, Button3, toggletag, {0} }, }; |
