Lipi Reference Lipi

Functions

input.color()

Asks the reader for a colour. Pass the result straight to a colour argument of a chart-output call; those arguments accept an input-form colour.

Syntax

                input.color(const color defval, const string title, const string tooltip, const string inline, const string group, const bool confirm) → input color
              

Arguments

defval required const color The colour the control starts at. Required.
title const string The label shown beside the control.
tooltip const string Help text for the control.
inline const string A key that puts several controls on one row.
group const string A heading the control sits under.
confirm const bool Asks the reader to confirm the value.

Return Type

input color

Example


          indicator("Custom SMA", overlay=true)
smaColor = input.color(color.blue, title="SMA Color")
plot(talib.sma(close, 14), color=smaColor)