seamm_widgets package

Submodules

seamm_widgets.labeled_combobox module

Labeled combobox widget.

The goal of these widgets is twofold: to make it easier for developers to implement dialogs with compound widgets, and to naturally standardize the user interface presented to the user.

class seamm_widgets.labeled_combobox.LabeledCombobox(parent, *args, **kwargs)[source]

Bases: seamm_widgets.labeled_widget.LabeledWidget

config(**kwargs)[source]

Set the configuration of the megawidget

configure(**kwargs)[source]

Configure resources of a widget.

The values for resources are specified as keyword arguments. To get an overview about the allowed keyword arguments call the method keys.

get()[source]

return the current value

set(value)[source]

Set the value of the widget

show(*args)[source]

Show only the specified subwidgets. ‘all’ or no arguments reverts to showing all

property value

seamm_widgets.labeled_entry module

Labeled entry widget.

The goal of these widgets is twofold: to make it easier for developers to implement dialogs with compound widgets, and to naturally standardize the user interface presented to the user.

class seamm_widgets.labeled_entry.LabeledEntry(parent, *args, **kwargs)[source]

Bases: seamm_widgets.labeled_widget.LabeledWidget

config(**kwargs)[source]

Set the configuration of the megawidget

get()[source]

return the current value

set(value)[source]

Set the value of the entry widget

show(*args)[source]

Show only the specified subwidgets. ‘all’ or no arguments reverts to showing all

property value

seamm_widgets.labeled_widget module

Base class for labeled widgets.

The goal of these widgets is twofold: to make it easier for developers to implement dialogs with compound widgets, and to naturally standardize the user interface presented to the user.

class seamm_widgets.labeled_widget.LabeledWidget(parent, *args, **kwargs)[source]

Bases: tkinter.ttk.Frame

config(**kwargs)[source]

Set the configuration of the megawidget

property labelpos

Where the label is positioned relative to the widget.

show(*args)[source]

Show only the specified subwidgets. ‘all’ or no arguments reverts to showing all

seamm_widgets.labeled_widget.align_labels(widgets, sticky=None)[source]

Align the labels of a given list of widgets

seamm_widgets.mousewheel_support module

Add support for the mousewheel to scrolled widgets

Based on a version: # Version: 0.22 # Author: Miguel Martinez Lopez # Uncomment the next line to see my email # print(“Author’s email: “, # “61706c69636163696f6e616d656469646140676d61696c2e636f6d”.decode(“hex”))

with minor changes.

class seamm_widgets.mousewheel_support.MousewheelSupport(*args, **kwargs)[source]

Bases: object

add_support_to(widget=None, xscrollbar=None, yscrollbar=None, what='units', horizontal_factor=None, vertical_factor=None)[source]

seamm_widgets.scrolled_columns module

A ttk-based widget for columns of widgets, with fixed titles and scrolling

This widgets has two areas: a row of titles across the top and a scrolled frame below it. It is used to make a table of widgets with fixed column headers.

class seamm_widgets.scrolled_columns.ScrolledColumns(parent, *args, **kwargs)[source]

Bases: tkinter.ttk.Frame

cell(row, column, value=None)[source]

Return or set the widget at the given cell

clear()[source]

Clear the contents of the widget.

Return type

None

delete_column(index)[source]
delete_row(index)[source]
interior()[source]

Where the user packs widgets

property ncolumns
property nrows
xview(*args)[source]

Connect the subwidgets to the single scrollbar

seamm_widgets.scrolled_frame module

A Tk scrolled frame widget compatible with tkinter.ttk

Based on a version: # Version: 0.22 # Author: Miguel Martinez Lopez # Uncomment the next line to see my email # print(“Author’s email: “, # “61706c69636163696f6e616d656469646140676d61696c2e636f6d”.decode(“hex”))

with minor changes.

class seamm_widgets.scrolled_frame.ScrolledFrame(master, width=None, anchor='n', height=None, mousewheel_speed=2, scroll_horizontally=True, xscrollbar=None, scroll_vertically=True, yscrollbar=None, background=None, inner_frame=<class 'tkinter.ttk.Frame'>, **kwargs)[source]

Bases: tkinter.ttk.Frame

property height
interior()[source]

The frame that contains user widgets

set_size(width, height)[source]
update_viewport()[source]
property width

seamm_widgets.unit_combobox module

Labeled combobox widget with units.

The goal of these widgets is twofold: to make it easier for developers to implement dialogs with compound widgets, and to naturally standardize the user interface presented to the user.

class seamm_widgets.unit_combobox.UnitCombobox(parent, *args, **kwargs)[source]

Bases: seamm_widgets.labeled_combobox.LabeledCombobox

config(**kwargs)[source]

Set the configuration of the megawidget

get()[source]

return the current value with units

set(value, unit_string=None)[source]

Set the the value and units

set_units(values=None)[source]
show(*args)[source]

Show only the specified subwidgets. ‘all’ or no arguments reverts to showing all

property value

seamm_widgets.unit_entry module

Labeled entry widget with units.

The goal of these widgets is twofold: to make it easier for developers to implement dialogs with compound widgets, and to naturally standardize the user interface presented to the user.

class seamm_widgets.unit_entry.UnitEntry(parent, *args, **kwargs)[source]

Bases: seamm_widgets.labeled_entry.LabeledEntry

config(**kwargs)[source]

Set the configuration of the megawidget

get()[source]

return the current value with units

set(value, unit_string=None)[source]

Set the the value and units

set_units(values=None)[source]
show(*args)[source]

Show only the specified subwidgets. ‘all’ or no arguments reverts to showing all

property value

Module contents

seamm_widgets Custom Tk widgets for SEAMM.