Hello,
I'm Modifyng the Climate Cabinet example.
I'm printing instead of the humidity value, a temperature value from an external input.
I wanted to add a StrokePath to the graph, so every step of the Running Bar, a point is drawn on the intersection of the Running Bar and the temperature bar.

In the method UpdateLayout of the Diagram in the climate cabinet example, i matched the Bounds of the stroke path with the graph ones.
I'm assuming the coordinates of the path are related to the pixels in the stroke path rectangle, so after that i made the stoke path begin in the bottom left corner, and the number of sub path items match with the graph width.
Graph.Bounds = rect( 2 * Climate::Spacing.x, y1, aSize.x - Climate::Spacing.x, y2 - Climate::Spacing.y );
StrokePath.Bounds = Graph.Bounds;
TempPath.InitSubPath( 0, Graph.Bounds.w);
TempPath.Begin(0, 0.0 ,StrokePath.Bounds.h);
When adding a new point to the line, i want to add it with the x coordinates to match the running bar coordinate and y to match the temperature bar y positition.
/* adjust running bar */
RunningBar.Visible = (Application::Device.StartCycle);
RunningBar.Bounds.origin = point( Graph.Bounds.x1 + ((totalTimems - Application::Device.RemainingTime)) * Graph.Bounds.w / (rangeTime*1000), Graph.Bounds.y1 );
//add tempPath Point
//humPos refers to the temperature bar y position, correct in the graph.
TempPath.AddLine(0,RunningBar.Bounds.origin.x, humPos);
The scaling and value rappresentation of the graph are consistent with the data recevied.
I'm getting this behavior:
The Stroke path Runs Ahead of the running bar by i presume a offset constant amount, represented by that initial ramp that i can't explain.
I'm printing the values on screen also:
Text1.String = "Running Bar X: " +string(RunningBar.Bounds.origin.x);
Text2.String = "StrokePath X: " + string(TempPath.GetPathBounds().point2.x);
Text3.String = "Temp Bar Y: " +string(HumidityBar.Bounds.origin.y);
Text4.String = "Stroke Path Y: " +string(TempPath.GetPathBounds().point2.y);
The x Position are the same, but not on the displayed stroke path.
The y position of the strokepath last point is not changing.