libretro.api.message¶
Types that allow Cores to display notifications on the frontend’s OSD.
See also
MessageDriverThe
Protocolthat uses these types to implement notification support in libretro.py.libretro.drivers.messagelibretro.py’s included
MessageDriverimplementations.
Module Attributes
Corresponds to |
|
Corresponds to |
Classes
Where a message should be displayed. |
|
The presentation style of a message. |
|
A short-lived on-screen notification. |
|
An extended version of |
- class MessageTarget[source]¶
Bases:
IntEnumWhere a message should be displayed.
MessageDrivers can interpret these however they want.>>> from libretro.api import MessageTarget >>> MessageTarget.OSD <MessageTarget.OSD: 1>
- ALL = 0¶
- OSD = 1¶
- LOG = 2¶
- __new__(value)¶
- classmethod value in self¶
Return True if value is in cls.
value is in cls if: 1) value is a member of cls, or 2) value is the value of one of the cls’s members. 3) value is a pseudo-member (flags)
- classmethod self[name]¶
Return the member matching name.
- __init__()¶
- classmethod iter(self)¶
Return members in definition order.
- classmethod len(self)¶
Return the number of members (no aliases)
- class MessageType[source]¶
Bases:
IntEnumThe presentation style of a message.
MessageDrivers can interpret these however they want.- NOTIFICATION = 0¶
- NOTIFICATION_ALT = 1¶
- STATUS = 2¶
- PROGRESS = 3¶
- __new__(value)¶
- classmethod value in self¶
Return True if value is in cls.
value is in cls if: 1) value is a member of cls, or 2) value is the value of one of the cls’s members. 3) value is a pseudo-member (flags)
- classmethod self[name]¶
Return the member matching name.
- __init__()¶
- classmethod iter(self)¶
Return members in definition order.
- classmethod len(self)¶
Return the number of members (no aliases)
- class retro_message[source]¶
Bases:
StructureA short-lived on-screen notification.
Corresponds to
retro_messageinlibretro.h.- msg¶
Null-terminated message text to display.
- frames¶
Duration in frames to show the message.
- __deepcopy__(memodict=None)[source]¶
Return a copy of this object, including all strings. Intended for use with
copy.deepcopy().
- __init__(*args, **kwargs)¶
- classmethod __new__(*args, **kwargs)¶
- class retro_message_ext[source]¶
Bases:
StructureAn extended version of
retro_messagewith more display options.Corresponds to
retro_message_extinlibretro.h.- msg¶
Null-terminated message text to display.
- duration¶
Duration in milliseconds to show the message.
- priority¶
Priority of the message. Higher values take precedence.
- __init__(*args, **kwargs)¶
- classmethod __new__(*args, **kwargs)¶
- level¶
Log severity level of the message.
- target¶
Where the message should be displayed.
- type¶
Presentation style of the message.
- progress¶
A value from -1 to 100 representing task progress. -1 for indefinite.
Assigned values are bitwise-masked to fit into a
uint8_t.
- __deepcopy__(memodict=None)[source]¶
Return a copy of this object, including all strings. Intended for use with
copy.deepcopy().>>> import copy >>> from libretro.api import retro_message_ext >>> copy.deepcopy(retro_message_ext()).duration 0
- retro_message_target¶
Corresponds to
retro_message_targetinlibretro.h.
- retro_message_type¶
Corresponds to
retro_message_typeinlibretro.h.