Dynamically adapt column size in lists

When hostnames are too long, they tend to get on top of each other in the unresponsive list, which is not very useful.

This patch sets the number of columns and column size dynamically to avoid this behaviour.

While I'm at it, I've added Util functions so we can do that everywhere.
The +1 here feels sneaky.  Why's it a +1, and why is it hidden inside this ternary operator.