From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/86017 Path: news.gmane.org!not-for-mail From: Kate F Newsgroups: gmane.comp.tex.context Subject: MkIV XML and |c|c|c| Date: Sun, 19 Jan 2014 11:53:11 +0100 Message-ID: Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1390206276 1386 80.91.229.3 (20 Jan 2014 08:24:36 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 20 Jan 2014 08:24:36 +0000 (UTC) To: ntg-context@ntg.nl Original-X-From: ntg-context-bounces@ntg.nl Mon Jan 20 09:24:44 2014 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from balder.ntg.nl ([5.39.185.229]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1W5AA0-0000fL-0j for gctc-ntg-context-518@m.gmane.org; Mon, 20 Jan 2014 09:24:44 +0100 Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 397BD101F5; Mon, 20 Jan 2014 09:24:29 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (balder.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id rZ4hy-fieO9n; Mon, 20 Jan 2014 09:24:29 +0100 (CET) Original-Received: from balder.ntg.nl (localhost [IPv6:::1]) by balder.ntg.nl (Postfix) with ESMTP id 58519101EE; Mon, 20 Jan 2014 09:24:18 +0100 (CET) Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 8F0F2101E2 for ; Sun, 19 Jan 2014 11:53:16 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (balder.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id mU6k7X0XctTO for ; Sun, 19 Jan 2014 11:53:15 +0100 (CET) Original-Received: from filter3-ams.mf.surf.net (filter3-ams.mf.surf.net [192.87.102.71]) by balder.ntg.nl (Postfix) with ESMTP id 8DDB9101E1 for ; Sun, 19 Jan 2014 11:53:15 +0100 (CET) Original-Received: from mail-ob0-f176.google.com (mail-ob0-f176.google.com [209.85.214.176]) by filter3-ams.mf.surf.net (8.14.3/8.14.3/Debian-9.4) with ESMTP id s0JArCTJ029999 (version=TLSv1/SSLv3 cipher=RC4-SHA bits=128 verify=NOT) for ; Sun, 19 Jan 2014 11:53:14 +0100 Original-Received: by mail-ob0-f176.google.com with SMTP id gq1so4120595obb.35 for ; Sun, 19 Jan 2014 02:53:12 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:date:message-id:subject:from:to :content-type; bh=/xyS5GWRNMdpJmZesSkkGSgg/S1scgeM6H9sfFu97gU=; b=bIjsRDYgaKqPlWtC258BoewAIcVIwNwqK5jsN72jZCxuB4atoPwuhmEyJjzSf1vJEK Z3APsTgp09fy/19b9HTgQf8qc50abJi7HgUss2XopJNUTz8cf3M5VL5//du+z1EW6x/6 otaeOgkGFvCeMLjHoeTXfavm77pWXSXf7+HPY02uikmXohi5Lt2/oQQs4iaVuaC2ayXp LUQyLh1s18PbJFgKzgxRdnKuoPKLU7Z0n6UXXCWgZ9DKGUmZgR8VNJiyjfe9nDjCdMLq bnGbjmk+PUdftwLDfcdXhc8bG2VzzxlqlAlxM31D7ZutsAkj6JKVrXh2WoeKJdxH97DQ VKow== X-Gm-Message-State: ALoCoQk5cnof4CSDexF74uTufO2zOQDhjgA4xRF0wgW4wzgdDzmc2pxj6GkFD3XQ5g7rab3uZUL/ X-Received: by 10.60.118.168 with SMTP id kn8mr1119485oeb.43.1390128791947; Sun, 19 Jan 2014 02:53:11 -0800 (PST) Original-Received: by 10.76.91.169 with HTTP; Sun, 19 Jan 2014 02:53:11 -0800 (PST) X-Originating-IP: [37.191.144.53] X-Bayes-Prob: 0.0001 (Score 0, tokens from: @@RPTN) X-CanIt-Geo: ip=209.85.214.176; country=US; region=CA; city=Mountain View; postalcode=94043; latitude=37.4192; longitude=-122.0574; metrocode=807; areacode=650; http://maps.google.com/maps?q=37.4192,-122.0574&z=6 X-CanItPRO-Stream: uu:ntg-context@ntg.nl (inherits from uu:default, base:default) X-Canit-Stats-ID: 03LfKRdBp - 97cdd1e57c2b - 20140119 X-Scanned-By: CanIt (www . roaringpenguin . com) on 192.87.102.71 X-Mailman-Approved-At: Mon, 20 Jan 2014 09:24:14 +0100 X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.14 Precedence: list List-Id: mailing list for ConTeXt users List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: ntg-context-bounces@ntg.nl Original-Sender: ntg-context-bounces@ntg.nl Xref: news.gmane.org gmane.comp.tex.context:86017 Archived-At: Hi, I'm trying to glue MkIV XML handling to ConTeXt's tabulation. My markup has a HTML-style table model, with an arbitary number of elements. My problem is to produce the |c|c|c|c| format based on the number of elements I have, rather than hardcoding a specific number of columns. I thought I could do something like this, but unfortunately the string produced by \xmlconcat{#1}{col}{\|} seems to be ignored: % in practice this would produce various alignments, not just "c" \startxmlsetups xml:col c \stopxmlsetups \startxmlsetups xml:table \starttabulate[\|\xmlconcat{#1}{col}{\|}\|] \xmlall{#1}{thead|tbody} \stoptabulate \stopxmlsetups Whereas this works fine, as I'd expect: \starttabulate[|c|c|c|c|] (I'm also confused about the escaping for \| there. I guess the [] is a special environment, with | being given a different catcode, perhaps?) Is there a way to do this, with the number of columns and their alignment generated from the input XML? Thanks, -- Kate ___________________________________________________________________________________ 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 : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________