Simple UI Library for pygame
Project description
PyGameUI Is a PyGame UI Library that adds simple UI for with the use of PyGame
Setting up a simple setup:
in your Main Class write:
if __name__ == "__main__":
pygameui.setup(YourMainScene())
and also make a Script and add a class to that script in my Case "YourMainScene"
class YourMainScene(PyGameScene):
def update(self):
# Write your Code here that Should only run when the Window is updated
def render(self,screen,events):
# Write your Rendering Code here
now lets say you want to add a Button then write a snippet like this in update:
self.drawables.append(Button("Here Goes the Button Text",
(Here Goes a tuple of 2 ints that is the center of the button),
(Here Goes a tuple of 2 ints that is the size of the button),
heres a reference for what should happen when the button gets clicked(lamda supported),
[Heres a list of values that should be passed onto the on_clicked methode]))
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
simple_pygame_ui-0.1.8.tar.gz
(12.6 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file simple_pygame_ui-0.1.8.tar.gz.
File metadata
- Download URL: simple_pygame_ui-0.1.8.tar.gz
- Upload date:
- Size: 12.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
07dca6a244c49f7bd15752e22b84879aae1b3bebd259c1e875ceb018d8c0b9f5
|
|
| MD5 |
248cf5272a7cd95b077f43284aa17f08
|
|
| BLAKE2b-256 |
b4dc236f5ff87702afc0a5a6435c79a3fc3aeff7c1e413f481b21bd235144b2c
|
File details
Details for the file simple_pygame_ui-0.1.8-py3-none-any.whl.
File metadata
- Download URL: simple_pygame_ui-0.1.8-py3-none-any.whl
- Upload date:
- Size: 22.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
19645634afdc933cbde9f8ddd0b0d01735651a1540a0a8d11925638672a9e4b7
|
|
| MD5 |
76fff278fabe10fd12520987d7ef671a
|
|
| BLAKE2b-256 |
51d27a69ba3b6a7f9f18e5e02cb59e4583192297c61a164136de79c18564a0cd
|