I am not sure if this is the right place to ask such a question but being a new wannabe Python developer i want any one to please explain Python`s Tkinter small program to me.
Program:
from Tkinter import *
master = Tk()
e = Entry(master)
e.pack()
root = Tk()
text = Text(root)
e.focus_set()
text.pack()
def callback():
text.insert(INSERT, e.get())
b = Button(master, text="Start", width=10, command=callback)
b.pack()
mainloop()
root.mainloop()
This program is working perfectly but following the documentation here i am still confused about few things.
- What is Enter(master)
- e.pack()
- Text(root)
- text.pack()
- mainloop()
- root.mainloop()
Thanks !!!