[gnome-control-center/wip/benzea/wifi-panel-with-editor-changes: 3/19] connection-editor: Improve VPN selection
- From: Benjamin Berg <bberg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-control-center/wip/benzea/wifi-panel-with-editor-changes: 3/19] connection-editor: Improve VPN selection
- Date: Thu, 13 Dec 2018 17:09:32 +0000 (UTC)
commit 271c72ca1957b670081ccf98cda3aa58b46dd0db
Author: Adrien Plazas <kekun plazas laposte net>
Date: Wed Dec 5 08:32:11 2018 +0100
connection-editor: Improve VPN selection
Make the names ellipsizable to allow the dialog to reach narrower sizes
and align the labels at the start so they remain aligned regardless the
size of the dialog.
panels/network/connection-editor/net-connection-editor.c | 3 +++
1 file changed, 3 insertions(+)
---
diff --git a/panels/network/connection-editor/net-connection-editor.c
b/panels/network/connection-editor/net-connection-editor.c
index 609556b8d..d60382bf3 100644
--- a/panels/network/connection-editor/net-connection-editor.c
+++ b/panels/network/connection-editor/net-connection-editor.c
@@ -691,12 +691,15 @@ select_vpn_type (NetConnectionEditor *editor, GtkListBox *list)
gtk_widget_set_margin_bottom (row_box, 12);
name_label = gtk_label_new (name);
+ gtk_label_set_ellipsize (GTK_LABEL (name_label), PANGO_ELLIPSIZE_END);
+ gtk_label_set_xalign (GTK_LABEL (name_label), 0.0f);
gtk_widget_set_halign (name_label, GTK_ALIGN_START);
gtk_box_pack_start (GTK_BOX (row_box), name_label, FALSE, TRUE, 0);
desc_label = gtk_label_new (NULL);
gtk_label_set_markup (GTK_LABEL (desc_label), desc_markup);
gtk_label_set_line_wrap (GTK_LABEL (desc_label), TRUE);
+ gtk_label_set_xalign (GTK_LABEL (desc_label), 0.0f);
gtk_widget_set_halign (desc_label, GTK_ALIGN_START);
context = gtk_widget_get_style_context (desc_label);
gtk_style_context_add_class (context, "dim-label");
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]