help me!



 
 Havoc Pennington, 
 
 
I see ur mail id in mailing list. 
 
I want a small help in gtk. 
 
The problem is i cand draw that image with the following code 
 
 
#include <gtk/gtk.h> 
                                                                                                                
void close_application( GtkWidget *widget, GdkEvent 
*event, gpointer data ) { 
gtk_main_quit(); 
} 
 
int main (int argc, char *argv[]) 
{ 
GtkWidget *window; 
GdkPixbuf *pixbuf; 
//GdkColormap *colormap; 
                                                                                                                
gtk_init (&argc, &argv); 
                                                                                                                
//colormap = gdk_colormap_get_system(); 
window = gtk_window_new( GTK_WINDOW_TOPLEVEL); 
//gdk_drawable_set_colormap(window->window, colormap); 
                                                                                                                
gtk_signal_connect (GTK_OBJECT (window), "delete_event", 
                         GTK_SIGNAL_FUNC (close_application), NULL); 
gtk_widget_show (window); 
                                                                                                                
pixbuf = gdk_pixbuf_new_from_file((gchar *) "mandir_n.png", NULL); 
                                                                                                                
gdk_draw_pixbuf(window->window, NULL, GDK_PIXBUF 
(pixbuf),0,0,100,100,gdk_pixbuf_get_width (pixbuf),gdk_pixbuf_get_height (pixbuf),GDK_RGB_DITHER_NONE,0,0); 
gtk_main (); 
                                                                                                                
     return 0; 
} 
 
 
 
what is wrong with here. The prog has no error in compiling. 
 
please help me 
 
Thanks in advance 
 
Manoj 
-- 
______________________________________________
Check out the latest SMS services @ http://www.linuxmail.org 
This allows you to send and receive SMS through your mailbox.


Powered by Outblaze



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