[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Strange behaviour with dired and UTF8

From: Jan D.
Subject: Re: Strange behaviour with dired and UTF8
Date: Wed, 7 May 2003 19:40:22 +0200

onsdagen den 7 maj 2003 kl 18.31 skrev Stefan Monnier:

Say I have two files, one in UTF-8 and one in latin-1.  Emacs has only
one coding system for file names, say it is latin-1.

Question: how do other applications deal with such situations ?

I mean, of course Emacs should do better than the rest of the crowd,
but if most/all other applications fail miserably, then it's unlikely
that people will use such setups and it would be wrong for Emacs to
make it easier to create such a setup (unless maybe only Emacs
will ever care about those file names, of course).

I can only say that GNOME (Nautilus) deals with this fine, better than
most.  It can actually display two files, one in latin-1 and the other
in UTF-8 that has the same display representation so it looks like
the two files have the same name.  When clicking on them (to open
for example), it opens the correct file (I use the size of the files
to tell them apart).  When renaming a file, it uses UTF-8 always.
I think this is as good as it gets.

I don't know in detail, but given that UTF-8 is so fundamental to GNOME,
I think Nautilus first tries UTF-8, and if the name isn't valid UTF-8, it tries the users locale. Actually Nautilus behaves better than most other GNOME applications. For example, gedit always tries UTF-8 for displaying
the file name and says "invalid UTF-8" if that fails.

KDE (Konquerer) seems to use the locale character set always.

Other systems can change the view character set.  Much like you
can do in Netscape/Mozilla.  Open up a directory and then you can
toggle the coding system used to display file names (in Mozilla:
View -> Character coding).  This is what I thought Emacs could do, but
it lost the original file name.

        Jan D.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]