auto column width

auto column width

thegenethegene Posts: 4Questions: 0Answers: 0
edited May 2012 in General
I have the default settings on my table currently, so all the columns have "auto" width. The columns do indeed change width depending on the table width, but all the columns seem to be a bit confused. Columns with low width requirements are afforded more than some with high width requirements. I dunno why this might be happening or how to fix it. The difference between the columns is not very noticeable, I thought they were all just stuck at identical widths for a while, but it certainly looks like lots of space is being wasted in some circumstances.

I've tested and it behaves the same way in IE 9 and the latest Chrome.

Replies

  • allanallan Posts: 63,542Questions: 1Answers: 10,476 Site admin
    DataTables allows the browser to calculate the column widths using its built in algorithm (since recreating that would be a nightmare!). This is done by constructing a "worst case" table and reading the sizes from that. It can go slightly wrong from time to time, but should generally be okay.

    The best way to figure out what is going on is to give me a link to a table which shows a problem :-)

    Allan
This discussion has been closed.