At work we’re using jNice to make our buttons look a bit nicer. Unfortunately the library itself has some IE6+IE7 bugs. One of these bugs affects the styling of <button>'s. I have spent a couple of hours this morning investigating this bug and trying misc. classic IE fixes to no avail.
Steps to replicate in IE8 (using compatability mode to simulate IE7):
From my investigation it seems to be to do with floats and display: block on the inner floats that causes the wrap. Obviously the easy fix is to set an explicit width for the inner span’s but we use jNice across the whole site for all kinds of these buttons which have different amounts of text inside of them, so explicitly setting widths isn’t an option. The buttons need to dynamically expand.
Actually it is just the fact that the span is floated without a width inside the button and causes IE to “shrink to fit” because the parent (the button element) is also shrink to fit. It’s just buggy behaviour again.
I did suspect this was the case, although I wouldn’t have guessed the fix I’ll do some testing tomorrow using your fix Paul. Thanks as always and hope all is well!