chaco.tools.data_label_tool module¶
Defines the DataLabelTool class.
-
class
chaco.tools.data_label_tool.
DataLabelTool
(component=None, **traits)¶ Bases:
enable.tools.drag_tool.DragTool
A tool for dragging a data label.
Attach this tool to a DataLabel object by setting the tool’s component to the DataLabel.
-
auto_arrow_root
= Bool(True)¶ Use the root of the label’s arrow (if any) as the closest corner of the label?
The mouse button that initiates the drag.
-
drag_end
(event)¶ Called when a mouse event causes the drag operation to end.
Implements DragTool.
-
drag_start
(event)¶ Called when the drag operation starts.
Implements DragTool.
-
dragging
(event)¶ This method is called for every mouse_move event that the tool receives while the user is dragging the mouse.
Implements DragTool. Moves and redraws the label.
-
is_draggable
(x, y)¶ Returns whether the (x,y) position is in a region that is OK to drag.
Overrides DragTool.
-