diff options
author | Chong Yidong <[email protected]> | 2011-01-26 19:45:30 -0500 |
---|---|---|
committer | Chong Yidong <[email protected]> | 2011-01-26 19:45:30 -0500 |
commit | 37d1c45d60c946768ff107bc68141e063dbe80be (patch) | |
tree | c1b2c94b8fae00aab2e00e64b47a0d3d86fec354 | |
parent | ca9c274ae72514a3b06b805456e656ff5ea7d58d (diff) |
Fix GTK font name parsing to allow numbers in names (Bug#7853).
A better fix is already in the trunk.
* src/font.c (font_parse_fcname): Require GTK-style font sizes to
occur at the end of the font string (Bug#7853).
-rw-r--r-- | src/ChangeLog | 5 | ||||
-rw-r--r-- | src/font.c | 3 |
2 files changed, 7 insertions, 1 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index bbfd9592cf..c74732b421 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,8 @@ +2011-01-27 Chong Yidong <[email protected]> + + * font.c (font_parse_fcname): Require GTK-style font sizes to + occur at the end of the font string (Bug#7853). + 2011-01-26 Chong Yidong <[email protected]> * font.c (font_parse_fcname): Fix typo in string length. diff --git a/src/font.c b/src/font.c index 96c043626f..ebf0b547b9 100644 --- a/src/font.c +++ b/src/font.c @@ -1549,7 +1549,8 @@ font_parse_fcname (name, font) size_found = 0; break; } - if (size_found) + /* GTK font sizes must occur at the end. */ + if (size_found && *q == '\0') { double point_size = strtod (p, &q); ASET (font, FONT_SIZE_INDEX, make_float (point_size)); |