0

I want to make two buttons at the bottom of my table in python by using tkinter, one on the right and one on the left How do I do this using the method pack? Because the pack method has four directions, the buttons are placed under each other

quit = Button(text="Quit",font=("Segoe Script", 11), height=1, width=9, bg="indian red")
quit.pack(side="bottom")
restart = Button(text="Restart", font=("Segoe Script", 11), height=1, width=9, bg='indian red')
restart.pack(side="bottom")
Bryan Oakley
  • 370,779
  • 53
  • 539
  • 685
Zahra
  • 3
  • 2

1 Answers1

0

Use side=“left” or side=“right”, though it’s a bit more complicated if you have more than just two widgets. In your case you should add a frame at the bottom, then put the buttons in the frame.

For a visual example of how pack works, see this answer

Bryan Oakley
  • 370,779
  • 53
  • 539
  • 685