From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/19631 Path: news.gmane.org!not-for-mail From: =?ISO-8859-15?Q?Peter_M=FCnster?= Newsgroups: gmane.comp.tex.context Subject: Re: new command question Date: Tue, 5 Apr 2005 19:38:32 +0200 (CEST) Message-ID: References: <42530DBA@webmail.colostate.edu> Reply-To: ntg-context@ntg.nl NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Trace: sea.gmane.org 1112722867 28409 80.91.229.2 (5 Apr 2005 17:41:07 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Tue, 5 Apr 2005 17:41:07 +0000 (UTC) Original-X-From: ntg-context-bounces@ntg.nl Tue Apr 05 19:41:05 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 1DIs2u-0004f0-Sg for gctc-ntg-context-518@m.gmane.org; Tue, 05 Apr 2005 19:41:00 +0200 Original-Received: from localhost (localhost.localdomain [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 0B6811279A; Tue, 5 Apr 2005 19:43: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 10823-01; Tue, 5 Apr 2005 19:43:00 +0200 (CEST) Original-Received: from ronja.vet.uu.nl (localhost.localdomain [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 11273127BD; Tue, 5 Apr 2005 19:39:30 +0200 (CEST) Original-Received: from localhost (localhost.localdomain [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id E94EA127BD for ; Tue, 5 Apr 2005 19:39:28 +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 10700-01 for ; Tue, 5 Apr 2005 19:39:28 +0200 (CEST) Original-Received: from postfix4-2.free.fr (postfix4-2.free.fr [213.228.0.176]) by ronja.ntg.nl (Postfix) with ESMTP id 2FFE41279A for ; Tue, 5 Apr 2005 19:39:28 +0200 (CEST) Original-Received: from gaston.free.fr (rennes-1-62-147-97-247.dial.proxad.net [62.147.97.247]) by postfix4-2.free.fr (Postfix) with ESMTP id 913263193AA for ; Tue, 5 Apr 2005 19:39:26 +0200 (CEST) Original-Received: by gaston.free.fr (Postfix, from userid 500) id 9C6EF13C049; Tue, 5 Apr 2005 19:38:32 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by gaston.free.fr (Postfix) with ESMTP id 95A52148082 for ; Tue, 5 Apr 2005 19:38:32 +0200 (CEST) X-X-Sender: peter@gaston.free.fr Original-To: mailing list for ConTeXt users In-Reply-To: <42530DBA@webmail.colostate.edu> 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:19631 X-Report-Spam: http://spam.gmane.org/gmane.comp.tex.context:19631 On Mon, 4 Apr 2005, Idris Samawi Hamid wrote: > Instead of, say, > > \usetypescriptfile[type-ugm] > \usetypescript[URWGaramond] > \setupbodyfont[urwgaramond,10pt] > > I would like to define a single command as follows, using the ConTeXt option > method instead of \def{}{}{}: > > \globalbodyfont[type-ugm][URWGaramond][urwgaramond,10pt] > > I would like to learn how to do this. Thnx in advance for your help. Hello Idris, there are some good pages on the wiki about this subject. I don't know, if the option method is the best way to realize your \globalbodyfont command. I would do it as simple as this: \def\globalbodyfont[#1][#2][#3]{% \usetypescriptfile[#1] \usetypescript[#2] \setupbodyfont[#3]} I my opinion, the \globalbodyfont command is not that much better for the end-user, than the other 3 commands. I would rather make an environment-file: \startenvironment e-garamond \usetypescriptfile[type-ugm] \usetypescript[URWGaramond] \setupbodyfont[urwgaramond] \stopenvironment And then just "\environment e-garamond" in the document-file. Cheers, Peter -- http://pmrb.free.fr/contact/