gitkrwoptionchoiceboolean.c

Go to the documentation of this file.
00001 
00011 #define GITK_RENDERER_C
00012 #define GITKR_WIDGET_OPTIONCHOICE_BOOLEAN_C
00013 
00014 #include "gitkrincludes.h"
00015 
00017 void gitkr_widget_optionchoice_boolean_new(GitkrGtkWidgetPtr widget,gchar *id,GitkDialogPtr dialog,gchar *label,GtkContainer *container,gboolean box_vert,xmlNodePtr node) {
00018   gchar *value=gitk_widget_get_value(dialog,id,"value");
00019   gint cur_value;
00020 
00021   //-- determine selected entry
00022   cur_value=(value?atoi(value):0);
00023   g_free(value);
00024   
00025   gitkr_widget_new(widget,id,dialog);
00026 
00027   widget->impl=gtk_check_button_new_with_label(label);
00028   gtk_signal_connect(GTK_OBJECT(widget->impl),"clicked",GTK_SIGNAL_FUNC(sighandler_widget_on_clicked),widget);
00029   gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(widget->impl),(cur_value!=0));
00030   //gtk_box_pack_start_defaults(GTK_BOX(container),widget->impl);
00031   gtk_container_add(container,widget->impl);
00032 }
00033 

Generated on Thu Oct 28 10:59:14 2004 for gitk by doxygen 1.3.6