mirror of
https://github.com/opnsense/src.git
synced 2026-06-11 09:41:03 -04:00
vtfontcvt: Improve error message for unsupported DWIDTH
vtfontcvt requires that all glyphs are 1x or 2x a common width, reporting for example "bitmap with unsupported DWIDTH 27 0 on line xxx" if the font is expected to be 32 pixels wide. Add the expected / permitted values to the error message to make the issue more clear - for the same example, "bitmap with unsupported DWIDTH 27 0 (not 32 or 64)". Reviewed by: ziaee Sponsored by: The FreeBSD Foundation
This commit is contained in:
parent
caaeab697b
commit
3433daae0d
1 changed files with 2 additions and 2 deletions
|
|
@ -450,8 +450,8 @@ parse_bdf(FILE *fp, unsigned int map_idx)
|
|||
if (sscanf(ln + 7, "%d %d", &dwidth, &dwy) != 2)
|
||||
errx(1, "invalid DWIDTH at line %u", linenum);
|
||||
if (dwy != 0 || (dwidth != fbbw && dwidth * 2 != fbbw))
|
||||
errx(1, "bitmap with unsupported DWIDTH %d %d at line %u",
|
||||
dwidth, dwy, linenum);
|
||||
errx(1, "bitmap with unsupported DWIDTH %d %d (not %d or %d) at line %u",
|
||||
dwidth, dwy, fbbw, 2 * fbbw, linenum);
|
||||
if (dwidth < fbbw)
|
||||
set_width(dwidth);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue