mirror of
https://github.com/zyphlar/bdf2c.git
synced 2024-03-08 13:47:46 +00:00
Resolve compiler warnings to comply with -Werror; tabs to spaces
This commit is contained in:
parent
b07deb7a48
commit
003f1e97bb
11
bdf2c.c
11
bdf2c.c
|
@ -232,9 +232,9 @@ void DumpCharacter(FILE * out, unsigned char *bitmap, int fontwidth, int fonthei
|
||||||
fputc('\t', out);
|
fputc('\t', out);
|
||||||
for (x = 0; x < fontwidth; x += 8) {
|
for (x = 0; x < fontwidth; x += 8) {
|
||||||
// if current row is above or below the bitmap, output a blank row
|
// if current row is above or below the bitmap, output a blank row
|
||||||
if(y < yoffset || y > yoffset + charheight)
|
if(y < yoffset || y > yoffset + charheight) {
|
||||||
c = 0;
|
c = 0;
|
||||||
else
|
} else {
|
||||||
c = bitmap[(y - yoffset) * ((fontwidth + 7) / 8) + x / 8];
|
c = bitmap[(y - yoffset) * ((fontwidth + 7) / 8) + x / 8];
|
||||||
|
|
||||||
//printf("%d = %d\n", y * ((width+7)/8) + x/8, c);
|
//printf("%d = %d\n", y * ((width+7)/8) + x/8, c);
|
||||||
|
@ -280,6 +280,7 @@ void DumpCharacter(FILE * out, unsigned char *bitmap, int fontwidth, int fonthei
|
||||||
}
|
}
|
||||||
fputc(',', out);
|
fputc(',', out);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
fputc('\n', out);
|
fputc('\n', out);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -394,7 +395,7 @@ void ReadBdf(FILE * bdf, FILE * out, const char *name)
|
||||||
char *p;
|
char *p;
|
||||||
int fontboundingbox_width;
|
int fontboundingbox_width;
|
||||||
int fontboundingbox_height;
|
int fontboundingbox_height;
|
||||||
int fontboundingbox_xoff;
|
// int fontboundingbox_xoff;
|
||||||
int fontboundingbox_yoff;
|
int fontboundingbox_yoff;
|
||||||
int chars;
|
int chars;
|
||||||
int i;
|
int i;
|
||||||
|
@ -414,7 +415,7 @@ void ReadBdf(FILE * bdf, FILE * out, const char *name)
|
||||||
|
|
||||||
fontboundingbox_width = 0;
|
fontboundingbox_width = 0;
|
||||||
fontboundingbox_height = 0;
|
fontboundingbox_height = 0;
|
||||||
fontboundingbox_xoff = 0;
|
// fontboundingbox_xoff = 0;
|
||||||
fontboundingbox_yoff = 0;
|
fontboundingbox_yoff = 0;
|
||||||
chars = 0;
|
chars = 0;
|
||||||
for (;;) {
|
for (;;) {
|
||||||
|
@ -431,7 +432,7 @@ void ReadBdf(FILE * bdf, FILE * out, const char *name)
|
||||||
p = strtok(NULL, " \t\n\r");
|
p = strtok(NULL, " \t\n\r");
|
||||||
fontboundingbox_height = atoi(p);
|
fontboundingbox_height = atoi(p);
|
||||||
p = strtok(NULL, " \t\n\r");
|
p = strtok(NULL, " \t\n\r");
|
||||||
fontboundingbox_xoff = atoi(p);
|
// fontboundingbox_xoff = atoi(p);
|
||||||
p = strtok(NULL, " \t\n\r");
|
p = strtok(NULL, " \t\n\r");
|
||||||
fontboundingbox_yoff = atoi(p);
|
fontboundingbox_yoff = atoi(p);
|
||||||
} else if (!strcasecmp(s, "CHARS")) {
|
} else if (!strcasecmp(s, "CHARS")) {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user