You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

73 lines
2.6 KiB

19 years ago
19 years ago
  1. /*
  2. * (C)opyright MMVI Anselm R. Garbe <garbeam at gmail dot com>
  3. * See LICENSE file for license details.
  4. */
  5. enum { Tfnord, Tdev, Tnet, Twork, Tmisc, TLast };
  6. #define TAGS \
  7. char *tags[TLast] = { \
  8. [Tfnord] = "fnord", \
  9. [Tdev] = "dev", \
  10. [Tnet] = "net", \
  11. [Twork] = "work", \
  12. [Tmisc] = "misc", \
  13. };
  14. #define DEFMODE dotile /* dofloat */
  15. #define DEFTAG Tdev
  16. #define FONT "-*-terminus-medium-*-*-*-13-*-*-*-*-*-iso10646-*"
  17. #define BGCOLOR "#0a2c2d"
  18. #define FGCOLOR "#ddeeee"
  19. #define BORDERCOLOR "#176164"
  20. #define MODKEY Mod1Mask
  21. #define NUMLOCKMASK Mod2Mask
  22. #define MASTERW 60 /* percent */
  23. #define KEYS \
  24. const char *browse[] = { "firefox", NULL }; \
  25. const char *gimp[] = { "gimp", NULL }; \
  26. const char *term[] = { \
  27. "urxvt", "-tr", "+sb", "-bg", "black", "-fg", "white", "-cr", "white", \
  28. "-fn", "-*-terminus-medium-*-*-*-13-*-*-*-*-*-iso10646-*", NULL \
  29. }; \
  30. const char *xlock[] = { "xlock", NULL }; \
  31. static Key key[] = { \
  32. /* modifier key function arguments */ \
  33. { MODKEY, XK_0, view, { .i = Tfnord } }, \
  34. { MODKEY, XK_1, view, { .i = Tdev } }, \
  35. { MODKEY, XK_2, view, { .i = Tnet } }, \
  36. { MODKEY, XK_3, view, { .i = Twork } }, \
  37. { MODKEY, XK_4, view, { .i = Tmisc} }, \
  38. { MODKEY, XK_h, viewprev, { 0 } }, \
  39. { MODKEY, XK_j, focusnext, { 0 } }, \
  40. { MODKEY, XK_k, focusprev, { 0 } }, \
  41. { MODKEY, XK_l, viewnext, { 0 } }, \
  42. { MODKEY, XK_m, togglemax, { 0 } }, \
  43. { MODKEY, XK_space, togglemode, { 0 } }, \
  44. { MODKEY, XK_Return, zoom, { 0 } }, \
  45. { MODKEY|ControlMask, XK_0, appendtag, { .i = Tfnord } }, \
  46. { MODKEY|ControlMask, XK_1, appendtag, { .i = Tdev } }, \
  47. { MODKEY|ControlMask, XK_2, appendtag, { .i = Tnet } }, \
  48. { MODKEY|ControlMask, XK_3, appendtag, { .i = Twork } }, \
  49. { MODKEY|ControlMask, XK_4, appendtag, { .i = Tmisc } }, \
  50. { MODKEY|ShiftMask, XK_0, replacetag, { .i = Tfnord } }, \
  51. { MODKEY|ShiftMask, XK_1, replacetag, { .i = Tdev } }, \
  52. { MODKEY|ShiftMask, XK_2, replacetag, { .i = Tnet } }, \
  53. { MODKEY|ShiftMask, XK_3, replacetag, { .i = Twork } }, \
  54. { MODKEY|ShiftMask, XK_4, replacetag, { .i = Tmisc } }, \
  55. { MODKEY|ShiftMask, XK_c, killclient, { 0 } }, \
  56. { MODKEY|ShiftMask, XK_q, quit, { 0 } }, \
  57. { MODKEY|ShiftMask, XK_Return, spawn, { .argv = term } }, \
  58. { MODKEY|ShiftMask, XK_g, spawn, { .argv = gimp } }, \
  59. { MODKEY|ShiftMask, XK_l, spawn, { .argv = xlock } }, \
  60. { MODKEY|ShiftMask, XK_w, spawn, { .argv = browse } }, \
  61. };
  62. #define RULES \
  63. static Rule rule[] = { \
  64. /* class:instance tags isfloat */ \
  65. { "Firefox.*", { [Tnet] = "net" }, False }, \
  66. { "Gimp.*", { 0 }, True}, \
  67. { "MPlayer.*", { 0 }, True}, \
  68. { "Acroread.*", { 0 }, True}, \
  69. };