diff --git a/luadoc/keygrabber.lua b/luadoc/keygrabber.lua index eb041f052..f7ae788ea 100644 --- a/luadoc/keygrabber.lua +++ b/luadoc/keygrabber.lua @@ -12,6 +12,23 @@ module("keygrabber") -- @param func A callback function as described above. -- @name run -- @class function +-- @usage Following function can be bound to a key, and used to resize a client +-- using keyboard. +--
+-- function resize(c)
+-- keygrabber.run(function(mod, key, event)
+-- if event == "release" then return true end
+--
+-- if key == 'Up' then awful.client.moveresize(0, 0, 0, 5, c)
+-- elseif key == 'Down' then awful.client.moveresize(0, 0, 0, -5, c)
+-- elseif key == 'Right' then awful.client.moveresize(0, 0, 5, 0, c)
+-- elseif key == 'Left' then awful.client.moveresize(0, 0, -5, 0, c)
+-- else keygrabber.stop()
+-- end
+--
+-- return true
+-- end
+--