Build a GUI application using Tkinter / customTKinter.
Using TCL/Tk to build apps with python
https://docs.python.org/3/library/tkinter....
See also
• TkDocs
Extensive tutorial on creating user interfaces with Tkinter. Explains key concepts, and illustrates recommended approaches using the modern API.
• Tkinter 8.5 reference: a GUI for Python
Reference documentation for Tkinter 8.5 detailing available classes, methods, and options.
Tcl/Tk Resources:
• Tk commands
Comprehensive reference to each of the underlying Tcl/Tk commands used by Tkinter.
• Tcl/Tk Home Page
Additional documentation, and links to Tcl/Tk core development.
Books:
• Modern Tkinter for Busy Python Developers
By Mark Roseman. (ISBN 978-1999149567)
• Python and Tkinter Programming
By Alan Moore. (ISBN 978-1788835886)
• Programming Python
By Mark Lutz; has excellent coverage of Tkinter. (ISBN 978-0596158101)
• Tcl and the Tk Toolkit (2nd edition)
By John Ousterhout, inventor of Tcl/Tk, and Ken Jones; does not cover Tkinter. (ISBN 978-0321336330)
---------------------
Here is the code that was shown in this video:
#! /usr/bin/env python3
'''Demonstration of customTKinter see TKInter documentation at https://docs.python.org/3/library/tkinter.... '''
import sys
import os
from platform import system as system_name # Returns the system/OS name
from subprocess import call as system_call # Execute a shell command
'''-----------------'''
import customtkinter
'''================='''
import my_module
'''-----------------'''
def my_calculate():
output_box.delete(0)
print("my_calculate invoked")
output_box.delete(0,)
output_box.insert(0, my_module.my_strlen(input_box.get()))
'''================='''
try:
customtkinter.set_appearance_mode("dark") # Modes: system (default), light, dark
customtkinter.set_default_color_theme("blue") # Themes: blue (default), dark-blue, green
app =customtkinter.CTk() # create CTk window like you do with the Tk window
app.geometry("230x280")
input_box = customtkinter.CTkEntry(master = app, placeholder_text = "enter text here")
input_box.pack( padx = 12, pady=20)
output_box = customtkinter.CTkEntry(master = app, placeholder_text = "Char Count")
output_box.pack( padx = 12, pady=10)
Use CTkButton instead of tkinter Button
button = customtkinter.CTkButton(master=app, text="Calculate", command=my_calculate)
button.place(relx=0.5, rely=0.6, anchor=customtkinter.CENTER)
button1 = customtkinter.CTkButton(master=app, text="Exit", command=app.destroy)
button1.place(relx=0.5, rely=0.8, anchor=customtkinter.CENTER)
app.mainloop()
except Exception as e:
print(type(e), e)
sys.exit(-1)
On this page of the site you can watch the video online create a GUI app with TKinter and Python with a duration of hours minute second in good quality, which was uploaded by the user Paul Cayley 15 August 2023, share the link with friends and acquaintances, this video has already been watched 59 times on youtube and it was liked by 1 viewers. Enjoy your viewing!