Skip to content

[ Enhancement/Bug/Question] My problem is regarding creating multiple nested TABS #3927

@mobvarun

Description

@mobvarun

Type of Issues (Enhancement, Error, Bug, Question) : Question

Operating System : Window 10, 64 Bit

Python version : Python 3.6.3 - 64 Bit

PySimpleGUI Port and Version

Ports = tkinter, Qt, WxPython, Web

PySimpleGUI Version:

tkinter version:

You can get these by adding this to the top of your file and running it:

import PySimpleGUI as sg

print(sg)             # Location of your PySimpleGUI.py file
print(sg.version)     # PySimpleGUI version number
print(sg.tclversion_detailed)   # tkinter detailed version number (in PySimpleGUI version 4.29.0+)
print(sg.sys.version) # Python version number
Python 3.6.3 (v3.6.3:2c5fed8, Oct  3 2017, 18:11:49) [MSC v.1900 64 bit (AMD64)] on win32
>>> import PySimpleGUI as sg
... 
... print(sg)             # Location of your PySimpleGUI.py file
... print(sg.version)     # PySimpleGUI version number
... print(sg.tclversion_detailed)   # tkinter detailed version number (in PySimpleGUI version 4.29.0+)
... print(sg.sys.version) # Python version number
<module 'PySimpleGUI' from 'C:\\Scripts\\MATLAB_2_Python\\Matlab_2_Python_Venv_Pycharm\\Platform_Gui_Testathon_21\\lib\\site-packages\\PySimpleGUI\\__init__.py'>
4.34.0 Released 18-Jan-2021
8.6.6
3.6.3 (v3.6.3:2c5fed8, Oct  3 2017, 18:11:49) [MSC v.1900 64 bit (AMD64)]

The tkinter version number can be obtained using above code in version 4.29.0+. If your code is prior:

print(sg.tkinter.Tcl().eval('info patchlevel'))
8.6.6

Your Experience Levels In Months or Years

5___ Python programming experience
8___ Programming experience overall
yes___ Have used another Python GUI Framework (tkinter, Qt, etc) previously (yes/no is fine)?

You have completed these steps:

  • [Y ] Read instructions on how to file an Issue
  • [ Y] Searched through main docs http://www.PySimpleGUI.org for your problem
  • [ Y] Searched through the readme for your specific port if not PySimpleGUI (Qt, WX, Remi)
  • [ Y] Looked for Demo Programs that are similar to your goal http://www.PySimpleGUI.com
  • [ Y] Note that there are also Demo Programs under each port on GitHub
  • [ Y] Run your program outside of your debugger (from a command line)
  • [ Y] Searched through Issues (open and closed) to see if already reported
  • [ Y] Try again by upgrading your PySimpleGUI.py file to use the current one on GitHub. Your problem may have already been fixed but is not yet on PyPI.

Description of Problem / Question / Details

Is there any way to create multi-level tabs in PySimpleGui. I have gone through the demo program located at : PySimpleGUI/DemoPrograms/Demo_Tabs_Nested.py, but I am not able to make it as per my need.

image
I am able to replicate and create the GUI's for TAB_1, TAB_2, TAB_3; but I am not able to do the nesting of TAB_1_NESTED_1 and TAB_1_NESTED_2 within TAB_1, and TAB_1_NESTED_2_ONE_MORE_NESTING_1, TAB_1_NESTED_2_ONE_MORE_NESTING_2, TAB_1_NESTED_2_ONE_MORE_NESTING_3 within TAB_1_NESTED_2

I am not pasting any code for this, as it is just the being re-used from the demo program. Any suggestions/ or pointers will be of great help !!!!

** Note: I understand that I am certainly missing something in sg.TabGroup and it surely has to do something with nested list but I am not able to fix the order ??**

Code To Duplicate

A short program that isolates and demonstrates the problem (i.e. please don't paste a link to your 400 line program.... instead paste your 10 line program in full).

Yes, it is a pain to narrow down problems, but it's part of the debugging process. Help me help you by providing something that can be executed so that work on getting you a fix or a workaround can immediately begin.

This pre-formatted code block is all set for you to paste in your bit of code:

import PySimpleGUI as sg

## Paste your code here

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions