Helpful tools for designing text-based interfaces, based on curses.
Project description
Witchui
Helpful utilities for designing text-based interfaces on top of curses.
Usage
See an example below, showing usage of some of the tools provided.
import curses
from witchui import (
setup_curses_colors,
WindowPrinter,
TitleText,
SelectionDropdown,
InputText,
)
def main(window):
curses.curs_set(0)
setup_curses_colors()
window.clear()
wprinter = WindowPrinter(window)
wprinter.print(TitleText("My title"))
wprinter.print("Choose from the list below:")
possible_choices = ["apples", "bananas", "oranges"]
selection = SelectionDropdown(window, possible_choices, line=2, col=4)
selected_option = selection.run()
input_text = InputText(window, line=6, col=2).run()
curses.wrapper(main)
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
witchui-0.1.0.tar.gz
(3.9 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 witchui-0.1.0.tar.gz.
File metadata
- Download URL: witchui-0.1.0.tar.gz
- Upload date:
- Size: 3.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.1.12 CPython/3.10.1 Darwin/21.2.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
22280fe4d4ea159d4905165e18cf281eb488d0322ceeb6ce7181f0304703bc7d
|
|
| MD5 |
b4e41b598489f8a1fa0efab9b867e1a4
|
|
| BLAKE2b-256 |
0d52ffcace22b201659987a49af6f290c121014c0547786d4bd98adb271520cd
|
File details
Details for the file witchui-0.1.0-py3-none-any.whl.
File metadata
- Download URL: witchui-0.1.0-py3-none-any.whl
- Upload date:
- Size: 5.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.1.12 CPython/3.10.1 Darwin/21.2.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9eeb01f3dd2c0a3988390e06c4362f359f342eb15a095a6e91a07262bb62a8f6
|
|
| MD5 |
5a3f2e403719e326f91ddf4ea6e76674
|
|
| BLAKE2b-256 |
a49498e834446eaba7545ce35745c3a5dc46f6445a7aebe667f244dff53c2c6e
|