Python Forum
[Tkinter] grid layout
Thread Rating:
  • 1 Vote(s) - 2 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[Tkinter] grid layout
#5
Sorry, I totally forgot about your post, and thought someone else might have responded.
Nevertheless, I'm back. I thought your original post had code with it, but I don't see any. You will need Python 3
or do the conversion to Python 2 yourself, in order to complete the task.


I'll try to get what you're looking for.

first, Inside your root window you are going to make two frames, one for the buttons on the left,

and one to fill the entire area that gets overlaid on the right. These wukk use the pack geometry

Inside the left frame, you will layout your buttons using grid. Since they are encapsulated inside of
the frame that was made, each button will span two rows, and contain padding on both the x and y axis
to make them appear as though they are floating.


within the second frame, I'd use a tkinter.ttk Notebook widget without tabs (since the buttons will replace the tabs.
This will allow you to overlay that frame by simply switching tabs. the layout for each tab can be completely different
from one another, you can make some canvases, text windows, data entry, or whatever. The Notebook widget will make
switching windows simple.

I'll go so far as to modify your layout on a spreadsheet which I'll attach later today as soon as it is done. I'll also give
you a template with the basic frames and notebook to get you started.
Reply


Messages In This Thread
grid layout - by neech - Oct-07-2016, 06:18 PM
RE: tkinter grid layout - by neech - Oct-07-2016, 09:05 PM
RE: tkinter grid layout - by Larz60+ - Oct-07-2016, 09:55 PM
RE: tkinter grid layout - by neech - Oct-07-2016, 11:55 PM
RE: grid layout - by Larz60+ - Oct-13-2016, 09:41 AM
RE: grid layout - by Yoriz - Oct-13-2016, 11:56 AM
RE: grid layout - by Larz60+ - Oct-13-2016, 10:07 PM
RE: grid layout - by Larz60+ - Oct-13-2016, 11:16 PM
RE: grid layout - by Larz60+ - Oct-14-2016, 07:06 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Using Grid layout and QHBox hobbyist 1 3,105 Jan-26-2021, 12:35 AM
Last Post: deanhystad
  pyqt5 layout Nickd12 8 3,521 Jan-18-2021, 09:09 AM
Last Post: Axel_Erfurt
  [Kivy] Weird spacing in grid layout test 3 3,475 Nov-08-2019, 04:37 PM
Last Post: Axel_Erfurt
  Python GUI layout off between different OS shift838 5 3,732 Jan-02-2019, 02:53 AM
Last Post: shift838

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020