Subject: Re: bug#14647: 24.3.50; doc of `set-face-font'

From: Lars Ingebrigtsen <[email-masked]>
Date: Fri, 01 Nov 2019 18:29:47 +0100

Lars Ingebrigtsen <[email-masked]> writes:

> Drew Adams <[email-masked]> writes:
>
>> 1. Neither the Elisp manual (node `Attribute Functions') nor the doc
>> string says what form the string FONT must or may take.
>
> Good question.  The function is barely used in the Emacs source code
> tree.  The only usage I could find that set it to something was this:
>
> (defvar gamegrid-font "-*-courier-medium-r-*-*-*-140-100-75-*-*-iso8859-*"
>   "Name of the font used in X mode.")

But it's basically any string that describes a font on your system,
depending on what font system you have.  So "futura:size=20" works fine,
too.

>> 2. The manual says that this command sets the :font attribute.  The doc
>> string says instead that it sets attributes :family, :foundry, :width,
>> :height, :weight, and :slant.  Which is it?
>
> Yeah.

It looks like it's the latter, so I've altered the documentation in the
manual.

>> 3. #1 is all the more imporatnt because the doc string of `x-list-fonts'
>> says that it returns a list of strings that are "suitable as arguments
>> to `set-face-font'.  Really?  Just what kind of strings are so suitable?
>>
>> I think, but am not sure, that FONT must be in XLFD form.  Whatever the
>> acceptable form(s), the doc needs to spell this out.

I don't think so -- we aren't told what the form is, because that seems
unnecessary.  If we're curious for some reason, we can just call the
function.

So I'm closing this bug report.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no