Why aren't very old (or very simple) apps aren't picked up by AllTray?

Created by Michael B. Trausch on on 2009-06-17
Last updated by:
Michael B. Trausch on on 2009-06-17

This FAQ applies to AllTray 0.7.3dev and later versions of AllTray.

Very old application software (or extremely simple application software written in Xlib directly or another lower-level toolkit which is not ICCCM/EWMH aware will not work with AllTray. This is because important information is not present on the application's windows, which AllTray uses to decide what to attach to the tray.

In short, AllTray can only manage application software that adheres to the EWMH standard (which itself is an enhancement to the ICCCM standard).

A more technical answer follows, useful if you are a programmer and want to make sure your application will work with AllTray:

AllTray can run in three modes: spawn mode, attach-to-PID mode, and attach-to-application mode. For all three modes, _NET_WM_PID (documented in the EWMH) must be set on the top-level windows which are created by the application. _NET_WM_PID must be a PID that (for AllTray's spawn mode) is a descendant of AllTray and contained within AllTray's process group; for any other mode, it must simply be set correctly.

For spawn mode (where the user runs "alltray PROGRAM"), AllTray will fork and exec the child process, and remember the PID. The new process is in AllTray's process group automatically. For most ("normal") applications, this child process is the program itself and _NET_WM_PID for the application will be equal to the value that AllTray received as the return value from the call to fork(). For some applications that are started with shell scripts (specifically, applications that use a shell script to initialize the environment and then start the program without using "exec"), _NET_WM_PID will be the grandchild of AllTray in the process tree. For some other applications (such as OpenOffice.org), _NET_WM_PID will be in AllTray's process group, but will no longer be AllTray's descendant because the starter script will have died and init will have already adopted the process.

For attach-to-PID mode (where the user runs "alltray -p"), the application must set _NET_WM_PID on its top-level windows so that AllTray can find it when the user has specified the PID to attach to.

For attach-to-application mode ("click mode", where the user runs "alltray -a"), the application must set _NET_WM_PID on its top-level windows so that AllTray can manage the entire application in the system tray.