Unplanned
Last Updated: 21 Jun 2023 05:56 by ADMIN
Bipin
Created on: 14 Jun 2023 16:43
Category: Grid
Type: Feature Request
1
Add ability to both AutoFit columns and allow the user to change the width manually.
I would like the ability to AutoFit Grid Columns on each change in the grid but also allow the user to adjust the column's width manually without being adjusted back by AutoFit. 
1 comment
ADMIN
Stamo Gochev
Posted on: 21 Jun 2023 05:56

Hi Bipin,

The auto-fit columns functionality requires various calculations and renderings of the Grid elements, so it is not an operation that we want to provide out of the box on "any" Grid update. What I can suggest in this case is to bind to Grid events that you are interested in and make a call to auto-fit the columns.

Regarding the combination of auto-fit and column resizing - this is possible with the current version - you can resize the columns after they have been auto-fitted.

If you auto-fit the columns after column resizing, then the previous column widths will be lost as auto-fitting is done depending on the content of the cells and independently by any specific width defined by user actions.

If you want to keep some previously expanded widths, then a possible approach is to manually track which columns have been resized using the state events of the Grid (for when a column width is updated) and restore these widths after auto-fitting 

Regards,
Stamo Gochev
Progress Telerik

As of R2 2023, the default icon type will be SVG instead of Font. See this blogpost for more information.