diff --git a/lib/awful/client.lua.in b/lib/awful/client.lua.in index 5e236247e..8224ea3c4 100644 --- a/lib/awful/client.lua.in +++ b/lib/awful/client.lua.in @@ -897,6 +897,38 @@ function iterate(filter, start, s) return util.table.iterate(clients, filter, start) end +--- +--
Switch to a client matching the given condition if running, else spawn it. +-- If multiple clients match the given condition then the next one is +-- focussed.
+-- +-- @param cmd the command to execute +-- @param matcher a function that returns true to indicate a matching client +-- @param merge if true then merge tags when clients are not visible +-- +-- @usage run or raise urxvt (perhaps, with tabs) on modkey + semicolon +--
+-- awful.key({ modkey, }, 'semicolon', function ()
+-- local matcher = function (c)
+-- return awful.rules.match(c, {class = 'URxvt'})
+-- end
+-- awful.client.run_or_raise('urxvt', matcher)
+-- end);
+--