Python Forum
[PyGUI] [PySimpleGUI] How to go to next page
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[PyGUI] [PySimpleGUI] How to go to next page
#1
I just started to use PySimpleGUI and need a kick start.

I have a menu_def with the pages I want to show. For each page I created a layoutPagex

I have for each layoutPagex a windowPagex.

Basically something like:
menu_def = [....

layoutStart = [...

layoutCamera = [...

layout....

windowStart = sg.Window('headline', layoutStart, default_element_size=(40, 1), grab_anywhere=False)
eventStart, valuesStart = windowStart.Read()

sg.Popup('Title',
         'The results of the window.',
         'The button clicked was "{}"'.format(eventStart),
         'The values are', valuesStart)

windowCamera = sg.Window('headline', layoutCamera, default_element_size=(40, 1), grab_anywhere=False)
eventCamera, valuesCamera = windowCamera.Read()

sg.Popup('Title',
         'The results of the window.',
         'The button clicked was "{}"'.format(eventCamera),
         'The values are', valuesCamera)

window...
event...
sg.Popup ...
It doesn't matter which menu item I select, I just get the next window in the list.

1. How can I get a flow logic into that? Open only that page I select, and close the current page, so that only the last page will be displayed.
2. I want to add a logo in the Title
3. I want to use a camera picture. The user should be able to set some parameters of the camera, like brightness, ... with a slider and the camera picture should show the effect directly.

Can you guide me to a solution, please.
Reply
#2
Based on history, we only get a question or two every few months about pysimplegui. And if i recall correctly, now one uses it here that i know of. Everyone here just uses the GUI that pysimplegui is wrapping around, such as tkinter, WxPython, or PyQt.
Recommended Tutorials:
Reply
#3
This sounds like an interesting project. Have you tried posting an Issue on the PySimpleGUI project's GitHub page?
Reply


Forum Jump:

User Panel Messages

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