WIN_CLOSED bulk update. No more test for event is None, use WIN_CLOSED instead

This commit is contained in:
PySimpleGUI 2020-05-07 06:22:59 -04:00
parent 6174b355a6
commit 0076b461f5
135 changed files with 395 additions and 349 deletions

View file

@ -1,6 +1,6 @@
#!/usr/bin/env python
import PySimpleGUI as sg
print(sg.version, sg)
'''
Usage of Column Element
'''
@ -9,7 +9,7 @@ sg.theme('BlueMono')
# Column layout
col = [[sg.Text('col Row 1', text_color='white', background_color='blue')],
[sg.Text('col Row 2', text_color='white', background_color='blue'), sg.Input('col input 1')],
[sg.Text('col Row 2', text_color='white', background_color='blue', pad=(0,(25,0))),sg.T('Another item'), sg.T('another'), sg.Input('col input 1')],
[sg.Text('col Row 3', text_color='white', background_color='blue'), sg.Input('col input 2')]]
# Window layout
layout = [[sg.Listbox(values=('Listbox Item 1', 'Listbox Item 2', 'Listbox Item 3'),
@ -19,7 +19,7 @@ layout = [[sg.Listbox(values=('Listbox Item 1', 'Listbox Item 2', 'Listbox Item
[sg.OK()]]
# Display the window and get values
window = sg.Window('Compact 1-line form with column', layout)
window = sg.Window('Compact 1-line form with column', layout, margins=(0,0), element_padding=(0,0))
event, values = window.read()
sg.popup(event, values, line_width=200)