Configuration file for DWM on MacBook Air
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.

148 lines
4.5 KiB

16 years ago
  1. /* See LICENSE file for copyright and license details. */
  2. /* appearance */
  3. #define BORDERPX 1
  4. #define FONT "-*-terminus-medium-r-normal-*-14-*-*-*-*-*-*-*"
  5. #define NORMBORDERCOLOR "#cccccc"
  6. #define NORMBGCOLOR "#cccccc"
  7. #define NORMFGCOLOR "#000000"
  8. #define SELBORDERCOLOR "#0066ff"
  9. #define SELBGCOLOR "#0066ff"
  10. #define SELFGCOLOR "#ffffff"
  11. #if ANSELM_OFFICE
  12. /* bar position */
  13. #define BX 0
  14. #define BY 0
  15. #define BW 1280
  16. /* master area */
  17. #define MX 0
  18. #define MY bh
  19. #define MW 1280
  20. #define MH 800 - bh
  21. /* tile area, might be on a different screen */
  22. #define TX 1280
  23. #define TY 0
  24. #define TW 1680
  25. #define TH 1050
  26. /* monocle area, might be restricted to a specific screen */
  27. #define MOX MX
  28. #define MOY MY
  29. #define MOW MW
  30. #define MOH MH
  31. #else
  32. /* bar position */
  33. #define BX sx
  34. #define BY sy
  35. #define BW sw
  36. /* master area */
  37. #define MX sx
  38. #define MY sy + bh
  39. #define MW ((int)(((float)sw) * 0.6))
  40. #define MH sh - bh
  41. /* tile area, might be on a different screen */
  42. #define TX sx + MW
  43. #define TY MY
  44. #define TW sw - MW
  45. #define TH MH
  46. /* monocle area, might be restricted to a specific screen */
  47. #define MOX sx
  48. #define MOY MY
  49. #define MOW sw
  50. #define MOH MH
  51. #endif
  52. /* tagging */
  53. const char tags[][MAXTAGLEN] = { "1", "2", "3", "4", "5", "6", "7", "8", "9" };
  54. Rule rules[] = {
  55. /* class:instance:title substr tags ref isfloating */
  56. { "Firefox", tags[8], False },
  57. { "Gimp", NULL, True },
  58. { "MPlayer", NULL, True },
  59. { "Acroread", NULL, True },
  60. };
  61. /* layout(s) */
  62. #define RESIZEHINTS True /* False - respect size hints in tiled resizals */
  63. #define SNAP 32 /* snap pixel */
  64. Layout layouts[] = {
  65. /* symbol function */
  66. { "[]=", tile }, /* first entry is default */
  67. { "><>", floating },
  68. { "[M]", monocle },
  69. };
  70. /* key definitions */
  71. #define MODKEY Mod1Mask
  72. Key keys[] = {
  73. /* modifier key function argument */
  74. #if ANSELM_OFFICE
  75. { MODKEY, XK_p, spawn,
  76. "exec dmenu_run -fn '"FONT"' -nb '"NORMBGCOLOR"' -nf '"NORMFGCOLOR"' -sb '"SELBGCOLOR"' -sf '"SELFGCOLOR"' -x 0 -y 0 -w 1280" },
  77. #else
  78. { MODKEY, XK_p, spawn,
  79. "exec dmenu_run -fn '"FONT"' -nb '"NORMBGCOLOR"' -nf '"NORMFGCOLOR"' -sb '"SELBGCOLOR"' -sf '"SELFGCOLOR"'" },
  80. #endif
  81. { MODKEY|ShiftMask, XK_Return, spawn, "exec uxterm" },
  82. { MODKEY, XK_j, focusnext, NULL },
  83. { MODKEY, XK_k, focusprev, NULL },
  84. { MODKEY, XK_r, reapply, NULL },
  85. { MODKEY, XK_Return, zoom, NULL },
  86. { MODKEY, XK_Tab, viewprevtag, NULL },
  87. { MODKEY, XK_m, setlayout, "[M]" },
  88. { MODKEY, XK_f, setlayout, "><>" },
  89. { MODKEY, XK_t, setlayout, "[]=" },
  90. { MODKEY|ShiftMask, XK_space, togglefloating, NULL },
  91. { MODKEY|ShiftMask, XK_c, killclient, NULL },
  92. { MODKEY, XK_0, view, NULL },
  93. { MODKEY, XK_1, view, tags[0] },
  94. { MODKEY, XK_2, view, tags[1] },
  95. { MODKEY, XK_3, view, tags[2] },
  96. { MODKEY, XK_4, view, tags[3] },
  97. { MODKEY, XK_5, view, tags[4] },
  98. { MODKEY, XK_6, view, tags[5] },
  99. { MODKEY, XK_7, view, tags[6] },
  100. { MODKEY, XK_8, view, tags[7] },
  101. { MODKEY, XK_9, view, tags[8] },
  102. { MODKEY|ControlMask, XK_1, toggleview, tags[0] },
  103. { MODKEY|ControlMask, XK_2, toggleview, tags[1] },
  104. { MODKEY|ControlMask, XK_3, toggleview, tags[2] },
  105. { MODKEY|ControlMask, XK_4, toggleview, tags[3] },
  106. { MODKEY|ControlMask, XK_5, toggleview, tags[4] },
  107. { MODKEY|ControlMask, XK_6, toggleview, tags[5] },
  108. { MODKEY|ControlMask, XK_7, toggleview, tags[6] },
  109. { MODKEY|ControlMask, XK_8, toggleview, tags[7] },
  110. { MODKEY|ControlMask, XK_9, toggleview, tags[8] },
  111. { MODKEY|ShiftMask, XK_0, tag, NULL },
  112. { MODKEY|ShiftMask, XK_1, tag, tags[0] },
  113. { MODKEY|ShiftMask, XK_2, tag, tags[1] },
  114. { MODKEY|ShiftMask, XK_3, tag, tags[2] },
  115. { MODKEY|ShiftMask, XK_4, tag, tags[3] },
  116. { MODKEY|ShiftMask, XK_5, tag, tags[4] },
  117. { MODKEY|ShiftMask, XK_6, tag, tags[5] },
  118. { MODKEY|ShiftMask, XK_7, tag, tags[6] },
  119. { MODKEY|ShiftMask, XK_8, tag, tags[7] },
  120. { MODKEY|ShiftMask, XK_9, tag, tags[8] },
  121. { MODKEY|ControlMask|ShiftMask, XK_1, toggletag, tags[0] },
  122. { MODKEY|ControlMask|ShiftMask, XK_2, toggletag, tags[1] },
  123. { MODKEY|ControlMask|ShiftMask, XK_3, toggletag, tags[2] },
  124. { MODKEY|ControlMask|ShiftMask, XK_4, toggletag, tags[3] },
  125. { MODKEY|ControlMask|ShiftMask, XK_5, toggletag, tags[4] },
  126. { MODKEY|ControlMask|ShiftMask, XK_6, toggletag, tags[5] },
  127. { MODKEY|ControlMask|ShiftMask, XK_7, toggletag, tags[6] },
  128. { MODKEY|ControlMask|ShiftMask, XK_8, toggletag, tags[7] },
  129. { MODKEY|ControlMask|ShiftMask, XK_9, toggletag, tags[8] },
  130. { MODKEY|ShiftMask, XK_q, quit, NULL },
  131. };