- From: John Boyer <boyerj@ca.ibm.com>
- Date: Wed, 29 Dec 2010 10:45:57 -0800
- To: Erik Bruchez <ebruchez@orbeon.com>
- Cc: Forms WG <public-forms@w3.org>, www-forms@w3.org
- Message-ID: <OFDA830E59.BD1216C5-ON88257808.0066E0C7-88257808.00671847@ca.ibm.com>
Cool, OK so that's at least two XForms implementations then that match empty string in a select1 ref to an item with an empty string value, if one exists. Leigh and Steven, can we discuss creating an XForms 1.1 erratum for this? Thanks, John M. Boyer, Ph.D. Distinguished Engineer, IBM Forms and Smarter Web Applications IBM Canada Software Lab, Victoria E-Mail: boyerj@ca.ibm.com Blog: http://www.ibm.com/developerworks/blogs/page/JohnBoyer Blog RSS feed: http://www.ibm.com/developerworks/blogs/rss/JohnBoyer?flavor=rssdw From: Erik Bruchez <ebruchez@orbeon.com> To: Forms WG <public-forms@w3.org>, www-forms@w3.org Date: 12/21/2010 07:14 PM Subject: Re: Implementors please read: poll about select1 and empty values Got it. Our implementation does an exact match, whether the value is empty or not. It seems a bit odd to me to make empty value behave differently from any other value, and I could bet that the default expectation for a form author would be to assume that, if an empty value is legal for an itemset value, then it should match an empty value in instance data. -Erik On Wed, Dec 15, 2010 at 9:43 AM, John Boyer <boyerj@ca.ibm.com> wrote: Hi Erik, Quick notes: 1) The poll is not about the question you answered in this email. I think we pretty much answered the original question with the "exact string match" behavior that you use everywhere except on initial load, so adjusting your initial load to be a string match without trimming would be best considering the answer we sent out already. 2) The poll question is asking what happens to a select1 when the ref of the select1 binds to a node with empty content and the select1 contains an item whose value is empty. To make it easy, say you use appearance="full" so that you get a radio button group. Let the item with the empty value be the middle of three item elements in the select1. Does the radio group show no items selected or does it show the middle item as selected? Cheers, John M. Boyer, Ph.D. Distinguished Engineer, IBM Forms and Smarter Web Applications IBM Canada Software Lab, Victoria E-Mail: boyerj@ca.ibm.com Blog: http://www.ibm.com/developerworks/blogs/page/JohnBoyer Blog RSS feed: http://www.ibm.com/developerworks/blogs/rss/JohnBoyer?flavor=rssdw From: Erik Bruchez <ebruchez@orbeon.com> To: www-forms@w3.org, Forms WG <public-forms@w3.org> Date: 12/14/2010 11:20 PM Subject: Re: Implementors please read: poll about select1 and empty values All, I haven't yet had time to fully dig into this, but our implementation seems to trim strings on both sides before comparison, but only on initial show of the page to indicatedthe initially-selected item. That would be a bug! Other than that, the Orbeon behavior is to do an exact string match with select1 (as pointed out, it doesn't for select). (BTW Leigh, I can't seem to run your test case page right now.) -Erik On Wed, Dec 8, 2010 at 10:09 AM, Leigh L. Klotz, Jr. <Leigh.Klotz@xerox.com> wrote: > A question has come up about conformance and interoperability of XForms > processors with regard to the behavior of select1 when a value is the empty > string or whitespace only. > > This message is a poll to find out how select1 with an empty item/value > element behaves in existing XForms 1.1 implementations. Based on the > results of this poll we may add additional test cases, additional > clarification, issue an erratum, or propose new features for XForms 1.2. > > Background: > The XForms 1.1 Recommendation says [1] about select1 (and select as well): > > > "For both closed and open selections, any selection item with a storage > value which is empty or which contains only white space characters must > remain deselected." > > Discussion: > Nick van den Bleeken tentatively reported that least one implementation > supports a select1/item/label for the empty item/value. > > John Boyer and I both noted that select has this implementation requirement > because its space-separated values in list content are indistinguishable > from empty. In short, the absence of any selected item is ithe indication > that no item is selected. > > John further noted, however, that the requirement on select1 is motivated > not only by consistency with select, but also by another point, that the > "required" MIP be used to indicate that a value has been set. John noted > that xsi:nil can also be used for this purpose, but is not well understood > or implemented. > > John suggested to form designers that a "none" value for any select1 > control-bound data would better be represented by a distinguished value > chosen by the application, e.g. "none" or "n", rather than an empty value. > > I noted that only if the XForms application and the data are co-designed can > the form designer can satisfy this requirement, and that web resources may > require an empty string to indicate a value of "none," and that allowing a > binding of a label gives form designers the ability to express this UI. > > As a result of this discussion, we are polling implementations and seeking > feedback on the presentation and behavior of empty ref node values and empty > item/value (and by extension, itemset) in select1. > > Test Case: > > I have produced a test and made it work using xsltforms. > It is available at http://xformstest.org/2010/12/select1-empty and please > choose select1-empty.xml > We're asking implementors to adapt and run this test case and report > behavior. > A sample report is below: > > Test Case Results Example > For the sample I produced, here are the results for the select1 cases with > an empty item/value. > (The test page also includes controls with no empty item/value). > > no appearance: > displays as pulldown menu > empty value displays as a blank item inside select1. (to spec) > selecting the "(empty)" labeled item causes only that control to change. > (partially to spec) > after that, selecting the unlabeled item causes all form controls bound to > the node to change to the "(empty)" labeled item (not to spec) > selecting the "full" labeled item causes all controls to change to "full". > (to spec) > selecting the "full" labeled item causes the blank item to disappear from > all select1 controls, however the explicit "(empty)" choice remains. > selecting the "(enpty)" labeled item again causes the blank item to > re-appear in all select1 controls (???) > > > appearance=minimal: > displays as pulldown menu > same behavior as above > > appearance=compact > displays as in-place visible menus with one selection allowed > same behavior as above > > appearance="full" > displays as radio buttons; no blank or unlabeled radio button > empty value displays as a selected "(empty)" radio button. (NOT to spec) > selecting the "(empty)" labeled item causes all form controls to change to > display the unlabeled item. (to spec) > selecting the "full" labeled item causes all controls to change to "full". > (to spec) > selecting the "full" labeled item causes the blank item to disappear from > all select1 controls, however the explicit "(empty)" choice remains; > selecting the "(empty)" labeled item again causes the blank item to > re-appear in all select1 controls. (???) > > Of the above, only the full appearance (radio) had a notable behavior: it > offered no way to choose the empty item, and if the empty item were chosen > by another control, it displayed with no selection. > > Leigh. > > > [1] http://www.w3.org/TR/xforms11/#ui-selectOne
Received on Wednesday, 29 December 2010 18:46:36 UTC