Hiding Indicator Drawing Objects

Created at 08 Feb 2023, 12:44
How’s your experience with the cTrader Platform?
Your feedback is crucial to cTrader's development. Please take a few seconds to share your opinion and help us improve your trading experience. Thanks!
PJ

pjm_101

Joined 08.02.2023

Hiding Indicator Drawing Objects
08 Feb 2023, 12:44


Hey,

A recent update has introduced Indicator titles on the chart, along with a hide button (the eye icon).

Clicking the eye will hide the indictor series, but I'd like to also be able to hide any related objects.

Is there an event I can use to hook the hide\show request in the indicator, so I can go and hide any indicator related drawing objects (lines, shapes etc)?

Or is there a different way to acheive this?

I couldn't find any documents on this, but please point me to it if there is one. ;)

Cheers.


@pjm_101
Replies

firemyst
29 May 2023, 06:03

I don't think so. I think what you'll have to do is have a separate button or checkbox to hide the indicator drawings before someone clicks the eyeball to hide the indicator.

 

This means you'll have to have the indicator keep track of all its drawings so it can show/hide them when the button/checkbox you create is checked/unchecked.


@firemyst