EAttachmentIconView: Improve display settings
This bug report is the result of my investigations with the GTK inspector to figure out the "magic combination" of optimal settings to make the iconview look and behave much better than it ever did. First some before/after screenshots:
Another before/after shot with all items selected and a wider window layout:
In addition to the myriad of issues solved that we can see here, this also solves https://bugzilla.gnome.org/show_bug.cgi?id=763726
Here are my recommendations in order to achieve these results:
- In the EAttachmentIconView:
- In the GtkCellAreaBox
- In the GtkCellRendererPixbuf:
- set "xalign" to 0.0, not 0.5 (partially fixes https://bugzilla.gnome.org/show_bug.cgi?id=763726)
- set "yalign" to 1.0 so that the images are always flush with the text
- unset stock-size to 0 or -1 (this lets you set the width and height later)
- set "width" to 96 (rather than 128; but 96 only works well if you use ALL my tricks below, including the 64 height AND 80% font size)
- set "height" to 64 (yes really, not 128; it works out better for space savings and widescreen image uniformity; for some reason it seems GtkIconview has some cropping behavior going on sometimes)
- In the GtkCellRendererText:
- set "alignment" to PANGO_ALIGN_LEFT instead of PANGO_ALIGN_CENTER (partially fixes https://bugzilla.gnome.org/show_bug.cgi?id=763726)
- set "scale" to 0.8 (so that the text is smaller at 80%, and has a much lower tendency to wrap
- unset "wrap-width" to 0 (instead of 150) - this seems unimportant at first, but it actually is the thing that allows nice homogenous thumbnail sizes when everything else is set
- unset xpad to 0 (partially fixes https://bugzilla.gnome.org/show_bug.cgi?id=763726)
- maybe also unset ypad to 0 because space is constrained anyway, but not strictly required
- In the GtkCellRendererPixbuf:
- In the GtkCellAreaBox
Notes:
- You can keep "wrap-mode" at PANGO_WRAP_WORD, not wrap char or wrap word-char
- The "width" property doesn't seem to affect anything?
- These changes have been devised by trial and error using the GTK Inspector on Evolution 3.38.x
I suspect there might also be other areas of the app that might benefit from these findings too, such as the "gallery" pane (which previously had some initial round of optimizations in https://bugzilla.gnome.org/show_bug.cgi?id=753704 ; I don't know if there are other areas where iconview is used...