Is there a straightforward way to get an indicator to only draw something before, at, or after (time axis) wherever the must recent bar is on the chart?
For example, I have a chart with a right side margin (RSM) of 200 and I'd like to have an indicator draw a rectangle with x-coordinates from RSM + 25 to chartControl.CanvasRight - 25.
In other words, I'd like the rectangle to start to the left of the RSM/most recent bar by a few bars and then extend to the right just before the chart canvas ends.
I know how RenderTarget.FillRectangle(newRectangleF(floatx,floaty,floatwidth,floatheight), Brush) works, I just can't figure out how to access RSM via code. I honestly don't even need to use the right side margin if there's another way, I just want the code to be able to locate the x-position of the most recent bar on the chart and then draw a rectangle in that area.
Comment