Warning message....



Hi,

I made a menu bar in which i have pic's and text (in a hbox) and it works.. 
but when i run the program the message

	Gdk-WARNING **: Creating pixmap from xpm with NULL window and colormap 

appears in the console... i don't know why this is happening...

here's the code:

----------------------------------------------------
(.....)
        GtkWidget *pixmapwid;
        GdkBitmap *mask;
        GtkStyle *style;
 
        caixa = gtk_hbox_new(FALSE, 0);
 
        gtk_widget_show(caixa);
 
        file_itens = gtk_menu_new();
 
        item_aux = gtk_menu_item_new_with_label("New Game");
 
        gtk_widget_show(item_aux);
 
 
        GdkPixmap*  pix = new GdkPixmap();
 
        style = gtk_widget_get_style( caixa );
 
        pix = gdk_pixmap_create_from_xpm (GTK_WIDGET( caixa )->window, &mask, 
&style->bg[GTK_STATE_NORMAL],"./images/xmms.xpm");
 
        pixmapwid = gtk_pixmap_new( pix, mask );
  
        gtk_box_pack_start(GTK_BOX(caixa), pixmapwid, TRUE, FALSE, 0);
 
        gtk_box_pack_end(GTK_BOX(caixa), item_aux, TRUE, FALSE, 0);
  
        gtk_widget_show(pixmapwid);
 
        GtkWidget *item_total = new GtkWidget();
 
        item_total = gtk_menu_item_new();
 
        gtk_container_add (GTK_CONTAINER (item_total), caixa);
 
        gtk_menu_append(GTK_MENU(file_itens), item_total);
 
        gtk_widget_show(item_total);

(.....)

-------------------------------------------------------

Nuno Afonso.




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