Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

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
 
PREVIOUS NEXT
Tagged: #creating #interface #tkinter
ADD COMMENT
Topic
Name
6+8 =