2025-01-03 10:52 AM
I am having trouble finding how to change the interval of the major gridlines dynamically. I am using the scrolling graph and have implemented dynamic Y-axis range, but I want to be able to change the intervals of the gridlines as well. Is this possible using touchGFX tools or do I need to make a custom widget?
Solved! Go to Solution.
2025-01-07 10:02 AM
Thank you.
I discovered that the labels and grids are not manipulated through the graph object, but look like they are their own separate objects.
I was originally trying to find something like graph.setYinterval();
My solution was to use graphMajorYAxisGrid.setInterval();
Eventually added graphMajorYAxisLabel.setInterval(); To make labels match
2025-01-07 09:24 AM - edited 2025-01-07 09:31 AM
Hello Ethan
Have you simply try to use setInterval- function for to grid you need to manipulate dynamically ?
If you look your generated xxxxBase.cpp code, you will see how interval is set initially (and also other dynamic graph parameters, like setGraphRangeY which is also closely involved to your issue).
Hope this help
Br JTP
ps. this might also intrest you
2025-01-07 10:02 AM
Thank you.
I discovered that the labels and grids are not manipulated through the graph object, but look like they are their own separate objects.
I was originally trying to find something like graph.setYinterval();
My solution was to use graphMajorYAxisGrid.setInterval();
Eventually added graphMajorYAxisLabel.setInterval(); To make labels match