only for RuBoard - do not distribute or recompile |
The interface.c and tabular.glade files are included in this section.
Listing C.3 is the Glade-generated file for the tabular executable window widget. It creates a single form (frm_tabular) and returns a pointer to the newly created form.
/* * DO NOT EDIT THIS FILE - it is generated by Glade. */ #ifdef HAVE_CONFIG_H # include <config.h> #endif #include <sys/types.h> #include <sys/stat.h> #include <unistd.h> #include <string.h> #include <gdk/gdkkeysyms.h> #include <gtk/gtk.h> #include "callbacks.h" #include "interface.h" #include "support.h" GtkWidget* create_frm_tabular (void) { GtkWidget *frm_tabular; GtkWidget *vbox1; GtkWidget *scrolledwindow1; GtkWidget *clist1; GtkWidget *label1; GtkWidget *label2; GtkWidget *label3; GtkWidget *statusbar1; frm_tabular = gtk_window_new (GTK_WINDOW_TOPLEVEL); gtk_object_set_data (GTK_OBJECT (frm_tabular), "frm_tabular", frm_tabular); gtk_window_set_title (GTK_WINDOW (frm_tabular), "Top Commission Earners"); gtk_window_set_default_size (GTK_WINDOW (frm_tabular), 280, 500); vbox1 = gtk_vbox_new (FALSE, 0); gtk_widget_ref (vbox1); gtk_object_set_data_full (GTK_OBJECT (frm_tabular), "vbox1", vbox1, (GtkDestroyNotify) gtk_widget_unref); gtk_widget_show (vbox1); gtk_container_add (GTK_CONTAINER (frm_tabular), vbox1); scrolledwindow1 = gtk_scrolled_window_new (NULL, NULL); gtk_widget_ref (scrolledwindow1); gtk_object_set_data_full (GTK_OBJECT (frm_tabular), "scrolledwindow1", scrolledwindow1, (GtkDestroyNotify) gtk_widget_unref); gtk_widget_show (scrolledwindow1); gtk_box_pack_start (GTK_BOX (vbox1), scrolledwindow1, TRUE, TRUE, 0); clist1 = gtk_clist_new (3); gtk_widget_ref (clist1); gtk_object_set_data_full (GTK_OBJECT (frm_tabular), "clist1", clist1, (GtkDestroyNotify) gtk_widget_unref); gtk_widget_show (clist1); gtk_container_add (GTK_CONTAINER (scrolledwindow1), clist1); gtk_clist_set_column_width (GTK_CLIST (clist1), 0, 80); gtk_clist_set_column_width (GTK_CLIST (clist1), 1, 80); gtk_clist_set_column_width (GTK_CLIST (clist1), 2, 80); gtk_clist_column_titles_show (GTK_CLIST (clist1)); label1 = gtk_label_new ("label1"); gtk_widget_ref (label1); gtk_object_set_data_full (GTK_OBJECT (frm_tabular), "label1", label1, (GtkDestroyNotify) gtk_widget_unref); gtk_widget_show (label1); gtk_clist_set_column_widget (GTK_CLIST (clist1), 0, label1); label2 = gtk_label_new ('label2"); gtk_widget_ref (label2); gtk_object_set_data_full (GTK_OBJECT (frm_tabular), "label2", label2, (GtkDestroyNotify) gtk_widget_unref); gtk_widget_show (label2); gtk_clist_set_column_widget (GTK_CLIST (clist1), 1, label2); label3 = gtk_label_new ("label3"); gtk_widget_ref (label3); gtk_object_set_data_full (GTK_OBJECT (frm_tabular), "label3", label3, (GtkDestroyNotify) gtk_widget_unref); gtk_widget_show (label3); gtk_clist_set_column_widget (GTK_CLIST (clist1), 2, label3); statusbar1 = gtk_statusbar_new (); gtk_widget_ref (statusbar1); gtk_object_set_data_full (GTK_OBJECT (frm_tabular), "statusbar1", statusbar1, (GtkDestroyNotify) gtk_widget_unref); gtk_widget_show (statusbar1); gtk_box_pack_start (GTK_BOX (vbox1), statusbar1, FALSE, FALSE, 0); gtk_signal_connect (GTK_OBJECT (frm_tabular), "show", GTK_SIGNAL_FUNC (on_frm_tabular_show), NULL); gtk_signal_connect (GTK_OBJECT (frm_tabular), "delete_event", GTK_SIGNAL_FUNC (on_frm_tabular_delete_event), NULL); return frm_tabular; }
Listing C.4 is the Glade project file for the tabular executable. It is in XML format and is created by Glade.
<?xml version="1.0"?> <GTK-Interface> <project> <name>tabular</name> <program_name>tabular</program_name> <directory></directory> <source_directory>src</source_directory> <pixmaps_directory>pixmaps</pixmaps_directory> <language>C</language> <gnome_support>False</gnome_support> <gettext_support>False</gettext_support> <use_widget_names>False</use_widget_names> <output_main_file>True</output_main_file> <output_support_files>True</output_support_files> <output_build_files>True</output_build_files> <backup_source_files>True</backup_source_files> <main_source_file>interface.c</main_source_file> <main_header_file>interface.h</main_header_file> <handler_source_file>callbacks.c</handler_source_file> <handler_header_file>callbacks.h</handler_header_file> <support_source_file>support.c</support_source_file> <support_header_file>support.h</support_header_file> <translatable_strings_file></translatable_strings_file> </project> <widget> <class>GtkWindow</class> <name>frm_tabular</name> <signal> <name>show</name> <handler>on_frm_tabular_show</handler> <last_modification_time>Sun, 18 Feb 2001 21:58:53 GMT</last_modification_time> </signal> <signal> <name>delete_event</name> <handler>on_frm_tabular_delete_event</handler> <last_modification_time>Sun, 18 Feb 2001 22:10:58 GMT</last_modification_time> </signal> <title>Top Commission Earners</title> <type>GTK_WINDOW_TOPLEVEL</type> <position>GTK_WIN_POS_NONE</position> <modal>False</modal> <default_width>280</default_width> <default_height>500</default_height> <allow_shrink>False</allow_shrink> <allow_grow>True</allow_grow> <auto_shrink>False</auto_shrink> <widget> <class>GtkVBox</class> <name>vbox1</name> <homogeneous>False</homogeneous> <spacing>0</spacing> <widget> <class>GtkScrolledWindow</class> <name>scrolledwindow1</name> <hscrollbar_policy>GTK_POLICY_ALWAYS</hscrollbar_policy> <vscrollbar_policy>GTK_POLICY_ALWAYS</vscrollbar_policy> <hupdate_policy>GTK_UPDATE_CONTINUOUS</hupdate_policy> <vupdate_policy>GTK_UPDATE_CONTINUOUS</vupdate_policy> <child> <padding>0</padding> <expand>True</expand> <fill>True</fill> </child> <widget> <class>GtkCList</class> <name>clist1</name> <can_focus>True</can_focus> <columns>3</columns> <column_widths>80,80,80</column_widths> <selection_mode>GTK_SELECTION_SINGLE</selection_mode> <show_titles>True</show_titles> <shadow_type>GTK_SHADOW_IN</shadow_type> <widget> <class>GtkLabel</class> <child_name>CList:title</child_name> <name>label1</name> <label>label1</label> <justify>GTK_JUSTIFY_CENTER</justify> <wrap>False</wrap> <xalign>0.5</xalign> <yalign>0.5</yalign> <xpad>0</xpad> <ypad>0</ypad> </widget> <widget> <class>GtkLabel</class> <child_name>CList:title</child_name> <name>label2</name> <label>label2</label> <justify>GTK_JUSTIFY_CENTER</justify> <wrap>False</wrap> <xalign>0.5</xalign> <yalign>0.5</yalign> <xpad>0</xpad> <ypad>0</ypad> </widget> <widget> <class>GtkLabel</class> <child_name>CList:title</child_name> <name>label3</name> <label>label3</label> <justify>GTK_JUSTIFY_CENTER</justify> <wrap>False</wrap> <xalign>0.5</xalign> <yalign>0.5</yalign> <xpad>0</xpad> <ypad>0</ypad> </widget> </widget> </widget> <widget> <class>GtkStatusbar</class> <name>statusbar1</name> <child> <padding>0</padding> <expand>False</expand> <fill>False</fill> </child> </widget> </widget> </widget> </GTK-Interface>
only for RuBoard - do not distribute or recompile |