site news archive - minesweeper display bug
15th October 2004 - 23:19
If you have a look in the news archive at the entry titled minesweeper you'll see that I mentioned a display bug that I'd managed to solve, but didn't know why the solution worked.
I've read lots more information about CSS and web design since then and I believe I now know why the solution works. The solution I found was that when I reduced the line-height property of the table cells, the gap disappeared. Apparently this is because when images are displayed they sit on the baseline of the text, where most normal text would sit. The gap that appeared below the images was the area below a line that the drop down parts of the letters g and y etc. would drop down into, hence reducing the line height moved this area up "under" where the image sits. Not particuarly exciting, but it satisfied my curiosity.
I found this information from a link in a post to the CSS Discuss list, which is an excellent resource if you're at all interested in CSS design issues, you can find a link to the list on the links page.