Hi folks,
I'm attempting to learn more about Lua and Awesome, and have come across
something I just don't understand. (It's possibly a bug in Shifty, which I'm
also using, not sure.)
For the record, I'm using awesome 3.4.9 and shifty from shifty-master at
git.mercenariesguild.net.
I have the following in a file called tags-client.lua, which is read by
rc.lua:
shifty.config.apps = {
{ match = { "" },
tag = "[0]",
float = true,
buttons =
{
button({ }, 1, function (c) c:raise() end),
button({ modkey }, 1, function (c) awful.mouse.client.move()
end),
button({ modkey }, 3, function (c) awful.mouse.client.resize()
end),
},
...etc.
The mappings for modkey+1 and modkey+3 are working fine, but just button 1
isn't raising the client. Instead, I get this when I click on a client:
W: awesome: luaA_dofunction:108: error while running function
stack traceback:
/home/pete/.config/awesome/tags-clients.lua:67: in function
</home/pete/.config/awesome/tags-clients.lua:67>
error: /home/pete/.config/awesome/tags-clients.lua:67: attempt to call method
'raise' (a nil value)
To try to figure this out, I swapped out
button({ }, 1, function (c) client.focus = c; c:raise() end),
for
button({ }, 1, function (c) print(c) end),
and strangely I get these:
button: 0x22d46d8
button: 0x22d46d8
button: 0x22d46d8
(The button reference is the same regardless of which client I click on.)
Should these c's not be the client objects instead? This is the way it works
will all other instances of function(c) in my configs.
Thanks,
Pete.
--
To unsubscribe, send mail to [email protected].