Pack
- It basically packs each of the widgets next to each other in a vaguely logical format. And by default, pack will always start from the top and then pack every other widget just below the previous one.
- You can change this by adding a side parameter and you can change it to side = left. And if you change this for all of the packs, then it's going to pack everything starting from the left edge of the program
- The problem with pack is that it's actually quite difficult to specify a precise position
#Label
my_label = Label(text="I Am a Label", font=("Arial", "24", "bold"))
my_label["text"] = "New text"
my_label.pack(side="left")
Place
- Place is all about precise positioning. So when you place something, you can provide a X and Y value.
- The downside of place on the other hand is the fact that it is so specific and we have to work out in our head the coordinate and where to put each widget.
#Label
my_label = Label(text="I Am a Label", font=("Arial", "24", "bold"))
my_label["text"] = "New text"
my_label.config(text="New text")
my_label.place(x=0, y=0)
Grid
- The grid is a really simple concept. It imagines that your entire program is a grid and you can divide it into any number of columns and rows that you want to.
- So the easiest way of working with the grid is starting with the things that you want it to be at the top left, defining a starting column and rows, zero, zero, and then for the next and subsequent widgets to just keep going through it and define its position on the grid.
- Just a word of warning though. You can't mix up grid and pack in the same program.
#Label
my_label = Label(text="I Am a Label", font=("Arial", "24", "bold"))
my_label["text"] = "New text"
my_label.config(text="New text")
my_label.grid(column=0, row=0)
button.grid(column=1, row=1)
entry.grid(column=2, row=2)

Padding
- GUI programs is how to add a little bit of padding around components.
- The easiest way to add padding is actually to directly modify the widgets.