Usage

Installation

Install PygameYaGUI using pip:

$ pip install pygameyagui

About Python version

This package was developed and tested using Python 3.8. Users with other Python versions, please be aware of unforeseen consequences.

Also, you can download the zip package of Pygame-YaGUI.. Unzip and rename the folder pygameyagui-main to pygameyagui and put this folder in the same directory of your project.

Importing

In your project you need to add the following:

1import sys
2import pygame
3import pygameyagui
4
5pygame.init()

You are all set to use the Pygame-YaGUI environment. You will need to create an interface (pygameyagui.Interface) that is necessary for hosting (any amount of) toolboxes (pygameyagui.Toolbox). Each toolbox can have (any amount of) your widgets. Have fun!

Creating an Interface

Create an pygameyagui.Interface object with:

interface = pygameyagui.Interface()

Documentation

Refer to Interface Documentation for arguments, methods, properties and attributes.

Creating a Toolbox

Create a pygameyagui.Toolbox object with:

toolbox = pygameyagui.Toolbox(interface, 'This is a Toolbox')

Documentation

Refer to Toolbox Documentation for arguments, methods, properties and attributes.

Creating a Widget

A Widget object can be of two types: output and input