textArea.invalidate(); makes my textArea disappear
Hello there,
i'm using touchgfx to show time data using
touchgfx::Unicode::snprintf(textArea1Buffer, TEXTAREA1_SIZE, "%d", sec);
but when I use invalidate() function to refresh the text area, the text disappear from my screen;
instead, the code getRootContainer().invalidate(); works well and make things correct.
by the way, the code using textArea1.invalidate(); can shown on TouchGFX simulator, it just doesn't work on my F411CEU6
here is my code:
uint16_t count = 0;
uint16_t sec = 0;
void Clock_screenView::handleTickEvent()
{
touchgfx::Rect Rect1;
if(count > 33)
{
touchgfx::Unicode::snprintf(textArea1Buffer, TEXTAREA1_SIZE, "%d", sec);
textArea1.invalidate();
//getRootContainer().invalidate();
count=0;
sec++;
}
else
{
count++;
}
}
Is there anyone, who can explain this phenomena?
Best regards
Rust
