ToolBox¶
- class ToolBox¶
The Toolbox allows for trendlines, ray lines and horizontal lines to be drawn and edited directly on the chart.
It can be used within any Chart object, and is enabled by setting the
toolboxparameter toTrueupon Chart declaration.The following hotkeys can also be used when the Toolbox is enabled:
Key Cmd
Action
alt TTrendline
alt HHorizontal Line
alt RRay Line
⌘ Zorctrl ZUndo
Right-clicking on a drawing will open a context menu, allowing for color selection, style selection and deletion.
- save_drawings_under(widget: Widget)¶
Saves drawings under a specific
topbartext widget. For example:chart.toolbox.save_drawings_under(chart.topbar['symbol'])
- load_drawings(tag: str)¶
Loads and displays drawings stored under the tag given.
- import_drawings(file_path: str)¶
Imports the drawings stored at the JSON file given in
file_path.
- export_drawings(file_path: str)¶
Exports all currently saved drawings to the JSON file given in
file_path.