<html><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">
<div>My logic was that putting "%s %s" is a valid string, and there shouldn't be any gotchas there - putting a "%s" into a String() doesn't do anything by itself. That the format attribute invokes processing on a normal string is natural to me and if you forget, you get "%s" on your screen to remind you :)</div><div><br class="webkit-block-placeholder"></div><div>As to the name of the function colliding, id' rather see the (lesser used, i presume, is the opinion?) format() function named to 'applyFormat' to mimic applying a delegate, and allowing both to be easily remembered.</div><div><br class="webkit-block-placeholder"></div><div>Any better? Think this is my best here, otherwise overall i still like #2 the best , strange though that sound.</div><div><br class="webkit-block-placeholder"></div><div><i>in tag land</i></div><div><br class="webkit-block-placeholder"></div><div><div>&lt;text datapath="person/" text="%s %s" format="$path{'firstName/text()', 'lastName/text()'}" /&gt;</div><div><br class="webkit-block-placeholder"></div><div><i>and in javascript:</i></div><div><br class="webkit-block-placeholder"></div><div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">&lt;text datapath="person/"</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">      ondata="applyFormat('%s %s', datapath.xpathQuery('firstName/text()'), datapath.xpathQuery('lastName/text()'))"</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">    /&gt;</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><br class="webkit-block-placeholder"></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">(which blows away the current contents of the text attribute by nature, of course)</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><br class="webkit-block-placeholder"></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">-j</div> </div></div><div><br></div><div><br><div><div>On Jul 11, 2007, at 3:59 PM, P T Withington wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">On 2007-07-11, at 15:49 EDT, Henry Minsky wrote:</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; min-height: 14px; "><br></div> <blockquote type="cite"><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">On 7/11/07, James Robey &lt;<a href="mailto:jrobey@laszlosystems.com">jrobey@laszlosystems.com</a>&gt; wrote:</div> <blockquote type="cite"><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; min-height: 14px; "><br></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">Wow, a major reduction in code size and removes lexically spurious layouts</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">too!</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; min-height: 14px; "><br></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; min-height: 14px; "><br></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">*If i were king*:</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">&lt;text datapath="person/" text="%s %s" format="$path{'firstName/text()',</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">'lastName/text()'}" /&gt;</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; min-height: 14px; "><br></div> </blockquote><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; min-height: 14px; "><br></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">I vote for that one!</div> </blockquote><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; min-height: 14px; "><br></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">Problems:</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; min-height: 14px; "><br></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">1) `text` is the actual content of the text node.<span class="Apple-converted-space">  </span>You don't want the compiler to magically guess that if there are %'s in the content that it should do something different.</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; min-height: 14px; "><br></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">2) `format` is a method on text nodes.<span class="Apple-converted-space">  </span>We cause infinite pain when we try to have an attribute and a method with the same name.</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; min-height: 14px; "><br></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">This suggestion is really choice 3 (which uses new attribute names to avoid the problems above):</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; min-height: 14px; "><br></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><span class="Apple-converted-space">  </span>&lt;text datapath="person/" dataformat="'%s %s'" data=$path{'firstName/text()', 'lastName/text()'} /&gt;</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; min-height: 14px; "><br></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">(I showed `dataformat` as being an expression, so you could have a variable format if you liked.)</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; min-height: 14px; "><br></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">So, should I infer you and James really like choice 3?</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; min-height: 14px; "><br></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; min-height: 14px; "><br></div> </blockquote></div><br></div></body></html>