commit
7af14ce08d
|
@ -1,6 +1,6 @@
|
||||||
#!/usr/bin/python3
|
#!/usr/bin/python3
|
||||||
|
|
||||||
version = __version__ = "4.12.0.1 Unreleased - Element.expand added expand_row parm"
|
version = __version__ = "4.12.0.2 Unreleased - Element.expand added expand_row parm, spin - defaults to first entry if none specified"
|
||||||
|
|
||||||
port = 'PySimpleGUI'
|
port = 'PySimpleGUI'
|
||||||
|
|
||||||
|
@ -865,7 +865,7 @@ class Element():
|
||||||
except:
|
except:
|
||||||
print('Warning, error hiding element row for key =', self.Key)
|
print('Warning, error hiding element row for key =', self.Key)
|
||||||
|
|
||||||
def expand(self, expand_x=False, expand_y=False, expand_row=False):
|
def expand(self, expand_x=False, expand_y=False, expand_row=True):
|
||||||
"""
|
"""
|
||||||
Causes the Element to expand to fill available space in the X and Y directions. Can specify which or both directions
|
Causes the Element to expand to fill available space in the X and Y directions. Can specify which or both directions
|
||||||
|
|
||||||
|
@ -8582,6 +8582,7 @@ def PackFormIntoFrame(form, containing_frame, toplevel_form):
|
||||||
element.TKSpinBox = element.Widget = tk.Spinbox(tk_row_frame, values=element.Values,
|
element.TKSpinBox = element.Widget = tk.Spinbox(tk_row_frame, values=element.Values,
|
||||||
textvariable=element.TKStringVar,
|
textvariable=element.TKStringVar,
|
||||||
width=width, bd=border_depth)
|
width=width, bd=border_depth)
|
||||||
|
if element.DefaultValue is not None:
|
||||||
element.TKStringVar.set(element.DefaultValue)
|
element.TKStringVar.set(element.DefaultValue)
|
||||||
element.TKSpinBox.configure(font=font) # set wrap to width of widget
|
element.TKSpinBox.configure(font=font) # set wrap to width of widget
|
||||||
if element.BackgroundColor is not None and element.BackgroundColor != COLOR_SYSTEM_DEFAULT:
|
if element.BackgroundColor is not None and element.BackgroundColor != COLOR_SYSTEM_DEFAULT:
|
||||||
|
|
Loading…
Reference in New Issue