Tribou, Eric wrote: > Anyone using floated layouts have any tricks to share regarding the use of > images or other objects within your floats that go wider than the float > allows? That seems to be my biggest problem; things like images are thrown > into columns that get too narrow and force columns to drop/wrap. > > I've used some tricks like negative right margins on images to fake their > width to 0 or setting an image as the background to a 100% wide DIV. > Hopefully there are tricks out there I'm just not aware of. Any suggestions > you might offer would be appreciated. >
Certain types of negative margin layouts will allow some browsers to auto-expand divs and prevent them from wrapping down, generating a horizontal scrollbar instead. Here's a really simple example: http://www.pixelsurge.com/experiment/negative_margins_2.html In IE6, the yellow div with the big image stays propped open to the width of that image. In FF, it doesn't stay propped open, but at least the side float doesn't drop down or get overlapped. If you want FF to stay propped open too, you can feed it its own style sheet using table display values. I wrote an article on this a while back: http://www.communitymx.com/abstract.cfm?cid=EB8C5 But, this article was written before IE7 came out. Unfortunately, IE7 no longer has IE6's bug of auto expansion, nor does it have FF's support for table display values. Does this mean this method is dead? Perhaps. I haven't had a chance to play with it since IE7 came out. The best solution, of course, is to not let your structure get too small for your content, or to not put content that is too big for your structure into it. In other words, design for your content. The typical min-width solutions apply here. By the way, to start a new thread, do not reply to an existing message. When you do this, your message gets threaded on to the old thread, which messes up the archives and makes it less likely that others will see your message and subsequently reply to you. You must send a new message with an appropriate and descriptive subject line to [email protected] in order to start a new thread. Thank you for your cooperation and participation. Zoe -- Zoe M. Gillenwater Design Services Manager UNC Highway Safety Research Center http://www.hsrc.unc.edu ______________________________________________________________________ css-discuss [EMAIL PROTECTED] http://www.css-discuss.org/mailman/listinfo/css-d IE7 information -- http://css-discuss.incutio.com/?page=IE7 List wiki/FAQ -- http://css-discuss.incutio.com/ Supported by evolt.org -- http://www.evolt.org/help_support_evolt/
