[gnome-builder/wip/chergert/layout: 77/118] devhelp: align search icon with cell renderer icons
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-builder/wip/chergert/layout: 77/118] devhelp: align search icon with cell renderer icons
- Date: Wed, 5 Jul 2017 11:54:32 +0000 (UTC)
commit 0676d20aa72bf5640a5a261d1f14eb813b79a0b3
Author: Christian Hergert <chergert redhat com>
Date: Sun Jul 2 20:49:02 2017 -0700
devhelp: align search icon with cell renderer icons
plugins/devhelp/gbp-devhelp-menu-button.c | 14 ++++++++++++++
1 files changed, 14 insertions(+), 0 deletions(-)
---
diff --git a/plugins/devhelp/gbp-devhelp-menu-button.c b/plugins/devhelp/gbp-devhelp-menu-button.c
index 168161b..b8cc3d2 100644
--- a/plugins/devhelp/gbp-devhelp-menu-button.c
+++ b/plugins/devhelp/gbp-devhelp-menu-button.c
@@ -144,6 +144,7 @@ monkey_patch_devhelp (GbpDevhelpMenuButton *self)
GtkCellRenderer *cell;
GtkTreeModel *model;
GType column_type;
+ GtkSearchEntry *search;
g_assert (GBP_IS_DEVHELP_MENU_BUTTON (self));
@@ -187,6 +188,19 @@ monkey_patch_devhelp (GbpDevhelpMenuButton *self)
gtk_cell_layout_set_cell_data_func (GTK_CELL_LAYOUT (column), cell,
gbp_devhelp_menu_button_pixbuf_data_func,
NULL, NULL);
+
+ /*
+ * Now find the GtkSearchEntry and adjust the margins on it to match
+ * our style and align the search icon with our icon cell renderer.
+ */
+ search = dzl_gtk_widget_find_child_typed (GTK_WIDGET (self->sidebar), GTK_TYPE_SEARCH_ENTRY);
+ if (search != NULL)
+ g_object_set (search,
+ "margin-top", 0,
+ "margin-end", 0,
+ "margin-start", 0,
+ "margin-bottom", 6,
+ NULL);
}
static void
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]