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 14:59:59 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 1104332649 14615 80.91.229.6 (29 Dec 2004 15:04:09 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Wed, 29 Dec 2004 15:04:09 +0000 (UTC) Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Wed Dec 29 16:04:03 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 1CjfMo-0005vQ-00 for ; Wed, 29 Dec 2004 16:04:02 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.33) id 1CjfXi-0003cF-F4 for geh-help-gnu-emacs@m.gmane.org; Wed, 29 Dec 2004 10:15:18 -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!newsread2.news.atl.earthlink.net.POSTED!d4e81fc7!not-for-mail Original-Newsgroups: gnu.emacs.help Mail-Copies-To: never Original-Lines: 105 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: newsread2.news.atl.earthlink.net 1104332399 66.149.110.191 (Wed, 29 Dec 2004 06:59:59 PST) Original-NNTP-Posting-Date: Wed, 29 Dec 2004 06:59:59 PST Original-Xref: shelby.stanford.edu gnu.emacs.help:127577 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:23040 X-Report-Spam: http://spam.gmane.org/gmane.emacs.help:23040 shamino@techie.com (David C.) writes: > > That being said, I visited the MacOS X Emacs list and used some of > their postings in conjunction with your advice to come up with this > addition to .emacs: > > (set-selection-coding-system 'mac-roman) > (set-keyboard-coding-system 'mac-roman) > (create-fontset-from-fontset-spec > "-apple-courier-medium-r-normal--14-*-*-*-*-*-fontset-david, > ascii:-apple-courier-medium-r-normal--14-140-75-75-m-140-mac-roman, > latin-iso8859-1:-apple-courier-medium-r-normal--14-140-75-75-m-140-mac-roman, > mule-unicode-0100-24ff:-apple-courier-medium-r-normal--14-140-75-75-m-140-mac-roman") > (set-frame-font "fontset-david") > (standard-display-8bit 128 255) > > This allows hi-page characters generated by programs (like Gnus) to > be displayed, and I can still see the characters of my test document > after a find-file. But I still see squares when I do a insert-file > into the scratch buffer or a newly-created document buffer. OK. I did a bit more work on it. I realized that your example posted fontsets for a tremedous number of fonts and sizes. Since I only work in one font (courier-14), it could be trimmed way down. This block seems to solve my problem: (set-variable 'default-buffer-file-coding-system 'mac-roman-unix) (set-default-coding-systems 'mac-roman-unix) (set-selection-coding-system 'mac-roman) (set-keyboard-coding-system 'mac-roman) (prefer-coding-system 'mac-roman-unix) (create-fontset-from-fontset-spec "-apple-courier-medium-r-normal--14-*-*-*-*-*-fontset-david, ascii:-apple-courier-medium-r-normal--14-*-*-*-*-*-mac-roman, latin-iso8859-1:-apple-courier-medium-r-normal--14-*-*-*-*-*-mac-roman, latin-iso8859-2:-apple-courier-medium-r-normal--14-*-*-*-*-*-mac-roman, latin-iso8859-3:-apple-courier-medium-r-normal--14-*-*-*-*-*-mac-roman, latin-iso8859-4:-apple-courier-medium-r-normal--14-*-*-*-*-*-mac-roman, latin-iso8859-5:-apple-courier-medium-r-normal--14-*-*-*-*-*-mac-roman, latin-iso8859-6:-apple-courier-medium-r-normal--14-*-*-*-*-*-mac-roman, latin-iso8859-7:-apple-courier-medium-r-normal--14-*-*-*-*-*-mac-roman, latin-iso8859-8:-apple-courier-medium-r-normal--14-*-*-*-*-*-mac-roman, latin-iso8859-9:-apple-courier-medium-r-normal--14-*-*-*-*-*-mac-roman, latin-iso8859-10:-apple-courier-medium-r-normal--14-*-*-*-*-*-mac-roman, latin-iso8859-13:-apple-courier-medium-r-normal--14-*-*-*-*-*-mac-roman, latin-iso8859-14:-apple-courier-medium-r-normal--14-*-*-*-*-*-mac-roman, latin-iso8859-15:-apple-courier-medium-r-normal--14-*-*-*-*-*-mac-roman, mac-roman-lower:-apple-courier-medium-r-normal--14-*-*-*-*-*-mac-roman, mac-roman-upper:-apple-courier-medium-r-normal--14-*-*-*-*-*-mac-roman, mule-unicode-0100-24ff:-apple-courier-medium-r-normal--14-*-*-*-*-*-mac-roman, mule-unicode-2500-33ff:-apple-courier-medium-r-normal--14-*-*-*-*-*-mac-roman, mule-unicode-e000-ffff:-apple-courier-medium-r-normal--14-*-*-*-*-*-mac-roman, iso10646-1::-apple-courier-medium-r-normal--14-*-*-*-*-*-mac-roman" t 'noerror) (setq default-frame-alist (append '((width . 80) (height . 104) (font . "fontset-david")) default-frame-alist)) The lack of default coding systems (default-buffer-file-coding-system, set-default-coding-systems, and prefer-coding-system) were what was ruining the file-insert operation. Once I did that, all but four characters rendered. Adding the font to the fontset for all the other characters solved that problem. I still think something like this could be, and should be automated. The fact that every single code-range uses the same font (and appears to for most of yours as well) tells me that Emacs should assume this pattern unless explicitly configured otherwise. Specifying a font instead of a fontset should tell Emacs to do what you and I already did - use that one font for all ranges. This would make the system backward-compaible and simple to set up for the majority of users. > I'll see what I can do here, but I really don't want to spend the > next month writing thousands of lines of lookup tables in order to do > this. Ignore that whine. I took one look at all you wrote and didn't realize you had simply provided code for 68 fonts, and that you only need the ones for those fonts you're actually going to be using. >> From which of the thousands of fonts can it take the glyphs? Try >> once: M-x set-frame-font TAB TAB -- and save this buffer for later >> contemplation! > > I would hope, that after setting a single font for the frame, it > would realize that I want everything to be displayed according to > that one font. > > This all was much simpler back in Emacs-19. Everything was simple > and obvious before they started forcing users to re-invent the > wheel. However, I stand by this gripe. But there's no need for me to dump my complaint on you. Thanks for all your help. -- David