Suppress moving column of visible table area

I am using Vaddin 7.2.2 and found out a little bit strange behaviour by column resizing.

Having a Table with 2 columns:

It is possible to resize Column1 that Column2 is not visible any more:
|Column1 |

This behaviour can be reproduced in “” by resizing column “COUNTRY” to right that column “CODE” is not visible any more. But resizing column “CODE” in left direction does not move out column “COUNTRY” from visible area, it makes this column only smaller.

I would like to ask:

  • is it a feature or a bug?
  • is it possible to suppress this behaviour?
  • is it possible to call some method on Table object to restore the initial Table layout and get the Column2 back to Table visible area?

… thank you very much for any help / advice.

IIRC, this has been the behavior of the Table for years now. The idea is that if you have a very wide content inside a column but set a smaller width, the user can make that column much wider if they want to see the content. The only thing the Table does in this case is create scrollbars.

You can call setColumnWidth on any column to change the with from the server side. There is not a dedicated ‘repaint’ method, but refreshRowCache() might do it. Another way is to temporarily remove the container from the table and re-set it, which should clear column settings.