You are not logged in.
Hi,
I'm trying dwm after some time on Spectrwm, but i'm facing a strange behaviour it is impossible at all to switch to n tag with ModKey + n or put client to desired tag.
Also dmenu wont spawn with ModKey + p. It spawn perfectly with "$: dmenu_run" in a terminal but not with dwm shortcut.
Other things seems to works fine.
is anyone already had the same behaviour ?
here is my config.h the only things that have changed from the config.def.h template is the termcmd (st replaced with terminology) and the modkey which I have change from "Alt" to "WindowsKey"
/* See LICENSE file for copyright and license details. */
/* appearance */
static const char font[] = "-*-terminus-medium-r-*-*-16-*-*-*-*-*-*-*";
static const char normbordercolor[] = "#444444";
static const char normbgcolor[] = "#222222";
static const char normfgcolor[] = "#bbbbbb";
static const char selbordercolor[] = "#005577";
static const char selbgcolor[] = "#005577";
static const char selfgcolor[] = "#eeeeee";
static const unsigned int borderpx = 1; /* border pixel of windows */
static const unsigned int snap = 32; /* snap pixel */
static const Bool showbar = True; /* False means no bar */
static const Bool topbar = True; /* False means bottom bar */
/* tagging */
static const char *tags[] = { "1", "2", "3", "4", "5", "6", "7", "8", "9" };
static const Rule rules[] = {
/* xprop(1):
* WM_CLASS(STRING) = instance, class
* WM_NAME(STRING) = title
*/
/* class instance title tags mask isfloating monitor */
{ "Gimp", NULL, NULL, 0, True, -1 },
{ "Firefox", NULL, NULL, 1 << 8, False, -1 },
};
/* layout(s) */
static const float mfact = 0.55; /* factor of master area size [0.05..0.95] */
static const int nmaster = 1; /* number of clients in master area */
static const Bool resizehints = True; /* True means respect size hints in tiled resizals */
static const Layout layouts[] = {
/* symbol arrange function */
{ "[]=", tile }, /* first entry is default */
{ "><>", NULL }, /* no layout function means floating behavior */
{ "[M]", monocle },
};
/* key definitions */
#define MODKEY Mod4Mask
#define TAGKEYS(KEY,TAG) \
{ MODKEY, KEY, view, {.ui = 1 << TAG} }, \
{ MODKEY|ControlMask, KEY, toggleview, {.ui = 1 << TAG} }, \
{ MODKEY|ShiftMask, KEY, tag, {.ui = 1 << TAG} }, \
{ MODKEY|ControlMask|ShiftMask, KEY, toggletag, {.ui = 1 << TAG} },
/* helper for spawning shell commands in the pre dwm-5.0 fashion */
#define SHCMD(cmd) { .v = (const char*[]){ "/bin/sh", "-c", cmd, NULL } }
/* commands */
static char dmenumon[2] = "0"; /* component of dmenucmd, manipulated in spawn() */
static const char *dmenucmd[] = { "dmenu_run", "-m", dmenumon, "-fn", font, "-nb", normbgcolor, "-nf", normfgcolor, "-sb", selbgcolor, "-sf", selfgcolor, NULL };
static const char *termcmd[] = { "terminology", NULL };
static Key keys[] = {
/* modifier key function argument */
{ MODKEY, XK_p, spawn, {.v = dmenucmd } },
{ MODKEY|ShiftMask, XK_Return, spawn, {.v = termcmd } },
{ MODKEY, XK_b, togglebar, {0} },
{ MODKEY, XK_j, focusstack, {.i = +1 } },
{ MODKEY, XK_k, focusstack, {.i = -1 } },
{ MODKEY, XK_i, incnmaster, {.i = +1 } },
{ MODKEY, XK_d, incnmaster, {.i = -1 } },
{ MODKEY, XK_h, setmfact, {.f = -0.05} },
{ MODKEY, XK_l, setmfact, {.f = +0.05} },
{ MODKEY, XK_Return, zoom, {0} },
{ MODKEY, XK_Tab, view, {0} },
{ MODKEY|ShiftMask, XK_c, killclient, {0} },
{ MODKEY, XK_t, setlayout, {.v = &layouts[0]} },
{ MODKEY, XK_f, setlayout, {.v = &layouts[1]} },
{ MODKEY, XK_m, setlayout, {.v = &layouts[2]} },
{ MODKEY, XK_space, setlayout, {0} },
{ MODKEY|ShiftMask, XK_space, togglefloating, {0} },
{ MODKEY, XK_0, view, {.ui = ~0 } },
{ MODKEY|ShiftMask, XK_0, tag, {.ui = ~0 } },
{ MODKEY, XK_comma, focusmon, {.i = -1 } },
{ MODKEY, XK_period, focusmon, {.i = +1 } },
{ MODKEY|ShiftMask, XK_comma, tagmon, {.i = -1 } },
{ MODKEY|ShiftMask, XK_period, tagmon, {.i = +1 } },
TAGKEYS( XK_1, 0)
TAGKEYS( XK_2, 1)
TAGKEYS( XK_3, 2)
TAGKEYS( XK_4, 3)
TAGKEYS( XK_5, 4)
TAGKEYS( XK_6, 5)
TAGKEYS( XK_7, 6)
TAGKEYS( XK_8, 7)
TAGKEYS( XK_9, 8)
{ MODKEY|ShiftMask, XK_q, quit, {0} },
};
/* button definitions */
/* click can be ClkLtSymbol, ClkStatusText, ClkWinTitle, ClkClientWin, or ClkRootWin */
static Button buttons[] = {
/* click event mask button function argument */
{ 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} },
};
Last edited by core_sum (2013-10-03 18:23:05)
Offline
What version of DWM are you running?
How did you install it?
How are you starting it?
Does it work if you change your MODKEY?
Last edited by XURL (2013-09-29 19:29:50)
☑ CPU: Single core Intel Pentium M (-UP-) clocked at 1733.000 Mhz
☑ MEM: 490.1 MB
☑ HDD: 40.1 GB
Offline
Not a C programmer, but I think you might be missing some semicolons and/or brackets in your config.h.
Offline
Not a C programmer, but I think you might be missing some semicolons and/or brackets in your config.h.
Where? He wouldn't be able to compile it in case of missing semicolons.
☑ CPU: Single core Intel Pentium M (-UP-) clocked at 1733.000 Mhz
☑ MEM: 490.1 MB
☑ HDD: 40.1 GB
Offline
dwm 6.1 latest git pull
build & installed with makepkg -efi (config.h tweaked)
started with xinitrc "exec dwm"
I have try with alt (modkey1) and windows key (modkey4) same issue.
Also I have try to install the dwm binary from arch repo. the Dmenu works with ModKey + p but not the tag switching.
Offline
at least as of dwm6.0 the command to send a client to a tab was Mod1 + Shift + [1-9]. I would go back and recompile without the mods and see if the stock key bindings work that or go back to 6.0 as that is known to work.
#define MODKEY Mod4Mask
As I recall and I could be totally wrong but shouldn't it be more like
#define MODKEY Mod4
Offline
It was in fact the 6.0.1 so I presum this the 6.0 version.
I have try to recompile with and without modification in config.h switching tags or sending clien to specified tag still not working.
Also I have try with
#define MODKEY Mod4
but it wont compile.
All others keybiding works well like toggling the status bar with ModKey4 + b, increase client size, switching layout...but not the dmenu and tags functions.
I have try on my laptop and on my workstation and it does the same behaviour so it should be an error from me
Last edited by core_sum (2013-09-30 18:59:51)
Offline
#define MODKEY Mod4
You of course mean Mod4MASK, right?
Offline
All others keybiding works well like toggling the status bar with ModKey4 + b, increase client size, switching layout...but not the dmenu and tags functions.
What version of dmenu are you running? Try discarding "-m" option for dmenucmd in config.h, like this:
static const char *dmenucmd[] = { "dmenu_run", "-fn", font, "-nb", normbgcolor, "-nf", normfgcolor, "-sb", selbgcolor, "-sf", selfgcolor, NULL };
Offline
yeah for sur I mean Mod4Mask
it is dmenu version 4.5.3.
I have remove the -m option and voila dmenu is back from hell. it works perfectly without -m option.
I'm trying to figure out what is that -m option, but it's not in the dmenu man.
Also ModKey4 + TAB works well and switch from the last tag seen so the wm is usable but it would be nice if sending client to tag was functional
Last edited by core_sum (2013-10-01 11:11:00)
Offline
Ok solved,
it was the keycodes from my azerty keyboard which not correspond to the shortcuts in the config.h, I have change the keycodes according to the azerty patch availiable here and voila all issues are gone.
I mark the topic solved.
Offline