* emacs cannot read accent properly in a path
@ 2006-12-23 10:41 PG
2006-12-23 14:09 ` Peter Dyballa
0 siblings, 1 reply; 9+ messages in thread
From: PG @ 2006-12-23 10:41 UTC (permalink / raw)
I am newby in the matter. I want to share a FAT32 hard disk using both
Windows XP and GNU Linux Ubuntu 6.10. The ubuntu terminal (utf-8) work OK
and MS DOS paths (even with blanks in the name and accents) are well read.
Eg:
/users/Documents and Settings/giraudoux/Mes documents/Thèse
Robardet/Analyses 0611$
However when I wanted to read the same path from e-macs (eg to import a file
C-x C-f), I get this:
/users/Documents and Settings/giraudoux/Mes documents/ThA"se
Robardet/Analyses 0611$
(actually a sign ~ is above the A), and of course, files cannot be read.
I have tried to manage to get emacs reading such a path including accents
correctly with those commands into .emacs
(set-terminal-coding-system 'utf-8)
(set-keyboard-coding-system 'utf-8)
(set-language-environment 'utf-8)
This works well when using auto-completion in the minibuffer from the home
(eg ~/ emacs and then C-x C-f and using autocompletion along the path)
However, when I launch e-macs from within the final directory
/users/Documents and Settings/giraudoux/Mes documents/Thèse
Robardet/Analyses 0611$ emacs
The minibuffer does not manage again with accent...
Thanks in advance for any hint
Patrick
--
View this message in context: http://www.nabble.com/emacs-cannot-read-accent-properly-in-a-path-tf2874092.html#a8032977
Sent from the Emacs - Help mailing list archive at Nabble.com.
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: emacs cannot read accent properly in a path
2006-12-23 10:41 emacs cannot read accent properly in a path PG
@ 2006-12-23 14:09 ` Peter Dyballa
2006-12-23 14:40 ` PG
0 siblings, 1 reply; 9+ messages in thread
From: Peter Dyballa @ 2006-12-23 14:09 UTC (permalink / raw)
Cc: Help-gnu-emacs
Am 23.12.2006 um 11:41 schrieb PG:
> Thanks in advance for any hint
You could set environment variables LC_CTYPE or LANG to fr_FR.UTF-8
or such.
You can set in .emacs:
(prefer-coding-system 'utf-8)
(set-default-coding-systems 'utf-8)
(setq file-name-coding-system 'utf-8)
--
Greetings
Pete
Real Time, adj.:
Here and now, as opposed to fake time, which only occurs there and then.
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: emacs cannot read accent properly in a path
2006-12-23 14:09 ` Peter Dyballa
@ 2006-12-23 14:40 ` PG
2006-12-23 15:46 ` Peter Dyballa
2006-12-23 15:48 ` Peter Dyballa
0 siblings, 2 replies; 9+ messages in thread
From: PG @ 2006-12-23 14:40 UTC (permalink / raw)
The Ubuntu bash is set to UTF-8 (and thus usually reads the accents in
directory and file names)
I have just tried to modify .emacs following instructions and also modifying
.bash_profile with LANG= fr_FR.UTF-8 but it does not helped...
Still does no read the accent in the path when emacs is launched from within
the directory
/users/Documents and Settings/giraudoux/Mes documents/Thèse
Robardet/Analyses 0611$
Greetings
Peter Dyballa wrote:
>
>
> Am 23.12.2006 um 11:41 schrieb PG:
>
>> Thanks in advance for any hint
>
> You could set environment variables LC_CTYPE or LANG to fr_FR.UTF-8
> or such.
>
> You can set in .emacs:
>
> (prefer-coding-system 'utf-8)
> (set-default-coding-systems 'utf-8)
> (setq file-name-coding-system 'utf-8)
>
> --
> Greetings
>
> Pete
>
> Real Time, adj.:
> Here and now, as opposed to fake time, which only occurs there and then.
>
>
>
>
> _______________________________________________
> help-gnu-emacs mailing list
> help-gnu-emacs@gnu.org
> http://lists.gnu.org/mailman/listinfo/help-gnu-emacs
>
>
--
View this message in context: http://www.nabble.com/emacs-cannot-read-accent-properly-in-a-path-tf2874092.html#a8034186
Sent from the Emacs - Help mailing list archive at Nabble.com.
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: emacs cannot read accent properly in a path
2006-12-23 14:40 ` PG
@ 2006-12-23 15:46 ` Peter Dyballa
2006-12-23 16:19 ` Patrick Giraudoux
2006-12-23 15:48 ` Peter Dyballa
1 sibling, 1 reply; 9+ messages in thread
From: Peter Dyballa @ 2006-12-23 15:46 UTC (permalink / raw)
Cc: Help-gnu-emacs
Am 23.12.2006 um 15:40 schrieb PG:
> .bash_profile with LANG= fr_FR.UTF-8 but it does not helped...
export LANG=fr_FR.UTF-8
would be correct syntax, if your system would know about
"fr_FR.UTF-8" as a locale. You should consult you system with locale
(man locale for some details)
And if this fails, then check whether you set-language-environment –
if you do, comment it!
Do the Elisp statements change the behaviour? Are the DOS or Windows
file name "exported" and "imported" in the right encoding? When the
file names are in DOS or Windows in some Code Page, then you can't
mount them in Linux as UTF-8 ... (although the excerpt ``A"´´ for è
makes one believe, but è is in UTF-8 C3 A8, i.e. è)
--
Greetings
Pete
Never be led astray onto the path of virtue
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: emacs cannot read accent properly in a path
2006-12-23 14:40 ` PG
2006-12-23 15:46 ` Peter Dyballa
@ 2006-12-23 15:48 ` Peter Dyballa
1 sibling, 0 replies; 9+ messages in thread
From: Peter Dyballa @ 2006-12-23 15:48 UTC (permalink / raw)
Cc: Help-gnu-emacs
Am 23.12.2006 um 15:40 schrieb PG:
> modifying .bash_profile
... would only work in a login shell! The file ~/.bashrc is better
suited: it's always used, sourced, included ...
--
Greetings
Pete
Windows, c'est un peu comme le beaujolais nouveau: à chaque nouvelle
cuvée on sait que ce sera dégueulasse, mais on en prend quand même,
par masochisme.
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: emacs cannot read accent properly in a path
2006-12-23 15:46 ` Peter Dyballa
@ 2006-12-23 16:19 ` Patrick Giraudoux
2006-12-23 17:17 ` Peter Dyballa
0 siblings, 1 reply; 9+ messages in thread
From: Patrick Giraudoux @ 2006-12-23 16:19 UTC (permalink / raw)
Cc: Help-gnu-emacs, PG
>
> would be correct syntax, if your system would know about "fr_FR.UTF-8"
> as a locale. You should consult you system with locale (man locale for
> some details)
tried it locale -a and fr_FR.UTF-8 is in the list.
Tried to set
export LANG=fr_FR.UTF-8
into ~/.bashrc
Did not work
>
> And if this fails, then check whether you set-language-environment –
> if you do, comment it!
I did it through the menu Options > Mule > Set Language Environment
setting up UTF-8 as well as > European > French.
No result.
>
> Do the Elisp statements change the behaviour? Are the DOS or Windows
> file name "exported" and "imported" in the right encoding? When the
> file names are in DOS or Windows in some Code Page, then you can't
> mount them in Linux as UTF-8 ... (although the excerpt ``A"´´ for è
> makes one believe, but è is in UTF-8 C3 A8, i.e. è)
Actually the bash reads DOS encoding well including the accents, and
even emacs autocompletion is correct in the mini-buffer if emacs is
started from ~/. The è unstead è just come when starting emacs within a
directory which includes letter accents in the path... Very strange.
Anyway, many thanks for your help,
Patrick
>
> --
> Greetings
>
> Pete
>
> Never be led astray onto the path of virtue
>
>
>
>
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: emacs cannot read accent properly in a path
2006-12-23 16:19 ` Patrick Giraudoux
@ 2006-12-23 17:17 ` Peter Dyballa
2006-12-23 19:11 ` Patrick Giraudoux
0 siblings, 1 reply; 9+ messages in thread
From: Peter Dyballa @ 2006-12-23 17:17 UTC (permalink / raw)
Cc: Help-gnu-emacs, PG
Am 23.12.2006 um 17:19 schrieb Patrick Giraudoux:
> I did it through the menu Options > Mule > Set Language Environment
> setting up UTF-8 as well as > European > French.
That's wrong! This puts you into a 7 bit world.
How is GNU Emacs' file name completion working? Can you make the ls
command in dired use switches to display UTF-8 characters (gls --
dired ...)?
--
Greetings
Pete
"America believes in education: the average professor earns more money
in a year than a professional athlete earns in a whole week." – Evan
Esar
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: emacs cannot read accent properly in a path
2006-12-23 17:17 ` Peter Dyballa
@ 2006-12-23 19:11 ` Patrick Giraudoux
2006-12-23 20:05 ` Peter Dyballa
0 siblings, 1 reply; 9+ messages in thread
From: Patrick Giraudoux @ 2006-12-23 19:11 UTC (permalink / raw)
Cc: Help-gnu-emacs, PG
> How is GNU Emacs' file name completion working? Can you make the ls
> command in dired use switches to display UTF-8 characters (gls --dired
> ...)?
Yes no problem, see below:
ls /users/Documents\ and\ Settings/giraudoux/Mes\ documents/Thèse\ Robardet/
Analyses 0509 Analyses 0608 projet thèse ER janv2005.doc
Analyses 0606 Analyses 0611
ls --dired /users/Documents\ and\ Settings/giraudoux/Mes\
documents/Thèse\ Robardet/
Analyses 0509 Analyses 0608 projet thèse ER janv2005.doc
Analyses 0606 Analyses 0611
Even when emacs is launched from ~/ emacs the completion after C-x C-f
is working well with accents. The only trouble comes when emacs is
launched from within a directory whose path has an accent in one of the
names, eg:
/users/Documents\ and\ Settings/giraudoux/Mes\ documents/Thèse\
Robardet/emacs
Then, within emacs, the path given after C-x C-f does not read accents
properly in the path provided in the mini-buffer..
Quite strange?
Patrick
>
> --
> Greetings
>
> Pete
>
> "America believes in education: the average professor earns more money
> in a year than a professional athlete earns in a whole week." – Evan
> Esar
>
>
>
>
>
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: emacs cannot read accent properly in a path
2006-12-23 19:11 ` Patrick Giraudoux
@ 2006-12-23 20:05 ` Peter Dyballa
0 siblings, 0 replies; 9+ messages in thread
From: Peter Dyballa @ 2006-12-23 20:05 UTC (permalink / raw)
Cc: Help-gnu-emacs, PG
Am 23.12.2006 um 20:11 schrieb Patrick Giraudoux:
> Even when emacs is launched from ~/ emacs the completion after C-x
> C-f is working well with accents. The only trouble comes when
> emacs is launched from within a directory whose path has an accent
> in one of the names, eg:
>
> /users/Documents\ and\ Settings/giraudoux/Mes\ documents/Thèse\
> Robardet/emacs
>
> Then, within emacs, the path given after C-x C-f does not read
> accents properly in the path provided in the mini-buffer..
>
> Quite strange?
Yes. You should report it. (In Help menu you'll find Report Emacs
Bug...)
Besides, there are problems with some characters that are neither in
mode-line nor in *Buffer Menu* nor in *Buffer List* correctly
displayed or presented. At least I can open the files or follow into
the sub-directory.
Here, on Mac OS X, I can't reproduce it. And I don't have a version
21 by hand. GNU Emacs 22.0.92 has a problem finding $PWD: the *shell*
buffer was rooted in / ...
--
Greetings
Pete
"I love deadlines. I love the whooshing noise they make as they go by."
(Douglas Adams)
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2006-12-23 20:05 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-12-23 10:41 emacs cannot read accent properly in a path PG
2006-12-23 14:09 ` Peter Dyballa
2006-12-23 14:40 ` PG
2006-12-23 15:46 ` Peter Dyballa
2006-12-23 16:19 ` Patrick Giraudoux
2006-12-23 17:17 ` Peter Dyballa
2006-12-23 19:11 ` Patrick Giraudoux
2006-12-23 20:05 ` Peter Dyballa
2006-12-23 15:48 ` Peter Dyballa
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).