From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/45256 Path: news.gmane.org!not-for-mail From: "Alan STONE" Newsgroups: gmane.comp.tex.context Subject: Re: ctx files Date: Mon, 3 Nov 2008 14:39:13 +0100 Message-ID: <326847810811030539n36194803q1e31d3d9485e8d2d@mail.gmail.com> References: <326847810810290313qae61571j13de9eda053227a8@mail.gmail.com> <49083BB2.10902@wxs.nl> <326847810810311026p1919817etc688174415dd25a6@mail.gmail.com> Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============0241000803==" X-Trace: ger.gmane.org 1225721281 8988 80.91.229.12 (3 Nov 2008 14:08:01 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 3 Nov 2008 14:08:01 +0000 (UTC) To: "mailing list for ConTeXt users" Original-X-From: ntg-context-bounces@ntg.nl Mon Nov 03 15:08:52 2008 connect(): Connection refused 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 lo.gmane.org with esmtp (Exim 4.50) id 1Kx06V-0004Ol-Rb for gctc-ntg-context-518@m.gmane.org; Mon, 03 Nov 2008 15:08:27 +0100 Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id A5A2C1FADC; Mon, 3 Nov 2008 15:06:57 +0100 (CET) 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 18240-02-6; Mon, 3 Nov 2008 15:05:52 +0100 (CET) Original-Received: from ronja.vet.uu.nl (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 90CA71FBEF; Mon, 3 Nov 2008 14:39:49 +0100 (CET) Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id B422C1FBEB for ; Mon, 3 Nov 2008 14:39:47 +0100 (CET) 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 15522-01-3 for ; Mon, 3 Nov 2008 14:39:13 +0100 (CET) Original-Received: from nf-out-0910.google.com (nf-out-0910.google.com [64.233.182.185]) by ronja.ntg.nl (Postfix) with ESMTP id DE5C71FBA8 for ; Mon, 3 Nov 2008 14:39:13 +0100 (CET) Original-Received: by nf-out-0910.google.com with SMTP id c10so994177nfd.44 for ; Mon, 03 Nov 2008 05:39:13 -0800 (PST) Original-Received: by 10.210.16.17 with SMTP id 17mr139847ebp.22.1225719553709; Mon, 03 Nov 2008 05:39:13 -0800 (PST) Original-Received: by 10.210.136.3 with HTTP; Mon, 3 Nov 2008 05:39:13 -0800 (PST) In-Reply-To: <326847810810311026p1919817etc688174415dd25a6@mail.gmail.com> X-Virus-Scanned: amavisd-new at ntg.nl X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.9 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:45256 Archived-At: --===============0241000803== Content-Type: multipart/alternative; boundary="----=_Part_55246_23414500.1225719553701" ------=_Part_55246_23414500.1225719553701 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline On Fri, Oct 31, 2008 at 6:26 PM, Alan STONE wrote: > After giving it some further thought, I tried the following (which seems > more logical) but that doesn't work either... > > *** ctx-test.tex *** > > \starttext > > \doifmode{mode1a} > {mode1a} > > \doifmode{mode2a} > {\blank mode2a} > > \stoptext > > *** ctx-main.ctx *** > > > > > > > > > > > > > > > *** ctx-flags.ctx *** > > > > texengine=luatex > interface=en > result=ctx-modes > > *** ctx-modes1.ctx *** > > > > mode1a > > *** ctx-modes2.ctx *** > > > > mode2a > > *** end of code *** > > A Google search for the XML include element didn't bring much wisdom > either. What's missing/wrong please ? > Hi Hans, You wrote "<software.list.1es9s@gmail.com> wrote:
After giving it some further thought, I tried the following (which seems more logical) but that doesn't work either...


*** ctx-test.tex ***

\starttext

\doifmode{mode1a}
    {mode1a}
   
\doifmode{mode2a}
    {\blank mode2a}

\stoptext

*** ctx-main.ctx ***

<?xml version='1.0' standalone='yes'?>

<ctx:job>
     <ctx:preprocess/>
    <ctx:flags>
            <ctx:include name='ctx-flags.ctx'/>
    </ctx:flags>
    <ctx:process>
        <ctx:resources>
            <ctx:include name='ctx-modes1.ctx'/>
        </ctx:resources>
    </ctx:process>
     <ctx:postprocess/>
</ctx:job>

*** ctx-flags.ctx ***

<?xml version='1.0' standalone='yes'?>

<ctx:flag>texengine=luatex</ctx:flag>
<ctx:flag>interface=en</ctx:flag>
<ctx:flag>result=ctx-modes</ctx:flag>

*** ctx-modes1.ctx ***

<?xml version='1.0' standalone='yes'?>

<ctx:mode>mode1a</ctx:mode>

*** ctx-modes2.ctx ***

<?xml version='1.0' standalone='yes'?>

<ctx:mode>mode2a</ctx:mode>

*** end of code ***

A Google search for the XML include element didn't bring much wisdom either. What's missing/wrong please ?

Hi Hans,

You wrote "<ctx:include name='whatever.ctx"/> should work"

Given the above example, I'd really like to learn how to make it work.  :O)

texmfstart texexec --ctx=ctx-main ctx-test

--
Best,
Alan

P.S. Happy Birthdaybeforeyesterday.

* ConTeXt  minimals ver: 2008.10.31 13:58 MKIV  fmt: 2008.10.31  int: english/english
* Ubuntu 8.04 Hardy Heron
------=_Part_55246_23414500.1225719553701-- --===============0241000803== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline ___________________________________________________________________________________ If your question is of interest to others as well, please add an entry to the Wiki! maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context webpage : http://www.pragma-ade.nl / http://tex.aanhet.net archive : https://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________ --===============0241000803==--