From ef97da75e63e837ccdc635edb14d06028c828f7d Mon Sep 17 00:00:00 2001 From: Jeena Date: Tue, 15 Aug 2017 16:53:05 +0200 Subject: [PATCH] Make labels in contact-sheet selectable Right now to be able to copy & paste a name, address or telephone number one has to change to edit mode, select the text and then copy it. This is not a good UI, therefor thes patch makes the labels in the contact-sheet selectable. This way the user doesn't have to change to edit mode to be able to copy & paste the information. --- src/contacts-contact-sheet.vala | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/contacts-contact-sheet.vala b/src/contacts-contact-sheet.vala index 37b7330..bbeb9ba 100644 --- a/src/contacts-contact-sheet.vala +++ b/src/contacts-contact-sheet.vala @@ -76,6 +76,7 @@ public class Contacts.ContactSheet : Grid { value_label.set_halign (Align.START); value_label.set_ellipsize (Pango.EllipsizeMode.END); value_label.wrap_mode = Pango.WrapMode.CHAR; + value_label.set_selectable (true); /* FIXME: hardcode gap to match the button size */ type_label.margin_top = 3; @@ -111,6 +112,7 @@ public class Contacts.ContactSheet : Grid { name_label.margin_start = 6; name_label.set_ellipsize (Pango.EllipsizeMode.END); name_label.xalign = 0.0f; + name_label.set_selectable (true); c.keep_widget_uptodate (name_label, (w) => { (w as Label).set_markup (Markup.printf_escaped ("%s", c.display_name));