From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/19667 Path: news.gmane.org!not-for-mail From: Hans Hagen Newsgroups: gmane.comp.tex.context Subject: Re: Textfont in math-formulas? Date: Thu, 07 Apr 2005 10:55:19 +0200 Message-ID: <4254F577.5050902@wxs.nl> References: <20050328194852.CB04012866@ronja.ntg.nl> <200504062121.15662.kai.straube@gmx.de> Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1112864259 24448 80.91.229.2 (7 Apr 2005 08:57:39 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Thu, 7 Apr 2005 08:57:39 +0000 (UTC) Original-X-From: ntg-context-bounces@ntg.nl Thu Apr 07 10:57:31 2005 Return-path: Original-Received: from ronja.vet.uu.nl ([131.211.172.88] helo=ronja.ntg.nl) by ciao.gmane.org with esmtp (Exim 4.43) id 1DJSok-0000eA-5O for gctc-ntg-context-518@m.gmane.org; Thu, 07 Apr 2005 10:56:50 +0200 Original-Received: from localhost (localhost.localdomain [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 66E1E1284E; Thu, 7 Apr 2005 10:59:01 +0200 (CEST) Original-Received: from ronja.ntg.nl ([127.0.0.1]) by localhost (ronja.vet.uu.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 29979-03; Thu, 7 Apr 2005 10:59:01 +0200 (CEST) Original-Received: from ronja.vet.uu.nl (localhost.localdomain [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id E907F12847; Thu, 7 Apr 2005 10:55:18 +0200 (CEST) Original-Received: from localhost (localhost.localdomain [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 1F4E112847 for ; Thu, 7 Apr 2005 10:55:17 +0200 (CEST) Original-Received: from ronja.ntg.nl ([127.0.0.1]) by localhost (ronja.vet.uu.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 29979-01 for ; Thu, 7 Apr 2005 10:55:14 +0200 (CEST) Original-Received: from mailrelay02.solcon.nl (maillb.solcon.nl [212.45.32.200]) by ronja.ntg.nl (Postfix) with ESMTP id 62BD9127A7 for ; Thu, 7 Apr 2005 10:55:14 +0200 (CEST) Original-Received: from server-1.pragma-net.nl (dsl-212-84-128-085.solcon.nl [212.84.128.85]) by mailrelay02.solcon.nl (8.12.11/SQL-8.12.11-5/8.12.11) with ESMTP id j378tCrv005286 for ; Thu, 7 Apr 2005 10:55:12 +0200 Original-Received: by server-1.pragma-net.nl (Postfix, from userid 65534) id E3CC11A200; Thu, 7 Apr 2005 10:35:26 +0200 (CEST) Original-Received: from [10.100.1.54] (unknown [10.100.1.54]) by server-1.pragma-net.nl (Postfix) with ESMTP id E20141803F for ; Thu, 7 Apr 2005 08:35:25 +0000 (UTC) User-Agent: Mozilla Thunderbird 1.0.2 (Windows/20050317) X-Accept-Language: en-us, en Original-To: mailing list for ConTeXt users In-Reply-To: <200504062121.15662.kai.straube@gmx.de> X-Virus-Scanned: ClamAV 0.80/705/Fri Feb 11 17:51:32 2005 clamav-milter version 0.80j on mailrelay02 X-Virus-Status: Clean X-Virus-Scanned: by amavisd-new at ntg.nl X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.5 Precedence: list List-Id: mailing list for ConTeXt users List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: ntg-context-bounces@ntg.nl Errors-To: ntg-context-bounces@ntg.nl X-Virus-Scanned: by amavisd-new at ntg.nl Xref: news.gmane.org gmane.comp.tex.context:19667 X-Report-Spam: http://spam.gmane.org/gmane.comp.tex.context:19667 Kai Straube wrote: > I have a little problem with fonts in my document. I use the cm sans serif > font in my text and want to have this in the tex-formulas to, but it worked > not for me. > Simple example: > > \enableregime[utf] > \setupoutput[pdf] > \mainlanguage[de] > \language[de] you can omit \language since you've already set the main language (after that language is used for local language switching) > \setuppapersize[A4] > \setupbodyfont[ss] > > \starttext > Some text, we can read it without serifs. But the formula: $ \frac{1}{x-2} $ > is not in the same font. > \stoptext for that you need a ss math font; in the simple case it could be made to work but since in math characters can come from any of the (about) 4 math fonts you would get inconsistent output. So, if you want to gamble, you may try this: % define a typeface \definetypeface [modern] [rm] [serif] [modern-base] [default] \definetypeface [modern] [ss] [sans] [modern-base] [default] \definetypeface [modern] [tt] [mono] [modern-base] [default] \definetypeface [modern] [mm] [math] [modern-base] [default] % overloaad a mapping % \startfontclass[modern] % \definefontsynonym [ComputerModernMath-Roman] [ComputerModernSans] % \definefontsynonym [ComputerModernMath-Italic] [ComputerModernSans-Italic] % \stopfontclass \startfontclass[modern] \definefontsynonym [MathRoman] [Sans] \definefontsynonym [MathItalic] [SansItalic] \stopfontclass % initialize the typeface \setupbodyfont[modern,ss] \starttext Some text, we can read it without serifs. But the formula: $ \frac{1}{x-2} $ is not in the same font. \stoptext you can put this in one of the dark corners of the wiki -) Hans ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com | www.pragma-pod.nl -----------------------------------------------------------------