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

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

Re: umlaute not recognized


From: ken
Subject: Re: umlaute not recognized
Date: Mon, 20 Dec 2010 07:57:05 -0500
User-agent: Thunderbird 2.0.0.24 (X11/20101213)

On 12/20/2010 06:05 AM LanX wrote:
> Hi Peter
> 
> I have a similar problem, which doesn't disappear with
> 
> (prefer-coding-system 'utf-8)
> 
> and my env is set
> :~$ env|grep LANG
> LANG=de_DE.UTF-8
> GDM_LANG=de_DE.UTF-8
> 
> I have an org file where umlauts are occasionally set to something
> like ä or \ddd (d=digit).
> 
> Exporting to latex fails for obscure reasons.
> 
> describe-coding-system says
> ----------------
> Coding system for saving this buffer:
>   1 -- iso-latin-1-unix (alias: iso-8859-1-unix latin-1-unix)
> 
> Default coding system (for new files):
>   1 -- iso-latin-1-unix (alias: iso-8859-1-unix latin-1-unix)
> ----------------
> 
> And the codings system is the same for new files, despite all utf8
> settings.
> 
> Any ideas?
> 
> Cheers
>   Rolf
> 
> On 19 Dez., 20:51, Peter Dyballa <Peter_Dyba...@Web.DE> wrote:
>> Am 19.12.2010 um 19:52 schrieb Tim Häring:
>>
>>> If I write a text-file in e.g. gedit like the following:
>>> Hällöle
>>> and open it with emacs I get the following:
>>> hällöle
>> Make GNU Emacs open the file in UTF-8! GNU Emacs will do that
>> automatically when it finds in the environment LANG or LC_CTYPE set to
>> some *.UTF-8 value. Another option is to put into your init file:
>>
>>         (prefer-coding-system 'utf-8)

What works for me:

Insert this into the top of the file:

<!-- -*- coding: utf-8; -*- -->

Do "C-x C-v RETURN" to reload the file.

I then see a 'U' in the second column of the status line.  Sometimes
there are characters in the file which are not UTF-8 and so which don't
display properly; they appear as '\366' or suchlike... a backslash and a
three-digit number.  Attempting to save the file, I'm queried about
them.  But I do a search-and-replace on these and when they're all
removed, the file is properly saved in UTF-8.

hth,
ken

-- 
"The owners of this country know the truth: It's called the
American dream because you have to be asleep to believe it."
        --George Carlin




reply via email to

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