Reputation: 39
I want to avoid horizontal scroll in Vaadin grid and oblige column to be resized according to the screen. I tried grid.setExpandRatio()
but I have no change.
Have you any idea please?
Upvotes: 2
Views: 3029
Reputation: 2749
The Vaadin Grid component provides width control for each column. See API doc.
You can set expand ratio of each column that is added when additional free space is available beside the space that is required for each column. But this doesn't help in your case. The best way I found so far is to set a maximum width for a column that is suitable for shrinking.
Upvotes: 1