navigation from one form to another.

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

 



 
Hi
 
   I am developing a reservation application in gtk under linux which consists of 10 transaction forms.
 
I have expirementing with  two forms in which i am navigating from one form to another with a click event.
In compilation itself i am getting many errors.I am not able to resolve.
 
          Kindly give me help.
 
Here i am attaching the program which i have done and the errors i am getting.
 

#include

<gtk/gtk.h>

#include

<glib.h>

#include

<stdio.h>

#include

<string.h>

gint destroyapp (GtkWidget *widget, gpointer gdata)

{

g_print ("Quitting...\n");

gtk_main_quit();

return (FALSE);

}

void

button_clicked(GtkWidget *widget, gpointer gdata)

{

gtk_main_quit();

int

main(int argc,char *argv[])

{

GtkWidget *window,*label,*box,*separator,*exit_btn;

gtk_init(&argc,&argv);

window=gtk_window_new(GTK_WINDOW_TOPLEVEL);

Gtk_Widget_show(window);

box=gtk_vbox_new(FALSE,10);

label=gtk_label_new("gtk");

separator=gtk_hseparator_new();

exit_btn=gtk_button_new_with_label("exit");

Gtk_Widget_show(label);

Gtk_Widget_show(box);

Gtk_Widget_show(separator);

Gtk_Widget_show(exit_btn);

Gtk_main();

return 0;

}

}

int

main (int argc, char *argv[])

{

GtkWidget *window;

GtkWidget *button;  

gtk_init (&argc, &argv);

window = gtk_window_new(GTK_WINDOW_TOPLEVEL);

button = gtk_button_new_with_label("Click Me");

gtk_signal_connect(GTK_OBJECT(window), "delete_event", GTK_SIGNAL_FUNC(destroyapp), NULL);

gtk_signal_connect(GTK_OBJECT(button), "clicked", GTK_SIGNAL_FUNC(button_clicked), NULL);

gtk_container_add(GTK_CONTAINER (window), button);

gtk_container_border_width (GTK_CONTAINER (window), 15);

gtk_widget_show(button);

gtk_widget_show(window);

gtk_main();

return 0;

}

The errors are as follows:

/tmp/cclYSbJO.o(.text+0x55): In function `main.0':
: undefined reference to `Gtk_Widget_show'

/tmp/cclYSbJO.o(.text+0xa3): In function `main.0':
: undefined reference to `Gtk_Widget_show'

/tmp/cclYSbJO.o(.text+0xb1): In function `main.0':
: undefined reference to `Gtk_Widget_show'

/tmp/cclYSbJO.o(.text+0xbf): In function `main.0':
: undefined reference to `Gtk_Widget_show'

/tmp/cclYSbJO.o(.text+0xcd): In function `main.0':
: undefined reference to `Gtk_Widget_show'

/tmp/cclYSbJO.o(.text+0xd5): In function `main.0':
: undefined reference to `Gtk_main'

collect2: ld returned 1 exit status.

_______________________________________________
gtk-list mailing list
gtk-list@xxxxxxxxx
http://mail.gnome.org/mailman/listinfo/gtk-list

[Index of Archives]     [Touch Screen Library]     [GIMP Users]     [Gnome]     [KDE]     [Yosemite News]     [Steve's Art]

  Powered by Linux