[evolution] Bug 753704 - Wrap file names in the picture gallery icon view



commit dabda1058c0beab67468125790fd740784fc6569
Author: Jean-François Fortin Tam <nekohayo gmail com>
Date:   Mon Feb 26 13:48:37 2018 +0100

    Bug 753704 - Wrap file names in the picture gallery icon view

 src/composer/e-composer-private.c |    1 +
 src/e-util/e-picture-gallery.c    |    5 +++++
 2 files changed, 6 insertions(+), 0 deletions(-)
---
diff --git a/src/composer/e-composer-private.c b/src/composer/e-composer-private.c
index 24413c8..fa324f8 100644
--- a/src/composer/e-composer-private.c
+++ b/src/composer/e-composer-private.c
@@ -236,6 +236,7 @@ e_composer_private_constructed (EMsgComposer *composer)
                E_ATTACHMENT_PANED (priv->attachment_paned));
 
        widget = gtk_paned_new (GTK_ORIENTATION_VERTICAL);
+       gtk_paned_set_wide_handle (GTK_PANED (widget), TRUE);
        gtk_box_pack_start (GTK_BOX (container), widget, TRUE, TRUE, 0);
        gtk_widget_show (widget);
 
diff --git a/src/e-util/e-picture-gallery.c b/src/e-util/e-picture-gallery.c
index 217ac5b..21e7419 100644
--- a/src/e-util/e-picture-gallery.c
+++ b/src/e-util/e-picture-gallery.c
@@ -365,6 +365,11 @@ picture_gallery_constructed (GObject *object)
        gtk_icon_view_set_text_column (icon_view, COL_FILENAME_TEXT);
        gtk_icon_view_set_tooltip_column (icon_view, -1);
 
+       /* Fit more icons by letting text wrap, especially with long filenames.
+        * The thumbnail is usually 128x128, so match it, as the text won't wrap
+        * smaller than the thumbnail width anyway. */
+       gtk_icon_view_set_item_width (icon_view, 128);
+
        list = gtk_target_list_new (NULL, 0);
        gtk_target_list_add_uri_targets (list, 0);
        targets = gtk_target_table_new_from_list (list, &n_targets);


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]