Added an extra frame in widget heirarchy in case I want to add

separators later
This commit is contained in:
Barry Warsaw 1998-09-29 17:36:43 +00:00
parent f984a65267
commit d7d4725dba
2 changed files with 7 additions and 4 deletions

View File

@ -53,7 +53,7 @@ class ChipViewer:
def __init__(self, switchboard, parent=None): def __init__(self, switchboard, parent=None):
self.__sb = switchboard self.__sb = switchboard
self.__frame = Frame(parent) self.__frame = Frame(parent)
self.__frame.pack() self.__frame.pack(expand=YES, fill=BOTH)
# create the chip that will display the currently selected color # create the chip that will display the currently selected color
# exactly # exactly
self.__sframe = Frame(self.__frame) self.__sframe = Frame(self.__frame)

View File

@ -267,17 +267,20 @@ class StripWidget:
class StripViewer: class StripViewer:
def __init__(self, switchboard, parent=None): def __init__(self, switchboard, parent=None):
self.__sb = switchboard self.__sb = switchboard
self.__reds = StripWidget(switchboard, parent, # create a frame inside the parent
self.__frame = Frame(parent)
self.__frame.pack()
self.__reds = StripWidget(switchboard, self.__frame,
generator=constant_cyan_generator, generator=constant_cyan_generator,
axis=0, axis=0,
label='Red Variations') label='Red Variations')
self.__greens = StripWidget(switchboard, parent, self.__greens = StripWidget(switchboard, self.__frame,
generator=constant_magenta_generator, generator=constant_magenta_generator,
axis=1, axis=1,
label='Green Variations') label='Green Variations')
self.__blues = StripWidget(switchboard, parent, self.__blues = StripWidget(switchboard, self.__frame,
generator=constant_yellow_generator, generator=constant_yellow_generator,
axis=2, axis=2,
label='Blue Variations') label='Blue Variations')