![](/media/cache/group/default_image.jpg.50x50_q85.jpg)
V.062 11/3
Dependencies: FT6206 SDFileSystem ILI9341_t3
Fork of ATT_AWS_IoT_demo_v06 by
Diff: TextField.h
- Revision:
- 30:8c979815f533
diff -r f71a0be59b99 -r 8c979815f533 TextField.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/TextField.h Wed Nov 15 19:28:37 2017 +0000 @@ -0,0 +1,33 @@ +#ifndef _TEXTFIELD_INC_ +#define _TEXTFIELD_INC_ + +#include "ILI9341_t3.h" + +class TextField { + + public: + TextField(); + + void setDisplay(ILI9341_t3 *pNewTft); + void setFieldInt(ILI9341_t3 *pNewTft, const char* fmt, int32_t data); + void setFieldStr(ILI9341_t3 *pNewTft, const char* fmt, const char* data); + void setFieldFloat(ILI9341_t3 *pNewTft, const char* fmt, float data); + + void setFieldLine(ILI9341_t3 *pNewTft, const char* fmt); + + + void drawFieldInt(int32_t data); + void drawFieldStr(const char* data, bool erase); + void drawFieldFloat(float data); + + protected: + void setupField(ILI9341_t3 *pNewTft, const char* buf); + void eraseField(bool erase=true); + + private: + ILI9341_t3 *pTft; + int16_t x, y, w, h; + const char* fmt; +}; + +#endif \ No newline at end of file