Skip to main content

A cross-hardware GUI framework

Project description

UniGui

Screenshot

A cross-platform user interface framework based on Adafruit Displayio

This GUI framework can be used to create front-ends on multiple platforms, including Generic Linux and Windows PCs, Single board computers such as Raspberry Pi using a hardware display (for instance: PiTFT), and microcontroller-based projects (i.e. Feather RP2040) using CircuitPython and a display.

There is also a class called PygameDisplay that uses pygame to create a displayio.Display for use in a non-embedded environment. Much of that code was adopted from https://github.com/FoamyGuy/Blinka_Displayio_PyGameDisplay.

ToDo list

  • PR for Adafruit_Blinka and (possibly) PlatformDetect to allow usage on generic PC environments.
  • Overall improvement and features for widgets
  • Fix border_on function for generic widget so border is always drawn on top of other content (useful for viewing widget dimensions)
  • Map names (such as BASE_DARK, BASE_LIGHT, TEXT_DEFAULT, TEXT_HIGHLIGHT, etc) to the palette indices so that I can reference them independently of the color scheme
  • Figure out how to better handle clicks. For example, I might want a single widget to have multiple click regions. I don't think this is easy to do right now. Consider removing UniGui object totally and just making the Widget idea fully recursive.
  • Fix font file paths so they work always

How to use this framework

  • Clone this repository to your computer, then navigate into the project directory.
  • Create a python virtual environment with python -m venv .venv. Note: This project has been tested with Python 3.10.4 on Windows and Linux. You can name your virtual environment directory whatever you like. The current .gitignore will ignore all directories starting with .venv
  • Activate the virtual environment on Linux with source .venv/bin/activate.sh, or on Windows PowerShell with .venv\Scripts\Activate.ps1.
  • Install dependencies with pip install -r requirements.txt.
  • To run the main example, type python examples/desktop/code-desktop.py

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

unigui-carstentb-0.1.3.tar.gz (47.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

unigui_carstentb-0.1.3-py3-none-any.whl (52.1 kB view details)

Uploaded Python 3

File details

Details for the file unigui-carstentb-0.1.3.tar.gz.

File metadata

  • Download URL: unigui-carstentb-0.1.3.tar.gz
  • Upload date:
  • Size: 47.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.0 CPython/3.10.4

File hashes

Hashes for unigui-carstentb-0.1.3.tar.gz
Algorithm Hash digest
SHA256 11b7241424cc1ea41bb8409dfcc1ac6ffaad3e5058e47b29a37af45c30ece34c
MD5 55f9ec9c837f42226b0cb627cbe0b62a
BLAKE2b-256 58241e268e564f52886108d54c7ed1b7c6c088c58c55ef980775674313f1aa65

See more details on using hashes here.

File details

Details for the file unigui_carstentb-0.1.3-py3-none-any.whl.

File metadata

File hashes

Hashes for unigui_carstentb-0.1.3-py3-none-any.whl
Algorithm Hash digest
SHA256 0f1a1d0a317f64a81cf8bf5105f1f51a7df2dcc06679496bf1d118dd9916ce40
MD5 a970b4b1124057d2b14f8ccd2d014239
BLAKE2b-256 a7ee24e26f43a6fbf87445b03379551cb976fe53070118253b3b0fa09056db99

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page