cancel
Showing results for 
Search instead for 
Did you mean: 

How to change the static graph line's color?

Junde
Senior II

Hi there,

As the title, I use a static graph with a line, and I want to change the line's color according the data.

But I check the API of static graph in TouchGFX document, I didn't find the function like setColor() or setLineColor().

How can I do it by code?

Thanks

1 ACCEPTED SOLUTION

Accepted Solutions
Junde
Senior II

I got it.

// the static graph object is named graph1
graph1Line1Painter.setColor(0x00FF00);

View solution in original post

1 REPLY 1
Junde
Senior II

I got it.

// the static graph object is named graph1
graph1Line1Painter.setColor(0x00FF00);