> -----Oorspronkelijk bericht-----
> Van: [EMAIL PROTECTED] 
> [mailto:[EMAIL PROTECTED] Namens Michiel Meeuwissen
> Verzonden: maandag 7 november 2005 10:38
> Aan: Discussion list for developers
> Onderwerp: Re: [Developers] DataType String
> 
> 
> Ernst Bunders wrote:
> > there is allso a middle way. We could define a gui 
> defenition language
> > compareable to the searchquery syntax, where you can define 
> > characteristics of a gui interface element:
> > <guitype>
> >     <line length="40">
> > </guitype>
> 
> I think the lenght of value is suficciently defined by its 
> length. The gui can decide on a different presentation 
> length, but I think that is solely a CSS issue.
> 
> > <guitype>
> >     <textarea width="40" height="10%">
> > </guitype>
> 
> Number of lines is quite hard to fixate, but a reasonable 
> guess would be the length divided by a line-length..
> 
> 10% of what?

of the avaliable space

well, usefull syntax would have to be puzzeld out. the main idear is
that you can determin the gui interface type in a declarative manner,
and leave the domain specific choices to the handlers for that domain
(like the searchqueries).

> 
> So, you may have a point here, but I don't really get it. If 
> these things still server as a mere indication, that I'd say 
> that the 'actual' maximal length is a good indication too..

well, that depends. consider the below:
<guitype>
        <box align="horizontal">
                <label value="${fieldname}" width="80%"/>
                <line length="20%"/>
        </box>
</guitype>

in this example you make the stricly presentation related choice to make
a lot of room (in whatever space is available for showing this field
interface type) for a label containing the name of the field, and only a
small area for the actual input. (even though the fieldtype length could
be anything).


> 
> 
> > getting all carried away, i think we could even add some kind of
> > databinding where, for instance in an i18n fieldtype (an 
> xml field with 
> > elements for some content for different languages) you 
> could define a 
> > combination of a dropdown with all supported languages with 
> a textarea 
> > allowing you to edit the contents of the matching element.
> 
> These things are of course feasible. In the 'guihandler' 
> you'll sometimes need datatype specific information. Perhaps 
> it's even better to match on class of the datatype rather 
> than on identifier, because then you could easilily plug in 
> 'I18NXmlHandler' into taglib. (It's not the name which is 
> important but the class).
> 

i don't really understand what you mean here.

> But actually I think it is possible already. If you define 
> 'i18xml' in datatypexml, then you can associate a typehandler 
> in taglib in 'fieldtypes.xml' of taglib with that string.

i don't know about that yet either.

I will soon have to seriously gear up on the fieldtypes code.


all in all this idear of declaring the gui of a fieldtype as well as
it's content properties seens natural. the question is if it is realy
nececairy. Maybe we have to think about it a little bit.

Ernst


> 
> Michiel
> 
> -- 
> Michiel Meeuwissen                  mihxil'
> Peperbus 111 MediaPark H'sum          [] ()
> +31 (0)35 6772979         nl_NL eo_XX en_US
> 
> 
> 
> _______________________________________________
> Developers mailing list
> [email protected] 
> http://lists.mmbase.org/mailman/listinfo/developers
> 
_______________________________________________
Developers mailing list
[email protected]
http://lists.mmbase.org/mailman/listinfo/developers

Reply via email to