@header@
 
 
matplotlib.widgets
index
/usr/lib/python2.4/site-packages/matplotlib/widgets.py

GUI Neutral widgets
 
All of these widgets require you to predefine an Axes instance and
pass that as the first arg.  matplotlib doesn't try to be too smart in
layout -- you have to figure out how wide and tall you want your Axes
to be to accommodate your widget.

 
Classes
       
Widget
Button
CheckButtons
RadioButtons
Slider
SubplotTool

 
class Button(Widget)
    A GUI neutral button
 
The following attributes are accesible
 
  ax    - the Axes the button renders into
  label - a text.Text instance
  color - the color of the button when not hovering
  hovercolor - the color of the button when hovering
 
Call "on_clicked" to connect to the button
 
  Methods defined here:
__init__(self, ax, label, image=None, color=0.84999999999999998, hovercolor=0.94999999999999996)
ax is the Axes instance the button will be placed into
 
label is a string which is the button text
 
image if not None, is an image to place in the button -- can
  be any legal arg to imshow (array, matplotlib Image
  instance, or PIL image)
 
color is the color of the button when not activated
 
hovercolor is the color of the button when the mouse is over
  it
disconnect(self, cid)
remove the observer with connection id cid
on_clicked(self, func)
When the button is clicked, call this func with event
 
A connection id is returned which can be used to disconnect

Data and other attributes inherited from Widget:
drawon = True
eventson = True

 
class CheckButtons(Widget)
    A GUI neutral radio button
 
The following attributes are exposed
 
 ax - the Axes instance the buttons are in
 labels - a list of text.Text instances
 lines - a list of (line1, line2) tuples for the x's in the check boxes.
         These lines exist for each box, but have set_visible(False) when
         box is not checked
 rectangles - a list of patch.Rectangle instances
 
Connect to the CheckButtons with the on_clicked method
 
  Methods defined here:
__init__(self, ax, labels, actives)
Add check buttons to axes.Axes instance ax
 
labels is a len(buttons) list of labels as strings
 
actives is a len(buttons) list of booleans indicating whether
 the button is active
disconnect(self, cid)
remove the observer with connection id cid
on_clicked(self, func)
When the button is clicked, call this func with button label
 
A connection id is returned which can be used to disconnect

Data and other attributes inherited from Widget:
drawon = True
eventson = True

 
class RadioButtons(Widget)
    A GUI neutral radio button
 
The following attributes are exposed
 
 ax - the Axes instance the buttons are in
 activecolor - the color of the button when clicked
 labels - a list of text.Text instances
 circles - a list of patch.Circle instances
 
Connect to the RadioButtons with the on_clicked method
 
  Methods defined here:
__init__(self, ax, labels, active=0, activecolor='blue')
Add radio buttons to axes.Axes instance ax
 
labels is a len(buttons) list of labels as strings
 
active is the index into labels for the button that is active
 
activecolor is the color of the button when clicked
disconnect(self, cid)
remove the observer with connection id cid
on_clicked(self, func)
When the button is clicked, call this func with button label
 
A connection id is returned which can be used to disconnect

Data and other attributes inherited from Widget:
drawon = True
eventson = True

 
class Slider(Widget)
    A slider representing a floating point range
 
The following attributes are defined 
  ax     : the slider axes.Axes instance
  val    : the current slider value
  vline  : a Line2D instance representing the initial value
  poly   : A patch.Polygon instance which is the slider
  valfmt : the format string for formatting the slider text
  label  : a text.Text instance, the slider label
  closedmin : whether the slider is closed on the minimum 
  closedmax : whether the slider is closed on the maximum
  slidermin : another slider - if not None, this slider must be > slidermin
  slidermax : another slider - if not None, this slider must be < slidermax
 
  
Call on_changed to connect to the slider event
 
  Methods defined here:
__init__(self, ax, label, valmin, valmax, valinit=0.5, valfmt='%1.2f', closedmin=True, closedmax=True, slidermin=None, slidermax=None)
Create a slider from valmin to valmax in axes ax;
 
label is the slider label valinit is the slider initial position
 
valfmt is used to format the slider value
 
closedmin and closedmax indicated whether the slider interval is closed
 
slidermin and slidermax can be used to contrain the value of
  this slider to the values of other sliders.
disconnect(self, cid)
remove the observer with connection id cid
on_changed(self, func)
When the slider valud is changed, call this func with the new
slider position
 
A connection id is returned which can be used to disconnect
reset(self)
reset the slider to the initial value

Data and other attributes inherited from Widget:
drawon = True
eventson = True

 
class SubplotTool(Widget)
    A tool to adjust to subplot params of fig
 
  Methods defined here:
__init__(self, targetfig, toolfig)
targetfig is the figure to adjust
 
toolfig is the figure to embed the the subplot tool into.  If
None, a default pylab figure will be created.  If you are
using this from the GUI
funcbottom(self, val)
funchspace(self, val)
funcleft(self, val)
funcright(self, val)
functop(self, val)
funcwspace(self, val)

Data and other attributes inherited from Widget:
drawon = True
eventson = True

 
class Widget
    OK, I couldn't resist; abstract base class for mpl GUI neutral
widgets
 
  Data and other attributes defined here:
drawon = True
eventson = True

 
Functions
       
array(...)
array(sequence, typecode=None, copy=1, savespace=0) will return a new array formed from the given (potentially nested) sequence with type given by typecode.  If no typecode is given, then the type will be determined as the minimum type required to hold the objects in sequence.  If copy is zero and sequence is already an array, a reference will be returned.  If savespace is nonzero, the new array will maintain its precision in operations.
@footer@