Graph is only used within TouchGFX.
 
Symbols
loading...
Files
loading...

Graph class

@class Graph Graph.hpp gui/graph_screen/Graph.hpp A graph with line, area below and dots. A graph with line, area below and dots. To save space, the 4 graph components are linked to share the same memory for graph points. @sa Container

Syntax

class Graph : public Container { public:     Graph();     virtual ~Graph();     void setup(int newWidth, int newHeight, uint16_t lineColor, uint16_t backgroundColor);     bool addValue(int x, int y)      {          return graphLine.addValue(x, y);      }     bool deleteValue(int x)      {          return graphLine.deleteValue(x);     }     void clear()      {          graphLine.clearGraph();             }      void setRange(int left, int right, int top, int bottom) ;     void setLineVisible(bool lineVisible);     void setDotsVisible(bool dotsVisible);     void setDotsBackgroundVisible(bool dotsBackgroundVisible);     void setAreaVisible(bool areaVisible);     void setDotShape(int startAngle, int angleStep, int lineWidth);     void setDotBackgroundShape(int startAngle, int angleStep, int lineWidth);     void setAlpha(uint8_t alpha);     uint8_t getAlpha();     static const int NUMBER_OF_POINTS = 40;  protected:     GraphLine graphLine;                GraphBelow graphArea;               GraphDots graphDots;                GraphDots graphDotsBackground;      GraphLine::GraphPoint graphBuffer[NUMBER_OF_POINTS];      PainterRGB565 graphLinePainter;                PainterRGB565 graphDotsPainter;                PainterRGB565 graphDotsBackgroundPainter;      PainterVerticalAlpha graphAreaPainter;         uint8_t myAlpha;  };

Fields

NUMBER_OF_POINTS

No summary provided. Read more...

graphLine

No summary provided. Read more...

graphArea

No summary provided. Read more...

graphDots

No summary provided. Read more...

graphDotsBackground

No summary provided. Read more...

graphBuffer

No summary provided. Read more...

graphLinePainter

No summary provided. Read more...

graphDotsPainter

No summary provided. Read more...

graphDotsBackgroundPainter

No summary provided. Read more...

graphAreaPainter

No summary provided. Read more...

myAlpha

No summary provided. Read more...

Methods

setup()

@fn void Graph::setup(int newWidth, int newHeight, uint16_t lineColor, uint16_t backgroundColor); Set characteristics of the graph. Set characteristics of the graph. Read more...

addValue()

@fn bool Graph::addValue(int x, int y) Adds a point to the graph. Adds a point to the graph. Read more...

deleteValue()

@fn bool Graph::deleteValue(int x) Deletes the value for the given x. Read more...

clear()

@fn void Graph::clear() Clears the graph. Clears the graph. Read more...

setRange()

@fn void Graph::setRange(int left, int right, int top, int bottom); Sets the range for the graph. Sets the range for the graph. Read more...

setLineVisible()

@fn void Graph::setLineVisible(bool lineVisible); Sets line visible. Sets line visible. Read more...

setDotsVisible()

@fn void Graph::setDotsVisible(bool dotsVisible); Sets dots visible. Sets dots visible. Read more...

setDotsBackgroundVisible()

@fn void Graph::setDotsBackgroundVisible(bool dotsBackgroundVisible); Sets dots background visible. Sets dots background visible. Read more...

setAreaVisible()

@fn void Graph::setAreaVisible(bool areaVisible); Sets area visible. Sets area visible. Read more...

setDotShape()

@fn void Graph::setDotShape(int startAngle, int angleStep, int lineWidth); Sets dot shape. Sets dot shape. Read more...

setDotBackgroundShape()

@fn void Graph::setDotBackgroundShape(int startAngle, int angleStep, int lineWidth); Sets dot background shape. Sets dot background shape. Read more...

setAlpha()

@fn void Graph::setAlpha(uint8_t alpha); Sets the alpha. Sets the alpha. Read more...

getAlpha()

@fn uint8_t Graph::getAlpha(); Gets the alpha. Gets the alpha. Read more...

Class Tree

Child classes
Graph
all items filtered out
Variables of Graph type
Graph