PINE LIBRARY
lib_set

Library "lib_set"
This is a convenience lib that bundles different setter functions allowing to update all coordinates and of line/box in one call, and coordinates and text for label.
method set_xy_text(this, x, y, txt, tooltip)
โโUpdates a label object with new data (equals redrawing it)
โโNamespace types: series label
โโParameters:
โโโโthis (label)
โโโโx (int): reassigns the x coordinate, optional param, no effect if x = na (same as draw(extend_only = true) for Line objects). Avoiding to reassign x can prevent errors for invalid params passed to set_x***
โโโโy (float): reassigns the y coordinate
โโโโtxt (string): reassigns the label text
โโโโtooltip (string): reassigns the label tooltip
method set_xy1_xy2(this, x1, y1, x2, y2)
โโUpdates a line object with new data (equals redrawing it)
โโNamespace types: series line
โโParameters:
โโโโthis (line)
โโโโx1 (int): reassigns the x1 coordinate, optional param, no effect if x1 = na (same as draw(extend_only = true) for Line objects). Avoiding to reassign x1 can prevent errors for invalid params passed to set_x***
โโโโy1 (float): reassigns the y1 coordinate
โโโโx2 (int): reassigns the x2 coordinate
โโโโy2 (float): reassigns the y2 coordinate
method set_left_top_right_bottom(this, left, top, right, bottom)
โโUpdates a box object with new data (equals redrawing it)
โโNamespace types: series box
โโParameters:
โโโโthis (box)
โโโโleft (int): reassigns the left coordinate, optional param, no effect if left = na (same as draw(extend_only = true) for Box objects). Avoiding to reassign 'left' can prevent errors for invalid params passed to set_x***
โโโโtop (float): reassigns the top coordinate
โโโโright (int): reassigns the right coordinate
โโโโbottom (float): reassigns the bottom coordinate
This is a convenience lib that bundles different setter functions allowing to update all coordinates and of line/box in one call, and coordinates and text for label.
method set_xy_text(this, x, y, txt, tooltip)
โโUpdates a label object with new data (equals redrawing it)
โโNamespace types: series label
โโParameters:
โโโโthis (label)
โโโโx (int): reassigns the x coordinate, optional param, no effect if x = na (same as draw(extend_only = true) for Line objects). Avoiding to reassign x can prevent errors for invalid params passed to set_x***
โโโโy (float): reassigns the y coordinate
โโโโtxt (string): reassigns the label text
โโโโtooltip (string): reassigns the label tooltip
method set_xy1_xy2(this, x1, y1, x2, y2)
โโUpdates a line object with new data (equals redrawing it)
โโNamespace types: series line
โโParameters:
โโโโthis (line)
โโโโx1 (int): reassigns the x1 coordinate, optional param, no effect if x1 = na (same as draw(extend_only = true) for Line objects). Avoiding to reassign x1 can prevent errors for invalid params passed to set_x***
โโโโy1 (float): reassigns the y1 coordinate
โโโโx2 (int): reassigns the x2 coordinate
โโโโy2 (float): reassigns the y2 coordinate
method set_left_top_right_bottom(this, left, top, right, bottom)
โโUpdates a box object with new data (equals redrawing it)
โโNamespace types: series box
โโParameters:
โโโโthis (box)
โโโโleft (int): reassigns the left coordinate, optional param, no effect if left = na (same as draw(extend_only = true) for Box objects). Avoiding to reassign 'left' can prevent errors for invalid params passed to set_x***
โโโโtop (float): reassigns the top coordinate
โโโโright (int): reassigns the right coordinate
โโโโbottom (float): reassigns the bottom coordinate
Pine library
In true TradingView spirit, the author has published this Pine code as an open-source library so that other Pine programmers from our community can reuse it. Cheers to the author! You may use this library privately or in other open-source publications, but reuse of this code in publications is governed by House Rules.
Disclaimer
The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.
Pine library
In true TradingView spirit, the author has published this Pine code as an open-source library so that other Pine programmers from our community can reuse it. Cheers to the author! You may use this library privately or in other open-source publications, but reuse of this code in publications is governed by House Rules.
Disclaimer
The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.