changeset 54766:b87089cc7e4c

(face_color_supported_p): Fix compilation without X11.
author Stefan Monnier <monnier@iro.umontreal.ca>
date Fri, 09 Apr 2004 16:15:08 +0000
parents 3129d46cd5b6
children 1c98354c2113
files src/xfaces.c
diffstat 1 files changed, 14 insertions(+), 10 deletions(-) [+]
line wrap: on
line diff
--- a/src/xfaces.c	Fri Apr 09 14:32:49 2004 +0000
+++ b/src/xfaces.c	Fri Apr 09 16:15:08 2004 +0000
@@ -1,5 +1,5 @@
 /* xfaces.c -- "Face" primitives.
-   Copyright (C) 1993, 1994, 1998, 1999, 2000, 2001, 2002, 2003
+   Copyright (C) 1993, 1994, 1998, 1999, 2000, 2001, 2002, 2003, 2004
    Free Software Foundation.
 
 This file is part of GNU Emacs.
@@ -1505,15 +1505,19 @@
   XColor not_used;
 
   XSETFRAME (frame, f);
-  return (FRAME_WINDOW_P (f)
-	  ? (!NILP (Fxw_display_color_p (frame))
-	     || xstricmp (color_name, "black") == 0
-	     || xstricmp (color_name, "white") == 0
-	     || (background_p
-		 && face_color_gray_p (f, color_name))
-	     || (!NILP (Fx_display_grayscale_p (frame))
-		 && face_color_gray_p (f, color_name)))
-	  : tty_defined_color (f, color_name, &not_used, 0));
+  return
+#ifdef HAVE_X_WINDOWS
+    FRAME_WINDOW_P (f)
+    ? (!NILP (Fxw_display_color_p (frame))
+       || xstricmp (color_name, "black") == 0
+       || xstricmp (color_name, "white") == 0
+       || (background_p
+	   && face_color_gray_p (f, color_name))
+       || (!NILP (Fx_display_grayscale_p (frame))
+	   && face_color_gray_p (f, color_name)))
+    :
+#endif
+    tty_defined_color (f, color_name, &not_used, 0);
 }