From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/30735 Path: news.gmane.org!not-for-mail From: =?ISO-8859-15?Q?Peter_M=FCnster?= Newsgroups: gmane.comp.tex.context Subject: Re: Define doifoneelse Date: Mon, 11 Sep 2006 11:57:52 +0200 (CEST) Message-ID: References: Reply-To: ntg-context@ntg.nl NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1157973810 22586 80.91.229.2 (11 Sep 2006 11:23:30 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Mon, 11 Sep 2006 11:23:30 +0000 (UTC) Original-X-From: ntg-context-bounces@ntg.nl Mon Sep 11 13:23:27 2006 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org 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 1GMjsa-0001JQ-Oq for gctc-ntg-context-518@m.gmane.org; Mon, 11 Sep 2006 13:23:09 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id E6E801FC74; Mon, 11 Sep 2006 13:23:07 +0200 (CEST) Original-Received: from ronja.ntg.nl ([127.0.0.1]) by localhost (smtp.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 11158-03; Mon, 11 Sep 2006 13:23:03 +0200 (CEST) Original-Received: from ronja.vet.uu.nl (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 0647F1FC78; Mon, 11 Sep 2006 13:23:03 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 293211FC78 for ; Mon, 11 Sep 2006 13:23:01 +0200 (CEST) Original-Received: from ronja.ntg.nl ([127.0.0.1]) by localhost (smtp.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 11159-02 for ; Mon, 11 Sep 2006 13:22:59 +0200 (CEST) Original-Received: from smtp.Neuf.fr (sp604005mt.neufgp.fr [84.96.92.11]) by ronja.ntg.nl (Postfix) with SMTP id 77D921FC74 for ; Mon, 11 Sep 2006 13:22:59 +0200 (CEST) Original-Received: from gaston.pm ([84.7.233.81]) by sp604005mt.gpm.neuf.ld (Sun Java System Messaging Server 6.2-5.05 (built Feb 16 2006)) with ESMTP id <0J5F00FVMEA6L6H0@sp604005mt.gpm.neuf.ld> for ntg-context@ntg.nl; Mon, 11 Sep 2006 13:22:56 +0200 (CEST) Original-Received: by gaston.pm (Postfix, from userid 500) id 71A2013C080; Mon, 11 Sep 2006 11:57:52 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by gaston.pm (Postfix) with ESMTP id 6CBFC148016 for ; Mon, 11 Sep 2006 11:57:52 +0200 (CEST) In-reply-to: X-X-Sender: peter@gaston.pm Original-To: mailing list for ConTeXt users X-Virus-Scanned: amavisd-new at ntg.nl X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.7 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: amavisd-new at ntg.nl Xref: news.gmane.org gmane.comp.tex.context:30735 Archived-At: On Mon, 11 Sep 2006, Aditya Mahajan wrote: > \doifoneelse{1}{a}{b} gives a > \doifoneelse{1.5}{a}{b} gives b > \doifonelese{string}{a}{b} gives b > > Can someone suggest how to define this? \def\doifoneelse#1#2#3{\doifelse{1}{#1}{#2}{#3}} \starttext \doifoneelse{1}{a}{b} gives a \doifoneelse{1.5}{a}{b} gives b \doifoneelse{string}{a}{b} gives b \stoptext Cheers, Peter -- http://pmrb.free.fr/contact/