From 45697bfbb1bdd5d0c0e207ff69d2863488cec9f7 Mon Sep 17 00:00:00 2001 From: Vincent Bernat Date: Sun, 8 Jul 2012 23:06:43 +0200 Subject: [PATCH] apparance: configure the colors to be used for applets in systray See: http://thread.gmane.org/gmane.comp.window-managers.awesome/9028 --- rc/apparance.lua | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/rc/apparance.lua b/rc/apparance.lua index 25412f9..e56c484 100644 --- a/rc/apparance.lua +++ b/rc/apparance.lua @@ -38,3 +38,15 @@ gtk3:close() -- seems a bit complex to override it each time. The solution is to -- run qtconfig and to select "GTK+" for the style and the appropriate -- font. + +-- The systray is a bit complex. We need to configure it to display +-- the right colors. Here is a link with more background about this: +-- http://thread.gmane.org/gmane.comp.window-managers.awesome/9028 +xprop = assert(io.popen("xprop -root _NET_SUPPORTING_WM_CHECK")) +wid = xprop:read():match("^_NET_SUPPORTING_WM_CHECK.WINDOW.: window id # (0x[%S]+)$") +if wid then + wid = tonumber(wid) + 1 + os.execute("xprop -id " .. wid .. " -format _NET_SYSTEM_TRAY_COLORS 32c " .. + "-set _NET_SYSTEM_TRAY_COLORS " .. + "65535,65535,65535,65535,8670,8670,65535,32385,0,8670,65535,8670") +end