[fractal] main_window: wrap room_info GtkBox in GtkScrolledWindow



commit 36c1d827b345068a8fe4cc4cb09242d32444e674
Author: Christopher Davis <brainblasted disroot org>
Date:   Tue Jan 29 12:12:46 2019 -0500

    main_window: wrap room_info GtkBox in GtkScrolledWindow
    
    The room_info labels could cause the leaflet to fold before
    they could ellipsize, causing Fractal to fold at the wrong width. By wrapping in ScrolledWindow we work 
around that issue.

 fractal-gtk/res/ui/main_window.ui | 67 +++++++++++++++++++++++----------------
 1 file changed, 39 insertions(+), 28 deletions(-)
---
diff --git a/fractal-gtk/res/ui/main_window.ui b/fractal-gtk/res/ui/main_window.ui
index 726d3260..c6dcc52e 100644
--- a/fractal-gtk/res/ui/main_window.ui
+++ b/fractal-gtk/res/ui/main_window.ui
@@ -874,39 +874,50 @@
                       </object>
                     </child>
                     <child type="title">
-                      <object class="GtkBox" id="room_info">
+                      <object class="GtkScrolledWindow">
                         <property name="visible">True</property>
                         <property name="can_focus">False</property>
-                        <property name="orientation">vertical</property>
-                        <child>
-                          <object class="GtkLabel" id="room_name">
-                            <property name="can_focus">False</property>
-                            <property name="label" translatable="yes">Room name</property>
-                            <property name="ellipsize">end</property>
-                            <style>
-                              <class name="title"/>
-                            </style>
-                          </object>
-                          <packing>
-                            <property name="expand">False</property>
-                            <property name="fill">True</property>
-                            <property name="position">0</property>
-                          </packing>
-                        </child>
+                        <property name="hexpand">True</property>
+                        <property name="hscrollbar_policy">never</property>
+                        <property name="vscrollbar_policy">never</property>
+                        <property name="propagate_natural_height">True</property>
+                        <property name="propagate_natural_width">False</property>
                         <child>
-                          <object class="GtkLabel" id="room_topic">
+                          <object class="GtkBox" id="room_info">
+                            <property name="visible">True</property>
                             <property name="can_focus">False</property>
-                            <property name="label" translatable="yes">Room topic</property>
-                            <property name="ellipsize">end</property>
-                            <style>
-                              <class name="subtitle"/>
-                            </style>
+                            <property name="orientation">vertical</property>
+                            <child>
+                              <object class="GtkLabel" id="room_name">
+                                <property name="can_focus">False</property>
+                                <property name="label" translatable="yes">Room name</property>
+                                <property name="ellipsize">end</property>
+                                <style>
+                                  <class name="title"/>
+                                </style>
+                              </object>
+                              <packing>
+                                <property name="expand">False</property>
+                                <property name="fill">True</property>
+                                <property name="position">0</property>
+                              </packing>
+                            </child>
+                            <child>
+                              <object class="GtkLabel" id="room_topic">
+                                <property name="can_focus">False</property>
+                                <property name="label" translatable="yes">Room topic</property>
+                                <property name="ellipsize">end</property>
+                                <style>
+                                  <class name="subtitle"/>
+                                </style>
+                              </object>
+                              <packing>
+                                <property name="expand">False</property>
+                                <property name="fill">True</property>
+                                <property name="position">1</property>
+                              </packing>
+                            </child>
                           </object>
-                          <packing>
-                            <property name="expand">False</property>
-                            <property name="fill">True</property>
-                            <property name="position">1</property>
-                          </packing>
                         </child>
                       </object>
                     </child>


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