GNOME Bugzilla – Bug 114296
file and icon entries cannot handle locale's encoded filenames
Last modified: 2010-12-21 08:24:32 UTC
In G_BROKEN_FILENAMES==True environments,(so are RHL 8 & 9 environemtns by default), test-gnome, a libgnomeui test program, cannot handle locale's encoded filenames at least in the following two widgets. [case 1:file entry] 1. bring up a "file entry" and browse any existing file whose filename contains current locale's string. 2. Clicking "Update file labels" does not show the filename at "File name(if exists only)". [case 2:icon entry] 1. bring up a "icon entry and browse a existing image-file (png, jpeg,..) whose filename contains current locale's string. 2. It does not show the image, and wrongly says "Nothing selected" for the icon filename. It is because of lack of conversion bettween file-systems's filenames and UTF-8. While gtk-entry uses UTF-8 in set&get_text functions(), g_file_test(), gdk_pixbuf_new_file(), ..these must be called with filename strings which are actually used in the filesystem.
Sorry for the spam. Just trying something
Do you have a patch to fix this?
Any news here?
I'm not sure if it's exactly the same issue, but I have encountered similar problems when opening and diplaying names of files that contained ISO-8859-2 characters (my locales are pl_PL) in few gnome applications. The files seem to open (using new filechooser) and save just fine, wihout a need to convert the strings, but when trying to diplay the names of the files I'm getting pango errors (non-valid UTF-8 strings). Names are shown partially, or not shown at all. There is quite simple fix for this: use g_get_charset to check if system locale is UTF-8, if not, use g_strcompress and g_filename_to_utf8 functions to convert filenames to utf8. In my opinion this should be done by filechooser (or any othe widget that provides a filename), so applications would oparate only on valid UTF-8 filenames.
Is this problem still there or are we handling these situations now? I guess most people have moved towards using UTF-8 for filenames by now though?
No response in ages. If this is still a problem the new bug should be filed against gtk+ I guess.