pub fn status_item(
id: &str,
build: impl Fn() -> StatusItem + 'static,
) -> StatusItemHandleExpand description
Show a status item (docs/status-item.md): an icon in the macOS menu bar, the Windows
notification area, or a Linux tray. build runs now and again whenever a signal it reads
changes, so a timer’s title or a “Pause sync” check mark follows the app’s state. id names
the item; showing a second item with the same id replaces the first.
An app with a status item keeps running when its last window closes (KeepRunning:: Automatic, docs/windows.md); its menu should offer a way to quit. Probe
capability(Cap::StatusItem): a phone and the web show nothing, and on Linux the item needs a
running tray host, which stock GNOME lacks.