diff --git a/c/libs/GUI/GUI_Paint.c b/c/libs/GUI/GUI_Paint.c index 91b3981..1c751d0 100644 --- a/c/libs/GUI/GUI_Paint.c +++ b/c/libs/GUI/GUI_Paint.c @@ -570,6 +570,13 @@ void Paint_DrawString(UWORD Xstart, UWORD Ystart, const char * pString, UWORD Xpoint = Xstart; UWORD Ypoint = Ystart; + Debug("Width: "); + Debug(Paint.Width) + Debug("\n") + Debug("Height: ") + Debug(Paint.Height) + Debug("\n") + if (Xstart > Paint.Width || Ystart > Paint.Height) { Debug("Paint_DrawString_EN Input exceeds the normal display range\r\n"); return; diff --git a/c/src/p2fa.c b/c/src/p2fa.c index 8370ead..12658ae 100644 --- a/c/src/p2fa.c +++ b/c/src/p2fa.c @@ -31,6 +31,7 @@ int draw() { const char *confName = "default"; GoString confStr = {confName, strlen(confName)}; const char *code = getCode(confStr); + Debug("Code: %s", code); Paint_DrawString(5, 5, code, &Font24, WHITE, BLACK); Paint_DrawRectangle(10, 112, 240, 92, BLACK, DOT_PIXEL_1X1, DRAW_FILL_EMPTY);