docs: apply simplified technical english across docs and docstrings.

This commit is contained in:
imSp4rky
2026-08-19 16:31:06 -06:00
parent 4177cb2267
commit 66971230c3
135 changed files with 2651 additions and 2570 deletions
+7 -7
View File
@@ -31,10 +31,10 @@ class Events:
Parameters:
event_type: The Events.Type to subscribe to.
callback: The function or lambda to call on event emit.
ephemeral: Unsubscribe the callback from the event on first emit.
Note that this is not thread-safe and may be called multiple
times at roughly the same time.
callback: The function or lambda to call when `emit()` sends the event.
ephemeral: Unsubscribe the callback from the event at the first `emit()` call.
Note that this is not thread-safe, so unshackle can call the
callback several times at roughly the same time.
"""
[self.__subscriptions, self.__ephemeral][ephemeral][event_type].append(callback)
@@ -44,7 +44,7 @@ class Events:
Parameters:
event_type: The Events.Type to unsubscribe from.
callback: The function or lambda to remove from event emit.
callback: The function or lambda to remove from the `emit()` callbacks.
"""
if callback in self.__subscriptions[event_type]:
self.__subscriptions[event_type].remove(callback)
@@ -53,10 +53,10 @@ class Events:
def emit(self, event_type: Events.Types, *args: Any, **kwargs: Any) -> None:
"""
Emit an Event, executing all subscribed Callbacks.
Send an Event to all subscribed Callbacks.
Parameters:
event_type: The Events.Type to emit.
event_type: The Events.Type to send.
args: Positional arguments to pass to callbacks.
kwargs: Keyword arguments to pass to callbacks.
"""