• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

columnwidth in JTable

 
vinaya kumar
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello All,
I have table with 3 columns.
i want to set the columnwidth to dynamically,based on the screen size.
i.e i know what % of the screen size a column will take!
Based on these values and based on the screen size
i would like to set the values for columnWidth.
But my doubt is , for a column which has Boolean Class(checkbox),is there any minimum field width set.
This is because even if i make the column width to zero,the column is still displayed.
Thanks and Regards
vinaya
p.s Let me know if u require code.
 
Altaf Ahmad
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
TableColumn has a setMinWidth() method which governs the minimum width of columns. If you specify a value for the width which is less than the minimum width, then the minimum width is only as low as it'll go.
 
vinaya kumar
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
wow!
thanks a lot !
it works!
vinaya
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic