1
0
Fork 0
forked from len0rd/rockbox

checkwps: Warn if using SYSFONT in a viewport

Change-Id: Ief69dd489d08af62ed96624dfe504ab5b9f9e6d9
This commit is contained in:
Solomon Peachy 2025-03-07 09:39:53 -05:00
parent a05bd377ab
commit 8ef4f217d4

View file

@ -1071,11 +1071,7 @@ static int parse_progressbar_tag(struct skin_element* element,
pb->height = -1; /* calculate at display time */ pb->height = -1; /* calculate at display time */
else else
{ {
#ifndef __PCTOOL__
pb->height = font_get(vp->font)->height; pb->height = font_get(vp->font)->height;
#else
pb->height = 8;
#endif
} }
} }
/* optional params, first is the image filename if it isnt recognised as a keyword */ /* optional params, first is the image filename if it isnt recognised as a keyword */
@ -2164,6 +2160,10 @@ static bool skin_load_fonts(struct wps_data *data)
else if (font_id <= 0) else if (font_id <= 0)
{ {
vp->font = FONT_SYSFIXED; vp->font = FONT_SYSFIXED;
DEBUGF("WARNING: Do not use SYSFONT (id 0) in viewports!\n");
#ifdef __PCTOOL__
// success = false;
#endif
continue; continue;
} }