AutoResizePopupMenuCustomizer should consider Header AND Row

This forum is used by users to request and discuss new product features. Please do not use this forum for technical support including bug reports.

Moderator: JIDE Support

Forum rules
Product suggestions only. Please do not use this forum for technical support including bug reports.

AutoResizePopupMenuCustomizer should consider Header AND Row

Postby mgs » Thu Jan 08, 2009 12:37 pm

The AutoResizePopupMenuCustomizer has setConsiderTableHeader and setConsiderVisibleRowsOnly to let us tell JIDE what to consider when resizing. These two seems to be mutually exclusive because when set both to true and then call TableUtils.autoResizeAllColumns(treeTable), the table was resized based on header.

It would be nice to have a capability to consider both at the same time. For example, if the values in the table is longer than the header then used the maximum width of visible rows. However, if all rows in the column is empty or the width is shorter than the header, then use the width of the header. This way you will have smooth looking table. No "...'" in header or in cells. We would be very happy if Jide ha this capability as it retains the behaviour of our old table component.

You may also want to consider the option of allowing the developer pass a List of preferred column width.

Regards.
mgs
 
Posts: 48
Joined: Mon Dec 01, 2008 11:01 am

Re: AutoResizePopupMenuCustomizer should consider Header AND Row

Postby JIDE Support » Thu Jan 08, 2009 2:45 pm

Code: Select all
These two seems to be mutually exclusive because when set both to true and then call TableUtils.autoResizeAllColumns(treeTable), the table was resized based on header.


This is not true. Based on our code, we will consider the max width of the header and the visible rows. I thought what you described is exactly what it supposes to do. I also tried myself in a demo and it works like that.

I can add an option to pass in the preferred column width.

Thanks,
JIDE Software Technical Support Team
JIDE Support
Site Admin
 
Posts: 37219
Joined: Sun Sep 14, 2003 10:49 am

Re: AutoResizePopupMenuCustomizer should consider Header AND Row

Postby mgs » Fri Jan 09, 2009 9:28 am

JIDE Support wrote:This is not true. Based on our code, we will consider the max width of the header and the visible rows.

You are right. It must be something I have done in my code. I cleaned up my code and it works as I wanted.

JIDE Support wrote:I can add an option to pass in the preferred column width.

That would be great. Could you please let me know when it is available for download?

Thanks a lot.
mgs
 
Posts: 48
Joined: Mon Dec 01, 2008 11:01 am

Re: AutoResizePopupMenuCustomizer should consider Header AND Row

Postby JIDE Support » Thu Jan 22, 2009 5:50 pm

Just so you know, we added setMinimumWidth to AutoResizePopupMenuCustomizer in 2.5.0.

Thanks,
JIDE Software Technical Support Team
JIDE Support
Site Admin
 
Posts: 37219
Joined: Sun Sep 14, 2003 10:49 am

Re: AutoResizePopupMenuCustomizer should consider Header AND Row

Postby mgs » Fri Jan 23, 2009 11:17 am

Thanks. We are using it right away.
mgs
 
Posts: 48
Joined: Mon Dec 01, 2008 11:01 am

Re: AutoResizePopupMenuCustomizer should consider Header AND Row

Postby mgs » Wed Mar 04, 2009 3:12 pm

Is it possible to add setPreferredWidths or setMaximumWidth in AutoResizePopupMenuCustomizer? Basically, what we want is the table should first consider the width of the visible rows and then the header. After the maxium width of the column is identified it checks if it exceeded the maximum width. If greater than maximum width then it should set the width to the specified maximum width.
mgs
 
Posts: 48
Joined: Mon Dec 01, 2008 11:01 am

Re: AutoResizePopupMenuCustomizer should consider Header AND Row

Postby JIDE Support » Wed Mar 04, 2009 4:02 pm

Yeah. Understood your request. Would you please try set the column's max width? It will restrict the calculated column width not exceeding the max width if you set considerTableHeader true in current release.

And with this approach, you have an extra advantage that this maximum width will take effect in other scenarios also than auto resize column scenario only. If this can satisfy your request, we will not consider add a seperate setMaximumWidth() in AutoResizePopupMenuCustomizer.

Thanks,
JIDE Software Technical Support Team
JIDE Support
Site Admin
 
Posts: 37219
Joined: Sun Sep 14, 2003 10:49 am

Re: AutoResizePopupMenuCustomizer should consider Header AND Row

Postby mgs » Thu Mar 05, 2009 1:13 pm

Thanks for your suggestion. I experimented with column's maxWidth and preferredWidth and it looks like settimg preferredWidth satisfies our needs. By default the column used the preferredWidth but the user has the option to resize the column either manually or using the Auto Resize in the popup. maxWidth makes the column not resizable.
This looks great to me. Thanks.
mgs
 
Posts: 48
Joined: Mon Dec 01, 2008 11:01 am


Return to Product Suggestions

Who is online

Users browsing this forum: Google [Bot] and 12 guests

cron