This week's book giveaway is in the OCAJP 8 forum. We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line! See this thread for details.
You can't change the width of individual cells, only of a complete column. The PdfPtable class has the setWidths method for that, or you can use the PdfPTable(float relativeWidths) constructor.
Joined: Mar 19, 2008
so, in the Java PDF we can't set the size to the cells, i.e. if the table width is 600 like , then the three cells equally shares the size? I think it doesn't make sence.. but I need to maintain three cells in different sizes as I mentioned in the query. what can I do?
Joined: Mar 22, 2005
The two methods I mentioned let you set different widths for each column, while setTotalWidth sets the width of the table itself. Why do you think that doesn't make sense?