W3C home > Mailing lists > Public > www-forms@w3.org > May 2006

RE: On running a pre-processor [RE: XForms timer]

From: Klotz, Leigh <Leigh.Klotz@xerox.com>
Date: Fri, 19 May 2006 15:46:41 -0700
Message-ID: <E254B0A7E0268949ABFE5EA97B7D0CF401DCAB9D@usa7061ms01.na.xerox.net>
To: "Mark Birbeck" <mark.birbeck@x-port.net>, "www-forms" <www-forms@w3.org>

Mark,
I think we're talking at cross purposes.  I don't see anything at all
that is outside of the XForms 1.0 recommendation in my example.

I think that the semantics are completely captured in
select/@enumeration='open' and bind/@type='xforms:listItems'.  I believe
a visual browsser has the freedom to present that as a completing-reader
type of chooser rather than a pulldown list chooser.   I don't see
repeat or non-standard attributres involved at all.

Now, if you want to have the nodeset of the itemset change in response
to typing, I agree, you'll need an @incremental on select1 and an event
handler to do the xf:send for you, but my guess is that for many of the
use cases, simply populating the instance for the nodeset fully will do,
and doing the as-you-type fetch is an extra thing.  But again, I think
this can be done on top of the select/itemset presentation described
above, and doesn't need any extra attributes, inputs, repeats, etc.

Leigh.

-----Original Message-----
From: www-forms-request@w3.org [mailto:www-forms-request@w3.org] On
Behalf Of Mark Birbeck
Sent: Tuesday, May 16, 2006 4:27 PM
To: 'www-forms'
Subject: On running a pre-processor [RE: XForms timer]


Hi Leigh,

Yes, you can of course use XForms to create an approximation of 'Google
suggest' functionality, by using a combination of a submission, two
instances, and a select1.

But to really get it right you require an input (using incremental), an
output, a repeat, some focus in and out handlers, a 'value changed'
handler,
and some script for keyboard events. Unfortunately, whilst it's true
that
this creates a reusable, generic, pattern, wiring these pieces up is far
more than we want authors to have to do. Ideally they would just provide
a
select1 with an extra attribute or two, and everything else would be
worked
out for them.

My point though, was that if we (as in formsPlayer) unilaterally start
adding such attributes to formsPlayer because we need these features
*today*, we start to move away from the standard. We obviously don't
want to
do that, but at the same time we can't stand still; running a
pre-processor
step that converts 'simple XForms with a sprinkling of non-standard
attributes' into 'complex XForms that religiously adhere to the
standard'
(and therefore will run in many processors) seemed to me to be a pretty
good
compromise.

Best regards,

Mark

Mark Birbeck
CEO
x-port.net Ltd.

e: Mark.Birbeck@x-port.net
t: +44 (0) 20 7689 9232
b: http://internet-apps.blogspot.com/
w: http://www.formsPlayer.com/

Download our XForms processor from
http://www.formsPlayer.com/

> -----Original Message-----
> From: Klotz, Leigh [mailto:Leigh.Klotz@xerox.com] 
> Sent: 16 May 2006 23:00
> To: Mark Birbeck; www-forms
> Subject: RE: XForms timer
> 
> Mark Birbeck wrote:
> >...To give an example, we want an author to be able to get 'Google
> suggest' 
> >style functionality just by using a drop-box, but we don't 
> want to go 
> >adding too much to formsPlayer that takes it away from 'pure'
> XForms.
> 
> I realize this is unrelated to the timer discussion, but I 
> believe XForms already allows the author to express the 
> intent you describe.
> It's up to vendors to present it properly ;-)
> 
> Leigh.
> 
> 
> <?xml version="1.0" encoding="UTF-8"?>
> <!-- ***** BEGIN LICENSE BLOCK *****
> - Version: MPL 1.1/GPL 2.0/LGPL 2.1
> -
> - The contents of this file are subject to the Mozilla Public 
> License Version
> - 1.1 (the "License"); you may not use this file except in 
> compliance with
> - the License. You may obtain a copy of the License at
> - http://www.mozilla.org/MPL/
> -
> - Software distributed under the License is distributed on an "AS IS"
> basis,
> - WITHOUT WARRANTY OF ANY KIND, either express or implied. 
> See the License
> - for the specific language governing rights and limitations under the
> - License.
> -
> - The Original Code is Open Selection Completion Example.
> -
> - The Initial Developer of the Original Code is
> -      Xerox Corporation
> -
> - Portions created by the Initial Developer are Copyright (C) 2006
> - the Initial Developer. All Rights Reserved.
> -
> - Contributor(s):
> -      Leigh L. Klotz, Jr.
> -
> - Alternatively, the contents of this file may be used under 
> the terms of
> - either the GNU General Public License Version 2 or later 
> (the "GPL"), or
> - the GNU Lesser General Public License Version 2.1 or later 
> (the "LGPL"),
> - in which case the provisions of the GPL or the LGPL are 
> applicable instead
> - of those above. If you wish to allow use of your version of 
> this file only
> - under the terms of either the GPL or the LGPL, and not to 
> allow others to
> - use your version of this file under the terms of the MPL, 
> indicate your
> - decision by deleting the provisions above and replace them 
> with the notice
> - and other provisions required by the LGPL or the GPL. If 
> you do not delete
> - the provisions above, a recipient may use your version of 
> this file under
> - the terms of any one of the MPL, the GPL or the LGPL.
> -
> - ***** END LICENSE BLOCK ***** -->
> <html xmlns="http://www.w3.org/1999/xhtml"
> xmlns:xf="http://www.w3.org/2002/xforms">
>   <head>
>     <title>Open Selection Completion Example</title>
>     <xf:model>
>       <xf:instance>
>         <data xmlns="">
>           <colors />
>         </data>
>       </xf:instance>
>       <xf:bind nodeset="colors" type="xf:listItems" />
>       <xf:instance id="colors">
>         <data xmlns="">
>           <color>red</color>
>           <color>green</color>
>           <color>blue</color>
>         </data>
>       </xf:instance>
>       <xf:bind nodeset="instance('colors')/color" 
> type="xf:listItem" />
>     </xf:model>
>   </head>
>   <body>
>     <h1>Open Selection Completion Example</h1>
>     <p>This example shows how an XForms user agent could 
> offer completion for select with open enumerations.</p>
>     <xf:group>
>       <ol>
>         <li>
>           <p>You can input whatever space-separated words you 
> want here, but you get no completion:</p>
>           <xf:input 
> ref="colors"><xf:label>Colors</xf:label></xf:input>
>         </li>
>         <li>
>           <p>This should be present the same as the above, 
> but with completion.</p>
>           <p>That is, you can input whatever space-separated 
> words you want here, <em>and</em> you get completion!</p>
>           <p>If it doesn't, ask your XForms vendor to make it so!</p>
>           <xf:select ref="colors" selection="open" 
> appearance="minimal">
>             <xf:label>Colors</xf:label>
>             <xf:itemset nodeset="instance('colors')/color">
>               <xf:label ref="." />
>               <xf:value ref="." />
>             </xf:itemset>
>           </xf:select>
>         </li>
>       </ol>
>     </xf:group>
>   </body>
> </html>
>  
> 
> 
Received on Friday, 19 May 2006 22:47:11 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Saturday, 10 March 2012 06:22:04 GMT