<property name="position">1</property>
</packing>
</child>
+ <child>
+ <object class="GtkButtonBox" id="buttonbox2">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="spacing">5</property>
+ <property name="layout_style">center</property>
+ <child>
+ <object class="GtkButton" id="button4">
+ <property name="label" translatable="yes">Is valid?</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
<child>
<object class="GtkScrolledWindow" id="scrolledwindow1">
<property name="visible">True</property>
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
- <property name="position">2</property>
+ <property name="position">3</property>
</packing>
</child>
</object>
<default-value>John Doe</default-value>
<widget>txt_name</widget>
<label>label1</label>
+ <filter type="zak_form_element_filter_trim"></filter>
+ <validator type="zak_form_element_validator_notempty"></validator>
</element>
<element type="zak_form_gtk_form_element_spin">
#include <libzakformgtk/libzakformgtk.h>
#include <libzakformgdaex/libzakformgdaex.h>
+GtkWidget *w;
+
ZakFormGtkForm *form;
ZakFormGdaexProvider *provider;
zak_form_form_update (ZAK_FORM_FORM (form), ZAK_FORM_IPROVIDER (provider));
}
+void
+is_valid_clicked (GtkButton *button,
+ gpointer user_data)
+{
+ zak_form_gtk_form_is_valid (form, w);
+}
+
int
main (int argc, char *argv[])
{
GtkBuilder *builder;
- GtkWidget *w;
GdaEx *gdaex;
G_CALLBACK (insert_clicked), NULL);
g_signal_connect (gtk_builder_get_object (builder, "button3"), "clicked",
G_CALLBACK (update_clicked), NULL);
+ g_signal_connect (gtk_builder_get_object (builder, "button4"), "clicked",
+ G_CALLBACK (is_valid_clicked), NULL);
form = zak_form_gtk_form_new ();
zak_form_gtk_form_set_gtkbuilder (form, builder);