Appendix I: Glossary of Terms

attribute

An element of data that is associated with all instances of a given class, and is named at the class level. [19] In most cases, attributes are stored and assigned separately for each instance (for the exception, see class attribute). Synonyms include “data member” and “instance variable”.

class attribute

An element of data that is associated with a class, and is named at the class level. There is only one value for a class attribute, associated with the class itself. In contrast, for an instance attribute, there is a value associated with every instance of a class.

command button

A button on a window that globally controls the window. Examples include OK, Cancel, Apply, Revert, and Help.

controller

The element of the MVC (“model-view-controller”) design pattern that manages the transfer of information between the data model and the view used to observe and edit it.

dialog box

A secondary window whose purpose is for a user to specify additional information when entering a command.

editor

A user interface component for editing the value of a trait attribute. Each type of trait has a default editor, but you can override this selection with one of a number of editor factories provided by the TraitsUI package. In some cases an editor can include multiple widgets, e.g., a slider and a text box for a Range trait attribute.

editor factory

An instance of the Traits class EditorFactory. Editor factories generate the actual widgets used in a user interface. You can use an editor factory without knowing what the underlying GUI toolkit is.

factory

An object used to produce other objects at run time without necessarily assigning them to named variables or attributes. A single factory is often parameterized to produce instances of different classes as needed.

Group

An object that specifies an ordered set of Items and other Groups for display in a TraitsUI View. Various display options can be specified by means of attributes of this class, including a border, a group label, and the orientation of elements within the Group. An instance of the TraitsUI class Group.

Handler

A TraitsUI object that implements GUI logic (data manipulation and dynamic window behavior) for one or more user interface windows. A Handler instance fills the role of controller in the MVC design pattern. An instance of the TraitsUI class Handler.

HasTraits

A class defined in the Traits package to specify objects whose attributes are typed. That is, any attribute of a HasTraits subclass can be a trait attribute.

instance

A concrete entity belonging to an abstract category such as a class. In object-oriented programming terminology, an entity with allocated memory storage whose structure and behavior are defined by the class to which it belongs. Often called an object.

Item

A non-subdividable element of a Traits user interface specification (View), usually specifying the display options to be used for a single trait attribute. An instance of the TraitsUI class Item.

live

A term used to describe a window that is linked directly to the underlying model data, so that changes to data in the interface are reflected immediately in the model. A window that is not live displays and manipulates a copy of the model data until the user confirms any changes.

livemodal

A term used to describe a window that is both live and modal.

MVC

A design pattern for interactive software applications. The initials stand for “Model-View-Controller”, the three distinct entities prescribed for designing such applications. (See the glossary entries for model, view, and controller.)

modal

A term used to describe a window that causes the remainder of the application to be suspended, so that the user can interact only with the window until it is closed.

model

A component of the MVC design pattern for interactive software applications. The model consists of the set of classes and objects that define the underlying data of the application, as well as any internal (i.e., non-GUI-related) methods or functions on that data.

nonmodal

A term used to describe a window that is neither live nor modal.

object

Synonym for instance.

panel

A user interface region similar to a window except that it is embedded in a larger window rather than existing independently.

predefined trait type

Any trait type that is built into the Traits package.

subpanel

A variation on a panel that ignores (i.e., does not display) any command buttons.

trait

A term used loosely to refer to either a trait type or a trait attribute.

trait attribute

An attribute whose type is specified and checked by means of the Traits package.

trait type

A type-checked data type, either built into or implemented by means of the Traits package.

Traits

An open source package engineered by Enthought, Inc. to perform explicit typing in Python.

TraitsUI

A high-level user interface toolkit designed to be used with the Traits package.

View

A template object for constructing a GUI window or panel for editing a set of traits. The structure of a View is defined by one or more Group or Item objects; a number of attributes are defined for specifying display options including height and width, menu bar (if any), and the set of buttons (if any) that are displayed. A member of the TraitsUI class View.

view

A component of the MVC design pattern for interactive software applications. The view component encompasses the visual aspect of the application, as opposed to the underlying data (the model) and the application’s behavior (the controller).

ViewElement

A View, Group or Item object. The ViewElement class is the parent of all three of these subclasses.

widget

An interactive element in a graphical user interface, e.g., a scrollbar, button, pull-down menu or text box.

wizard

An interface composed of a series of dialog box windows, usually used to guide a user through an interactive task such as software installation.

wx

A shorthand term for the low-level GUI toolkit on which TraitsUI and Pyface are currently based (wxWidgets) and its Python wrapper (wxPython).

Footnotes