Table Column

Hi guys,

Im trying to explore Vaadin 7 using the demo layout and having problems with the table width between the column and the data which are not the same. there’s a few centemiter gap with the column and the data. what would be the problem about this?


https://www.imageupload.co.uk/image/5oV7

        table.setWidth("100%");
        table.setSelectable(true); 
        table.addStyleName("compact");
        table.setImmediate(true);
        
        table.addContainerProperty("client", String.class, null);   
   
        table.removeAllItems();
        List<PromoDealsBean> listPromoDeals = PromoDealsBean.getAllPromoDeals();
        int i = 0;
        for(PromoDealsBean bean : listPromoDeals){
            table.addItem(new Object[]{  
                bean.getClientName() 
            }, new Integer(i));
            i++;
        }
        table.setPageLength(0);

Try to remove the style you added:

table.addStyleName("compact");

I don’t know of any issues like this so it might be from that style.

Also try to use Grid instead of Table. It’s available since 7.4.

I’ll try Grid… Thanks