From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Kenichi Handa Newsgroups: gmane.emacs.bugs Subject: bug#613: 23.0.60; Unicode display problems Date: Wed, 20 Aug 2008 10:38:54 +0900 Message-ID: References: <87myjv2tc8.fsf@stupidchicken.com> <87zlnrx33y.fsf@physik.rwth-aachen.de> <87ej52vg8r.fsf@physik.rwth-aachen.de> <873al2sd2h.fsf@physik.rwth-aachen.de> <87od3qqvlg.fsf@physik.rwth-aachen.de> Reply-To: Kenichi Handa , 613@emacsbugs.donarmstrong.com NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 (generated by SEMI 1.14.3 - "Ushinoya") Content-Type: text/plain; charset=US-ASCII X-Trace: ger.gmane.org 1219196863 9556 80.91.229.12 (20 Aug 2008 01:47:43 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 20 Aug 2008 01:47:43 +0000 (UTC) Cc: sand@blarg.net, 613@emacsbugs.donarmstrong.com, emacs-devel@gnu.org To: Torsten Bronger Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Wed Aug 20 03:48:35 2008 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1KVcoL-0003d8-DE for geb-bug-gnu-emacs@m.gmane.org; Wed, 20 Aug 2008 03:48:33 +0200 Original-Received: from localhost ([127.0.0.1]:58595 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KVcnO-0002oA-4b for geb-bug-gnu-emacs@m.gmane.org; Tue, 19 Aug 2008 21:47:34 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1KVcnL-0002o5-Tg for bug-gnu-emacs@gnu.org; Tue, 19 Aug 2008 21:47:31 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1KVcnK-0002nt-Ec for bug-gnu-emacs@gnu.org; Tue, 19 Aug 2008 21:47:30 -0400 Original-Received: from [199.232.76.173] (port=46049 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KVcnK-0002nq-7c for bug-gnu-emacs@gnu.org; Tue, 19 Aug 2008 21:47:30 -0400 Original-Received: from rzlab.ucr.edu ([138.23.92.77]:57756) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1KVcnJ-0002QJ-EZ for bug-gnu-emacs@gnu.org; Tue, 19 Aug 2008 21:47:29 -0400 Original-Received: from rzlab.ucr.edu (rzlab.ucr.edu [127.0.0.1]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id m7K1lQiV001139; Tue, 19 Aug 2008 18:47:27 -0700 Original-Received: (from debbugs@localhost) by rzlab.ucr.edu (8.13.8/8.13.8/Submit) id m7K1j30j032346; Tue, 19 Aug 2008 18:45:03 -0700 X-Loop: don@donarmstrong.com Resent-From: Kenichi Handa Resent-To: bug-submit-list@donarmstrong.com Resent-CC: Emacs Bugs Resent-Date: Wed, 20 Aug 2008 01:45:03 +0000 Resent-Message-ID: Resent-Sender: don@donarmstrong.com X-Emacs-PR-Message: report 613 X-Emacs-PR-Package: emacs X-Emacs-PR-Keywords: Original-Received: via spool by 613-submit@emacsbugs.donarmstrong.com id=B613.121919638330753 (code B ref 613); Wed, 20 Aug 2008 01:45:03 +0000 Original-Received: (at 613) by emacsbugs.donarmstrong.com; 20 Aug 2008 01:39:43 +0000 Original-Received: from mx1.aist.go.jp (mx1.aist.go.jp [150.29.246.133]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id m7K1dci5030747 for <613@emacsbugs.donarmstrong.com>; Tue, 19 Aug 2008 18:39:40 -0700 Original-Received: from rqsmtp2.aist.go.jp (rqsmtp2.aist.go.jp [150.29.254.123]) by mx1.aist.go.jp with ESMTP id m7K1d9Zw014603; Wed, 20 Aug 2008 10:39:09 +0900 (JST) env-from (handa@m17n.org) Original-Received: from smtp4.aist.go.jp by rqsmtp2.aist.go.jp with ESMTP id m7K1d8Wl013962; Wed, 20 Aug 2008 10:39:09 +0900 (JST) env-from (handa@m17n.org) Original-Received: by smtp4.aist.go.jp with ESMTP id m7K1cslU013815; Wed, 20 Aug 2008 10:38:54 +0900 (JST) env-from (handa@m17n.org) Original-Received: from handa by etlken.m17n.org with local (Exim 4.69) (envelope-from ) id 1KVcf0-0004FY-Gl; Wed, 20 Aug 2008 10:38:54 +0900 In-reply-to: <87od3qqvlg.fsf@physik.rwth-aachen.de> (message from Torsten Bronger on Mon, 18 Aug 2008 15:52:11 +0200) User-Agent: SEMI/1.14.3 (Ushinoya) FLIM/1.14.2 (Yagi-Nishiguchi) APEL/10.2 Emacs/23.0.60 (i686-pc-linux-gnu) MULE/6.0 (HANACHIRUSATO) X-detected-kernel: by monty-python.gnu.org: Linux 2.6 (newer, 3) Resent-Date: Tue, 19 Aug 2008 21:47:30 -0400 X-BeenThere: bug-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:19552 Archived-At: In article <87od3qqvlg.fsf@physik.rwth-aachen.de>, Torsten Bronger writes: > finding a font for: (8220) > ftfont-list: -unknown-DejaVu Sans Mono-*-iso10646-1:script=symbol > list: -unknown-DejaVu Sans Mono-*-iso10646-1:script=symbol [...] Now I see what is wrong. Dejavu Sans Mono lacks some of charaters (#x201C #x2200 #x2500) to be used as `symbol' font, so the other arbitrary font that contains all of those characters are selected. This setting was added by the request in the attached mail, but it seems that the restriction is too strong for symbol fonts. So, I deleted that restriction. Please try again with the latest CVS code. --- Kenichi Handa handa@ni.aist.go.jp In article <18477.2875.876651.446827@priss.frightenedpiglet.com>, sand@blarg.net writes: > Below is the complete set of fontset changes that my system needed to > display the HELLO file and Markus Kuhn's "UTF-8-demo.txt" file. There > are various problems with the fontset definitions that we can fix in > Emacs Lisp. > 1. The "symbol" and "phonetic" scripts don't have any representative > characters defined, and they don't have any fontset defined. > 2. The Latin script doesn't have representative characters over > 7-bits. This means the Xft backend doesn't have any constraint that > would reject ISO8859-1 fonts. Emacs appears to have special support > for real ISO8859-1 characters, so the new definition should not > break anything. > 3. The Armenian script has representative characters, but no fontset > defined. > 4. The Thai fontset definition assumes that you have OpenType set > up. It needs a fallback in case you don't. > 5. The Hangul fontset definition assumes that you have a language > definition in your Hangul font. It needs a fallback in case you > don't. > Note that for some people, the "symbol", "phonetic" and Latin scripts > may display just fine. The problem is that Emacs is not rejecting > ISO8859-1 fonts---but if your installation happens to pick a > ISO10646-1 font with coverage first then you won't see any weirdness. > For example, my work machine had trouble displaying the scripts while > my home machine did not. > It may be that the Thai and Hangul definitions are the tip of the > iceberg. I suspect that *every* ISO10646-1 fontset definition that > uses :otf or :language needs a fallback definition that uses :script. > If your HELLO file shows weird fonts being picked (such as a > double-width Chinese font for U+2018 LEFT SINGLE QUOTATION MARK) or > "missing font" boxes, can you please try putting the below code into > your .emacs file to see if it fixes the problem? These were sufficent > to get my work machine displaying every HELLO and "UTF-8-demo.txt" > glyphs for every font that I had installed. > This code can be applied to CVS HEAD before or after the font-backend > merge. > Derek > -- > Derek Upham > sand@blarg.net > ------------------------------ cut here ------------------------------ > ;; The eval-after-load here is a hack for testing. These should > ;; really be changes in "fontset.el". > ;; > ;; Some of the fontset definitions have 'prepend for testing. When > ;; added to "fontset.el" they should go into some appropriate > ;; location in the current lists. > (eval-after-load "fontset" > '(progn > ;; Representative characters for Latin need to include the > ;; various extension blocks. This should replace the existing > ;; definition. > (setq script-representative-chars > (cons '(latin ?A ?Z ?a ?z #x00C0 #x0100 #x0180 #x1e00) > script-representative-chars)) > ;; Representative characters for symbols were not defined. > (setq script-representative-chars > (cons '(symbol #x201C #x2200 #x2500) > script-representative-chars)) > ;; Representative characters for phonetics were not defined. > (setq script-representative-chars > (cons '(phonetic #x0250 #x0283) > script-representative-chars)) > ;; 'latin script needs a declaration that incorporates the Latin > ;; representative characters. None of the current ones do. > (set-fontset-font "fontset-default" 'latin > (font-spec :registry "iso10646-1" :script 'latin) nil 'prepend) > ;; No 'symbol script declaration exists. Create one using the new > ;; representative characters. > (set-fontset-font "fontset-default" 'symbol > (font-spec :registry "iso10646-1" :script 'symbol)) > ;; No 'phonetic declaration exists. Create one using the new > ;; representative characters. (Note that there is an 'ipa > ;; declaration, but 'ipa doesn't exist as a real script.) > (set-fontset-font "fontset-default" 'phonetic > (font-spec :registry "iso10646-1" :script 'phonetic)) > ;; No fontset was defined for Armenian. > (set-fontset-font "fontset-default" 'armenian > (font-spec :registry "iso10646-1" :script 'armenian)) > ;; The Thai fontset definition assumes that you have OpenType > ;; definitions set up properly. We need an explicit :script > ;; declaration as a backup. I think this should go after the :otf > ;; declaration, but I'm doing it as a 'prepend here. (Perhaps > ;; FreeSerif Thai fonts comply with OpenType, but Misc-Fixed > ;; ones don't.) > (set-fontset-font "fontset-default" 'thai > (font-spec :registry "iso10646-1" :script 'thai) nil 'prepend) > ;; 'hangul script has a :language restriction for iso10646-1, but also > ;; needs :script restriction as alternative. > (set-fontset-font "fontset-default" 'hangul > (font-spec :registry "iso10646-1" :script 'hangul) nil 'prepend) > ))