help-gnu-emacs
[Top][All Lists]
Advanced

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

Reading national characters in filenames on Mac OS X?


From: Jonas Steverud
Subject: Reading national characters in filenames on Mac OS X?
Date: Sat, 26 Apr 2003 09:18:42 +0200
User-agent: Gnus/5.090018 (Oort Gnus v0.18) Emacs/21.2 (darwin)

Hello.

(In case this should be a faq, please direct me to wherever I can find
the asnwer, I've googled around but whithout success.)

Since I'm swedish speaking I find it quite natural to have 
directory names and filenames in swedish, which means that quite a
few will contain the swedish letters, åäöÅÄÖ.

The problem is that Emacs[1] cannot handle those files since Mac OS X
10.2.5 use UTF-8 (?) for encoding filenames - not in the current set-up
at least. It thinks the multibyte is two characters.

Does anyone know how to make Emacs understand that the names are UTF-8
encoded?

Apple's X11.app ß3
LANG=sv_SE
LC_CTYPE=iso_8859_1

(set-language-environment "Latin-1")

The above probably sets the following:
default-file-name-coding-system's value is iso-latin-1
file-name-coding-system's value is nil

I tried to set file-name-coding-system to 'utf-8 and 'mac-roman and
Emacs stops complaing about the file's name (with iso-latin-1 it can
walk down a directory path with non-A-Z but when I try to select a
file it claims the directory doesn't exist ["run M-x make-directory"])
but I don't see the non-A-Z character but some other two character
representation, i.e. Emacs doesn't decode the multibyte when it is viewed.

What is the recommended set-up if I want to be able to read a Mac
filesystem and edit text in Latin-1 - I have too many files using
Latin-1, esp. Gnus, to change to UTF-8. But UTF-8 for editing is an
option if all my old files won't confuse Emacs, i.e. I don't want to
lose all my mails.

Is there a (set-language-environemnt "utf-8")-equivalent? I couldn't
find anything appropriate. :-(

Any suggestions?

-------
[1]  GNU Emacs 21.2.1 (powerpc-apple-darwin, X toolkit) of 2003-01-02
on Neocortex.local. Downloaded and patched via the Fink project.
-- 
(         http://hem.bredband.net/steverud        !     Wei Wu Wei     )
(        Meaning of U2 Lyrics, Roleplaying        !  To Do Without Do  )


reply via email to

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