diff --git a/components/dwin/var_icon.cpp b/components/dwin/var_icon.cpp index 6ca3144..5d85d58 100644 --- a/components/dwin/var_icon.cpp +++ b/components/dwin/var_icon.cpp @@ -69,6 +69,8 @@ void VarIcon::setpos(uint16_t posx, uint16_t posy) { flushcfg(); } + + void VarIcon::dumpinfo() { readcfg(); printf("m_VP = %04x\n", m_descript.m_VP); diff --git a/components/dwin/var_icon.hpp b/components/dwin/var_icon.hpp index 5392ddd..ee159ac 100644 --- a/components/dwin/var_icon.hpp +++ b/components/dwin/var_icon.hpp @@ -45,6 +45,15 @@ class VarIcon { void initcfg(uint16_t valpointerAdd, uint16_t initval, uint16_t posx, uint16_t posy, uint16_t iconlib, uint16_t iconmin, uint16_t iconmax); void setpos(uint16_t posx, uint16_t posy); + void setpos_x(uint16_t posx) { + m_descript.m_PosX = posx; + flushcfg(); + } + + void setpos_y(uint16_t posy) { + m_descript.m_PosY = posy; + flushcfg(); + } /** * @brief