emacs-devel
[Top][All Lists]
Advanced

[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: Fri, 2 May 2003 14:44:46 +0200 (CEST)

> >>  A user may type C-x C-f FILENAME in the dired buffer.  With
> >>  the above method, we don't know how to encode FILENAME.
> 
> > Why would this change?  I am only talking about file names that dired
> > reads from a directory.  No need to change C-x C-f.
> 
> Typing `f' works fine but C-x C-f doesn't, which is not a
> good behaviour.

I think I understand now.  You mean if dired uses UTF8, and file system
coding is Latin-1, C-x C-f would then use Latin-1, and possibly fail?

I agree that this is bad, but I am not sure anything can be done
about it.  Both KDE and GNOME file managers and file dialogs fail to open
the right file in certain cases.  I think it is worse if dired fails on
'f' since in that case the file name is supplied by dired, not the user.
For C-x C-f there is always TAB to see what Emacs thinks the file is called.

> 
> >>  And, even if one types `f' to visit a file, in that file
> >>  buffer, we loose the information of the original
> >>  representation.
> 
> > Then Emacs as a whole should change.
> 
> Yes, my proposal is to change Emacs' behavior as to filename
> handing as a whole in a fairly low cost.
> 

I am not sure your case covers all cases.  If a file name was
latin-1 and then converted to UTF8 (outside Emacs), Emacs would think it is
still latin-1, no?
It involves a bit of user interaction, making it intrusive.

> By the way, I've just thought of this weird situation.  One
> has a file of utf-8 name in a directly of latin-1 name.  :-(
> I think we can say sorry in such a case.

But then you would be using non-printable latin-1 characters.  I don't
think this is something one has to handle.

        Jan D.





reply via email to

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