Get the column width by index instead of position

85 Views Asked by At

I would like to get the column width by index instead of position.

To get the width of columns currently viewed I can use this.

bodyLayer.getColumnWidthByPosition(columnPosition)

Is it possible to get the column width by index instead? This would allow me to get the column widths of columns that aren't within the viewport. I would like to loop through every column and get its width.

1

There are 1 best solutions below

0
On BEST ANSWER

This is only possible if you operate on a deeper layer like the DataLayer. The ViewportLayer will not return you any width of a column that is currently not visible. That would violate the design of the ViewportLayer.