I believe this would be hard to add: the MarkupWriter has no knowledge of the components. So, to make this happen, each component would need to write the appropriate "t:" attributes to the MarkupWriter as it renders. I suppose its conceivable to imagine intercepting the component render, acquiring the attribute values and decorating the MarkupWriter to output them into the first element written by the component - but this seems quite complex to attempt; there are probably lots of corner cases such as components that don't generate an element (and so have no suitable place in the output to write the attributes).
I'm interested to know in what way this "would make life even better" for you... perhaps there is another way of approaching the problem. So far, I've written a lot of tests using PageTester and the tapestry-xpath library and I'm just using HTML "id" attributes with a little XPath and it's working great. Paul ------------------ Paul Field Research IT Deutsche Bank "Joost Schouten (mailing lists)" <joost...@jsportal.com> 26/05/2009 22:23 Please respond to "Tapestry users" <users@tapestry.apache.org> To Tapestry users <users@tapestry.apache.org> cc Subject Re: tapestry xpath and t: namespace I guess I'm looking for a way to tell the MarkupWriter (or other responsible DOM generators) to also output the t namespace in the generated html. In particulair, I'm after having the t:id added. Would this be hard to add, and what would be my entrypoint to start on a patch. The idea comes from wicket which has a getTagByWicketId which I think is quite powerful. Cheers, Joost On Wed, May 27, 2009 at 12:22 AM, Thiago H. de Paula Figueiredo <thiag...@gmail.com> wrote: > On Mon, May 25, 2009 at 6:14 PM, Joost Schouten (mailing lists) > <joost...@jsportal.com> wrote: >> First off, I love the new xpath project. Unit testing components and >> pages is a lot easier because of it. > > It can be used to write mixins too. :) > >> One thing that would make life even better is if I have a way to tell >> tapestry to print out all t: namespace params in the output xhtml (for >> testing purposes). Targeting specific components on a page will be >> made a lot easier. Does such a setting exist? > > I guess it doesn't, as the DOM XPaths works on is the generated HTML > output, not the template. > > -- > Thiago > > --------------------------------------------------------------------- > To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org > For additional commands, e-mail: users-h...@tapestry.apache.org > > --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org --- This e-mail may contain confidential and/or privileged information. If you are not the intended recipient (or have received this e-mail in error) please notify the sender immediately and delete this e-mail. Any unauthorized copying, disclosure or distribution of the material in this e-mail is strictly forbidden. Please refer to http://www.db.com/en/content/eu_disclosures.htm for additional EU corporate and regulatory disclosures.