GNU bug report logs -
#59347
29.0.50; `:family` face setting ignored
Previous Next
Reported by: Stefan Monnier <monnier <at> iro.umontreal.ca>
Date: Fri, 18 Nov 2022 04:58:01 UTC
Severity: normal
Found in version 29.0.50
Done: Gregory Heytings <gregory <at> heytings.org>
Bug is archived. No further changes may be made.
Full log
Message #290 received at 59347 <at> debbugs.gnu.org (full text, mbox):
>> But when I specify the `weight` property of the `bold` face, it's not
>> clear at all that the `:family` of the default face should take precedence
>> over the `:weight` of the `bold` face.
>
> If we want to distinguish between explicitly requested attributes and
> inherited attributes, we need to store this information inside the
> font spec. (We have the :user-spec attribute, but it is used for
> slightly different purposes.)
Indeed.
>> FWIW, I've been running with your patch and I like the result.
>
> Which patch is that? The one proposed in the message to which you are
> responding, or one of the earlier ones?
See the hunk below.
> How would you determine the order in the stack? IOW, which attributes
> will be "the first"?
For attributes specified directly in a face the relative order is not
specified, but attributes directly specified would come before
inherited attributes, and similarly when we merge several faces,
attributes from the first face would come before those of later faces.
Stefan
@@ -3003,6 +3012,10 @@ font_find_for_lface (struct frame *f, Lisp_Object *attrs, Lisp_Object spec, int
}
ASET (work, FONT_SIZE_INDEX, Qnil);
+ /* Also ignore the font weight, which when set leads to suboptimal
+ font choices. See bug#59347. */
+ ASET (work, FONT_WEIGHT_INDEX, Qnil);
+
/* Foundry specification alternatives: from the most specific to the
least specific and finally an unspecified one. */
foundry[0] = AREF (work, FONT_FOUNDRY_INDEX);
This bug report was last modified 2 years and 159 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.