Re: colormaps
- From: Russell Shaw <rjshaw iprimus com au>
- Cc: gtk-app-devel-list gnome org
- Subject: Re: colormaps
- Date: Fri, 17 Oct 2003 02:42:24 +1000
Olexiy Avramchenko wrote:
Russell Shaw wrote:
Hi,
In an expose-event callback of a gtk_drawing_area this always paints
a black region even tho i have it set for white:
...
You should allocate colors before gdk_gc_set_*ground calls. You see the
black color because of zero *pixel* field value in foreground/background
structures. If you want to avoid color allocation - use
gdk_gc_set_rgb_*_color functions:
http://developer.gnome.org/doc/API/2.0/gdk/gdk-Graphics-Contexts.html#gdk-gc-set-rgb-fg-color
Thanks.
I never understand colormaps stuff until now: http://www.gtk.org/faq/#AEN834
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]