MCPcopy Create free account
hub / github.com/ColdGrub1384/Pyto / __init__

Method __init__

site-packages/matplotlib/widgets.py:2772–2785  ·  view source on GitHub ↗
(self, ax, xy, callback=None, useblit=True)

Source from the content-addressed store, hash-verified

2770 """
2771
2772 def __init__(self, ax, xy, callback=None, useblit=True):
2773 AxesWidget.__init__(self, ax)
2774
2775 self.useblit = useblit and self.canvas.supports_blit
2776 if self.useblit:
2777 self.background = self.canvas.copy_from_bbox(self.ax.bbox)
2778
2779 x, y = xy
2780 self.verts = [(x, y)]
2781 self.line = Line2D([x], [y], linestyle='-', color='black', lw=2)
2782 self.ax.add_line(self.line)
2783 self.callback = callback
2784 self.connect_event('button_release_event', self.onrelease)
2785 self.connect_event('motion_notify_event', self.onmove)
2786
2787 def onrelease(self, event):
2788 if self.ignore(event):

Callers 11

__init__Method · 0.45
__init__Method · 0.45
__init__Method · 0.45
__init__Method · 0.45
__init__Method · 0.45
__init__Method · 0.45
__init__Method · 0.45
__init__Method · 0.45
__init__Method · 0.45
__init__Method · 0.45
__init__Method · 0.45

Calls 4

Line2DClass · 0.85
copy_from_bboxMethod · 0.80
add_lineMethod · 0.80
connect_eventMethod · 0.80

Tested by

no test coverage detected