Text and marker sizes: size.auto, size.tiny, size.small, size.normal, size.large and size.huge, from smallest to largest.
size.* constants set the size argument of plotshape, plotchar and label.new, and the text_size argument of box.new, table.cell and similar drawing calls. From smallest to largest they run size.tiny, size.small, size.normal, size.large, size.huge. size.auto lets the chart choose a size that fits the current zoom.
The default depends on the function: label.new uses size.normal, while plotshape, plotchar and the text of boxes default to size.auto.
Constants
| Name | Value | Description |
|---|---|---|
size.auto | Chosen by the chart to fit the zoom level. | |
size.huge | The largest step. | |
size.large | Larger than normal. | |
size.normal | The standard size. | |
size.small | Smaller than normal. | |
size.tiny | The smallest step. |
Remarks
- Sizes are named steps, not pixel values, and the exact height of each step depends on the chart.
Example
//@version=6
indicator("Sizes", overlay = true)
if bar_index % 150 == 0
label.new(bar_index, high, "tiny", size = size.tiny)
if bar_index % 150 == 50
label.new(bar_index, high, "normal", size = size.normal)
if bar_index % 150 == 100
label.new(bar_index, high, "huge", size = size.huge)
plot(close, "Close", color.gray)See also
Runs on Sidechair