diff options
author | Stephane Marchesin <stephane.marchesin@gmail.com> | 2010-05-07 21:21:54 -0700 |
---|---|---|
committer | Stephane Marchesin <stephane.marchesin@gmail.com> | 2010-05-07 21:21:54 -0700 |
commit | 5d8136b120819d3fb3f92dea832147f54dab2669 (patch) | |
tree | 24ac188785c203a724747fb57c13e0958c592102 | |
parent | a54e8e11f50279ac03273d047688d2681a059893 (diff) |
More color.
-rw-r--r-- | xlib_api.c | 6 |
1 files changed, 5 insertions, 1 deletions
@@ -192,7 +192,7 @@ Status XParseColor( XColor* exact_def_return ) { - unsigned short r,g,b; + unsigned long r,g,b; if (!spec) return BadValue; if (spec[0] == '#') @@ -222,6 +222,10 @@ Status XParseColor( default: return BadValue; } + exact_def_return -> red = r; + exact_def_return -> green = g; + exact_def_return -> blue = b; + exact_def_return -> pixel = (r << 32) | (g << 16) | b; printf("parse color ok %x-%x-%x\n",r>>8,g>>8,b>>8); } else |