comparison src/xfaces.c @ 103228:7300fabaa28b

* xfaces.c (tty_supports_face_attributes_p): Recognize unspecified weight when testing attributes (Bug#3282).
author Chong Yidong <cyd@stupidchicken.com>
date Thu, 14 May 2009 21:37:02 +0000
parents fa8e2c663118
children eb941fcd33b4
comparison
equal deleted inserted replaced
103227:aa902960b81b 103228:7300fabaa28b
5173 5173
5174 5174
5175 /* Test for terminal `capabilities' (non-color character attributes). */ 5175 /* Test for terminal `capabilities' (non-color character attributes). */
5176 5176
5177 /* font weight (bold/dim) */ 5177 /* font weight (bold/dim) */
5178 weight = FONT_WEIGHT_NAME_NUMERIC (attrs[LFACE_WEIGHT_INDEX]); 5178 val = attrs[LFACE_WEIGHT_INDEX];
5179 if (weight >= 0) 5179 if (!UNSPECIFIEDP (val)
5180 && (weight = FONT_WEIGHT_NAME_NUMERIC (val), weight >= 0))
5180 { 5181 {
5181 int def_weight = FONT_WEIGHT_NAME_NUMERIC (def_attrs[LFACE_WEIGHT_INDEX]); 5182 int def_weight = FONT_WEIGHT_NAME_NUMERIC (def_attrs[LFACE_WEIGHT_INDEX]);
5182 5183
5183 if (weight > 100) 5184 if (weight > 100)
5184 { 5185 {