[gnumeric] More GtkTable to GtkGrid replacements.
- From: Jean Bréfort <jbrefort src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnumeric] More GtkTable to GtkGrid replacements.
- Date: Tue, 26 Feb 2013 13:20:10 +0000 (UTC)
commit c8a627b0785b992ce28e2bda26b74db7074f620b
Author: Jean Brefort <jean brefort normalesup org>
Date: Tue Feb 26 13:18:59 2013 +0100
More GtkTable to GtkGrid replacements.
ChangeLog | 4 +
src/dialogs/ChangeLog | 10 +
src/dialogs/cell-format.ui | 133 ++++++++
src/dialogs/dialog-cell-format.c | 1 +
src/dialogs/dialog-goal-seek.c | 26 +-
src/dialogs/font-sel.ui | 122 ++++----
src/dialogs/formula-guru.ui | 115 ++++---
src/dialogs/goalseek.ui | 606 ++++++++++++++++++-----------------
src/number-match.c | 20 +-
src/widgets/ChangeLog | 4 +
src/widgets/widget-font-selector.c | 15 +-
11 files changed, 624 insertions(+), 432 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index 3e3e508..901f72d 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2013-02-26 Jean Brefort <jean brefort normalesup org>
+
+ * src/number-match.c: more introspection warnings.
+
2013-02-23 Morten Welinder <terra gnome org>
* */*.c: Avoid G_OBJECT casts for g_object_ref and g_object_unref.
diff --git a/src/dialogs/ChangeLog b/src/dialogs/ChangeLog
index d3137a3..742f310 100644
--- a/src/dialogs/ChangeLog
+++ b/src/dialogs/ChangeLog
@@ -1,3 +1,13 @@
+2013-02-26 Jean Brefort <jean brefort normalesup org>
+
+ * cell-format.ui: replaced GtkTable with GtkGrid.
+ * dialog-cell-format.c (fmt_dialog_init_font_page): ditto.
+ * dialog-goal-seek.c (cb_dialog_apply_clicked), (dialog_realized),
+ (dialog_init): ditto.
+ * font-sel.ui: ditto.
+ * formula-guru.ui: ditto.
+ * goalseek.ui: ditto.
+
2013-02-24 Jean Brefort <jean brefort normalesup org>
* dialog-doc-metadata.c: replaced GtkTable with GtkGrid.
diff --git a/src/dialogs/cell-format.ui b/src/dialogs/cell-format.ui
index 0d3939e..5ae46b3 100644
--- a/src/dialogs/cell-format.ui
+++ b/src/dialogs/cell-format.ui
@@ -506,6 +506,27 @@
<property name="height">1</property>
</packing>
</child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
</object>
</child>
<child type="tab">
@@ -523,6 +544,7 @@
<object class="GtkGrid" id="font-grid">
<property name="visible">True</property>
<property name="can_focus">False</property>
+ <property name="hexpand">True</property>
<property name="border_width">12</property>
<property name="row_spacing">6</property>
<property name="column_spacing">12</property>
@@ -632,6 +654,24 @@
<property name="height">1</property>
</packing>
</child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
</object>
<packing>
<property name="position">1</property>
@@ -892,6 +932,63 @@
<property name="height">1</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>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
</object>
<packing>
<property name="left_attach">0</property>
@@ -1175,6 +1272,9 @@
<property name="height">1</property>
</packing>
</child>
+ <child>
+ <placeholder/>
+ </child>
</object>
<packing>
<property name="position">2</property>
@@ -1797,6 +1897,15 @@
<property name="height">1</property>
</packing>
</child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
</object>
<packing>
<property name="position">3</property>
@@ -2208,6 +2317,30 @@
<property name="height">1</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>
</object>
<packing>
<property name="position">5</property>
diff --git a/src/dialogs/dialog-cell-format.c b/src/dialogs/dialog-cell-format.c
index 4ae63fd..b902643 100644
--- a/src/dialogs/dialog-cell-format.c
+++ b/src/dialogs/dialog-cell-format.c
@@ -832,6 +832,7 @@ fmt_dialog_init_font_page (FormatState *state)
/* TODO: How to insert the font box in the right place initially */
gtk_widget_show (tmp);
gtk_widget_set_vexpand (tmp, TRUE);
+ gtk_widget_set_hexpand (tmp, TRUE);
gtk_grid_attach (GTK_GRID (container), tmp, 0, 0, 5, 1);
font_selector_editable_enters (font_widget, GTK_WINDOW (state->dialog));
diff --git a/src/dialogs/dialog-goal-seek.c b/src/dialogs/dialog-goal-seek.c
index 4399a2b..4bb751f 100644
--- a/src/dialogs/dialog-goal-seek.c
+++ b/src/dialogs/dialog-goal-seek.c
@@ -73,7 +73,7 @@ typedef struct {
GtkWidget *current_value_label;
GtkWidget *solution_label;
GtkWidget *result_label;
- GtkWidget *result_table;
+ GtkWidget *result_grid;
Sheet *sheet;
Workbook *wb;
WBCGtk *wbcg;
@@ -456,7 +456,7 @@ cb_dialog_apply_clicked (G_GNUC_UNUSED GtkWidget *button,
}
state->cancelled = FALSE;
- gtk_widget_show (state->result_table);
+ gtk_widget_show (state->result_grid);
return;
}
@@ -472,7 +472,7 @@ static void
dialog_realized (G_GNUC_UNUSED GtkWidget *dialog,
GoalSeekState *state)
{
- gtk_widget_hide (state->result_table);
+ gtk_widget_hide (state->result_grid);
}
/**
@@ -505,7 +505,7 @@ dialog_preload_selection (GoalSeekState *state, GnmExprEntry *entry)
static gboolean
dialog_init (GoalSeekState *state)
{
- GtkTable *table;
+ GtkGrid *grid;
state->dialog = go_gtk_builder_get_widget (state->gui, "GoalSeek");
if (state->dialog == NULL)
@@ -540,18 +540,17 @@ dialog_init (GoalSeekState *state)
gtk_label_set_justify (GTK_LABEL (state->solution_label), GTK_JUSTIFY_RIGHT);
state->result_label = go_gtk_builder_get_widget (state->gui, "result-label");
- state->result_table = go_gtk_builder_get_widget (state->gui, "result-table");
+ state->result_grid = go_gtk_builder_get_widget (state->gui, "result-grid");
- table = GTK_TABLE (go_gtk_builder_get_widget (state->gui, "goal-table"));
+ grid = GTK_GRID (go_gtk_builder_get_widget (state->gui, "goal-grid"));
state->set_cell_entry = gnm_expr_entry_new (state->wbcg, TRUE);
gnm_expr_entry_set_flags (state->set_cell_entry,
GNM_EE_SINGLE_RANGE |
GNM_EE_FORCE_ABS_REF,
GNM_EE_MASK);
- gtk_table_attach (table, GTK_WIDGET (state->set_cell_entry),
- 2, 3, 1, 2,
- GTK_EXPAND | GTK_FILL, 0,
- 0, 0);
+ gtk_grid_attach (grid, GTK_WIDGET (state->set_cell_entry),
+ 1, 0, 1, 1);
+ gtk_widget_set_hexpand (GTK_WIDGET (state->set_cell_entry), TRUE);
gnumeric_editable_enters (GTK_WINDOW (state->dialog),
GTK_WIDGET (state->set_cell_entry));
dialog_preload_selection (state, state->set_cell_entry);
@@ -562,10 +561,9 @@ dialog_init (GoalSeekState *state)
GNM_EE_SINGLE_RANGE |
GNM_EE_FORCE_ABS_REF,
GNM_EE_MASK);
- gtk_table_attach (table, GTK_WIDGET (state->change_cell_entry),
- 2, 3, 3, 4,
- GTK_EXPAND | GTK_FILL, 0,
- 0, 0);
+ gtk_grid_attach (grid, GTK_WIDGET (state->change_cell_entry),
+ 1, 2, 1, 1);
+ gtk_widget_set_hexpand (GTK_WIDGET (state->change_cell_entry), TRUE);
gnumeric_editable_enters (GTK_WINDOW (state->dialog),
GTK_WIDGET (state->change_cell_entry));
dialog_preload_selection (state, state->change_cell_entry);
diff --git a/src/dialogs/font-sel.ui b/src/dialogs/font-sel.ui
index ca98ba5..2e19e92 100644
--- a/src/dialogs/font-sel.ui
+++ b/src/dialogs/font-sel.ui
@@ -1,28 +1,13 @@
<?xml version="1.0" encoding="UTF-8"?>
<interface>
<!-- interface-requires gtk+ 3.0 -->
- <object class="GtkTable" id="toplevel-table">
+ <object class="GtkGrid" id="toplevel-grid">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="n_rows">4</property>
- <property name="n_columns">3</property>
- <property name="column_spacing">4</property>
+ <property name="hexpand">True</property>
+ <property name="vexpand">True</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>
+ <property name="column_spacing">4</property>
<child>
<object class="GtkLabel" id="label1">
<property name="visible">True</property>
@@ -32,8 +17,10 @@
<property name="justify">center</property>
</object>
<packing>
- <property name="x_options">GTK_FILL</property>
- <property name="y_options"></property>
+ <property name="left_attach">0</property>
+ <property name="top_attach">0</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
</packing>
</child>
<child>
@@ -46,9 +33,9 @@
</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>
+ <property name="top_attach">0</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
</packing>
</child>
<child>
@@ -61,9 +48,9 @@
</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>
+ <property name="top_attach">0</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
</packing>
</child>
<child>
@@ -72,30 +59,28 @@
<property name="can_focus">True</property>
<property name="editable">False</property>
<property name="invisible_char">●</property>
+ <property name="invisible_char_set">True</property>
</object>
<packing>
+ <property name="left_attach">0</property>
<property name="top_attach">1</property>
- <property name="bottom_attach">2</property>
- <property name="y_options"></property>
+ <property name="width">1</property>
+ <property name="height">1</property>
</packing>
</child>
<child>
- <object class="GtkFrame" id="font-preview-frame">
+ <object class="GtkEntry" id="font-style-entry">
<property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="label_xalign">0</property>
- <child type="label">
- <object class="GtkLabel" id="label4">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="label" translatable="yes">Preview</property>
- </object>
- </child>
+ <property name="can_focus">True</property>
+ <property name="editable">False</property>
+ <property name="invisible_char">●</property>
+ <property name="invisible_char_set">True</property>
</object>
<packing>
- <property name="right_attach">3</property>
- <property name="top_attach">3</property>
- <property name="bottom_attach">4</property>
+ <property name="left_attach">1</property>
+ <property name="top_attach">1</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
</packing>
</child>
<child>
@@ -103,56 +88,74 @@
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="invisible_char">●</property>
+ <property name="invisible_char_set">True</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>
+ <property name="width">1</property>
+ <property name="height">1</property>
</packing>
</child>
<child>
- <object class="GtkScrolledWindow" id="scrolledwindow2">
+ <object class="GtkLabel" id="label4">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="hexpand">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Preview</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">3</property>
+ <property name="width">3</property>
+ <property name="height">1</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="shadow_type">in</property>
<child>
- <object class="GtkTreeView" id="font-style-list">
+ <object class="GtkTreeView" id="font-name-list">
<property name="visible">True</property>
<property name="can_focus">True</property>
+ <property name="vexpand">True</property>
<child internal-child="selection">
- <object class="GtkTreeSelection" id="treeview-selection1"/>
+ <object class="GtkTreeSelection" id="treeview-selection"/>
</child>
</object>
</child>
</object>
<packing>
- <property name="left_attach">1</property>
- <property name="right_attach">2</property>
+ <property name="left_attach">0</property>
<property name="top_attach">2</property>
- <property name="bottom_attach">3</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
</packing>
</child>
<child>
- <object class="GtkScrolledWindow" id="scrolledwindow1">
+ <object class="GtkScrolledWindow" id="scrolledwindow2">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="shadow_type">in</property>
<child>
- <object class="GtkTreeView" id="font-name-list">
+ <object class="GtkTreeView" id="font-style-list">
<property name="visible">True</property>
<property name="can_focus">True</property>
<child internal-child="selection">
- <object class="GtkTreeSelection" id="treeview-selection2"/>
+ <object class="GtkTreeSelection" id="treeview-selection1"/>
</child>
</object>
</child>
</object>
<packing>
+ <property name="left_attach">1</property>
<property name="top_attach">2</property>
- <property name="bottom_attach">3</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
</packing>
</child>
<child>
@@ -166,17 +169,16 @@
<property name="visible">True</property>
<property name="can_focus">True</property>
<child internal-child="selection">
- <object class="GtkTreeSelection" id="treeview-selection3"/>
+ <object class="GtkTreeSelection" id="treeview-selection2"/>
</child>
</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>
+ <property name="width">1</property>
+ <property name="height">1</property>
</packing>
</child>
</object>
diff --git a/src/dialogs/formula-guru.ui b/src/dialogs/formula-guru.ui
index fdc4f62..8a85fbe 100644
--- a/src/dialogs/formula-guru.ui
+++ b/src/dialogs/formula-guru.ui
@@ -20,6 +20,7 @@
<child>
<object class="GtkButton" id="help_button">
<property name="label">gtk-help</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="can_default">True</property>
@@ -36,6 +37,7 @@
<child>
<object class="GtkButton" id="cancel_button">
<property name="label">gtk-cancel</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="can_default">True</property>
@@ -52,6 +54,7 @@
<child>
<object class="GtkButton" id="ok_button">
<property name="label">gtk-ok</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="can_default">True</property>
@@ -74,77 +77,80 @@
</packing>
</child>
<child>
- <object class="GtkTable" id="main_table">
+ <object class="GtkGrid" id="main-grid">
+ <property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="border_width">5</property>
- <property name="n_rows">5</property>
- <property name="n_columns">2</property>
- <property name="column_spacing">4</property>
- <property name="row_spacing">4</property>
+ <property name="vexpand">True</property>
+ <property name="border_width">6</property>
+ <property name="row_spacing">6</property>
+ <property name="column_spacing">12</property>
<child>
<object class="GtkScrolledWindow" id="scrolled">
<property name="visible">True</property>
<property name="can_focus">True</property>
+ <property name="hexpand">True</property>
<property name="border_width">5</property>
<property name="shadow_type">etched-in</property>
</object>
<packing>
- <property name="bottom_attach">4</property>
+ <property name="left_attach">0</property>
+ <property name="top_attach">0</property>
+ <property name="width">1</property>
+ <property name="height">4</property>
</packing>
</child>
<child>
- <object class="GtkButton" id="select_func">
+ <object class="GtkButton" id="trash">
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="receives_default">False</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
<property name="use_action_appearance">False</property>
<child>
- <object class="GtkImage" id="image1">
+ <object class="GtkImage" id="image2">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="stock">Gnumeric_FormulaGuru</property>
+ <property name="stock">gtk-clear</property>
<property name="icon-size">3</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>
- <property name="x_options">GTK_SHRINK</property>
- <property name="y_options">GTK_SHRINK</property>
+ <property name="top_attach">3</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
</packing>
</child>
<child>
- <object class="GtkButton" id="trash">
+ <object class="GtkButton" id="select_func">
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="receives_default">False</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
<property name="use_action_appearance">False</property>
<child>
- <object class="GtkImage" id="image2">
+ <object class="GtkImage" id="image1">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="stock">gtk-clear</property>
+ <property name="stock">Gnumeric_FormulaGuru</property>
<property name="icon-size">3</property>
</object>
</child>
</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_SHRINK</property>
- <property name="y_options">GTK_SHRINK</property>
+ <property name="top_attach">2</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
</packing>
</child>
<child>
<object class="GtkToggleButton" id="zoom">
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="receives_default">False</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
<property name="use_action_appearance">False</property>
<child>
<object class="GtkImage" id="image3">
@@ -157,60 +163,75 @@
</object>
<packing>
<property name="left_attach">1</property>
- <property name="right_attach">2</property>
- <property name="x_options">GTK_SHRINK</property>
- <property name="y_options">GTK_SHRINK</property>
+ <property name="top_attach">0</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label1">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="vexpand">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">1</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
</packing>
</child>
<child>
- <object class="GtkBox" id="hbox1">
+ <object class="GtkGrid" id="check-grid">
<property name="visible">True</property>
<property name="can_focus">False</property>
+ <property name="column_spacing">12</property>
<child>
<object class="GtkCheckButton" id="array_button">
<property name="label" translatable="yes">Enter as array function</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
<property name="use_action_appearance">False</property>
<property name="use_underline">True</property>
+ <property name="xalign">0</property>
<property name="draw_indicator">True</property>
</object>
<packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
- <property name="padding">2</property>
- <property name="position">0</property>
+ <property name="left_attach">0</property>
+ <property name="top_attach">0</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
</packing>
</child>
<child>
<object class="GtkCheckButton" id="quote-button">
<property name="label" translatable="yes">Quote unknown names</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
<property name="use_action_appearance">False</property>
+ <property name="xalign">0</property>
<property name="active">True</property>
<property name="draw_indicator">True</property>
</object>
<packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
- <property name="padding">2</property>
- <property name="position">1</property>
+ <property name="left_attach">1</property>
+ <property name="top_attach">0</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
</packing>
</child>
</object>
<packing>
- <property name="right_attach">2</property>
+ <property name="left_attach">0</property>
<property name="top_attach">4</property>
- <property name="bottom_attach">5</property>
- <property name="y_options"></property>
+ <property name="width">2</property>
+ <property name="height">1</property>
</packing>
</child>
- <child>
- <placeholder/>
- </child>
</object>
<packing>
<property name="expand">False</property>
diff --git a/src/dialogs/goalseek.ui b/src/dialogs/goalseek.ui
index 4630833..1beb57b 100644
--- a/src/dialogs/goalseek.ui
+++ b/src/dialogs/goalseek.ui
@@ -21,6 +21,7 @@
<child>
<object class="GtkButton" id="helpbutton">
<property name="label">gtk-help</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="can_default">True</property>
@@ -37,6 +38,7 @@
<child>
<object class="GtkButton" id="applybutton">
<property name="label">gtk-apply</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="can_default">True</property>
@@ -53,6 +55,7 @@
<child>
<object class="GtkButton" id="cancelbutton">
<property name="label">gtk-cancel</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="can_default">True</property>
@@ -69,6 +72,7 @@
<child>
<object class="GtkButton" id="closebutton">
<property name="label">gtk-close</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="can_default">True</property>
@@ -91,146 +95,12 @@
</packing>
</child>
<child>
- <object class="GtkTable" id="goal-table">
+ <object class="GtkGrid" id="main-grid">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="border_width">5</property>
- <property name="n_rows">6</property>
- <property name="n_columns">3</property>
- <property name="column_spacing">12</property>
+ <property name="border_width">6</property>
<property name="row_spacing">6</property>
- <child>
- <object class="GtkLabel" id="set_cell-label">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="xalign">0</property>
- <property name="label" translatable="yes">_Set Cell:</property>
- <property name="use_underline">True</property>
- <property name="justify">right</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="to_value-label">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="xalign">0</property>
- <property name="label" translatable="yes">_To Value:</property>
- <property name="use_underline">True</property>
- <property name="justify">right</property>
- <property name="mnemonic_widget">to_value_entry</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="by_changing-label">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="xalign">0</property>
- <property name="label" translatable="yes">_By Changing Cell:</property>
- <property name="use_underline">True</property>
- <property name="justify">center</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="at_least-label">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="xalign">0</property>
- <property name="label" translatable="yes">(_Minimum):</property>
- <property name="use_underline">True</property>
- <property name="justify">center</property>
- <property name="mnemonic_widget">at_least-entry</property>
- </object>
- <packing>
- <property name="left_attach">1</property>
- <property name="right_attach">2</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>
- <object class="GtkLabel" id="at_most-label">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="xalign">0</property>
- <property name="label" translatable="yes">(Ma_ximum):</property>
- <property name="use_underline">True</property>
- <property name="justify">center</property>
- <property name="mnemonic_widget">at_most-entry</property>
- </object>
- <packing>
- <property name="left_attach">1</property>
- <property name="right_attach">2</property>
- <property name="top_attach">5</property>
- <property name="bottom_attach">6</property>
- <property name="x_options">GTK_FILL</property>
- <property name="y_options"></property>
- </packing>
- </child>
- <child>
- <object class="GtkEntry" id="to_value_entry">
- <property name="visible">True</property>
- <property name="can_focus">True</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="y_options"></property>
- </packing>
- </child>
- <child>
- <object class="GtkEntry" id="at_least-entry">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- </object>
- <packing>
- <property name="left_attach">2</property>
- <property name="right_attach">3</property>
- <property name="top_attach">4</property>
- <property name="bottom_attach">5</property>
- <property name="y_options"></property>
- </packing>
- </child>
- <child>
- <object class="GtkEntry" id="at_most-entry">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- </object>
- <packing>
- <property name="left_attach">2</property>
- <property name="right_attach">3</property>
- <property name="top_attach">5</property>
- <property name="bottom_attach">6</property>
- <property name="y_options"></property>
- </packing>
- </child>
+ <property name="column_spacing">12</property>
<child>
<object class="GtkLabel" id="label8">
<property name="visible">True</property>
@@ -240,22 +110,171 @@
<property name="use_markup">True</property>
</object>
<packing>
- <property name="right_attach">3</property>
- <property name="x_options">GTK_FILL</property>
- <property name="y_options"></property>
+ <property name="left_attach">0</property>
+ <property name="top_attach">0</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
</packing>
</child>
<child>
- <object class="GtkLabel" id="label10">
+ <object class="GtkGrid" id="goal-grid">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="xalign">0</property>
+ <property name="margin_left">12</property>
+ <property name="row_spacing">6</property>
+ <property name="column_spacing">12</property>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <object class="GtkLabel" id="set_cell-label">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Set Cell:</property>
+ <property name="use_underline">True</property>
+ <property name="justify">right</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">0</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="to_value-label">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_To Value:</property>
+ <property name="use_underline">True</property>
+ <property name="justify">right</property>
+ <property name="mnemonic_widget">to_value_entry</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">1</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="by_changing-label">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_By Changing Cell:</property>
+ <property name="use_underline">True</property>
+ <property name="justify">center</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">2</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="at_least-label">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">(_Minimum):</property>
+ <property name="use_underline">True</property>
+ <property name="justify">center</property>
+ <property name="mnemonic_widget">at_least-entry</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">3</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="at_most-label">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">(Ma_ximum):</property>
+ <property name="use_underline">True</property>
+ <property name="justify">center</property>
+ <property name="mnemonic_widget">at_most-entry</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">4</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="to_value_entry">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">●</property>
+ <property name="invisible_char_set">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">1</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="at_least-entry">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">●</property>
+ <property name="invisible_char_set">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">3</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="at_most-entry">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">●</property>
+ <property name="invisible_char_set">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">4</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
</object>
<packing>
+ <property name="left_attach">0</property>
<property name="top_attach">1</property>
- <property name="bottom_attach">6</property>
- <property name="x_options">GTK_FILL</property>
- <property name="y_options">GTK_FILL</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
</packing>
</child>
<child>
@@ -264,187 +283,186 @@
<child>
<placeholder/>
</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="result-table">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="border_width">5</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="GtkLabel" id="target-value">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="xalign">0</property>
- <property name="xpad">5</property>
- <property name="ypad">1</property>
- <property name="label" translatable="yes">label8</property>
- <property name="justify">right</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="current-value">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="xalign">0</property>
- <property name="xpad">5</property>
- <property name="ypad">1</property>
- <property name="label" translatable="yes">label9</property>
- <property name="justify">right</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>
+ <placeholder/>
</child>
<child>
- <object class="GtkLabel" id="solution">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="xalign">0</property>
- <property name="xpad">5</property>
- <property name="ypad">1</property>
- <property name="label" translatable="yes">label10</property>
- <property name="justify">right</property>
- </object>
- <packing>
- <property name="left_attach">2</property>
- <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>
+ <placeholder/>
</child>
<child>
- <object class="GtkLabel" id="label5">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="xalign">0</property>
- <property name="xpad">5</property>
- <property name="ypad">1</property>
- <property name="label" translatable="yes">Remaining Error:</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_SHRINK | GTK_FILL</property>
- <property name="y_options"></property>
- </packing>
+ <placeholder/>
</child>
<child>
- <object class="GtkLabel" id="label6">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="xalign">0</property>
- <property name="xpad">5</property>
- <property name="ypad">1</property>
- <property name="label" translatable="yes">Current Value:</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_SHRINK | GTK_FILL</property>
- <property name="y_options"></property>
- </packing>
+ <placeholder/>
</child>
<child>
- <object class="GtkLabel" id="label7">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="xalign">0</property>
- <property name="xpad">5</property>
- <property name="ypad">1</property>
- <property name="label" translatable="yes">Solution:</property>
- <property name="justify">center</property>
- </object>
- <packing>
- <property name="left_attach">1</property>
- <property name="right_attach">2</property>
- <property name="top_attach">4</property>
- <property name="bottom_attach">5</property>
- <property name="x_options">GTK_SHRINK | GTK_FILL</property>
- <property name="y_options"></property>
- </packing>
+ <placeholder/>
</child>
<child>
- <object class="GtkLabel" id="result-label">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="xalign">0</property>
- <property name="xpad">5</property>
- <property name="ypad">5</property>
- <property name="label" translatable="yes">label4</property>
- <property name="justify">center</property>
- <property name="wrap">True</property>
- </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="y_options"></property>
- </packing>
+ <placeholder/>
</child>
<child>
- <object class="GtkLabel" id="label11">
+ <object class="GtkLabel" id="label9">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="xalign">0</property>
+ <property name="label" translatable="yes"><span weight="bold">Last
Result</span></property>
+ <property name="use_markup">True</property>
</object>
<packing>
- <property name="top_attach">1</property>
- <property name="bottom_attach">5</property>
- <property name="x_options"></property>
- <property name="y_options">GTK_FILL</property>
+ <property name="left_attach">0</property>
+ <property name="top_attach">2</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
</packing>
</child>
<child>
- <object class="GtkLabel" id="label9">
+ <object class="GtkGrid" id="result-grid">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="xalign">0</property>
- <property name="label" translatable="yes"><span weight="bold">Last
Result</span></property>
- <property name="use_markup">True</property>
+ <property name="margin_left">12</property>
+ <property name="row_spacing">6</property>
+ <property name="column_spacing">12</property>
+ <child>
+ <object class="GtkLabel" id="result-label">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">label4</property>
+ <property name="justify">center</property>
+ <property name="wrap">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">0</property>
+ <property name="width">2</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label5">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Remaining Error:</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">1</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label6">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Current Value:</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">2</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label7">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Solution:</property>
+ <property name="justify">center</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">3</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="target-value">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="xpad">5</property>
+ <property name="ypad">1</property>
+ <property name="label" translatable="yes">label8</property>
+ <property name="justify">right</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">1</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="current-value">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="xpad">5</property>
+ <property name="ypad">1</property>
+ <property name="label" translatable="yes">label9</property>
+ <property name="justify">right</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">2</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="solution">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="xpad">5</property>
+ <property name="ypad">1</property>
+ <property name="label" translatable="yes">label10</property>
+ <property name="justify">right</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">3</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
</object>
<packing>
- <property name="right_attach">3</property>
- <property name="x_options">GTK_FILL</property>
- <property name="y_options"></property>
+ <property name="left_attach">0</property>
+ <property name="top_attach">3</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
</packing>
</child>
</object>
<packing>
<property name="expand">False</property>
- <property name="fill">False</property>
- <property name="position">2</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
</packing>
</child>
+ <child>
+ <placeholder/>
+ </child>
</object>
</child>
<action-widgets>
diff --git a/src/number-match.c b/src/number-match.c
index 5e2313d..5f6d860 100644
--- a/src/number-match.c
+++ b/src/number-match.c
@@ -37,12 +37,12 @@
#undef DEBUG_NUMBER_MATCH
/*
- * value_is_error : Check to see if a string begins with one of the magic
+ * value_is_error: Check to see if a string begins with one of the magic
* error strings.
*
- * @str : The string to test
+ * @str: The string to test
*
- * returns : an error if there is one, or NULL.
+ * Returns: an error if there is one, or %NULL.
*/
static GnmValue *
value_is_error (char const *str)
@@ -60,8 +60,8 @@ value_is_error (char const *str)
}
/**
- * format_match_simple :
- * @text : A String to match against.
+ * format_match_simple:
+ * @text: A String to match against.
*
* Attempt to match the supplied string as a simple value.
*
@@ -1138,8 +1138,8 @@ set_money_format (GnmValue *v)
/**
* format_match:
- * @text : The text to parse
- * @cur_fmt : The current format for the value (potentially NULL)
+ * @text: The text to parse
+ * @cur_fmt: The current format for the value (potentially NULL)
* @date_conv: optional date convention
*
* Attempts to parse the supplied string to see if it matches a known value
@@ -1283,9 +1283,9 @@ format_match (char const *text, GOFormat const *cur_fmt,
}
/**
- * format_match_number :
- * @text : The text to parse
- * @cur_fmt : The current format for the value (potentially NULL)
+ * format_match_number:
+ * @text: The text to parse
+ * @cur_fmt: The current format for the value (potentially NULL)
* @date_conv: optional date convention
*
* Attempts to parse the supplied string to see if it matches a known value format.
diff --git a/src/widgets/ChangeLog b/src/widgets/ChangeLog
index c7448f1..a0a6d86 100644
--- a/src/widgets/ChangeLog
+++ b/src/widgets/ChangeLog
@@ -1,3 +1,7 @@
+2013-02-26 Jean Brefort <jean brefort normalesup org>
+
+ * widget-font-selector.c (fs_init): replaced GtkTable with GtkGrid.
+
2013-01-10 Morten Welinder <terra gnome org>
* gnumeric-expr-entry.c (gee_check_tooltip): Look up translated
diff --git a/src/widgets/widget-font-selector.c b/src/widgets/widget-font-selector.c
index 9fea92d..c565431 100644
--- a/src/widgets/widget-font-selector.c
+++ b/src/widgets/widget-font-selector.c
@@ -30,7 +30,7 @@
#include <string.h>
struct _FontSelector {
- GtkBox box;
+ GtkGrid grid;
GtkBuilder *gui;
GtkWidget *font_name_entry;
@@ -50,7 +50,7 @@ struct _FontSelector {
};
typedef struct {
- GtkBoxClass parent_class;
+ GtkGridClass parent_class;
void (* font_changed) (FontSelector *fs, GnmStyle *mstyle);
} FontSelectorClass;
@@ -380,8 +380,8 @@ fs_init (FontSelector *fs)
gnm_style_set_align_h (fs->mstyle, GNM_HALIGN_CENTER);
gnm_style_set_font_size (fs->mstyle, 10);
- gtk_box_pack_start (GTK_BOX (fs),
- go_gtk_builder_get_widget (fs->gui, "toplevel-table"), TRUE, TRUE, 0);
+ gtk_container_add (GTK_CONTAINER (fs),
+ go_gtk_builder_get_widget (fs->gui, "toplevel-grid"));
fs->font_name_entry = go_gtk_builder_get_widget (fs->gui, "font-name-entry");
fs->font_style_entry = go_gtk_builder_get_widget (fs->gui, "font-style-entry");
@@ -395,8 +395,8 @@ fs_init (FontSelector *fs)
goc_canvas_scroll_to (fs->font_preview_canvas, 0, 0);
gtk_widget_override_background_color (w, GTK_STATE_FLAG_NORMAL, &gs_white);
gtk_widget_show_all (w);
- w = go_gtk_builder_get_widget (fs->gui, "font-preview-frame");
- gtk_container_add (GTK_CONTAINER (w), GTK_WIDGET (fs->font_preview_canvas));
+ w = go_gtk_builder_get_widget (fs->gui, "toplevel-grid");
+ gtk_grid_attach (GTK_GRID (w), GTK_WIDGET (fs->font_preview_canvas), 0, 4, 4, 1);
fs->font_preview_grid = GOC_ITEM (goc_item_new (
goc_canvas_get_root (fs->font_preview_canvas),
preview_grid_get_type (),
@@ -406,6 +406,7 @@ fs_init (FontSelector *fs)
"default-value", value_new_string (_("AaBbCcDdEe12345")),
"default-style", fs->mstyle,
NULL));
+ gtk_widget_set_size_request (GTK_WIDGET (fs->font_preview_canvas), -1, 96);
g_signal_connect (G_OBJECT (fs->font_preview_canvas),
"size-allocate",
@@ -459,7 +460,7 @@ fs_class_init (GObjectClass *klass)
}
GSF_CLASS (FontSelector, font_selector,
- fs_class_init, fs_init, GTK_TYPE_BOX)
+ fs_class_init, fs_init, GTK_TYPE_GRID)
GtkWidget *
font_selector_new (void)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]