The fnDrawThumb is used to draw an up or down thumb on a price chart. It is positioned by price and shift value.
After the fnDrawThumb function has been added to a Drawing, it is configured by clicking the (+) button along the bottom of the Element.
The Function Configuration window allows you to select values for each parameter.
Each Chart Object function offers a number of parameters on the Configuration Tab, and also a number of parameters on the Advanced Tab.
- Parameters on the Configuration Tab should be inspected and set each time the function is added to a drawing.
- Parameters on the Advanced Tab usually do not need to be changed from their default values.
Parameters on the Configuration Tab
Parameter Name |
Data type |
Description |
type |
Integer |
Type of thumb. The pull-down menu offers these choices: OBJ_ARROW_THUMB_UP OBJ_ARROW_THUMB_DOWN |
name |
String |
The name of the object. Each object on a chart must have a unique name. Note: String parameters require enclosing quotes. Objects names can viewed from the MetaTrader platform by going to: Charts->Objects->Object List |
shift |
Integer |
The candle shift used to position the object's vertical location on the price chart. |
price |
Double |
The price value used to position the object's horizontal location on the price chart. |
lineColor |
Color |
The color of the object. |
Parameters on the Advanced Tab
Parameter Name |
Data type |
Description |
redraw |
Integer |
The interval when to redraw the object. The pull-down menu offers these choices: REDRAW_ONCE: draw the object once only. REDRAW_BAR: redraw the object on each new bar. REDRAW_TICK: redraw the object on each new tick. Note: The object function must be connected on the drawing so that it executes on each tick for the redraw options to work correctly. Objects that use the shift parameter will move on the chart as new candles are formed. |
size |
Integer |
The size of the object. |
lineStyle |
Integer |
The line style. The pull-down menu offers these choices: STYLE_SOLID STYLE_DASH STYLE_DOT STYLE_DASHDOT STYLE_DASHDOTDOT Note: Styles only work when the size is 1. |
chartID |
Integer |
The chart identifier. Use 0 for the current chart. |
windowID |
Integer |
The window identifier. Use 0 for the current window. |