From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: David Kastrup Newsgroups: gmane.emacs.help Subject: Re: Trying to input Unicode via GNU Emacs 21.3.1 Date: Fri, 11 Feb 2005 22:31:21 +0100 Organization: Organization?!? Message-ID: References: NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit X-Trace: sea.gmane.org 1108157394 24473 80.91.229.2 (11 Feb 2005 21:29:54 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Fri, 11 Feb 2005 21:29:54 +0000 (UTC) Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Fri Feb 11 22:29:54 2005 Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1CziMI-0002Wc-9V for geh-help-gnu-emacs@m.gmane.org; Fri, 11 Feb 2005 22:29:50 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1CzibH-0001t3-Ce for geh-help-gnu-emacs@m.gmane.org; Fri, 11 Feb 2005 16:45:19 -0500 Original-Path: shelby.stanford.edu!newsfeed.stanford.edu!newsmi-us.news.garr.it!newsmi-eu.news.garr.it!NewsITBone-GARR!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 45 Original-X-Trace: individual.net GDmgGQSKc6unxe0tRRonFQ37oIG2qDENT6JPsWVIucWSKOPMYP X-Face: 2FEFf>]>q>2iw=B6, xrUubRI>pR&Ml9=ao@P@i)L:\urd*t9M~y1^:+Y]'C0~{mAl`oQuAl \!3KEIp?*w`|bL5qr,H)LFO6Q=qx~iH4DN; i"; /yuIsqbLLCh/!U#X[S~(5eZ41to5f%E@'ELIi$t^ Vc\LWP@J5p^rst0+('>Er0=^1{]M9!p?&:\z]|;&=NP3AhB!B_bi^]Pfkw User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (gnu/linux) Cancel-Lock: sha1:hUQFQMjRVySfr6ctk0d452g7baU= Original-Xref: shelby.stanford.edu gnu.emacs.help:128509 Original-To: help-gnu-emacs@gnu.org X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org X-MailScanner-To: geh-help-gnu-emacs@m.gmane.org Xref: main.gmane.org gmane.emacs.help:24041 X-Report-Spam: http://spam.gmane.org/gmane.emacs.help:24041 List account writes: > I am trying to use GNU Emacs 21.3.1 on FreeBSD (5.3) to edit web pages > (I'm accessing my FreeBSD machine via Terminal.App on a Mac, with > TERM=xterm-color). I need to input Unicode characters and have them > appear properly in web browsers. Currently, I have gotten Emacs to > use "Unicode" mode (i.e. the two or three little "u"'s appear at the > bottom left), and I am able to enter characters that look just fine in > Emacs, but they display as gibberish in browsers. > > For instance, I need to be able to display the typical accented > Spanish, Italian and French characters. As an example, I can input > "Alarcón" in Emacs and it looks fine, but it displays in my browser > (Camino 0.82 on Mac OS X) as "Alarcón". The odd thing is that I > basically copied and modified this text from a page that actually > works just fine. > > I have the following lines in my .emacs: > (setq locale-coding-system 'utf-8) > (set-terminal-coding-system 'utf-8) > (set-keyboard-coding-system 'utf-8) > (set-selection-coding-system 'utf-8) > (prefer-coding-system 'utf-8) It would appear that the browser is of the opinion that the selection is in latin-1, your system default. You are explicitly telling Emacs to ignore the system default. Also with your other settings you tell Emacs that everything the locale appears to be is wrong. The easiest thing probably would be if you not only told your Emacs that all of your environment is utf-8, but if you just configured your environment to actually be so, in which case you would not have to tell all of those lies to Emacs. It may be that in a Latin-1 locale, Emacs-21.3 does not have a way to tell the browser "Everything in the selection is utf-8". I believe that the development version of Emacs _has_ had some changes, due to some X conventions that have been introduced or become common-place only after Emacs 21.3 has been release, so it might fair better with passing Unicode characters over a selection that it principally Latin-1, at least when the other program also knows about those conventions. -- David Kastrup, Kriemhildstr. 15, 44793 Bochum