From a7570f88f25354a64c7e2c2578b706b11d09110b Mon Sep 17 00:00:00 2001 From: Michael James Gratton Date: Fri, 12 Aug 2016 00:01:00 +1000 Subject: [PATCH] Ensure conversation messages min width is low enough for small screens. * src/client/conversation-viewer/conversation-message.vala (AddressFlowBoxChild): Enable ellipsizing the label. Set the alignment so labels are correctly aligned at narrow widths. Removed some cruft. * ui/conversation-message.ui: Ensure long words in subject are wrapped. Ensure there's always at least two cols for recipient address flow boxes. --- src/client/conversation-viewer/conversation-message.vala | 6 ++---- ui/conversation-message.ui | 5 +++-- 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/src/client/conversation-viewer/conversation-message.vala b/src/client/conversation-viewer/conversation-message.vala index c39addcc..ca43686f 100644 --- a/src/client/conversation-viewer/conversation-message.vala +++ b/src/client/conversation-viewer/conversation-message.vala @@ -28,9 +28,8 @@ public class ConversationMessage : Gtk.Box { this.address = address; Gtk.Label label = new Gtk.Label(null); - //label.set_halign(Gtk.Align.START); - //label.set_valign(Gtk.Align.BASELINE); - //label.set_xalign(0.0f); + label.ellipsize = Pango.EllipsizeMode.END; + label.set_xalign(0.0f); string name = Geary.HTML.escape_markup(address.name); string addr = Geary.HTML.escape_markup(address.address); @@ -47,7 +46,6 @@ public class ConversationMessage : Gtk.Box { add(label); set_halign(Gtk.Align.START); - //child.set_valign(Gtk.Align.START); show_all(); } diff --git a/ui/conversation-message.ui b/ui/conversation-message.ui index 74f8f406..85e07a02 100644 --- a/ui/conversation-message.ui +++ b/ui/conversation-message.ui @@ -198,6 +198,7 @@ start Subject True + word-char True 0