This repository has been archived by the owner on Dec 20, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
changeLabelTextSize()
Mammad900 edited this page Nov 5, 2020
·
1 revision
Resizes a label.
- page (
int
) : The number of the page which contains the label - index (
int
) : Index of the label relative to it's containing page. - X (
byte
) : X (height) text size for the label - Y (
byte
) : Y (width) text size for the label
Nothing
void changeLabelTextSize(int page, int i, byte X, byte Y) {
if ((label_textSizeX[page][i] != X) || (label_textSizeY[page][i] != Y)) {
HCT
if (CurrentPage == page) {
undrawlabel(page, i);
label_textSizeX[page][i] = X;
label_textSizeY[page][i] = Y;
drawlabel(page, i);
}
else {
label_textSizeX[page][i] = X;
label_textSizeY[page][i] = Y;
}
}
}
Note: HCT
is a macro for making the rest of the library aware that something has changed.