Hi!
In a GNOME Flashback session using Metacity, which component, process or daemon is responsible for setting the inital application icon that appears in the taskbar & the Alt-Tab
app switcher, and/or change/modify it during the application’s runtime (if it’s not done by the application itself)?
Here’s some background information for this admittedly rather strange question.
In gnome-terminal
, I have a profile called “Mutt”, which sets the initial terminal title to “Mutt” and starts, well, mutt
, and another profile called “Slrn”, which sets the initial terminal title to “Slrn” and starts, you guessed it, slrn
. After login, I always start a separate gnome-terminal
window with the “Mutt” profile, and a second tab in that window with the “Slrn” profile.
In addition to that, I also have a little “daemon” (it’s actually just a backgrounded #!/bin/bash
script) started on login, which waits for a window titled “Mutt” or “Slrn” to appear using xdotool
, and then sets a special icon (one for “Mutt”, another one for “Slrn”) for that windows using xseticon
. If the window title changes from “Mutt” to “Slrn” or vice versa, the “daemon” changes the window icon accordingly. This “daemon” keeps running as long as gnome-session-binary
appears in ps
, and then quits. So if I switch back and forth between the “Mutt” and “Slrn” tabs, the icon shown in the taskbar and the Alt-Tab
app switcher changes accordingly, and shows which one of the two is currently active. And if I logout of my session, the “daemon” terminates as well.
So far, so good, all of this works actually fine … BUT.
Every now and then, in irregular intervals, not following any special “desktop actions” or other patterns that I would be aware of, the icon of that particular window gets reset to the normal gnome-terminal
application icon, and loses its special “Mutt” or “Slrn” icon that was set by the “daemon”. I can immediately get the special icon back if I click into that window and switch tabs from “Mutt” to “Slrn” or vice versa, and then that special icon stays again … until, at some random time, by some unknown (to me) process and for some unknown (to me) reason, it gets reset to the default gnome-terminal
app icon again. Rinse, repeat.
So I would like to be able to identify this particular component of the GNOME Flashback session that keeps doing this, and understand why, how, and when it does that, so I can possibly find a workaround that makes the special icon for my “Mutt”/“Slrn” window permanent.
Yes, I know, I could simply set the special icon every 0,5 seconds or so as long as the daemon “sees” the matching window title, but I’d rather only change the icon when I actually switch tabs.
I can also show you the “daemon” script if necessary, but I don’t think the root cause is in there. There’s nothing in it that would set the icon to gnome-terminal
’s default app icon on any window.
Can anybody help me with this, and point me into the right direction? I would really appreciate that. Thanks!