xpra icon
Bug tracker and wiki

Opened 8 years ago

Closed 6 years ago

Last modified 6 years ago

#77 closed enhancement (fixed)

missing tray icons - forward notification area

Reported by: ammoled Owned by: Antoine Martin
Priority: minor Milestone: 0.8
Component: client Version:
Keywords: Cc:

Description

XPRA does not display the tray icons of attached applications such as xchat.

Attachments (7)

tray-area.patch (5.5 KB) - added by Antoine Martin 7 years ago.
adds a hardcoded area for tray icons to dock into - ugly hack for now
tray-area-v2.patch (12.8 KB) - added by Antoine Martin 7 years ago.
much more complete implementation
tray-area-v3.patch (25.0 KB) - added by Antoine Martin 7 years ago.
we can almost click on the forwarded icon too
tray-area-v4.patch (34.4 KB) - added by Antoine Martin 7 years ago.
updated patch for r2088
tray-area-v5.patch (49.1 KB) - added by Antoine Martin 7 years ago.
updated patch with cleanups
tray-area-v6.patch (50.4 KB) - added by Antoine Martin 7 years ago.
work on transparency
window-backing-depth.patch (2.7 KB) - added by Antoine Martin 7 years ago.
adds the ability to handle 32-bit window backing

Download all attachments as: .zip

Change History (21)

comment:1 Changed 8 years ago by Antoine Martin

Milestone: currentfuture
Owner: changed from Antoine Martin to Antoine Martin
Status: newaccepted

and it may never do

comment:2 Changed 8 years ago by Antoine Martin

This is a very difficult problem to solve - I am not even sure it can be solved:

  • there are at least two main implementations of "tray icons" on *nix: gtk's "StatusIcon" and Ubuntu's "appindicator" (see #43 for an example of how much of a mess it is to try to support them all)
  • none of these support overriding at present (and afaik none use dbus..), so the code would have duplicated in each case

Pointers welcome.

comment:3 Changed 8 years ago by Antoine Martin

Looks like I was wrong about them not using dbus, so we may be able to do something after all (as was done for #22), some more pointers:

comment:4 Changed 8 years ago by Antoine Martin

Or even by implementing the raw X11 specification: docking a tray icon - although this is probably more difficult (we would need a fake area to dock into then we need to implement XEmbed).

Last edited 7 years ago by Antoine Martin (previous) (diff)

comment:5 Changed 7 years ago by Antoine Martin

Summary: Missing Tray Iconsmissing tray icons - forward notification area
Type: defectenhancement

comment:6 Changed 7 years ago by Antoine Martin

comment:3 is wrong about being wrong about dbus (..): the spec does not use dbus, and most apps will not use a dbus interface either, so we must implement the docking tray icon spec directly.

Found pypanel which may serve as a good base for implementing our own tray icon forwarding code.

Changed 7 years ago by Antoine Martin

Attachment: tray-area.patch added

adds a hardcoded area for tray icons to dock into - ugly hack for now

Changed 7 years ago by Antoine Martin

Attachment: tray-area-v2.patch added

much more complete implementation

Changed 7 years ago by Antoine Martin

Attachment: tray-area-v3.patch added

we can almost click on the forwarded icon too

Changed 7 years ago by Antoine Martin

Attachment: tray-area-v4.patch added

updated patch for r2088

Changed 7 years ago by Antoine Martin

Attachment: tray-area-v5.patch added

updated patch with cleanups

Changed 7 years ago by Antoine Martin

Attachment: tray-area-v6.patch added

work on transparency

comment:7 Changed 7 years ago by Antoine Martin

  • r2094 adds the server-side part
  • r2097 adds the client-side part

It is mostly working as it is, but with some limitations we should address:

  • missing transparency: we set _NET_SYSTEM_TRAY_VISUAL to the 32-bit visual - but somehow the docking requests we receive are for 24-bit visual windows, not sure why.
  • gtk.StatusIcon only gives us two events for mouse clicks: activate and popup-menu so we end up simulating a button press and release on the remote tray area. By implementing the system tray using raw X11 calls we ought to be able to get more useful events to forward, the win32 implementation can probably supply the same too in OnTaskbarNotify. We can then use the StatusIcon version as fallback for platforms without native support (ie: osx or pure-python builds).
  • we should avoid the round-trip via a pixmap backing to get the pixbuf
  • detect when we lose the tray selection and cleanup
  • support balloon messages
Last edited 7 years ago by Antoine Martin (previous) (diff)

Changed 7 years ago by Antoine Martin

Attachment: window-backing-depth.patch added

adds the ability to handle 32-bit window backing

comment:8 Changed 7 years ago by Antoine Martin

We probably also need to split this code into a separate executable so that we can exit/upgrade xpra without losing the trays.

comment:9 Changed 7 years ago by Antoine Martin

For transparency, see #279

comment:10 Changed 7 years ago by Antoine Martin

transparency fixed in r3475 for *nix

comment:11 Changed 6 years ago by Antoine Martin

Status: acceptednew

Works well enough.

comment:12 Changed 6 years ago by Antoine Martin

Resolution: fixed
Status: newclosed

comment:13 Changed 6 years ago by Antoine Martin

win32 native code in use as of r4640 - which allows us to do things other implementations cannot do: hovering events, etc

comment:14 Changed 6 years ago by Antoine Martin

Milestone: future0.8
Version: 0.0.7.22

(setting correct milestone the work was completed in)

Note: See TracTickets for help on using tickets.