From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Xah Lee Newsgroups: gmane.emacs.help Subject: Re: getting unicode chars to show on Windows Date: Fri, 28 Aug 2009 07:00:57 -0700 (PDT) Organization: http://groups.google.com Message-ID: References: <66341491-5c5b-406a-bb4c-7f02b7709983@t11g2000prh.googlegroups.com> <9b617e7b-9840-499d-b22b-881e4a540a70@h21g2000yqa.googlegroups.com> <6e107769-cd13-43f0-ac9f-8daa9fb83c5e@a39g2000pre.googlegroups.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1251495645 26416 80.91.229.12 (28 Aug 2009 21:40:45 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 28 Aug 2009 21:40:45 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Fri Aug 28 23:40:38 2009 Return-path: Envelope-to: geh-help-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 1Mh9BS-0002Zx-Bj for geh-help-gnu-emacs@m.gmane.org; Fri, 28 Aug 2009 23:40:34 +0200 Original-Received: from localhost ([127.0.0.1]:49504 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Mh9BR-0005mR-NU for geh-help-gnu-emacs@m.gmane.org; Fri, 28 Aug 2009 17:40:33 -0400 Original-Path: news.stanford.edu!headwall.stanford.edu!news.glorb.com!news2.glorb.com!transit3.readnews.com!news-out.readnews.com!transit4.readnews.com!postnews.google.com!o9g2000prg.googlegroups.com!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 72 Original-NNTP-Posting-Host: 76.102.12.87 Original-X-Trace: posting.google.com 1251468063 28433 127.0.0.1 (28 Aug 2009 14:01:03 GMT) Original-X-Complaints-To: groups-abuse@google.com Original-NNTP-Posting-Date: Fri, 28 Aug 2009 14:01:03 +0000 (UTC) Complaints-To: groups-abuse@google.com Injection-Info: o9g2000prg.googlegroups.com; posting-host=76.102.12.87; posting-account=bRPKjQoAAACxZsR8_VPXCX27T2YcsyMA User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/5.0 (Windows; U; Windows NT 6.0; en-US) AppleWebKit/530.5 (KHTML, like Gecko) Chrome/2.0.172.39 Safari/530.5, gzip(gfe), gzip(gfe) Original-Xref: news.stanford.edu gnu.emacs.help:172475 X-Mailman-Approved-At: Fri, 28 Aug 2009 16:50:50 -0400 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: news.gmane.org gmane.emacs.help:67623 Archived-At: Hi Florian, thank for your info. I'll need to study it more... getting any unicode char to display ... also wished to understand emacs fontset in some detail, so am a bit slow and taking it easy. There are several posts on this font issue recently... i think Peter? posted a fonset code that supposed to make all unicode display... (saved to be studied later) A complication with emacs/fonts is that different OS comes with different sets of fonts, and for particular platform emacs also deals font differently ... Though, right now there's this one thing i need. How do i set a font for the current frame? What i want is a toggle-font code so that i can press a key and have the font set to either a monospaced or variable-spaced one, and just for the current frame. More specifically: =E2=80=A2 what's the elisp function that makes the current frame use Courie= r New? (i'll also need to know the full string or whatever that emacs uses for what Windows calls the Courier New font.) Thanks. Xah On Aug 28, 3:40 am, Florian Beck wrote: > > Thanks. Spent a couple of hours reading about emacs fonts... am still > > pretty much nowhere.... agh emacs. > > Not sure what exactly your problem is, but here are a couple of pointers: > > To figure out what character ranges, fonts, etc I need, I use this site: > > http://www.alanwood.net/unicode/fontsbyrange.html > > Then you simply specify the font you want for specific characters (like > Jason wrote), e.g. > > (set-fontset-font t 'cherokee > (font-spec :family "MPH 2B Damase" :size 24)) > > Instead of the script name 'cherokee you can also use a range '(5024 . > 5119) or '(#x13A0 . #x13FF) or specify the first and last character '(?= =E1=8E=A0 > . ?=E1=8F=BF). > > After you have done this for the most important characters you can use > something like > > (set-fontset-font t nil (font-spec :family "Code2000") nil 'prepend) > > Called with 'prepend, set-fontset-font will only affect characters that > had no font previously, so you can use Code2000 as a fallback. > > If you want to use several fontsets or start from scratch, the easiest > way is to define a fontset > > (create-fontset-from-fontset-spec > "-*-DejaVu Sans Mono-medium-r-normal-*-14-*-*-*-*-*-fontset-mono") > > This fontset will be called fontset-mono, so you would use > > (set-fontset-font "fontset-mono" 'cherokee > (font-spec :family "MPH 2B Damase" :size 24)) > > to modify it. > > Hope that helps. > > -- > Florian Beck