Drawing tools catalog
Use this page as a lookup table. Not sure which type string to pass to drawTool()? Find it here, then open the grouped guide for a copy-paste example.
Two anchors define the direction. This is the cleanest programmatic entry point for support, resistance, and trend projection.
How to read this catalog
| Column | Meaning |
|---|---|
| Runtime type | String for drawTool({ type: "…" }) |
| Anchors | How many points you place |
| Creation | Helper shortcut, if any |
Helper first when available (drawTrendLine is easier than raw drawTool). Otherwise use drawTool({ type, anchors, … }).
Beginner picks (start here)
| Tool | Type | Use |
|---|---|---|
| Trend line | trendLine | Connect two swings — guide |
| Horizontal level | hLine | Support / resistance price |
| Fibonacci | fibonLines | Retracement levels — guide |
| Rectangle | box | Highlight a zone — guide |
| Time window | timeRange | Shade a session — guide |
Lines
| Runtime type | Label | Anchors | Creation |
|---|---|---|---|
trendLine | Trend line | 2 | drawTrendLine() or drawTool() |
trendRay | Trend ray | 2 | drawTool() |
hLine | Horizontal line | 1 | drawTool() |
hRay | Horizontal ray | 1 | drawTool() |
vLine | Vertical line | 1 | drawTool() |
vRay | Vertical ray | 1 | drawTool() |
crossLine | Cross line | 1 | drawTool() |
mLine | Multi-line | 3 | drawTool() |
Grouped examples: Lines, ranges, and tags.
Levels, channels, and projections
| Runtime type | Label | Anchors | Creation |
|---|---|---|---|
fibonLines | Fibonacci retracement | 2 | drawTool() |
fibonExtension | Fibonacci extension | 2 | drawTool() |
fibonTimeZone | Fibonacci time zone | 2 | drawTool() |
fibonChannel | Fibonacci channel | 3 | drawTool() |
fibonArcs | Fibonacci arcs | 2 | drawTool() |
fibonCircles | Fibonacci circles | 2 | drawTool() |
parallelChannel | Parallel channel | 3 | drawTool() |
pitchfork | Pitchfork | 3 | drawTool() |
regressionChannel | Regression channel | 2 | drawTool() |
gannFan | Gann fan | 2 | drawTool() |
gannGrid | Gann grid | 2 | drawTool() |
gannBox | Gann box | 2 | drawTool() |
abcd | ABCD | 3 | drawTool() |
Grouped examples: Levels and channels.
Every tool described: Complete tool reference.
Volume and trade planning
| Runtime type | Label | Anchors | Creation |
|---|---|---|---|
fixedRangeVolumeProfile | Volume profile | 2 | drawTool() |
longShortPosition | Long / short plan | 3 | drawLongShortPosition() or drawTool() |
fixedRangeVolumeProfile draws a volume histogram between two time anchors (POC + value area).
longShortPosition is for paper-trade entry/stop/target — not live broker lines.
Ranges, sessions, and tags
| Runtime type | Label | Anchors | Creation |
|---|---|---|---|
hRange | Horizontal range | 2 | drawTool() |
vRange | Vertical range | 2 | drawTool() |
timeRange | Time range | 2 | drawTimeRange() or drawTool() |
priceTag | Price tag | 1 | drawTool() |
timeBet | Time bet overlay | — | drawTimeBet() only |
Grouped examples: Lines, ranges, and tags.
Shapes and text
| Runtime type | Label | Anchors | Creation |
|---|---|---|---|
brush | Brush (freehand) | dynamic | drawTool() |
arrow | Arrow | 2 | drawTool() |
ellipse | Ellipse | 2 | drawTool() |
triangle | Triangle | 3 | drawTool() |
box | Rectangle | 2 | drawTool() |
cycle | Cycle | 2 | drawTool() |
textAnnotation | Text | 2 | drawTool() |
Grouped examples: Shapes and annotations.
Toolbar controls
| Control | Where | Effect |
|---|---|---|
| Magnet | Left toolbar | Snap anchors to OHLC |
| Lock all | Toolbar + Chart settings → Layers | Prevent dragging |
| Unlock all | Same | Allow editing again |
chart.setDrawingMagnetEnabled(true);
chart.lockAllDrawings();
chart.unlockAllDrawings();
Notes for integrators
- Anchor counts match the current ChartUI tool definitions.
- Fibonacci, ABCD, and similar tools accept extra fields (
values,valuesState,fillBg) beyond the shared config type — pass them throughdrawTool(). - Treat this catalog as a name lookup; behavior details live in the grouped pages and live showcase.
What is next?
- Complete tool reference — every type with live preview
- Overview — anchors and helpers explained
- Drawing tools recipes — end-to-end tutorial