[nautilus/wip/apoos-maximus/gsoc2020: 23/26] properties-window: Reposition icon above basic grid




commit 33dc065b41c4f19c76d7db996f60c850b1e23c46
Author: Apoorv Sachan <apoorv 99 sachan gmail com>
Date:   Tue Jul 14 02:20:52 2020 +0530

    properties-window: Reposition icon above basic grid
    
    With the title labels aligned to the right, the icon widget is isolated
    at the left side, pushed to the edge and disconnected.
    
    Center the icon horizontally, at the top of the page, for better visual
    balance. Also, make it slightly larger, using standard icon size.

 src/nautilus-properties-window.c               | 6 +++---
 src/resources/ui/nautilus-properties-window.ui | 2 ++
 2 files changed, 5 insertions(+), 3 deletions(-)
---
diff --git a/src/nautilus-properties-window.c b/src/nautilus-properties-window.c
index 887474879..e74d5471c 100644
--- a/src/nautilus-properties-window.c
+++ b/src/nautilus-properties-window.c
@@ -417,13 +417,13 @@ get_image_for_properties_window (NautilusPropertiesWindow  *window,
 
         if (!icon)
         {
-            icon = nautilus_file_get_icon (file, NAUTILUS_CANVAS_ICON_SIZE_SMALL, icon_scale,
+            icon = nautilus_file_get_icon (file, NAUTILUS_CANVAS_ICON_SIZE_STANDARD, icon_scale,
                                            NAUTILUS_FILE_ICON_FLAGS_USE_THUMBNAILS |
                                            NAUTILUS_FILE_ICON_FLAGS_IGNORE_VISITING);
         }
         else
         {
-            new_icon = nautilus_file_get_icon (file, NAUTILUS_CANVAS_ICON_SIZE_SMALL, icon_scale,
+            new_icon = nautilus_file_get_icon (file, NAUTILUS_CANVAS_ICON_SIZE_STANDARD, icon_scale,
                                                NAUTILUS_FILE_ICON_FLAGS_USE_THUMBNAILS |
                                                NAUTILUS_FILE_ICON_FLAGS_IGNORE_VISITING);
             if (!new_icon || new_icon != icon)
@@ -451,7 +451,7 @@ get_image_for_properties_window (NautilusPropertiesWindow  *window,
 
     if (icon_pixbuf != NULL)
     {
-        *icon_pixbuf = nautilus_icon_info_get_pixbuf_at_size (icon, NAUTILUS_CANVAS_ICON_SIZE_SMALL);
+        *icon_pixbuf = nautilus_icon_info_get_pixbuf_at_size (icon, NAUTILUS_CANVAS_ICON_SIZE_STANDARD);
     }
 
     g_object_unref (icon);
diff --git a/src/resources/ui/nautilus-properties-window.ui b/src/resources/ui/nautilus-properties-window.ui
index d65334264..250a6ca05 100644
--- a/src/resources/ui/nautilus-properties-window.ui
+++ b/src/resources/ui/nautilus-properties-window.ui
@@ -20,11 +20,13 @@
                 <property name="visible">True</property>
                 <property name="can_focus">False</property>
                 <property name="border_width">12</property>
+                <property name="orientation">vertical</property>
                 <property name="spacing">12</property>
                 <child>
                   <object class="GtkStack" id="icon_stack">
                     <property name="visible">True</property>
                     <property name="can_focus">False</property>
+                    <property name="halign">center</property>
                     <property name="valign">start</property>
                     <child>
                       <object class="GtkImage" id="icon_image">


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