Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
emacs
emacs
Commits
57c82a63
Commit
57c82a63
authored
Aug 28, 1994
by
Richard M. Stallman
Browse files
(Fx_color_defined_p): Return list of RGB values, not just t.
parent
3b0deae5
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
2 deletions
+10
-2
src/xfns.c
src/xfns.c
+10
-2
No files found.
src/xfns.c
View file @
57c82a63
...
...
@@ -2944,7 +2944,8 @@ even if they match PATTERN and FACE.")
DEFUN ("x-color-defined-p", Fx_color_defined_p, Sx_color_defined_p, 1, 1, 0,
"Return t if the current X display supports the color named COLOR.")
"Return non-nil if the X display supports the color named COLOR.\n\
The value is actually a list of integer RGB values--(RED GREEN BLUE).")
(color)
Lisp_Object color;
{
...
...
@@ -2954,7 +2955,14 @@ DEFUN ("x-color-defined-p", Fx_color_defined_p, Sx_color_defined_p, 1, 1, 0,
CHECK_STRING (color, 0);
if (defined_color (XSTRING (color)->data, &foo))
return Qt;
{
Lisp_Object rgb[3];
rgb[0] = make_number (foo.red);
rgb[1] = make_number (foo.green);
rgb[2] = make_number (foo.blue);
return Flist (3, rgb);
}
else
return Qnil;
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment