Change Qubes lock icon to application specific icon

171 views
Skip to first unread message

Eldad

unread,
Aug 8, 2014, 1:52:46 AM8/8/14
to qubes...@googlegroups.com
Hi ,

When I'm launching a new program in some AppVM , the program icon on the taskbar ( I'm using xfce4 ) is always the Qubes lock icon with the color of this AppVM.

Is it possible the change it so the icon will be the program specific icon?

Best Regards ,
Eldad.

Marek Marczykowski-Górecki

unread,
Aug 8, 2014, 6:23:41 AM8/8/14
to Eldad, qubes...@googlegroups.com
Currently no. GUI daemon have no knowledge which window belongs to which
application (the only hint is window title, which can vary).

--
Best Regards,
Marek Marczykowski-Górecki
Invisible Things Lab
A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?

signature.asc

eld...@gmail.com

unread,
Aug 8, 2014, 6:30:57 AM8/8/14
to qubes...@googlegroups.com, eld...@gmail.com
Thanks for the answer.

Might be a good feature for next releases.
It's very confusing that way...

Eldad.

JPL

unread,
Nov 14, 2015, 7:05:34 PM11/14/15
to qubes-users, eld...@gmail.com
Just to resurrect this old post, is there any way around this? In my opinion it is the single biggest thing affecting everyday usability in Qubes. As a workaround, I group similar things on different desktops, but it's a bit of a pain.    

Marek Marczykowski-Górecki

unread,
Nov 14, 2015, 7:51:47 PM11/14/15
to JPL, qubes-users, eld...@gmail.com
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

