Re: [gtk-list] gdk_draw_rgb_32_image()

On Tue, Feb 16, 1999 at 08:55:00PM +0000, Hrafnkell Eiriksson wrote:
> static gint expose_event (GtkWidget *widget, GdkEventExpose *event) {
>    gdk_draw_rgb_32_image(widget->window,
>                         widget->style->white_gc,
>                         event->area.x, event->area.y, i->w, i->h,
>                         GDK_RGB_DITHER_NONE, i->raster, i->w);
>    return FALSE;
> }                                             
> When running my program it segfaults on the gdk_draw_rgb_32_imgage().
> The i pointer is valid and so is i->raster
> What am I doing wrong?

You forgot gdk_rgb_init().

See testrgb.c in the GTK+ source directory.

Andreas E. Bombe <>

PGP 1024bit ID:0x886663c9 fingerprint: 30EC0973847B5583 C47A91D99DC54BB0
    2048bit ID:0xF62D5CC1 fingerprint: 136BBC1536B8B77A 200558E86FAAF8ED

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]