Answers for "creating an interface tkinter"

1

creating an interface tkinter

import tkinter as tk #tkinter is the library that we will use

class main:
  def __init__(self,master):
    master.title('Simple Interface') #This is the title
    master.geometry('500x500') #Our window will be a square
    master.configure(background='white') #Color of background
    master.resizable(False, False) #Resizable Off

if __name__ == '__main__':
  master = tk.Tk() #master is the name of our window
  main = main(master) #main is a class
  master.mainloop() #this is the loop
Posted by: Guest on July-25-2021

Code answers related to "creating an interface tkinter"

Python Answers by Framework

Browse Popular Code Answers by Language