pytauri.ffi.tray
¶
Classes:
Name | Description |
---|---|
TrayIcon |
|
TrayIconEvent |
|
MouseButton |
|
MouseButtonState |
Attributes:
Name | Type | Description |
---|---|---|
TrayIconId |
||
TrayIconEventType |
See TrayIconEvent for details. |
__all__
module-attribute
¶
__all__ = ['MouseButton', 'MouseButtonState', 'TrayIcon', 'TrayIconEvent', 'TrayIconEventType', 'TrayIconId']
TrayIconEventType
module-attribute
¶
TrayIconEventType = TypeAliasType('TrayIconEventType', Union[Click, DoubleClick, Enter, Move, Leave, _NonExhaustive])
See TrayIconEvent for details.
TrayIcon
¶
Methods:
Name | Description |
---|---|
__new__ |
|
with_id |
|
app_handle |
|
on_menu_event |
This is an alias for pytauri.ffi.AppHandle.on_menu_event. |
on_tray_icon_event |
Set a handler for this tray icon events. |
id |
|
set_icon |
|
set_menu |
|
set_tooltip |
|
set_title |
|
set_visible |
|
set_temp_dir_path |
|
set_icon_as_template |
|
set_show_menu_on_left_click |
|
rect |
|
__new__
¶
__new__(manager: ImplManager) -> Self
Source code in python/pytauri/src/pytauri/ffi/tray.py
with_id
staticmethod
¶
with_id(manager: ImplManager, id: TrayIconId) -> TrayIcon
on_menu_event
¶
on_tray_icon_event
¶
on_tray_icon_event(handler: Callable[[Self, TrayIconEventType], None]) -> None
Set a handler for this tray icon events.
Warning
handler
has the same restrictions as App.run.
Source code in python/pytauri/src/pytauri/ffi/tray.py
set_icon
¶
Source code in python/pytauri/src/pytauri/ffi/tray.py
set_menu
¶
set_menu(menu: Optional[ImplContextMenu]) -> None
Source code in python/pytauri/src/pytauri/ffi/tray.py
set_tooltip
¶
Source code in python/pytauri/src/pytauri/ffi/tray.py
set_title
¶
Source code in python/pytauri/src/pytauri/ffi/tray.py
set_visible
¶
set_visible(visible: bool) -> None
Source code in python/pytauri/src/pytauri/ffi/tray.py
set_temp_dir_path
¶
set_temp_dir_path(path: Optional[Pyo3Path]) -> None
Source code in python/pytauri/src/pytauri/ffi/tray.py
set_icon_as_template
¶
set_icon_as_template(is_template: bool) -> None
Source code in python/pytauri/src/pytauri/ffi/tray.py
TrayIconEvent
¶
Classes:
Name | Description |
---|---|
Click |
|
DoubleClick |
|
Enter |
|
Move |
|
Leave |
Click
¶
tauri::tray::TrayIconEvent::Click
Attributes:
Name | Type | Description |
---|---|---|
id |
TrayIconId
|
|
position |
_PhysicalPositionF64
|
|
rect |
Rect
|
|
button |
MouseButton
|
|
button_state |
MouseButtonState
|
|
DoubleClick
¶
tauri::tray::TrayIconEvent::DoubleClick
Attributes:
Name | Type | Description |
---|---|---|
id |
TrayIconId
|
|
position |
_PhysicalPositionF64
|
|
rect |
Rect
|
|
button |
MouseButton
|
|
Enter
¶
tauri::tray::TrayIconEvent::Enter
Attributes:
Name | Type | Description |
---|---|---|
id |
TrayIconId
|
|
position |
_PhysicalPositionF64
|
|
rect |
Rect
|
|
Move
¶
tauri::tray::TrayIconEvent::Move
Attributes:
Name | Type | Description |
---|---|---|
id |
TrayIconId
|
|
position |
_PhysicalPositionF64
|
|
rect |
Rect
|
|
Leave
¶
tauri::tray::TrayIconEvent::Leave
Attributes:
Name | Type | Description |
---|---|---|
id |
TrayIconId
|
|
position |
_PhysicalPositionF64
|
|
rect |
Rect
|
|