diff options
| author | Chong Yidong | 2009-01-12 02:32:08 +0000 |
|---|---|---|
| committer | Chong Yidong | 2009-01-12 02:32:08 +0000 |
| commit | 5e5e80fb43b19caa1eb003a96c0a7cba00126983 (patch) | |
| tree | 1fce40055ebf0deb67f46324c425bb50e0e698b4 /src | |
| parent | 944636b8cf537c66b9764e9b2270bca6c3708a65 (diff) | |
| download | emacs-5e5e80fb43b19caa1eb003a96c0a7cba00126983.tar.gz emacs-5e5e80fb43b19caa1eb003a96c0a7cba00126983.zip | |
(Finternal_set_lisp_face_attribute): If setting the family, clear the
font width index too.
Diffstat (limited to 'src')
| -rw-r--r-- | src/xfaces.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/xfaces.c b/src/xfaces.c index 54c317a5ea7..141d565203f 100644 --- a/src/xfaces.c +++ b/src/xfaces.c | |||
| @@ -3341,6 +3341,12 @@ FRAME 0 means change the face on all frames, and change the default | |||
| 3341 | the attribute is mandatory. Also, clear the average | 3341 | the attribute is mandatory. Also, clear the average |
| 3342 | width. */ | 3342 | width. */ |
| 3343 | font_clear_prop (XVECTOR (lface)->contents, prop_index); | 3343 | font_clear_prop (XVECTOR (lface)->contents, prop_index); |
| 3344 | |||
| 3345 | /* If we are setting QCfamily, clear out FONT_WIDTH_INDEX as | ||
| 3346 | well. This avoids rejecting valid families that lack support | ||
| 3347 | for a particular width. */ | ||
| 3348 | if (prop_index == FONT_FAMILY_INDEX) | ||
| 3349 | font_clear_prop (XVECTOR (lface)->contents, FONT_WIDTH_INDEX); | ||
| 3344 | } | 3350 | } |
| 3345 | 3351 | ||
| 3346 | /* Changing a named face means that all realized faces depending on | 3352 | /* Changing a named face means that all realized faces depending on |