[fractal] uibuilder: improve adaptive UI



commit 0b06dba073f59f3592522a31511a8d6205ef6fbf
Author: Arnaud Ferraris <arnaud ferraris collabora com>
Date:   Thu Apr 23 12:29:08 2020 +0200

    uibuilder: improve adaptive UI
    
    `sventry_disabled` sets a line-wrap mode, but doesn't enable line-wrap.
    While this is fine for `en` locales, some translations (at least `fr`)
    have a longer text for this label, which causes the minimum window width
    to exceed 400px.
    
    Enabling line-wrap for `sventry_disabled` solves this issue.

 fractal-gtk/src/uibuilder.rs | 1 +
 1 file changed, 1 insertion(+)
---
diff --git a/fractal-gtk/src/uibuilder.rs b/fractal-gtk/src/uibuilder.rs
index b570ca87..34d7adfd 100644
--- a/fractal-gtk/src/uibuilder.rs
+++ b/fractal-gtk/src/uibuilder.rs
@@ -53,6 +53,7 @@ impl UI {
         )));
         sventry_disabled.set_hexpand(false);
         sventry_disabled.get_style_context().add_class("dim-label");
+        sventry_disabled.set_line_wrap(true);
         sventry_disabled.set_line_wrap_mode(pango::WrapMode::WordChar);
         sventry_stack.add_named(&sventry_disabled, "Disabled Entry");
 


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