File tree Expand file tree Collapse file tree 4 files changed +15
-2
lines changed
Expand file tree Collapse file tree 4 files changed +15
-2
lines changed Original file line number Diff line number Diff line change 292292 " truetype" ,
293293 " undoc" ,
294294 " Unifont" ,
295+ " unraisablehook" ,
295296 " upscaling" ,
296297 " VAFUNC" ,
297298 " vcoef" ,
Original file line number Diff line number Diff line change @@ -4,6 +4,12 @@ Changes relevant to the users of python-tcod are documented here.
44This project adheres to [ Semantic Versioning] ( https://semver.org/ ) since version ` 2.0.0 ` .
55
66## [ Unreleased]
7+ ### Added
8+ - Adds ` sdl_window ` and ` sdl_renderer ` to tcod contexts.
9+ - Adds ` tcod.event.add_watch ` and ` tcod.event.remove_watch ` to handle SDL events via callback.
10+ - Adds the ` tcod.sdl.video ` module to handle SDL windows.
11+ - Adds the ` tcod.sdl.render ` module to handle SDL renderers.
12+ - Adds the ` tcod.render ` module which gives more control over the rendering of consoles and tilesets.
713### Fixed
814- Fixed handling of non-Path PathLike parameters and filepath encodings.
915
Original file line number Diff line number Diff line change @@ -355,7 +355,7 @@ def toggle_fullscreen(context: tcod.context.Context) -> None:
355355
356356 @property
357357 def sdl_window (self ) -> Optional [tcod .sdl .video .Window ]:
358- """Return a tcod.sdl.video.Window referencing this contexts SDL window if it exists.
358+ """Return a :any:` tcod.sdl.video.Window` referencing this contexts SDL window if it exists.
359359
360360 .. versionadded:: 13.4
361361 """
@@ -364,7 +364,7 @@ def sdl_window(self) -> Optional[tcod.sdl.video.Window]:
364364
365365 @property
366366 def sdl_renderer (self ) -> Optional [tcod .sdl .render .Renderer ]:
367- """Return a tcod.sdl.render.Renderer referencing this contexts SDL renderer if it exists.
367+ """Return a :any:` tcod.sdl.render.Renderer` referencing this contexts SDL renderer if it exists.
368368
369369 .. versionadded:: 13.4
370370 """
Original file line number Diff line number Diff line change @@ -1089,6 +1089,10 @@ def add_watch(callback: _EventCallback) -> _EventCallback:
10891089
10901090 Callbacks added as event watchers can later be removed with :any:`tcod.event.remove_watch`.
10911091
1092+ .. warning::
1093+ How uncaught exceptions in a callback are handled is not currently defined by tcod.
1094+ They will likely be handled by :any:`sys.unraisablehook`.
1095+
10921096 Args:
10931097 callback (Callable[[Event], None]):
10941098 A function which accepts :any:`Event` parameters.
@@ -2303,6 +2307,8 @@ def __repr__(self) -> str:
23032307 "get" ,
23042308 "wait" ,
23052309 "get_mouse_state" ,
2310+ "add_watch" ,
2311+ "remove_watch" ,
23062312 "EventDispatch" ,
23072313 "get_keyboard_state" ,
23082314 "get_modifier_state" ,
You can’t perform that action at this time.
0 commit comments