2

I'm using pysimplegui, when I run this code it shows a very small screen...

I would like to know if there is a size attribute to make with k a screen always starts in full screen, that is, occupying my full screen by default

import PySimpleGUI as sg

layout = [ [sg.Button('Hello World3')] ]

window = sg.Window('This is a long heading.', layout)
while True:
    event, values = window.read()
    if event == sg.WIN_CLOSED or event == 'Close':
        break
    break
window.close()
Henry Ecker
  • 34,399
  • 18
  • 41
  • 57

1 Answers1

2

Using method maximize of sg.Window after window finalized.

import PySimpleGUI as sg

layout = [ [sg.Button('Hello World3')] ]

window = sg.Window('This is a long heading.', layout, finalize=True)
window.maximize()

while True:
    event, values = window.read()
    if event == sg.WIN_CLOSED or event == 'Close':
        break
    break
window.close()
Jason Yang
  • 11,284
  • 2
  • 9
  • 23