V.062 11/3

Dependencies:   FT6206 SDFileSystem ILI9341_t3

Fork of ATT_AWS_IoT_demo_v06 by attiot

Committer:
eggsylah
Date:
Thu Nov 16 21:49:45 2017 +0000
Revision:
32:62a026c88e22
Parent:
30:8c979815f533
V08 used in demo unigs

Who changed what in which revision?

UserRevisionLine numberNew contents of line
eggsylah 30:8c979815f533 1 #ifndef _TEXTFIELD_INC_
eggsylah 30:8c979815f533 2 #define _TEXTFIELD_INC_
eggsylah 30:8c979815f533 3
eggsylah 30:8c979815f533 4 #include "ILI9341_t3.h"
eggsylah 30:8c979815f533 5
eggsylah 30:8c979815f533 6 class TextField {
eggsylah 30:8c979815f533 7
eggsylah 30:8c979815f533 8 public:
eggsylah 30:8c979815f533 9 TextField();
eggsylah 30:8c979815f533 10
eggsylah 30:8c979815f533 11 void setDisplay(ILI9341_t3 *pNewTft);
eggsylah 30:8c979815f533 12 void setFieldInt(ILI9341_t3 *pNewTft, const char* fmt, int32_t data);
eggsylah 30:8c979815f533 13 void setFieldStr(ILI9341_t3 *pNewTft, const char* fmt, const char* data);
eggsylah 30:8c979815f533 14 void setFieldFloat(ILI9341_t3 *pNewTft, const char* fmt, float data);
eggsylah 30:8c979815f533 15
eggsylah 30:8c979815f533 16 void setFieldLine(ILI9341_t3 *pNewTft, const char* fmt);
eggsylah 30:8c979815f533 17
eggsylah 30:8c979815f533 18
eggsylah 30:8c979815f533 19 void drawFieldInt(int32_t data);
eggsylah 30:8c979815f533 20 void drawFieldStr(const char* data, bool erase);
eggsylah 30:8c979815f533 21 void drawFieldFloat(float data);
eggsylah 30:8c979815f533 22
eggsylah 30:8c979815f533 23 protected:
eggsylah 30:8c979815f533 24 void setupField(ILI9341_t3 *pNewTft, const char* buf);
eggsylah 30:8c979815f533 25 void eraseField(bool erase=true);
eggsylah 30:8c979815f533 26
eggsylah 30:8c979815f533 27 private:
eggsylah 30:8c979815f533 28 ILI9341_t3 *pTft;
eggsylah 30:8c979815f533 29 int16_t x, y, w, h;
eggsylah 30:8c979815f533 30 const char* fmt;
eggsylah 30:8c979815f533 31 };
eggsylah 30:8c979815f533 32
eggsylah 30:8c979815f533 33 #endif