Package schrodinger :: Package application :: Package bioluminate :: Module sliderchart :: Class SlidableLine
[hide private]
[frames] | no frames]

Class SlidableLine

object --+
         |
        SlidableLine
Known Subclasses:

A line on a matplotlib plot that can be grabbed and moved by the user

Instance Methods [hide private]
 
__init__(self, parent, axes, line, tolerance=7, border='high', shade_color='0.70', callback=None)
Create a SlidableLine object
 
onRelease(self, event)
Stop checking for movement when the mouse button is released
 
remove(self)
Remove this from the plot

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, parent, axes, line, tolerance=7, border='high', shade_color='0.70', callback=None)
(Constructor)

 

Create a SlidableLine object

Parameters:
  • parent (SliderPlot object) - The matplotlib canvas these lines are plotted on
  • axes (matplotlib Axes object) - The matplotlib axes these lines are plotted on
  • line (matplotlib Line2D object) - the actual line that will be moved
  • tolerance (int) - The amount that the user can "miss" the line and still grab it
  • border (str) - either "high" or "low", the role this line plays in bounding the box - high lines are those that bound the upper value of X or Y
  • shade_color (str) - A matplotlib-recognized color string that the unselected areas will be shaded
  • callback (callable) - Called when the slider line has been moved. The callback will receive the SlidableLine object that was moved.
Overrides: object.__init__