tcod 19.3.1__tar.gz → 19.4.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {tcod-19.3.1 → tcod-19.4.0}/CHANGELOG.md +14 -0
- {tcod-19.3.1 → tcod-19.4.0}/PKG-INFO +1 -1
- {tcod-19.3.1 → tcod-19.4.0}/tcod/event.py +34 -23
- {tcod-19.3.1 → tcod-19.4.0}/tcod/version.py +2 -2
- {tcod-19.3.1 → tcod-19.4.0}/tcod.egg-info/PKG-INFO +1 -1
- {tcod-19.3.1 → tcod-19.4.0}/CONTRIBUTING.md +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/LICENSE.txt +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/MANIFEST.in +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/README.rst +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/build_libtcod.py +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/build_sdl.py +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/CHANGELOG.md +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/CMakeLists.txt +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/CONTRIBUTING.md +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/LIBTCOD-CREDITS.txt +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/LICENSE.txt +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/README.md +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/bresenham.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/bresenham_c.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/bsp.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/bsp_c.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/color.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/color.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/config.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/console.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/console.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/console_drawing.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/console_drawing.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/console_etc.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/console_etc.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/console_init.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/console_init.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/console_printing.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/console_printing.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/console_rexpaint.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/console_rexpaint.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/console_types.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/context.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/context.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/context_init.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/context_init.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/context_viewport.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/context_viewport.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/error.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/error.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/fov.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/fov_c.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/fov_circular_raycasting.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/fov_diamond_raycasting.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/fov_permissive2.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/fov_recursive_shadowcasting.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/fov_restrictive.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/fov_symmetric_shadowcast.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/fov_types.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/globals.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/globals.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/heapq.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/heapq.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/heightmap.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/heightmap_c.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/image.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/image_c.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/lex.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/lex_c.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/libtcod.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/libtcod_int.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/list.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/list_c.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/logging.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/logging.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/mersenne.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/mersenne_c.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/mersenne_types.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/mouse.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/mouse_types.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/namegen.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/namegen_c.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/noise.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/noise_c.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/noise_defaults.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/parser.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/parser_c.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/path.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/path_c.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/pathfinder.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/pathfinder.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/pathfinder_frontier.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/pathfinder_frontier.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/portability.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/random.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/random.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/renderer_sdl2.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/renderer_sdl2.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/renderer_xterm.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/renderer_xterm.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/sdl2/console_grid.glslf +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/sdl2/console_grid.glslv +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/sdl2/event.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/sys.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/sys_c.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/sys_sdl_c.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/sys_sdl_img_bmp.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/sys_sdl_img_png.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/tileset.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/tileset.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/tileset_bdf.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/tileset_bdf.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/tileset_fallback.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/tileset_fallback.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/tileset_render.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/tileset_render.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/tileset_truetype.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/tileset_truetype.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/timer.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/tree.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/tree_c.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/txtfield.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/txtfield_c.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/utility.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/version.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/wrappers.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/wrappers.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/zip.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod/zip_c.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/libtcod_c.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/vendor/khrplatform.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/vendor/lodepng.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/vendor/lodepng.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/vendor/stb.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/vendor/stb_ds.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/vendor/stb_truetype.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/vendor/utf8proc/utf8proc.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/vendor/utf8proc/utf8proc.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/vendor/utf8proc/utf8proc_data.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/vendor/zlib/adler32.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/vendor/zlib/compress.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/vendor/zlib/crc32.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/vendor/zlib/crc32.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/vendor/zlib/deflate.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/vendor/zlib/deflate.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/vendor/zlib/gzclose.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/vendor/zlib/gzguts.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/vendor/zlib/gzlib.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/vendor/zlib/gzread.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/vendor/zlib/gzwrite.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/vendor/zlib/infback.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/vendor/zlib/inffast.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/vendor/zlib/inffast.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/vendor/zlib/inffixed.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/vendor/zlib/inflate.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/vendor/zlib/inflate.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/vendor/zlib/inftrees.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/vendor/zlib/inftrees.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/vendor/zlib/trees.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/vendor/zlib/trees.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/vendor/zlib/uncompr.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/vendor/zlib/zconf.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/vendor/zlib/zlib.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/vendor/zlib/zutil.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcod/src/vendor/zlib/zutil.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/libtcodpy.py +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/pyproject.toml +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/requirements.txt +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/setup.cfg +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/setup.py +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/__init__.py +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/__pyinstaller/__init__.py +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/__pyinstaller/hook-tcod.py +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/_internal.py +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/_libtcod.pyi +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/bsp.py +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/cdef.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/cffi.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/cffi.py +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/color.py +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/console.py +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/constants.py +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/context.py +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/event_constants.py +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/image.py +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/libtcodpy.py +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/los.py +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/map.py +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/noise.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/noise.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/noise.py +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/path.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/path.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/path.py +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/py.typed +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/random.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/random.py +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/render.py +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/sdl/__init__.py +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/sdl/_internal.py +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/sdl/audio.py +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/sdl/constants.py +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/sdl/joystick.py +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/sdl/mouse.py +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/sdl/render.py +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/sdl/sys.py +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/sdl/video.py +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/tcod.c +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/tcod.h +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/tcod.py +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod/tileset.py +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod.egg-info/SOURCES.txt +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod.egg-info/dependency_links.txt +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod.egg-info/entry_points.txt +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod.egg-info/requires.txt +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tcod.egg-info/top_level.txt +0 -0
- {tcod-19.3.1 → tcod-19.4.0}/tox.ini +0 -0
|
@@ -6,6 +6,18 @@ This project adheres to [Semantic Versioning](https://semver.org/) since version
|
|
|
6
6
|
|
|
7
7
|
## [Unreleased]
|
|
8
8
|
|
|
9
|
+
## [19.4.0] - 2025-08-06
|
|
10
|
+
|
|
11
|
+
### Changed
|
|
12
|
+
|
|
13
|
+
- Checking "WindowSizeChanged" was not valid since SDL 3 and was also not valid in previous examples.
|
|
14
|
+
You must no longer check the type of the `WindowResized` event.
|
|
15
|
+
|
|
16
|
+
### Fixed
|
|
17
|
+
|
|
18
|
+
- Corrected some inconsistent angle brackets in the `__str__` of Event subclasses. #165
|
|
19
|
+
- Fix regression with window events causing them to be `Unknown` and uncheckable.
|
|
20
|
+
|
|
9
21
|
## [19.3.1] - 2025-08-02
|
|
10
22
|
|
|
11
23
|
Solved a deprecation warning which was internal to tcod and no doubt annoyed many devs.
|
|
@@ -91,6 +103,8 @@ Be sure to run [Mypy](https://mypy.readthedocs.io/en/stable/getting_started.html
|
|
|
91
103
|
- `WindowFlags.FULLSCREEN_DESKTOP` is now just `WindowFlags.FULLSCREEN`
|
|
92
104
|
- `tcod.sdl.render.Renderer.integer_scaling` removed.
|
|
93
105
|
- Removed `callback`, `spec`, `queued_samples`, `queue_audio`, and `dequeue_audio` attributes from `tcod.sdl.audio.AudioDevice`.
|
|
106
|
+
- `tcod.event.WindowResized`: `type="WindowSizeChanged"` removed and must no longer be checked for.
|
|
107
|
+
`EventDispatch.ev_windowsizechanged` is no longer called.
|
|
94
108
|
|
|
95
109
|
### Fixed
|
|
96
110
|
|
|
@@ -83,6 +83,7 @@ Example::
|
|
|
83
83
|
from __future__ import annotations
|
|
84
84
|
|
|
85
85
|
import enum
|
|
86
|
+
import functools
|
|
86
87
|
import warnings
|
|
87
88
|
from collections.abc import Callable, Iterator, Mapping
|
|
88
89
|
from typing import TYPE_CHECKING, Any, Final, Generic, Literal, NamedTuple, TypeVar
|
|
@@ -90,7 +91,6 @@ from typing import TYPE_CHECKING, Any, Final, Generic, Literal, NamedTuple, Type
|
|
|
90
91
|
import numpy as np
|
|
91
92
|
from typing_extensions import deprecated
|
|
92
93
|
|
|
93
|
-
import tcod.event
|
|
94
94
|
import tcod.event_constants
|
|
95
95
|
import tcod.sdl.joystick
|
|
96
96
|
import tcod.sdl.sys
|
|
@@ -194,6 +194,7 @@ class Modifier(enum.IntFlag):
|
|
|
194
194
|
|
|
195
195
|
Example::
|
|
196
196
|
|
|
197
|
+
>>> import tcod.event
|
|
197
198
|
>>> mod = tcod.event.Modifier(4098)
|
|
198
199
|
>>> mod & tcod.event.Modifier.SHIFT # Check if any shift key is held.
|
|
199
200
|
<Modifier.RSHIFT: 2>
|
|
@@ -599,7 +600,7 @@ class MouseButtonEvent(MouseState):
|
|
|
599
600
|
return f"tcod.event.{self.__class__.__name__}(position={tuple(self.position)!r}, tile={tuple(self.tile)!r}, button={MouseButton(self.button)!r})"
|
|
600
601
|
|
|
601
602
|
def __str__(self) -> str:
|
|
602
|
-
return "<type=%r, position=(x=%i, y=%i), tile=(x=%i, y=%i), button=%r
|
|
603
|
+
return "<type=%r, position=(x=%i, y=%i), tile=(x=%i, y=%i), button=%r>" % (
|
|
603
604
|
self.type,
|
|
604
605
|
*self.position,
|
|
605
606
|
*self.tile,
|
|
@@ -650,7 +651,7 @@ class MouseWheel(Event):
|
|
|
650
651
|
)
|
|
651
652
|
|
|
652
653
|
def __str__(self) -> str:
|
|
653
|
-
return "<%s, x=%i, y=%i, flipped=%r
|
|
654
|
+
return "<%s, x=%i, y=%i, flipped=%r>" % (
|
|
654
655
|
super().__str__().strip("<>"),
|
|
655
656
|
self.x,
|
|
656
657
|
self.y,
|
|
@@ -698,7 +699,6 @@ class WindowEvent(Event):
|
|
|
698
699
|
"WindowExposed",
|
|
699
700
|
"WindowMoved",
|
|
700
701
|
"WindowResized",
|
|
701
|
-
"WindowSizeChanged",
|
|
702
702
|
"WindowMinimized",
|
|
703
703
|
"WindowMaximized",
|
|
704
704
|
"WindowRestored",
|
|
@@ -715,13 +715,13 @@ class WindowEvent(Event):
|
|
|
715
715
|
|
|
716
716
|
@classmethod
|
|
717
717
|
def from_sdl_event(cls, sdl_event: Any) -> WindowEvent | Undefined:
|
|
718
|
-
if sdl_event.
|
|
718
|
+
if sdl_event.type not in cls._WINDOW_TYPES:
|
|
719
719
|
return Undefined.from_sdl_event(sdl_event)
|
|
720
|
-
event_type: Final = cls.
|
|
720
|
+
event_type: Final = cls._WINDOW_TYPES[sdl_event.type]
|
|
721
721
|
self: WindowEvent
|
|
722
|
-
if sdl_event.
|
|
722
|
+
if sdl_event.type == lib.SDL_EVENT_WINDOW_MOVED:
|
|
723
723
|
self = WindowMoved(sdl_event.window.data1, sdl_event.window.data2)
|
|
724
|
-
elif sdl_event.
|
|
724
|
+
elif sdl_event.type in (
|
|
725
725
|
lib.SDL_EVENT_WINDOW_RESIZED,
|
|
726
726
|
lib.SDL_EVENT_WINDOW_PIXEL_SIZE_CHANGED,
|
|
727
727
|
):
|
|
@@ -734,7 +734,7 @@ class WindowEvent(Event):
|
|
|
734
734
|
def __repr__(self) -> str:
|
|
735
735
|
return f"tcod.event.{self.__class__.__name__}(type={self.type!r})"
|
|
736
736
|
|
|
737
|
-
|
|
737
|
+
_WINDOW_TYPES: Final = {
|
|
738
738
|
lib.SDL_EVENT_WINDOW_SHOWN: "WindowShown",
|
|
739
739
|
lib.SDL_EVENT_WINDOW_HIDDEN: "WindowHidden",
|
|
740
740
|
lib.SDL_EVENT_WINDOW_EXPOSED: "WindowExposed",
|
|
@@ -785,10 +785,13 @@ class WindowResized(WindowEvent):
|
|
|
785
785
|
Attributes:
|
|
786
786
|
width (int): The current width of the window.
|
|
787
787
|
height (int): The current height of the window.
|
|
788
|
+
|
|
789
|
+
.. versionchanged:: 19.4
|
|
790
|
+
Removed "WindowSizeChanged" type.
|
|
788
791
|
"""
|
|
789
792
|
|
|
790
|
-
type: Final[Literal["WindowResized"
|
|
791
|
-
"""WindowResized"
|
|
793
|
+
type: Final[Literal["WindowResized"]] # type: ignore[misc]
|
|
794
|
+
"""Always "WindowResized"."""
|
|
792
795
|
|
|
793
796
|
def __init__(self, type: str, width: int, height: int) -> None:
|
|
794
797
|
super().__init__(type)
|
|
@@ -1130,6 +1133,15 @@ class ControllerDevice(ControllerEvent):
|
|
|
1130
1133
|
return cls(type, sdl_event.cdevice.which)
|
|
1131
1134
|
|
|
1132
1135
|
|
|
1136
|
+
@functools.cache
|
|
1137
|
+
def _find_event_name(index: int, /) -> str:
|
|
1138
|
+
"""Return the SDL event name for this index."""
|
|
1139
|
+
for attr in dir(lib):
|
|
1140
|
+
if attr.startswith("SDL_EVENT_") and getattr(lib, attr) == index:
|
|
1141
|
+
return attr
|
|
1142
|
+
return "???"
|
|
1143
|
+
|
|
1144
|
+
|
|
1133
1145
|
class Undefined(Event):
|
|
1134
1146
|
"""This class is a place holder for SDL events without their own tcod.event class."""
|
|
1135
1147
|
|
|
@@ -1144,9 +1156,12 @@ class Undefined(Event):
|
|
|
1144
1156
|
|
|
1145
1157
|
def __str__(self) -> str:
|
|
1146
1158
|
if self.sdl_event:
|
|
1147
|
-
return "<Undefined sdl_event.type
|
|
1159
|
+
return f"<Undefined sdl_event.type={self.sdl_event.type} {_find_event_name(self.sdl_event.type)}>"
|
|
1148
1160
|
return "<Undefined>"
|
|
1149
1161
|
|
|
1162
|
+
def __repr__(self) -> str:
|
|
1163
|
+
return self.__str__()
|
|
1164
|
+
|
|
1150
1165
|
|
|
1151
1166
|
_SDL_TO_CLASS_TABLE: dict[int, type[Event]] = {
|
|
1152
1167
|
lib.SDL_EVENT_QUIT: Quit,
|
|
@@ -1157,7 +1172,6 @@ _SDL_TO_CLASS_TABLE: dict[int, type[Event]] = {
|
|
|
1157
1172
|
lib.SDL_EVENT_MOUSE_BUTTON_UP: MouseButtonUp,
|
|
1158
1173
|
lib.SDL_EVENT_MOUSE_WHEEL: MouseWheel,
|
|
1159
1174
|
lib.SDL_EVENT_TEXT_INPUT: TextInput,
|
|
1160
|
-
# lib.SDL_EVENT_WINDOW_EVENT: WindowEvent,
|
|
1161
1175
|
lib.SDL_EVENT_JOYSTICK_AXIS_MOTION: JoystickAxis,
|
|
1162
1176
|
lib.SDL_EVENT_JOYSTICK_BALL_MOTION: JoystickBall,
|
|
1163
1177
|
lib.SDL_EVENT_JOYSTICK_HAT_MOTION: JoystickHat,
|
|
@@ -1176,9 +1190,11 @@ _SDL_TO_CLASS_TABLE: dict[int, type[Event]] = {
|
|
|
1176
1190
|
|
|
1177
1191
|
def _parse_event(sdl_event: Any) -> Event:
|
|
1178
1192
|
"""Convert a C SDL_Event* type into a tcod Event sub-class."""
|
|
1179
|
-
if sdl_event.type
|
|
1180
|
-
return
|
|
1181
|
-
|
|
1193
|
+
if sdl_event.type in _SDL_TO_CLASS_TABLE:
|
|
1194
|
+
return _SDL_TO_CLASS_TABLE[sdl_event.type].from_sdl_event(sdl_event)
|
|
1195
|
+
if sdl_event.type in WindowEvent._WINDOW_TYPES:
|
|
1196
|
+
return WindowEvent.from_sdl_event(sdl_event)
|
|
1197
|
+
return Undefined.from_sdl_event(sdl_event)
|
|
1182
1198
|
|
|
1183
1199
|
|
|
1184
1200
|
def get() -> Iterator[Any]:
|
|
@@ -1198,10 +1214,7 @@ def get() -> Iterator[Any]:
|
|
|
1198
1214
|
return
|
|
1199
1215
|
sdl_event = ffi.new("SDL_Event*")
|
|
1200
1216
|
while lib.SDL_PollEvent(sdl_event):
|
|
1201
|
-
|
|
1202
|
-
yield _SDL_TO_CLASS_TABLE[sdl_event.type].from_sdl_event(sdl_event)
|
|
1203
|
-
else:
|
|
1204
|
-
yield Undefined.from_sdl_event(sdl_event)
|
|
1217
|
+
yield _parse_event(sdl_event)
|
|
1205
1218
|
|
|
1206
1219
|
|
|
1207
1220
|
def wait(timeout: float | None = None) -> Iterator[Any]:
|
|
@@ -1425,9 +1438,6 @@ class EventDispatch(Generic[T]):
|
|
|
1425
1438
|
def ev_windowresized(self, event: tcod.event.WindowResized, /) -> T | None:
|
|
1426
1439
|
"""Called when the window is resized."""
|
|
1427
1440
|
|
|
1428
|
-
def ev_windowsizechanged(self, event: tcod.event.WindowResized, /) -> T | None:
|
|
1429
|
-
"""Called when the system or user changes the size of the window."""
|
|
1430
|
-
|
|
1431
1441
|
def ev_windowminimized(self, event: tcod.event.WindowEvent, /) -> T | None:
|
|
1432
1442
|
"""Called when the window is minimized."""
|
|
1433
1443
|
|
|
@@ -2738,6 +2748,7 @@ class KeySym(enum.IntEnum):
|
|
|
2738
2748
|
|
|
2739
2749
|
Example::
|
|
2740
2750
|
|
|
2751
|
+
>>> import tcod.event
|
|
2741
2752
|
>>> tcod.event.KeySym.F1.label
|
|
2742
2753
|
'F1'
|
|
2743
2754
|
>>> tcod.event.KeySym.BACKSPACE.label
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|