mirror of
https://gitlab.gnome.org/GNOME/nautilus
synced 2024-11-05 16:04:31 +00:00
trash-bar: Ellipsize subtitle label
The subtitle label is long and may be even longer in some locales. As a result, a wide minimum width is forced on the whole window, which is not desirable. So, make it ellipsize and also add a tooltip. Fixes https://gitlab.gnome.org/GNOME/nautilus/-/issues/2012
This commit is contained in:
parent
42b0362e98
commit
6afce418af
1 changed files with 5 additions and 1 deletions
|
@ -212,6 +212,7 @@ static void
|
|||
nautilus_trash_bar_init (NautilusTrashBar *bar)
|
||||
{
|
||||
GtkWidget *content_area, *action_area, *w;
|
||||
const gchar *subtitle_text;
|
||||
GtkWidget *label;
|
||||
GtkWidget *subtitle;
|
||||
PangoAttrList *attrs;
|
||||
|
@ -228,7 +229,10 @@ nautilus_trash_bar_init (NautilusTrashBar *bar)
|
|||
gtk_label_set_attributes (GTK_LABEL (label), attrs);
|
||||
pango_attr_list_unref (attrs);
|
||||
|
||||
subtitle = gtk_label_new (_("Trashed items are automatically deleted after a period of time"));
|
||||
subtitle_text = _("Trashed items are automatically deleted after a period of time");
|
||||
subtitle = gtk_label_new (subtitle_text);
|
||||
gtk_widget_set_tooltip_text (subtitle, subtitle_text);
|
||||
gtk_label_set_ellipsize (GTK_LABEL (subtitle), PANGO_ELLIPSIZE_END);
|
||||
|
||||
g_settings_bind (gnome_privacy_preferences,
|
||||
"remove-old-trash-files",
|
||||
|
|
Loading…
Reference in a new issue