Previous Message
Next Message

Blocks and floats - odd, simple situation

Sent by John Lewis on 10 March 2005 20:08


On Thu, 10 Mar 2005 11:58:58 -0600, Ken Martin [EMAIL-REMOVED]> wrote:

> When I have a floated element (a narrow column), I find that subsequent  
> block elements (like a h1) draw their box behind the float (noticeable  
> using background-color or border), but reflow text inside the h1 in  
> "response" to the float.

I had some success faking the behavior you want. I used a border that  
matches the page background instead of a margin (which is transparent).  
The border will obscure the box behind the float, but it only works in  
certain situations and breaks fairly easily. Example here:  
<http://gleemax.home.comcast.net/temp/blocks-and-floats.html>.

Floats are supposed to behave the way you described. If you don't need to  
use floats, maybe there is a better solution to your problem.

-- 
John Lewis
______________________________________________________________________
css-discuss [EMAIL-REMOVED]]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/
Previous Message
Next Message

Message thread: