Python Library for making Dialogs
- Python 3.x
cursesandtextwraplibraries
Displays a simple alert box in the console.
title(str): The title of the box.message(str): The message to display in the box.width(int, optional): The width of the box. Default is 50.height(int, optional): The height of the box. Default is 10.button(str, optional): The label of the button. Default is "OK".
alert("Welcome", "Welcome to my script, press OK to continue.")Displays a box in the console where the user can use the arrow keys to navigate through choices the user can select.
title(str): The title of the selection box.message(str): The message to display in the box.width(int, optional): The width of the box. Default is 50.height(int, optional): The height of the box. Default is 10.options(list, optional): A list of options to choose from. Default is["Yes", "No"].
selection = select("IMPORTANT", "All data will be erased on drive Z:\, do you want to continue?", options=["Yes", "No"])
alert(f"You selected: {selection}")