Author: David N. Welton <firstname.lastname@example.org> State: Draft Type: Project Tcl-Version: 8.7 Vote: Pending Created: 25-Aug-2008 Post-History: Keywords: Tk, desktop integration
Modern operating systems have a "system tray", where programs may place an icon to indicate program status. This TIP proposes that Tk should adopt some existing code in order to permit cross platform access to this functionality.
Existing code is sufficient, and utilizes an acceptable license in order to repurpose it for a systray command.
To be determined by the TCT, but along the lines of what tktray provides:
tktray::icon pathName ?options?
Create a new icon for the system tray. The application managing the system tray is notified about the new icon. It normally results in the icon being added to the tray. If there is no system tray at the icon creation time, the icon will be invisible. When a new system tray appears, the icon will be added to it. Options:
-class: WM_CLASS attribute for the icon window. Tray manager may use class name to remember icon position or other attributes.
-image: image to show in the system tray. The value must be the name of a photo image. Transparency data of the photo are used to set the window's shape. The icon will be automatically redrawn or resized appropriately on any image modifications.
-visible: boolean value indicating whether the icon must be visible. The system tray manager continues to manage the icon whether it is visible or not. Thus when invisible icon becomes visible, its position on the system tray is likely to remain the same.
This document has been placed in the public domain.