Support Board
Date/Time: Thu, 30 Oct 2025 14:26:48 +0000
Post From: StudyRegionRightCoordinate Problem when
| [2019-06-03 10:42:46] |
| User907968 - Posts: 847 |
|
Hi BlakJak, I think that these functions (sc.StudyRegion######## & sc.BarIndexToXPixelCoordinate) return values based on the chart window co-ordinate system. If your Device Context / Bitmap is not copied to the origin of the Chart Window (as would be the case when you have a trade window attached to the left of the chart), then you need to translate the Chart Window co-ordinates accordingly. for example - for the item drawn to the Device Context int x = sc.BarIndexToXPixelCoordinate(itr->barIndex()) - sc.StudyRegionLeftCoordinate; Hopefully this helps. |
