dylanaraps/sowm

User shortcuts doesn't work

Vouivre opened this issue · 3 comments

Hello,

I have defined some shortcuts in my config.def.h and they doesn't work. The shortcuts are the following:

const char* tile[]    = {"tile", "-s", 0};
const char* zathura[] = {"zathura",    0};
{MOD, XK_t,      run, {.com = tile}},
{MOD, XK_z,      run, {.com = zathura}},

My config.def.h

#ifndef CONFIG_H
#define CONFIG_H

#define MOD Mod4Mask

const char* menu[]    = {"dmenu_run",      0};
const char* scrot[]   = {"scr",            0};
const char* briup[]   = {"bri", "10", "+", 0};
const char* bridown[] = {"bri", "10", "-", 0};
const char* voldown[] = {"amixer", "sset", "Master", "5%-",         0};
const char* volup[]   = {"amixer", "sset", "Master", "5%+",         0};
const char* volmute[] = {"amixer", "sset", "Master", "toggle",      0};
const char* colors[]  = {"bud", "/home/goldie/Pictures/Wallpapers", 0};
const char* term[]    = {"st", "-f", "DejaVuSansMono-11", "-g", "104x28+0+20", "-e", "fish", 0};
const char* tile[]    = {"tile", "-s", 0};
const char* zathura[] = {"zathura",    0};

static struct key keys[] = {
    {MOD,      XK_q,   win_kill,   {0}},
    {MOD,      XK_c,   win_center, {0}},
    {MOD,      XK_f,   win_fs,     {0}},
    {Mod1Mask, XK_Tab, win_next,   {0}},

    {MOD,      XK_KP_Home,   win_top_left, {0}},
    {MOD,      XK_KP_Prior,   win_top_right, {0}},
    {MOD,      XK_KP_End,   win_bottom_left, {0}},
    {MOD,      XK_KP_Next,   win_bottom_right, {0}},

    {MOD,           XK_k,  win_move,  {.com = (const char*[]){"move",   "n"}, .i = 10}},
    {MOD,           XK_j,  win_move,  {.com = (const char*[]){"move",   "s"}, .i = 10}},
    {MOD,           XK_l,  win_move,  {.com = (const char*[]){"move",   "e"}, .i = 10}},
    {MOD,           XK_h,  win_move,  {.com = (const char*[]){"move",   "w"}, .i = 10}},

    {MOD|ShiftMask, XK_k,  win_move,  {.com = (const char*[]){"resize", "n"}, .i = 10}},
    {MOD|ShiftMask, XK_j,  win_move,  {.com = (const char*[]){"resize", "s"}, .i = 10}},
    {MOD|ShiftMask, XK_l,  win_move,  {.com = (const char*[]){"resize", "e"}, .i = 10}},
    {MOD|ShiftMask, XK_h,  win_move,  {.com = (const char*[]){"resize", "w"}, .i = 10}},


    {MOD, XK_d,      run, {.com = menu}},
    {MOD, XK_w,      run, {.com = colors}},
    {MOD, XK_p,      run, {.com = scrot}},
    {MOD, XK_space,  run, {.com = term}},
    {MOD, XK_t,      run, {.com = tile}},
    {MOD, XK_z,      run, {.com = zathura}},

    {0,   XF86XK_AudioLowerVolume,  run, {.com = voldown}},
    {0,   XF86XK_AudioRaiseVolume,  run, {.com = volup}},
    .
    .
    .

tile is a user defined script, so I thought it was the problem. But even zathura which is in /usr/bin doesn't work. I have customized the term command and it works perfectly fine. I use sowm 1.6. Other similar issues didn't help me.

They must go in config.h not config.def.h. 👍

Thank you!

EDIT: sorry, it still doesn't work. I have to investigate.

Same for me. Edited config.h also tried with default config, sowm does nothing. It just starts with a cursor, gives no error output. I didn't understand what's wrong.