From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: shamino@techie.com (David C.) Newsgroups: gmane.emacs.help Subject: Re: Macintosh character display (128-255) Date: Wed, 29 Dec 2004 11:37:19 GMT Organization: David's house of kumquats Message-ID: References: NNTP-Posting-Host: deer.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1104320368 18244 80.91.229.6 (29 Dec 2004 11:39:28 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Wed, 29 Dec 2004 11:39:28 +0000 (UTC) Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Wed Dec 29 12:39:19 2004 Return-path: Original-Received: from lists.gnu.org ([199.232.76.165]) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1CjcAh-0003vi-00 for ; Wed, 29 Dec 2004 12:39:19 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.33) id 1CjcLa-0005Lr-V8 for geh-help-gnu-emacs@m.gmane.org; Wed, 29 Dec 2004 06:50:35 -0500 Original-Path: shelby.stanford.edu!newsfeed.stanford.edu!headwall.stanford.edu!newshub.sdsu.edu!elnk-nf2-pas!newsfeed.earthlink.net!stamper.news.pas.earthlink.net!stamper.news.atl.earthlink.net!newsread3.news.atl.earthlink.net.POSTED!d4e81fc7!not-for-mail Original-Newsgroups: gnu.emacs.help Mail-Copies-To: never Original-Lines: 133 User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3.50 Original-NNTP-Posting-Host: 66.149.110.191 Original-X-Complaints-To: abuse@earthlink.net Original-X-Trace: newsread3.news.atl.earthlink.net 1104320239 66.149.110.191 (Wed, 29 Dec 2004 03:37:19 PST) Original-NNTP-Posting-Date: Wed, 29 Dec 2004 03:37:19 PST Original-Xref: shelby.stanford.edu gnu.emacs.help:127573 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 Xref: main.gmane.org gmane.emacs.help:23035 X-Report-Spam: http://spam.gmane.org/gmane.emacs.help:23035 Peter Dyballa writes: > Am 29.12.2004 um 10:56 schrieb David C.: > >> I'm running Emacs 21.3.50, compiled for Macintosh OS X 10.3. > > Are you running it in Terminal, or as carbonized Emacs natively in > Aqua, or as very good programme under X11? A carbonized Emacs natively in Aqua. emacs-version reports: GNU Emacs 21.3.50.1 (powerpc-apple-darwin7.2.0) of 2004-01-18 When I run in a terminal window, this problem doesn't happen. All the characters always display with the expected glyphs, based on what font the Terminal window is configured to use. >> I have set up my system to display the mac-roman version of the >> courier font for all frames, and to display all hi-page characters >> as-is, since the font contains glyphs for them all. The relevant >> lines from my .emacs file are: >> >> (set-default-font >> "-apple-courier-medium-r-normal--14-*-*-*-*-*-mac-roman") > > This is too short! Later more. > >> (setq default-frame-alist >> (append >> '((width . 80) >> (height . 104) >> (font . >> "-apple-courier-medium-r-normal--14-*-*-*-*-*-mac-roman")) >> default-frame-alist)) >> >> (standard-display-8bit 128 255) > > I think that's not needed. > >> Using this setup, I find that the hi-page characters still don't >> display properly. I get the hollow rectanlges (some extra-wide) >> representing those characters in all newly-created buffers. If I >> load a file with these characters, however, they display OK. >> >> As a test, I created a simple text file containing all 128 of the >> hi-page characters. >> >> If I load the buffer (C-x C-f ), all of the hi-page >> characters display correctly. > > Which coding-system is displayed in the modeline? The mode-line doesn't seem to show one: -:---Emacs upper-ascii.txt All L1 (Text Fill)----------- >> If instead, I create a new buffer (or simply switch to the scratch >> buffer) and insert the contents of that same file (C-x i ), >> the even-numbered hi-page characters all display as boxes and the >> odd-numbered hi-page characters all display as a capital "A" with an >> umlaut over it. > > Again: which coding-system? You have to teach Emacs to prefer some > coding-system. If it's running in Terminal, then Terminal should be > set to UTF-8, and under X11 and in Terminal you should make Emacs use > UTF-8 too. The mode-line here is different: -t:**-Emacs *scratch* All L1 (Lisp Interaction)--------- According to list-coding-systems, the "t" indicates raw-text >> I don't think this a frame-setting problem, because I see the problem >> when both buffers are displayed in the same frame. >> >> The "new buffer" behavior is also exhibited when reading messages >> with Gnus. >> >> If I comment off the font-changes from my .emacs file, I get the same >> behavior as before, but with latin-1 characters displayed for loaded >> files instead of mac-roman characters. >> >> If I comment off the "standard-display-8bit" call, I see a variation >> on the same behavior. New buffers show all of the hi-page characters >> as their octal equivalents, while loaded buffers show octal for the >> range of 128-159 > > In Unicode and ISO Latin these are control codes, only Mac Roman and > maybe Windows too uses this range as characters. So in a Unicode or > Latin buffer you can't anything else than octal values. Mac-Roman is 8-bit and has characters in these positions. When I call standard-display-8bit to force the display of these characters, and do a find-file, the characters in those positions are displayed with the characters in those positions. >> Could someone point me in the right direction. Or even better, >> suggest a change to my .emacs that will force newly-created buffers >> to display the mac-roman encoding for all of the hi-page characters? > > Here is a setup for a .emacs file: I'll try some of this, but it's going to need quite a bit of editing, since it is setting up all kinds of things that (I hope) are unrelated to this problem. (For instance, you LaTeX hooks). I pulled these lines from your .emacs: (set-variable 'file-name-coding-system 'utf-8) (set-variable 'default-buffer-file-coding-system 'mac-roman-unix) (set-default-coding-systems 'mac-roman-unix) (set-keyboard-coding-system 'mac-roman) (prefer-coding-system 'mac-roman-unix) When I do this, every buffer is created in the Mac-Roman encoding. And as a result of this, every buffer (whether new or loaded) shows my test file as nothing but empty squares. In other words, it made the problem worse. As for all the fontset work, I appreciate your assistance here, but I really don't think fontsets are the issue. As I wrote originally, my existing font configuration _DOES_ show the required characters when I do a find-file on the buffer. It only has problems for new buffers. And all buffers in all frames are using the same font. > The fontsets are bit more complicated (excerpts from other postings to > the Mac OS X Emacs list > List Post: > List Archives: ): This is a resource I didn't know about. Thanks. -- David