Skip to main content

Easy GUI Prompt

PyPI version Python versions License: MIT

A Python library to simplify the creation of GUI elements in the terminal using prompt-toolkit.

Installation

Install easy_gui_prompt using pip:

pip install easy_gui_prompt

Usage

Import the EasyGUI class:

from easy_gui_prompt import EasyGUI

Create an instance of EasyGUI with a title:

gui = EasyGUI("My GUI")

Add GUI elements using the available methods:

# Yes/No prompt
result = gui.add_yes_no("confirm", "Do you want to proceed?", remember_value=True)

# Text input
name = gui.add_text("name", "Enter your name:", remember_value=True)

# Integer range
age = gui.add_int_range("age", "Enter your age:", 18, 100, remember_value=True)

Save the settings to a configuration file:

gui.save_settings()

Restore default settings:

gui.restore_default_settings()

Configuration

The library automatically saves user preferences to onfiguration files in ~/.easy_gui/. This allows the GUI to remember the last entered values when remember_value=True is used.

You can also access the configuration directly using the get_config and save_config functions:

from easy_gui_prompt import get_config, save_config

config = get_config("My GUI")
save_config("My GUI", config)

License

This project is licensed under the MIT License. See the LICENSE file for details.

Metadata

Release files for easy_gui_prompt 2024.5.28

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for easy_gui_prompt 2024.5.28
File Size Uploaded Provenance Actions
easy_gui_prompt-2024.5.28.tar.gz 3.9 kB Without provenance Details for easy_gui_prompt-2024.5.28.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for easy_gui_prompt 2024.5.28
File Interpreter ABI Platform Actions
easy_gui_prompt-2024.5.28-py3-none-any.whl Python 3 none any Details for easy_gui_prompt-2024.5.28-py3-none-any.whl

Total release size: 8.5 kB

Release files / easy_gui_prompt-2024.5.28.tar.gz

Download URL easy_gui_prompt-2024.5.28.tar.gz
Size 3.9 kB
Tags Source
SHA-256 checksum
How to use checksums
1f9c425c06d70a522dfac3e02a62fe1d445e7ef6f2e9992e32fc5b9b916c8150
BLAKE2b-256 checksum
How to use checksums
1a2928e75719b75c60016095a59d5497faff74e740c54293a4053b744fdc77a4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.8.2 CPython/3.12.3 Darwin/23.5.0

Release files / easy_gui_prompt-2024.5.28-py3-none-any.whl

Download URL easy_gui_prompt-2024.5.28-py3-none-any.whl
Size 4.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
a71ba3c2692e9577d1237a78f61fe701a80be2120e9dd368ad8ec0ee0af2a737
BLAKE2b-256 checksum
How to use checksums
33d51797b02a5b936bd59d3933a00345908cb7370d7730a85c3eb4ba13626892
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.8.2 CPython/3.12.3 Darwin/23.5.0

Security for easy_gui_prompt 2024.5.28

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

2024.5.28 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page