[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Emacs-diffs] Changes to emacs/src/xfaces.c,v
From: |
Juanma Barranquero |
Subject: |
Re: [Emacs-diffs] Changes to emacs/src/xfaces.c,v |
Date: |
Fri, 1 Aug 2008 16:54:51 +0200 |
On Fri, Aug 1, 2008 at 13:48, Adrian Robert <address@hidden> wrote:
> + cmap = Fcons (Fcons (build_string (name),
> + make_number ((red << 16) | (green << 8) |
> blue)),
> + cmap);
This is a change over the original function, and in fact it doesn't
work on Windows because of byte order issues.
Either the attached patch, or adding a new RGB_TO_EMACS_INT macro, is needed.
Juanma
Index: src/xfaces.c
===================================================================
RCS file: /cvsroot/emacs/emacs/src/xfaces.c,v
retrieving revision 1.409
diff -u -2 -r1.409 xfaces.c
--- src/xfaces.c 1 Aug 2008 14:01:08 -0000 1.409
+++ src/xfaces.c 1 Aug 2008 14:43:37 -0000
@@ -6601,5 +6601,9 @@
name[num] = 0;
cmap = Fcons (Fcons (build_string (name),
- make_number ((red << 16) | (green <<
8) | blue)),
+#ifdef WINDOWSNT
+ make_number (RGB (red, green, blue))),
+#else
+ make_number ((red << 16) | (green << 8) |
blue)),
+#endif
cmap);
}
- Re: [Emacs-diffs] Changes to emacs/src/xfaces.c,v,
Juanma Barranquero <=