Tray

Tray item displayed in system notification area.

Modulerequire("yue.gui")
TypeClass

Platform limitations:

Class methods

createwithimage(icon)

Create a tray item with icon.

Parameters

Return

Tray

createwithtitle(title) macOS

Create a tray item with only title.

Parameters

Return

Tray

Methods

settitle(title) macOS linux

Set title to be displayed aside item's icon.

Parameters

setimage(icon)

Set the icon of tray item.

Parameters

setmenu(menu)

Set the menu attached with the tray item.

On most platforms the menu will show when clicking on the icon, while on Windows the menu will only show when when right-clicking on the icon.

Parameters

getmenu()

Return the menu attached.

Return

Menu

Events

onclick(self) Windows

Emitted when the tray item is clicked.

Parameters

Preventable

No.