diff --git a/client.c b/client.c index f0cf24ad..7ba8af0c 100644 --- a/client.c +++ b/client.c @@ -1366,6 +1366,7 @@ luaA_client_newindex(lua_State *L) * \return The number of elements pushed on stack. * \luastack * \lfield name The client title. + * \lfield type The window type (desktop, normal, dock, …). * \lfield class The client class. * \lfield instance The client instance. * \lfield pid The client PID, if available. @@ -1411,6 +1412,26 @@ luaA_client_index(lua_State *L) case A_TK_NAME: lua_pushstring(L, (*c)->name); break; + case A_TK_TYPE: + switch((*c)->type) + { + case WINDOW_TYPE_DESKTOP: + lua_pushliteral(L, "desktop"); + break; + case WINDOW_TYPE_DOCK: + lua_pushliteral(L, "dock"); + break; + case WINDOW_TYPE_SPLASH: + lua_pushliteral(L, "splash"); + break; + case WINDOW_TYPE_DIALOG: + lua_pushliteral(L, "dialog"); + break; + default: + lua_pushliteral(L, "normal"); + break; + } + break; case A_TK_CLASS: if(!xcb_get_wm_class_reply(globalconf.connection, xcb_get_wm_class_unchecked(globalconf.connection, (*c)->win), diff --git a/common/tokenize.gperf b/common/tokenize.gperf index faa4e8b2..8e504e9a 100644 --- a/common/tokenize.gperf +++ b/common/tokenize.gperf @@ -64,6 +64,7 @@ top topleft topright true +type urgent visible vertical