Sat Jun 17 19:52:25 PDT 2000 Michael Jennings <mej@eterm.org>
Patch from Martin Grimm <grimm.martin@gmx.de> to fix the parsing of the font fx stuff. SVN revision: 2818
This commit is contained in:
parent
a6f80249cf
commit
93c90b74bb
|
@ -3692,3 +3692,9 @@ Fri Jun 16 13:29:59 PDT 2000 Michael Jennings <mej@eterm.org>
|
||||||
image tiling in Esetroot.
|
image tiling in Esetroot.
|
||||||
|
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
|
Sat Jun 17 19:52:25 PDT 2000 Michael Jennings <mej@eterm.org>
|
||||||
|
|
||||||
|
Patch from Martin Grimm <grimm.martin@gmx.de> to fix the parsing of
|
||||||
|
the font fx stuff.
|
||||||
|
|
||||||
|
-------------------------------------------------------------------------------
|
||||||
|
|
|
@ -1999,12 +1999,16 @@ parse_attributes(char *buff, void *state)
|
||||||
char *tmp = PWord(2, buff);
|
char *tmp = PWord(2, buff);
|
||||||
unsigned char n;
|
unsigned char n;
|
||||||
|
|
||||||
if (NumWords(buff) != 3) {
|
if (!BEG_STRCASECMP(tmp, "fx ") || !BEG_STRCASECMP(tmp, "effect")) {
|
||||||
|
if (parse_font_fx(PWord(2, tmp)) != 1) {
|
||||||
|
print_error("Parse error in file %s, line %lu: Syntax error in font effects specification",
|
||||||
|
file_peek_path(), file_peek_line());
|
||||||
|
}
|
||||||
|
} else if (NumWords(buff) != 3) {
|
||||||
print_error("Parse error in file %s, line %lu: Invalid parameter list \"%s\" for "
|
print_error("Parse error in file %s, line %lu: Invalid parameter list \"%s\" for "
|
||||||
"attribute font", file_peek_path(), file_peek_line(), NONULL(tmp));
|
"attribute font", file_peek_path(), file_peek_line(), NONULL(tmp));
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
} else if (isdigit(*tmp)) {
|
||||||
if (isdigit(*tmp)) {
|
|
||||||
n = (unsigned char) strtoul(tmp, (char **) NULL, 0);
|
n = (unsigned char) strtoul(tmp, (char **) NULL, 0);
|
||||||
if (n <= 255) {
|
if (n <= 255) {
|
||||||
eterm_font_add(&etfonts, PWord(2, tmp), n);
|
eterm_font_add(&etfonts, PWord(2, tmp), n);
|
||||||
|
@ -2022,11 +2026,6 @@ parse_attributes(char *buff, void *state)
|
||||||
} else if (!BEG_STRCASECMP(tmp, "default ")) {
|
} else if (!BEG_STRCASECMP(tmp, "default ")) {
|
||||||
def_font_idx = strtoul(PWord(2, tmp), (char **) NULL, 0);
|
def_font_idx = strtoul(PWord(2, tmp), (char **) NULL, 0);
|
||||||
|
|
||||||
} else if (!BEG_STRCASECMP(tmp, "fx ") || !BEG_STRCASECMP(tmp, "effect")) {
|
|
||||||
if (parse_font_fx(PWord(2, tmp)) != 1) {
|
|
||||||
print_error("Parse error in file %s, line %lu: Syntax error in font effects specification",
|
|
||||||
file_peek_path(), file_peek_line());
|
|
||||||
}
|
|
||||||
} else {
|
} else {
|
||||||
tmp = Word(1, tmp);
|
tmp = Word(1, tmp);
|
||||||
print_error("Parse error in file %s, line %lu: Invalid font index \"%s\"",
|
print_error("Parse error in file %s, line %lu: Invalid font index \"%s\"",
|
||||||
|
|
Loading…
Reference in New Issue