On Sat, Nov 14, 2015 at 04:05:34PM -0800, JPL wrote:
>
>
> On Friday, August 8, 2014 at 11:30:57 AM UTC+1, eld...@gmail.com wrote:
> >
> > On Friday, August 8, 2014 1:23:41 PM UTC+3, Marek Marczykowski-Górecki
> > wrote:
> > > On 08.08.2014 07:52, Eldad wrote:
> > >
> > > > Hi ,
> > >
> > > >
> > >
> > > > When I'm launching a new program in some AppVM , the program icon on
> > the taskbar ( I'm using xfce4 ) is always the Qubes lock icon with the
> > color of this AppVM.
> > >
> > > >
> > >
> > > > Is it possible the change it so the icon will be the program specific
> > icon?
> > >
> > >
> > >
> > > Currently no. GUI daemon have no knowledge which window belongs to which
> > >
> > > application (the only hint is window title, which can vary).
> > >
> >
> > Thanks for the answer.
> >
> > Might be a good feature for next releases.
> > It's very confusing that way...
> >
> > Eldad.
>
>
> Just to resurrect this old post, is there any way around this? In my
> opinion it is the single biggest thing affecting everyday usability in
> Qubes. As a workaround, I group similar things on different desktops, but
> it's a bit of a pain.

Good news: it is implemented and planned to be released in Qubes R3.1
https://github.com/QubesOS/qubes-issues/issues/967

- --
Best Regards,
Marek Marczykowski-Górecki
Invisible Things Lab
A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1

iQEcBAEBCAAGBQJWR9caAAoJENuP0xzK19csXtEH/3WAf84LqHPQY3n5rx4geIfr
mrmWU7tSPKhRfTFJXXiBHpRmuvsB1R1h3m26RUOKzlPfV10nFD7BKHB4tAhqATrD
J/9e0dTI9XExAyhBFIF0C7yNqc55zNkPDAwKq0M4lJEfOP+cZpynlDvAt0/c7Q53
9Gr04W4WvmKbfositveZJCQjQw+YTM4CYqgUt9uqMhs2MjWOcM38Y2fba0+8fTsU
ZmL3H69LQSl98DqgtRD7TC9UokPAlllCGfsQhGKRqkL06JhAjjq8OBta00v9nXa+
Ynk0AF8ConL3LsUnS+ydTIHuFO3rXtzBxzgaG/33SvugAAnjn/sKaHlbMbzM/rw=
=w/fK
-----END PGP SIGNATURE-----

JPL

unread,
Nov 14, 2015, 8:19:04 PM11/14/15
to qubes-users, atep...@gmail.com, eld...@gmail.com
That's great news. Thanks Marek! 

Adrian Rocha

unread,
Feb 9, 2016, 7:28:21 PM2/9/16
to qubes-users, atep...@gmail.com, eld...@gmail.com
Hi all,

This is a great feature, but I'm using Qubes 3.1 and, the most of time, the windows icons changes and returns the "lock" icon.
Is this a known bug?
Is there any log that can I look to understand the problem?

Regards

Marek Marczykowski-Górecki

unread,
Feb 9, 2016, 7:55:54 PM2/9/16
to Adrian Rocha, qubes-users, atep...@gmail.com, eld...@gmail.com
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

There is a race condition, sometimes preventing icon being set:
https://github.com/QubesOS/qubes-issues/issues/1495

- --
Best Regards,
Marek Marczykowski-Górecki
Invisible Things Lab
A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2

iQEcBAEBCAAGBQJWuoqRAAoJENuP0xzK19csqjIH/An9TdFzVm0IY4V6T66AQdzL
qHJHbyprHbvX8p5b+rxJerBXMyFNKlxX2DvZZcn9tFFImWq3vgaE9AJwGQPL1WxJ
2o2VpPXe3UrTtbjMlx3ErSojjtAsgsiLBzKq3yiB265vfgQS0gMIqu1MOQaBnqgO
nzq4UF1ABxIQWX0ZIGkqtHOVxSYrWUe6LCIwQxAm2+0l5QN6/SAcCCs8j5g230Dv
Y5ZUzvR1sceS0yIGc3S3rzLL9xf+mHO+SGyZXO9VQnRZgfRZqRjqsswYTESRNYG/
h9tvt9AsFhlFPr1NzsgD4FDZOyFWAbN4a1NifMoDHmiV+3SloPGKZvWyI867RVs=
=bB4U
-----END PGP SIGNATURE-----

Adrian Rocha

unread,
Feb 11, 2016, 7:39:26 PM2/11/16
to qubes-users, adrian....@gmail.com, atep...@gmail.com, eld...@gmail.com
Thanks Marek,

I reviewed the icon-sender and icon-receiver, but I cannot understand how it works yet. I'd like to help but I'm relatively new in Qubes, and in Python too.

Best Regards

Marek Marczykowski-Górecki

unread,
Feb 11, 2016, 8:11:03 PM2/11/16
to Adrian Rocha, qubes-users, atep...@gmail.com, eld...@gmail.com
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

In short:
1. When the icon is received but no matching window exists, it is
discarded. That part of code is here:
https://github.com/QubesOS/qubes-gui-daemon/blob/master/window-icon-updater/icon-receiver#L319-L324

2. Instead of discarding it should be cached for a short time, and then
when new window appears icon from cache should be applied (if there is
one). This part require watching for "CreateNotifyEvent", which isn't
currently done. Instead X11 events are handled only when searching for
some window:
https://github.com/QubesOS/qubes-gui-daemon/blob/master/window-icon-updater/icon-receiver#L235

Watching for such events is implemented on the sender part here:
https://github.com/QubesOS/qubes-gui-agent-linux/blob/master/window-icon-updater/icon-sender#L134-L143

3. The icon cache should be done with security in mind, for example to
not allow any VM use all dom0 memory. I think limiting its size to for
example last 10 icons should be enough.


Not sure if that is enough to implement this change, probably some
knowledge of X11 protocol is required... Anyway I'll paste above
information into that ticket, for whoever will work on this.

- --
Best Regards,
Marek Marczykowski-Górecki
Invisible Things Lab
A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2

iQEcBAEBCAAGBQJWvTEdAAoJENuP0xzK19cs/HYIAIQjDfmyp8o6lwJ2Shl1okQi
FXRcRWWQqrQekGchDS/0LEuRKYEbHnyYOBiW8J+iwanJwflJupBszrgV15CHRQyb
7wOiIuCtqn8WZzqNamFsXNHh+4kEpzvvEn+WaTHwjwKD7iWZPN4p1Bm6W9SDOn8t
ud+r9NFifyPaEM07VYqbslFmkMWepQkUi5gVFrKNXghgiDaV5OKZQsVqF5vsuiEk
SlJbe0Hd/xdBPNl8hHl7ANQEKCfNONbed698NobRAsHkplBzGu/Ecx90JQ/XDFMe
5bvIXRD3X3ggWJD9GCMoL7x5YmcsodDAgC2tlOxmFcpo7ptyGNipuyqGpbToFT8=
=3L5e
-----END PGP SIGNATURE-----
Reply all
Reply to author
Forward
0 new messages