all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* color-gray-p
@ 2004-08-22 16:36 Luc Teirlinck
  2004-08-22 17:02 ` color-gray-p Devon
  0 siblings, 1 reply; 12+ messages in thread
From: Luc Teirlinck @ 2004-08-22 16:36 UTC (permalink / raw)
  Cc: bug-gnu-emacs

Devon Sean McCullough wrote:

    (color-gray-p "gray") signals (wrong-type-argument framep nil)

    Functions `color-gray-p' and `color-supported-p'
    do not work as documented.

These bugs occurred in 21.3, but they are fixed in Emacs CVS and,
hence, will be fixed in 21.4 (not yet released).

Sincerely,

Luc.

^ permalink raw reply	[flat|nested] 12+ messages in thread
* color-gray-p
@ 2004-08-22  5:36 Devon Sean McCullough
  0 siblings, 0 replies; 12+ messages in thread
From: Devon Sean McCullough @ 2004-08-22  5:36 UTC (permalink / raw)


In GNU Emacs 21.3.3 (i386-unknown-freebsd4.8, X toolkit, Xaw3d scroll bars)
 of 2003-06-08 on grant.org
Important settings:
  value of $LC_ALL: nil
  value of $LC_COLLATE: nil
  value of $LC_CTYPE: nil
  value of $LC_MESSAGES: nil
  value of $LC_MONETARY: nil
  value of $LC_NUMERIC: nil
  value of $LC_TIME: nil
  value of $LANG: nil
  locale-coding-system: nil
  default-enable-multibyte-characters: t

Please describe exactly what actions triggered the bug
and the precise symptoms of the bug:

(color-gray-p "gray") signals (wrong-type-argument framep nil)

Functions `color-gray-p' and `color-supported-p'
do not work as documented.  See patch to xfaces.c
below which seems to correct the trouble although
much is obscure to me, e.g. the second parameter
of CHECK_* is a total mystery.

Recent input:
( c o l o r - g r ESC TAB SPC " g r a y " ) C-j ESC 
x r e p o r t SPC e m SPC SPC RET

Recent messages:
(emacs -q)
For information about the GNU Project and its goals, type C-h C-p.
eval: 
Loading debug...done
Entering debugger...
 [2 times]
Loading emacsbug...done

--- emacs-21.3/src/xfaces.c.~1~	Thu Nov 14 08:15:48 2002
+++ emacs-21.3/src/xfaces.c	Fri Aug 20 13:22:13 2004
@@ -1476,15 +1476,17 @@
 {
   struct frame *f;
 
-  CHECK_FRAME (frame, 0);
   CHECK_STRING (color, 0);
+  if (NILP (frame))
+    frame = selected_frame;
+  CHECK_FRAME (frame, 0);
   f = XFRAME (frame);
   return face_color_gray_p (f, XSTRING (color)->data) ? Qt : Qnil;
 }
 
 
 DEFUN ("color-supported-p", Fcolor_supported_p,
-       Scolor_supported_p, 2, 3, 0,
+       Scolor_supported_p, 1, 3, 0,
   "Return non-nil if COLOR can be displayed on FRAME.\n\
 BACKGROUND-P non-nil means COLOR is used as a background.\n\
 If FRAME is nil or omitted, use the selected frame.\n\
@@ -1494,8 +1496,10 @@
 {
   struct frame *f;
 
-  CHECK_FRAME (frame, 0);
   CHECK_STRING (color, 0);
+  if (NILP (frame))
+    frame = selected_frame;
+  CHECK_FRAME (frame, 0);
   f = XFRAME (frame);
   if (face_color_supported_p (f, XSTRING (color)->data, !NILP (background_p)))
     return Qt;

^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2004-08-22 21:33 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-08-22 16:36 color-gray-p Luc Teirlinck
2004-08-22 17:02 ` color-gray-p Devon
2004-08-22 17:34   ` color-gray-p Luc Teirlinck
2004-08-22 17:41   ` color-gray-p Luc Teirlinck
2004-08-22 18:14     ` color-gray-p Devon
2004-08-22 18:21     ` color-gray-p Devon
2004-08-22 18:37       ` color-gray-p Luc Teirlinck
2004-08-22 18:58         ` color-gray-p Devon
2004-08-22 19:07           ` color-gray-p Luc Teirlinck
2004-08-22 21:33           ` color-gray-p Luc Teirlinck
2004-08-22 18:10   ` color-gray-p Luc Teirlinck
  -- strict thread matches above, loose matches on Subject: below --
2004-08-22  5:36 color-gray-p Devon Sean McCullough

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.