I have a vaugue idea to move the HTML formatting part of form elements to the ADP page without requiring the designer to specify the full form template inline in the ADP.
Right now when you use form builder or ad_form, the programmer can specify html attributes of the form element such as size or rows/cols in the tcl file when the element is created.
I am thinking that we want a way to be able to specify the html attributes for an element from the ADP file. Something like:
<formtemplate id="myform">
<formelement id="first_name" html="size 30">
<formelement id="middle_name" html="size 1">
<formelement id="last_name" html="size 30">
<formelement id="notes" html="rows 30 cols 80">
</formtemplate>
The formelement (or whatever, the tag name can be decided during implementation) would modify the form element definition before the form is rendered by the form template.
I think this might be useful for another option I wanted to add, the ability to specify grouping for form elements. So that in this example, a designer could specify that first_name, middle_name, last_name would all be grouped together. How they are "grouped" would be determined by the formtemplate used. Perhaps all in one table row, perhaps a box is drawn around it. That can be decided by the form style that is used.
I think this control might be best delagated to a designer.
Of course we can just specify each formwidget, I am not sure this is absolutely necessary, is there a better way to get this control but keep consistent form styling across a site?