[gimp/gimpmetadata-new-wip] plug-ins: fix showing utf-8 filenames correctly
- From: Hartmut Kuhse <hartmutkuhse src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp/gimpmetadata-new-wip] plug-ins: fix showing utf-8 filenames correctly
- Date: Sat, 7 Jan 2017 10:02:24 +0000 (UTC)
commit 601654beb8c4275da7f2db0747473466b038cf6f
Author: Hartmut Kuhse <hk_priv gmx de>
Date: Sat Jan 7 11:01:28 2017 +0100
plug-ins: fix showing utf-8 filenames correctly
app/pdb/item-cmds.c | 20 ++++++++++----------
libgimpbase/gimpmetadata.c | 3 ++-
plug-ins/common/attributes.c | 2 +-
plug-ins/common/iptc.c | 2 +-
4 files changed, 14 insertions(+), 13 deletions(-)
---
diff --git a/app/pdb/item-cmds.c b/app/pdb/item-cmds.c
index 0ba96b8..7ebbe60 100644
--- a/app/pdb/item-cmds.c
+++ b/app/pdb/item-cmds.c
@@ -823,11 +823,11 @@ item_set_tattoo_invoker (GimpProcedure *procedure,
static GimpValueArray *
item_get_metadata_invoker (GimpProcedure *procedure,
- Gimp *gimp,
- GimpContext *context,
- GimpProgress *progress,
- const GimpValueArray *args,
- GError **error)
+ Gimp *gimp,
+ GimpContext *context,
+ GimpProgress *progress,
+ const GimpValueArray *args,
+ GError **error)
{
gboolean success = TRUE;
GimpValueArray *return_vals;
@@ -855,11 +855,11 @@ item_get_metadata_invoker (GimpProcedure *procedure,
static GimpValueArray *
item_set_metadata_invoker (GimpProcedure *procedure,
- Gimp *gimp,
- GimpContext *context,
- GimpProgress *progress,
- const GimpValueArray *args,
- GError **error)
+ Gimp *gimp,
+ GimpContext *context,
+ GimpProgress *progress,
+ const GimpValueArray *args,
+ GError **error)
{
gboolean success = TRUE;
GimpItem *item;
diff --git a/libgimpbase/gimpmetadata.c b/libgimpbase/gimpmetadata.c
index d1f360f..7631d55 100644
--- a/libgimpbase/gimpmetadata.c
+++ b/libgimpbase/gimpmetadata.c
@@ -2756,9 +2756,10 @@ gimp_metadata_load_from_file (GFile *file,
if (! gexiv2_metadata_open_path (GEXIV2_METADATA (metadata), filename, error))
{
+ g_set_error (error, gimp_metadata_error_quark (), 0,
+ _("GExiv2: Can't load metadata"));
g_free (filename);
g_object_unref (metadata);
-
return NULL;
}
}
diff --git a/plug-ins/common/attributes.c b/plug-ins/common/attributes.c
index 3eb69f5..9b77b65 100644
--- a/plug-ins/common/attributes.c
+++ b/plug-ins/common/attributes.c
@@ -315,7 +315,7 @@ attributes_dialog (gint32 item_id,
switch (source)
{
case ATT_IMAGE:
- item_name = g_filename_display_basename (gimp_image_get_uri (item_id));
+ item_name = gimp_image_get_name (item_id);
header = g_strdup_printf ("Image");
role = g_strdup_printf ("gimp-image-attributes-dialog");
pixbuf = gimp_image_get_thumbnail (item_id, THUMB_SIZE, THUMB_SIZE,
diff --git a/plug-ins/common/iptc.c b/plug-ins/common/iptc.c
index d140152..73b8028 100644
--- a/plug-ins/common/iptc.c
+++ b/plug-ins/common/iptc.c
@@ -262,7 +262,7 @@ iptc_dialog (gint32 item_id,
switch (source)
{
case ATT_IMAGE:
- fname = g_filename_display_basename (gimp_image_get_uri (item_id));
+ fname = gimp_image_get_name (item_id);
header = g_strdup_printf ("Image");
title = g_strdup_printf ("Image: %s", fname);
role = g_strdup_printf ("gimp-image-iptc-dialog");
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]