Page 1 of 1

Customizing field widths in the grid widget

PostPosted: Fri Nov 04, 2011 4:57 am
by rleyba
Hi Steve,

How do we individually modify the length of the "rectangles" while in edit view for a record which includes a grid widget?

In my case below, all the 4 fields show up in the form with equal lengths, but I want the "rectangle" of the Description field to have a longer length than the others. It doesn't help much if the data entry behavior causes the text to scroll to the left as I add to my description field as there are may cases (i.e. when proofreading the entered data while still in edit mode) we want to see the whole field content. In the mySQL table, the 4 fields have different lengths, but xataface presents the form with the fields all of equal length.
Would there be an easy way to do this?

[Devices]
widget:label = "Devices"
transient=1
relationship=Devices
widget:type=grid
widget:columns="DeviceName, IPAddress, Location,Description"
order=22

thanks Steve.

Re: Customizing field widths in the grid widget

PostPosted: Fri Nov 04, 2011 9:45 am
by shannah
You can use CSS to target the fields directly and force them to be certain widths. Just check the resulting HTML source and target the fields based on class or ID to make them particular widths.

Re: Customizing field widths in the grid widget

PostPosted: Mon Nov 07, 2011 5:53 pm
by rleyba
Ok Steve...I'll try that route. Thanks.