Re: gdk_gc_set_foreground(): not working over DirectFB
- From: Sven Neumann <sven gimp org>
- To: Prasanna Kumar K <prasanna tataelxsi co in>
- Cc: gtk-devel-list gnome org, amirthakaruna tataelxsi co in
- Subject: Re: gdk_gc_set_foreground(): not working over DirectFB
- Date: Tue, 14 Nov 2006 09:29:20 +0100
Hi,
On Mon, 2006-11-13 at 14:40 +0530, Prasanna Kumar K wrote:
> + GdkColor color;
> +
> + color.pixel = 0xffff0000;
> + gdk_gc_set_foreground (widget->style->fg_gc[GTK_WIDGET_STATE (widget)], &color);
You are using an unallocated color here. There's
gdk_gc_set_rgb_fg_color() for that purpose. Kalle already outlined other
issues with this code in another mail so I am not going to comment on
the fact that it is a bad idea to access the widget's style directly.
Sven
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]