- From: Tony R. <tony@gonk.net>
- Date: Thu, 10 Mar 2011 11:04:01 -0500
- To: XProc Dev <xproc-dev@w3.org>
- Message-Id: <509CADA1-B5CB-4081-87B1-585477FDF633@gonk.net>
Hello everyone! There seems to be a consensus that XProc could use some syntactic sugar. It could generally just be a little more human-friendly to read. I just whipped up a few examples of what I often wish was possible when I'm working with XProc. Feel free to throw comments, criticisms, rotten fruit and vegetables, and money… …or maybe even throw some of your own example code! :) ***** <!-- ALTERNATE SYNTAX FOR p:pipe (pipe() FUNCTION) ================================================================= --> <input port="source" href="pipe('step-name','port-name')" /> <!-- defaults to primary output --> <input port="source" href="pipe('step-name')" /> <!-- ALTERNATE SYNTAX FOR p:empty (empty() FUNCTION) ================================================================= --> <input port="source" href="empty()" /> <!-- …or… --> <input port="source" empty="true" /> <!-- GROUPING FOR IMPORTS (Code reuse good. Overwhelming wall of text for imports bad.) ================================================================= --> <imports> <import href="…" /> <import href="…" /> <import href="…" /> </imports> <!-- …or space-separated URI list… --> <import href=" import1.xpl import2.xpl http://another/import.xpl" /> <!-- GROUPING FOR I/O PORTS ================================================================= --> <ports> <input port="source" href="…" /> <input port="blah" href="blah.xml" /> <output port="result" /> <output port="alt-result" /> </ports> ***** —Tony
Received on Thursday, 10 March 2011 16:04:58 UTC