all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: David Ponce <da_vid@orange.fr>
To: Eli Zaretskii <eliz@gnu.org>
Cc: luangruo@yahoo.com, 57652@debbugs.gnu.org, gregory@heytings.org
Subject: bug#57652: 29.0.50; Warning setting attribute of face ‘term’
Date: Thu, 8 Sep 2022 14:34:14 +0200	[thread overview]
Message-ID: <7b0977cd-a236-c9ad-887a-f23c98ed4a6e@orange.fr> (raw)
In-Reply-To: <83czc6fe9t.fsf@gnu.org>

On 08/09/2022 10:42, Eli Zaretskii wrote:
>> Cc: 57652@debbugs.gnu.org, gregory@heytings.org
>> Date: Thu, 8 Sep 2022 10:22:31 +0200
>> From: David Ponce <da_vid@orange.fr>
>>
>>      "Apart from the values given below, each face attribute can have the
>> value ‘unspecified’.  This special value means that the face doesn’t
>> specify that attribute directly.  An ‘unspecified’ attribute tells Emacs
>> to refer instead to a parent face (see the description ‘:inherit’
>> attribute below); or, failing that, to an underlying face (*note
>> Displaying Faces::).  (However, ‘unspecified’ is not a valid value in
>> ‘defface’.)"
>>
>> So it seems that unspecified is not allowed in defface.
> 
> Where does it say that unspecified is not allowed?  (And this doc
> string is from set-face-attribute, not from defface.)

I mentioned what is currently in the Emacs Lisp reference manual 
(lisp.info): (elisp)Top > Display > Faces > Face Attributes

>> So, how to specify a missing attribute excepted by using nil in the
>> defface used in term.el?
> 
> If you don't have anything to say about an attribute, just don't
> mention it in defface.  That's what unspecified means, as the doc
> string says.  So I'm unsure why you would need "to specify a missing
> attribute".

It is not me, it is how it is currently implemented in term.el:

(defcustom term-default-fg-color nil
   "If non-nil, default color for foreground in Term mode."
   :group 'term
   :type '(choice (const nil) (string :tag "color")))
(make-obsolete-variable 'term-default-fg-color "use the face `term' 
instead."
                         "24.3")

(defcustom term-default-bg-color nil
   "If non-nil, default color for foreground in Term mode."
   :group 'term
   :type '(choice (const nil) (string :tag "color")))
(make-obsolete-variable 'term-default-bg-color "use the face `term' 
instead."
                         "24.3")

(defface term
   `((t
      :foreground ,term-default-fg-color
      :background ,term-default-bg-color
      :inherit default))
   "Default face to use in Term mode."
   :group 'term)






  reply	other threads:[~2022-09-08 12:34 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-09-07 18:49 bug#57652: 29.0.50; Warning setting attribute of face ‘term’ David Ponce
2022-09-08  5:02 ` Po Lu via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-09-08  8:22   ` David Ponce
2022-09-08  8:42     ` Eli Zaretskii
2022-09-08 12:34       ` David Ponce [this message]
2022-09-08  8:43     ` David Ponce
2022-09-08 11:44     ` Akib Azmain Turja via Bug reports for GNU Emacs, the Swiss army knife of text editors

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=7b0977cd-a236-c9ad-887a-f23c98ed4a6e@orange.fr \
    --to=da_vid@orange.fr \
    --cc=57652@debbugs.gnu.org \
    --cc=eliz@gnu.org \
    --cc=gregory@heytings.org \
    --cc=luangruo@yahoo.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.