diff options
author | Carlos Soriano <csoriano@gnome.org> | 2016-02-10 09:56:17 +0100 |
---|---|---|
committer | Carlos Soriano <csoriano@gnome.org> | 2016-02-11 13:24:31 +0100 |
commit | 4a99c692c30e8bde27d7ba614405583df44c1357 (patch) | |
tree | 3733db678d8dadb07311ca0aea2e1a0a9aad86b1 /src/nautilus-list-view.c | |
parent | 0d5c5d371c7eabdfdb91b0b53e646c24c13077e2 (diff) | |
download | nautilus-4a99c692c30e8bde27d7ba614405583df44c1357.tar.gz |
general: add another zoom level
In icon view, add a smaller zoom level to be able for dense views,
and increase the default padding to allow the labels enough space.
Now levels are 48px, 64px, 96px and 128px for icon view, instead of
only 64px, 96px and 128px, but with the increased padding the 64px and
48px are useful.
List view also gains a bigger level, and they become 16px, 32px, 48px,
64px.
Also, adjust the label max width to be larger, but inside the icon
itself. This fixes the label not taking advantage of all the width the
icon provides, and also a few cases where icons were misaligned.
Diffstat (limited to 'src/nautilus-list-view.c')
-rw-r--r-- | src/nautilus-list-view.c | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/src/nautilus-list-view.c b/src/nautilus-list-view.c index 3fde3f9f7..833b0e7d6 100644 --- a/src/nautilus-list-view.c +++ b/src/nautilus-list-view.c @@ -1535,6 +1535,7 @@ trash_orig_path_cell_data_func (GtkTreeViewColumn *column, #define SMALL_ZOOM_ICON_PADDING 0 #define STANDARD_ZOOM_ICON_PADDING 6 #define LARGE_ZOOM_ICON_PADDING 6 +#define LARGER_ZOOM_ICON_PADDING 6 static gint nautilus_list_view_get_icon_padding_for_zoom_level (NautilusListZoomLevel zoom_level) @@ -1546,6 +1547,8 @@ nautilus_list_view_get_icon_padding_for_zoom_level (NautilusListZoomLevel zoom_l return STANDARD_ZOOM_ICON_PADDING; case NAUTILUS_LIST_ZOOM_LEVEL_LARGE: return LARGE_ZOOM_ICON_PADDING; + case NAUTILUS_LIST_ZOOM_LEVEL_LARGER: + return LARGER_ZOOM_ICON_PADDING; default: g_assert_not_reached (); } @@ -2028,7 +2031,7 @@ get_default_zoom_level (void) { NAUTILUS_PREFERENCES_LIST_VIEW_DEFAULT_ZOOM_LEVEL); if (default_zoom_level < NAUTILUS_LIST_ZOOM_LEVEL_SMALL - || default_zoom_level > NAUTILUS_LIST_ZOOM_LEVEL_LARGE) { + || default_zoom_level > NAUTILUS_LIST_ZOOM_LEVEL_LARGER) { default_zoom_level = NAUTILUS_LIST_ZOOM_LEVEL_STANDARD; } @@ -2723,7 +2726,7 @@ nautilus_list_view_set_zoom_level (NautilusListView *view, g_return_if_fail (NAUTILUS_IS_LIST_VIEW (view)); g_return_if_fail (new_level >= NAUTILUS_LIST_ZOOM_LEVEL_SMALL && - new_level <= NAUTILUS_LIST_ZOOM_LEVEL_LARGE); + new_level <= NAUTILUS_LIST_ZOOM_LEVEL_LARGER); if (view->details->zoom_level == new_level) { return; @@ -2752,7 +2755,7 @@ nautilus_list_view_bump_zoom_level (NautilusFilesView *view, int zoom_increment) new_level = list_view->details->zoom_level + zoom_increment; if (new_level >= NAUTILUS_LIST_ZOOM_LEVEL_SMALL && - new_level <= NAUTILUS_LIST_ZOOM_LEVEL_LARGE) { + new_level <= NAUTILUS_LIST_ZOOM_LEVEL_LARGER) { nautilus_list_view_zoom_to_level (view, new_level); } } @@ -2770,7 +2773,7 @@ nautilus_list_view_can_zoom_in (NautilusFilesView *view) { g_return_val_if_fail (NAUTILUS_IS_LIST_VIEW (view), FALSE); - return NAUTILUS_LIST_VIEW (view)->details->zoom_level < NAUTILUS_LIST_ZOOM_LEVEL_LARGE; + return NAUTILUS_LIST_VIEW (view)->details->zoom_level < NAUTILUS_LIST_ZOOM_LEVEL_LARGER; } static gboolean |