scallop dome pyformex logo

Previous topic

31. appMenu — Menu with pyFormex apps.

Next topic

33. calpy_itf — Calpy interface for pyFormex.

[FSF Associate Member]

Valid XHTML 1.0 Transitional

32. toolbar — Toolbars for the pyFormex GUI.

This module defines the functions for creating the pyFormex window toolbars.

Classes defined in module toolbar

Functions defined in module toolbar

toolbar.addActionButtons(toolbar)

Add the script action buttons to the toolbar.

toolbar.addButton(toolbar, tooltip, icon, func, repeat=False, toggle=False, checked=False, icon0=None)

Add a button to a toolbar.

  • toolbar: the toolbar where the button will be added
  • tooltip: the text to appears as tooltip
  • icon: name of the icon to be displayed on the button,
  • func: function to be called when the button is pressed,
  • repeat: if True, the func will repeatedly be called if button is held down.
  • toggle: if True, the button is a toggle and stays in depressed state until pressed again.
  • checked: initial state for a toggle buton.
  • icon1: for a toggle button, icon to display when button is not checked.
toolbar.removeButton(toolbar, button)

Remove a button from a toolbar.

toolbar.addCameraButtons(toolbar)

Add the camera buttons to a toolbar.

toolbar.toggleButton(attr, state=None)

Update the corresponding viewport attribute.

This does not update the button state.

toolbar.updateButton(button, attr)

Update the button to correct state.

toolbar.updateWireButton()

Update the wire button to correct state.

toolbar.updateTransparencyButton()

Update the transparency button to correct state.

toolbar.updateLightButton()

Update the light button to correct state.

toolbar.updateNormalsButton(state=True)

Update the normals button to correct state.

toolbar.updatePerspectiveButton()

Update the normals button to correct state.

toolbar.addTimeoutButton(toolbar)

Add or remove the timeout button,depending on cfg.

toolbar.timeout(onoff=None)

Programmatically toggle the timeout button