[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: address@hidden: Two problems in Emacs-21.2.91 on Windows]

From: Kim F. Storm
Subject: Re: address@hidden: Two problems in Emacs-21.2.91 on Windows]
Date: 24 Oct 2002 11:35:07 +0200
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3.50

Juanma Barranquero <address@hidden> writes:

> On Thu, 24 Oct 2002 09:13:26 +0200 (IST), Eli Zaretskii <address@hidden> 
> wrote:
> > We could use some header that is common to all platforms, with a suitable 
> > ifdef if needed.
> I agree, if:
>  - There's a suitable .h file (I mean, not lisp.h or any non-UI oriented
>    .h file, which would be ugly).

dispextern.h seems like a good choice.  It actually uses XColor in a 

I suggest adding the following near the top of the file:

  #include <X11/Xlib.h>
  #ifdef USE_X_TOOLKIT
  #include <X11/Intrinsic.h>
  #endif /* USE_X_TOOLKIT */
+ #else /* !HAVE_X_WINDOWS */
+ /* X-related stuff used by non-X gui code. */
+ typedef struct {
+   unsigned long pixel;
+   unsigned short red, green, blue;
+   char flags;
+   char pad;
+ } XColor;
  #endif /* HAVE_X_WINDOWS */

>  - It's already (directly or indirectly) included in the relevant .c
>    files.
dispextern.h is included by all files using XColor!

> But I'm *really* not arguing. If you know of such a .h file, I'm not
> opposing to do it your way if people feels is better.

Avoiding [verbatim] duplication of code or defs always make me feel better :-)

Kim F. Storm <address@hidden> http://www.cua.dk

reply via email to

[Prev in Thread] Current Thread [Next in Thread]