From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Jesper Harder Newsgroups: gmane.emacs.help Subject: Re: Unicode box-drawing chars Date: Sat, 14 Sep 2002 22:49:11 +0200 Organization: http://purl.org/harder/ Sender: help-gnu-emacs-admin@gnu.org Message-ID: References: NNTP-Posting-Host: localhost.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: main.gmane.org 1032067895 21925 127.0.0.1 (15 Sep 2002 05:31:35 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Sun, 15 Sep 2002 05:31:35 +0000 (UTC) Return-path: Original-Received: from monty-python.gnu.org ([199.232.76.173]) by main.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 17qS0L-0005hU-00 for ; Sun, 15 Sep 2002 07:31:33 +0200 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.10) id 17qS0a-000269-00; Sun, 15 Sep 2002 01:31:48 -0400 Original-Path: shelby.stanford.edu!nntp.stanford.edu!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!newsfeed.icl.net!newsfeed.fjserv.net!newspeer.clara.net!news.clara.net!colt.net!news.tele.dk!not-for-mail Original-Newsgroups: gnu.emacs.help X-Face: ^RrvqCr7c,P$zTR:QED"@h9+BTm-"fjZJJ-3=OU7.)i/K]<.J88}s>'Z_$r; List-Post: List-Subscribe: , List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: Xref: main.gmane.org gmane.emacs.help:1472 X-Report-Spam: http://spam.gmane.org/gmane.emacs.help:1472 Oliver Scholz writes: > Yes. And even when there is a unicode font, it is quite possible that > it does not contain the box-drawing glyphs. > > Is it possible to check from lisp if a font actually contains a glyph? This isn't a very good solution (and it'll only work on X11): You can determine which font Emacs will use with `internal-char-font'. You could then call xlsfonts -lll -fn FONT and parse the output to get the font metrics. If the metrics for a particular code point contains all zeros, say 0x009f (159) 0 0 0 0 0 0x0000 . then the glyph doesn't exist in this font.