From 35deb1eb304f69de82fab69c8b4f8f5d8bbaf8ad Mon Sep 17 00:00:00 2001 From: Joachim Priesner <137221-jpr@users.noreply.gitlab.gnome.org> Date: Wed, 26 Jun 2024 19:14:10 +0200 Subject: [PATCH] dialogs: Don't escape underscores in Welcome Dialog recent files list MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit It seems unnecessary – at least on my system, files with underscores in their names are shown with two underscores in the recent files list. This patch fixes that. --- app/dialogs/welcome-dialog.c | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/app/dialogs/welcome-dialog.c b/app/dialogs/welcome-dialog.c index 79471d903e..4fff11bca0 100644 --- a/app/dialogs/welcome-dialog.c +++ b/app/dialogs/welcome-dialog.c @@ -739,7 +739,6 @@ welcome_dialog_create_creation_page (Gimp *gimp, GimpThumbnail *icon; const gchar *name; gchar *basename; - gchar *escaped; imagefile = (GimpImagefile *) gimp_container_get_child_by_index (gimp->documents, i); @@ -749,14 +748,11 @@ welcome_dialog_create_creation_page (Gimp *gimp, name = gimp_file_get_utf8_name (file); basename = g_path_get_basename (name); - escaped = gimp_escape_uline (basename); - g_free (basename); - /* If the file is not found, remove it and try to * load another one if possible */ if (! g_file_test (name, G_FILE_TEST_IS_REGULAR)) { - g_free (escaped); + g_free (basename); if (list_count < num_images) list_count++; @@ -796,8 +792,8 @@ welcome_dialog_create_creation_page (Gimp *gimp, if (thumbnail) gtk_grid_attach (GTK_GRID (grid), thumbnail, 1, 0, 1, 1); - name_label = gtk_label_new (escaped); - g_free (escaped); + name_label = gtk_label_new (basename); + g_free (basename); g_object_set (name_label, "xalign", 0.0, NULL); gtk_grid_attach (GTK_GRID (grid), name_label, 2, 0, 1, 1);