diff options
author | Bastien Nocera <hadess@hadess.net> | 2010-12-13 14:03:10 +0000 |
---|---|---|
committer | Bastien Nocera <hadess@hadess.net> | 2010-12-13 14:03:10 +0000 |
commit | e92fba97a786f72de89df7833d4738022c30cf60 (patch) | |
tree | de4cca170c25de6d0acd523f2fad6abc95cda015 /shell/cc-shell-item-view.c | |
parent | 40d882da1c786efef5f442e6200700c8180c0648 (diff) | |
download | gnome-control-center-e92fba97a786f72de89df7833d4738022c30cf60.tar.gz |
shell: Set wrap mode to "word" for the icon text
https://bugzilla.gnome.org/show_bug.cgi?id=637035
Diffstat (limited to 'shell/cc-shell-item-view.c')
-rw-r--r-- | shell/cc-shell-item-view.c | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/shell/cc-shell-item-view.c b/shell/cc-shell-item-view.c index a1cd9d7b6..7b0b37ae3 100644 --- a/shell/cc-shell-item-view.c +++ b/shell/cc-shell-item-view.c @@ -148,6 +148,26 @@ iconview_item_activated_cb (GtkIconView *icon_view, g_free (id); } +void +cc_shell_item_view_update_cells (CcShellItemView *view) +{ + GList *cells, *l; + + cells = gtk_cell_layout_get_cells (GTK_CELL_LAYOUT (view)); + for (l = cells ; l != NULL; l = l->next) + { + GtkCellRenderer *cell = l->data; + + if (GTK_IS_CELL_RENDERER_TEXT (cell)) { + g_object_set (G_OBJECT (cell), + "wrap-mode", PANGO_WRAP_WORD, + NULL); + /* We only have one text cell */ + break; + } + } +} + static void cc_shell_item_view_class_init (CcShellItemViewClass *klass) { |