2 root.buttons(awful.util.table.join(
3 awful.button({ }, 3, function () mymainmenu:toggle() end),
4 awful.button({ }, 4, awful.tag.viewnext),
5 awful.button({ }, 5, awful.tag.viewprev)
8 clientbuttons = awful.util.table.join(
9 awful.button({ }, 1, function (c) client.focus = c; c:raise() end),
10 awful.button({ modkey }, 1, awful.mouse.client.move),
11 awful.button({ modkey }, 3, awful.mouse.client.resize))
15 globalkeys = awful.util.table.join(
17 awful.key({ modkey, }, "Left", awful.tag.viewprev ),
18 awful.key({ modkey, }, "Right", awful.tag.viewnext ),
19 awful.key({ modkey, }, "Escape", awful.tag.history.restore),
21 awful.key({ modkey, }, "j",
23 awful.client.focus.byidx( 1)
24 if client.focus then client.focus:raise() end
26 awful.key({ modkey, }, "k",
28 awful.client.focus.byidx(-1)
29 if client.focus then client.focus:raise() end
31 awful.key({ modkey }, "w", function () mymainmenu:show() end),
33 -- Layout manipulation
34 awful.key({ modkey, "Shift" }, "j", function () awful.client.swap.byidx( 1) end),
35 awful.key({ modkey, "Shift" }, "k", function () awful.client.swap.byidx( -1) end),
36 awful.key({ modkey, "Control" }, "j", function () awful.screen.focus_relative( 1) end),
37 awful.key({ modkey, "Control" }, "k", function () awful.screen.focus_relative(-1) end),
38 awful.key({ modkey, }, "u", awful.client.urgent.jumpto),
39 awful.key({ modkey, }, "Tab",
41 awful.client.focus.history.previous()
48 awful.key({ modkey, }, "Return", function () awful.util.spawn(terminal) end),
49 awful.key({ modkey, "Control" }, "r", awesome.restart),
50 awful.key({ modkey, "Shift" }, "q", awesome.quit),
52 awful.key({ modkey, }, "l", function () awful.tag.incmwfact( 0.05) end),
53 awful.key({ modkey, }, "h", function () awful.tag.incmwfact(-0.05) end),
54 awful.key({ modkey, "Shift" }, "h", function () awful.tag.incnmaster( 1) end),
55 awful.key({ modkey, "Shift" }, "l", function () awful.tag.incnmaster(-1) end),
56 awful.key({ modkey, "Control" }, "h", function () awful.tag.incncol( 1) end),
57 awful.key({ modkey, "Control" }, "l", function () awful.tag.incncol(-1) end),
59 awful.key({ modkey, "Control" }, "n", awful.client.restore),
61 awful.key({ modkey }, "x",
63 awful.prompt.run({ prompt = "Run Lua code: " },
64 mypromptbox[mouse.screen].widget,
66 awful.util.getdir("cache") .. "/history_eval")
69 awful.key({ modkey }, "p", function() menubar.show() end),
74 awful.key({ modkey }, "space", function () mypromptbox[mouse.screen]:run() end),
76 awful.key({ modkey }, "]", function () awful.layout.inc(layouts, 1) end),
77 awful.key({ modkey }, "[", function () awful.layout.inc(layouts, -1) end),
79 awful.key({ }, "F13", function () awful.util.spawn("ksnapshot") end),
80 -- Layout manipulation
81 awful.key({ modkey, }, "#94", function () awful.screen.focus_relative( 1) end), -- that's the key left of 1
82 awful.key({ modkey, "Control" }, "Left", function () awful.screen.focus_relative( 1) end),
83 awful.key({ modkey, "Control" }, "Right", function () awful.screen.focus_relative(-1) end),
85 awful.key({ }, "XF86AudioRaiseVolume", function () awful.util.spawn("ponymix increase 5") end),
86 awful.key({ }, "XF86AudioLowerVolume", function () awful.util.spawn("ponymix decrease 5") end),
87 awful.key({ }, "XF86AudioMute", function () awful.util.spawn("ponymix toggle") end),
89 awful.key({ }, "XF86AudioPlay", function () awful.util.spawn("clementine -t") end),
90 awful.key({ }, "XF86AudioNext", function () awful.util.spawn("clementine -f") end),
91 awful.key({ }, "XF86AudioPrev", function () awful.util.spawn("clementine -r") end),
92 awful.key({ "Shift" }, "XF86AudioRaiseVolume", function () awful.util.spawn("clementine --volume-increase-by 5") end),
93 awful.key({ "Shift" }, "XF86AudioLowerVolume", function () awful.util.spawn("clementine --volume-decrease-by 5") end)
99 clientkeys = awful.util.table.join(
100 -- {{{ Awesome Client Keys
101 awful.key({ modkey, }, "f", function (c) c.fullscreen = not c.fullscreen end),
102 awful.key({ modkey, "Shift" }, "c", function (c) c:kill() end),
103 awful.key({ modkey, "Control" }, "space", awful.client.floating.toggle ),
104 awful.key({ modkey, "Control" }, "Return", function (c) c:swap(awful.client.getmaster()) end),
105 awful.key({ modkey, }, "n",
107 -- The client currently has the input focus, so it cannot be
108 -- minimized, since minimized clients can't have the focus.
111 awful.key({ modkey, }, "m",
113 c.maximized_horizontal = not c.maximized_horizontal
114 c.maximized_vertical = not c.maximized_vertical
118 -- {{{ My Client Keys
119 -- Move client to screen
120 awful.key({ modkey, "Shift" }, "#94", awful.client.movetoscreen ),
122 awful.key({ modkey, }, "t", function (c) c.ontop = not c.ontop end),
123 awful.key({ modkey, }, "b", function (c) c.below = not c.below end)
128 -- Bind all key numbers to tags.
129 -- Be careful: we use keycodes to make it works on any keyboard layout.
130 -- This should map on the top row of your keyboard, usually 1 to 9.
132 globalkeys = awful.util.table.join(globalkeys,
133 awful.key({ modkey }, "#" .. i + 9,
135 local screen = mouse.screen
136 local tag = awful.tag.gettags(screen)[i]
138 awful.tag.viewonly(tag)
141 awful.key({ modkey, "Control" }, "#" .. i + 9,
143 local screen = mouse.screen
144 local tag = awful.tag.gettags(screen)[i]
146 awful.tag.viewtoggle(tag)
149 awful.key({ modkey, "Shift" }, "#" .. i + 9,
151 local tag = awful.tag.gettags(client.focus.screen)[i]
152 if client.focus and tag then
153 awful.client.movetotag(tag)
156 awful.key({ modkey, "Control", "Shift" }, "#" .. i + 9,
158 local tag = awful.tag.gettags(client.focus.screen)[i]
159 if client.focus and tag then
160 awful.client.toggletag(tag)