[goffice] migrated from Glade to GtkBuilder.
- From: Jean Bréfort <jbrefort src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [goffice] migrated from Glade to GtkBuilder.
- Date: Wed, 26 Aug 2009 09:37:08 +0000 (UTC)
commit 0cd75a2e4761285d2d5b709922e7fc8c27d0dd87
Author: Jean Brefort <jean brefort normalesup org>
Date: Wed Aug 26 11:31:22 2009 +0200
migrated from Glade to GtkBuilder.
ChangeLog | 4 +
NEWS | 1 +
configure.in | 3 +-
goffice/graph/Makefile.am | 28 +-
goffice/graph/gog-3d-box-prefs.glade | 142 ---
goffice/graph/gog-3d-box-prefs.ui | 154 +++
goffice/graph/gog-3d-box.c | 14 +-
goffice/graph/gog-axis-line.c | 49 +-
goffice/graph/gog-axis-prefs.glade | 988 -----------------
goffice/graph/gog-axis-prefs.ui | 662 ++++++++++++
goffice/graph/gog-axis.c | 41 +-
goffice/graph/gog-equation-prefs.glade | 53 -
goffice/graph/gog-equation-prefs.ui | 55 +
goffice/graph/gog-equation.c | 11 +-
goffice/graph/gog-error-bar-prefs.glade | 520 ---------
goffice/graph/gog-error-bar-prefs.ui | 387 +++++++
goffice/graph/gog-error-bar.c | 38 +-
goffice/graph/gog-graph-prefs.glade | 162 ---
goffice/graph/gog-graph-prefs.ui | 103 ++
goffice/graph/gog-graph.c | 13 +-
goffice/graph/gog-guru-type-selector.glade | 222 ----
goffice/graph/gog-guru-type-selector.ui | 236 ++++
goffice/graph/gog-guru.c | 55 +-
goffice/graph/gog-guru.glade | 420 --------
goffice/graph/gog-guru.ui | 383 +++++++
goffice/graph/gog-label.c | 12 +-
goffice/graph/gog-object-prefs.glade | 667 ------------
goffice/graph/gog-object-prefs.ui | 457 ++++++++
goffice/graph/gog-object.c | 54 +-
goffice/graph/gog-plot-prefs.glade | 431 --------
goffice/graph/gog-plot-prefs.ui | 295 ++++++
goffice/graph/gog-plot.c | 23 +-
goffice/graph/gog-reg-curve-prefs.glade | 112 --
goffice/graph/gog-reg-curve-prefs.ui | 62 ++
goffice/graph/gog-reg-curve.c | 11 +-
goffice/graph/gog-reg-eqn-prefs.glade | 69 --
goffice/graph/gog-reg-eqn-prefs.ui | 41 +
goffice/graph/gog-series-prefs.glade | 157 ---
goffice/graph/gog-series-prefs.ui | 171 +++
goffice/graph/gog-series.c | 27 +-
goffice/gtk/Makefile.am | 16 +-
goffice/gtk/go-3d-rotation-sel.c | 10 +-
goffice/gtk/go-3d-rotation-sel.glade | 84 --
goffice/gtk/go-3d-rotation-sel.ui | 88 ++
goffice/gtk/go-combo-text.c | 2 +-
goffice/gtk/go-combo-text.h | 2 +-
goffice/gtk/go-font-sel.c | 22 +-
goffice/gtk/go-font-sel.glade | 277 -----
goffice/gtk/go-font-sel.ui | 174 +++
goffice/gtk/go-format-sel.c | 27 +-
goffice/gtk/go-format-sel.glade | 1030 ------------------
goffice/gtk/go-format-sel.ui | 625 +++++++++++
goffice/gtk/go-image-save-dialog-extra.glade | 210 ----
goffice/gtk/go-image-save-dialog-extra.ui | 120 +++
goffice/gtk/go-image-sel.c | 18 +-
.../gtk/{go-image-sel.glade => go-image-sel.ui} | 105 +-
goffice/gtk/go-rotation-sel.c | 10 +-
goffice/gtk/go-rotation-sel.glade | 225 ----
goffice/gtk/go-rotation-sel.ui | 138 +++
goffice/gtk/goffice-gtk.c | 176 ++--
goffice/gtk/goffice-gtk.h | 29 +-
goffice/utils/Makefile.am | 6 +-
goffice/utils/go-editor.c | 11 +-
goffice/utils/go-style-prefs.glade | 874 ---------------
goffice/utils/go-style-prefs.ui | 952 +++++++++++++++++
goffice/utils/go-style.c | 103 +-
plugins/plot_barcol/Makefile.am | 4 +-
plugins/plot_barcol/gog-1.5d.c | 1 +
plugins/plot_barcol/gog-barcol-prefs.c | 13 +-
plugins/plot_barcol/gog-barcol-prefs.glade | 176 ---
plugins/plot_barcol/gog-barcol-prefs.ui | 117 ++
plugins/plot_barcol/gog-barcol.c | 6 +-
plugins/plot_barcol/gog-minmax-prefs.glade | 104 --
plugins/plot_barcol/gog-minmax-prefs.ui | 61 ++
plugins/plot_barcol/gog-minmax.c | 13 +-
plugins/plot_distrib/Makefile.am | 4 +-
plugins/plot_distrib/gog-boxplot-prefs.glade | 156 ---
plugins/plot_distrib/gog-boxplot-prefs.ui | 180 ++++
plugins/plot_distrib/gog-boxplot.c | 41 +-
plugins/plot_distrib/gog-probability-plot.c | 4 +-
plugins/plot_pie/Makefile.am | 4 +-
plugins/plot_pie/gog-pie-prefs.c | 50 +-
plugins/plot_pie/gog-pie-prefs.glade | 198 ----
plugins/plot_pie/gog-pie-prefs.ui | 134 +++
plugins/plot_pie/gog-pie-series.glade | 117 --
plugins/plot_pie/gog-pie-series.ui | 72 ++
plugins/plot_pie/gog-pie.c | 9 +-
plugins/plot_pie/gog-ring-prefs.glade | 270 -----
plugins/plot_pie/gog-ring-prefs.ui | 188 ++++
plugins/plot_radar/Makefile.am | 5 +-
plugins/plot_radar/gog-color-polar-prefs.glade | 27 -
plugins/plot_radar/gog-color-polar-prefs.ui | 24 +
plugins/plot_radar/gog-radar.c | 6 +-
plugins/plot_surface/Makefile.am | 8 +-
plugins/plot_surface/gog-xyz-prefs.c | 11 +-
plugins/plot_surface/gog-xyz-prefs.glade | 32 -
plugins/plot_surface/gog-xyz-prefs.ui | 25 +
plugins/plot_surface/gog-xyz-surface-prefs.c | 13 +-
plugins/plot_surface/gog-xyz-surface-prefs.glade | 83 --
plugins/plot_surface/gog-xyz-surface-prefs.ui | 92 ++
plugins/plot_surface/gog-xyz-surface.c | 6 +-
plugins/plot_surface/gog-xyz.c | 9 +-
plugins/plot_xy/Makefile.am | 10 +-
plugins/plot_xy/gog-bubble-prefs.c | 21 +-
plugins/plot_xy/gog-bubble-prefs.glade | 246 -----
plugins/plot_xy/gog-bubble-prefs.ui | 177 +++
plugins/plot_xy/gog-xy-color-prefs.glade | 28 -
plugins/plot_xy/gog-xy-color-prefs.ui | 24 +
plugins/plot_xy/gog-xy-series-prefs.glade | 51 -
plugins/plot_xy/gog-xy-series-prefs.ui | 26 +
plugins/plot_xy/gog-xy.c | 29 +-
plugins/reg_linear/Makefile.am | 2 +-
plugins/reg_logfit/Makefile.am | 2 +-
plugins/smoothing/Makefile.am | 8 +-
plugins/smoothing/gog-exp-smooth.c | 13 +-
plugins/smoothing/gog-exp-smooth.glade | 113 --
plugins/smoothing/gog-exp-smooth.ui | 68 ++
plugins/smoothing/gog-moving-avg.c | 13 +-
plugins/smoothing/gog-moving-avg.glade | 109 --
plugins/smoothing/gog-moving-avg.ui | 72 ++
po/ChangeLog | 4 +
po/POTFILES.in | 66 +-
tests/Makefile.am | 2 +-
tests/go-demo.c | 46 +-
tests/{go-demo.glade => go-demo.ui} | 1118 +++++++++++++-------
125 files changed, 7747 insertions(+), 9431 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index 233d7fa..4ab5ee8 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2009-08-26 Jean Brefort <jean brefort normalesup org>
+
+ * all files: migrated from Glade to GtkBuilder
+
2009-08-25 Morten Welinder <terra gnome org>
* goffice/app/go-conf-win32.c (go_conf_win32_get_node): Guess what
diff --git a/NEWS b/NEWS
index dff2065..969e3a5 100644
--- a/NEWS
+++ b/NEWS
@@ -3,6 +3,7 @@ goffice 0.7.10:
Jean:
* Canvas improvements.
* Removed FooCanvas.
+ * Migrated from Glade to GtkBuilder.
Morten:
* Namespace issues. [#592283]
diff --git a/configure.in b/configure.in
index c858768..2f98022 100644
--- a/configure.in
+++ b/configure.in
@@ -102,8 +102,7 @@ goffice_reqs="
cairo >= 1.2.0
"
goffice_gtk_reqs="
- gtk+-2.0 >= 2.6.0
- libglade-2.0 >= 2.3.6
+ gtk+-2.0 >= 2.12.0
"
surfaces_reqs="
diff --git a/goffice/graph/Makefile.am b/goffice/graph/Makefile.am
index 30f14a3..68dc994 100644
--- a/goffice/graph/Makefile.am
+++ b/goffice/graph/Makefile.am
@@ -80,24 +80,24 @@ if WITH_GTK
gog-child-button.h
endif
-gladedir = $(goffice_datadir)/glade
-dist_glade_DATA = \
- gog-guru.glade \
- gog-guru-type-selector.glade \
- gog-object-prefs.glade \
- gog-graph-prefs.glade \
- gog-plot-prefs.glade \
- gog-axis-prefs.glade \
- gog-error-bar-prefs.glade \
- gog-reg-curve-prefs.glade \
- gog-reg-eqn-prefs.glade \
- gog-series-prefs.glade \
- gog-3d-box-prefs.glade
+uidir = $(goffice_datadir)/ui
+dist_ui_DATA = \
+ gog-guru.ui \
+ gog-guru-type-selector.ui \
+ gog-object-prefs.ui \
+ gog-graph-prefs.ui \
+ gog-plot-prefs.ui \
+ gog-axis-prefs.ui \
+ gog-error-bar-prefs.ui \
+ gog-reg-curve-prefs.ui \
+ gog-reg-eqn-prefs.ui \
+ gog-series-prefs.ui \
+ gog-3d-box-prefs.ui
if GOFFICE_WITH_LASEM
libgoffice_graph_la_SOURCES += gog-equation.c
libgoffice_graph_la_HEADERS += gog-equation.h
- dist_glade_DATA += gog-equation-prefs.glade
+ dist_ui_DATA += gog-equation-prefs.ui
endif
include $(top_srcdir)/goffice.mk
diff --git a/goffice/graph/gog-3d-box-prefs.ui b/goffice/graph/gog-3d-box-prefs.ui
new file mode 100644
index 0000000..d9f9791
--- /dev/null
+++ b/goffice/graph/gog-3d-box-prefs.ui
@@ -0,0 +1,154 @@
+<?xml version="1.0"?>
+<interface>
+ <requires lib="gtk+" version="2.16"/>
+ <!-- interface-naming-policy toplevel-contextual -->
+ <object class="GtkAdjustment" id="adjustment1">
+ <property name="upper">180</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment2">
+ <property name="upper">360</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment3">
+ <property name="upper">360</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkHBox" id="gog_3d_box_prefs">
+ <property name="visible">True</property>
+ <property name="border_width">12</property>
+ <property name="spacing">24</property>
+ <child>
+ <object class="GtkVBox" id="vbox7">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">12</property>
+ <child>
+ <object class="GtkLabel" id="label4">
+ <property name="visible">True</property>
+ <property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes"><b>Euler angles</b></property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkTable" id="table1">
+ <property name="visible">True</property>
+ <property name="n_rows">3</property>
+ <property name="n_columns">2</property>
+ <property name="column_spacing">12</property>
+ <property name="row_spacing">6</property>
+ <child>
+ <object class="GtkHScale" id="theta_scale">
+ <property name="width_request">180</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
+ <property name="adjustment">adjustment1</property>
+ <property name="digits">0</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHScale" id="psi_scale">
+ <property name="width_request">180</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
+ <property name="adjustment">adjustment2</property>
+ <property name="digits">0</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label1">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Psi:</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label2">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Theta:</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label3">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Phi:</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHScale" id="phi_scale">
+ <property name="width_request">180</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
+ <property name="adjustment">adjustment3</property>
+ <property name="digits">0</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ </object>
+</interface>
diff --git a/goffice/graph/gog-3d-box.c b/goffice/graph/gog-3d-box.c
index b9a4960..1b0a4d2 100644
--- a/goffice/graph/gog-3d-box.c
+++ b/goffice/graph/gog-3d-box.c
@@ -157,7 +157,7 @@ gog_3d_box_populate_editor (GogObject *gobj,
{
GtkWidget *w;
GtkWidget *g3d;
- GladeXML *gui;
+ GtkBuilder *gui;
Gog3DBox *box = GOG_3D_BOX(gobj);
g3d = go_3d_rotation_sel_new ();
@@ -165,7 +165,7 @@ gog_3d_box_populate_editor (GogObject *gobj,
go_3d_rotation_sel_set_fov (GO_3D_ROTATION_SEL (g3d), box->fov);
go_editor_add_page (editor, g3d, _("Rotation"));
- gui = go_glade_new ("gog-3d-box-prefs.glade", "gog_3d_box_prefs", GETTEXT_PACKAGE, cc);
+ gui = go_gtk_builder_new ("gog-3d-box-prefs.ui", GETTEXT_PACKAGE, cc);
if (gui == NULL)
return;
@@ -175,7 +175,7 @@ gog_3d_box_populate_editor (GogObject *gobj,
"signal::fov-changed", G_CALLBACK (cb_fov_changed), gobj,
NULL);
- w = glade_xml_get_widget (gui, "psi_scale");
+ w = go_gtk_builder_get_widget (gui, "psi_scale");
gtk_range_set_value (GTK_RANGE (w), box->psi * 180 / M_PI);
g_object_connect (G_OBJECT (w),
"signal::button-release-event", G_CALLBACK (cb_box_psi_changed), gobj,
@@ -186,7 +186,7 @@ gog_3d_box_populate_editor (GogObject *gobj,
G_CALLBACK (cb_g3d_change_psi),
GTK_RANGE (w));
- w = glade_xml_get_widget (gui, "theta_scale");
+ w = go_gtk_builder_get_widget (gui, "theta_scale");
gtk_range_set_value (GTK_RANGE (w), box->theta * 180 / M_PI);
g_object_connect (G_OBJECT (w),
"signal::button-release-event", G_CALLBACK (cb_box_theta_changed), gobj,
@@ -197,7 +197,7 @@ gog_3d_box_populate_editor (GogObject *gobj,
G_CALLBACK (cb_g3d_change_theta),
GTK_RANGE (w));
- w = glade_xml_get_widget (gui, "phi_scale");
+ w = go_gtk_builder_get_widget (gui, "phi_scale");
gtk_range_set_value (GTK_RANGE (w), box->phi * 180 / M_PI);
g_object_connect (G_OBJECT (w),
"signal::button-release-event", G_CALLBACK (cb_box_phi_changed), gobj,
@@ -208,9 +208,9 @@ gog_3d_box_populate_editor (GogObject *gobj,
G_CALLBACK (cb_g3d_change_phi),
GTK_RANGE (w));
- w = glade_xml_get_widget (gui, "gog_3d_box_prefs");
+ w = go_gtk_builder_get_widget (gui, "gog_3d_box_prefs");
g_object_set_data_full (G_OBJECT (w),
- "state", gui, (GDestroyNotify)g_object_unref);
+ "state", gui, (GDestroyNotify) g_object_unref);
go_editor_add_page (editor, w, _("Advanced"));
}
diff --git a/goffice/graph/gog-axis-line.c b/goffice/graph/gog-axis-line.c
index 3f72cae..40a59e2 100644
--- a/goffice/graph/gog-axis-line.c
+++ b/goffice/graph/gog-axis-line.c
@@ -376,7 +376,7 @@ gog_axis_base_get_clamped_position (GogAxisBase *axis_base)
#ifdef GOFFICE_WITH_GTK
typedef struct {
GogAxisBase *axis_base;
- GladeXML *gui;
+ GtkBuilder *gui;
} AxisBasePrefs;
static void
@@ -390,7 +390,7 @@ static void
cb_cross_location_changed (GtkWidget *editor, AxisBasePrefs *state)
{
gtk_toggle_button_set_active
- (GTK_TOGGLE_BUTTON (glade_xml_get_widget (state->gui, "axis_cross")),
+ (GTK_TOGGLE_BUTTON (gtk_builder_get_object (state->gui, "axis_cross")),
TRUE);
}
@@ -407,7 +407,7 @@ cb_cross_axis_changed (GtkComboBox *combo, AxisBasePrefs *state)
state->axis_base->crossed_axis_id = g_value_get_uint (&value);
gtk_toggle_button_set_active
- (GTK_TOGGLE_BUTTON (glade_xml_get_widget (state->gui, "axis_cross")),
+ (GTK_TOGGLE_BUTTON (gtk_builder_get_object (state->gui, "axis_cross")),
TRUE);
g_value_unset (&value);
@@ -432,7 +432,7 @@ cb_position_toggled (GtkWidget *button, AxisBasePrefs *state)
position = GOG_AXIS_AT_LOW;
if (position != axis_base->position)
- gtk_widget_set_sensitive (glade_xml_get_widget (state->gui, "padding_spinbutton"),
+ gtk_widget_set_sensitive (go_gtk_builder_get_widget (state->gui, "padding_spinbutton"),
position != GOG_AXIS_CROSS);
if (position != GOG_AXIS_CROSS) {
@@ -487,7 +487,8 @@ gog_axis_base_populate_editor (GogObject *gobj,
"minor-tick-in"
};
GogAxisBase *axis_base;
- GladeXML *gui;
+ GtkBuilder *gui;
+ GtkWidget *w;
GogAxisType crossed_axis_type, axis_type;
static guint axis_base_pref_page = 0;
unsigned i;
@@ -506,7 +507,7 @@ gog_axis_base_populate_editor (GogObject *gobj,
return;
}
- gui = go_glade_new ("gog-axis-prefs.glade", "axis_base_pref_box", GETTEXT_PACKAGE, cc);
+ gui = go_gtk_builder_new ("gog-axis-prefs.ui", GETTEXT_PACKAGE, cc);
if (gui == NULL) {
(GOG_OBJECT_CLASS(gab_parent_klass)->populate_editor) (gobj, editor, dalloc, cc);
return;
@@ -522,9 +523,9 @@ gog_axis_base_populate_editor (GogObject *gobj,
unsigned axis_count;
GtkCellRenderer *cell;
AxisBasePrefs *state;
-
+
store = gtk_list_store_new (2, G_TYPE_STRING, G_TYPE_UINT);
- combo = glade_xml_get_widget (gui, "cross_axis_combo");
+ combo = go_gtk_builder_get_widget (gui, "cross_axis_combo");
gtk_combo_box_set_model (GTK_COMBO_BOX (combo), GTK_TREE_MODEL (store));
cell = gtk_cell_renderer_text_new ();
@@ -558,32 +559,30 @@ gog_axis_base_populate_editor (GogObject *gobj,
deditor = gog_data_allocator_editor
(dalloc, GOG_DATASET (axis_base),
GOG_AXIS_ELEM_CROSS_POINT, GOG_DATA_SCALAR);
- container = glade_xml_get_widget (gui, "cross_location_alignment");
- gtk_container_add (GTK_CONTAINER (container),
- GTK_WIDGET (deditor));
+ container = go_gtk_builder_get_widget (gui, "cross_location_alignment");
+ gtk_container_add (GTK_CONTAINER (container), GTK_WIDGET (deditor));
gtk_widget_show_all (container);
state = g_new (AxisBasePrefs, 1);
state->axis_base = axis_base;
- state->gui = gui;
+ state->gui = g_object_ref (gui);
g_signal_connect (G_OBJECT (combo), "changed",
G_CALLBACK (cb_cross_axis_changed), state);
g_signal_connect (G_OBJECT (deditor), "changed",
G_CALLBACK (cb_cross_location_changed), state);
- g_object_set_data_full (G_OBJECT (combo),
- "state", state, (GDestroyNotify) axis_base_pref_free);
+ g_signal_connect_swapped (G_OBJECT (combo), "destroy", G_CALLBACK (axis_base_pref_free), state);
- w = glade_xml_get_widget (gui, "axis_low");
+ w = go_gtk_builder_get_widget (gui, "axis_low");
if (axis_base->position == GOG_AXIS_AT_LOW)
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (w), TRUE);
g_signal_connect (G_OBJECT (w), "toggled",
G_CALLBACK (cb_position_toggled), state);
- w = glade_xml_get_widget (gui, "axis_cross");
+ w = go_gtk_builder_get_widget (gui, "axis_cross");
if (axis_base->position == GOG_AXIS_CROSS)
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (w), TRUE);
g_signal_connect (G_OBJECT (w), "toggled",
G_CALLBACK (cb_position_toggled), state);
- w = glade_xml_get_widget (gui, "axis_high");
+ w = go_gtk_builder_get_widget (gui, "axis_high");
if (axis_base->position == GOG_AXIS_AT_HIGH)
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (w), TRUE);
g_signal_connect (G_OBJECT (w), "toggled",
@@ -591,7 +590,7 @@ gog_axis_base_populate_editor (GogObject *gobj,
hide_position_box = FALSE;
} else {
- GtkWidget *w = glade_xml_get_widget (gui, "cross_box");
+ w = go_gtk_builder_get_widget (gui, "cross_box");
gtk_widget_hide (w);
}
@@ -599,25 +598,26 @@ gog_axis_base_populate_editor (GogObject *gobj,
axis_type == GOG_AXIS_Y ||
axis_type == GOG_AXIS_Z ||
axis_type == GOG_AXIS_RADIAL) {
- GtkWidget *w = glade_xml_get_widget (gui, "padding_spinbutton");
+ w = go_gtk_builder_get_widget (gui, "padding_spinbutton");
gtk_spin_button_set_value (GTK_SPIN_BUTTON (w), axis_base->padding);
g_signal_connect (G_CALLBACK (w), "value-changed",
G_CALLBACK (cb_padding_changed), axis_base);
gtk_widget_set_sensitive (w, axis_base->position != GOG_AXIS_CROSS);
hide_position_box = FALSE;
} else {
- GtkWidget *w = glade_xml_get_widget (gui, "padding_box");
+ w = go_gtk_builder_get_widget (gui, "padding_box");
gtk_widget_hide (w);
}
if (hide_position_box) {
- GtkWidget *w = glade_xml_get_widget (gui, "position_box");
+ w = go_gtk_builder_get_widget (gui, "position_box");
gtk_widget_hide (w);
}
for (i = 0; i < G_N_ELEMENTS (toggle_props) ; i++) {
gboolean cur_val;
- GtkWidget *w = glade_xml_get_widget (gui, toggle_props[i]);
+
+ w = go_gtk_builder_get_widget (gui, toggle_props[i]);
g_object_get (G_OBJECT (gobj), toggle_props[i], &cur_val, NULL);
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (w), cur_val);
g_signal_connect_object (G_OBJECT (w),
@@ -627,13 +627,14 @@ gog_axis_base_populate_editor (GogObject *gobj,
if (gog_axis_is_discrete (axis_base->axis)) {
/* Hide minor tick properties */
- GtkWidget *w = glade_xml_get_widget (gui, "minor_tick_box");
+ GtkWidget *w = go_gtk_builder_get_widget (gui, "minor_tick_box");
gtk_widget_hide (w);
}
go_editor_add_page (editor,
- glade_xml_get_widget (gui, "axis_base_pref_box"),
+ go_gtk_builder_get_widget (gui, "axis_base_pref_box"),
_("Layout"));
+ g_object_unref (gui);
(GOG_OBJECT_CLASS(gab_parent_klass)->populate_editor) (gobj, editor, dalloc, cc);
}
diff --git a/goffice/graph/gog-axis-prefs.ui b/goffice/graph/gog-axis-prefs.ui
new file mode 100644
index 0000000..5d6438f
--- /dev/null
+++ b/goffice/graph/gog-axis-prefs.ui
@@ -0,0 +1,662 @@
+<?xml version="1.0"?>
+<interface>
+ <requires lib="gtk+" version="2.16"/>
+ <!-- interface-naming-policy toplevel-contextual -->
+ <object class="GtkAdjustment" id="adjustment1">
+ <property name="lower">-180</property>
+ <property name="upper">180</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment2">
+ <property name="lower">-10000</property>
+ <property name="upper">10000</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkHBox" id="axis_pref_box">
+ <property name="visible">True</property>
+ <property name="border_width">12</property>
+ <property name="spacing">24</property>
+ <child>
+ <object class="GtkVBox" id="vbox7">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">12</property>
+ <child>
+ <object class="GtkVBox" id="bound_box">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <child>
+ <object class="GtkLabel" id="label1">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes"><b>Bounds</b></property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkAlignment" id="alignment16">
+ <property name="visible">True</property>
+ <property name="top_padding">6</property>
+ <property name="left_padding">12</property>
+ <child>
+ <object class="GtkTable" id="bound_table">
+ <property name="visible">True</property>
+ <property name="n_rows">2</property>
+ <property name="n_columns">2</property>
+ <property name="column_spacing">12</property>
+ <property name="row_spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="label7">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Automatic</property>
+ </object>
+ <packing>
+ <property name="right_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="mapping_box">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <child>
+ <object class="GtkLabel" id="label2">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes"><b>Mapping</b></property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkAlignment" id="alignment9">
+ <property name="visible">True</property>
+ <property name="top_padding">6</property>
+ <property name="left_padding">12</property>
+ <child>
+ <object class="GtkVBox" id="vbox18">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkCheckButton" id="invert-axis">
+ <property name="label" translatable="yes">_Invert axis</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHBox" id="map_type_box">
+ <property name="visible">True</property>
+ <property name="spacing">12</property>
+ <child>
+ <object class="GtkLabel" id="map_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Type:</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkComboBox" id="map_type_combo">
+ <property name="visible">True</property>
+ <property name="model">model1</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkTable" id="circular_table">
+ <property name="visible">True</property>
+ <property name="n_rows">2</property>
+ <property name="n_columns">3</property>
+ <property name="column_spacing">12</property>
+ <property name="row_spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="label9">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Rotation:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">circular_rotation_spinbutton</property>
+ </object>
+ <packing>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label10">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">degrees</property>
+ </object>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="circular_rotation_spinbutton">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ <property name="adjustment">adjustment1</property>
+ <property name="climb_rate">1</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label8">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Unit:</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkComboBox" id="polar_unit_combo">
+ <property name="visible">True</property>
+ <property name="model">polar-unit-model</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ </object>
+ <object class="GtkVBox" id="axis_base_pref_box">
+ <property name="visible">True</property>
+ <property name="border_width">12</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">12</property>
+ <child>
+ <object class="GtkHBox" id="hbox3">
+ <property name="visible">True</property>
+ <property name="spacing">24</property>
+ <child>
+ <object class="GtkVBox" id="major_tick_box">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <child>
+ <object class="GtkLabel" id="label3">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes"><b>Major ticks</b></property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkAlignment" id="alignment12">
+ <property name="visible">True</property>
+ <property name="top_padding">6</property>
+ <property name="left_padding">12</property>
+ <child>
+ <object class="GtkVBox" id="vbox13">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkCheckButton" id="major-tick-out">
+ <property name="label" translatable="yes">_Outside</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkCheckButton" id="major-tick-in">
+ <property name="label" translatable="yes">_Inside</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkCheckButton" id="major-tick-labeled">
+ <property name="label" translatable="yes">_Show Labels</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="minor_tick_box">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <child>
+ <object class="GtkLabel" id="label4">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes"><b>Minor ticks</b></property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkAlignment" id="alignment13">
+ <property name="visible">True</property>
+ <property name="top_padding">6</property>
+ <property name="left_padding">12</property>
+ <child>
+ <object class="GtkVBox" id="vbox15">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkCheckButton" id="minor-tick-out">
+ <property name="label" translatable="yes">O_utside</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkCheckButton" id="minor-tick-in">
+ <property name="label" translatable="yes">I_nside</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="position_box">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <child>
+ <object class="GtkLabel" id="label5">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes"><b>Position</b></property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkAlignment" id="alignment14">
+ <property name="visible">True</property>
+ <property name="top_padding">6</property>
+ <property name="left_padding">12</property>
+ <child>
+ <object class="GtkVBox" id="vbox19">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkVBox" id="cross_box">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkRadioButton" id="axis_low">
+ <property name="label" translatable="yes">_Low</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="active">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkRadioButton" id="axis_high">
+ <property name="label" translatable="yes">_High</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ <property name="group">axis_low</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHBox" id="hbox4">
+ <property name="visible">True</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkAlignment" id="alignment15">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="yalign">0</property>
+ <child>
+ <object class="GtkRadioButton" id="axis_cross">
+ <property name="label" translatable="yes">_Cross</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ <property name="group">axis_low</property>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkComboBox" id="cross_axis_combo">
+ <property name="visible">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label6">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes">at</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkAlignment" id="cross_location_alignment">
+ <property name="visible">True</property>
+ <child>
+ <placeholder/>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">3</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHBox" id="padding_box">
+ <property name="visible">True</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="label11">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes">Padding:</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="padding_spinbutton">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ <property name="adjustment">adjustment2</property>
+ <property name="climb_rate">1</property>
+ <property name="numeric">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label12">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes">pts</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <object class="GtkListStore" id="model1">
+ <columns>
+ <!-- column-name gchararray1 -->
+ <column type="gchararray"/>
+ </columns>
+ </object>
+ <object class="GtkListStore" id="polar-unit-model">
+ <columns>
+ <!-- column-name gchararray1 -->
+ <column type="gchararray"/>
+ </columns>
+ </object>
+</interface>
diff --git a/goffice/graph/gog-axis.c b/goffice/graph/gog-axis.c
index 47eeee1..99c5689 100644
--- a/goffice/graph/gog-axis.c
+++ b/goffice/graph/gog-axis.c
@@ -2070,7 +2070,6 @@ gog_axis_update (GogObject *obj)
#ifdef GOFFICE_WITH_GTK
typedef struct {
- GladeXML *gui;
GogAxis *axis;
GtkWidget *format_selector;
} GogAxisPrefState;
@@ -2080,8 +2079,6 @@ gog_axis_pref_state_free (GogAxisPrefState *state)
{
if (state->axis != NULL)
g_object_unref (state->axis);
- if (state->gui != NULL)
- g_object_unref (state->gui);
g_free (state);
}
@@ -2268,19 +2265,18 @@ gog_axis_populate_editor (GogObject *gobj,
GogAxis *axis = GOG_AXIS (gobj);
GogAxisPrefState *state;
GogDataset *set = GOG_DATASET (gobj);
- GladeXML *gui;
+ GtkBuilder *gui;
- gui = go_glade_new ("gog-axis-prefs.glade", "axis_pref_box", GETTEXT_PACKAGE, cc);
+ gui = go_gtk_builder_new ("gog-axis-prefs.ui", GETTEXT_PACKAGE, cc);
if (gui == NULL)
return;
state = g_new0 (GogAxisPrefState, 1);
- state->gui = gui;
state->axis = axis;
g_object_ref (G_OBJECT (axis));
/* Bounds Page */
- table = GTK_TABLE (glade_xml_get_widget (gui, "bound_table"));
+ table = GTK_TABLE (gtk_builder_get_object (gui, "bound_table"));
if (axis->is_discrete) {
static char const * const dim_names[] = {
N_("M_inimum"),
@@ -2307,38 +2303,39 @@ gog_axis_populate_editor (GogObject *gobj,
/* Details page */
if (!axis->is_discrete && gog_axis_get_atype (axis) != GOG_AXIS_CIRCULAR) {
- GtkWidget *w = glade_xml_get_widget (gui, "map_type_combo");
- gog_axis_map_populate_combo (axis, GTK_COMBO_BOX (w));
- g_signal_connect_object (G_OBJECT (w),
+ GtkComboBox *box = go_gtk_builder_combo_box_init_text (gui, "map_type_combo");
+ gog_axis_map_populate_combo (axis, box);
+ g_signal_connect_object (G_OBJECT (box),
"changed",
G_CALLBACK (cb_map_combo_changed),
axis, 0);
} else {
- GtkWidget *w = glade_xml_get_widget (gui, "map_type_box");
+ GtkWidget *w = go_gtk_builder_get_widget (gui, "map_type_box");
gtk_widget_hide (w);
}
if (!axis->is_discrete && gog_axis_get_atype (axis) == GOG_AXIS_CIRCULAR) {
- GtkWidget *w = glade_xml_get_widget (gui, "polar_unit_combo");
- gog_axis_populate_polar_unit_combo (axis, GTK_COMBO_BOX (w));
- g_signal_connect (G_OBJECT (w),
+ GtkWidget *w;
+ GtkComboBox *box = go_gtk_builder_combo_box_init_text (gui, "polar_unit_combo");
+ gog_axis_populate_polar_unit_combo (axis, box);
+ g_signal_connect (G_OBJECT (box),
"changed",
G_CALLBACK (cb_polar_unit_changed),
state);
- w = glade_xml_get_widget (gui, "circular_rotation_spinbutton");
+ w = go_gtk_builder_get_widget (gui, "circular_rotation_spinbutton");
gtk_spin_button_set_value (GTK_SPIN_BUTTON (w), axis->circular_rotation);
g_signal_connect_object (G_OBJECT (w), "value-changed",
G_CALLBACK (cb_rotation_changed),
axis, 0);
} else {
- GtkWidget *w = glade_xml_get_widget (gui, "circular_table");
+ GtkWidget *w = go_gtk_builder_get_widget (gui, "circular_table");
gtk_widget_hide (w);
}
for (i = 0; i < G_N_ELEMENTS (toggle_props) ; i++) {
gboolean cur_val;
- GtkWidget *w = glade_xml_get_widget (gui, toggle_props[i]);
+ GtkWidget *w = go_gtk_builder_get_widget (gui, toggle_props[i]);
g_object_get (G_OBJECT (gobj), toggle_props[i], &cur_val, NULL);
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (w), cur_val);
@@ -2348,7 +2345,7 @@ gog_axis_populate_editor (GogObject *gobj,
}
go_editor_add_page (editor,
- glade_xml_get_widget (gui, "axis_pref_box"),
+ go_gtk_builder_get_widget (gui, "axis_pref_box"),
_("Scale"));
if (gog_object_is_visible (axis) && gog_axis_get_atype (axis) < GOG_AXIS_VIRTUAL) {
@@ -2367,14 +2364,14 @@ gog_axis_populate_editor (GogObject *gobj,
go_editor_add_page (editor, w, _("Format"));
- gtk_widget_show (w);
g_signal_connect (G_OBJECT (w),
"format_changed", G_CALLBACK (cb_axis_fmt_changed), axis);
}
}
- w = glade_xml_get_widget (gui, "axis_pref_box");
- g_object_set_data_full (G_OBJECT (w), "state", state,
- (GDestroyNotify)gog_axis_pref_state_free);
+
+ g_object_set_data_full (gtk_builder_get_object (gui, "axis_pref_box"),
+ "state", state, (GDestroyNotify) gog_axis_pref_state_free);
+ g_object_unref (gui);
go_editor_set_store_page (editor, &axis_pref_page);
}
diff --git a/goffice/graph/gog-equation-prefs.ui b/goffice/graph/gog-equation-prefs.ui
new file mode 100644
index 0000000..5a73b59
--- /dev/null
+++ b/goffice/graph/gog-equation-prefs.ui
@@ -0,0 +1,55 @@
+<?xml version="1.0"?>
+<interface>
+ <requires lib="gtk+" version="2.16"/>
+ <!-- interface-naming-policy toplevel-contextual -->
+ <object class="GtkVBox" id="gog_equation_prefs">
+ <property name="visible">True</property>
+ <property name="border_width">12</property>
+ <property name="orientation">vertical</property>
+ <child>
+ <object class="GtkVBox" id="plot_area_box">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkScrolledWindow" id="scrolledwindow1">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="hscrollbar_policy">automatic</property>
+ <property name="vscrollbar_policy">automatic</property>
+ <property name="shadow_type">etched-in</property>
+ <child>
+ <object class="GtkTextView" id="equation_text">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="wrap_mode">char</property>
+ <property name="accepts_tab">False</property>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkCheckButton" id="compact_mode_check">
+ <property name="label" translatable="yes">_Compact mode</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ </object>
+</interface>
diff --git a/goffice/graph/gog-equation.c b/goffice/graph/gog-equation.c
index d1e4802..0f5c8d6 100644
--- a/goffice/graph/gog-equation.c
+++ b/goffice/graph/gog-equation.c
@@ -75,27 +75,28 @@ gog_equation_populate_editor (GogObject *obj,
GOCmdContext *cc)
{
GogEquation *equation = GOG_EQUATION (obj);
- GladeXML *gui;
+ GtkBuilder *gui;
GtkWidget *widget;
GtkTextBuffer *buffer;
static guint equation_pref_page = 0;
- gui = go_glade_new ("gog-equation-prefs.glade", "gog_equation_prefs", GETTEXT_PACKAGE, cc);
+ gui = go_gtk_builder_new ("gog-equation-prefs.ui", GETTEXT_PACKAGE, cc);
g_return_if_fail (gui != NULL);
- widget = glade_xml_get_widget (gui, "equation_text");
+ widget = go_gtk_builder_get_widget (gui, "equation_text");
buffer = gtk_text_view_get_buffer (GTK_TEXT_VIEW (widget));
gtk_text_buffer_set_text (GTK_TEXT_BUFFER (buffer), equation->itex != NULL ? equation->itex: "", -1);
g_signal_connect (G_OBJECT (buffer), "changed", G_CALLBACK (cb_equation_buffer_changed), obj);
- widget = glade_xml_get_widget (gui, "compact_mode_check");
+ widget = go_gtk_builder_get_widget (gui, "compact_mode_check");
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (widget), equation->inline_mode);
g_signal_connect (G_OBJECT (widget), "toggled", G_CALLBACK (cb_inline_mode_check_toggled), obj);
- widget = glade_xml_get_widget (gui, "gog_equation_prefs");
+ widget = go_gtk_builder_get_widget (gui, "gog_equation_prefs");
go_editor_add_page (editor, widget, _("Equation"));
+ g_object_unref (gui);
(GOG_OBJECT_CLASS(equation_parent_klass)->populate_editor) (obj, editor, dalloc, cc);
diff --git a/goffice/graph/gog-error-bar-prefs.ui b/goffice/graph/gog-error-bar-prefs.ui
new file mode 100644
index 0000000..101126a
--- /dev/null
+++ b/goffice/graph/gog-error-bar-prefs.ui
@@ -0,0 +1,387 @@
+<?xml version="1.0"?>
+<interface>
+ <requires lib="gtk+" version="2.16"/>
+ <!-- interface-naming-policy toplevel-contextual -->
+ <object class="GtkAdjustment" id="adjustment1">
+ <property name="value">1</property>
+ <property name="upper">100</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment2">
+ <property name="value">5</property>
+ <property name="upper">100</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkListStore" id="model1">
+ <columns>
+ <!-- column-name gchararray -->
+ <column type="gchararray"/>
+ </columns>
+ <data>
+ <row>
+ <col id="0" translatable="yes">None</col>
+ </row>
+ <row>
+ <col id="0" translatable="yes">Absolute</col>
+ </row>
+ <row>
+ <col id="0" translatable="yes">Relative</col>
+ </row>
+ <row>
+ <col id="0" translatable="yes">Percent</col>
+ </row>
+ </data>
+ </object>
+ <object class="GtkVBox" id="gog_error_bar_prefs">
+ <property name="visible">True</property>
+ <property name="border_width">12</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">12</property>
+ <child>
+ <object class="GtkHBox" id="hbox1">
+ <property name="visible">True</property>
+ <property name="spacing">24</property>
+ <child>
+ <object class="GtkVBox" id="vbox1">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <child>
+ <object class="GtkLabel" id="category_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes"><b>Error category</b></property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkAlignment" id="category_alignment">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="yalign">0</property>
+ <property name="xscale">0</property>
+ <property name="yscale">0</property>
+ <property name="top_padding">6</property>
+ <property name="left_padding">18</property>
+ <child>
+ <object class="GtkComboBox" id="category_combo">
+ <property name="visible">True</property>
+ <property name="model">model1</property>
+ <child>
+ <object class="GtkCellRendererText" id="renderer1"/>
+ <attributes>
+ <attribute name="text">0</attribute>
+ </attributes>
+ </child>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="style_box">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <child>
+ <object class="GtkLabel" id="style_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes"><b>Style</b></property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkAlignment" id="alignment1">
+ <property name="visible">True</property>
+ <property name="top_padding">6</property>
+ <property name="left_padding">18</property>
+ <child>
+ <object class="GtkTable" id="style_table">
+ <property name="visible">True</property>
+ <property name="n_rows">4</property>
+ <property name="n_columns">5</property>
+ <property name="column_spacing">12</property>
+ <property name="row_spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="display_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="xpad">5</property>
+ <property name="label" translatable="yes">Dis_play:</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="width_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="xpad">5</property>
+ <property name="label" translatable="yes">_Width:</property>
+ <property name="use_underline">True</property>
+ <property name="justify">right</property>
+ <property name="mnemonic_widget">width</property>
+ </object>
+ <packing>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="line_width_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="xpad">5</property>
+ <property name="label" translatable="yes">_Line width:</property>
+ <property name="use_underline">True</property>
+ <property name="justify">right</property>
+ <property name="mnemonic_widget">line_width</property>
+ </object>
+ <packing>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="color_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="xpad">5</property>
+ <property name="label" translatable="yes">Colo_r:</property>
+ <property name="use_underline">True</property>
+ <property name="justify">right</property>
+ </object>
+ <packing>
+ <property name="top_attach">3</property>
+ <property name="bottom_attach">4</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="line_width">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ <property name="adjustment">adjustment1</property>
+ <property name="climb_rate">1</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="width">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ <property name="adjustment">adjustment2</property>
+ <property name="climb_rate">1</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label1">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">pts</property>
+ </object>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label2">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">pts</property>
+ </object>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="values_box">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <child>
+ <object class="GtkLabel" id="values_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes"><b>Values</b></property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkAlignment" id="alignment3">
+ <property name="visible">True</property>
+ <property name="top_padding">6</property>
+ <property name="left_padding">18</property>
+ <child>
+ <object class="GtkTable" id="values_table">
+ <property name="visible">True</property>
+ <property name="n_rows">2</property>
+ <property name="n_columns">2</property>
+ <property name="column_spacing">12</property>
+ <property name="row_spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="plus_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">(+)</property>
+ </object>
+ <packing>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="minus_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">(-)</property>
+ </object>
+ <packing>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+</interface>
diff --git a/goffice/graph/gog-error-bar.c b/goffice/graph/gog-error-bar.c
index ca85f88..1eaabbd 100644
--- a/goffice/graph/gog-error-bar.c
+++ b/goffice/graph/gog-error-bar.c
@@ -47,7 +47,6 @@ static GObjectClass *error_bar_parent_klass;
#include <goffice/gtk/goffice-gtk.h>
#include <goffice/gtk/go-pixbuf.h>
#include <goffice/gtk/go-color-selector.h>
-#include <glade/glade-xml.h>
typedef struct {
GogSeries *series;
@@ -135,7 +134,7 @@ cb_display_changed (GtkComboBox *combo, GogErrorBarEditor *editor)
static void
cb_type_changed (GtkWidget *w, GogErrorBarEditor *editor)
{
- GladeXML *gui = GLADE_XML (g_object_get_data (G_OBJECT (w), "gui"));
+ GtkBuilder *gui = GTK_BUILDER (g_object_get_data (G_OBJECT (w), "gui"));
gpointer data;
GogDataset *set;
GogDataAllocator *dalloc;
@@ -156,10 +155,10 @@ cb_type_changed (GtkWidget *w, GogErrorBarEditor *editor)
gtk_widget_destroy (GTK_WIDGET(data));
g_object_set_data (G_OBJECT (w), "plus", NULL);
g_object_set_data (G_OBJECT (w), "minus", NULL);
- gtk_widget_hide (glade_xml_get_widget (gui, "values_box"));
- gtk_widget_hide (glade_xml_get_widget (gui, "style_box"));
+ gtk_widget_hide (go_gtk_builder_get_widget (gui, "values_box"));
+ gtk_widget_hide (go_gtk_builder_get_widget (gui, "style_box"));
} else {
- GtkWidget *table = glade_xml_get_widget (gui, "values_table");
+ GtkWidget *table = go_gtk_builder_get_widget (gui, "values_table");
if (!editor->bar) {
editor->bar = g_object_new (GOG_TYPE_ERROR_BAR, NULL);
editor->bar->style->line.color = editor->color;
@@ -189,8 +188,8 @@ cb_type_changed (GtkWidget *w, GogErrorBarEditor *editor)
gtk_table_attach (GTK_TABLE (table), al, 1, 2, 1, 2, GTK_FILL | GTK_EXPAND, 0, 0, 0);
g_object_set_data (G_OBJECT (w), "minus", al);
}
- gtk_widget_show_all (glade_xml_get_widget (gui, "values_box"));
- gtk_widget_show (glade_xml_get_widget (gui, "style_box"));
+ gtk_widget_show_all (go_gtk_builder_get_widget (gui, "values_box"));
+ gtk_widget_show (go_gtk_builder_get_widget (gui, "style_box"));
}
gog_object_request_update (GOG_OBJECT (editor->series));
}
@@ -202,7 +201,7 @@ gog_error_bar_prefs (GogSeries *series,
GogDataAllocator *dalloc,
GOCmdContext *cc)
{
- GladeXML *gui;
+ GtkBuilder *gui;
GtkWidget *w, *bar_prefs;
GtkTable *style_table, *values_table;
GtkWidget *combo;
@@ -233,30 +232,30 @@ gog_error_bar_prefs (GogSeries *series,
}
set = GOG_DATASET (series);
- gui = go_glade_new ("gog-error-bar-prefs.glade", "gog_error_bar_prefs", GETTEXT_PACKAGE, cc);
+ gui = go_gtk_builder_new ("gog-error-bar-prefs.ui", GETTEXT_PACKAGE, cc);
/* Style properties */
/* Width */
- w = glade_xml_get_widget (gui, "width");
+ w = go_gtk_builder_get_widget (gui, "width");
gtk_spin_button_set_value (GTK_SPIN_BUTTON (w), editor->width);
g_signal_connect (gtk_spin_button_get_adjustment (GTK_SPIN_BUTTON (w)),
"value_changed",
G_CALLBACK (cb_width_changed), editor);
/* Line width */
- w = glade_xml_get_widget (gui, "line_width");
+ w = go_gtk_builder_get_widget (gui, "line_width");
gtk_spin_button_set_value (GTK_SPIN_BUTTON (w), editor->line_width);
g_signal_connect (gtk_spin_button_get_adjustment (GTK_SPIN_BUTTON (w)),
"value_changed",
G_CALLBACK (cb_line_width_changed), editor);
- style_table = GTK_TABLE (glade_xml_get_widget (gui, "style_table"));
+ style_table = GTK_TABLE (gtk_builder_get_object (gui, "style_table"));
/* Color */
w = go_color_selector_new (editor->color, RGBA_BLACK, "error-bar");
gtk_label_set_mnemonic_widget (
- GTK_LABEL (glade_xml_get_widget (gui, "color_label")), w);
+ GTK_LABEL (gtk_builder_get_object (gui, "color_label")), w);
g_signal_connect (G_OBJECT (w),
"activate",
G_CALLBACK (cb_color_changed), editor);
@@ -294,18 +293,18 @@ gog_error_bar_prefs (GogSeries *series,
g_signal_connect (G_OBJECT (combo), "changed", G_CALLBACK (cb_display_changed), editor);
/* Category property*/
- w = glade_xml_get_widget (gui, "category_combo");
+ w = go_gtk_builder_get_widget (gui, "category_combo");
gtk_combo_box_set_active (GTK_COMBO_BOX (w), (editor->bar)? (int) editor->bar->type: 0);
- g_object_set_data_full (G_OBJECT (w), "gui", gui, (GDestroyNotify)g_object_unref);
+ g_object_set_data (G_OBJECT (w), "gui", gui);
g_object_set_data (G_OBJECT (w), "allocator", dalloc);
g_signal_connect (G_OBJECT (w), "changed", G_CALLBACK (cb_type_changed), editor);
/* Value properties */
- bar_prefs = glade_xml_get_widget (gui, "gog_error_bar_prefs");
+ bar_prefs = go_gtk_builder_get_widget (gui, "gog_error_bar_prefs");
g_signal_connect (bar_prefs, "destroy", G_CALLBACK (cb_destroy), editor);
gtk_widget_show_all (bar_prefs);
- values_table = GTK_TABLE (glade_xml_get_widget (gui, "values_table"));
+ values_table = GTK_TABLE (gtk_builder_get_object (gui, "values_table"));
if (editor->bar) {
GtkWidget* al = GTK_WIDGET (gog_data_allocator_editor (dalloc, set, editor->bar->error_i, GOG_DATA_VECTOR));
gtk_widget_show (al);
@@ -316,9 +315,10 @@ gog_error_bar_prefs (GogSeries *series,
gtk_table_attach (values_table, al, 1, 2, 1, 2, GTK_FILL | GTK_EXPAND, 0, 0, 0);
g_object_set_data (G_OBJECT (w), "minus", al);
} else {
- gtk_widget_hide (glade_xml_get_widget (gui, "values_box"));
- gtk_widget_hide (glade_xml_get_widget (gui, "style_box"));
+ gtk_widget_hide (go_gtk_builder_get_widget (gui, "values_box"));
+ gtk_widget_hide (go_gtk_builder_get_widget (gui, "style_box"));
}
+ g_signal_connect (G_OBJECT (bar_prefs), "destroy", G_CALLBACK (g_object_unref), gui);
return GTK_WIDGET(bar_prefs);
}
diff --git a/goffice/graph/gog-graph-prefs.ui b/goffice/graph/gog-graph-prefs.ui
new file mode 100644
index 0000000..80710d7
--- /dev/null
+++ b/goffice/graph/gog-graph-prefs.ui
@@ -0,0 +1,103 @@
+<?xml version="1.0"?>
+<interface>
+ <requires lib="gtk+" version="2.16"/>
+ <!-- interface-naming-policy toplevel-contextual -->
+ <object class="GtkListStore" id="model1">
+ <columns>
+ <!-- column-name gchararray -->
+ <column type="gchararray"/>
+ </columns>
+ <data>
+ <row>
+ <col id="0" translatable="yes">Default</col>
+ </row>
+ </data>
+ </object>
+ <object class="GtkTable" id="gog_graph_prefs">
+ <property name="visible">True</property>
+ <property name="border_width">12</property>
+ <property name="n_rows">2</property>
+ <property name="n_columns">2</property>
+ <property name="column_spacing">6</property>
+ <property name="row_spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="label51">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Theme:</property>
+ </object>
+ <packing>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkComboBox" id="theme_combo">
+ <property name="visible">True</property>
+ <property name="model">model1</property>
+ <child>
+ <object class="GtkCellRendererText" id="renderer1"/>
+ <attributes>
+ <attribute name="text">0</attribute>
+ </attributes>
+ </child>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options">GTK_FILL</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButton" id="force_theme_button">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
+ <child>
+ <object class="GtkAlignment" id="alignment1">
+ <property name="visible">True</property>
+ <property name="xscale">0</property>
+ <property name="yscale">0</property>
+ <child>
+ <object class="GtkHBox" id="hbox1">
+ <property name="visible">True</property>
+ <property name="spacing">2</property>
+ <child>
+ <object class="GtkImage" id="image1">
+ <property name="visible">True</property>
+ <property name="stock">gtk-clear</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label52">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes">Forget user styles</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="right_attach">2</property>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ </object>
+</interface>
diff --git a/goffice/graph/gog-graph.c b/goffice/graph/gog-graph.c
index bd789e2..1750a73 100644
--- a/goffice/graph/gog-graph.c
+++ b/goffice/graph/gog-graph.c
@@ -195,11 +195,11 @@ gog_graph_populate_editor (GogObject *gobj,
GOCmdContext *cc)
{
GogGraph *graph = GOG_GRAPH (gobj);
- GladeXML *gui;
+ GtkBuilder *gui;
GSList *theme_names;
static guint graph_pref_page = 0;
- gui = go_glade_new ("gog-graph-prefs.glade", "gog_graph_prefs", GETTEXT_PACKAGE, cc);
+ gui = go_gtk_builder_new ("gog-graph-prefs.ui", GETTEXT_PACKAGE, cc);
if (gui == NULL)
return;
@@ -215,7 +215,7 @@ gog_graph_populate_editor (GogObject *gobj,
int count, index = 0;
graph_theme_name = gog_theme_get_name (graph->theme);
- combo = glade_xml_get_widget (gui, "theme_combo");
+ combo = go_gtk_builder_get_widget (gui, "theme_combo");
gtk_list_store_clear (GTK_LIST_STORE (gtk_combo_box_get_model (GTK_COMBO_BOX (combo))));
count = 0;
@@ -228,13 +228,12 @@ gog_graph_populate_editor (GogObject *gobj,
gtk_combo_box_set_active (GTK_COMBO_BOX (combo), index);
g_signal_connect (G_OBJECT (combo), "changed", G_CALLBACK (cb_theme_changed), graph);
- g_signal_connect (G_OBJECT (glade_xml_get_widget (gui, "force_theme_button")), "clicked",
+ g_signal_connect (gtk_builder_get_object (gui, "force_theme_button"), "clicked",
G_CALLBACK (cb_force_theme), graph);
- box = glade_xml_get_widget (gui, "gog_graph_prefs");
- g_object_set_data_full (G_OBJECT (box), "gui", gui,
- (GDestroyNotify)g_object_unref);
+ box = go_gtk_builder_get_widget (gui, "gog_graph_prefs");
go_editor_add_page (editor, box, _("Theme"));
+ g_object_unref (gui);
g_slist_free (theme_names);
}
diff --git a/goffice/graph/gog-guru-type-selector.ui b/goffice/graph/gog-guru-type-selector.ui
new file mode 100644
index 0000000..77c1174
--- /dev/null
+++ b/goffice/graph/gog-guru-type-selector.ui
@@ -0,0 +1,236 @@
+<?xml version="1.0"?>
+<interface>
+ <requires lib="gtk+" version="2.16"/>
+ <!-- interface-naming-policy toplevel-contextual -->
+ <object class="GtkAlignment" id="type_selector">
+ <property name="visible">True</property>
+ <property name="top_padding">6</property>
+ <property name="left_padding">6</property>
+ <property name="right_padding">6</property>
+ <child>
+ <object class="GtkVBox" id="vbox2">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">12</property>
+ <child>
+ <object class="GtkHBox" id="hbox1">
+ <property name="visible">True</property>
+ <property name="spacing">24</property>
+ <child>
+ <object class="GtkVBox" id="vbox4">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="type_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes"><b>_Plot type</b></property>
+ <property name="use_markup">True</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">type_treeview</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkScrolledWindow" id="scrolledwindow1">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="hscrollbar_policy">never</property>
+ <property name="vscrollbar_policy">never</property>
+ <property name="shadow_type">in</property>
+ <child>
+ <object class="GtkTreeView" id="type_treeview">
+ <property name="width_request">150</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="headers_visible">False</property>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="vbox5">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">12</property>
+ <child>
+ <object class="GtkVBox" id="rbox">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="subtype_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes"><b>_Subtype</b></property>
+ <property name="use_markup">True</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">type_treeview</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkFrame" id="canvas_container">
+ <property name="visible">True</property>
+ <property name="label_xalign">0</property>
+ <property name="shadow_type">in</property>
+ <child>
+ <placeholder/>
+ </child>
+ </object>
+ <packing>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkAlignment" id="alignment10">
+ <property name="visible">True</property>
+ <property name="xalign">1</property>
+ <property name="yalign">0</property>
+ <property name="xscale">0</property>
+ <property name="yscale">0</property>
+ <property name="top_padding">6</property>
+ <child>
+ <object class="GtkButton" id="sample_button">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
+ <property name="focus_on_click">False</property>
+ <child>
+ <object class="GtkAlignment" id="alignment8">
+ <property name="visible">True</property>
+ <property name="xscale">0</property>
+ <property name="yscale">0</property>
+ <child>
+ <object class="GtkHBox" id="hbox3">
+ <property name="visible">True</property>
+ <property name="spacing">2</property>
+ <child>
+ <object class="GtkImage" id="image27">
+ <property name="visible">True</property>
+ <property name="stock">gtk-dialog-info</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="sample_label">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes">Show sample</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ </object>
+ </child>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHBox" id="hbox2">
+ <property name="visible">True</property>
+ <property name="spacing">24</property>
+ <child>
+ <object class="GtkVBox" id="vbox3">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="description_title_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes"><b>Description</b></property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkFrame" id="frame2">
+ <property name="visible">True</property>
+ <property name="label_xalign">0</property>
+ <property name="shadow_type">in</property>
+ <child>
+ <object class="GtkLabel" id="description_label">
+ <property name="height_request">60</property>
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="yalign">0</property>
+ <property name="xpad">6</property>
+ <property name="ypad">6</property>
+ <property name="wrap">True</property>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ </object>
+</interface>
diff --git a/goffice/graph/gog-guru.c b/goffice/graph/gog-guru.c
index 713ea43..e3a0274 100644
--- a/goffice/graph/gog-guru.c
+++ b/goffice/graph/gog-guru.c
@@ -46,7 +46,7 @@ struct _GraphGuruState {
GClosure *register_closure;
/* GUI accessors */
- GladeXML *gui;
+ GtkBuilder *gui;
GtkWidget *dialog;
GtkWidget *button_cancel;
GtkWidget *button_navigate;
@@ -86,7 +86,7 @@ struct _GraphGuruState {
};
struct _GraphGuruTypeSelector {
- GladeXML *gui;
+ GtkBuilder *gui;
GtkWidget *canvas;
GtkWidget *sample_button;
GtkLabel *label;
@@ -883,18 +883,18 @@ graph_guru_init_format_page (GraphGuruState *s)
return;
s->fmt_page_initialized = TRUE;
- w = glade_xml_get_widget (s->gui, "menu_hbox");
+ w = go_gtk_builder_get_widget (s->gui, "menu_hbox");
s->child_button = gog_child_button_new ();
gtk_box_pack_start (GTK_BOX (w), s->child_button, FALSE, FALSE, 0);
gtk_box_reorder_child (GTK_BOX (w), s->child_button, 0);
gtk_widget_show (s->child_button);
- s->delete_button = glade_xml_get_widget (s->gui, "delete");
- s->prec.inc_button = glade_xml_get_widget (s->gui, "inc_precedence");
- s->prec.dec_button = glade_xml_get_widget (s->gui, "dec_precedence");
- s->prec.first_button = glade_xml_get_widget (s->gui, "first_precedence");
- s->prec.last_button = glade_xml_get_widget (s->gui, "last_precedence");
+ s->delete_button = go_gtk_builder_get_widget (s->gui, "delete");
+ s->prec.inc_button = go_gtk_builder_get_widget (s->gui, "inc_precedence");
+ s->prec.dec_button = go_gtk_builder_get_widget (s->gui, "dec_precedence");
+ s->prec.first_button = go_gtk_builder_get_widget (s->gui, "first_precedence");
+ s->prec.last_button = go_gtk_builder_get_widget (s->gui, "last_precedence");
g_signal_connect_swapped (G_OBJECT (s->delete_button),
"clicked",
@@ -913,7 +913,7 @@ graph_guru_init_format_page (GraphGuruState *s)
G_CALLBACK (cb_prec_last), s);
/* Load up the sample view and make it fill the entire canvas */
- w = glade_xml_get_widget (s->gui, "sample-alignment");
+ w = go_gtk_builder_get_widget (s->gui, "sample-alignment");
canvas = GTK_WIDGET (g_object_new (GOC_TYPE_CANVAS, NULL));
gtk_container_add (GTK_CONTAINER (w), canvas);
s->sample_graph_shadow = goc_item_new (goc_canvas_get_root (GOC_CANVAS (canvas)),
@@ -950,7 +950,7 @@ graph_guru_init_format_page (GraphGuruState *s)
G_CALLBACK (cb_graph_selection_changed), s);
g_object_unref (G_OBJECT (rend));
- w = glade_xml_get_widget (s->gui, "prop_alignment");
+ w = go_gtk_builder_get_widget (s->gui, "prop_alignment");
s->prop_container = GTK_CONTAINER (w);
s->prop_model = gtk_tree_store_new (PLOT_ATTR_NUM_COLUMNS,
G_TYPE_STRING, G_TYPE_POINTER);
@@ -974,7 +974,7 @@ graph_guru_init_format_page (GraphGuruState *s)
s, NULL, FALSE);
gtk_tree_view_expand_all (s->prop_view);
- w = glade_xml_get_widget (s->gui, "attr_window");
+ w = go_gtk_builder_get_widget (s->gui, "attr_window");
gtk_container_add (GTK_CONTAINER (w), GTK_WIDGET (s->prop_view));
gtk_widget_show_all (w);
@@ -1052,14 +1052,13 @@ cb_graph_guru_clicked (GtkWidget *button, GraphGuruState *s)
NULL);
g_value_unset (instance_and_params + 0);
}
-
gtk_widget_destroy (GTK_WIDGET (s->dialog));
}
static GtkWidget *
graph_guru_init_button (GraphGuruState *s, char const *widget_name)
{
- GtkWidget *button = glade_xml_get_widget (s->gui, widget_name);
+ GtkWidget *button = go_gtk_builder_get_widget (s->gui, widget_name);
g_signal_connect (G_OBJECT (button),
"clicked",
G_CALLBACK (cb_graph_guru_clicked), s);
@@ -1069,7 +1068,7 @@ graph_guru_init_button (GraphGuruState *s, char const *widget_name)
static GtkWidget *
graph_guru_init_ok_button (GraphGuruState *s)
{
- GtkButton *button = GTK_BUTTON (glade_xml_get_widget
+ GtkButton *button = GTK_BUTTON (gtk_builder_get_object
(s->gui, "button_ok"));
if (s->editing) {
@@ -1112,10 +1111,10 @@ graph_guru_type_selector_new (GraphGuruState *s)
GtkTreeSelection *selection;
GraphGuruTypeSelector *typesel;
GtkWidget *selector;
- GladeXML *gui;
+ GtkBuilder *gui;
GOStyle *style;
- gui = go_glade_new ("gog-guru-type-selector.glade", "type_selector", GETTEXT_PACKAGE, s->cc);
+ gui = go_gtk_builder_new ("gog-guru-type-selector.ui", GETTEXT_PACKAGE, s->cc);
typesel = g_new0 (GraphGuruTypeSelector, 1);
typesel->state = s;
@@ -1126,7 +1125,7 @@ graph_guru_type_selector_new (GraphGuruState *s)
typesel->max_priority_so_far = -1;
s->type_selector = typesel;
- selector = glade_xml_get_widget (gui, "type_selector");
+ selector = GTK_WIDGET (g_object_ref (gtk_builder_get_object (gui, "type_selector")));
/* List of family types */
typesel->model = gtk_list_store_new (PLOT_FAMILY_NUM_COLUMNS,
@@ -1136,7 +1135,7 @@ graph_guru_type_selector_new (GraphGuruState *s)
gtk_tree_sortable_set_sort_column_id (GTK_TREE_SORTABLE (typesel->model),
PLOT_FAMILY_TYPE_NAME, GTK_SORT_ASCENDING);
- typesel->list_view = GTK_TREE_VIEW (glade_xml_get_widget (gui, "type_treeview"));
+ typesel->list_view = GTK_TREE_VIEW (gtk_builder_get_object (gui, "type_treeview"));
gtk_tree_view_set_model (typesel->list_view, GTK_TREE_MODEL (typesel->model));
gtk_tree_view_append_column (typesel->list_view,
gtk_tree_view_column_new_with_attributes ("",
@@ -1167,7 +1166,7 @@ graph_guru_type_selector_new (GraphGuruState *s)
gtk_widget_set_size_request (typesel->canvas,
MINOR_PIXMAP_WIDTH*3 + BORDER*5,
MINOR_PIXMAP_HEIGHT*3 + BORDER*5);
- gtk_container_add (GTK_CONTAINER (glade_xml_get_widget (gui, "canvas_container")),
+ gtk_container_add (GTK_CONTAINER (gtk_builder_get_object (gui, "canvas_container")),
typesel->canvas);
/* Init the list and the canvas group for each family */
@@ -1191,10 +1190,10 @@ graph_guru_type_selector_new (GraphGuruState *s)
typesel_set_selection_color (typesel);
/* Setup the description label */
- typesel->label = GTK_LABEL (glade_xml_get_widget (gui, "description_label"));
+ typesel->label = GTK_LABEL (gtk_builder_get_object (gui, "description_label"));
/* Set up sample button */
- typesel->sample_button = glade_xml_get_widget (gui, "sample_button");
+ typesel->sample_button = go_gtk_builder_get_widget (gui, "sample_button");
g_signal_connect_swapped (G_OBJECT (typesel->sample_button),
"pressed",
G_CALLBACK (cb_sample_pressed), typesel);
@@ -1213,12 +1212,12 @@ graph_guru_type_selector_new (GraphGuruState *s)
static gboolean
graph_guru_init (GraphGuruState *s)
{
- s->gui = go_glade_new ("gog-guru.glade", NULL, GETTEXT_PACKAGE, s->cc);
+ s->gui = go_gtk_builder_new ("gog-guru.ui", GETTEXT_PACKAGE, s->cc);
if (s->gui == NULL)
return TRUE;
- s->dialog = glade_xml_get_widget (s->gui, "GraphGuru");
- s->steps = GTK_NOTEBOOK (glade_xml_get_widget (s->gui, "notebook"));
+ s->dialog = go_gtk_builder_get_widget (s->gui, "GraphGuru");
+ s->steps = GTK_NOTEBOOK (gtk_builder_get_object (s->gui, "notebook"));
/* Buttons */
s->button_cancel = graph_guru_init_button (s, "button_cancel");
@@ -1242,7 +1241,7 @@ GtkWidget *
gog_guru_get_help_button (GtkWidget *guru)
{
GraphGuruState *state = g_object_get_data (G_OBJECT (guru), "state");
- return state ? glade_xml_get_widget (state->gui, "help_button") : NULL;
+ return state ? go_gtk_builder_get_widget (state->gui, "help_button") : NULL;
}
/**
@@ -1317,8 +1316,10 @@ gog_guru (GogGraph *graph, GogDataAllocator *dalloc,
graph_guru_set_page (state, page);
/* a candidate for merging into attach guru */
- g_object_set_data_full (G_OBJECT (state->dialog),
- "state", state, (GDestroyNotify) graph_guru_state_destroy);
+ g_signal_connect_swapped (G_OBJECT (state->dialog), "destroy", G_CALLBACK (graph_guru_state_destroy), state);
+
+ g_object_set_data (G_OBJECT (state->dialog),
+ "state", state);
return state->dialog;
}
diff --git a/goffice/graph/gog-guru.ui b/goffice/graph/gog-guru.ui
new file mode 100644
index 0000000..10893c7
--- /dev/null
+++ b/goffice/graph/gog-guru.ui
@@ -0,0 +1,383 @@
+<?xml version="1.0"?>
+<!--*- mode: xml -*-->
+<interface>
+ <object class="GtkDialog" id="GraphGuru">
+ <property name="border_width">6</property>
+ <property name="title">GNOME Office Graph</property>
+ <property name="type">GTK_WINDOW_TOPLEVEL</property>
+ <property name="window_position">GTK_WIN_POS_MOUSE</property>
+ <property name="modal">False</property>
+ <property name="default_width">530</property>
+ <property name="default_height">625</property>
+ <property name="resizable">True</property>
+ <property name="destroy_with_parent">False</property>
+ <property name="decorated">True</property>
+ <property name="skip_taskbar_hint">False</property>
+ <property name="skip_pager_hint">False</property>
+ <property name="type_hint">GDK_WINDOW_TYPE_HINT_DIALOG</property>
+ <property name="gravity">GDK_GRAVITY_NORTH_WEST</property>
+ <property name="focus_on_map">True</property>
+ <property name="urgency_hint">False</property>
+ <property name="has_separator">False</property>
+ <child internal-child="vbox">
+ <object class="GtkVBox" id="dialog-vbox4">
+ <property name="visible">True</property>
+ <property name="homogeneous">False</property>
+ <property name="spacing">0</property>
+ <child internal-child="action_area">
+ <object class="GtkHButtonBox" id="dialog-action_area4">
+ <property name="visible">True</property>
+ <property name="layout_style">GTK_BUTTONBOX_END</property>
+ <child>
+ <object class="GtkButton" id="help_button">
+ <property name="visible">True</property>
+ <property name="can_default">True</property>
+ <property name="can_focus">True</property>
+ <property name="label">gtk-help</property>
+ <property name="use_stock">True</property>
+ <property name="relief">GTK_RELIEF_NORMAL</property>
+ <property name="focus_on_click">True</property>
+ </object>
+ </child>
+ <child>
+ <object class="GtkButton" id="button_cancel">
+ <property name="visible">True</property>
+ <property name="can_default">True</property>
+ <property name="can_focus">True</property>
+ <property name="label">gtk-cancel</property>
+ <property name="use_stock">True</property>
+ <property name="relief">GTK_RELIEF_NORMAL</property>
+ <property name="focus_on_click">True</property>
+ </object>
+ </child>
+ <child>
+ <object class="GtkButton" id="button_navigate">
+ <property name="visible">True</property>
+ <property name="can_default">True</property>
+ <property name="can_focus">True</property>
+ <property name="label">gtk-go-forward</property>
+ <property name="use_stock">True</property>
+ <property name="relief">GTK_RELIEF_NORMAL</property>
+ <property name="focus_on_click">True</property>
+ </object>
+ </child>
+ <child>
+ <object class="GtkButton" id="button_ok">
+ <property name="visible">True</property>
+ <property name="can_default">True</property>
+ <property name="can_focus">True</property>
+ <property name="label">gtk-ok</property>
+ <property name="use_stock">True</property>
+ <property name="relief">GTK_RELIEF_NORMAL</property>
+ <property name="focus_on_click">True</property>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="pack_type">GTK_PACK_END</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkNotebook" id="notebook">
+ <property name="visible">True</property>
+ <property name="show_tabs">False</property>
+ <property name="show_border">False</property>
+ <property name="tab_pos">GTK_POS_TOP</property>
+ <property name="scrollable">False</property>
+ <property name="enable_popup">False</property>
+ <child>
+ <object class="GtkVPaned" id="v_fmt_pane">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="position">1</property>
+ <child>
+ <object class="GtkHPaned" id="h_fmt_pane">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="position">1</property>
+ <child>
+ <object class="GtkAlignment" id="alignment1">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="yalign">0</property>
+ <property name="xscale">1</property>
+ <property name="yscale">1</property>
+ <property name="top_padding">6</property>
+ <property name="bottom_padding">6</property>
+ <property name="left_padding">6</property>
+ <property name="right_padding">6</property>
+ <child>
+ <object class="GtkVBox" id="vbox1">
+ <property name="visible">True</property>
+ <property name="homogeneous">False</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkScrolledWindow" id="attr_window">
+ <property name="height_request">150</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="hscrollbar_policy">GTK_POLICY_AUTOMATIC</property>
+ <property name="vscrollbar_policy">GTK_POLICY_AUTOMATIC</property>
+ <property name="shadow_type">GTK_SHADOW_IN</property>
+ <property name="window_placement">GTK_CORNER_TOP_LEFT</property>
+ </object>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHBox" id="menu_hbox">
+ <property name="visible">True</property>
+ <property name="homogeneous">False</property>
+ <property name="spacing">0</property>
+ <child>
+ <object class="GtkButton" id="first_precedence">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="relief">GTK_RELIEF_NORMAL</property>
+ <property name="focus_on_click">True</property>
+ <child>
+ <object class="GtkImage" id="image79">
+ <property name="visible">True</property>
+ <property name="stock">gtk-goto-top</property>
+ <property name="icon_size">4</property>
+ <property name="xalign">0.5</property>
+ <property name="yalign">0.5</property>
+ <property name="xpad">0</property>
+ <property name="ypad">0</property>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButton" id="inc_precedence">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="relief">GTK_RELIEF_NORMAL</property>
+ <property name="focus_on_click">True</property>
+ <child>
+ <object class="GtkImage" id="image78">
+ <property name="visible">True</property>
+ <property name="stock">gtk-go-up</property>
+ <property name="icon_size">4</property>
+ <property name="xalign">0.5</property>
+ <property name="yalign">0.5</property>
+ <property name="xpad">0</property>
+ <property name="ypad">0</property>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButton" id="dec_precedence">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="relief">GTK_RELIEF_NORMAL</property>
+ <property name="focus_on_click">True</property>
+ <child>
+ <object class="GtkImage" id="image77">
+ <property name="visible">True</property>
+ <property name="stock">gtk-go-down</property>
+ <property name="icon_size">4</property>
+ <property name="xalign">0.5</property>
+ <property name="yalign">0.5</property>
+ <property name="xpad">0</property>
+ <property name="ypad">0</property>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButton" id="last_precedence">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="relief">GTK_RELIEF_NORMAL</property>
+ <property name="focus_on_click">True</property>
+ <child>
+ <object class="GtkImage" id="image76">
+ <property name="visible">True</property>
+ <property name="stock">gtk-goto-bottom</property>
+ <property name="icon_size">4</property>
+ <property name="xalign">0.5</property>
+ <property name="yalign">0.5</property>
+ <property name="xpad">0</property>
+ <property name="ypad">0</property>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButton" id="delete">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="relief">GTK_RELIEF_NORMAL</property>
+ <property name="focus_on_click">False</property>
+ <child>
+ <object class="GtkImage" id="image80">
+ <property name="visible">True</property>
+ <property name="stock">gtk-remove</property>
+ <property name="icon_size">4</property>
+ <property name="xalign">0.5</property>
+ <property name="yalign">0.5</property>
+ <property name="xpad">0</property>
+ <property name="ypad">0</property>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="shrink">False</property>
+ <property name="resize">False</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkAlignment" id="sample-alignment">
+ <property name="width_request">200</property>
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="yalign">0</property>
+ <property name="xscale">1</property>
+ <property name="yscale">1</property>
+ <property name="top_padding">6</property>
+ <property name="bottom_padding">6</property>
+ <property name="left_padding">6</property>
+ <property name="right_padding">6</property>
+ <child>
+ <placeholder/>
+ </child>
+ </object>
+ <packing>
+ <property name="shrink">False</property>
+ <property name="resize">False</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="shrink">False</property>
+ <property name="resize">False</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkAlignment" id="prop_alignment">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="yalign">0</property>
+ <property name="xscale">1</property>
+ <property name="yscale">1</property>
+ <property name="top_padding">6</property>
+ <property name="bottom_padding">0</property>
+ <property name="left_padding">6</property>
+ <property name="right_padding">6</property>
+ <child>
+ <placeholder/>
+ </child>
+ </object>
+ <packing>
+ <property name="shrink">False</property>
+ <property name="resize">False</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="tab_expand">False</property>
+ <property name="tab_fill">True</property>
+ </packing>
+ </child>
+ <child type="tab">
+ <object class="GtkLabel" id="label1">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes"/>
+ <property name="use_underline">False</property>
+ <property name="use_markup">False</property>
+ <property name="justify">GTK_JUSTIFY_LEFT</property>
+ <property name="wrap">False</property>
+ <property name="selectable">False</property>
+ <property name="xalign">0</property>
+ <property name="yalign">0</property>
+ <property name="xpad">0</property>
+ <property name="ypad">0</property>
+ <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
+ <property name="width_chars">-1</property>
+ <property name="single_line_mode">False</property>
+ <property name="angle">0</property>
+ </object>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child type="tab">
+ <object class="GtkLabel" id="label2">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes"/>
+ <property name="use_underline">False</property>
+ <property name="use_markup">False</property>
+ <property name="justify">GTK_JUSTIFY_LEFT</property>
+ <property name="wrap">False</property>
+ <property name="selectable">False</property>
+ <property name="xalign">0</property>
+ <property name="yalign">0</property>
+ <property name="xpad">0</property>
+ <property name="ypad">0</property>
+ <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
+ <property name="width_chars">-1</property>
+ <property name="single_line_mode">False</property>
+ <property name="angle">0</property>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="padding">0</property>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ <action-widgets>
+ <action-widget response="-11">help_button</action-widget>
+ <action-widget response="-6">button_cancel</action-widget>
+ <action-widget response="2">button_navigate</action-widget>
+ <action-widget response="-5">button_ok</action-widget>
+ </action-widgets>
+ </object>
+</interface>
diff --git a/goffice/graph/gog-label.c b/goffice/graph/gog-label.c
index f216ab0..a116a84 100644
--- a/goffice/graph/gog-label.c
+++ b/goffice/graph/gog-label.c
@@ -336,27 +336,29 @@ gog_reg_eqn_populate_editor (GogObject *gobj,
GOCmdContext *cc)
{
GtkWidget *w;
- GladeXML *gui;
+ GtkBuilder *gui;
GogRegEqn *reg_eqn = GOG_REG_EQN (gobj);
- gui = go_glade_new ("gog-reg-eqn-prefs.glade", "reg-eqn-prefs", GETTEXT_PACKAGE, cc);
+ gui = go_gtk_builder_new ("gog-reg-eqn-prefs.ui", GETTEXT_PACKAGE, cc);
if (gui == NULL)
return;
go_editor_add_page (editor,
- glade_xml_get_widget (gui, "reg-eqn-prefs"),
+ go_gtk_builder_get_widget (gui, "reg-eqn-prefs"),
_("Details"));
- w = glade_xml_get_widget (gui, "show_eq");
+ w = go_gtk_builder_get_widget (gui, "show_eq");
g_object_set_data (G_OBJECT (w), "prop", (void*) "show-eq");
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (w), reg_eqn->show_eq);
g_signal_connect (w, "toggled", G_CALLBACK (cb_text_visibility_changed), gobj);
- w = glade_xml_get_widget (gui, "show_r2");
+ w = go_gtk_builder_get_widget (gui, "show_r2");
g_object_set_data (G_OBJECT (w), "prop", (void*) "show-r2");
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (w), reg_eqn->show_r2);
g_signal_connect (w, "toggled", G_CALLBACK (cb_text_visibility_changed), gobj);
+ g_object_unref (gui);
+
(GOG_OBJECT_CLASS(reg_eqn_parent_klass)->populate_editor) (gobj, editor, dalloc, cc);
}
#endif
diff --git a/goffice/graph/gog-object-prefs.ui b/goffice/graph/gog-object-prefs.ui
new file mode 100644
index 0000000..9ff9551
--- /dev/null
+++ b/goffice/graph/gog-object-prefs.ui
@@ -0,0 +1,457 @@
+<?xml version="1.0"?>
+<interface>
+ <requires lib="gtk+" version="2.16"/>
+ <!-- interface-naming-policy toplevel-contextual -->
+ <object class="GtkAdjustment" id="adjustment1">
+ <property name="lower">-10000</property>
+ <property name="upper">10000</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment2">
+ <property name="lower">-10000</property>
+ <property name="upper">10000</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment3">
+ <property name="upper">10000</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment4">
+ <property name="upper">10000</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkListStore" id="position-select-model">
+ <columns>
+ <!-- column-name gchararray -->
+ <column type="gchararray"/>
+ </columns>
+ <data>
+ <row>
+ <col id="0" translatable="yes">Automatic</col>
+ </row>
+ <row>
+ <col id="0" translatable="yes">Manual</col>
+ </row>
+ </data>
+ </object>
+ <object class="GtkVBox" id="gog_object_prefs">
+ <property name="visible">True</property>
+ <property name="border_width">12</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkHBox" id="position_select_box">
+ <property name="visible">True</property>
+ <property name="spacing">12</property>
+ <child>
+ <object class="GtkLabel" id="label47">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes">_Object position:</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkComboBox" id="position_select_combo">
+ <property name="visible">True</property>
+ <property name="model">position-select-model</property>
+ <child>
+ <object class="GtkCellRendererText" id="renderer1"/>
+ <attributes>
+ <attribute name="text">0</attribute>
+ </attributes>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkNotebook" id="position_notebook">
+ <property name="visible">True</property>
+ <property name="show_tabs">False</property>
+ <property name="show_border">False</property>
+ <child>
+ <object class="GtkVBox" id="vbox12">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkHBox" id="compass_position">
+ <property name="visible">True</property>
+ <property name="spacing">12</property>
+ <child>
+ <object class="GtkLabel" id="position_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Position:</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkComboBox" id="position_combo">
+ <property name="visible">True</property>
+ <property name="model">position-model</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHBox" id="compass_alignment">
+ <property name="visible">True</property>
+ <property name="spacing">12</property>
+ <child>
+ <object class="GtkLabel" id="alignment_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Alignment:</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkComboBox" id="alignment_combo">
+ <property name="visible">True</property>
+ <property name="model">alignment-model</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ <child type="tab">
+ <object class="GtkLabel" id="label46">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes">label46</property>
+ </object>
+ <packing>
+ <property name="tab_fill">False</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="vbox9">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkTable" id="manual_positions">
+ <property name="visible">True</property>
+ <property name="n_rows">3</property>
+ <property name="n_columns">3</property>
+ <property name="column_spacing">12</property>
+ <property name="row_spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="label37">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">%</property>
+ </object>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label38">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">%</property>
+ </object>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="y_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Y:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">y_spin</property>
+ </object>
+ <packing>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="x_spin">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ <property name="adjustment">adjustment1</property>
+ <property name="climb_rate">1</property>
+ <property name="digits">1</property>
+ <property name="numeric">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="y_spin">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ <property name="adjustment">adjustment2</property>
+ <property name="climb_rate">1</property>
+ <property name="digits">1</property>
+ <property name="numeric">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="x_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_X:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">x_spin</property>
+ </object>
+ <packing>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="anchor_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Anchor:</property>
+ </object>
+ <packing>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkComboBox" id="anchor_combo">
+ <property name="visible">True</property>
+ <property name="model">anchor-model</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">3</property>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options">GTK_FILL</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkTable" id="manual_sizes">
+ <property name="visible">True</property>
+ <property name="n_rows">2</property>
+ <property name="n_columns">3</property>
+ <property name="column_spacing">12</property>
+ <property name="row_spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="height_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Height:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">height_spin</property>
+ </object>
+ <packing>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label39">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">%</property>
+ </object>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label42">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">%</property>
+ </object>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="width_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Width:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">width_spin</property>
+ </object>
+ <packing>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="width_spin">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ <property name="adjustment">adjustment3</property>
+ <property name="climb_rate">1</property>
+ <property name="digits">1</property>
+ <property name="numeric">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="height_spin">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ <property name="adjustment">adjustment4</property>
+ <property name="climb_rate">1</property>
+ <property name="digits">1</property>
+ <property name="numeric">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child type="tab">
+ <object class="GtkLabel" id="label45">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes">label45</property>
+ </object>
+ <packing>
+ <property name="position">1</property>
+ <property name="tab_fill">False</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <object class="GtkListStore" id="alignment-model">
+ <columns>
+ <!-- column-name gchararray -->
+ <column type="gchararray"/>
+ </columns>
+ </object>
+ <object class="GtkListStore" id="position-model">
+ <columns>
+ <!-- column-name gchararray -->
+ <column type="gchararray"/>
+ </columns>
+ </object>
+ <object class="GtkListStore" id="anchor-model">
+ <columns>
+ <!-- column-name gchararray -->
+ <column type="gchararray"/>
+ </columns>
+ </object>
+</interface>
diff --git a/goffice/graph/gog-object.c b/goffice/graph/gog-object.c
index df63a91..4ba874d 100644
--- a/goffice/graph/gog-object.c
+++ b/goffice/graph/gog-object.c
@@ -264,7 +264,7 @@ typedef struct {
GtkWidget *position_select_combo;
GtkWidget *position_notebook;
GogObject *gobj;
- GladeXML *gui;
+ GtkBuilder *gui;
gulong update_editor_handler;
} ObjectPrefState;
@@ -364,7 +364,7 @@ gog_object_populate_editor (GogObject *gobj,
{
GtkWidget *w;
GtkSizeGroup *widget_size_group, *label_size_group;
- GladeXML *gui;
+ GtkBuilder *gui;
GogObjectClass *gog_klass;
GogObjectPosition allowable_positions, flags;
ObjectPrefState *state;
@@ -379,7 +379,7 @@ gog_object_populate_editor (GogObject *gobj,
if (!(allowable_positions & (GOG_POSITION_MANUAL | GOG_POSITION_COMPASS)))
return;
- gui = go_glade_new ("gog-object-prefs.glade", "gog_object_prefs", GETTEXT_PACKAGE, cc);
+ gui = go_gtk_builder_new ("gog-object-prefs.ui", GETTEXT_PACKAGE, cc);
if (gui == NULL)
return;
@@ -391,7 +391,7 @@ gog_object_populate_editor (GogObject *gobj,
state->y_spin = NULL;
state->w_spin = NULL;
state->h_spin = NULL;
- state->position_notebook = glade_xml_get_widget (gui, "position_notebook");
+ state->position_notebook = go_gtk_builder_get_widget (gui, "position_notebook");
g_object_ref (G_OBJECT (gobj));
@@ -399,7 +399,7 @@ gog_object_populate_editor (GogObject *gobj,
label_size_group = gtk_size_group_new (GTK_SIZE_GROUP_HORIZONTAL);
if (allowable_positions & GOG_POSITION_COMPASS) {
- w = glade_xml_get_widget (gui, "position_combo");
+ w = go_gtk_builder_get_widget (gui, "position_combo");
gtk_size_group_add_widget (widget_size_group, w);
flags = gog_object_get_position_flags (gobj, GOG_POSITION_COMPASS);
for (i = 0; i < G_N_ELEMENTS (position_compass); i++) {
@@ -408,28 +408,27 @@ gog_object_populate_editor (GogObject *gobj,
gtk_combo_box_set_active (GTK_COMBO_BOX (w), i);
}
g_signal_connect (G_OBJECT (w), "changed", G_CALLBACK (cb_compass_changed), state);
- w = glade_xml_get_widget (gui, "position_label");
+ w = go_gtk_builder_get_widget (gui, "position_label");
gtk_size_group_add_widget (label_size_group, w);
} else {
- w = glade_xml_get_widget (gui, "compass_position");
+ w = go_gtk_builder_get_widget (gui, "compass_position");
gtk_widget_hide (w);
}
-
if (allowable_positions & GOG_POSITION_COMPASS) {
- w = glade_xml_get_widget (gui, "alignment_combo");
+ w = go_gtk_builder_get_widget (gui, "alignment_combo");
gtk_size_group_add_widget (widget_size_group, w);
flags = gog_object_get_position_flags (gobj, GOG_POSITION_ALIGNMENT);
- for (i = 0; i < G_N_ELEMENTS (position_alignment); i++) {
+ for (i = 0; i < G_N_ELEMENTS (position_alignment); i++) {
gtk_combo_box_append_text (GTK_COMBO_BOX (w), _(position_alignment[i].label));
if (position_alignment[i].flags == flags)
gtk_combo_box_set_active (GTK_COMBO_BOX (w), i);
}
g_signal_connect (G_OBJECT (w), "changed", G_CALLBACK (cb_alignment_changed), state);
- w = glade_xml_get_widget (gui, "alignment_label");
+ w = go_gtk_builder_get_widget (gui, "alignment_label");
gtk_size_group_add_widget (label_size_group, w);
} else {
- w = glade_xml_get_widget (gui, "compass_alignment");
+ w = go_gtk_builder_get_widget (gui, "compass_alignment");
gtk_widget_hide (w);
}
@@ -443,25 +442,25 @@ gog_object_populate_editor (GogObject *gobj,
label_size_group = gtk_size_group_new (GTK_SIZE_GROUP_HORIZONTAL);
if (allowable_positions & GOG_POSITION_MANUAL) {
- w = glade_xml_get_widget (gui, "x_label");
+ w = go_gtk_builder_get_widget (gui, "x_label");
gtk_size_group_add_widget (label_size_group, w);
- w = glade_xml_get_widget (gui, "x_spin");
+ w = go_gtk_builder_get_widget (gui, "x_spin");
gtk_size_group_add_widget (widget_size_group, w);
gtk_spin_button_set_value (GTK_SPIN_BUTTON (w), gobj->manual_position.x * 100.0);
g_signal_connect (G_OBJECT (w), "value-changed", G_CALLBACK (cb_position_changed), state);
state->x_spin = w;
- w = glade_xml_get_widget (gui, "y_label");
+ w = go_gtk_builder_get_widget (gui, "y_label");
gtk_size_group_add_widget (label_size_group, w);
- w = glade_xml_get_widget (gui, "y_spin");
+ w = go_gtk_builder_get_widget (gui, "y_spin");
gtk_size_group_add_widget (widget_size_group, w);
gtk_spin_button_set_value (GTK_SPIN_BUTTON (w), gobj->manual_position.y * 100.0);
g_signal_connect (G_OBJECT (w), "value-changed", G_CALLBACK (cb_position_changed), state);
state->y_spin = w;
- w = glade_xml_get_widget (gui, "anchor_label");
+ w = go_gtk_builder_get_widget (gui, "anchor_label");
gtk_size_group_add_widget (label_size_group, w);
- w = glade_xml_get_widget (gui, "anchor_combo");
+ w = go_gtk_builder_get_widget (gui, "anchor_combo");
flags = gog_object_get_position_flags (gobj, GOG_POSITION_ANCHOR);
for (i = 0; i < G_N_ELEMENTS (position_anchor); i++) {
gtk_combo_box_append_text (GTK_COMBO_BOX (w), _(position_anchor[i].label));
@@ -472,25 +471,25 @@ gog_object_populate_editor (GogObject *gobj,
gtk_combo_box_set_wrap_width (GTK_COMBO_BOX (w), 3);
if (gog_klass->can_manual_size) {
- w = glade_xml_get_widget (gui, "width_label");
+ w = go_gtk_builder_get_widget (gui, "width_label");
gtk_size_group_add_widget (label_size_group, w);
- w = glade_xml_get_widget (gui, "width_spin");
+ w = go_gtk_builder_get_widget (gui, "width_spin");
gtk_size_group_add_widget (widget_size_group, w);
gtk_spin_button_set_value (GTK_SPIN_BUTTON (w), gobj->manual_position.w * 100.0);
g_signal_connect (G_OBJECT (w), "value-changed",
G_CALLBACK (cb_position_changed), state);
state->w_spin = w;
- w = glade_xml_get_widget (gui, "height_label");
+ w = go_gtk_builder_get_widget (gui, "height_label");
gtk_size_group_add_widget (label_size_group, w);
- w = glade_xml_get_widget (gui, "height_spin");
+ w = go_gtk_builder_get_widget (gui, "height_spin");
gtk_size_group_add_widget (widget_size_group, w);
gtk_spin_button_set_value (GTK_SPIN_BUTTON (w), gobj->manual_position.h * 100.0);
g_signal_connect (G_OBJECT (w), "value-changed",
G_CALLBACK (cb_position_changed), state);
state->h_spin = w;
} else {
- w = glade_xml_get_widget (gui, "manual_sizes");
+ w = go_gtk_builder_get_widget (gui, "manual_sizes");
gtk_widget_hide (w);
}
} else
@@ -502,14 +501,14 @@ gog_object_populate_editor (GogObject *gobj,
if ((allowable_positions & GOG_POSITION_MANUAL) &&
((allowable_positions & (GOG_POSITION_COMPASS | GOG_POSITION_ALIGNMENT)) ||
(allowable_positions & GOG_POSITION_SPECIAL))) {
- state->position_select_combo = glade_xml_get_widget (gui, "position_select_combo");
+ state->position_select_combo = go_gtk_builder_get_widget (gui, "position_select_combo");
update_select_state (state);
g_signal_connect (G_OBJECT (state->position_select_combo),
"changed", G_CALLBACK (cb_manual_position_changed), state);
} else {
- w = glade_xml_get_widget (gui, "position_select_box");
+ w = go_gtk_builder_get_widget (gui, "position_select_box");
gtk_widget_hide (w);
}
@@ -517,9 +516,8 @@ gog_object_populate_editor (GogObject *gobj,
"update-editor",
G_CALLBACK (cb_update_editor), state);
- w = glade_xml_get_widget (gui, "gog_object_prefs");
- g_object_set_data_full (G_OBJECT (w), "state", state,
- (GDestroyNotify) object_pref_state_free);
+ w = go_gtk_builder_get_widget (gui, "gog_object_prefs");
+ g_signal_connect_swapped (G_OBJECT (w), "destroy", G_CALLBACK (object_pref_state_free), state);
go_editor_add_page (editor, w, _("Position"));
}
#endif
diff --git a/goffice/graph/gog-plot-prefs.ui b/goffice/graph/gog-plot-prefs.ui
new file mode 100644
index 0000000..3ae6d84
--- /dev/null
+++ b/goffice/graph/gog-plot-prefs.ui
@@ -0,0 +1,295 @@
+<?xml version="1.0"?>
+<interface>
+ <requires lib="gtk+" version="2.16"/>
+ <!-- interface-naming-policy toplevel-contextual -->
+ <object class="GtkAdjustment" id="adjustment1">
+ <property name="upper">100</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment2">
+ <property name="upper">100</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment3">
+ <property name="upper">100</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment4">
+ <property name="upper">100</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkListStore" id="model1">
+ <columns>
+ <!-- column-name gchararray -->
+ <column type="gchararray"/>
+ </columns>
+ <data>
+ <row>
+ <col id="0" translatable="yes">Automatic</col>
+ </row>
+ <row>
+ <col id="0" translatable="yes">Manual</col>
+ </row>
+ </data>
+ </object>
+ <object class="GtkVBox" id="gog_plot_prefs">
+ <property name="visible">True</property>
+ <property name="border_width">12</property>
+ <property name="orientation">vertical</property>
+ <child>
+ <object class="GtkVBox" id="plot_area_box">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkHBox" id="hbox1">
+ <property name="visible">True</property>
+ <property name="spacing">12</property>
+ <child>
+ <object class="GtkLabel" id="label54">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes">_Object position:</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkComboBox" id="position_select_combo">
+ <property name="visible">True</property>
+ <property name="model">model1</property>
+ <child>
+ <object class="GtkCellRendererText" id="renderer1"/>
+ <attributes>
+ <attribute name="text">0</attribute>
+ </attributes>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkTable" id="manual_setting_table">
+ <property name="visible">True</property>
+ <property name="n_rows">4</property>
+ <property name="n_columns">3</property>
+ <property name="column_spacing">12</property>
+ <property name="row_spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="label47">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Y:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">y_spin</property>
+ </object>
+ <packing>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label48">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Width:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">w_spin</property>
+ </object>
+ <packing>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label49">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Height:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">h_spin</property>
+ </object>
+ <packing>
+ <property name="top_attach">3</property>
+ <property name="bottom_attach">4</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label51">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">%</property>
+ </object>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label52">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">%</property>
+ </object>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label53">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">%</property>
+ </object>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
+ <property name="top_attach">3</property>
+ <property name="bottom_attach">4</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="x_spin">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ <property name="adjustment">adjustment1</property>
+ <property name="climb_rate">1</property>
+ <property name="digits">1</property>
+ <property name="numeric">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="y_spin">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ <property name="adjustment">adjustment2</property>
+ <property name="climb_rate">1</property>
+ <property name="digits">1</property>
+ <property name="numeric">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="w_spin">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ <property name="adjustment">adjustment3</property>
+ <property name="climb_rate">1</property>
+ <property name="digits">1</property>
+ <property name="numeric">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="h_spin">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ <property name="adjustment">adjustment4</property>
+ <property name="climb_rate">1</property>
+ <property name="digits">1</property>
+ <property name="numeric">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="top_attach">3</property>
+ <property name="bottom_attach">4</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label50">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">%</property>
+ </object>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label46">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_X:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">x_spin</property>
+ </object>
+ <packing>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ </object>
+</interface>
diff --git a/goffice/graph/gog-plot.c b/goffice/graph/gog-plot.c
index 9f6e359..54fe451 100644
--- a/goffice/graph/gog-plot.c
+++ b/goffice/graph/gog-plot.c
@@ -136,7 +136,7 @@ role_series_pre_remove (GogObject *parent, GogObject *series)
#ifdef GOFFICE_WITH_GTK
typedef struct {
- GladeXML *gui;
+ GtkBuilder *gui;
GtkWidget *x_spin, *y_spin, *w_spin, *h_spin;
gulong w_spin_signal, h_spin_signal;
GtkWidget *position_select_combo;
@@ -278,12 +278,12 @@ gog_plot_populate_editor (GogObject *obj,
GtkListStore *store;
GtkTreeIter iter;
GtkCellRenderer *cell;
- GladeXML *gui;
+ GtkBuilder *gui;
PlotPrefState *state;
gboolean is_plot_area_manual;
g_return_if_fail (chart != NULL);
- gui = go_glade_new ("gog-plot-prefs.glade", "gog_plot_prefs", GETTEXT_PACKAGE, cc);
+ gui = go_gtk_builder_new ("gog-plot-prefs.ui", GETTEXT_PACKAGE, cc);
g_return_if_fail (gui != NULL);
state = g_new (PlotPrefState, 1);
@@ -351,19 +351,19 @@ gog_plot_populate_editor (GogObject *obj,
is_plot_area_manual = gog_chart_get_plot_area (chart, &plot_area);
- state->x_spin = glade_xml_get_widget (gui, "x_spin");
+ state->x_spin = go_gtk_builder_get_widget (gui, "x_spin");
gtk_spin_button_set_value (GTK_SPIN_BUTTON (state->x_spin),
plot_area.x * 100.0);
g_signal_connect (G_OBJECT (state->x_spin), "value-changed",
G_CALLBACK (cb_plot_area_changed), state);
- state->y_spin = glade_xml_get_widget (gui, "y_spin");
+ state->y_spin = go_gtk_builder_get_widget (gui, "y_spin");
gtk_spin_button_set_value (GTK_SPIN_BUTTON (state->y_spin),
plot_area.y * 100.0);
g_signal_connect (G_OBJECT (state->y_spin), "value-changed",
G_CALLBACK (cb_plot_area_changed), state);
- state->w_spin = glade_xml_get_widget (gui, "w_spin");
+ state->w_spin = go_gtk_builder_get_widget (gui, "w_spin");
gtk_spin_button_set_range (GTK_SPIN_BUTTON (state->w_spin),
0.0, (1.0 - plot_area.x) * 100.0);
gtk_spin_button_set_value (GTK_SPIN_BUTTON (state->w_spin),
@@ -371,7 +371,7 @@ gog_plot_populate_editor (GogObject *obj,
state->w_spin_signal = g_signal_connect (G_OBJECT (state->w_spin), "value-changed",
G_CALLBACK (cb_plot_area_changed), state);
- state->h_spin = glade_xml_get_widget (gui, "h_spin");
+ state->h_spin = go_gtk_builder_get_widget (gui, "h_spin");
gtk_spin_button_set_range (GTK_SPIN_BUTTON (state->h_spin),
0.0, (1.0 - plot_area.y) * 100.0);
gtk_spin_button_set_value (GTK_SPIN_BUTTON (state->h_spin),
@@ -379,19 +379,18 @@ gog_plot_populate_editor (GogObject *obj,
state->h_spin_signal = g_signal_connect (G_OBJECT (state->h_spin), "value-changed",
G_CALLBACK (cb_plot_area_changed), state);
- state->position_select_combo = glade_xml_get_widget (gui, "position_select_combo");
+ state->position_select_combo = go_gtk_builder_get_widget (gui, "position_select_combo");
gtk_combo_box_set_active (GTK_COMBO_BOX (state->position_select_combo),
is_plot_area_manual ? 1 : 0);
- state->manual_setting_table = glade_xml_get_widget (gui, "manual_setting_table");
+ state->manual_setting_table = go_gtk_builder_get_widget (gui, "manual_setting_table");
if (!is_plot_area_manual)
gtk_widget_hide (state->manual_setting_table);
g_signal_connect (G_OBJECT (state->position_select_combo),
"changed", G_CALLBACK (cb_manual_position_changed), state);
- w = glade_xml_get_widget (gui, "gog_plot_prefs");
- g_object_set_data_full (G_OBJECT (w), "state", state,
- (GDestroyNotify) plot_pref_state_free);
+ w = go_gtk_builder_get_widget (gui, "gog_plot_prefs");
+ g_signal_connect_swapped (G_OBJECT (w), "destroy", G_CALLBACK (plot_pref_state_free), state);
go_editor_add_page (editor, w, _("Plot area"));
state->update_editor_handler = g_signal_connect (G_OBJECT (plot),
diff --git a/goffice/graph/gog-reg-curve-prefs.ui b/goffice/graph/gog-reg-curve-prefs.ui
new file mode 100644
index 0000000..2fe4099
--- /dev/null
+++ b/goffice/graph/gog-reg-curve-prefs.ui
@@ -0,0 +1,62 @@
+<?xml version="1.0"?>
+<interface>
+ <requires lib="gtk+" version="2.16"/>
+ <!-- interface-naming-policy toplevel-contextual -->
+ <object class="GtkTable" id="reg-curve-prefs">
+ <property name="visible">True</property>
+ <property name="border_width">12</property>
+ <property name="n_rows">3</property>
+ <property name="n_columns">2</property>
+ <property name="column_spacing">12</property>
+ <property name="row_spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="label1">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="xpad">5</property>
+ <property name="label" translatable="yes">Low bound:</property>
+ </object>
+ <packing>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label2">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="xpad">5</property>
+ <property name="label" translatable="yes">High bound:</property>
+ </object>
+ <packing>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkCheckButton" id="skip-invalid">
+ <property name="label" translatable="yes">Skip invalid data</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="right_attach">2</property>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ </object>
+</interface>
diff --git a/goffice/graph/gog-reg-curve.c b/goffice/graph/gog-reg-curve.c
index 1e56113..2296952 100644
--- a/goffice/graph/gog-reg-curve.c
+++ b/goffice/graph/gog-reg-curve.c
@@ -59,25 +59,25 @@ gog_reg_curve_populate_editor (GogObject *gobj,
{
GtkWidget *w;
GtkTable *table;
- GladeXML *gui;
+ GtkBuilder *gui;
GogDataset *set = GOG_DATASET (gobj);
- gui = go_glade_new ("gog-reg-curve-prefs.glade", "reg-curve-prefs", GETTEXT_PACKAGE, cc);
+ gui = go_gtk_builder_new ("gog-reg-curve-prefs.ui", GETTEXT_PACKAGE, cc);
if (gui == NULL)
return;
go_editor_add_page (editor,
- glade_xml_get_widget (gui, "reg-curve-prefs"),
+ go_gtk_builder_get_widget (gui, "reg-curve-prefs"),
_("Details"));
- table = GTK_TABLE (glade_xml_get_widget (gui, "reg-curve-prefs"));
+ table = GTK_TABLE (gtk_builder_get_object (gui, "reg-curve-prefs"));
w = GTK_WIDGET (gog_data_allocator_editor (dalloc, set, 0, GOG_DATA_SCALAR));
gtk_widget_show (w);
gtk_table_attach (table, w, 1, 2, 0, 1, GTK_FILL | GTK_EXPAND, 0, 0, 0);
w = GTK_WIDGET (gog_data_allocator_editor (dalloc, set, 1, GOG_DATA_SCALAR));
gtk_widget_show (w);
gtk_table_attach (table, w, 1, 2, 1, 2, GTK_FILL | GTK_EXPAND, 0, 0, 0);
- w = glade_xml_get_widget (gui, "skip-invalid");
+ w = go_gtk_builder_get_widget (gui, "skip-invalid");
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (w),
(GOG_REG_CURVE (gobj))->skip_invalid);
g_signal_connect (G_OBJECT (w), "toggled",
@@ -85,6 +85,7 @@ gog_reg_curve_populate_editor (GogObject *gobj,
if ((GOG_REG_CURVE_GET_CLASS (gobj))->populate_editor != NULL)
(GOG_REG_CURVE_GET_CLASS (gobj))->populate_editor (GOG_REG_CURVE (gobj), table);
+ g_object_unref (gui);
(GOG_OBJECT_CLASS (reg_curve_parent_klass)->populate_editor) (gobj, editor, dalloc, cc);
}
diff --git a/goffice/graph/gog-reg-eqn-prefs.ui b/goffice/graph/gog-reg-eqn-prefs.ui
new file mode 100644
index 0000000..3bf87e2
--- /dev/null
+++ b/goffice/graph/gog-reg-eqn-prefs.ui
@@ -0,0 +1,41 @@
+<?xml version="1.0"?>
+<interface>
+ <requires lib="gtk+" version="2.16"/>
+ <!-- interface-naming-policy toplevel-contextual -->
+ <object class="GtkVBox" id="reg-eqn-prefs">
+ <property name="visible">True</property>
+ <property name="border_width">12</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkCheckButton" id="show_eq">
+ <property name="label" translatable="yes">Display _equation</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkCheckButton" id="show_r2">
+ <property name="label" translatable="yes">Display _regression coefficient R²</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+</interface>
diff --git a/goffice/graph/gog-series-prefs.ui b/goffice/graph/gog-series-prefs.ui
new file mode 100644
index 0000000..b46a046
--- /dev/null
+++ b/goffice/graph/gog-series-prefs.ui
@@ -0,0 +1,171 @@
+<?xml version="1.0"?>
+<interface>
+ <requires lib="gtk+" version="2.16"/>
+ <!-- interface-naming-policy toplevel-contextual -->
+ <object class="GtkListStore" id="model1">
+ <columns>
+ <!-- column-name gchararray -->
+ <column type="gchararray"/>
+ </columns>
+ <data>
+ <row>
+ <col id="0" translatable="yes">content</col>
+ </row>
+ </data>
+ </object>
+ <object class="GtkVBox" id="interpolation_prefs">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <child>
+ <object class="GtkLabel" id="interpolation-label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes"><b>Interpolation</b></property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkAlignment" id="alignment8">
+ <property name="visible">True</property>
+ <property name="top_padding">6</property>
+ <property name="left_padding">18</property>
+ <child>
+ <object class="GtkTable" id="interpolation-table">
+ <property name="visible">True</property>
+ <property name="n_rows">3</property>
+ <property name="n_columns">2</property>
+ <property name="column_spacing">12</property>
+ <property name="row_spacing">6</property>
+ <child>
+ <object class="GtkTable" id="clamps-table">
+ <property name="n_rows">2</property>
+ <property name="n_columns">2</property>
+ <property name="column_spacing">12</property>
+ <property name="row_spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="deriv-last-btn">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes"><i>y'</i>(<i>x</i><sub>last</sub>):</property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="deriv-first-btn">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes"><i>y'</i>(<i>x</i><sub>first</sub>):</property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="x_options">GTK_FILL</property>
+ </packing>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ </object>
+ <packing>
+ <property name="right_attach">2</property>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="interpolation-type-label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="yalign">0.46000000834465027</property>
+ <property name="label" translatable="yes">_Type:</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="x_options">GTK_FILL</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkCheckButton" id="interpolation-skip-invalid">
+ <property name="label" translatable="yes">S_kip invalid data</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="right_attach">2</property>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ </packing>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <object class="GtkVBox" id="fill_type_prefs">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <child>
+ <object class="GtkHBox" id="hbox1">
+ <property name="visible">True</property>
+ <property name="spacing">12</property>
+ <child>
+ <object class="GtkLabel" id="label2">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="yalign">0.46000000834465027</property>
+ <property name="label" translatable="yes">Fill _to:</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkComboBox" id="fill_type_combo">
+ <property name="visible">True</property>
+ <property name="model">model1</property>
+ <child>
+ <object class="GtkCellRendererText" id="renderer1"/>
+ <attributes>
+ <attribute name="text">0</attribute>
+ </attributes>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ </object>
+</interface>
diff --git a/goffice/graph/gog-series.c b/goffice/graph/gog-series.c
index 643467c..ac33541 100644
--- a/goffice/graph/gog-series.c
+++ b/goffice/graph/gog-series.c
@@ -405,9 +405,9 @@ cb_show_in_legend (GtkToggleButton *b, GObject *series)
static void
cb_line_interpolation_changed (GtkComboBox *box, GogSeries *series)
{
- GladeXML *gui = g_object_get_data (G_OBJECT (box), "gui");
+ GtkBuilder *gui = g_object_get_data (G_OBJECT (box), "gui");
GtkWidget *widget = GTK_WIDGET (g_object_get_data (G_OBJECT(box), "skip-button"));
- GtkWidget *table = glade_xml_get_widget (gui, "clamps-table");
+ GtkWidget *table = go_gtk_builder_get_widget (gui, "clamps-table");
series->interpolation = gtk_combo_box_get_active (box);
gtk_widget_set_sensitive (widget, !go_line_interpolation_auto_skip (series->interpolation));
widget = GTK_WIDGET (g_object_get_data (G_OBJECT(box), "fill-type"));
@@ -517,17 +517,17 @@ gog_series_populate_editor (GogObject *gobj,
box = go_editor_get_registered_widget (editor, "line_box");
if (series_class->has_interpolation && box != NULL) {
- GladeXML *gui;
+ GtkBuilder *gui;
GtkWidget *widget;
- gui = go_glade_new ("gog-series-prefs.glade", "interpolation_prefs", GETTEXT_PACKAGE, cc);
+ gui = go_gtk_builder_new ("gog-series-prefs.ui", GETTEXT_PACKAGE, cc);
if (gui != NULL) {
int i;
GogAxisSet set = gog_plot_axis_set_pref (gog_series_get_plot (series));
GogDataset *clamp_set = gog_series_get_interpolation_params (series);
- widget = glade_xml_get_widget (gui, "interpolation_prefs");
+ widget = go_gtk_builder_get_widget (gui, "interpolation_prefs");
gtk_box_pack_start (GTK_BOX (box), widget, FALSE, FALSE, 0);
- widget = glade_xml_get_widget (gui, "interpolation-table");
+ widget = go_gtk_builder_get_widget (gui, "interpolation-table");
/* create an interpolation type combo and populate it */
combo = GTK_COMBO_BOX (gtk_combo_box_new_text ());
if (set & 1 << GOG_AXIS_RADIAL)
@@ -545,7 +545,7 @@ gog_series_populate_editor (GogObject *gobj,
0, 1, (GtkAttachOptions) (GTK_FILL | GTK_EXPAND),
(GtkAttachOptions) (GTK_FILL | GTK_EXPAND), 0, 0);
gtk_widget_show_all (widget);
- widget = glade_xml_get_widget (gui, "interpolation-skip-invalid");
+ widget = go_gtk_builder_get_widget (gui, "interpolation-skip-invalid");
g_object_set_data (G_OBJECT (combo), "skip-button", widget);
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (widget), series->interpolation_skip_invalid);
if (go_line_interpolation_auto_skip (series->interpolation))
@@ -554,7 +554,7 @@ gog_series_populate_editor (GogObject *gobj,
G_CALLBACK (cb_line_interpolation_skip_changed), series);
if (clamp_set) {
GtkWidget *w;
- widget = glade_xml_get_widget (gui, "clamps-table");
+ widget = go_gtk_builder_get_widget (gui, "clamps-table");
w = GTK_WIDGET (gog_data_allocator_editor (dalloc, clamp_set, 0, GOG_DATA_SCALAR));
gtk_widget_show (w);
gtk_table_attach (GTK_TABLE (widget), w, 1, 2, 0, 1, GTK_FILL | GTK_EXPAND, 0, 0, 0);
@@ -564,19 +564,18 @@ gog_series_populate_editor (GogObject *gobj,
if (series->interpolation != GO_LINE_INTERPOLATION_CLAMPED_CUBIC_SPLINE)
gtk_widget_hide (widget);
}
- g_object_set_data_full (G_OBJECT (combo), "gui", gui,
- (GDestroyNotify) g_object_unref);
+ g_signal_connect_swapped (G_OBJECT (combo), "destroy", G_CALLBACK (g_object_unref), gui);
}
}
box = go_editor_get_registered_widget (editor, "fill_extension_box");
if (series_class->has_fill_type && box != NULL) {
- GladeXML *gui;
+ GtkBuilder *gui;
GtkWidget *widget;
- gui = go_glade_new ("gog-series-prefs.glade", "fill_type_prefs", GETTEXT_PACKAGE, cc);
+ gui = go_gtk_builder_new ("gog-series-prefs.ui", GETTEXT_PACKAGE, cc);
if (gui != NULL) {
- widget = glade_xml_get_widget (gui, "fill_type_combo");
+ widget = go_gtk_builder_get_widget (gui, "fill_type_combo");
gog_series_populate_fill_type_combo (GOG_SERIES (series), GTK_COMBO_BOX (widget));
g_signal_connect (G_OBJECT (widget), "changed",
G_CALLBACK (cb_fill_type_changed), series);
@@ -584,7 +583,7 @@ gog_series_populate_editor (GogObject *gobj,
g_object_set_data (G_OBJECT (combo), "fill-type", widget);
if (series->interpolation == GO_LINE_INTERPOLATION_CLOSED_SPLINE)
gtk_widget_set_sensitive (widget, FALSE);
- widget = glade_xml_get_widget (gui, "fill_type_prefs");
+ widget = go_gtk_builder_get_widget (gui, "fill_type_prefs");
gtk_box_pack_start (GTK_BOX (box), widget, TRUE, TRUE, 0);
g_object_set_data_full (G_OBJECT (widget), "gui", gui,
(GDestroyNotify) g_object_unref);
diff --git a/goffice/gtk/Makefile.am b/goffice/gtk/Makefile.am
index ece67ea..3f7169d 100644
--- a/goffice/gtk/Makefile.am
+++ b/goffice/gtk/Makefile.am
@@ -75,14 +75,14 @@ libgoffice_gtk_la_HEADERS = \
go-graph-widget.h \
go-image-sel.h
-gladedir = $(goffice_datadir)/glade
-dist_glade_DATA = \
- go-rotation-sel.glade \
- go-font-sel.glade \
- go-format-sel.glade \
- go-3d-rotation-sel.glade \
- go-image-save-dialog-extra.glade \
- go-image-sel.glade
+uidir = $(goffice_datadir)/ui
+dist_ui_DATA = \
+ go-rotation-sel.ui \
+ go-font-sel.ui \
+ go-format-sel.ui \
+ go-3d-rotation-sel.ui \
+ go-image-save-dialog-extra.ui \
+ go-image-sel.ui
EXTRA_DIST = $(UNUSED)
diff --git a/goffice/gtk/go-3d-rotation-sel.c b/goffice/gtk/go-3d-rotation-sel.c
index 42dfd52..7cb81dc 100644
--- a/goffice/gtk/go-3d-rotation-sel.c
+++ b/goffice/gtk/go-3d-rotation-sel.c
@@ -37,7 +37,7 @@ typedef struct {
struct _GO3DRotationSel {
GtkHBox box;
- GladeXML *gui;
+ GtkBuilder *gui;
GtkRange *fovscale;
double psi;
double theta;
@@ -334,7 +334,7 @@ g3d_init (GO3DRotationSel *g3d)
{
GtkWidget *w;
- g3d->gui = go_glade_new ("go-3d-rotation-sel.glade", "toplevel",
+ g3d->gui = go_gtk_builder_new ("go-3d-rotation-sel.ui",
GETTEXT_PACKAGE, NULL);
if (g3d->gui == NULL)
return;
@@ -348,7 +348,7 @@ g3d_init (GO3DRotationSel *g3d)
g3d->bank_dial = NULL;
memset (g3d->cube_polygons, 0, sizeof (g3d->cube_polygons));
g3d->rotate_canvas = GOC_CANVAS (g_object_new (GOC_TYPE_CANVAS, NULL));
- gtk_container_add (GTK_CONTAINER (glade_xml_get_widget (g3d->gui,
+ gtk_container_add (GTK_CONTAINER (gtk_builder_get_object (g3d->gui,
"rotate_canvas")),
GTK_WIDGET (g3d->rotate_canvas));
gtk_widget_show (GTK_WIDGET (g3d->rotate_canvas));
@@ -363,14 +363,14 @@ g3d_init (GO3DRotationSel *g3d)
G_CALLBACK (cb_rotate_canvas_button), g3d,
NULL);
- g3d->fovscale = GTK_RANGE (glade_xml_get_widget (g3d->gui, "fovscale"));
+ g3d->fovscale = GTK_RANGE (gtk_builder_get_object (g3d->gui, "fovscale"));
g_object_connect (G_OBJECT (g3d->fovscale),
"signal::button-release-event",
G_CALLBACK (cb_fov_changed), g3d,
"signal::key-release-event",
G_CALLBACK (cb_fov_changed), g3d,
NULL);
- w = glade_xml_get_widget (g3d->gui, "toplevel");
+ w = go_gtk_builder_get_widget (g3d->gui, "toplevel");
gtk_box_pack_start (GTK_BOX (g3d), w, TRUE, TRUE, 0);
gtk_widget_show_all (GTK_WIDGET (g3d));
}
diff --git a/goffice/gtk/go-3d-rotation-sel.ui b/goffice/gtk/go-3d-rotation-sel.ui
new file mode 100644
index 0000000..21e6f8c
--- /dev/null
+++ b/goffice/gtk/go-3d-rotation-sel.ui
@@ -0,0 +1,88 @@
+<?xml version="1.0"?>
+<interface>
+ <requires lib="gtk+" version="2.16"/>
+ <!-- interface-naming-policy toplevel-contextual -->
+ <object class="GtkAdjustment" id="adjustment1">
+ <property name="upper">90</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkHBox" id="toplevel">
+ <property name="visible">True</property>
+ <property name="border_width">12</property>
+ <property name="spacing">24</property>
+ <child>
+ <object class="GtkVBox" id="vbox7">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">12</property>
+ <child>
+ <object class="GtkLabel" id="label1">
+ <property name="visible">True</property>
+ <property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes"><b>Rotation</b></property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHBox" id="hbox1">
+ <property name="visible">True</property>
+ <property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
+ <child>
+ <object class="GtkScrolledWindow" id="rotate_canvas">
+ <property name="width_request">220</property>
+ <property name="height_request">220</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
+ <property name="hscrollbar_policy">never</property>
+ <property name="vscrollbar_policy">never</property>
+ <property name="shadow_type">in</property>
+ <child>
+ <placeholder/>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVScale" id="fovscale">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
+ <property name="orientation">vertical</property>
+ <property name="adjustment">adjustment1</property>
+ <property name="digits">0</property>
+ <property name="draw_value">False</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ </object>
+</interface>
diff --git a/goffice/gtk/go-combo-text.c b/goffice/gtk/go-combo-text.c
index 5c0cdbf..2006266 100644
--- a/goffice/gtk/go-combo-text.c
+++ b/goffice/gtk/go-combo-text.c
@@ -283,7 +283,7 @@ go_combo_text_new (GCompareFunc cmp_func)
}
GtkWidget *
-go_combo_text_glade_new (void)
+go_combo_text_new_default (void)
{
return go_combo_text_new (NULL);
}
diff --git a/goffice/gtk/go-combo-text.h b/goffice/gtk/go-combo-text.h
index 367984e..1d13e6b 100644
--- a/goffice/gtk/go-combo-text.h
+++ b/goffice/gtk/go-combo-text.h
@@ -20,7 +20,7 @@ typedef enum { /* begin the search from : */
GType go_combo_text_get_type (void);
GtkWidget *go_combo_text_new (GCompareFunc cmp_func);
-GtkWidget *go_combo_text_glade_new (void);
+GtkWidget *go_combo_text_new_default (void);
GtkWidget *go_combo_text_get_entry (GOComboText *ct);
gboolean go_combo_text_set_text (GOComboText *ct, const gchar *text,
diff --git a/goffice/gtk/go-font-sel.c b/goffice/gtk/go-font-sel.c
index 063c27e..857e137 100644
--- a/goffice/gtk/go-font-sel.c
+++ b/goffice/gtk/go-font-sel.c
@@ -20,7 +20,7 @@
struct _GOFontSel {
GtkHBox box;
- GladeXML *gui;
+ GtkBuilder *gui;
GtkWidget *font_name_entry;
GtkWidget *font_style_entry;
@@ -334,26 +334,26 @@ gfs_init (GOFontSel *gfs)
{
GtkWidget *w;
- gfs->gui = go_glade_new ("go-font-sel.glade", "toplevel-table", GETTEXT_PACKAGE, NULL);
+ gfs->gui = go_gtk_builder_new ("go-font-sel.ui", GETTEXT_PACKAGE, NULL);
if (gfs->gui == NULL)
return;
gfs->modifications = pango_attr_list_new ();
gtk_box_pack_start (GTK_BOX (gfs),
- glade_xml_get_widget (gfs->gui, "toplevel-table"),
- TRUE, TRUE, 0);
- gfs->font_name_entry = glade_xml_get_widget (gfs->gui, "font-name-entry");
- gfs->font_style_entry = glade_xml_get_widget (gfs->gui, "font-style-entry");
- gfs->font_size_entry = glade_xml_get_widget (gfs->gui, "font-size-entry");
- gfs->font_name_list = GTK_TREE_VIEW (glade_xml_get_widget (gfs->gui, "font-name-list"));
- gfs->font_style_list = GTK_TREE_VIEW (glade_xml_get_widget (gfs->gui, "font-style-list"));
- gfs->font_size_list = GTK_TREE_VIEW (glade_xml_get_widget (gfs->gui, "font-size-list"));
+ go_gtk_builder_get_widget (gfs->gui, "toplevel-table"),
+ TRUE, TRUE, 0);
+ gfs->font_name_entry = go_gtk_builder_get_widget (gfs->gui, "font-name-entry");
+ gfs->font_style_entry = go_gtk_builder_get_widget (gfs->gui, "font-style-entry");
+ gfs->font_size_entry = go_gtk_builder_get_widget (gfs->gui, "font-size-entry");
+ gfs->font_name_list = GTK_TREE_VIEW (gtk_builder_get_object (gfs->gui, "font-name-list"));
+ gfs->font_style_list = GTK_TREE_VIEW (gtk_builder_get_object (gfs->gui, "font-style-list"));
+ gfs->font_size_list = GTK_TREE_VIEW (gtk_builder_get_object (gfs->gui, "font-size-list"));
w = GTK_WIDGET (g_object_new (GOC_TYPE_CANVAS, NULL));
gfs->font_preview_canvas = GOC_CANVAS (w);
gtk_widget_show_all (w);
- w = glade_xml_get_widget (gfs->gui, "font-preview-frame");
+ w = go_gtk_builder_get_widget (gfs->gui, "font-preview-frame");
gtk_container_add (GTK_CONTAINER (w), GTK_WIDGET (gfs->font_preview_canvas));
gfs->font_preview_text = goc_item_new (
diff --git a/goffice/gtk/go-font-sel.ui b/goffice/gtk/go-font-sel.ui
new file mode 100644
index 0000000..c68931d
--- /dev/null
+++ b/goffice/gtk/go-font-sel.ui
@@ -0,0 +1,174 @@
+<?xml version="1.0"?>
+<interface>
+ <requires lib="gtk+" version="2.16"/>
+ <!-- interface-naming-policy toplevel-contextual -->
+ <object class="GtkTable" id="toplevel-table">
+ <property name="visible">True</property>
+ <property name="n_rows">4</property>
+ <property name="n_columns">3</property>
+ <property name="column_spacing">4</property>
+ <property name="row_spacing">4</property>
+ <child>
+ <object class="GtkEntry" id="font-style-entry">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="editable">False</property>
+ <property name="invisible_char">•</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label1">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Font:</property>
+ <property name="justify">center</property>
+ </object>
+ <packing>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label2">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Font style:</property>
+ <property name="justify">center</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label3">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Size:</property>
+ <property name="justify">center</property>
+ </object>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="font-name-entry">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="editable">False</property>
+ <property name="invisible_char">•</property>
+ </object>
+ <packing>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkFrame" id="font-preview-frame">
+ <property name="visible">True</property>
+ <property name="label_xalign">0</property>
+ <child type="label">
+ <object class="GtkLabel" id="label4">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes">Preview</property>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="right_attach">3</property>
+ <property name="top_attach">3</property>
+ <property name="bottom_attach">4</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="font-size-entry">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ </object>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkScrolledWindow" id="scrolledwindow2">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="hscrollbar_policy">automatic</property>
+ <property name="vscrollbar_policy">automatic</property>
+ <property name="shadow_type">in</property>
+ <child>
+ <object class="GtkTreeView" id="font-style-list">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkScrolledWindow" id="scrolledwindow1">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="hscrollbar_policy">automatic</property>
+ <property name="vscrollbar_policy">automatic</property>
+ <property name="shadow_type">in</property>
+ <child>
+ <object class="GtkTreeView" id="font-name-list">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkScrolledWindow" id="scrolledwindow3">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="hscrollbar_policy">never</property>
+ <property name="vscrollbar_policy">automatic</property>
+ <property name="shadow_type">in</property>
+ <child>
+ <object class="GtkTreeView" id="font-size-list">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ </packing>
+ </child>
+ </object>
+</interface>
diff --git a/goffice/gtk/go-format-sel.c b/goffice/gtk/go-format-sel.c
index f9885ed..f1c53dc 100644
--- a/goffice/gtk/go-format-sel.c
+++ b/goffice/gtk/go-format-sel.c
@@ -100,7 +100,7 @@ typedef enum {
struct _GOFormatSel {
GtkHBox box;
- GladeXML *gui;
+ GtkBuilder *gui;
gpointer value;
char *locale;
@@ -954,21 +954,17 @@ nfs_init (GOFormatSel *gfs)
GOFormatFamily page;
GtkWidget *toplevel;
- GtkWidget *old_parent;
gfs->enable_edit = FALSE;
gfs->show_format_with_markup = FALSE;
gfs->locale = NULL;
- gfs->gui = go_glade_new ("go-format-sel.glade", NULL, GETTEXT_PACKAGE, NULL);
+ gfs->gui = go_gtk_builder_new ("go-format-sel.ui", GETTEXT_PACKAGE, NULL);
if (gfs->gui == NULL)
return;
- toplevel = glade_xml_get_widget (gfs->gui, "number_box");
- old_parent = gtk_widget_get_toplevel (toplevel);
- gtk_widget_reparent (toplevel, GTK_WIDGET (gfs));
- gtk_widget_destroy (old_parent);
- gtk_widget_queue_resize (toplevel);
+ toplevel = go_gtk_builder_get_widget (gfs->gui, "number_box");
+ gtk_box_pack_start (GTK_BOX (gfs), toplevel, TRUE, TRUE, 0);
gfs->format.spec = go_format_general ();
go_format_ref (gfs->format.spec);
@@ -981,8 +977,8 @@ nfs_init (GOFormatSel *gfs)
study_format (gfs);
- gfs->format.preview_box = glade_xml_get_widget (gfs->gui, "preview_box");
- gfs->format.preview = GTK_TEXT_VIEW (glade_xml_get_widget (gfs->gui, "preview"));
+ gfs->format.preview_box = go_gtk_builder_get_widget (gfs->gui, "preview_box");
+ gfs->format.preview = GTK_TEXT_VIEW (gtk_builder_get_object (gfs->gui, "preview"));
{
PangoFontMetrics *metrics;
PangoContext *context;
@@ -1000,12 +996,14 @@ nfs_init (GOFormatSel *gfs)
}
gfs->format.preview_buffer = gtk_text_view_get_buffer (gfs->format.preview);
- gfs->format.menu = glade_xml_get_widget (gfs->gui, "format_menu");
+ gfs->format.menu = go_gtk_builder_get_widget (gfs->gui, "format_menu");
populate_menu (gfs);
/* Collect all the required format widgets and hide them */
for (i = 0; (name = widget_names[i]) != NULL; ++i) {
- tmp = glade_xml_get_widget (gfs->gui, name);
+ if (i == F_SYMBOL)
+ continue;
+ tmp = go_gtk_builder_get_widget (gfs->gui, name);
if (tmp == NULL) {
g_warning ("nfs_init : failed to load widget %s", name);
@@ -1106,8 +1104,11 @@ nfs_init (GOFormatSel *gfs)
g_signal_connect (G_OBJECT (combo), "entry_changed",
G_CALLBACK (cb_format_currency_select), gfs);
gtk_label_set_mnemonic_widget (
- GTK_LABEL (glade_xml_get_widget (gfs->gui, "format_symbol_label")),
+ GTK_LABEL (gtk_builder_get_object (gfs->gui, "format_symbol_label")),
GTK_WIDGET (combo));
+ /* add the combo to its container */
+ gtk_box_pack_start (GTK_BOX (gtk_builder_get_object (gfs->gui, "format_symbol_box")),
+ GTK_WIDGET (combo), TRUE, TRUE, 0);
}
/* Setup special handler for Custom */
diff --git a/goffice/gtk/go-format-sel.ui b/goffice/gtk/go-format-sel.ui
new file mode 100644
index 0000000..1a76bfe
--- /dev/null
+++ b/goffice/gtk/go-format-sel.ui
@@ -0,0 +1,625 @@
+<?xml version="1.0"?>
+<interface>
+ <requires lib="gtk+" version="2.16"/>
+ <!-- interface-naming-policy toplevel-contextual -->
+ <object class="GtkAdjustment" id="adjustment1">
+ <property name="upper">30</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">3</property>
+ </object>
+ <object class="GtkVBox" id="number_box">
+ <property name="visible">True</property>
+ <property name="border_width">12</property>
+ <child>
+ <object class="GtkHBox" id="hbox1">
+ <property name="visible">True</property>
+ <property name="spacing">12</property>
+ <child>
+ <object class="GtkVBox" id="vbox1">
+ <property name="visible">True</property>
+ <property name="spacing">12</property>
+ <child>
+ <object class="GtkVBox" id="vbox4">
+ <property name="visible">True</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="label6">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Ca_tegories:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">format_menu</property>
+ <accessibility>
+ <relation type="label-for" target="format_menu"/>
+ </accessibility>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkScrolledWindow" id="scrolledwindow1">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="hscrollbar_policy">never</property>
+ <property name="vscrollbar_policy">never</property>
+ <property name="shadow_type">in</property>
+ <child>
+ <object class="GtkTreeView" id="format_menu">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="border_width">5</property>
+ <property name="headers_visible">False</property>
+ <accessibility>
+ <relation type="labelled-by" target="label6"/>
+ </accessibility>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="preview_box">
+ <property name="visible">True</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="label7">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Preview:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">format_menu</property>
+ <accessibility>
+ <relation type="label-for" target="preview"/>
+ </accessibility>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkScrolledWindow" id="scrolledwindow2">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="hscrollbar_policy">never</property>
+ <property name="vscrollbar_policy">never</property>
+ <property name="shadow_type">in</property>
+ <child>
+ <object class="GtkTextView" id="preview">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="pixels_above_lines">2</property>
+ <property name="pixels_below_lines">2</property>
+ <property name="editable">False</property>
+ <property name="left_margin">3</property>
+ <property name="right_margin">3</property>
+ <property name="cursor_visible">False</property>
+ <accessibility>
+ <relation type="labelled-by" target="label7"/>
+ </accessibility>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="vbox2">
+ <property name="visible">True</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkTable" id="table1">
+ <property name="visible">True</property>
+ <property name="n_rows">2</property>
+ <property name="n_columns">2</property>
+ <child>
+ <object class="GtkLabel" id="format_number_explanation">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="yalign">1</property>
+ <property name="label" translatable="yes">Display numeric values with a fixed number of decimals.</property>
+ <property name="wrap">True</property>
+ </object>
+ <packing>
+ <property name="right_attach">2</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options">GTK_SHRINK</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="format_currency_explanation">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="yalign">1</property>
+ <property name="label" translatable="yes">Display currency amounts.</property>
+ <property name="wrap">True</property>
+ </object>
+ <packing>
+ <property name="right_attach">2</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options">GTK_SHRINK</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="format_accounting_explanation">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="yalign">1</property>
+ <property name="label" translatable="yes">Display amounts in traditional accounting styles.</property>
+ <property name="wrap">True</property>
+ </object>
+ <packing>
+ <property name="right_attach">2</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options">GTK_SHRINK</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="format_date_explanation">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="yalign">1</property>
+ <property name="label" translatable="yes">Display dates and optionally times of day.</property>
+ <property name="wrap">True</property>
+ </object>
+ <packing>
+ <property name="right_attach">2</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options">GTK_SHRINK</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="format_time_explanation">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="yalign">1</property>
+ <property name="label" translatable="yes">Display times of day.</property>
+ <property name="wrap">True</property>
+ </object>
+ <packing>
+ <property name="right_attach">2</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options">GTK_SHRINK</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="format_fraction_explanation">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="yalign">1</property>
+ <property name="label" translatable="yes">Display values as closest fractional approximation.</property>
+ <property name="wrap">True</property>
+ </object>
+ <packing>
+ <property name="right_attach">2</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options">GTK_SHRINK</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="format_scientific_explanation">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="yalign">1</property>
+ <property name="label" translatable="yes">Display values with power-of-ten scaling.</property>
+ <property name="wrap">True</property>
+ </object>
+ <packing>
+ <property name="right_attach">2</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options">GTK_SHRINK</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="format_text_explanation">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="yalign">1</property>
+ <property name="label" translatable="yes">Display and input values as strings with no interpretation.</property>
+ <property name="wrap">True</property>
+ </object>
+ <packing>
+ <property name="right_attach">2</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options">GTK_SHRINK</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="format_custom_explanation">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="yalign">1</property>
+ <property name="label" translatable="yes">Specify an XL-style format directly</property>
+ <property name="wrap">True</property>
+ </object>
+ <packing>
+ <property name="right_attach">2</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options">GTK_SHRINK</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="format_special_explanation">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="yalign">1</property>
+ <property name="wrap">True</property>
+ </object>
+ <packing>
+ <property name="right_attach">2</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options">GTK_SHRINK</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="format_percentage_explanation">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="yalign">1</property>
+ <property name="label" translatable="yes">Display values as percentages.</property>
+ <property name="wrap">True</property>
+ </object>
+ <packing>
+ <property name="right_attach">2</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options">GTK_SHRINK</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="format_general_explanation">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="yalign">1</property>
+ <property name="label" translatable="yes">Select an appropriate format automatically.</property>
+ <property name="wrap">True</property>
+ </object>
+ <packing>
+ <property name="right_attach">2</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options">GTK_SHRINK</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHSeparator" id="hseparator1">
+ <property name="visible">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHBox" id="format_decimal_box">
+ <property name="visible">True</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="format_decimal_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Deci_mal places:</property>
+ <property name="use_underline">True</property>
+ <property name="justify">center</property>
+ <property name="mnemonic_widget">format_number_decimals</property>
+ <accessibility>
+ <relation type="label-for" target="format_number_decimals"/>
+ </accessibility>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="format_number_decimals">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="adjustment">adjustment1</property>
+ <property name="climb_rate">1</property>
+ <property name="numeric">True</property>
+ <accessibility>
+ <relation type="labelled-by" target="format_decimal_label"/>
+ </accessibility>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkCheckButton" id="format_separator">
+ <property name="label" translatable="yes">_Use separator for 1000s</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="padding">6</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkCheckButton" id="format_engineering_button">
+ <property name="label" translatable="yes">_Engineering notation</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="tooltip_text" translatable="yes">Restrict exponent to multiples of 3</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">3</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="format_superscript_box">
+ <property name="visible">True</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkCheckButton" id="format_superscript_button">
+ <property name="label" translatable="yes">Use _superscript</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="tooltip_text" translatable="yes">Use superscript for exponent (e.g. 4×10²)</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkAlignment" id="alignment1">
+ <property name="visible">True</property>
+ <property name="left_padding">24</property>
+ <child>
+ <object class="GtkCheckButton" id="format_superscript_hide_1_button">
+ <property name="label" translatable="yes">_Don't show 1x's</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="tooltip_text" translatable="yes">When mantissa is equal to 1, only show exponent part (e.g. 10²)</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">4</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHBox" id="format_symbol_box">
+ <property name="visible">True</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="format_symbol_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">S_ymbol:</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="position">5</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkTable" id="table2">
+ <property name="visible">True</property>
+ <property name="n_rows">2</property>
+ <property name="row_spacing">6</property>
+ <child>
+ <object class="GtkScrolledWindow" id="format_list_scroll">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="hscrollbar_policy">automatic</property>
+ <property name="vscrollbar_policy">automatic</property>
+ <property name="shadow_type">in</property>
+ <child>
+ <object class="GtkTreeView" id="format_list">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="headers_visible">False</property>
+ <property name="enable_search">False</property>
+ <accessibility>
+ <relation type="labelled-by" target="format_list_label"/>
+ </accessibility>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkScrolledWindow" id="format_negatives_scroll">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="hscrollbar_policy">automatic</property>
+ <property name="vscrollbar_policy">automatic</property>
+ <property name="shadow_type">in</property>
+ <child>
+ <object class="GtkTreeView" id="format_negatives">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="headers_visible">False</property>
+ <accessibility>
+ <relation type="labelled-by" target="format_negatives_label"/>
+ </accessibility>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="format_list_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Format:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">format_list</property>
+ <accessibility>
+ <relation type="label-for" target="format_list"/>
+ </accessibility>
+ </object>
+ <packing>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="format_negatives_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Negative number _format:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">format_negatives</property>
+ <accessibility>
+ <relation type="label-for" target="format_negatives"/>
+ </accessibility>
+ </object>
+ <packing>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="position">6</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHBox" id="format_code_box">
+ <property name="visible">True</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="format_code_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Format c_ode:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">format_entry</property>
+ <accessibility>
+ <relation type="label-for" target="format_entry"/>
+ </accessibility>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="format_entry">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <accessibility>
+ <relation type="labelled-by" target="format_code_label"/>
+ </accessibility>
+ </object>
+ <packing>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="position">7</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ </object>
+</interface>
diff --git a/goffice/gtk/go-image-save-dialog-extra.ui b/goffice/gtk/go-image-save-dialog-extra.ui
new file mode 100644
index 0000000..cc0566c
--- /dev/null
+++ b/goffice/gtk/go-image-save-dialog-extra.ui
@@ -0,0 +1,120 @@
+<?xml version="1.0"?>
+<interface>
+ <requires lib="gtk+" version="2.16"/>
+ <!-- interface-naming-policy toplevel-contextual -->
+ <object class="GtkAdjustment" id="adjustment1">
+ <property name="value">150</property>
+ <property name="lower">30</property>
+ <property name="upper">2400</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkVBox" id="image_save_dialog_extra">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">12</property>
+ <child>
+ <object class="GtkHBox" id="file_type_box">
+ <property name="visible">True</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="label1">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes">_File type:</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkComboBox" id="format_combo">
+ <property name="visible">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkExpander" id="export_expander">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="expanded">True</property>
+ <property name="spacing">12</property>
+ <child>
+ <object class="GtkTable" id="resolution_table">
+ <property name="visible">True</property>
+ <property name="n_columns">3</property>
+ <property name="column_spacing">6</property>
+ <property name="row_spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="label2">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Resolution:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">resolution_spin</property>
+ </object>
+ <packing>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label4">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">pixels/in</property>
+ </object>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="resolution_spin">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ <property name="adjustment">adjustment1</property>
+ <property name="climb_rate">1</property>
+ <property name="snap_to_ticks">True</property>
+ <property name="numeric">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ <child type="label">
+ <object class="GtkLabel" id="label6">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes">Export settings</property>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+</interface>
diff --git a/goffice/gtk/go-image-sel.c b/goffice/gtk/go-image-sel.c
index acde892..4b782a8 100644
--- a/goffice/gtk/go-image-sel.c
+++ b/goffice/gtk/go-image-sel.c
@@ -37,7 +37,7 @@ struct _GOImageSelState {
GOImage **result;
/* GUI accessors */
- GladeXML *gui;
+ GtkBuilder *gui;
GtkEntry *name_entry;
GtkIconView *icon_view;
GtkListStore *model;
@@ -199,24 +199,24 @@ go_image_sel_new (GODoc *doc, GOCmdContext *cc, GOImage **image)
state->doc = doc;
state->cc = cc;
state->result = image;
- state->gui = go_glade_new ("go-image-sel.glade", NULL, GETTEXT_PACKAGE, state->cc);
+ state->gui = go_gtk_builder_new ("go-image-sel.ui", GETTEXT_PACKAGE, state->cc);
if (state->gui == NULL) {
g_free (state);
return NULL;
}
- w = glade_xml_get_widget (state->gui, "file-image-select");
+ w = go_gtk_builder_get_widget (state->gui, "file-image-select");
g_signal_connect (G_OBJECT (w),
"clicked",
G_CALLBACK (cb_file_image_select), state);
- w = glade_xml_get_widget (state->gui, "add");
+ w = go_gtk_builder_get_widget (state->gui, "add");
g_signal_connect (G_OBJECT (w),
"clicked",
G_CALLBACK (cb_image_add), state);
- state->name_entry = GTK_ENTRY (glade_xml_get_widget (state->gui, "name-entry"));
- state->icon_view = GTK_ICON_VIEW (glade_xml_get_widget (state->gui, "image-iconview"));
+ state->name_entry = GTK_ENTRY (gtk_builder_get_object (state->gui, "name-entry"));
+ state->icon_view = GTK_ICON_VIEW (gtk_builder_get_object (state->gui, "image-iconview"));
state->model = gtk_list_store_new (2, GDK_TYPE_PIXBUF, G_TYPE_STRING);
gtk_icon_view_set_model (state->icon_view , GTK_TREE_MODEL (state->model));
@@ -234,12 +234,12 @@ go_image_sel_new (GODoc *doc, GOCmdContext *cc, GOImage **image)
g_hash_table_foreach (hash, (GHFunc) add_image_cb, state);
/* buttons */
- w = glade_xml_get_widget (state->gui, "ok-button");
+ w = go_gtk_builder_get_widget (state->gui, "ok-button");
g_signal_connect (w, "clicked", G_CALLBACK (ok_button_clicked_cb), state);
- w = glade_xml_get_widget (state->gui, "cancel-button");
+ w = go_gtk_builder_get_widget (state->gui, "cancel-button");
g_signal_connect (w, "clicked", G_CALLBACK (cancel_button_clicked_cb), state);
- state->dialog = glade_xml_get_widget (state->gui, "go-image-sel");
+ state->dialog = go_gtk_builder_get_widget (state->gui, "go-image-sel");
g_signal_connect (state->dialog, "delete-event", G_CALLBACK (delete_event_cb), state);
return state->dialog;
}
diff --git a/goffice/gtk/go-image-sel.glade b/goffice/gtk/go-image-sel.ui
similarity index 79%
rename from goffice/gtk/go-image-sel.glade
rename to goffice/gtk/go-image-sel.ui
index f878faa..c075c26 100644
--- a/goffice/gtk/go-image-sel.glade
+++ b/goffice/gtk/go-image-sel.ui
@@ -1,29 +1,28 @@
-<?xml version="1.0" encoding="UTF-8" standalone="no"?>
-<!DOCTYPE glade-interface SYSTEM "glade-2.0.dtd">
+<?xml version="1.0"?>
<!--Generated with glade3 3.4.5 on Wed Jun 11 06:57:30 2008 -->
-<glade-interface>
- <widget class="GtkDialog" id="go-image-sel">
+<interface>
+ <object class="GtkDialog" id="go-image-sel">
<property name="border_width">5</property>
<property name="modal">True</property>
<property name="window_position">GTK_WIN_POS_CENTER_ON_PARENT</property>
<property name="type_hint">GDK_WINDOW_TYPE_HINT_DIALOG</property>
<property name="has_separator">False</property>
<child internal-child="vbox">
- <widget class="GtkVBox" id="dialog-vbox1">
+ <object class="GtkVBox" id="dialog-vbox1">
<property name="visible">True</property>
<property name="spacing">2</property>
<child>
- <widget class="GtkVBox" id="image-vbox">
+ <object class="GtkVBox" id="image-vbox">
<property name="visible">True</property>
<property name="spacing">6</property>
<child>
- <widget class="GtkScrolledWindow" id="scrolledwindow1">
+ <object class="GtkScrolledWindow" id="scrolledwindow1">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="hscrollbar_policy">GTK_POLICY_AUTOMATIC</property>
<property name="vscrollbar_policy">GTK_POLICY_AUTOMATIC</property>
<child>
- <widget class="GtkIconView" id="image-iconview">
+ <object class="GtkIconView" id="image-iconview">
<property name="width_request">200</property>
<property name="height_request">150</property>
<property name="visible">True</property>
@@ -31,40 +30,40 @@
<property name="pixbuf_column">0</property>
<property name="text_column">1</property>
<property name="reorderable">True</property>
- </widget>
+ </object>
</child>
- </widget>
+ </object>
</child>
<child>
- <widget class="GtkHSeparator" id="hseparator1">
+ <object class="GtkHSeparator" id="hseparator1">
<property name="visible">True</property>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
<property name="position">1</property>
</packing>
</child>
<child>
- <widget class="GtkVBox" id="vbox1">
+ <object class="GtkVBox" id="vbox1">
<property name="visible">True</property>
<property name="spacing">5</property>
<child>
- <widget class="GtkLabel" id="label1">
+ <object class="GtkLabel" id="label1">
<property name="visible">True</property>
<property name="xalign">0</property>
<property name="label" translatable="yes"><b>Add an image</b></property>
<property name="use_markup">True</property>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
</packing>
</child>
<child>
- <widget class="GtkAlignment" id="alignment1">
+ <object class="GtkAlignment" id="alignment1">
<property name="visible">True</property>
<property name="left_padding">15</property>
<child>
- <widget class="GtkTable" id="new-image-table">
+ <object class="GtkTable" id="new-image-table">
<property name="visible">True</property>
<property name="n_rows">2</property>
<property name="n_columns">3</property>
@@ -74,60 +73,58 @@
<placeholder/>
</child>
<child>
- <widget class="GtkButton" id="add">
+ <object class="GtkButton" id="add">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="label" translatable="yes">gtk-add</property>
<property name="use_stock">True</property>
- <property name="response_id">0</property>
- </widget>
+ </object>
<packing>
<property name="left_attach">2</property>
<property name="right_attach">3</property>
</packing>
</child>
<child>
- <widget class="GtkButton" id="file-image-select">
+ <object class="GtkButton" id="file-image-select">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="response_id">0</property>
<child>
- <widget class="GtkAlignment" id="alignment2">
+ <object class="GtkAlignment" id="alignment2">
<property name="visible">True</property>
<property name="xscale">0</property>
<property name="yscale">0</property>
<child>
- <widget class="GtkHBox" id="hbox4">
+ <object class="GtkHBox" id="hbox4">
<property name="visible">True</property>
<property name="spacing">2</property>
<child>
- <widget class="GtkImage" id="image1">
+ <object class="GtkImage" id="image1">
<property name="visible">True</property>
<property name="stock">gtk-open</property>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label32">
+ <object class="GtkLabel" id="label32">
<property name="visible">True</property>
<property name="label" translatable="yes">_Select...</property>
<property name="use_underline">True</property>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
<property name="position">1</property>
</packing>
</child>
- </widget>
+ </object>
</child>
- </widget>
+ </object>
</child>
- </widget>
+ </object>
<packing>
<property name="right_attach">2</property>
<property name="x_options">GTK_SHRINK | GTK_FILL</property>
@@ -135,10 +132,10 @@
</packing>
</child>
<child>
- <widget class="GtkEntry" id="name-entry">
+ <object class="GtkEntry" id="name-entry">
<property name="visible">True</property>
<property name="can_focus">True</property>
- </widget>
+ </object>
<packing>
<property name="left_attach">1</property>
<property name="right_attach">2</property>
@@ -148,11 +145,11 @@
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label2">
+ <object class="GtkLabel" id="label2">
<property name="visible">True</property>
<property name="xalign">0</property>
<property name="label" translatable="yes">Name:</property>
- </widget>
+ </object>
<packing>
<property name="top_attach">1</property>
<property name="bottom_attach">2</property>
@@ -160,74 +157,78 @@
<property name="y_options">GTK_FILL</property>
</packing>
</child>
- </widget>
+ </object>
</child>
- </widget>
+ </object>
<packing>
<property name="position">1</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
<property name="position">2</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="position">1</property>
</packing>
</child>
<child>
- <widget class="GtkHSeparator" id="hseparator2">
+ <object class="GtkHSeparator" id="hseparator2">
<property name="visible">True</property>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
<property name="position">2</property>
</packing>
</child>
<child internal-child="action_area">
- <widget class="GtkHButtonBox" id="dialog-action_area1">
+ <object class="GtkHButtonBox" id="dialog-action_area1">
<property name="visible">True</property>
<property name="layout_style">GTK_BUTTONBOX_END</property>
<child>
<placeholder/>
</child>
<child>
- <widget class="GtkButton" id="cancel-button">
+ <object class="GtkButton" id="cancel-button">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="label" translatable="yes">gtk-cancel</property>
<property name="use_stock">True</property>
- <property name="response_id">0</property>
- </widget>
+ </object>
<packing>
<property name="position">1</property>
</packing>
</child>
<child>
- <widget class="GtkButton" id="ok-button">
+ <object class="GtkButton" id="ok-button">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="label" translatable="yes">gtk-ok</property>
<property name="use_stock">True</property>
- <property name="response_id">0</property>
- </widget>
+ </object>
<packing>
<property name="position">2</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
<property name="pack_type">GTK_PACK_END</property>
</packing>
</child>
- </widget>
+ </object>
</child>
- </widget>
-</glade-interface>
+ <action-widgets>
+ <action-widget response="0">add</action-widget>
+ <action-widget response="0">file-image-select</action-widget>
+ <action-widget response="0">cancel-button</action-widget>
+ <action-widget response="0">ok-button</action-widget>
+ </action-widgets>
+ </object>
+</interface>
diff --git a/goffice/gtk/go-rotation-sel.c b/goffice/gtk/go-rotation-sel.c
index 5c297cf..6a812aa 100644
--- a/goffice/gtk/go-rotation-sel.c
+++ b/goffice/gtk/go-rotation-sel.c
@@ -26,7 +26,7 @@
struct _GORotationSel {
GtkHBox box;
- GladeXML *gui;
+ GtkBuilder *gui;
int angle;
GtkSpinButton *rotate_spinner;
@@ -211,7 +211,7 @@ grs_init (GORotationSel *grs)
{
GtkWidget *w;
- grs->gui = go_glade_new ("go-rotation-sel.glade", "toplevel", GETTEXT_PACKAGE, NULL);
+ grs->gui = go_gtk_builder_new ("go-rotation-sel.ui", GETTEXT_PACKAGE, NULL);
if (grs->gui == NULL)
return;
@@ -220,12 +220,12 @@ grs_init (GORotationSel *grs)
grs->text = NULL;
grs->text_widget = NULL;
grs->rotate_canvas = GOC_CANVAS (g_object_new (GOC_TYPE_CANVAS, NULL));
- gtk_container_add (GTK_CONTAINER (glade_xml_get_widget (grs->gui,
+ gtk_container_add (GTK_CONTAINER (go_gtk_builder_get_widget (grs->gui,
"rotate_canvas_container")),
GTK_WIDGET (grs->rotate_canvas));
gtk_widget_show (GTK_WIDGET (grs->rotate_canvas));
memset (grs->rotate_marks, 0, sizeof (grs->rotate_marks));
- w = glade_xml_get_widget (grs->gui, "rotate_spinner");
+ w = go_gtk_builder_get_widget (grs->gui, "rotate_spinner");
grs->rotate_spinner = GTK_SPIN_BUTTON (w);
g_signal_connect_swapped (G_OBJECT (w), "value-changed",
G_CALLBACK (cb_rotate_changed), grs);
@@ -238,7 +238,7 @@ grs_init (GORotationSel *grs)
NULL);
gtk_spin_button_set_value (grs->rotate_spinner, grs->angle);
- w = glade_xml_get_widget (grs->gui, "toplevel");
+ w = go_gtk_builder_get_widget (grs->gui, "toplevel");
gtk_box_pack_start (GTK_BOX (grs), w, TRUE, TRUE, 0);
gtk_widget_show_all (GTK_WIDGET (grs));
}
diff --git a/goffice/gtk/go-rotation-sel.ui b/goffice/gtk/go-rotation-sel.ui
new file mode 100644
index 0000000..55fe079
--- /dev/null
+++ b/goffice/gtk/go-rotation-sel.ui
@@ -0,0 +1,138 @@
+<?xml version="1.0"?>
+<interface>
+ <requires lib="gtk+" version="2.16"/>
+ <!-- interface-naming-policy toplevel-contextual -->
+ <object class="GtkAdjustment" id="adjustment1">
+ <property name="lower">-90</property>
+ <property name="upper">90</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">5</property>
+ </object>
+ <object class="GtkVBox" id="toplevel">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">12</property>
+ <child>
+ <object class="GtkLabel" id="label72">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes"><b>Orientation</b></property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHBox" id="hbox44">
+ <property name="visible">True</property>
+ <child>
+ <object class="GtkLabel" id="label73">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes"> </property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="vbox53">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkHBox" id="hbox58">
+ <property name="visible">True</property>
+ <child>
+ <object class="GtkScrolledWindow" id="rotate_canvas_container">
+ <property name="width_request">140</property>
+ <property name="height_request">210</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="hscrollbar_policy">never</property>
+ <property name="vscrollbar_policy">never</property>
+ <property name="shadow_type">in</property>
+ <child>
+ <placeholder/>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHBox" id="hbox39">
+ <property name="visible">True</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="label87">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes">A_ngle:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">rotate_spinner</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="rotate_spinner">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ <property name="adjustment">adjustment1</property>
+ <property name="climb_rate">1</property>
+ <property name="numeric">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label62">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes">degrees</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">rotate_spinner</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+</interface>
diff --git a/goffice/gtk/goffice-gtk.c b/goffice/gtk/goffice-gtk.c
index 60c5dac..bcd0d5f 100644
--- a/goffice/gtk/goffice-gtk.c
+++ b/goffice/gtk/goffice-gtk.c
@@ -99,96 +99,6 @@ go_gtk_dialog_add_button (GtkDialog *dialog, char const* text, char const* stock
}
/**
- * go_glade_new :
- * @gladefile : the name of the file load
- * @root : Name of the root object
- * @domain : The translation domain
- * @gcc : #GOCmdContext
- *
- * Simple utility to open glade files
- *
- * 0.4.3 : renamed from go_libglade_new
- *
- * Returns: a new #GladeXML or NULL
- **/
-GladeXML *
-go_glade_new (char const *gladefile, char const *root,
- char const *domain, GOCmdContext *gcc)
-{
- GladeXML *gui;
- char *f;
-
- g_return_val_if_fail (gladefile != NULL, NULL);
-
- if (!g_path_is_absolute (gladefile))
- f = g_build_filename (go_sys_data_dir (), "glade", gladefile, NULL);
- else
- f = g_strdup (gladefile);
-
- gui = glade_xml_new (f, root, domain);
- if (gui == NULL && gcc != NULL) {
- char *msg = g_strdup_printf (_("Unable to open file '%s'"), f);
- go_cmd_context_error_system (gcc, msg);
- g_free (msg);
- }
- g_free (f);
-
- return gui;
-}
-
-/**
- * go_glade_signal_connect :
- * @gui : #GladeXML
- * @instance_name : widget name
- * @detailed_signal : signal name
- * @c_handler : #GCallback
- * @data : arbitrary
- *
- * Convenience wrapper around g_signal_connect for glade.
- *
- * Returns: The signal id
- **/
-gulong
-go_glade_signal_connect (GladeXML *gui,
- gchar const *instance_name,
- gchar const *detailed_signal,
- GCallback c_handler,
- gpointer data)
-{
- GtkWidget *w;
- g_return_val_if_fail (gui != NULL, 0);
- w = glade_xml_get_widget (gui, instance_name);
- g_return_val_if_fail (w != NULL, 0);
- return g_signal_connect (w, detailed_signal, c_handler, data);
-}
-
-/**
- * go_glade_signal_connect_swapped :
- * @gui : #GladeXML
- * @instance_name : widget name
- * @detailed_signal : signal name
- * @c_handler : #GCallback
- * @data : arbitary
- *
- * Convenience wrapper around g_signal_connect_swapped for glade.
- *
- * Returns: The signal id
- **/
-gulong
-go_glade_signal_connect_swapped (GladeXML *gui,
- gchar const *instance_name,
- gchar const *detailed_signal,
- GCallback c_handler,
- gpointer data)
-{
- GtkWidget *w;
- g_return_val_if_fail (gui != NULL, 0);
- w = glade_xml_get_widget (gui, instance_name);
- g_return_val_if_fail (w != NULL, 0);
- return g_signal_connect_swapped (w, detailed_signal, c_handler, data);
-}
-
-/**
* go_gtk_builder_new :
* @uifile : the name of the file load
* @domain : the translation domain
@@ -216,7 +126,10 @@ go_gtk_builder_new (char const *uifile,
gui = gtk_builder_new ();
if (domain)
gtk_builder_set_translation_domain (gui, domain);
- gtk_builder_add_from_file (gui, f, &error);
+ if (!gtk_builder_add_from_file (gui, f, &error)) {
+ g_object_unref (gui);
+ gui = NULL;
+ }
if (gui == NULL && gcc != NULL) {
char *msg;
if (error) {
@@ -284,6 +197,70 @@ go_gtk_builder_signal_connect_swapped (GtkBuilder *gui,
return g_signal_connect_swapped (obj, detailed_signal, c_handler, data);
}
+/**
+ * go_gtk_builder_get_widget :
+ * @gui : the #GtkBuilder
+ * @widget_name : the name of the combo box in the ui file.
+ *
+ * Simple wrapper to #gtk_builder_get_object which returns the object
+ * as a GtkWidget.
+ *
+ * Returns: a new #GtkWidget or NULL
+ **/
+GtkWidget *
+go_gtk_builder_get_widget (GtkBuilder *gui, char const *widget_name)
+{
+ return GTK_WIDGET (gtk_builder_get_object (gui, widget_name));
+}
+
+/**
+ * go_gtk_builder_combo_box_init_text :
+ * @gui : the #GtkBuilder
+ * @widget_name : the name of the combo box in the ui file.
+ *
+ * searches the #GtkComboBox in @gui and ensures it has a model and a
+ * renderer appropriate for using with #gtk_combo_box_append_text and friends.
+ *
+ * Returns: the #GtkComboBox or NULL
+ **/
+GtkComboBox *
+go_gtk_builder_combo_box_init_text (GtkBuilder *gui, char const *widget_name)
+{
+ GtkComboBox *box;
+ GList *cells;
+ g_return_val_if_fail (gui != NULL, NULL);
+ box = GTK_COMBO_BOX (gtk_builder_get_object (gui, widget_name));
+ /* search for the model and create one if none exists */
+ g_return_val_if_fail (box != NULL, NULL);
+ if (gtk_combo_box_get_model (box) == NULL) {
+ GtkListStore *store = gtk_list_store_new (1, G_TYPE_STRING);
+ gtk_combo_box_set_model (box, GTK_TREE_MODEL (store));
+ g_object_unref (store);
+ }
+ cells = gtk_cell_layout_get_cells (GTK_CELL_LAYOUT (box));
+ if (g_list_length (cells) == 0) {
+ /* populate the cell layout */
+ GtkCellRenderer *cell = gtk_cell_renderer_text_new ();
+ gtk_cell_layout_pack_start (GTK_CELL_LAYOUT (box), cell, TRUE);
+ gtk_cell_layout_set_attributes (GTK_CELL_LAYOUT (box), cell,
+ "text", 0, NULL);
+ }
+ g_list_free (cells);
+ return box;
+}
+
+int
+go_gtk_builder_group_value (GtkBuilder *gui, char const * const group[])
+{
+ int i;
+ for (i = 0; group[i]; i++) {
+ GtkWidget *w = go_gtk_builder_get_widget (gui, group[i]);
+ if (gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (w)))
+ return i;
+ }
+ return -1;
+}
+
/*
* A variant of gtk_window_activate_default that does not end up reactivating
* the widget that [Enter] was pressed in.
@@ -718,7 +695,7 @@ go_gui_get_image_save_info (GtkWindow *toplevel, GSList *supported_formats,
GtkWidget *expander = NULL;
GtkWidget *resolution_spin = NULL;
GtkWidget *resolution_table;
- GladeXML *gui;
+ GtkBuilder *gui;
SaveInfoState *state;
char const *key = "go_gui_get_image_save_info";
char *uri = NULL;
@@ -737,8 +714,7 @@ go_gui_get_image_save_info (GtkWindow *toplevel, GSList *supported_formats,
g_object_set (G_OBJECT (fsel), "title", _("Save as"), NULL);
- gui = go_glade_new ("go-image-save-dialog-extra.glade",
- "image_save_dialog_extra",
+ gui = go_gtk_builder_new ("go-image-save-dialog-extra.ui",
GETTEXT_PACKAGE, NULL);
if (gui != NULL) {
GtkWidget *widget;
@@ -747,7 +723,7 @@ go_gui_get_image_save_info (GtkWindow *toplevel, GSList *supported_formats,
if (supported_formats != NULL && ret_format != NULL) {
int i;
GSList *l;
- format_combo = GTK_COMBO_BOX (glade_xml_get_widget (gui, "format_combo"));
+ format_combo = GTK_COMBO_BOX (gtk_builder_get_object (gui, "format_combo"));
for (l = supported_formats, i = 0; l != NULL; l = l->next, i++) {
format = GPOINTER_TO_UINT (l->data);
format_info = go_image_get_format_info (format);
@@ -758,26 +734,26 @@ go_gui_get_image_save_info (GtkWindow *toplevel, GSList *supported_formats,
if (gtk_combo_box_get_active (format_combo) < 0)
gtk_combo_box_set_active (format_combo, 0);
} else {
- widget = glade_xml_get_widget (gui, "file_type_box");
+ widget = go_gtk_builder_get_widget (gui, "file_type_box");
gtk_widget_hide (widget);
}
if (supported_formats != NULL && ret_format != NULL) {
- widget = glade_xml_get_widget (gui, "image_save_dialog_extra");
+ widget = go_gtk_builder_get_widget (gui, "image_save_dialog_extra");
gtk_file_chooser_set_extra_widget (fsel, widget);
}
/* Export setting expander */
- expander = glade_xml_get_widget (gui, "export_expander");
+ expander = go_gtk_builder_get_widget (gui, "export_expander");
if (resolution != NULL) {
gtk_expander_set_expanded (GTK_EXPANDER (expander), state->is_expanded);
- resolution_spin = glade_xml_get_widget (gui, "resolution_spin");
+ resolution_spin = go_gtk_builder_get_widget (gui, "resolution_spin");
gtk_spin_button_set_value (GTK_SPIN_BUTTON (resolution_spin), state->resolution);
} else
gtk_widget_hide (expander);
if (resolution != NULL && supported_formats != NULL && ret_format != NULL) {
- resolution_table = glade_xml_get_widget (gui, "resolution_table");
+ resolution_table = go_gtk_builder_get_widget (gui, "resolution_table");
cb_format_combo_changed (format_combo, resolution_table);
g_signal_connect (GTK_WIDGET (format_combo), "changed",
diff --git a/goffice/gtk/goffice-gtk.h b/goffice/gtk/goffice-gtk.h
index 2c4ae9d..ba2dbd2 100644
--- a/goffice/gtk/goffice-gtk.h
+++ b/goffice/gtk/goffice-gtk.h
@@ -20,7 +20,6 @@
#define _GOFFICE_GTK_H_
#include <gtk/gtk.h>
-#include <glade/glade-xml.h>
#include <goffice/goffice.h>
#include <goffice/gtk/go-palette.h>
@@ -58,33 +57,23 @@ G_BEGIN_DECLS
void go_gtk_editable_enters (GtkWindow *window, GtkWidget *w);
-GladeXML *go_glade_new (char const *gladefile,
- char const *root,
- char const *domain,
- GOCmdContext *gcc);
-gulong go_glade_signal_connect (GladeXML *gui,
+GtkBuilder *go_gtk_builder_new (char const *uifile,
+ char const *domain, GOCmdContext *gcc);
+gulong go_gtk_builder_signal_connect (GtkBuilder *gui,
gchar const *instance_name,
gchar const *detailed_signal,
GCallback c_handler,
gpointer data);
-gulong go_glade_signal_connect_swapped (GladeXML *gui,
+gulong go_gtk_builder_signal_connect_swapped (GtkBuilder *gui,
gchar const *instance_name,
gchar const *detailed_signal,
GCallback c_handler,
gpointer data);
-
-GtkBuilder *go_gtk_builder_new (char const *uifile,
- char const *domain, GOCmdContext *gcc);
-gulong go_gtk_builder_signal_connect (GtkBuilder *gui,
- gchar const *instance_name,
- gchar const *detailed_signal,
- GCallback c_handler,
- gpointer data);
-gulong go_gtk_builder_signal_connect_swapped (GtkBuilder *gui,
- gchar const *instance_name,
- gchar const *detailed_signal,
- GCallback c_handler,
- gpointer data);
+GtkWidget *go_gtk_builder_get_widget (GtkBuilder *gui,
+ char const *widget_name);
+GtkComboBox *go_gtk_builder_combo_box_init_text (GtkBuilder *gui,
+ char const *widget_name);
+int go_gtk_builder_group_value (GtkBuilder *gui, char const * const group[]);
int go_pango_measure_string (PangoContext *context,
PangoFontDescription const *font_desc,
diff --git a/goffice/utils/Makefile.am b/goffice/utils/Makefile.am
index 96bc198..864b14c 100644
--- a/goffice/utils/Makefile.am
+++ b/goffice/utils/Makefile.am
@@ -64,9 +64,9 @@ libgoffice_utils_la_HEADERS = \
go-style.h \
go-styled-object.h
-gladedir = $(goffice_datadir)/glade
-dist_glade_DATA = \
- go-style-prefs.glade
+uidir = $(goffice_datadir)/ui
+dist_ui_DATA = \
+ go-style-prefs.ui
CLEANFILES = \
go-marshalers.h \
diff --git a/goffice/utils/go-editor.c b/goffice/utils/go-editor.c
index 3733136..fbbdc68 100644
--- a/goffice/utils/go-editor.c
+++ b/goffice/utils/go-editor.c
@@ -43,6 +43,13 @@ go_editor_new (void)
return editor;
}
+static void page_free (GOEditorPage *page)
+{
+ if (page->widget)
+ g_object_unref (page->widget);
+ g_free (page);
+}
+
/**
* go_editor_free:
* @editor: a #GOEditor
@@ -53,7 +60,7 @@ go_editor_new (void)
void
go_editor_free (GOEditor *editor)
{
- g_slist_foreach (editor->pages, (GFunc) g_free, NULL);
+ g_slist_foreach (editor->pages, (GFunc) page_free, NULL);
g_slist_free (editor->pages);
g_datalist_clear (&editor->registered_widgets);
@@ -77,7 +84,7 @@ go_editor_add_page (GOEditor *editor, gpointer widget, char const *label)
g_return_if_fail (editor != NULL);
page = g_new (GOEditorPage, 1);
- page->widget = widget;
+ page->widget = g_object_ref (widget);
page->label = label;
editor->pages = g_slist_prepend (editor->pages, page);
diff --git a/goffice/utils/go-style-prefs.ui b/goffice/utils/go-style-prefs.ui
new file mode 100644
index 0000000..16d603e
--- /dev/null
+++ b/goffice/utils/go-style-prefs.ui
@@ -0,0 +1,952 @@
+<?xml version="1.0"?>
+<interface>
+ <requires lib="gtk+" version="2.16"/>
+ <!-- interface-naming-policy toplevel-contextual -->
+ <object class="GtkAdjustment" id="adjustment1">
+ <property name="upper">30</property>
+ <property name="step_increment">0.10000000000000001</property>
+ <property name="page_increment">1</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment2">
+ <property name="upper">30</property>
+ <property name="step_increment">0.10000000000000001</property>
+ <property name="page_increment">1</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment3">
+ <property name="upper">100</property>
+ <property name="step_increment">10</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment4">
+ <property name="value">5</property>
+ <property name="lower">1</property>
+ <property name="upper">200</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkListStore" id="model1">
+ <columns>
+ <!-- column-name gchararray -->
+ <column type="gchararray"/>
+ </columns>
+ <data>
+ <row>
+ <col id="0" translatable="yes">None</col>
+ </row>
+ <row>
+ <col id="0" translatable="yes">Pattern</col>
+ </row>
+ <row>
+ <col id="0" translatable="yes">Bicolor gradient</col>
+ </row>
+ <row>
+ <col id="0" translatable="yes">Unicolor gradient</col>
+ </row>
+ <row>
+ <col id="0" translatable="yes">Image</col>
+ </row>
+ </data>
+ </object>
+ <object class="GtkListStore" id="model2">
+ <columns>
+ <!-- column-name gchararray -->
+ <column type="gchararray"/>
+ </columns>
+ <data>
+ <row>
+ <col id="0" translatable="yes">stretched</col>
+ </row>
+ <row>
+ <col id="0" translatable="yes">wallpaper</col>
+ </row>
+ </data>
+ </object>
+ <object class="GtkHBox" id="go_style_prefs">
+ <property name="visible">True</property>
+ <property name="border_width">12</property>
+ <property name="spacing">24</property>
+ <child>
+ <object class="GtkVBox" id="outline_box">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <child>
+ <object class="GtkLabel" id="outline_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes"><b>Outline</b></property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkAlignment" id="alignment5">
+ <property name="visible">True</property>
+ <property name="top_padding">6</property>
+ <property name="left_padding">18</property>
+ <child>
+ <object class="GtkTable" id="outline_table">
+ <property name="visible">True</property>
+ <property name="n_rows">3</property>
+ <property name="n_columns">3</property>
+ <property name="column_spacing">12</property>
+ <property name="row_spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="label37">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">St_yle:</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="outline_color_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Co_lor:</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label35">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">pts</property>
+ </object>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="outline_size_spin">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ <property name="adjustment">adjustment1</property>
+ <property name="climb_rate">1</property>
+ <property name="digits">1</property>
+ <property name="numeric">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="outline_size_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Size:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">outline_size_spin</property>
+ </object>
+ <packing>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="line_box">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <child>
+ <object class="GtkLabel" id="line_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes"><b>Line</b></property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkAlignment" id="alignment6">
+ <property name="visible">True</property>
+ <property name="top_padding">6</property>
+ <property name="bottom_padding">10</property>
+ <property name="left_padding">18</property>
+ <child>
+ <object class="GtkTable" id="line_table">
+ <property name="visible">True</property>
+ <property name="n_rows">3</property>
+ <property name="n_columns">3</property>
+ <property name="column_spacing">12</property>
+ <property name="row_spacing">6</property>
+ <child>
+ <object class="GtkSpinButton" id="line_size_spin">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ <property name="adjustment">adjustment2</property>
+ <property name="climb_rate">1</property>
+ <property name="digits">1</property>
+ <property name="numeric">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label36">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">St_yle:</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label34">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">pts</property>
+ </object>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="line_size_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Size:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">line_size_spin</property>
+ </object>
+ <packing>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="line_color_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Co_lor:</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="fill_box">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <child>
+ <object class="GtkLabel" id="fill_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes"><b>Fill</b></property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkAlignment" id="alignment4">
+ <property name="visible">True</property>
+ <property name="top_padding">6</property>
+ <property name="left_padding">18</property>
+ <child>
+ <object class="GtkVBox" id="vbox1">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkHBox" id="hbox2">
+ <property name="visible">True</property>
+ <property name="spacing">12</property>
+ <child>
+ <object class="GtkLabel" id="fill_type_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Type:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">fill_type_menu</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkComboBox" id="fill_type_menu">
+ <property name="visible">True</property>
+ <property name="model">model1</property>
+ <child>
+ <object class="GtkCellRendererText" id="renderer1"/>
+ <attributes>
+ <attribute name="text">0</attribute>
+ </attributes>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHBox" id="fill_extension_box">
+ <property name="visible">True</property>
+ <child>
+ <placeholder/>
+ </child>
+ </object>
+ <packing>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkNotebook" id="fill_notebook">
+ <property name="visible">True</property>
+ <property name="show_tabs">False</property>
+ <property name="show_border">False</property>
+ <child>
+ <object class="GtkLabel" id="label31">
+ <property name="visible">True</property>
+ </object>
+ </child>
+ <child type="tab">
+ <object class="GtkLabel" id="label16">
+ <property name="visible">True</property>
+ </object>
+ <packing>
+ <property name="tab_fill">False</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="vbox3">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkHBox" id="fill_gradient_box">
+ <property name="visible">True</property>
+ <property name="spacing">12</property>
+ <child>
+ <object class="GtkLabel" id="fill_gradient_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Direction:</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHBox" id="fill_pattern_box">
+ <property name="visible">True</property>
+ <property name="spacing">12</property>
+ <child>
+ <object class="GtkLabel" id="fill_pattern_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Pattern:</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHBox" id="fill_foreground_box">
+ <property name="visible">True</property>
+ <property name="spacing">12</property>
+ <child>
+ <object class="GtkLabel" id="fill_foreground_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Foreground:</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHBox" id="fill_background_box">
+ <property name="visible">True</property>
+ <property name="spacing">12</property>
+ <child>
+ <object class="GtkLabel" id="fill_background_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Background:</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">3</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHBox" id="fill_brightness_box">
+ <property name="visible">True</property>
+ <property name="spacing">12</property>
+ <child>
+ <object class="GtkLabel" id="fill_brightness_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">B_rightness:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">fill_brightness_scale</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHScale" id="fill_brightness_scale">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="adjustment">adjustment3</property>
+ <property name="inverted">True</property>
+ <property name="draw_value">False</property>
+ </object>
+ <packing>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">4</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child type="tab">
+ <object class="GtkLabel" id="label18">
+ <property name="visible">True</property>
+ </object>
+ <packing>
+ <property name="position">1</property>
+ <property name="tab_fill">False</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkTable" id="fill_image_table">
+ <property name="visible">True</property>
+ <property name="n_rows">3</property>
+ <property name="n_columns">3</property>
+ <property name="column_spacing">12</property>
+ <property name="row_spacing">6</property>
+ <child>
+ <object class="GtkVBox" id="vbox2">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <child>
+ <object class="GtkImage" id="fill_image_sample">
+ <property name="width_request">100</property>
+ <property name="height_request">60</property>
+ <property name="visible">True</property>
+ <property name="stock">gtk-missing-image</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="image-size-label">
+ <property name="visible">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
+ <property name="bottom_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options">GTK_FILL</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label33">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ </object>
+ <packing>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButton" id="fill_image_select_picture">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
+ <child>
+ <object class="GtkAlignment" id="alignment2">
+ <property name="visible">True</property>
+ <property name="xscale">0</property>
+ <property name="yscale">0</property>
+ <child>
+ <object class="GtkHBox" id="hbox4">
+ <property name="visible">True</property>
+ <property name="spacing">2</property>
+ <child>
+ <object class="GtkImage" id="image1">
+ <property name="visible">True</property>
+ <property name="stock">gtk-open</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label32">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes">_Select...</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="right_attach">2</property>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_SHRINK | GTK_FILL</property>
+ <property name="y_options">GTK_SHRINK</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkComboBox" id="fill_image_fit">
+ <property name="visible">True</property>
+ <property name="model">model2</property>
+ <child>
+ <object class="GtkCellRendererText" id="renderer2"/>
+ <attributes>
+ <attribute name="text">0</attribute>
+ </attributes>
+ </child>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="x_options">GTK_SHRINK | GTK_FILL</property>
+ <property name="y_options">GTK_SHRINK</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="fill_image_fit_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Fit:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">fill_image_fit</property>
+ </object>
+ <packing>
+ <property name="x_options">GTK_SHRINK | GTK_FILL</property>
+ <property name="y_options">GTK_SHRINK</property>
+ </packing>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ </object>
+ <packing>
+ <property name="position">2</property>
+ <property name="tab_fill">False</property>
+ </packing>
+ </child>
+ <child type="tab">
+ <object class="GtkLabel" id="label19">
+ <property name="visible">True</property>
+ </object>
+ <packing>
+ <property name="position">2</property>
+ <property name="tab_fill">False</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ </object>
+ <object class="GtkVBox" id="go_style_font_prefs">
+ <property name="visible">True</property>
+ <property name="border_width">12</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">12</property>
+ <child>
+ <object class="GtkHBox" id="hbox5">
+ <property name="visible">True</property>
+ <child>
+ <object class="GtkHBox" id="color_box">
+ <property name="visible">True</property>
+ <property name="spacing">12</property>
+ <child>
+ <object class="GtkLabel" id="font_color_label">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes">Co_lor:</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ </object>
+ <object class="GtkAlignment" id="go_style_marker_prefs">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="yalign">0</property>
+ <property name="xscale">0</property>
+ <property name="yscale">0</property>
+ <property name="top_padding">12</property>
+ <property name="bottom_padding">12</property>
+ <property name="left_padding">12</property>
+ <property name="right_padding">12</property>
+ <child>
+ <object class="GtkVBox" id="marker_box">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <child>
+ <object class="GtkLabel" id="marker_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes"><b>Marker</b></property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkAlignment" id="alignment7">
+ <property name="visible">True</property>
+ <property name="top_padding">6</property>
+ <property name="left_padding">18</property>
+ <child>
+ <object class="GtkTable" id="marker_table">
+ <property name="visible">True</property>
+ <property name="n_rows">4</property>
+ <property name="n_columns">3</property>
+ <property name="column_spacing">12</property>
+ <property name="row_spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="marker_fill_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Fill:</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="marker_outline_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">O_utline:</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label7">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">pts</property>
+ </object>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
+ <property name="top_attach">3</property>
+ <property name="bottom_attach">4</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="marker_size_spin">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ <property name="adjustment">adjustment4</property>
+ <property name="climb_rate">1</property>
+ <property name="numeric">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="top_attach">3</property>
+ <property name="bottom_attach">4</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="marker_size_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Si_ze:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">marker_size_spin</property>
+ </object>
+ <packing>
+ <property name="top_attach">3</property>
+ <property name="bottom_attach">4</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="marker_shape_label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Sha_pe:</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ </object>
+</interface>
diff --git a/goffice/utils/go-style.c b/goffice/utils/go-style.c
index ab785fe..1818595 100644
--- a/goffice/utils/go-style.c
+++ b/goffice/utils/go-style.c
@@ -22,10 +22,8 @@
#include <goffice/goffice-config.h>
#include <goffice/goffice.h>
-#include <goffice/app/go-doc.h>
#ifdef GOFFICE_WITH_GTK
-#include <glade/glade-xml.h>
#include <gdk-pixbuf/gdk-pixdata.h>
#endif
@@ -53,8 +51,8 @@ static GObjectClass *parent_klass;
#ifdef GOFFICE_WITH_GTK
typedef struct {
- GladeXML *gui;
- GladeXML *font_gui;
+ GtkBuilder *gui;
+ GtkBuilder *font_gui;
GOStyle *style;
GOStyle *default_style;
GObject *object_with_style;
@@ -110,7 +108,7 @@ set_style (StylePrefState const *state)
static GtkWidget *
create_go_combo_color (StylePrefState *state,
GOColor initial_color, GOColor automatic_color,
- GladeXML *gui,
+ GtkBuilder *gui,
char const *group, char const *label_name,
GCallback func)
{
@@ -118,7 +116,7 @@ create_go_combo_color (StylePrefState *state,
w = go_color_selector_new (initial_color, automatic_color, group);
gtk_label_set_mnemonic_widget (
- GTK_LABEL (glade_xml_get_widget (gui, label_name)), w);
+ GTK_LABEL (gtk_builder_get_object (gui, label_name)), w);
g_signal_connect (G_OBJECT (w), "activate", G_CALLBACK (func), state);
return w;
}
@@ -142,13 +140,13 @@ go_style_set_image_preview (GOImage *pix, StylePrefState *state)
if (pix == NULL)
return;
- w = glade_xml_get_widget (state->gui, "fill_image_sample");
+ w = go_gtk_builder_get_widget (state->gui, "fill_image_sample");
scaled = go_pixbuf_intelligent_scale (go_image_get_pixbuf (pix), HSCALE, VSCALE);
gtk_image_set_from_pixbuf (GTK_IMAGE (w), scaled);
g_object_unref (scaled);
- w = glade_xml_get_widget (state->gui, "image-size-label");
+ w = go_gtk_builder_get_widget (state->gui, "image-size-label");
g_object_get (pix, "width", &width, "height", &height, NULL);
size = g_strdup_printf (_("%d x %d"), width, height);
@@ -198,7 +196,7 @@ outline_init (StylePrefState *state, gboolean enable, GOEditor *editor)
GOStyle *default_style = state->default_style;
GtkWidget *w, *table;
- w = glade_xml_get_widget (state->gui, "outline_box");
+ w = go_gtk_builder_get_widget (state->gui, "outline_box");
if (!enable) {
gtk_widget_hide (w);
return;
@@ -206,7 +204,7 @@ outline_init (StylePrefState *state, gboolean enable, GOEditor *editor)
go_editor_register_widget (editor, w);
- table = glade_xml_get_widget (state->gui, "outline_table");
+ table = go_gtk_builder_get_widget (state->gui, "outline_table");
/* DashType */
w = go_line_dash_selector_new (style->outline.dash_type,
@@ -215,7 +213,7 @@ outline_init (StylePrefState *state, gboolean enable, GOEditor *editor)
g_signal_connect (G_OBJECT (w), "activate",
G_CALLBACK (cb_outline_dash_type_changed), state);
/* Size */
- w = glade_xml_get_widget (state->gui, "outline_size_spin");
+ w = go_gtk_builder_get_widget (state->gui, "outline_size_spin");
gtk_spin_button_set_value (GTK_SPIN_BUTTON (w), style->outline.width);
g_signal_connect (gtk_spin_button_get_adjustment (GTK_SPIN_BUTTON (w)),
"value_changed",
@@ -272,7 +270,7 @@ line_init (StylePrefState *state, gboolean enable, GOEditor *editor)
GOStyle *default_style = state->default_style;
GtkWidget *w, *table;
- w = glade_xml_get_widget (state->gui, "line_box");
+ w = go_gtk_builder_get_widget (state->gui, "line_box");
if (!enable) {
gtk_widget_hide (w);
return;
@@ -280,7 +278,7 @@ line_init (StylePrefState *state, gboolean enable, GOEditor *editor)
go_editor_register_widget (editor, w);
- table = glade_xml_get_widget (state->gui, "line_table");
+ table = go_gtk_builder_get_widget (state->gui, "line_table");
/* DashType */
w = go_line_dash_selector_new (style->line.dash_type,
@@ -290,7 +288,7 @@ line_init (StylePrefState *state, gboolean enable, GOEditor *editor)
G_CALLBACK (cb_line_dash_type_changed), state);
/* Size */
- w = glade_xml_get_widget (state->gui, "line_size_spin");
+ w = go_gtk_builder_get_widget (state->gui, "line_size_spin");
gtk_spin_button_set_value (GTK_SPIN_BUTTON (w), style->line.width);
g_signal_connect (gtk_spin_button_get_adjustment (GTK_SPIN_BUTTON (w)),
"value_changed",
@@ -363,10 +361,10 @@ fill_pattern_init (StylePrefState *state)
go_pattern_selector_set_colors (GO_SELECTOR (selector), style->fill.pattern.fore,
style->fill.pattern.back);
- label = glade_xml_get_widget (state->gui, "fill_pattern_label");
+ label = go_gtk_builder_get_widget (state->gui, "fill_pattern_label");
gtk_size_group_add_widget (state->fill.size_group, label);
gtk_label_set_mnemonic_widget (GTK_LABEL (label), selector);
- state->fill.pattern.box = glade_xml_get_widget (state->gui, "fill_pattern_box");
+ state->fill.pattern.box = go_gtk_builder_get_widget (state->gui, "fill_pattern_box");
gtk_box_pack_start (GTK_BOX (state->fill.pattern.box), selector, FALSE, FALSE, 0);
g_signal_connect (G_OBJECT (selector), "activate",
@@ -408,22 +406,22 @@ fill_gradient_init (StylePrefState *state)
go_gradient_selector_set_colors (GO_SELECTOR (selector),
style->fill.pattern.back,
style->fill.pattern.fore);
- label = glade_xml_get_widget (state->gui, "fill_gradient_label");
+ label = go_gtk_builder_get_widget (state->gui, "fill_gradient_label");
gtk_size_group_add_widget (state->fill.size_group, label);
gtk_label_set_mnemonic_widget (GTK_LABEL (label), selector);
- state->fill.gradient.box = glade_xml_get_widget (state->gui, "fill_gradient_box");
+ state->fill.gradient.box = go_gtk_builder_get_widget (state->gui, "fill_gradient_box");
gtk_box_pack_start (GTK_BOX (state->fill.gradient.box), selector, FALSE, FALSE, 0);
state->fill.gradient.brightness = brightness =
- glade_xml_get_widget (state->gui, "fill_brightness_scale");
- label = glade_xml_get_widget (state->gui, "fill_brightness_label");
+ go_gtk_builder_get_widget (state->gui, "fill_brightness_scale");
+ label = go_gtk_builder_get_widget (state->gui, "fill_brightness_label");
gtk_size_group_add_widget (state->fill.size_group, label);
gtk_label_set_mnemonic_widget (GTK_LABEL (label), brightness);
- state->fill.gradient.brightness_box = glade_xml_get_widget (state->gui, "fill_brightness_box");
+ state->fill.gradient.brightness_box = go_gtk_builder_get_widget (state->gui, "fill_brightness_box");
g_signal_connect (selector, "activate",
G_CALLBACK (cb_gradient_type_changed), state);
- g_signal_connect (brightness, "value_changed",
+ g_signal_connect (brightness, "value_changed",
G_CALLBACK (cb_brightness_changed), state);
gtk_widget_show (selector);
gtk_widget_show (brightness);
@@ -466,7 +464,7 @@ fill_color_init (StylePrefState *state)
default_style->fill.pattern.back,
state->gui, "pattern_background", "fill_background_label",
G_CALLBACK (cb_fill_background_color));
- state->fill.background_box = glade_xml_get_widget (state->gui, "fill_background_box");
+ state->fill.background_box = go_gtk_builder_get_widget (state->gui, "fill_background_box");
gtk_box_pack_start (GTK_BOX (state->fill.background_box), w, FALSE, FALSE, 0);
gtk_widget_show (w);
@@ -475,13 +473,13 @@ fill_color_init (StylePrefState *state)
default_style->fill.pattern.fore,
state->gui, "pattern_foreground", "fill_foreground_label",
G_CALLBACK (cb_fill_foreground_color));
- state->fill.foreground_box = glade_xml_get_widget (state->gui, "fill_foreground_box");
+ state->fill.foreground_box = go_gtk_builder_get_widget (state->gui, "fill_foreground_box");
gtk_box_pack_start (GTK_BOX (state->fill.foreground_box), w, FALSE, FALSE, 0);
gtk_widget_show (w);
- state->fill.foreground_label = glade_xml_get_widget (state->gui, "fill_foreground_label");
+ state->fill.foreground_label = go_gtk_builder_get_widget (state->gui, "fill_foreground_label");
gtk_size_group_add_widget (state->fill.size_group, state->fill.foreground_label);
- state->fill.background_label = glade_xml_get_widget (state->gui, "fill_background_label");
+ state->fill.background_label = go_gtk_builder_get_widget (state->gui, "fill_background_label");
gtk_size_group_add_widget (state->fill.size_group, state->fill.background_label);
}
/************************************************************************/
@@ -519,14 +517,14 @@ fill_image_init (StylePrefState *state)
GtkWidget *w, *sample, *type;
GOStyle *style = state->style;
- w = glade_xml_get_widget (state->gui, "fill_image_select_picture");
+ w = go_gtk_builder_get_widget (state->gui, "fill_image_select_picture");
g_signal_connect (G_OBJECT (w),
"clicked",
G_CALLBACK (cb_image_select), state);
- sample = glade_xml_get_widget (state->gui, "fill_image_sample");
+ sample = go_gtk_builder_get_widget (state->gui, "fill_image_sample");
gtk_widget_set_size_request (sample, HSCALE + 10, VSCALE + 10);
- type = glade_xml_get_widget (state->gui, "fill_image_fit");
+ type = go_gtk_builder_get_widget (state->gui, "fill_image_fit");
state->fill.image.image = NULL;
@@ -611,11 +609,11 @@ fill_init (StylePrefState *state, gboolean enable, GOEditor *editor)
FillType type;
if (!enable) {
- gtk_widget_hide (glade_xml_get_widget (state->gui, "fill_box"));
+ gtk_widget_hide (go_gtk_builder_get_widget (state->gui, "fill_box"));
return;
}
- state->fill.extension_box = glade_xml_get_widget (state->gui, "fill_extension_box");
+ state->fill.extension_box = go_gtk_builder_get_widget (state->gui, "fill_extension_box");
go_editor_register_widget (editor, state->fill.extension_box);
state->fill.size_group = gtk_size_group_new (GTK_SIZE_GROUP_HORIZONTAL);
@@ -627,7 +625,7 @@ fill_init (StylePrefState *state, gboolean enable, GOEditor *editor)
fill_image_init (state);
fill_update_selectors (state);
- state->fill.notebook = glade_xml_get_widget (state->gui, "fill_notebook");
+ state->fill.notebook = go_gtk_builder_get_widget (state->gui, "fill_notebook");
switch (state->style->fill.type) {
case GO_STYLE_FILL_PATTERN:
@@ -652,7 +650,7 @@ fill_init (StylePrefState *state, gboolean enable, GOEditor *editor)
}
fill_update_visibilies (type, state);
- w = glade_xml_get_widget (state->gui, "fill_type_menu");
+ w = go_gtk_builder_get_widget (state->gui, "fill_type_menu");
if (state->doc == NULL)
gtk_combo_box_remove_text (GTK_COMBO_BOX (w), FILL_TYPE_IMAGE);
gtk_combo_box_set_active (GTK_COMBO_BOX (w), type);
@@ -660,7 +658,7 @@ fill_init (StylePrefState *state, gboolean enable, GOEditor *editor)
"changed",
G_CALLBACK (cb_fill_type_changed), state);
- w = glade_xml_get_widget (state->gui, "fill_box");
+ w = go_gtk_builder_get_widget (state->gui, "fill_box");
gtk_widget_show (GTK_WIDGET (w));
}
@@ -731,16 +729,16 @@ marker_init (StylePrefState *state, gboolean enable, GOEditor *editor, GOCmdCont
GOStyle *default_style = state->default_style;
GtkWidget *table, *w;
GtkWidget *selector;
- GladeXML *gui;
+ GtkBuilder *gui;
if (!enable)
return;
- gui = go_glade_new ("go-style-prefs.glade", "go_style_marker_prefs", GETTEXT_PACKAGE, cc);
+ gui = go_gtk_builder_new ("go-style-prefs.ui", GETTEXT_PACKAGE, cc);
if (gui == NULL)
return;
- table = glade_xml_get_widget (gui, "marker_table");
+ table = go_gtk_builder_get_widget (gui, "marker_table");
state->marker.selector = selector =
go_marker_selector_new (go_marker_get_shape (style->marker.mark),
@@ -752,7 +750,7 @@ marker_init (StylePrefState *state, gboolean enable, GOEditor *editor, GOCmdCont
else
go_marker_selector_set_colors (GO_SELECTOR (selector),
RGBA_BLUE, RGBA_BLUE);
- w = glade_xml_get_widget (gui, "marker_shape_label");
+ w = go_gtk_builder_get_widget (gui, "marker_shape_label");
gtk_label_set_mnemonic_widget (GTK_LABEL (w), selector);
gtk_table_attach (GTK_TABLE (table), selector, 1, 2, 0, 1, GTK_FILL, GTK_FILL, 0, 0);
g_signal_connect (G_OBJECT (selector), "activate",
@@ -789,7 +787,7 @@ marker_init (StylePrefState *state, gboolean enable, GOEditor *editor, GOCmdCont
}
gtk_table_attach (GTK_TABLE (table), w, 1, 2, 2, 3, GTK_FILL, GTK_FILL, 0, 0);
- w = glade_xml_get_widget (gui, "marker_size_spin");
+ w = go_gtk_builder_get_widget (gui, "marker_size_spin");
gtk_spin_button_set_value (GTK_SPIN_BUTTON (w),
go_marker_get_size (style->marker.mark));
g_signal_connect (G_OBJECT (gtk_spin_button_get_adjustment (GTK_SPIN_BUTTON (w))),
@@ -798,13 +796,14 @@ marker_init (StylePrefState *state, gboolean enable, GOEditor *editor, GOCmdCont
gtk_widget_show_all (table);
- w = glade_xml_get_widget (gui, "go_style_marker_prefs");
+ w = GTK_WIDGET (g_object_ref (gtk_builder_get_object (gui, "go_style_marker_prefs")));
go_editor_add_page (editor, w, _("Markers"));
g_object_unref (gui);
- if (state->gui == NULL)
- g_object_set_data_full (G_OBJECT (w),
- "state", state, (GDestroyNotify) go_style_pref_state_free);
+ if (state->gui == NULL) {
+ g_object_set_data (G_OBJECT (w), "state", state);
+ g_signal_connect_swapped (G_OBJECT (w), "destroy", G_CALLBACK (go_style_pref_state_free), state);
+ }
}
/************************************************************************/
@@ -842,14 +841,14 @@ font_init (StylePrefState *state, guint32 enable, GOEditor *editor, GOCmdContext
{
GOStyle *style = state->style;
GtkWidget *w, *box;
- GladeXML *gui;
+ GtkBuilder *gui;
if (!enable)
return;
g_return_if_fail (style->font.font != NULL);
- gui = go_glade_new ("go-style-prefs.glade", "go_style_font_prefs", GETTEXT_PACKAGE, cc);
+ gui = go_gtk_builder_new ("go-style-prefs.ui", GETTEXT_PACKAGE, cc);
if (gui == NULL)
return;
@@ -858,7 +857,7 @@ font_init (StylePrefState *state, guint32 enable, GOEditor *editor, GOCmdContext
w = create_go_combo_color (state, style->font.color, style->font.color,
gui, "pattern_foreground", "font_color_label",
G_CALLBACK (cb_font_color_changed));
- box = glade_xml_get_widget (gui, "color_box");
+ box = go_gtk_builder_get_widget (gui, "color_box");
gtk_box_pack_start (GTK_BOX (box), w, TRUE, TRUE, 0);
gtk_widget_show (w);
@@ -868,7 +867,7 @@ font_init (StylePrefState *state, guint32 enable, GOEditor *editor, GOCmdContext
G_CALLBACK (cb_font_changed), state);
gtk_widget_show (w);
- box = glade_xml_get_widget (gui, "go_style_font_prefs");
+ box = go_gtk_builder_get_widget (gui, "go_style_font_prefs");
gtk_box_pack_end (GTK_BOX (box), w, TRUE, TRUE, 0);
go_editor_add_page (editor, box, _("Font"));
@@ -944,7 +943,7 @@ go_style_populate_editor (GOStyle *style,
{
GOStyleFlag enable;
GtkWidget *w;
- GladeXML *gui;
+ GtkBuilder *gui;
StylePrefState *state;
g_return_if_fail (style != NULL);
@@ -967,15 +966,15 @@ go_style_populate_editor (GOStyle *style,
go_styled_object_get_document (GO_STYLED_OBJECT (object_with_style)): NULL;
if ((enable & (GO_STYLE_OUTLINE | GO_STYLE_LINE | GO_STYLE_FILL)) != 0) {
- gui = go_glade_new ("go-style-prefs.glade", "go_style_prefs", GETTEXT_PACKAGE, cc);
+ gui = go_gtk_builder_new ("go-style-prefs.ui", GETTEXT_PACKAGE, cc);
if (gui == NULL) {
g_free (state);
return;
}
state->gui = gui;
- w = glade_xml_get_widget (gui, "go_style_prefs");
- g_object_set_data_full (G_OBJECT (w),
- "state", state, (GDestroyNotify) go_style_pref_state_free);
+ w = go_gtk_builder_get_widget (gui, "go_style_prefs");
+ g_object_set_data (G_OBJECT (w), "state", state);
+ g_signal_connect_swapped (G_OBJECT (w), "destroy", G_CALLBACK (go_style_pref_state_free), state);
go_editor_add_page (editor, w, _("Style"));
outline_init (state, enable & GO_STYLE_OUTLINE, editor);
diff --git a/plugins/plot_barcol/Makefile.am b/plugins/plot_barcol/Makefile.am
index 8034c07..8e338ee 100644
--- a/plugins/plot_barcol/Makefile.am
+++ b/plugins/plot_barcol/Makefile.am
@@ -1,6 +1,6 @@
goffice_graph_barcoldir = $(goffice_plugindir)/plot_barcol
xmldir = $(goffice_graph_barcoldir)
-gladedir = $(goffice_graph_barcoldir)
+uidir = $(goffice_graph_barcoldir)
goffice_graph_barcol_LTLIBRARIES = barcol.la
barcol_la_LDFLAGS = -module $(GOFFICE_PLUGIN_FLAGS)
@@ -23,7 +23,7 @@ xml_DATA = $(xml_in_files:.xml.in=.xml)
@INTLTOOL_XML_RULE@
if WITH_GTK
-dist_glade_DATA = gog-barcol-prefs.glade gog-minmax-prefs.glade
+dist_ui_DATA = gog-barcol-prefs.ui gog-minmax-prefs.ui
barcol_la_SOURCES += gog-barcol-prefs.c
endif
diff --git a/plugins/plot_barcol/gog-1.5d.c b/plugins/plot_barcol/gog-1.5d.c
index ebaefd9..24a2b05 100644
--- a/plugins/plot_barcol/gog-1.5d.c
+++ b/plugins/plot_barcol/gog-1.5d.c
@@ -578,6 +578,7 @@ gog_series1_5d_populate_editor (GogObject *obj,
g_object_get (G_OBJECT (series->plot), "horizontal", &horizontal, NULL);
error_page = gog_error_bar_prefs (series, "errors", horizontal, dalloc, cc);
go_editor_add_page (editor, error_page, _("Error bars"));
+ g_object_unref (error_page);
}
#endif
diff --git a/plugins/plot_barcol/gog-barcol-prefs.c b/plugins/plot_barcol/gog-barcol-prefs.c
index 7b73017..807d721 100644
--- a/plugins/plot_barcol/gog-barcol-prefs.c
+++ b/plugins/plot_barcol/gog-barcol-prefs.c
@@ -44,28 +44,27 @@ gog_barcol_plot_pref (GogBarColPlot *barcol, GOCmdContext *cc)
GtkWidget *w;
char const *dir = go_plugin_get_dir_name (
go_plugins_get_plugin_by_id ("GOffice_plot_barcol"));
- char *path = g_build_filename (dir, "gog-barcol-prefs.glade", NULL);
- GladeXML *gui = go_glade_new (path, "gog_barcol_prefs", GETTEXT_PACKAGE, cc);
+ char *path = g_build_filename (dir, "gog-barcol-prefs.ui", NULL);
+ GtkBuilder *gui = go_gtk_builder_new (path, GETTEXT_PACKAGE, cc);
g_free (path);
if (gui == NULL)
return NULL;
- w = glade_xml_get_widget (gui, "gap_spinner");
+ w = go_gtk_builder_get_widget (gui, "gap_spinner");
gtk_spin_button_set_value (GTK_SPIN_BUTTON (w), barcol->gap_percentage);
g_signal_connect (G_OBJECT (gtk_spin_button_get_adjustment (GTK_SPIN_BUTTON (w))),
"value_changed",
G_CALLBACK (cb_gap_changed), barcol);
- w = glade_xml_get_widget (gui, "overlap_spinner");
+ w = go_gtk_builder_get_widget (gui, "overlap_spinner");
gtk_spin_button_set_value (GTK_SPIN_BUTTON (w), barcol->overlap_percentage);
g_signal_connect (G_OBJECT (gtk_spin_button_get_adjustment (GTK_SPIN_BUTTON (w))),
"value_changed",
G_CALLBACK (cb_overlap_changed), barcol);
- w = glade_xml_get_widget (gui, "gog_barcol_prefs");
- g_object_set_data_full (G_OBJECT (w),
- "state", gui, (GDestroyNotify)g_object_unref);
+ w = GTK_WIDGET (g_object_ref (gtk_builder_get_object (gui, "gog_barcol_prefs")));
+ g_object_unref (gui);
return w;
}
diff --git a/plugins/plot_barcol/gog-barcol-prefs.ui b/plugins/plot_barcol/gog-barcol-prefs.ui
new file mode 100644
index 0000000..750ae9d
--- /dev/null
+++ b/plugins/plot_barcol/gog-barcol-prefs.ui
@@ -0,0 +1,117 @@
+<?xml version="1.0"?>
+<interface>
+ <requires lib="gtk+" version="2.16"/>
+ <!-- interface-naming-policy toplevel-contextual -->
+ <object class="GtkAdjustment" id="adjustment1">
+ <property name="upper">500</property>
+ <property name="step_increment">10</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment2">
+ <property name="lower">-100</property>
+ <property name="upper">100</property>
+ <property name="step_increment">10</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkTable" id="gog_barcol_prefs">
+ <property name="visible">True</property>
+ <property name="border_width">12</property>
+ <property name="n_rows">2</property>
+ <property name="n_columns">3</property>
+ <property name="column_spacing">12</property>
+ <property name="row_spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="label61">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="yalign">0</property>
+ <property name="label" translatable="yes">_Gap:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">gap_spinner</property>
+ </object>
+ <packing>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label63">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">%</property>
+ </object>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label64">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">O_verlap:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">overlap_spinner</property>
+ </object>
+ <packing>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label65">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">%</property>
+ </object>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="gap_spinner">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ <property name="adjustment">adjustment1</property>
+ <property name="climb_rate">10</property>
+ <property name="snap_to_ticks">True</property>
+ <property name="numeric">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="overlap_spinner">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ <property name="adjustment">adjustment2</property>
+ <property name="climb_rate">0.10000000000000001</property>
+ <property name="snap_to_ticks">True</property>
+ <property name="numeric">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ </object>
+</interface>
diff --git a/plugins/plot_barcol/gog-barcol.c b/plugins/plot_barcol/gog-barcol.c
index a18a465..f5626c3 100644
--- a/plugins/plot_barcol/gog-barcol.c
+++ b/plugins/plot_barcol/gog-barcol.c
@@ -145,9 +145,9 @@ gog_barcol_plot_populate_editor (GogObject *item,
G_GNUC_UNUSED GogDataAllocator *dalloc,
GOCmdContext *cc)
{
- go_editor_add_page (editor,
- gog_barcol_plot_pref (GOG_BARCOL_PLOT (item), cc),
- _("Properties"));
+ GtkWidget *w = gog_barcol_plot_pref (GOG_BARCOL_PLOT (item), cc);
+ go_editor_add_page (editor, w, _("Properties"));
+ g_object_unref (w);
(GOG_OBJECT_CLASS(gog_barcol_parent_klass)->populate_editor) (item, editor, dalloc, cc);
}
diff --git a/plugins/plot_barcol/gog-minmax-prefs.ui b/plugins/plot_barcol/gog-minmax-prefs.ui
new file mode 100644
index 0000000..b2fd804
--- /dev/null
+++ b/plugins/plot_barcol/gog-minmax-prefs.ui
@@ -0,0 +1,61 @@
+<?xml version="1.0"?>
+<interface>
+ <requires lib="gtk+" version="2.16"/>
+ <!-- interface-naming-policy toplevel-contextual -->
+ <object class="GtkAdjustment" id="adjustment1">
+ <property name="upper">500</property>
+ <property name="step_increment">10</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkTable" id="gog_minmax_prefs">
+ <property name="visible">True</property>
+ <property name="border_width">12</property>
+ <property name="n_columns">3</property>
+ <property name="column_spacing">12</property>
+ <property name="row_spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="label61">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="yalign">0</property>
+ <property name="label" translatable="yes">_Gap:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">gap_spinner</property>
+ </object>
+ <packing>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label63">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">%</property>
+ </object>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="gap_spinner">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ <property name="adjustment">adjustment1</property>
+ <property name="climb_rate">10</property>
+ <property name="snap_to_ticks">True</property>
+ <property name="numeric">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ </object>
+</interface>
diff --git a/plugins/plot_barcol/gog-minmax.c b/plugins/plot_barcol/gog-minmax.c
index 891193e..b915932 100644
--- a/plugins/plot_barcol/gog-minmax.c
+++ b/plugins/plot_barcol/gog-minmax.c
@@ -180,24 +180,23 @@ gog_minmax_plot_populate_editor (GogObject *item,
GogMinMaxPlot *minmax = GOG_MINMAX_PLOT (item);
char const *dir = go_plugin_get_dir_name (
go_plugins_get_plugin_by_id ("GOffice_plot_barcol"));
- char *path = g_build_filename (dir, "gog-minmax-prefs.glade", NULL);
- GladeXML *gui = go_glade_new (path, "gog_minmax_prefs", GETTEXT_PACKAGE, cc);
+ char *path = g_build_filename (dir, "gog-minmax-prefs.ui", NULL);
+ GtkBuilder *gui = go_gtk_builder_new (path, GETTEXT_PACKAGE, cc);
g_free (path);
if (gui == NULL)
return;
- w = glade_xml_get_widget (gui, "gap_spinner");
+ w = go_gtk_builder_get_widget (gui, "gap_spinner");
gtk_spin_button_set_value (GTK_SPIN_BUTTON (w), minmax->gap_percentage);
g_signal_connect (G_OBJECT (gtk_spin_button_get_adjustment (GTK_SPIN_BUTTON (w))),
"value_changed",
G_CALLBACK (cb_gap_changed), minmax);
- w = glade_xml_get_widget (gui, "gog_minmax_prefs");
- g_object_set_data_full (G_OBJECT (w),
- "state", gui, (GDestroyNotify)g_object_unref);
-
+ w = go_gtk_builder_get_widget (gui, "gog_minmax_prefs");
go_editor_add_page (editor, w, _("Properties"));
+ g_object_unref (gui);
+
(GOG_OBJECT_CLASS(gog_minmax_parent_klass)->populate_editor) (item, editor, dalloc, cc);
}
#endif
diff --git a/plugins/plot_distrib/Makefile.am b/plugins/plot_distrib/Makefile.am
index 0bb3a8e..0d40fe2 100644
--- a/plugins/plot_distrib/Makefile.am
+++ b/plugins/plot_distrib/Makefile.am
@@ -1,6 +1,6 @@
goffice_graph_distribdir = $(goffice_plugindir)/plot_distrib
xmldir = $(goffice_graph_distribdir)
-gladedir = $(goffice_graph_distribdir)
+uidir = $(goffice_graph_distribdir)
goffice_graph_distrib_LTLIBRARIES = distrib.la
distrib_la_LDFLAGS = -module $(GOFFICE_PLUGIN_FLAGS)
@@ -22,7 +22,7 @@ if WITH_GTK
go-distribution-prefs.c \
go-distribution-prefs.h
- dist_glade_DATA = gog-boxplot-prefs.glade
+ dist_glade_ui = gog-boxplot-prefs.ui
endif
@INTLTOOL_XML_RULE@
diff --git a/plugins/plot_distrib/gog-boxplot-prefs.ui b/plugins/plot_distrib/gog-boxplot-prefs.ui
new file mode 100644
index 0000000..044ac0e
--- /dev/null
+++ b/plugins/plot_distrib/gog-boxplot-prefs.ui
@@ -0,0 +1,180 @@
+<?xml version="1.0"?>
+<interface>
+ <requires lib="gtk+" version="2.16"/>
+ <!-- interface-naming-policy toplevel-contextual -->
+ <object class="GtkAdjustment" id="adjustment1">
+ <property name="upper">500</property>
+ <property name="step_increment">10</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment2">
+ <property name="value">25</property>
+ <property name="upper">50</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkListStore" id="model1">
+ <columns>
+ <!-- column-name gchararray -->
+ <column type="gchararray"/>
+ </columns>
+ <data>
+ <row>
+ <col id="0" translatable="yes">Horizontal</col>
+ </row>
+ <row>
+ <col id="0" translatable="yes">Vertical</col>
+ </row>
+ </data>
+ </object>
+ <object class="GtkTable" id="gog_box_plot_prefs">
+ <property name="visible">True</property>
+ <property name="border_width">12</property>
+ <property name="n_rows">4</property>
+ <property name="n_columns">3</property>
+ <property name="column_spacing">12</property>
+ <property name="row_spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="label1">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="yalign">0</property>
+ <property name="label" translatable="yes">_Gap:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">gap_spinner</property>
+ </object>
+ <packing>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label2">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">%</property>
+ </object>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="gap_spinner">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ <property name="adjustment">adjustment1</property>
+ <property name="climb_rate">10</property>
+ <property name="snap_to_ticks">True</property>
+ <property name="numeric">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="layout-lbl">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Layout</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkComboBox" id="layout">
+ <property name="visible">True</property>
+ <property name="model">model1</property>
+ <child>
+ <object class="GtkCellRendererText" id="renderer1"/>
+ <attributes>
+ <attribute name="text">0</attribute>
+ </attributes>
+ </child>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">3</property>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options">GTK_FILL</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkCheckButton" id="show-outliers">
+ <property name="label" translatable="yes">_Exclude and show outliers</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="right_attach">3</property>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="diameter-label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Diameter/width:</property>
+ <property name="use_underline">True</property>
+ <property name="justify">right</property>
+ <property name="wrap_mode">word-char</property>
+ </object>
+ <packing>
+ <property name="top_attach">3</property>
+ <property name="bottom_attach">4</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="diameter">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ <property name="adjustment">adjustment2</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="top_attach">3</property>
+ <property name="bottom_attach">4</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="diam-pc-label">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">%</property>
+ </object>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
+ <property name="top_attach">3</property>
+ <property name="bottom_attach">4</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ </object>
+</interface>
diff --git a/plugins/plot_distrib/gog-boxplot.c b/plugins/plot_distrib/gog-boxplot.c
index 1ffe33e..33cb5b2 100644
--- a/plugins/plot_distrib/gog-boxplot.c
+++ b/plugins/plot_distrib/gog-boxplot.c
@@ -57,7 +57,6 @@ static GType gog_box_plot_view_get_type (void);
#ifdef GOFFICE_WITH_GTK
#include <goffice/gtk/goffice-gtk.h>
-#include <glade/glade-xml.h>
static void
cb_gap_changed (GtkAdjustment *adj, GObject *boxplot)
@@ -74,22 +73,22 @@ cb_layout_changed (GtkComboBox *box, GObject *boxplot)
static void
cb_outliers_changed (GtkToggleButton *btn, GObject *boxplot)
{
- GladeXML *gui = GLADE_XML (g_object_get_data (G_OBJECT (btn), "state"));
+ GtkBuilder *gui = GTK_BUILDER (g_object_get_data (G_OBJECT (btn), "state"));
GtkWidget *w;
gboolean outliers = gtk_toggle_button_get_active (btn);
if (outliers) {
- w = glade_xml_get_widget (gui, "diameter-label");
+ w = go_gtk_builder_get_widget (gui, "diameter-label");
gtk_widget_show (w);
- w = glade_xml_get_widget (gui, "diameter");
+ w = go_gtk_builder_get_widget (gui, "diameter");
gtk_widget_show (w);
- w = glade_xml_get_widget (gui, "diam-pc-label");
+ w = go_gtk_builder_get_widget (gui, "diam-pc-label");
gtk_widget_show (w);
} else {
- w = glade_xml_get_widget (gui, "diameter-label");
+ w = go_gtk_builder_get_widget (gui, "diameter-label");
gtk_widget_hide (w);
- w = glade_xml_get_widget (gui, "diameter");
+ w = go_gtk_builder_get_widget (gui, "diameter");
gtk_widget_hide (w);
- w = glade_xml_get_widget (gui, "diam-pc-label");
+ w = go_gtk_builder_get_widget (gui, "diam-pc-label");
gtk_widget_hide (w);
}
g_object_set (boxplot, "outliers", outliers, NULL);
@@ -109,29 +108,29 @@ gog_box_plot_pref (GogObject *obj,
GogBoxPlot *boxplot = GOG_BOX_PLOT (obj);
char const *dir = go_plugin_get_dir_name (
go_plugins_get_plugin_by_id ("GOffice_plot_boxes"));
- char *path = g_build_filename (dir, "gog-boxplot-prefs.glade", NULL);
- GladeXML *gui = go_glade_new (path, "gog_box_plot_prefs", GETTEXT_PACKAGE, cc);
+ char *path = g_build_filename (dir, "gog-boxplot-prefs.ui", NULL);
+ GtkBuilder *gui = go_gtk_builder_new (path, GETTEXT_PACKAGE, cc);
g_free (path);
if (gui == NULL)
return NULL;
- w = glade_xml_get_widget (gui, "gap_spinner");
+ w = go_gtk_builder_get_widget (gui, "gap_spinner");
gtk_spin_button_set_value (GTK_SPIN_BUTTON (w), boxplot->gap_percentage);
g_signal_connect (G_OBJECT (gtk_spin_button_get_adjustment (GTK_SPIN_BUTTON (w))),
"value_changed",
G_CALLBACK (cb_gap_changed), boxplot);
- w = glade_xml_get_widget (gui, "layout");
+ w = go_gtk_builder_get_widget (gui, "layout");
gtk_combo_box_set_active (GTK_COMBO_BOX (w), boxplot->vertical);
g_signal_connect (w, "changed", G_CALLBACK (cb_layout_changed), boxplot);
- w = glade_xml_get_widget (gui, "show-outliers");
+ w = go_gtk_builder_get_widget (gui, "show-outliers");
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (w), boxplot->outliers);
g_object_set_data (G_OBJECT (w), "state", gui);
g_signal_connect (w, "toggled", G_CALLBACK (cb_outliers_changed), boxplot);
- w = glade_xml_get_widget (gui, "diameter");
+ w = go_gtk_builder_get_widget (gui, "diameter");
gtk_spin_button_set_value (GTK_SPIN_BUTTON (w), boxplot->radius_ratio * 200.);
g_signal_connect (G_OBJECT (gtk_spin_button_get_adjustment (GTK_SPIN_BUTTON (w))),
"value_changed",
@@ -139,15 +138,15 @@ gog_box_plot_pref (GogObject *obj,
if (!boxplot->outliers) {
gtk_widget_hide (w);
- w = glade_xml_get_widget (gui, "diameter-label");
+ w = go_gtk_builder_get_widget (gui, "diameter-label");
gtk_widget_hide (w);
- w = glade_xml_get_widget (gui, "diam-pc-label");
+ w = go_gtk_builder_get_widget (gui, "diam-pc-label");
gtk_widget_hide (w);
}
- w = glade_xml_get_widget (gui, "gog_box_plot_prefs");
- g_object_set_data_full (G_OBJECT (w),
- "state", gui, (GDestroyNotify)g_object_unref);
+ w = go_gtk_builder_get_widget (gui, "gog_box_plot_prefs");
+ g_object_set_data (G_OBJECT (w), "state", gui);
+ g_signal_connect (G_OBJECT (w), "destroy", G_CALLBACK (g_object_unref), gui);
return w;
}
@@ -158,7 +157,9 @@ gog_box_plot_populate_editor (GogObject *item,
G_GNUC_UNUSED GogDataAllocator *dalloc,
GOCmdContext *cc)
{
- go_editor_add_page (editor, gog_box_plot_pref (item, dalloc, cc), _("Properties"));
+ GtkWidget *w = gog_box_plot_pref (item, dalloc, cc);
+ go_editor_add_page (editor,w, _("Properties"));
+ g_object_unref (w);
(GOG_OBJECT_CLASS(gog_box_plot_parent_klass)->populate_editor) (item, editor, dalloc, cc);
}
diff --git a/plugins/plot_distrib/gog-probability-plot.c b/plugins/plot_distrib/gog-probability-plot.c
index af89f42..63f4bc2 100644
--- a/plugins/plot_distrib/gog-probability-plot.c
+++ b/plugins/plot_distrib/gog-probability-plot.c
@@ -59,7 +59,9 @@ gog_probability_plot_populate_editor (GogObject *item,
GogDataAllocator *dalloc,
GOCmdContext *cc)
{
- go_editor_add_page (editor, go_distribution_pref_new (G_OBJECT (item), dalloc, cc), _("Distribution"));
+ GtkWidget *w = go_distribution_pref_new (G_OBJECT (item), dalloc, cc);
+ go_editor_add_page (editor, w, _("Distribution"));
+ g_object_unref (w);
(GOG_OBJECT_CLASS(probability_plot_parent_klass)->populate_editor) (item, editor, dalloc, cc);
}
diff --git a/plugins/plot_pie/Makefile.am b/plugins/plot_pie/Makefile.am
index e63b2bc..d9d3d27 100644
--- a/plugins/plot_pie/Makefile.am
+++ b/plugins/plot_pie/Makefile.am
@@ -1,6 +1,6 @@
goffice_graph_piedir = $(goffice_plugindir)/plot_pie
xmldir = $(goffice_graph_piedir)
-gladedir = $(goffice_graph_piedir)
+uidir = $(goffice_graph_piedir)
goffice_graph_pie_LTLIBRARIES = pie.la
pie_la_LDFLAGS = -module $(GOFFICE_PLUGIN_FLAGS)
@@ -16,7 +16,7 @@ xml_DATA = $(xml_in_files:.xml.in=.xml)
@INTLTOOL_XML_RULE@
if WITH_GTK
-dist_glade_DATA = gog-pie-prefs.glade gog-ring-prefs.glade gog-pie-series.glade
+dist_ui_DATA = gog-pie-prefs.ui gog-ring-prefs.ui gog-pie-series.ui
pie_la_SOURCES += gog-pie-prefs.c
endif
diff --git a/plugins/plot_pie/gog-pie-prefs.c b/plugins/plot_pie/gog-pie-prefs.c
index 0fb480d..2239f2f 100644
--- a/plugins/plot_pie/gog-pie-prefs.c
+++ b/plugins/plot_pie/gog-pie-prefs.c
@@ -39,22 +39,21 @@ gog_pie_series_element_pref (GogPieSeriesElement *element, GOCmdContext *cc)
GtkWidget *w;
char const *dir = go_plugin_get_dir_name (
go_plugins_get_plugin_by_id ("GOffice_plot_pie"));
- char *path = g_build_filename (dir, "gog-pie-series.glade", NULL);
- GladeXML *gui = go_glade_new (path, "gog_pie_series_element_prefs", GETTEXT_PACKAGE, cc);
+ char *path = g_build_filename (dir, "gog-pie-series.ui", NULL);
+ GtkBuilder *gui = go_gtk_builder_new (path, GETTEXT_PACKAGE, cc);
g_free (path);
if (gui == NULL)
return NULL;
- w = glade_xml_get_widget (gui, "separation_spinner");
+ w = go_gtk_builder_get_widget (gui, "separation_spinner");
gtk_spin_button_set_value (GTK_SPIN_BUTTON (w), element->separation * 100.);
g_signal_connect (G_OBJECT (gtk_spin_button_get_adjustment (GTK_SPIN_BUTTON (w))),
"value_changed",
G_CALLBACK (cb_element_separation_changed), element);
- w = glade_xml_get_widget (gui, "gog_pie_series_element_prefs");
- g_object_set_data_full (G_OBJECT (w),
- "state", gui, (GDestroyNotify)g_object_unref);
+ w = GTK_WIDGET (g_object_ref (gtk_builder_get_object (gui, "gog_pie_series_element_prefs")));
+ g_object_unref (gui);
return w;
}
@@ -65,16 +64,15 @@ GtkWidget *gog_pie_plot_pref (GogPiePlot *plot, GOCmdContext *cc);
typedef struct {
GtkWidget *separation_spinner;
GogObject *gobj;
- GladeXML *gui;
gulong update_editor_handler;
} PiePrefState;
static void
pie_pref_state_free (PiePrefState *state)
{
+puts("freeing");
g_signal_handler_disconnect (state->gobj, state->update_editor_handler);
g_object_unref (state->gobj);
- g_object_unref (state->gui);
g_free (state);
}
@@ -99,23 +97,23 @@ cb_use_style_toggled (GtkToggleButton *button, GObject *series)
}
static void
-gog_pie_plot_pref_signal_connect (GogPiePlot *pie, GladeXML *gui)
+gog_pie_plot_pref_signal_connect (GogPiePlot *pie, GtkBuilder *gui)
{
GtkWidget *w;
- w = glade_xml_get_widget (gui, "rotation_spinner");
+ w = go_gtk_builder_get_widget (gui, "rotation_spinner");
gtk_spin_button_set_value (GTK_SPIN_BUTTON (w), pie->initial_angle);
g_signal_connect (G_OBJECT (gtk_spin_button_get_adjustment (GTK_SPIN_BUTTON (w))),
"value_changed",
G_CALLBACK (cb_rotation_changed), pie);
- w = glade_xml_get_widget (gui, "separation_spinner");
+ w = go_gtk_builder_get_widget (gui, "separation_spinner");
gtk_spin_button_set_value (GTK_SPIN_BUTTON (w), pie->default_separation * 100.);
g_signal_connect (G_OBJECT (gtk_spin_button_get_adjustment (GTK_SPIN_BUTTON (w))),
"value_changed",
G_CALLBACK (cb_default_separation_changed), pie);
- w = glade_xml_get_widget (gui, "vary_style_by_element");
+ w = go_gtk_builder_get_widget (gui, "vary_style_by_element");
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (w), pie->base.vary_style_by_element);
g_signal_connect (G_OBJECT (w),
"toggled",
@@ -140,8 +138,8 @@ gog_pie_plot_pref (GogPiePlot *pie, GOCmdContext *cc)
{
GtkWidget *w;
char const *dir = go_plugin_get_dir_name (go_plugins_get_plugin_by_id ("GOffice_plot_pie"));
- char *path = g_build_filename (dir, "gog-pie-prefs.glade", NULL);
- GladeXML *gui = go_glade_new (path, "gog_pie_prefs", GETTEXT_PACKAGE, cc);
+ char *path = g_build_filename (dir, "gog-pie-prefs.ui", NULL);
+ GtkBuilder *gui = go_gtk_builder_new (path, GETTEXT_PACKAGE, cc);
PiePrefState *state;
g_free (path);
@@ -149,9 +147,8 @@ gog_pie_plot_pref (GogPiePlot *pie, GOCmdContext *cc)
return NULL;
state = g_new0 (PiePrefState, 1);
- state->gui = gui;
state->gobj = GOG_OBJECT (pie);
- state->separation_spinner = glade_xml_get_widget (gui, "separation_spinner");
+ state->separation_spinner = go_gtk_builder_get_widget (gui, "separation_spinner");
g_object_ref (G_OBJECT (pie));
gog_pie_plot_pref_signal_connect (pie, gui);
@@ -160,9 +157,9 @@ gog_pie_plot_pref (GogPiePlot *pie, GOCmdContext *cc)
"update-editor",
G_CALLBACK (cb_update_editor), state);
- w = glade_xml_get_widget (gui, "gog_pie_prefs");
- g_object_set_data_full (G_OBJECT (w),
- "state", state, (GDestroyNotify) pie_pref_state_free);
+ w = GTK_WIDGET (g_object_ref (gtk_builder_get_object (gui, "gog_pie_prefs")));
+ g_object_set_data_full (G_OBJECT (w), "state", state, (GDestroyNotify) pie_pref_state_free);
+ g_object_unref (gui);
return w;
}
@@ -184,8 +181,8 @@ gog_ring_plot_pref (GogRingPlot *ring, GOCmdContext *cc)
GtkWidget *w;
char const *dir = go_plugin_get_dir_name (
go_plugins_get_plugin_by_id ("GOffice_plot_pie"));
- char *path = g_build_filename (dir, "gog-ring-prefs.glade", NULL);
- GladeXML *gui = go_glade_new (path, "gog_ring_prefs", GETTEXT_PACKAGE, cc);
+ char *path = g_build_filename (dir, "gog-ring-prefs.ui", NULL);
+ GtkBuilder *gui = go_gtk_builder_new (path, GETTEXT_PACKAGE, cc);
PiePrefState *state;
g_free (path);
@@ -193,14 +190,13 @@ gog_ring_plot_pref (GogRingPlot *ring, GOCmdContext *cc)
return NULL;
state = g_new0 (PiePrefState, 1);
- state->gui = gui;
state->gobj = GOG_OBJECT (ring);
- state->separation_spinner = glade_xml_get_widget (gui, "separation_spinner");
+ state->separation_spinner = go_gtk_builder_get_widget (gui, "separation_spinner");
g_object_ref (G_OBJECT (ring));
gog_pie_plot_pref_signal_connect (GOG_PIE_PLOT (ring), gui);
- w = glade_xml_get_widget (gui, "center_size_spinner");
+ w = go_gtk_builder_get_widget (gui, "center_size_spinner");
gtk_spin_button_set_value (GTK_SPIN_BUTTON (w), ring->center_size * 100);
g_signal_connect (G_OBJECT (gtk_spin_button_get_adjustment (GTK_SPIN_BUTTON (w))),
"value_changed",
@@ -210,9 +206,9 @@ gog_ring_plot_pref (GogRingPlot *ring, GOCmdContext *cc)
"update-editor",
G_CALLBACK (cb_update_editor), state);
- w = glade_xml_get_widget (gui, "gog_ring_prefs");
- g_object_set_data_full (G_OBJECT (w),
- "state", state, (GDestroyNotify) pie_pref_state_free);
+ w = GTK_WIDGET (g_object_ref (gtk_builder_get_object (gui, "gog_ring_prefs")));
+ g_object_set_data_full (G_OBJECT (w), "state", state, (GDestroyNotify) pie_pref_state_free);
+ g_object_unref (gui);
return w;
}
diff --git a/plugins/plot_pie/gog-pie-prefs.ui b/plugins/plot_pie/gog-pie-prefs.ui
new file mode 100644
index 0000000..2fd8121
--- /dev/null
+++ b/plugins/plot_pie/gog-pie-prefs.ui
@@ -0,0 +1,134 @@
+<?xml version="1.0"?>
+<interface>
+ <requires lib="gtk+" version="2.16"/>
+ <!-- interface-naming-policy toplevel-contextual -->
+ <object class="GtkAdjustment" id="adjustment1">
+ <property name="upper">360</property>
+ <property name="step_increment">10</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment2">
+ <property name="upper">500</property>
+ <property name="step_increment">10</property>
+ <property name="page_increment">50</property>
+ </object>
+ <object class="GtkTable" id="gog_pie_prefs">
+ <property name="visible">True</property>
+ <property name="border_width">12</property>
+ <property name="n_rows">3</property>
+ <property name="n_columns">3</property>
+ <property name="column_spacing">12</property>
+ <property name="row_spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="label61">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="yalign">0</property>
+ <property name="label" translatable="yes">Slices start _at:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">rotation_spinner</property>
+ </object>
+ <packing>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label63">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">degrees</property>
+ </object>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkCheckButton" id="vary_style_by_element">
+ <property name="label" translatable="yes">_Vary colors by slice</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="right_attach">3</property>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label64">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Slice Separation:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">separation_spinner</property>
+ </object>
+ <packing>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label65">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">%</property>
+ </object>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="rotation_spinner">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ <property name="adjustment">adjustment1</property>
+ <property name="climb_rate">10</property>
+ <property name="snap_to_ticks">True</property>
+ <property name="numeric">True</property>
+ <property name="wrap">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="separation_spinner">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ <property name="adjustment">adjustment2</property>
+ <property name="climb_rate">10</property>
+ <property name="snap_to_ticks">True</property>
+ <property name="numeric">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ </object>
+</interface>
diff --git a/plugins/plot_pie/gog-pie-series.ui b/plugins/plot_pie/gog-pie-series.ui
new file mode 100644
index 0000000..b8d4c10
--- /dev/null
+++ b/plugins/plot_pie/gog-pie-series.ui
@@ -0,0 +1,72 @@
+<?xml version="1.0"?>
+<interface>
+ <requires lib="gtk+" version="2.16"/>
+ <!-- interface-naming-policy toplevel-contextual -->
+ <object class="GtkAdjustment" id="adjustment1">
+ <property name="upper">500</property>
+ <property name="step_increment">10</property>
+ <property name="page_increment">50</property>
+ </object>
+ <object class="GtkVBox" id="gog_pie_series_element_prefs">
+ <property name="visible">True</property>
+ <property name="border_width">12</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkTable" id="separation_table">
+ <property name="visible">True</property>
+ <property name="n_columns">3</property>
+ <property name="column_spacing">12</property>
+ <property name="row_spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="label64">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Separation:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">separation_spinner</property>
+ </object>
+ <packing>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label65">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">%</property>
+ </object>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="separation_spinner">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ <property name="adjustment">adjustment1</property>
+ <property name="climb_rate">10</property>
+ <property name="snap_to_ticks">True</property>
+ <property name="numeric">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ </object>
+</interface>
diff --git a/plugins/plot_pie/gog-pie.c b/plugins/plot_pie/gog-pie.c
index 9c78932..310e04f 100644
--- a/plugins/plot_pie/gog-pie.c
+++ b/plugins/plot_pie/gog-pie.c
@@ -86,6 +86,7 @@ gog_pie_series_element_populate_editor (GogObject *gobj,
{
GtkWidget *widget = gog_pie_series_element_pref (GOG_PIE_SERIES_ELEMENT (gobj), cc);
go_editor_add_page (editor, widget, _("Settings"));
+ g_object_unref (G_OBJECT (widget));
return widget;
}
#endif
@@ -202,9 +203,11 @@ gog_pie_plot_populate_editor (GogObject *item,
G_GNUC_UNUSED GogDataAllocator *dalloc,
GOCmdContext *cc)
{
+ GtkWidget *widget = gog_pie_plot_pref (GOG_PIE_PLOT (item), cc);
go_editor_add_page (editor,
- gog_pie_plot_pref (GOG_PIE_PLOT (item), cc),
+ widget,
_("Properties"));
+ g_object_unref (G_OBJECT (widget));
(GOG_OBJECT_CLASS(pie_parent_klass)->populate_editor) (item, editor, dalloc, cc);
}
@@ -348,9 +351,11 @@ gog_ring_plot_populate_editor (GogObject *item,
G_GNUC_UNUSED GogDataAllocator *dalloc,
GOCmdContext *cc)
{
+ GtkWidget *widget = gog_ring_plot_pref (GOG_RING_PLOT (item), cc);
go_editor_add_page (editor,
- gog_ring_plot_pref (GOG_RING_PLOT (item), cc),
+ widget,
_("Properties"));
+ g_object_unref (G_OBJECT (widget));
}
static void
diff --git a/plugins/plot_pie/gog-ring-prefs.ui b/plugins/plot_pie/gog-ring-prefs.ui
new file mode 100644
index 0000000..777ca45
--- /dev/null
+++ b/plugins/plot_pie/gog-ring-prefs.ui
@@ -0,0 +1,188 @@
+<?xml version="1.0"?>
+<interface>
+ <requires lib="gtk+" version="2.16"/>
+ <!-- interface-naming-policy toplevel-contextual -->
+ <object class="GtkAdjustment" id="adjustment1">
+ <property name="upper">360</property>
+ <property name="step_increment">10</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment2">
+ <property name="upper">500</property>
+ <property name="step_increment">10</property>
+ <property name="page_increment">50</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment3">
+ <property name="upper">95</property>
+ <property name="step_increment">5</property>
+ <property name="page_increment">0.20000000000000001</property>
+ </object>
+ <object class="GtkTable" id="gog_ring_prefs">
+ <property name="visible">True</property>
+ <property name="border_width">12</property>
+ <property name="n_rows">4</property>
+ <property name="n_columns">3</property>
+ <property name="column_spacing">12</property>
+ <property name="row_spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="label61">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="yalign">0</property>
+ <property name="label" translatable="yes">Slices start _at:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">rotation_spinner</property>
+ </object>
+ <packing>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label63">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">degrees</property>
+ </object>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkCheckButton" id="vary_style_by_element">
+ <property name="label" translatable="yes">_Vary colors by slice</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="right_attach">3</property>
+ <property name="top_attach">3</property>
+ <property name="bottom_attach">4</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label64">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Slice Separation:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">separation_spinner</property>
+ </object>
+ <packing>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label65">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">%</property>
+ </object>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="rotation_spinner">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ <property name="adjustment">adjustment1</property>
+ <property name="climb_rate">10</property>
+ <property name="snap_to_ticks">True</property>
+ <property name="numeric">True</property>
+ <property name="wrap">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="separation_spinner">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ <property name="adjustment">adjustment2</property>
+ <property name="climb_rate">10</property>
+ <property name="snap_to_ticks">True</property>
+ <property name="numeric">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label66">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Cen_ter size:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">center_size_spinner</property>
+ </object>
+ <packing>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label67">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">%</property>
+ </object>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="center_size_spinner">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ <property name="adjustment">adjustment3</property>
+ <property name="climb_rate">1</property>
+ <property name="snap_to_ticks">True</property>
+ <property name="numeric">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ </object>
+</interface>
diff --git a/plugins/plot_radar/Makefile.am b/plugins/plot_radar/Makefile.am
index 0693828..f37aead 100644
--- a/plugins/plot_radar/Makefile.am
+++ b/plugins/plot_radar/Makefile.am
@@ -13,7 +13,7 @@ radar_la_SOURCES = \
xml_in_files = plugin.xml.in plot-types.xml.in
xml_DATA = $(xml_in_files:.xml.in=.xml)
-ui_DATA = gog-color-polar-prefs.xml
+ui_DATA = gog-color-polar-prefs.ui
@INTLTOOL_XML_RULE@
@@ -22,8 +22,7 @@ ui_DATA = gog-color-polar-prefs.xml
plot-types.xml : plot-types.xml.in
cp $< $@
-EXTRA_DIST = $(xml_in_files) $(ui_DATA) \
- gog-color-polar-prefs.glade
+EXTRA_DIST = $(xml_in_files) $(ui_DATA)
DISTCLEANFILES = $(xml_in_files:.xml.in=.xml)
include $(top_srcdir)/goffice-plugins.mk
diff --git a/plugins/plot_radar/gog-color-polar-prefs.ui b/plugins/plot_radar/gog-color-polar-prefs.ui
new file mode 100644
index 0000000..d5ce07e
--- /dev/null
+++ b/plugins/plot_radar/gog-color-polar-prefs.ui
@@ -0,0 +1,24 @@
+<?xml version="1.0"?>
+<interface>
+ <requires lib="gtk+" version="2.16"/>
+ <!-- interface-naming-policy toplevel-contextual -->
+ <object class="GtkTable" id="gog-color-polar-prefs">
+ <property name="visible">True</property>
+ <property name="border_width">12</property>
+ <property name="column_spacing">12</property>
+ <property name="row_spacing">6</property>
+ <child>
+ <object class="GtkCheckButton" id="hide-outliers">
+ <property name="label" translatable="yes">Hide data outside of color axis bounds</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="x_options"></property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ </object>
+</interface>
diff --git a/plugins/plot_radar/gog-radar.c b/plugins/plot_radar/gog-radar.c
index 8b797a8..a4ed4ec 100644
--- a/plugins/plot_radar/gog-radar.c
+++ b/plugins/plot_radar/gog-radar.c
@@ -460,15 +460,13 @@ gog_color_polar_plot_populate_editor (GogObject *obj,
g_free (path);
if (gui != NULL) {
- GtkWidget *w = GTK_WIDGET (gtk_builder_get_object (gui, "hide-outliers"));
+ GtkWidget *w = go_gtk_builder_get_widget (gui, "hide-outliers");
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (w),
(GOG_COLOR_POLAR_PLOT (obj))->hide_outliers);
g_signal_connect (G_OBJECT (w),
"toggled",
G_CALLBACK (hide_outliers_toggled_cb), obj);
- w = GTK_WIDGET (gtk_builder_get_object (gui, "gog-color-polar-prefs"));
- gtk_widget_unparent (w);
- g_object_ref (w);
+ w = go_gtk_builder_get_widget (gui, "gog-color-polar-prefs");
go_editor_add_page (editor, w, _("Properties"));
g_object_unref (gui);
}
diff --git a/plugins/plot_surface/Makefile.am b/plugins/plot_surface/Makefile.am
index c911c5e..5eb8545 100644
--- a/plugins/plot_surface/Makefile.am
+++ b/plugins/plot_surface/Makefile.am
@@ -1,6 +1,6 @@
goffice_graph_surfacedir = $(goffice_plugindir)/plot_surface
xmldir = $(goffice_graph_surfacedir)
-gladedir = $(goffice_graph_surfacedir)
+uidir = $(goffice_graph_surfacedir)
goffice_graph_surface_LTLIBRARIES = surface.la
surface_la_LDFLAGS = -module $(GOFFICE_PLUGIN_FLAGS)
@@ -24,9 +24,9 @@ xml_DATA = $(xml_in_files:.xml.in=.xml)
@INTLTOOL_XML_RULE@
if WITH_GTK
-dist_glade_DATA = \
- gog-xyz-prefs.glade \
- gog-xyz-surface-prefs.glade
+dist_ui_DATA = \
+ gog-xyz-prefs.ui \
+ gog-xyz-surface-prefs.ui
surface_la_SOURCES += \
gog-xyz-prefs.c \
diff --git a/plugins/plot_surface/gog-xyz-prefs.c b/plugins/plot_surface/gog-xyz-prefs.c
index 0b66c9b..d385c72 100644
--- a/plugins/plot_surface/gog-xyz-prefs.c
+++ b/plugins/plot_surface/gog-xyz-prefs.c
@@ -40,23 +40,22 @@ gog_xyz_plot_pref (GogXYZPlot *plot, GOCmdContext *cc)
GtkWidget *w;
char const *dir = go_plugin_get_dir_name (
go_plugins_get_plugin_by_id ("GOffice_plot_surface"));
- char *path = g_build_filename (dir, "gog-xyz-prefs.glade", NULL);
- GladeXML *gui = go_glade_new (path, "gog_xyz_prefs", GETTEXT_PACKAGE, cc);
+ char *path = g_build_filename (dir, "gog-xyz-prefs.ui", NULL);
+ GtkBuilder *gui = go_gtk_builder_new (path, GETTEXT_PACKAGE, cc);
g_free (path);
if (gui == NULL)
return NULL;
- w = glade_xml_get_widget (gui, "transpose");
+ w = go_gtk_builder_get_widget (gui, "transpose");
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (w), plot->transposed);
g_signal_connect (G_OBJECT (w),
"toggled",
G_CALLBACK (cb_transpose), plot);
- w = glade_xml_get_widget (gui, "gog_xyz_prefs");
- g_object_set_data_full (G_OBJECT (w),
- "state", gui, (GDestroyNotify)g_object_unref);
+ w = GTK_WIDGET (g_object_ref (gtk_builder_get_object (gui, "gog_xyz_prefs")));
+ g_object_unref (gui);
return w;
}
diff --git a/plugins/plot_surface/gog-xyz-prefs.ui b/plugins/plot_surface/gog-xyz-prefs.ui
new file mode 100644
index 0000000..c338723
--- /dev/null
+++ b/plugins/plot_surface/gog-xyz-prefs.ui
@@ -0,0 +1,25 @@
+<?xml version="1.0"?>
+<interface>
+ <requires lib="gtk+" version="2.16"/>
+ <!-- interface-naming-policy toplevel-contextual -->
+ <object class="GtkTable" id="gog_xyz_prefs">
+ <property name="visible">True</property>
+ <property name="border_width">5</property>
+ <property name="column_spacing">5</property>
+ <property name="row_spacing">5</property>
+ <child>
+ <object class="GtkCheckButton" id="transpose">
+ <property name="label" translatable="yes">Transpose</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ </object>
+</interface>
diff --git a/plugins/plot_surface/gog-xyz-surface-prefs.c b/plugins/plot_surface/gog-xyz-surface-prefs.c
index e92d7fc..bde1fba 100644
--- a/plugins/plot_surface/gog-xyz-surface-prefs.c
+++ b/plugins/plot_surface/gog-xyz-surface-prefs.c
@@ -47,28 +47,27 @@ gog_xyz_surface_plot_pref (GogXYZSurfacePlot *plot, GOCmdContext *cc)
GtkWidget *w;
char const *dir = go_plugin_get_dir_name (
go_plugins_get_plugin_by_id ("GOffice_plot_surface"));
- char *path = g_build_filename (dir, "gog-xyz-surface-prefs.glade", NULL);
- GladeXML *gui = go_glade_new (path, "gog_xyz_surface_prefs", GETTEXT_PACKAGE, cc);
+ char *path = g_build_filename (dir, "gog-xyz-surface-prefs.ui", NULL);
+ GtkBuilder *gui = go_gtk_builder_new (path, GETTEXT_PACKAGE, cc);
g_free (path);
if (gui == NULL)
return NULL;
- w = glade_xml_get_widget (gui, "rows_spinner");
+ w = go_gtk_builder_get_widget (gui, "rows_spinner");
gtk_spin_button_set_value (GTK_SPIN_BUTTON (w), xyz->rows);
g_signal_connect (G_OBJECT (gtk_spin_button_get_adjustment (GTK_SPIN_BUTTON (w))),
"value_changed",
G_CALLBACK (cb_rows_changed), plot);
- w = glade_xml_get_widget (gui, "columns_spinner");
+ w = go_gtk_builder_get_widget (gui, "columns_spinner");
gtk_spin_button_set_value (GTK_SPIN_BUTTON (w), xyz->columns);
g_signal_connect (G_OBJECT (gtk_spin_button_get_adjustment (GTK_SPIN_BUTTON (w))),
"value_changed",
G_CALLBACK (cb_columns_changed), plot);
- w = glade_xml_get_widget (gui, "gog_xyz_surface_prefs");
- g_object_set_data_full (G_OBJECT (w),
- "state", gui, (GDestroyNotify)g_object_unref);
+ w = GTK_WIDGET (g_object_ref (gtk_builder_get_object (gui, "gog_xyz_surface_prefs")));
+ g_object_unref (gui);
return w;
}
diff --git a/plugins/plot_surface/gog-xyz-surface-prefs.ui b/plugins/plot_surface/gog-xyz-surface-prefs.ui
new file mode 100644
index 0000000..3363691
--- /dev/null
+++ b/plugins/plot_surface/gog-xyz-surface-prefs.ui
@@ -0,0 +1,92 @@
+<?xml version="1.0"?>
+<interface>
+ <requires lib="gtk+" version="2.16"/>
+ <!-- interface-naming-policy toplevel-contextual -->
+ <object class="GtkAdjustment" id="adjustment1">
+ <property name="value">10</property>
+ <property name="lower">2</property>
+ <property name="upper">1000</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment2">
+ <property name="value">10</property>
+ <property name="lower">2</property>
+ <property name="upper">1000</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkTable" id="gog_xyz_surface_prefs">
+ <property name="visible">True</property>
+ <property name="border_width">12</property>
+ <property name="n_rows">2</property>
+ <property name="n_columns">2</property>
+ <property name="column_spacing">12</property>
+ <property name="row_spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="label61">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="yalign">0</property>
+ <property name="label" translatable="yes">_Rows:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">rows_spinner</property>
+ </object>
+ <packing>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label64">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Columns:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">columns_spinner</property>
+ </object>
+ <packing>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="rows_spinner">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ <property name="adjustment">adjustment1</property>
+ <property name="climb_rate">10</property>
+ <property name="snap_to_ticks">True</property>
+ <property name="numeric">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="columns_spinner">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ <property name="adjustment">adjustment2</property>
+ <property name="climb_rate">0.10000000000000001</property>
+ <property name="snap_to_ticks">True</property>
+ <property name="numeric">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ </object>
+</interface>
diff --git a/plugins/plot_surface/gog-xyz-surface.c b/plugins/plot_surface/gog-xyz-surface.c
index 63ae34f..b0e5f28 100644
--- a/plugins/plot_surface/gog-xyz-surface.c
+++ b/plugins/plot_surface/gog-xyz-surface.c
@@ -176,10 +176,10 @@ gog_xyz_surface_plot_populate_editor (GogObject *item,
GogObjectClass *klass = (GOG_IS_PLOT_CONTOUR (item))?
plot_xyz_contour_parent_klass:
plot_xyz_surface_parent_klass;
+ GtkWidget *w = gog_xyz_surface_plot_pref (GOG_XYZ_PLOT (item), cc);
+ go_editor_add_page (editor, w, _("Properties"));
+ g_object_unref (G_OBJECT (w));
- go_editor_add_page (editor,
- gog_xyz_surface_plot_pref (GOG_XYZ_PLOT (item), cc),
- _("Properties"));
(GOG_OBJECT_CLASS (klass)->populate_editor) (item, editor, dalloc, cc);
}
#endif
diff --git a/plugins/plot_surface/gog-xyz.c b/plugins/plot_surface/gog-xyz.c
index d8cf0a2..32ac0da 100644
--- a/plugins/plot_surface/gog-xyz.c
+++ b/plugins/plot_surface/gog-xyz.c
@@ -94,10 +94,11 @@ gog_xyz_plot_populate_editor (GogObject *item,
G_GNUC_UNUSED GogDataAllocator *dalloc,
GOCmdContext *cc)
{
- if (!GOG_XYZ_PLOT (item)->data_xyz)
- go_editor_add_page (editor,
- gog_xyz_plot_pref (GOG_XYZ_PLOT (item), cc),
- _("Properties"));
+ if (!GOG_XYZ_PLOT (item)->data_xyz) {
+ GtkWidget *w = gog_xyz_plot_pref (GOG_XYZ_PLOT (item), cc);
+ go_editor_add_page (editor, w, _("Properties"));
+ g_object_unref (w);
+ }
(GOG_OBJECT_CLASS (plot_xyz_parent_klass)->populate_editor) (item, editor, dalloc, cc);
}
diff --git a/plugins/plot_xy/Makefile.am b/plugins/plot_xy/Makefile.am
index 30eb2dc..1ca8960 100644
--- a/plugins/plot_xy/Makefile.am
+++ b/plugins/plot_xy/Makefile.am
@@ -1,6 +1,6 @@
goffice_graph_xydir = $(goffice_plugindir)/plot_xy
xmldir = $(goffice_graph_xydir)
-gladedir = $(goffice_graph_xydir)
+uidir = $(goffice_graph_xydir)
goffice_graph_xy_LTLIBRARIES = xy.la
xy_la_LDFLAGS = -module $(GOFFICE_PLUGIN_FLAGS)
@@ -17,10 +17,10 @@ xml_DATA = $(xml_in_files:.xml.in=.xml)
if WITH_GTK
xy_la_SOURCES += gog-bubble-prefs.c
-dist_glade_DATA = \
- gog-bubble-prefs.glade \
- gog-xy-color-prefs.glade \
- gog-xy-series-prefs.glade
+dist_ui_DATA = \
+ gog-bubble-prefs.ui \
+ gog-xy-color-prefs.ui \
+ gog-xy-series-prefs.ui
endif
# do not use the intl-tool stuff to merge the text back
diff --git a/plugins/plot_xy/gog-bubble-prefs.c b/plugins/plot_xy/gog-bubble-prefs.c
index 22d2241..852342c 100644
--- a/plugins/plot_xy/gog-bubble-prefs.c
+++ b/plugins/plot_xy/gog-bubble-prefs.c
@@ -69,32 +69,32 @@ gog_bubble_plot_pref (GogBubblePlot *bubble, GOCmdContext *cc)
GtkWidget *w;
char const *dir = go_plugin_get_dir_name (
go_plugins_get_plugin_by_id ("GOffice_plot_xy"));
- char *path = g_build_filename (dir, "gog-bubble-prefs.glade", NULL);
- GladeXML *gui = go_glade_new (path, "gog_bubble_prefs", GETTEXT_PACKAGE, cc);
+ char *path = g_build_filename (dir, "gog-bubble-prefs.ui", NULL);
+ GtkBuilder *gui = go_gtk_builder_new (path, GETTEXT_PACKAGE, cc);
g_free (path);
if (gui == NULL)
return NULL;
- w = glade_xml_get_widget (gui, "area");
+ w = go_gtk_builder_get_widget (gui, "area");
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (w), bubble->size_as_area);
g_signal_connect (G_OBJECT (w),
"toggled",
G_CALLBACK (cb_type_changed), bubble);
- w = glade_xml_get_widget (gui, "diameter");
+ w = go_gtk_builder_get_widget (gui, "diameter");
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (w), !bubble->size_as_area);
g_signal_connect (G_OBJECT (w),
"toggled",
G_CALLBACK (cb_type_changed), bubble);
- w = glade_xml_get_widget (gui, "vary_style_by_element");
+ w = go_gtk_builder_get_widget (gui, "vary_style_by_element");
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (w), bubble->base.base.vary_style_by_element);
g_signal_connect (G_OBJECT (w),
"toggled",
G_CALLBACK (cb_style_changed), bubble);
- w = glade_xml_get_widget (gui, "3d");
+ w = go_gtk_builder_get_widget (gui, "3d");
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (w), bubble->in_3d);
g_signal_connect (G_OBJECT (w),
"toggled",
@@ -103,21 +103,20 @@ gog_bubble_plot_pref (GogBubblePlot *bubble, GOCmdContext *cc)
/* TODO Add support for 3D bubbles. Hide the button for now. */
gtk_widget_hide (w);
- w = glade_xml_get_widget (gui, "scale");
+ w = go_gtk_builder_get_widget (gui, "scale");
gtk_spin_button_set_value (GTK_SPIN_BUTTON (w), bubble->bubble_scale * 100.);
g_signal_connect (G_OBJECT (gtk_spin_button_get_adjustment (GTK_SPIN_BUTTON (w))),
"value_changed",
G_CALLBACK (cb_scale_changed), bubble);
- w = glade_xml_get_widget (gui, "show_negative_values");
+ w = go_gtk_builder_get_widget (gui, "show_negative_values");
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (w), bubble->show_negatives);
g_signal_connect (G_OBJECT (w),
"toggled",
G_CALLBACK (cb_negatives_changed), bubble);
- w = glade_xml_get_widget (gui, "gog_bubble_prefs");
- g_object_set_data_full (G_OBJECT (w),
- "state", gui, (GDestroyNotify)g_object_unref);
+ w = GTK_WIDGET (g_object_ref (gtk_builder_get_object (gui, "gog_bubble_prefs")));
+ g_object_unref (gui);
return w;
}
diff --git a/plugins/plot_xy/gog-bubble-prefs.ui b/plugins/plot_xy/gog-bubble-prefs.ui
new file mode 100644
index 0000000..11f037a
--- /dev/null
+++ b/plugins/plot_xy/gog-bubble-prefs.ui
@@ -0,0 +1,177 @@
+<?xml version="1.0"?>
+<interface>
+ <requires lib="gtk+" version="2.16"/>
+ <!-- interface-naming-policy toplevel-contextual -->
+ <object class="GtkAdjustment" id="adjustment1">
+ <property name="value">100</property>
+ <property name="upper">300</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkTable" id="gog_bubble_prefs">
+ <property name="visible">True</property>
+ <property name="border_width">12</property>
+ <property name="n_rows">5</property>
+ <property name="n_columns">3</property>
+ <property name="column_spacing">12</property>
+ <property name="row_spacing">6</property>
+ <child>
+ <object class="GtkCheckButton" id="3d">
+ <property name="label" translatable="yes">3_d</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="top_attach">3</property>
+ <property name="bottom_attach">4</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkRadioButton" id="area">
+ <property name="label" translatable="yes">Sur_face</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="active">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkRadioButton" id="diameter">
+ <property name="label" translatable="yes">Dia_meter</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ <property name="group">area</property>
+ </object>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="size_display">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Size represented by:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">area</property>
+ </object>
+ <packing>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkCheckButton" id="vary_style_by_element">
+ <property name="label" translatable="yes">_Vary colors by bubble</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="right_attach">2</property>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkCheckButton" id="show_negative_values">
+ <property name="label" translatable="yes">Show _negative values</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="right_attach">2</property>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHBox" id="scale_box">
+ <property name="visible">True</property>
+ <property name="spacing">12</property>
+ <child>
+ <object class="GtkLabel" id="scale_label">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes">_Bubbles scaled to</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">scale</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="scale">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ <property name="adjustment">adjustment1</property>
+ <property name="climb_rate">1</property>
+ </object>
+ <packing>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="percent">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes">% of default size</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="right_attach">3</property>
+ <property name="top_attach">4</property>
+ <property name="bottom_attach">5</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ </object>
+</interface>
diff --git a/plugins/plot_xy/gog-xy-color-prefs.ui b/plugins/plot_xy/gog-xy-color-prefs.ui
new file mode 100644
index 0000000..8ba1f6a
--- /dev/null
+++ b/plugins/plot_xy/gog-xy-color-prefs.ui
@@ -0,0 +1,24 @@
+<?xml version="1.0"?>
+<interface>
+ <requires lib="gtk+" version="2.16"/>
+ <!-- interface-naming-policy toplevel-contextual -->
+ <object class="GtkTable" id="gog-xy-color-prefs">
+ <property name="visible">True</property>
+ <property name="border_width">12</property>
+ <property name="column_spacing">12</property>
+ <property name="row_spacing">6</property>
+ <child>
+ <object class="GtkCheckButton" id="hide-outliers">
+ <property name="label" translatable="yes">Hide data outside of color axis bounds</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="x_options"></property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ </object>
+</interface>
diff --git a/plugins/plot_xy/gog-xy-series-prefs.ui b/plugins/plot_xy/gog-xy-series-prefs.ui
new file mode 100644
index 0000000..d292b77
--- /dev/null
+++ b/plugins/plot_xy/gog-xy-series-prefs.ui
@@ -0,0 +1,26 @@
+<?xml version="1.0"?>
+<interface>
+ <requires lib="gtk+" version="2.16"/>
+ <!-- interface-naming-policy toplevel-contextual -->
+ <object class="GtkVBox" id="gog_xy_series_prefs">
+ <property name="visible">True</property>
+ <property name="border_width">12</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkCheckButton" id="invalid_as_zero">
+ <property name="label" translatable="yes">_Use nul value instead of invalid</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ </object>
+</interface>
diff --git a/plugins/plot_xy/gog-xy.c b/plugins/plot_xy/gog-xy.c
index 4938bb9..96a42ec 100644
--- a/plugins/plot_xy/gog-xy.c
+++ b/plugins/plot_xy/gog-xy.c
@@ -426,9 +426,9 @@ gog_bubble_plot_populate_editor (GogObject *obj,
G_GNUC_UNUSED GogDataAllocator *dalloc,
GOCmdContext *cc)
{
- go_editor_add_page (editor,
- gog_bubble_plot_pref (GOG_BUBBLE_PLOT (obj), cc),
- _("Properties"));
+ GtkWidget *w = gog_bubble_plot_pref (GOG_BUBBLE_PLOT (obj), cc);
+ go_editor_add_page (editor, w, _("Properties"));
+ g_object_unref (G_OBJECT (w));
(GOG_OBJECT_CLASS(bubble_parent_klass)->populate_editor) (obj, editor, dalloc, cc);
}
@@ -686,23 +686,23 @@ gog_xy_color_plot_populate_editor (GogObject *obj,
GOCmdContext *cc)
{
#ifdef GOFFICE_WITH_GTK
- GladeXML *gui;
+ GtkBuilder *gui;
char const *dir;
char *path;
dir = go_plugin_get_dir_name (go_plugins_get_plugin_by_id ("GOffice_plot_xy"));
- path = g_build_filename (dir, "gog-xy-color-prefs.glade", NULL);
- gui = go_glade_new (path, "gog-xy-color-prefs", GETTEXT_PACKAGE, cc);
+ path = g_build_filename (dir, "gog-xy-color-prefs.ui", NULL);
+ gui = go_gtk_builder_new (path, GETTEXT_PACKAGE, cc);
g_free (path);
if (gui != NULL) {
- GtkWidget *w = glade_xml_get_widget (gui, "hide-outliers");
+ GtkWidget *w = go_gtk_builder_get_widget (gui, "hide-outliers");
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (w),
(GOG_XY_COLOR_PLOT (obj))->hide_outliers);
g_signal_connect (G_OBJECT (w),
"toggled",
G_CALLBACK (hide_outliers_toggled_cb), obj);
- w = glade_xml_get_widget (gui, "gog-xy-color-prefs");
+ w = go_gtk_builder_get_widget (gui, "gog-xy-color-prefs");
go_editor_add_page (editor, w, _("Properties"));
g_object_unref (gui);
}
@@ -1743,15 +1743,15 @@ gog_xy_series_populate_editor (GogObject *obj,
GtkWidget *w;
char const *dir = go_plugin_get_dir_name (
go_plugins_get_plugin_by_id ("GOffice_plot_xy"));
- char *path = g_build_filename (dir, "gog-xy-series-prefs.glade", NULL);
- GladeXML *gui = go_glade_new (path, "gog_xy_series_prefs", GETTEXT_PACKAGE, cc);
+ char *path = g_build_filename (dir, "gog-xy-series-prefs.ui", NULL);
+ GtkBuilder *gui = go_gtk_builder_new (path, GETTEXT_PACKAGE, cc);
g_free (path);
(GOG_OBJECT_CLASS(series_parent_klass)->populate_editor) (obj, editor, dalloc, cc);
if (gui != NULL) {
- w = glade_xml_get_widget (gui, "invalid_as_zero");
+ w = go_gtk_builder_get_widget (gui, "invalid_as_zero");
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (w),
(GOG_XY_SERIES (obj))->invalid_as_zero);
g_signal_connect (G_OBJECT (w),
@@ -1759,17 +1759,18 @@ gog_xy_series_populate_editor (GogObject *obj,
G_CALLBACK (invalid_toggled_cb), obj);
series = GOG_XY_SERIES (obj);
- w = glade_xml_get_widget (gui, "gog_xy_series_prefs");
- g_object_set_data_full (G_OBJECT (w),
- "state", gui, (GDestroyNotify)g_object_unref);
+ w = go_gtk_builder_get_widget (gui, "gog_xy_series_prefs");
go_editor_add_page (editor, w, _("Details"));
+ g_object_unref (gui);
}
w = gog_error_bar_prefs (GOG_SERIES (obj), "x-errors", TRUE, dalloc, cc);
go_editor_add_page (editor, w, _("X error bars"));
+ g_object_unref (w);
w = gog_error_bar_prefs (GOG_SERIES (obj), "y-errors", FALSE, dalloc, cc);
go_editor_add_page (editor, w, _("Y error bars"));
+ g_object_unref (w);
}
#endif
diff --git a/plugins/reg_linear/Makefile.am b/plugins/reg_linear/Makefile.am
index 92d4f09..9bfea46 100644
--- a/plugins/reg_linear/Makefile.am
+++ b/plugins/reg_linear/Makefile.am
@@ -1,6 +1,6 @@
goffice_graph_linregdir = $(goffice_plugindir)/reg_linear
xmldir = $(goffice_graph_linregdir)
-gladedir = $(goffice_graph_linregdir)
+uidir = $(goffice_graph_linregdir)
goffice_graph_linreg_LTLIBRARIES = linreg.la
linreg_la_LDFLAGS = -module $(GOFFICE_PLUGIN_FLAGS)
diff --git a/plugins/reg_logfit/Makefile.am b/plugins/reg_logfit/Makefile.am
index 57300ac..fbe8774 100644
--- a/plugins/reg_logfit/Makefile.am
+++ b/plugins/reg_logfit/Makefile.am
@@ -1,6 +1,6 @@
goffice_graph_logfitdir = $(goffice_plugindir)/reg_logfit
xmldir = $(goffice_graph_logfitdir)
-gladedir = $(goffice_graph_logfitdir)
+uidir = $(goffice_graph_logfitdir)
goffice_graph_logfit_LTLIBRARIES = logfit.la
logfit_la_LDFLAGS = -module $(GOFFICE_PLUGIN_FLAGS)
diff --git a/plugins/smoothing/Makefile.am b/plugins/smoothing/Makefile.am
index 9ab88ed..3ac2029 100644
--- a/plugins/smoothing/Makefile.am
+++ b/plugins/smoothing/Makefile.am
@@ -1,6 +1,6 @@
goffice_graph_smoothingdir = $(goffice_plugindir)/smoothing
xmldir = $(goffice_graph_smoothingdir)
-gladedir = $(goffice_graph_smoothingdir)
+uidir = $(goffice_graph_smoothingdir)
goffice_graph_smoothing_LTLIBRARIES = smoothing.la
smoothing_la_LDFLAGS = -module $(GOFFICE_PLUGIN_FLAGS)
@@ -18,9 +18,9 @@ xml_DATA = $(xml_in_files:.xml.in=.xml)
@INTLTOOL_XML_RULE@
-dist_glade_DATA = \
- gog-moving-avg.glade \
- gog-exp-smooth.glade
+dist_ui_DATA = \
+ gog-moving-avg.ui \
+ gog-exp-smooth.ui
# do not use the intl-tool stuff to merge the text back
# its simpler to just use gettext directly
diff --git a/plugins/smoothing/gog-exp-smooth.c b/plugins/smoothing/gog-exp-smooth.c
index 8666812..dd88f16 100644
--- a/plugins/smoothing/gog-exp-smooth.c
+++ b/plugins/smoothing/gog-exp-smooth.c
@@ -57,16 +57,16 @@ gog_exp_smooth_populate_editor (GogObject *obj,
GogDataset *set = GOG_DATASET (obj);
char const *dir = go_plugin_get_dir_name (
go_plugins_get_plugin_by_id ("GOffice_smoothing"));
- char *path = g_build_filename (dir, "gog-exp-smooth.glade", NULL);
- GladeXML *gui = go_glade_new (path, "exp-smooth-prefs", GETTEXT_PACKAGE, cc);
- GtkWidget *label, *box, *w = glade_xml_get_widget (gui, "steps");
+ char *path = g_build_filename (dir, "gog-exp-smooth.ui", NULL);
+ GtkBuilder *gui = go_gtk_builder_new (path, GETTEXT_PACKAGE, cc);
+ GtkWidget *label, *box, *w = go_gtk_builder_get_widget (gui, "steps");
GtkTable *table;
go_widget_set_tooltip_text (w, _("Number of interpolation steps"));
gtk_spin_button_set_range (GTK_SPIN_BUTTON (w), 10, G_MAXINT);
gtk_spin_button_set_value (GTK_SPIN_BUTTON (w), es->steps);
g_signal_connect (G_OBJECT (w), "value-changed", G_CALLBACK (steps_changed_cb), obj);
- table = GTK_TABLE (glade_xml_get_widget (gui, "exp-smooth-prefs"));
+ table = GTK_TABLE (gtk_builder_get_object (gui, "exp-smooth-prefs"));
w = GTK_WIDGET (gog_data_allocator_editor (dalloc, set, 0, GOG_DATA_SCALAR));
box = gtk_event_box_new ();
gtk_container_add (GTK_CONTAINER (box), w);
@@ -75,11 +75,10 @@ gog_exp_smooth_populate_editor (GogObject *obj,
"default will be used"));
gtk_widget_show_all (box);
gtk_table_attach (table, box, 1, 2, 0, 1, GTK_FILL | GTK_EXPAND, 0, 0, 0);
- label = glade_xml_get_widget (gui, "period-lbl");
+ label = go_gtk_builder_get_widget (gui, "period-lbl");
g_object_set (G_OBJECT (label), "mnemonic-widget", w, NULL);
- g_object_set_data_full (G_OBJECT (table),
- "state", gui, (GDestroyNotify) g_object_unref);
go_editor_add_page (editor, table, _("Properties"));
+ g_object_unref (gui);
(GOG_OBJECT_CLASS (exp_smooth_parent_klass)->populate_editor) (obj, editor, dalloc, cc);
}
diff --git a/plugins/smoothing/gog-exp-smooth.ui b/plugins/smoothing/gog-exp-smooth.ui
new file mode 100644
index 0000000..203de97
--- /dev/null
+++ b/plugins/smoothing/gog-exp-smooth.ui
@@ -0,0 +1,68 @@
+<?xml version="1.0"?>
+<interface>
+ <requires lib="gtk+" version="2.16"/>
+ <!-- interface-naming-policy toplevel-contextual -->
+ <object class="GtkAdjustment" id="adjustment1">
+ <property name="value">100</property>
+ <property name="lower">10</property>
+ <property name="upper">10000</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkTable" id="exp-smooth-prefs">
+ <property name="visible">True</property>
+ <property name="border_width">12</property>
+ <property name="n_rows">2</property>
+ <property name="n_columns">2</property>
+ <property name="column_spacing">12</property>
+ <property name="row_spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="period-lbl">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="xpad">5</property>
+ <property name="label" translatable="yes">_Period:</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label2">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="xpad">5</property>
+ <property name="label" translatable="yes">_Steps:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">steps</property>
+ </object>
+ <packing>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="steps">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ <property name="adjustment">adjustment1</property>
+ <property name="climb_rate">1</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ </object>
+</interface>
diff --git a/plugins/smoothing/gog-moving-avg.c b/plugins/smoothing/gog-moving-avg.c
index f82756c..d2875b9 100644
--- a/plugins/smoothing/gog-moving-avg.c
+++ b/plugins/smoothing/gog-moving-avg.c
@@ -98,21 +98,20 @@ gog_moving_avg_populate_editor (GogObject *obj,
GogMovingAvg *ma = GOG_MOVING_AVG (obj);
char const *dir = go_plugin_get_dir_name (
go_plugins_get_plugin_by_id ("GOffice_smoothing"));
- char *path = g_build_filename (dir, "gog-moving-avg.glade", NULL);
- GladeXML *gui = go_glade_new (path, "mv-avg-prefs", GETTEXT_PACKAGE, cc);
- GtkWidget *w = glade_xml_get_widget (gui, "span");
+ char *path = g_build_filename (dir, "gog-moving-avg.ui", NULL);
+ GtkBuilder *gui = go_gtk_builder_new (path, GETTEXT_PACKAGE, cc);
+ GtkWidget *w = go_gtk_builder_get_widget (gui, "span");
go_widget_set_tooltip_text (w, _("Number of values from which to calculate an average"));
gtk_spin_button_set_range (GTK_SPIN_BUTTON (w), 2, G_MAXINT);
gtk_spin_button_set_value (GTK_SPIN_BUTTON (w), ma->span);
g_signal_connect (G_OBJECT (w), "value-changed", G_CALLBACK (span_changed_cb), obj);
- w = glade_xml_get_widget (gui, "xavg");
+ w = go_gtk_builder_get_widget (gui, "xavg");
go_widget_set_tooltip_text (w, _("Whether to average x values as well or use the last one"));
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (w), ma->xavg);
g_signal_connect (G_OBJECT (w), "toggled", G_CALLBACK (xavg_toggled_cb), obj);
- w = glade_xml_get_widget (gui, "mv-avg-prefs");
- g_object_set_data_full (G_OBJECT (w),
- "state", gui, (GDestroyNotify) g_object_unref);
+ w = go_gtk_builder_get_widget (gui, "mv-avg-prefs");
go_editor_add_page (editor, w, _("Properties"));
+ g_object_unref (gui);
(GOG_OBJECT_CLASS (moving_avg_parent_klass)->populate_editor) (obj, editor, dalloc, cc);
}
diff --git a/plugins/smoothing/gog-moving-avg.ui b/plugins/smoothing/gog-moving-avg.ui
new file mode 100644
index 0000000..afb4ef5
--- /dev/null
+++ b/plugins/smoothing/gog-moving-avg.ui
@@ -0,0 +1,72 @@
+<?xml version="1.0"?>
+<interface>
+ <requires lib="gtk+" version="2.16"/>
+ <!-- interface-naming-policy toplevel-contextual -->
+ <object class="GtkAdjustment" id="adjustment1">
+ <property name="value">2</property>
+ <property name="lower">2</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkVBox" id="mv-avg-prefs">
+ <property name="visible">True</property>
+ <property name="border_width">12</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkHBox" id="hbox1">
+ <property name="visible">True</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="label1">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Span:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">span</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="span">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ <property name="adjustment">adjustment1</property>
+ <property name="climb_rate">1</property>
+ <property name="numeric">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkCheckButton" id="xavg">
+ <property name="label" translatable="yes">_Use averaged abscissa</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+</interface>
diff --git a/po/ChangeLog b/po/ChangeLog
index 9f95b8a..bf1848b 100644
--- a/po/ChangeLog
+++ b/po/ChangeLog
@@ -1,3 +1,7 @@
+2009-08-26 Jean Brefort <jean brefort normalesup org>
+
+ * POTFILES.in: migrated from Glade to GtkBuilder.
+
2009-08-19 Jean Brefort <jean brefort normalesup org>
* POTFILES.in: updated file list.
diff --git a/po/POTFILES.in b/po/POTFILES.in
index 38d14f8..79d82e9 100644
--- a/po/POTFILES.in
+++ b/po/POTFILES.in
@@ -84,10 +84,10 @@ goffice/goffice-priv.h
goffice/goffice.c
goffice/goffice.h
goffice/graph/goffice-graph.h
-goffice/graph/gog-3d-box-prefs.glade
+[type: gettext/glade]goffice/graph/gog-3d-box-prefs.ui
goffice/graph/gog-3d-box.c
goffice/graph/gog-axis-line.c
-goffice/graph/gog-axis-prefs.glade
+[type: gettext/glade]goffice/graph/gog-axis-prefs.ui
goffice/graph/gog-axis.c
goffice/graph/gog-axis.h
goffice/graph/gog-chart-impl.h
@@ -97,26 +97,26 @@ goffice/graph/gog-data-allocator.c
goffice/graph/gog-data-allocator.h
goffice/graph/gog-data-set.c
goffice/graph/gog-data-set.h
-goffice/graph/gog-error-bar-prefs.glade
+[type: gettext/glade]goffice/graph/gog-error-bar-prefs.ui
goffice/graph/gog-error-bar.c
goffice/graph/gog-error-bar.h
goffice/graph/gog-graph-impl.h
-goffice/graph/gog-graph-prefs.glade
+[type: gettext/glade]goffice/graph/gog-graph-prefs.ui
goffice/graph/gog-graph.c
goffice/graph/gog-graph.h
goffice/graph/gog-grid-line.c
goffice/graph/gog-grid-line.h
goffice/graph/gog-grid.c
goffice/graph/gog-grid.h
-goffice/graph/gog-guru-type-selector.glade
+[type: gettext/glade]goffice/graph/gog-guru-type-selector.ui
goffice/graph/gog-guru.c
-goffice/graph/gog-guru.glade
+[type: gettext/glade]goffice/graph/gog-guru.ui
goffice/graph/gog-guru.h
goffice/graph/gog-label.c
goffice/graph/gog-label.h
goffice/graph/gog-legend.c
goffice/graph/gog-legend.h
-goffice/graph/gog-object-prefs.glade
+[type: gettext/glade]goffice/graph/gog-object-prefs.ui
goffice/graph/gog-object-xml.c
goffice/graph/gog-object-xml.h
goffice/graph/gog-object.c
@@ -126,16 +126,16 @@ goffice/graph/gog-outlined-object.h
goffice/graph/gog-plot-engine.c
goffice/graph/gog-plot-engine.h
goffice/graph/gog-plot-impl.h
-goffice/graph/gog-plot-prefs.glade
+[type: gettext/glade]goffice/graph/gog-plot-prefs.ui
goffice/graph/gog-plot.c
goffice/graph/gog-plot.h
-goffice/graph/gog-reg-curve-prefs.glade
+[type: gettext/glade]goffice/graph/gog-reg-curve-prefs.ui
goffice/graph/gog-reg-curve.c
-goffice/graph/gog-reg-eqn-prefs.glade
+[type: gettext/glade]goffice/graph/gog-reg-eqn-prefs.ui
goffice/graph/gog-renderer.c
goffice/graph/gog-renderer.h
goffice/graph/gog-series-impl.h
-goffice/graph/gog-series-prefs.glade
+[type: gettext/glade]goffice/graph/gog-series-prefs.ui
goffice/graph/gog-series.c
goffice/graph/gog-series.h
goffice/graph/gog-smoothed-curve.c
@@ -146,7 +146,7 @@ goffice/graph/gog-theme.h
goffice/graph/gog-trend-line.c
goffice/graph/gog-view.c
goffice/graph/gog-view.h
-goffice/gtk/go-3d-rotation-sel.glade
+[type: gettext/glade]goffice/gtk/go-3d-rotation-sel.ui
goffice/gtk/go-action-combo-color.c
goffice/gtk/go-action-combo-color.h
goffice/gtk/go-action-combo-pixmaps.c
@@ -171,20 +171,20 @@ goffice/gtk/go-combo-pixmaps.h
goffice/gtk/go-combo-text.c
goffice/gtk/go-combo-text.h
goffice/gtk/go-font-sel.c
-goffice/gtk/go-font-sel.glade
+[type: gettext/glade]goffice/gtk/go-font-sel.ui
goffice/gtk/go-font-sel.h
goffice/gtk/go-format-sel.c
-goffice/gtk/go-format-sel.glade
+[type: gettext/glade]goffice/gtk/go-format-sel.ui
goffice/gtk/go-format-sel.h
-goffice/gtk/go-image-save-dialog-extra.glade
-goffice/gtk/go-image-sel.glade
+[type: gettext/glade]goffice/gtk/go-image-save-dialog-extra.ui
+[type: gettext/glade]goffice/gtk/go-image-sel.ui
goffice/gtk/go-locale-sel.c
goffice/gtk/go-locale-sel.h
goffice/gtk/go-optionmenu.c
goffice/gtk/go-optionmenu.h
goffice/gtk/go-palette.c
goffice/gtk/go-rotation-sel.c
-goffice/gtk/go-rotation-sel.glade
+[type: gettext/glade]goffice/gtk/go-rotation-sel.ui
goffice/gtk/go-rotation-sel.h
goffice/gtk/goffice-gtk.c
goffice/gtk/goffice-gtk.h
@@ -238,7 +238,7 @@ goffice/utils/go-pattern.c
goffice/utils/go-pattern.h
goffice/utils/go-style.c
goffice/utils/go-style.h
-goffice/utils/go-style-prefs.glade
+[type: gettext/glade]goffice/utils/go-style-prefs.ui
goffice/utils/go-units.h
goffice/utils/goffice-utils.h
goffice/utils/regutf8.c
@@ -246,18 +246,18 @@ goffice/utils/regutf8.h
plugins/plot_barcol/gog-1.5d.c
plugins/plot_barcol/gog-1.5d.h
plugins/plot_barcol/gog-barcol-prefs.c
-plugins/plot_barcol/gog-barcol-prefs.glade
+[type: gettext/glade]plugins/plot_barcol/gog-barcol-prefs.ui
plugins/plot_barcol/gog-barcol.c
plugins/plot_barcol/gog-barcol.h
plugins/plot_barcol/gog-dropbar.c
plugins/plot_barcol/gog-line.c
plugins/plot_barcol/gog-line.h
-plugins/plot_barcol/gog-minmax-prefs.glade
+[type: gettext/glade]plugins/plot_barcol/gog-minmax-prefs.ui
plugins/plot_barcol/gog-minmax.c
plugins/plot_barcol/plot-types.xml.in
plugins/plot_barcol/plugin.xml.in
plugins/plot_distrib/go-distribution-prefs.c
-plugins/plot_distrib/gog-boxplot-prefs.glade
+[type: gettext/glade]plugins/plot_distrib/gog-boxplot-prefs.ui
plugins/plot_distrib/gog-boxplot.c
plugins/plot_distrib/gog-boxplot.h
plugins/plot_distrib/gog-histogram.c
@@ -265,16 +265,16 @@ plugins/plot_distrib/gog-probability-plot.c
plugins/plot_distrib/plot-types.xml.in
plugins/plot_distrib/plugin.xml.in
plugins/plot_pie/gog-pie-prefs.c
-plugins/plot_pie/gog-pie-prefs.glade
-plugins/plot_pie/gog-pie-series.glade
+[type: gettext/glade]plugins/plot_pie/gog-pie-prefs.ui
+[type: gettext/glade]plugins/plot_pie/gog-pie-series.ui
plugins/plot_pie/gog-pie.c
plugins/plot_pie/gog-pie.h
-plugins/plot_pie/gog-ring-prefs.glade
+[type: gettext/glade]plugins/plot_pie/gog-ring-prefs.ui
plugins/plot_pie/plot-types.xml.in
plugins/plot_pie/plugin.xml.in
plugins/plot_radar/gog-radar.c
plugins/plot_radar/gog-radar.h
-plugins/plot_radar/gog-color-polar-prefs.xml
+[type: gettext/glade]plugins/plot_radar/gog-color-polar-prefs.ui
plugins/plot_radar/plot-types.xml.in
plugins/plot_radar/plugin.xml.in
plugins/plot_surface/gog-contour.c
@@ -284,19 +284,19 @@ plugins/plot_surface/gog-surface.h
plugins/plot_surface/gog-xyz.c
plugins/plot_surface/gog-xyz.h
plugins/plot_surface/gog-xyz-prefs.c
-plugins/plot_surface/gog-xyz-prefs.glade
+[type: gettext/glade]plugins/plot_surface/gog-xyz-prefs.ui
plugins/plot_surface/gog-xyz-surface.c
plugins/plot_surface/gog-xyz-surface.h
plugins/plot_surface/gog-xyz-surface-prefs.c
-plugins/plot_surface/gog-xyz-surface-prefs.glade
+[type: gettext/glade]plugins/plot_surface/gog-xyz-surface-prefs.ui
plugins/plot_surface/plot-types.xml.in
plugins/plot_surface/plugin.xml.in
plugins/plot_surface/xl-surface.c
plugins/plot_surface/xl-surface.h
plugins/plot_xy/gog-bubble-prefs.c
-plugins/plot_xy/gog-bubble-prefs.glade
-plugins/plot_xy/gog-xy-series-prefs.glade
-plugins/plot_xy/gog-xy-color-prefs.glade
+[type: gettext/glade]plugins/plot_xy/gog-bubble-prefs.ui
+[type: gettext/glade]plugins/plot_xy/gog-xy-series-prefs.ui
+[type: gettext/glade]plugins/plot_xy/gog-xy-color-prefs.ui
plugins/plot_xy/gog-xy.c
plugins/plot_xy/gog-xy.h
plugins/plot_xy/plot-types.xml.in
@@ -313,9 +313,9 @@ plugins/reg_logfit/gog-logfit.c
plugins/reg_logfit/plugin.xml.in
plugins/reg_logfit/reg-types.xml.in
plugins/smoothing/gog-moving-avg.c
-plugins/smoothing/gog-moving-avg.glade
+[type: gettext/glade]plugins/smoothing/gog-moving-avg.ui
plugins/smoothing/gog-exp-smooth.c
-plugins/smoothing/gog-exp-smooth.glade
+[type: gettext/glade]plugins/smoothing/gog-exp-smooth.ui
plugins/smoothing/plugin.xml.in
plugins/smoothing/types.xml.in
-tests/go-demo.glade
+[type: gettext/glade]tests/go-demo.ui
diff --git a/tests/Makefile.am b/tests/Makefile.am
index 0625708..11f8e73 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -10,4 +10,4 @@ pie_demo_SOURCES = pie-demo.c
go_demo_LDADD = $(GOFFICE_PLUGIN_LIBADD)
go_demo_SOURCES = go-demo.c
-EXTRA_DIST = go-demo.glade
+EXTRA_DIST = go-demo.ui
diff --git a/tests/go-demo.c b/tests/go-demo.c
index af7e8d8..4050f25 100644
--- a/tests/go-demo.c
+++ b/tests/go-demo.c
@@ -22,7 +22,6 @@
#include <glib.h>
#include <strings.h>
#include <gtk/gtk.h>
-#include <glade/glade.h>
#include <goffice/goffice.h>
#include <goffice/app/go-plugin.h>
@@ -35,14 +34,15 @@
#include <goffice/graph/gog-series.h>
#include <goffice/utils/go-style.h>
#include <goffice/utils/go-styled-object.h>
+#include <goffice/gtk/goffice-gtk.h>
#include <goffice/gtk/go-graph-widget.h>
typedef struct _GoDemoPrivate GODemoPrivate;
struct _GoDemoPrivate {
GtkWidget *toplevel;
- GladeXML *xml;
+ GtkBuilder *xml;
- GtkWidget *menu_item_quit;
+ GtkAction *menu_item_quit;
GtkWidget *btn_regen;
GtkWidget *notebook_charts;
GtkWidget *notebook_data;
@@ -314,17 +314,16 @@ init_data_widgets (GODemoPrivate *priv)
char *wname = NULL;
for (i =0; i< 6; i++) {
- GtkSpinButton *spbutton;
/* init legend widgets */
g_free (wname);
wname = g_strdup_printf ("entry_legend_%d", i+1);
- priv->entry_legend[i] = GTK_ENTRY (glade_xml_get_widget (
+ priv->entry_legend[i] = GTK_ENTRY (gtk_builder_get_object (
priv->xml, wname));
gtk_entry_set_text (priv->entry_legend[i], legends[i]);
/* init value widgets */
g_free (wname);
wname = g_strdup_printf ("spb_value_%d", i+1);
- priv->spb_value[i] = GTK_SPIN_BUTTON (glade_xml_get_widget (
+ priv->spb_value[i] = GTK_SPIN_BUTTON (gtk_builder_get_object (
priv->xml, wname));
gtk_spin_button_set_value (priv->spb_value[i], values[i]);
g_signal_connect(priv->spb_value[i], "value-changed",
@@ -332,7 +331,7 @@ init_data_widgets (GODemoPrivate *priv)
/* init index widgets */
g_free (wname);
wname = g_strdup_printf ("spb_index_%d", i+1);
- priv->spb_index[i] = GTK_SPIN_BUTTON (glade_xml_get_widget (
+ priv->spb_index[i] = GTK_SPIN_BUTTON (gtk_builder_get_object (
priv->xml, wname));
gtk_spin_button_set_value (priv->spb_index[i], indexs[i]);
g_signal_connect (priv->spb_index[i], "value-changed",
@@ -340,7 +339,7 @@ init_data_widgets (GODemoPrivate *priv)
/* init angle widgets */
g_free (wname);
wname = g_strdup_printf ("spb_angle_%d", i+1);
- priv->spb_angle[i] = GTK_SPIN_BUTTON (glade_xml_get_widget (
+ priv->spb_angle[i] = GTK_SPIN_BUTTON (gtk_builder_get_object (
priv->xml, wname));
gtk_spin_button_set_value (priv->spb_angle[i], angles[i]);
g_signal_connect (priv->spb_angle[i], "value-changed",
@@ -348,7 +347,7 @@ init_data_widgets (GODemoPrivate *priv)
/* init start widgets */
g_free (wname);
wname = g_strdup_printf ("spb_start_%d", i+1);
- priv->spb_start[i] = GTK_SPIN_BUTTON (glade_xml_get_widget (
+ priv->spb_start[i] = GTK_SPIN_BUTTON (gtk_builder_get_object (
priv->xml, wname));
gtk_spin_button_set_value (priv->spb_start[i], starts[i]);
g_signal_connect (priv->spb_start[i], "value-changed",
@@ -359,7 +358,7 @@ init_data_widgets (GODemoPrivate *priv)
/* init start widgets */
g_free (wname);
wname = g_strdup_printf ("spb_matrix_%d", i+1);
- priv->spb_matrix[i] = GTK_SPIN_BUTTON (glade_xml_get_widget (
+ priv->spb_matrix[i] = GTK_SPIN_BUTTON (gtk_builder_get_object (
priv->xml, wname));
gtk_spin_button_set_value (priv->spb_matrix[i], matrix[i]);
g_signal_connect (priv->spb_matrix[i], "value-changed",
@@ -455,7 +454,7 @@ main (int argc, char *argv[])
{
GtkWidget *window;
GODemoPrivate *priv;
- const gchar *glade_file;
+ const gchar *ui_file;
gtk_init (&argc, &argv);
/* Initialize libgoffice */
@@ -470,33 +469,34 @@ main (int argc, char *argv[])
g_signal_connect (window, "destroy", gtk_main_quit, NULL);
priv = g_new0 (GODemoPrivate, 1);
-#define GO_DEMO_GLADE "go-demo.glade"
- glade_file = "./" GO_DEMO_GLADE;
- if (!g_file_test (glade_file, G_FILE_TEST_EXISTS))
- glade_file = "../" GO_DEMO_GLADE;
- if (!g_file_test (glade_file, G_FILE_TEST_EXISTS)) {
- g_warning ("Unable to load file %s", GO_DEMO_GLADE);
+#define GO_DEMO_UI "go-demo.ui"
+ ui_file = "./" GO_DEMO_UI;
+ if (!g_file_test (ui_file, G_FILE_TEST_EXISTS))
+ ui_file = "../" GO_DEMO_UI;
+ if (!g_file_test (ui_file, G_FILE_TEST_EXISTS)) {
+ g_warning ("Unable to load file %s", GO_DEMO_UI);
return 0;
}
- priv->xml = glade_xml_new (glade_file, "toplevel", NULL);
+ priv->xml = gtk_builder_new ();
+ gtk_builder_add_from_file (priv->xml, ui_file, NULL);
#undef GO_DEMO_GLADE
- priv->toplevel = glade_xml_get_widget (priv->xml, "toplevel");
+ priv->toplevel = go_gtk_builder_get_widget (priv->xml, "toplevel");
gtk_container_add (GTK_CONTAINER (window), priv->toplevel);
- priv->menu_item_quit = glade_xml_get_widget (priv->xml, "menu_item_quit");
+ priv->menu_item_quit = GTK_ACTION (gtk_builder_get_object (priv->xml, "menu_item_quit"));
g_signal_connect (priv->menu_item_quit, "activate",
G_CALLBACK (on_quit), window);
- priv->btn_regen = glade_xml_get_widget (priv->xml, "btn_regen");
+ priv->btn_regen = go_gtk_builder_get_widget (priv->xml, "btn_regen");
g_signal_connect (priv->btn_regen, "clicked",
G_CALLBACK (btn_regen_clicked), priv);
- priv->notebook_data = glade_xml_get_widget (priv->xml, "notebook_data");
+ priv->notebook_data = go_gtk_builder_get_widget (priv->xml, "notebook_data");
init_data_widgets (priv);
gtk_notebook_set_current_page (GTK_NOTEBOOK (priv->notebook_data), 1);
- priv->notebook_charts = glade_xml_get_widget (priv->xml, "notebook_charts");
+ priv->notebook_charts = go_gtk_builder_get_widget (priv->xml, "notebook_charts");
generate_all_charts (GTK_NOTEBOOK (priv->notebook_charts));
gtk_widget_show_all (GTK_WIDGET (window));
diff --git a/tests/go-demo.glade b/tests/go-demo.ui
similarity index 62%
rename from tests/go-demo.glade
rename to tests/go-demo.ui
index d6a95e1..d871cde 100644
--- a/tests/go-demo.glade
+++ b/tests/go-demo.ui
@@ -1,191 +1,544 @@
-<?xml version="1.0" encoding="UTF-8" standalone="no"?>
-<!DOCTYPE glade-interface SYSTEM "glade-2.0.dtd">
+<?xml version="1.0"?>
<!--Generated with glade3 3.4.5 on Thu Aug 21 17:20:22 2008 -->
-<glade-interface>
- <widget class="GtkWindow" id="GoDemoWindow">
+<interface>
+ <object class="GtkAdjustment" id="adjustment1">
+ <property name="upper">10000</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">10</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment10">
+ <property name="upper">100</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">4</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment11">
+ <property name="upper">100</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">5</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment12">
+ <property name="upper">100</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">6</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment13">
+ <property name="upper">360</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">0</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment14">
+ <property name="upper">360</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">30</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment15">
+ <property name="upper">360</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">80</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment16">
+ <property name="upper">360</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">180</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment17">
+ <property name="upper">360</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">250</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment18">
+ <property name="upper">360</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">300</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment19">
+ <property name="upper">10000</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">1</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment2">
+ <property name="upper">10000</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">20</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment20">
+ <property name="upper">10000</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">2</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment21">
+ <property name="upper">10000</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">3</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment22">
+ <property name="upper">10000</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">4</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment23">
+ <property name="upper">10000</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">5</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment24">
+ <property name="upper">10000</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">6</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment25">
+ <property name="upper">10000</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">10</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment26">
+ <property name="upper">10000</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">20</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment27">
+ <property name="upper">10000</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">30</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment28">
+ <property name="upper">10000</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">40</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment29">
+ <property name="upper">10000</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">50</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment3">
+ <property name="upper">10000</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">30</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment30">
+ <property name="upper">10000</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">60</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment31">
+ <property name="upper">10000</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">70</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment32">
+ <property name="upper">10000</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">80</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment33">
+ <property name="upper">10000</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">90</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment34">
+ <property name="upper">10000</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">100</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment35">
+ <property name="upper">10000</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">110</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment36">
+ <property name="upper">10000</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">120</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment37">
+ <property name="upper">10000</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">110</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment38">
+ <property name="upper">10000</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">120</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment39">
+ <property name="upper">10000</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">130</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment4">
+ <property name="upper">10000</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">40</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment40">
+ <property name="upper">10000</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">140</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment41">
+ <property name="upper">10000</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">150</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment42">
+ <property name="upper">10000</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">160</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment43">
+ <property name="upper">10000</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">170</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment44">
+ <property name="upper">10000</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">180</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment5">
+ <property name="upper">10000</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">50</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment6">
+ <property name="upper">10000</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">60</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment7">
+ <property name="upper">100</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">1</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment8">
+ <property name="upper">100</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">2</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment9">
+ <property name="upper">100</property>
+ <property name="lower">0</property>
+ <property name="page_increment">10</property>
+ <property name="step_increment">1</property>
+ <property name="page_size">0</property>
+ <property name="value">3</property>
+ </object>
+ <object class="GtkUIManager" id="uimanager1">
<child>
- <widget class="GtkVBox" id="toplevel">
+ <object class="GtkActionGroup" id="actiongroup1">
+ <child>
+ <object class="GtkAction" id="menuitem1">
+ <property name="name">menuitem1</property>
+ <property name="label" translatable="yes">_File</property>
+ </object>
+ </child>
+ <child>
+ <object class="GtkAction" id="menu_item_quit">
+ <property name="stock_id" translatable="yes">gtk-quit</property>
+ <property name="name">menu_item_quit</property>
+ </object>
+ </child>
+ </object>
+ </child>
+ <ui>
+ <menubar name="menubar1">
+ <menu action="menuitem1">
+ <menuitem action="menu_item_quit"/>
+ </menu>
+ </menubar>
+ </ui>
+ </object>
+ <object class="GtkVBox" id="toplevel">
<property name="visible">True</property>
<child>
- <widget class="GtkMenuBar" id="menubar1">
+ <object class="GtkMenuBar" constructor="uimanager1" id="menubar1">
<property name="visible">True</property>
- <child>
- <widget class="GtkMenuItem" id="menuitem1">
- <property name="visible">True</property>
- <property name="label" translatable="yes">_File</property>
- <property name="use_underline">True</property>
- <child>
- <widget class="GtkMenu" id="menu1">
- <property name="visible">True</property>
- <child>
- <widget class="GtkImageMenuItem" id="menu_item_quit">
- <property name="visible">True</property>
- <property name="label" translatable="yes">gtk-quit</property>
- <property name="use_underline">True</property>
- <property name="use_stock">True</property>
- </widget>
- </child>
- </widget>
- </child>
- </widget>
- </child>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
</packing>
</child>
<child>
- <widget class="GtkVPaned" id="vpaned1">
+ <object class="GtkVPaned" id="vpaned1">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="position">550</property>
<child>
- <widget class="GtkNotebook" id="notebook_charts">
+ <object class="GtkNotebook" id="notebook_charts">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="scrollable">True</property>
- </widget>
+ </object>
<packing>
<property name="resize">False</property>
<property name="shrink">True</property>
</packing>
</child>
<child>
- <widget class="GtkVBox" id="vbox1">
+ <object class="GtkVBox" id="vbox1">
<property name="visible">True</property>
<child>
- <widget class="GtkHBox" id="hbox21">
+ <object class="GtkHBox" id="hbox21">
<property name="visible">True</property>
<child>
- <widget class="GtkLabel" id="label31">
+ <object class="GtkLabel" id="label31">
<property name="visible">True</property>
- <property name="label" translatable="yes">Click "Regenreate Charts" if you change the data.</property>
+ <property name="label" translatable="yes">Click "Regenerate Charts" if you change the data.</property>
<property name="justify">GTK_JUSTIFY_CENTER</property>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
</packing>
</child>
<child>
- <widget class="GtkHButtonBox" id="hbuttonbox1">
+ <object class="GtkHButtonBox" id="hbuttonbox1">
<property name="visible">True</property>
<property name="layout_style">GTK_BUTTONBOX_END</property>
<child>
- <widget class="GtkButton" id="btn_regen">
+ <object class="GtkButton" id="btn_regen">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="label" translatable="yes">Regenerate Charts</property>
- <property name="response_id">0</property>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
<property name="pack_type">GTK_PACK_END</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="position">1</property>
</packing>
</child>
- </widget>
+ </object>
</child>
<child>
- <widget class="GtkNotebook" id="notebook_data">
+ <object class="GtkNotebook" id="notebook_data">
<property name="visible">True</property>
<property name="can_focus">True</property>
<child>
- <widget class="GtkVBox" id="vbox2">
+ <object class="GtkVBox" id="vbox2">
<property name="visible">True</property>
<child>
- <widget class="GtkHBox" id="hbox1">
+ <object class="GtkHBox" id="hbox1">
<property name="visible">True</property>
<child>
- <widget class="GtkLabel" id="label4">
+ <object class="GtkLabel" id="label4">
<property name="visible">True</property>
<property name="label" translatable="yes">1:</property>
- </widget>
+ </object>
</child>
<child>
- <widget class="GtkEntry" id="entry_legend_1">
+ <object class="GtkEntry" id="entry_legend_1">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="editable">False</property>
<property name="text" translatable="yes">first</property>
- </widget>
+ </object>
<packing>
<property name="position">1</property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label5">
+ <object class="GtkLabel" id="label5">
<property name="visible">True</property>
<property name="label" translatable="yes">2:</property>
- </widget>
+ </object>
<packing>
<property name="position">2</property>
</packing>
</child>
<child>
- <widget class="GtkEntry" id="entry_legend_2">
+ <object class="GtkEntry" id="entry_legend_2">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="editable">False</property>
<property name="text" translatable="yes">second</property>
- </widget>
+ </object>
<packing>
<property name="position">3</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
</packing>
</child>
<child>
- <widget class="GtkHBox" id="hbox2">
+ <object class="GtkHBox" id="hbox2">
<property name="visible">True</property>
<child>
- <widget class="GtkLabel" id="label6">
+ <object class="GtkLabel" id="label6">
<property name="visible">True</property>
<property name="label" translatable="yes">3:</property>
- </widget>
+ </object>
</child>
<child>
- <widget class="GtkEntry" id="entry_legend_3">
+ <object class="GtkEntry" id="entry_legend_3">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="editable">False</property>
<property name="text" translatable="yes">third</property>
- </widget>
+ </object>
<packing>
<property name="position">1</property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label7">
+ <object class="GtkLabel" id="label7">
<property name="visible">True</property>
<property name="label" translatable="yes">4:</property>
- </widget>
+ </object>
<packing>
<property name="position">2</property>
</packing>
</child>
<child>
- <widget class="GtkEntry" id="entry_legend_4">
+ <object class="GtkEntry" id="entry_legend_4">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="editable">False</property>
<property name="text" translatable="yes">fourth</property>
- </widget>
+ </object>
<packing>
<property name="position">3</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
@@ -193,46 +546,46 @@
</packing>
</child>
<child>
- <widget class="GtkHBox" id="hbox3">
+ <object class="GtkHBox" id="hbox3">
<property name="visible">True</property>
<child>
- <widget class="GtkLabel" id="label8">
+ <object class="GtkLabel" id="label8">
<property name="visible">True</property>
<property name="label" translatable="yes">5:</property>
- </widget>
+ </object>
</child>
<child>
- <widget class="GtkEntry" id="entry_legend_5">
+ <object class="GtkEntry" id="entry_legend_5">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="editable">False</property>
<property name="text" translatable="yes">fifth</property>
- </widget>
+ </object>
<packing>
<property name="position">1</property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label9">
+ <object class="GtkLabel" id="label9">
<property name="visible">True</property>
<property name="label" translatable="yes">6:</property>
- </widget>
+ </object>
<packing>
<property name="position">2</property>
</packing>
</child>
<child>
- <widget class="GtkEntry" id="entry_legend_6">
+ <object class="GtkEntry" id="entry_legend_6">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="editable">False</property>
<property name="text" translatable="yes">sixth</property>
- </widget>
+ </object>
<packing>
<property name="position">3</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
@@ -240,118 +593,117 @@
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label64">
+ <object class="GtkLabel" id="label64">
<property name="visible">True</property>
<property name="label" translatable="yes">Legends can not be changed</property>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
<property name="position">3</property>
</packing>
</child>
- </widget>
+ </object>
</child>
- <child>
- <widget class="GtkLabel" id="label10">
+ <child type="tab">
+ <object class="GtkLabel" id="label10">
<property name="visible">True</property>
<property name="label" translatable="yes">Legends</property>
- </widget>
+ </object>
<packing>
- <property name="type">tab</property>
<property name="tab_fill">False</property>
</packing>
</child>
<child>
- <widget class="GtkVBox" id="vbox3">
+ <object class="GtkVBox" id="vbox3">
<property name="visible">True</property>
<child>
- <widget class="GtkHBox" id="hbox4">
+ <object class="GtkHBox" id="hbox4">
<property name="visible">True</property>
<child>
- <widget class="GtkLabel" id="label11">
+ <object class="GtkLabel" id="label11">
<property name="visible">True</property>
<property name="label" translatable="yes">1:</property>
- </widget>
+ </object>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_value_1">
+ <object class="GtkSpinButton" id="spb_value_1">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">10 0 10000 1 10 0</property>
+ <property name="adjustment">adjustment1</property>
<property name="digits">1</property>
- </widget>
+ </object>
<packing>
<property name="position">1</property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label12">
+ <object class="GtkLabel" id="label12">
<property name="visible">True</property>
<property name="label" translatable="yes">2:</property>
- </widget>
+ </object>
<packing>
<property name="position">2</property>
</packing>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_value_2">
+ <object class="GtkSpinButton" id="spb_value_2">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">20 0 10000 1 10 0</property>
+ <property name="adjustment">adjustment2</property>
<property name="digits">1</property>
- </widget>
+ </object>
<packing>
<property name="position">3</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
</packing>
</child>
<child>
- <widget class="GtkHBox" id="hbox5">
+ <object class="GtkHBox" id="hbox5">
<property name="visible">True</property>
<child>
- <widget class="GtkLabel" id="label13">
+ <object class="GtkLabel" id="label13">
<property name="visible">True</property>
<property name="label" translatable="yes">3:</property>
- </widget>
+ </object>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_value_3">
+ <object class="GtkSpinButton" id="spb_value_3">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">30 0 10000 1 10 0</property>
+ <property name="adjustment">adjustment3</property>
<property name="digits">1</property>
- </widget>
+ </object>
<packing>
<property name="position">1</property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label14">
+ <object class="GtkLabel" id="label14">
<property name="visible">True</property>
<property name="label" translatable="yes">4:</property>
- </widget>
+ </object>
<packing>
<property name="position">2</property>
</packing>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_value_4">
+ <object class="GtkSpinButton" id="spb_value_4">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">40 0 10000 1 10 0</property>
+ <property name="adjustment">adjustment4</property>
<property name="digits">1</property>
- </widget>
+ </object>
<packing>
<property name="position">3</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
@@ -359,154 +711,150 @@
</packing>
</child>
<child>
- <widget class="GtkHBox" id="hbox6">
+ <object class="GtkHBox" id="hbox6">
<property name="visible">True</property>
<child>
- <widget class="GtkLabel" id="label15">
+ <object class="GtkLabel" id="label15">
<property name="visible">True</property>
<property name="label" translatable="yes">5:</property>
- </widget>
+ </object>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_value_5">
+ <object class="GtkSpinButton" id="spb_value_5">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">50 0 10000 1 10 0</property>
+ <property name="adjustment">adjustment5</property>
<property name="digits">1</property>
- </widget>
+ </object>
<packing>
<property name="position">1</property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label16">
+ <object class="GtkLabel" id="label16">
<property name="visible">True</property>
<property name="label" translatable="yes">6:</property>
- </widget>
+ </object>
<packing>
<property name="position">2</property>
</packing>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_value_6">
+ <object class="GtkSpinButton" id="spb_value_6">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">60 0 10000 1 10 0</property>
+ <property name="adjustment">adjustment6</property>
<property name="digits">1</property>
- </widget>
+ </object>
<packing>
<property name="position">3</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
<property name="position">2</property>
</packing>
</child>
- </widget>
- <packing>
- <property name="position">1</property>
- </packing>
+ </object>
</child>
- <child>
- <widget class="GtkLabel" id="label17">
+ <child type="tab">
+ <object class="GtkLabel" id="label17">
<property name="visible">True</property>
<property name="label" translatable="yes">Values</property>
- </widget>
+ </object>
<packing>
- <property name="type">tab</property>
<property name="position">1</property>
<property name="tab_fill">False</property>
</packing>
</child>
<child>
- <widget class="GtkVBox" id="vbox4">
+ <object class="GtkVBox" id="vbox4">
<property name="visible">True</property>
<child>
- <widget class="GtkHBox" id="hbox7">
+ <object class="GtkHBox" id="hbox7">
<property name="visible">True</property>
<child>
- <widget class="GtkLabel" id="label18">
+ <object class="GtkLabel" id="label18">
<property name="visible">True</property>
<property name="label" translatable="yes">1:</property>
- </widget>
+ </object>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_index_1">
+ <object class="GtkSpinButton" id="spb_index_1">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">1 0 100 1 10 0</property>
- </widget>
+ <property name="adjustment">adjustment7</property>
+ </object>
<packing>
<property name="position">1</property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label19">
+ <object class="GtkLabel" id="label19">
<property name="visible">True</property>
<property name="label" translatable="yes">2:</property>
- </widget>
+ </object>
<packing>
<property name="position">2</property>
</packing>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_index_2">
+ <object class="GtkSpinButton" id="spb_index_2">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">2 0 100 1 10 0</property>
- </widget>
+ <property name="adjustment">adjustment8</property>
+ </object>
<packing>
<property name="position">3</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
</packing>
</child>
<child>
- <widget class="GtkHBox" id="hbox8">
+ <object class="GtkHBox" id="hbox8">
<property name="visible">True</property>
<child>
- <widget class="GtkLabel" id="label20">
+ <object class="GtkLabel" id="label20">
<property name="visible">True</property>
<property name="label" translatable="yes">3:</property>
- </widget>
+ </object>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_index_3">
+ <object class="GtkSpinButton" id="spb_index_3">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">3 0 100 1 10 0</property>
- </widget>
+ <property name="adjustment">adjustment9</property>
+ </object>
<packing>
<property name="position">1</property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label21">
+ <object class="GtkLabel" id="label21">
<property name="visible">True</property>
<property name="label" translatable="yes">4:</property>
- </widget>
+ </object>
<packing>
<property name="position">2</property>
</packing>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_index_4">
+ <object class="GtkSpinButton" id="spb_index_4">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">4 0 100 1 10 0</property>
- </widget>
+ <property name="adjustment">adjustment10</property>
+ </object>
<packing>
<property name="position">3</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
@@ -514,44 +862,44 @@
</packing>
</child>
<child>
- <widget class="GtkHBox" id="hbox9">
+ <object class="GtkHBox" id="hbox9">
<property name="visible">True</property>
<child>
- <widget class="GtkLabel" id="label22">
+ <object class="GtkLabel" id="label22">
<property name="visible">True</property>
<property name="label" translatable="yes">5:</property>
- </widget>
+ </object>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_index_5">
+ <object class="GtkSpinButton" id="spb_index_5">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">5 0 100 1 10 0</property>
- </widget>
+ <property name="adjustment">adjustment11</property>
+ </object>
<packing>
<property name="position">1</property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label23">
+ <object class="GtkLabel" id="label23">
<property name="visible">True</property>
<property name="label" translatable="yes">6:</property>
- </widget>
+ </object>
<packing>
<property name="position">2</property>
</packing>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_index_6">
+ <object class="GtkSpinButton" id="spb_index_6">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">6 0 100 1 10 0</property>
- </widget>
+ <property name="adjustment">adjustment12</property>
+ </object>
<packing>
<property name="position">3</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
@@ -559,120 +907,116 @@
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label35">
+ <object class="GtkLabel" id="label35">
<property name="visible">True</property>
<property name="label" translatable="yes">Only used for:
GogHistogramPlot, GogXYPlot, GogBubblePlot,
GogXYColorPlot, GogContourPlot, GogSurfacePlot</property>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
<property name="position">3</property>
</packing>
</child>
- </widget>
- <packing>
- <property name="position">2</property>
- </packing>
+ </object>
</child>
- <child>
- <widget class="GtkLabel" id="label24">
+ <child type="tab">
+ <object class="GtkLabel" id="label24">
<property name="visible">True</property>
<property name="label" translatable="yes">Indexs</property>
- </widget>
+ </object>
<packing>
- <property name="type">tab</property>
<property name="position">2</property>
<property name="tab_fill">False</property>
</packing>
</child>
<child>
- <widget class="GtkVBox" id="vbox5">
+ <object class="GtkVBox" id="vbox5">
<property name="visible">True</property>
<child>
- <widget class="GtkHBox" id="hbox10">
+ <object class="GtkHBox" id="hbox10">
<property name="visible">True</property>
<child>
- <widget class="GtkLabel" id="label25">
+ <object class="GtkLabel" id="label25">
<property name="visible">True</property>
<property name="label" translatable="yes">1:</property>
- </widget>
+ </object>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_angle_1">
+ <object class="GtkSpinButton" id="spb_angle_1">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">0 0 360 1 10 0</property>
- </widget>
+ <property name="adjustment">adjustment13</property>
+ </object>
<packing>
<property name="position">1</property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label26">
+ <object class="GtkLabel" id="label26">
<property name="visible">True</property>
<property name="label" translatable="yes">2:</property>
- </widget>
+ </object>
<packing>
<property name="position">2</property>
</packing>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_angle_2">
+ <object class="GtkSpinButton" id="spb_angle_2">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">30 0 360 1 10 0</property>
- </widget>
+ <property name="adjustment">adjustment14</property>
+ </object>
<packing>
<property name="position">3</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
</packing>
</child>
<child>
- <widget class="GtkHBox" id="hbox11">
+ <object class="GtkHBox" id="hbox11">
<property name="visible">True</property>
<child>
- <widget class="GtkLabel" id="label27">
+ <object class="GtkLabel" id="label27">
<property name="visible">True</property>
<property name="label" translatable="yes">3:</property>
- </widget>
+ </object>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_angle_3">
+ <object class="GtkSpinButton" id="spb_angle_3">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">80 0 360 1 10 0</property>
- </widget>
+ <property name="adjustment">adjustment15</property>
+ </object>
<packing>
<property name="position">1</property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label28">
+ <object class="GtkLabel" id="label28">
<property name="visible">True</property>
<property name="label" translatable="yes">4:</property>
- </widget>
+ </object>
<packing>
<property name="position">2</property>
</packing>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_angle_4">
+ <object class="GtkSpinButton" id="spb_angle_4">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">180 0 360 1 10 0</property>
- </widget>
+ <property name="adjustment">adjustment16</property>
+ </object>
<packing>
<property name="position">3</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
@@ -680,44 +1024,44 @@ GogXYColorPlot, GogContourPlot, GogSurfacePlot</property>
</packing>
</child>
<child>
- <widget class="GtkHBox" id="hbox12">
+ <object class="GtkHBox" id="hbox12">
<property name="visible">True</property>
<child>
- <widget class="GtkLabel" id="label29">
+ <object class="GtkLabel" id="label29">
<property name="visible">True</property>
<property name="label" translatable="yes">5:</property>
- </widget>
+ </object>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_angle_5">
+ <object class="GtkSpinButton" id="spb_angle_5">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">250 0 360 1 10 0</property>
- </widget>
+ <property name="adjustment">adjustment17</property>
+ </object>
<packing>
<property name="position">1</property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label30">
+ <object class="GtkLabel" id="label30">
<property name="visible">True</property>
<property name="label" translatable="yes">6:</property>
- </widget>
+ </object>
<packing>
<property name="position">2</property>
</packing>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_angle_6">
+ <object class="GtkSpinButton" id="spb_angle_6">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">300 0 360 1 10 0</property>
- </widget>
+ <property name="adjustment">adjustment18</property>
+ </object>
<packing>
<property name="position">3</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
@@ -725,122 +1069,118 @@ GogXYColorPlot, GogContourPlot, GogSurfacePlot</property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label36">
+ <object class="GtkLabel" id="label36">
<property name="visible">True</property>
<property name="label" translatable="yes">Only used for: GogPolarPlot</property>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
<property name="position">3</property>
</packing>
</child>
- </widget>
- <packing>
- <property name="position">3</property>
- </packing>
+ </object>
</child>
- <child>
- <widget class="GtkLabel" id="label">
+ <child type="tab">
+ <object class="GtkLabel" id="label">
<property name="visible">True</property>
<property name="label" translatable="yes">Angles</property>
- </widget>
+ </object>
<packing>
- <property name="type">tab</property>
<property name="position">3</property>
<property name="tab_fill">False</property>
</packing>
</child>
<child>
- <widget class="GtkVBox" id="vbox6">
+ <object class="GtkVBox" id="vbox6">
<property name="visible">True</property>
<child>
- <widget class="GtkHBox" id="hbox13">
+ <object class="GtkHBox" id="hbox13">
<property name="visible">True</property>
<child>
- <widget class="GtkLabel" id="label32">
+ <object class="GtkLabel" id="label32">
<property name="visible">True</property>
<property name="label" translatable="yes">1:</property>
- </widget>
+ </object>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_start_1">
+ <object class="GtkSpinButton" id="spb_start_1">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">1 0 10000 1 10 0</property>
+ <property name="adjustment">adjustment19</property>
<property name="digits">1</property>
- </widget>
+ </object>
<packing>
<property name="position">1</property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label33">
+ <object class="GtkLabel" id="label33">
<property name="visible">True</property>
<property name="label" translatable="yes">2:</property>
- </widget>
+ </object>
<packing>
<property name="position">2</property>
</packing>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_start_2">
+ <object class="GtkSpinButton" id="spb_start_2">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">2 0 10000 1 10 0</property>
+ <property name="adjustment">adjustment20</property>
<property name="digits">1</property>
- </widget>
+ </object>
<packing>
<property name="position">3</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
</packing>
</child>
<child>
- <widget class="GtkHBox" id="hbox14">
+ <object class="GtkHBox" id="hbox14">
<property name="visible">True</property>
<child>
- <widget class="GtkLabel" id="label34">
+ <object class="GtkLabel" id="label34">
<property name="visible">True</property>
<property name="label" translatable="yes">3:</property>
- </widget>
+ </object>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_start_3">
+ <object class="GtkSpinButton" id="spb_start_3">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">3 0 10000 1 10 0</property>
+ <property name="adjustment">adjustment21</property>
<property name="digits">1</property>
- </widget>
+ </object>
<packing>
<property name="position">1</property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label37">
+ <object class="GtkLabel" id="label37">
<property name="visible">True</property>
<property name="label" translatable="yes">4:</property>
- </widget>
+ </object>
<packing>
<property name="position">2</property>
</packing>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_start_4">
+ <object class="GtkSpinButton" id="spb_start_4">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">4 0 10000 1 10 0</property>
+ <property name="adjustment">adjustment22</property>
<property name="digits">1</property>
- </widget>
+ </object>
<packing>
<property name="position">3</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
@@ -848,46 +1188,46 @@ GogXYColorPlot, GogContourPlot, GogSurfacePlot</property>
</packing>
</child>
<child>
- <widget class="GtkHBox" id="hbox15">
+ <object class="GtkHBox" id="hbox15">
<property name="visible">True</property>
<child>
- <widget class="GtkLabel" id="label38">
+ <object class="GtkLabel" id="label38">
<property name="visible">True</property>
<property name="label" translatable="yes">5:</property>
- </widget>
+ </object>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_start_5">
+ <object class="GtkSpinButton" id="spb_start_5">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">5 0 10000 1 10 0</property>
+ <property name="adjustment">adjustment23</property>
<property name="digits">1</property>
- </widget>
+ </object>
<packing>
<property name="position">1</property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label39">
+ <object class="GtkLabel" id="label39">
<property name="visible">True</property>
<property name="label" translatable="yes">6:</property>
- </widget>
+ </object>
<packing>
<property name="position">2</property>
</packing>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_start_6">
+ <object class="GtkSpinButton" id="spb_start_6">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">6 0 10000 1 10 0</property>
+ <property name="adjustment">adjustment24</property>
<property name="digits">1</property>
- </widget>
+ </object>
<packing>
<property name="position">3</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
@@ -895,202 +1235,198 @@ GogXYColorPlot, GogContourPlot, GogSurfacePlot</property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label40">
+ <object class="GtkLabel" id="label40">
<property name="visible">True</property>
<property name="label" translatable="yes">Only used for: GogDropBarPlot, GogMinMaxPlot</property>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
<property name="position">3</property>
</packing>
</child>
- </widget>
- <packing>
- <property name="position">4</property>
- </packing>
+ </object>
</child>
- <child>
- <widget class="GtkLabel" id="label41">
+ <child type="tab">
+ <object class="GtkLabel" id="label41">
<property name="visible">True</property>
<property name="label" translatable="yes">Starts</property>
- </widget>
+ </object>
<packing>
- <property name="type">tab</property>
<property name="position">4</property>
<property name="tab_fill">False</property>
</packing>
</child>
<child>
- <widget class="GtkVBox" id="vbox7">
+ <object class="GtkVBox" id="vbox7">
<property name="visible">True</property>
<child>
- <widget class="GtkHBox" id="hbox16">
+ <object class="GtkHBox" id="hbox16">
<property name="visible">True</property>
<child>
- <widget class="GtkLabel" id="label44">
+ <object class="GtkLabel" id="label44">
<property name="visible">True</property>
<property name="label" translatable="yes">1:</property>
- </widget>
+ </object>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_matrix_1">
+ <object class="GtkSpinButton" id="spb_matrix_1">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">10 0 10000 1 10 0</property>
+ <property name="adjustment">adjustment25</property>
<property name="digits">1</property>
- </widget>
+ </object>
<packing>
<property name="position">1</property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label45">
+ <object class="GtkLabel" id="label45">
<property name="visible">True</property>
<property name="label" translatable="yes">2:</property>
- </widget>
+ </object>
<packing>
<property name="position">2</property>
</packing>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_matrix_2">
+ <object class="GtkSpinButton" id="spb_matrix_2">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">20 0 10000 1 10 0</property>
+ <property name="adjustment">adjustment26</property>
<property name="digits">1</property>
- </widget>
+ </object>
<packing>
<property name="position">3</property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label46">
+ <object class="GtkLabel" id="label46">
<property name="visible">True</property>
<property name="label" translatable="yes">3:</property>
- </widget>
+ </object>
<packing>
<property name="position">4</property>
</packing>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_matrix_3">
+ <object class="GtkSpinButton" id="spb_matrix_3">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">30 0 10000 1 10 0</property>
+ <property name="adjustment">adjustment27</property>
<property name="digits">1</property>
- </widget>
+ </object>
<packing>
<property name="position">5</property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label47">
+ <object class="GtkLabel" id="label47">
<property name="visible">True</property>
<property name="label" translatable="yes">4:</property>
- </widget>
+ </object>
<packing>
<property name="position">6</property>
</packing>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_matrix_4">
+ <object class="GtkSpinButton" id="spb_matrix_4">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">40 0 10000 1 10 0</property>
+ <property name="adjustment">adjustment28</property>
<property name="digits">1</property>
- </widget>
+ </object>
<packing>
<property name="position">7</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
</packing>
</child>
<child>
- <widget class="GtkHBox" id="hbox17">
+ <object class="GtkHBox" id="hbox17">
<property name="visible">True</property>
<child>
- <widget class="GtkLabel" id="label48">
+ <object class="GtkLabel" id="label48">
<property name="visible">True</property>
<property name="label" translatable="yes">5:</property>
- </widget>
+ </object>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_matrix_5">
+ <object class="GtkSpinButton" id="spb_matrix_5">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">50 0 10000 1 10 0</property>
+ <property name="adjustment">adjustment29</property>
<property name="digits">1</property>
- </widget>
+ </object>
<packing>
<property name="position">1</property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label49">
+ <object class="GtkLabel" id="label49">
<property name="visible">True</property>
<property name="label" translatable="yes">6:</property>
- </widget>
+ </object>
<packing>
<property name="position">2</property>
</packing>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_matrix_6">
+ <object class="GtkSpinButton" id="spb_matrix_6">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">60 0 10000 1 10 0</property>
+ <property name="adjustment">adjustment30</property>
<property name="digits">1</property>
- </widget>
+ </object>
<packing>
<property name="position">3</property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label50">
+ <object class="GtkLabel" id="label50">
<property name="visible">True</property>
<property name="label" translatable="yes">7:</property>
- </widget>
+ </object>
<packing>
<property name="position">4</property>
</packing>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_matrix_7">
+ <object class="GtkSpinButton" id="spb_matrix_7">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">70 0 10000 1 10 0</property>
+ <property name="adjustment">adjustment31</property>
<property name="digits">1</property>
- </widget>
+ </object>
<packing>
<property name="position">5</property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label51">
+ <object class="GtkLabel" id="label51">
<property name="visible">True</property>
<property name="label" translatable="yes">8:</property>
- </widget>
+ </object>
<packing>
<property name="position">6</property>
</packing>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_matrix_8">
+ <object class="GtkSpinButton" id="spb_matrix_8">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">80 0 10000 1 10 0</property>
+ <property name="adjustment">adjustment32</property>
<property name="digits">1</property>
- </widget>
+ </object>
<packing>
<property name="position">7</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
@@ -1098,86 +1434,86 @@ GogXYColorPlot, GogContourPlot, GogSurfacePlot</property>
</packing>
</child>
<child>
- <widget class="GtkHBox" id="hbox18">
+ <object class="GtkHBox" id="hbox18">
<property name="visible">True</property>
<child>
- <widget class="GtkLabel" id="label52">
+ <object class="GtkLabel" id="label52">
<property name="visible">True</property>
<property name="label" translatable="yes">9:</property>
- </widget>
+ </object>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_matrix_9">
+ <object class="GtkSpinButton" id="spb_matrix_9">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">90 0 10000 1 10 0</property>
+ <property name="adjustment">adjustment33</property>
<property name="digits">1</property>
- </widget>
+ </object>
<packing>
<property name="position">1</property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label53">
+ <object class="GtkLabel" id="label53">
<property name="visible">True</property>
<property name="label" translatable="yes">10:</property>
- </widget>
+ </object>
<packing>
<property name="position">2</property>
</packing>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_matrix_10">
+ <object class="GtkSpinButton" id="spb_matrix_10">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">100 0 10000 1 10 0</property>
+ <property name="adjustment">adjustment34</property>
<property name="digits">1</property>
- </widget>
+ </object>
<packing>
<property name="position">3</property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label54">
+ <object class="GtkLabel" id="label54">
<property name="visible">True</property>
<property name="label" translatable="yes">11:</property>
- </widget>
+ </object>
<packing>
<property name="position">4</property>
</packing>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_matrix_11">
+ <object class="GtkSpinButton" id="spb_matrix_11">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">110 0 10000 1 10 0</property>
+ <property name="adjustment">adjustment35</property>
<property name="digits">1</property>
- </widget>
+ </object>
<packing>
<property name="position">5</property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label55">
+ <object class="GtkLabel" id="label55">
<property name="visible">True</property>
<property name="label" translatable="yes">12:</property>
- </widget>
+ </object>
<packing>
<property name="position">6</property>
</packing>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_matrix_12">
+ <object class="GtkSpinButton" id="spb_matrix_12">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">120 0 10000 1 10 0</property>
+ <property name="adjustment">adjustment36</property>
<property name="digits">1</property>
- </widget>
+ </object>
<packing>
<property name="position">7</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
@@ -1185,86 +1521,86 @@ GogXYColorPlot, GogContourPlot, GogSurfacePlot</property>
</packing>
</child>
<child>
- <widget class="GtkHBox" id="hbox19">
+ <object class="GtkHBox" id="hbox19">
<property name="visible">True</property>
<child>
- <widget class="GtkLabel" id="label56">
+ <object class="GtkLabel" id="label56">
<property name="visible">True</property>
<property name="label" translatable="yes">13:</property>
- </widget>
+ </object>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_matrix_13">
+ <object class="GtkSpinButton" id="spb_matrix_13">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">110 0 10000 1 10 0</property>
+ <property name="adjustment">adjustment37</property>
<property name="digits">1</property>
- </widget>
+ </object>
<packing>
<property name="position">1</property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label57">
+ <object class="GtkLabel" id="label57">
<property name="visible">True</property>
<property name="label" translatable="yes">14:</property>
- </widget>
+ </object>
<packing>
<property name="position">2</property>
</packing>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_matrix_14">
+ <object class="GtkSpinButton" id="spb_matrix_14">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">120 0 10000 1 10 0</property>
+ <property name="adjustment">adjustment38</property>
<property name="digits">1</property>
- </widget>
+ </object>
<packing>
<property name="position">3</property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label58">
+ <object class="GtkLabel" id="label58">
<property name="visible">True</property>
<property name="label" translatable="yes">15:</property>
- </widget>
+ </object>
<packing>
<property name="position">4</property>
</packing>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_matrix_15">
+ <object class="GtkSpinButton" id="spb_matrix_15">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">130 0 10000 1 10 0</property>
+ <property name="adjustment">adjustment39</property>
<property name="digits">1</property>
- </widget>
+ </object>
<packing>
<property name="position">5</property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label59">
+ <object class="GtkLabel" id="label59">
<property name="visible">True</property>
<property name="label" translatable="yes">16:</property>
- </widget>
+ </object>
<packing>
<property name="position">6</property>
</packing>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_matrix_16">
+ <object class="GtkSpinButton" id="spb_matrix_16">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">140 0 10000 1 10 0</property>
+ <property name="adjustment">adjustment40</property>
<property name="digits">1</property>
- </widget>
+ </object>
<packing>
<property name="position">7</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
@@ -1272,86 +1608,86 @@ GogXYColorPlot, GogContourPlot, GogSurfacePlot</property>
</packing>
</child>
<child>
- <widget class="GtkHBox" id="hbox20">
+ <object class="GtkHBox" id="hbox20">
<property name="visible">True</property>
<child>
- <widget class="GtkLabel" id="label60">
+ <object class="GtkLabel" id="label60">
<property name="visible">True</property>
<property name="label" translatable="yes">17:</property>
- </widget>
+ </object>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_matrix_17">
+ <object class="GtkSpinButton" id="spb_matrix_17">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">150 0 10000 1 10 0</property>
+ <property name="adjustment">adjustment41</property>
<property name="digits">1</property>
- </widget>
+ </object>
<packing>
<property name="position">1</property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label61">
+ <object class="GtkLabel" id="label61">
<property name="visible">True</property>
<property name="label" translatable="yes">18:</property>
- </widget>
+ </object>
<packing>
<property name="position">2</property>
</packing>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_matrix_18">
+ <object class="GtkSpinButton" id="spb_matrix_18">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">160 0 10000 1 10 0</property>
+ <property name="adjustment">adjustment42</property>
<property name="digits">1</property>
- </widget>
+ </object>
<packing>
<property name="position">3</property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label62">
+ <object class="GtkLabel" id="label62">
<property name="visible">True</property>
<property name="label" translatable="yes">19:</property>
- </widget>
+ </object>
<packing>
<property name="position">4</property>
</packing>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_matrix_19">
+ <object class="GtkSpinButton" id="spb_matrix_19">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">170 0 10000 1 10 0</property>
+ <property name="adjustment">adjustment43</property>
<property name="digits">1</property>
- </widget>
+ </object>
<packing>
<property name="position">5</property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label63">
+ <object class="GtkLabel" id="label63">
<property name="visible">True</property>
<property name="label" translatable="yes">20:</property>
- </widget>
+ </object>
<packing>
<property name="position">6</property>
</packing>
</child>
<child>
- <widget class="GtkSpinButton" id="spb_matrix_20">
+ <object class="GtkSpinButton" id="spb_matrix_20">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="adjustment">180 0 10000 1 10 0</property>
+ <property name="adjustment">adjustment44</property>
<property name="digits">1</property>
- </widget>
+ </object>
<packing>
<property name="position">7</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
@@ -1359,51 +1695,45 @@ GogXYColorPlot, GogContourPlot, GogSurfacePlot</property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label42">
+ <object class="GtkLabel" id="label42">
<property name="visible">True</property>
<property name="label" translatable="yes">Only used for: GogContourPlot, GogSurfacePlot</property>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
<property name="position">5</property>
</packing>
</child>
- </widget>
- <packing>
- <property name="position">5</property>
- </packing>
+ </object>
</child>
- <child>
- <widget class="GtkLabel" id="label43">
+ <child type="tab">
+ <object class="GtkLabel" id="label43">
<property name="visible">True</property>
<property name="label" translatable="yes">Matrix</property>
- </widget>
+ </object>
<packing>
- <property name="type">tab</property>
<property name="position">5</property>
<property name="tab_fill">False</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
<property name="position">1</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="resize">True</property>
<property name="shrink">True</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="position">1</property>
</packing>
</child>
- </widget>
- </child>
- </widget>
-</glade-interface>
+ </object>
+</interface>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]