1

I've got a content area with a subcontent that's floated right inside. I want the subcontent to overlap the right edge just a bit. I also want the content area to be as tall as the subcontent which experience tells me I need to use overflow:auto to clear the float.

BUT I can't use overflow auto if I want the subcontent overlapping the edge can I? So I set overflow-x and overflow-y separately. Overflow-x:visible to show the overlap, & overflow-y: audo. But this has unexpected results!

Here's an example. I thought the subcontent would be visible, but it's being chopped off: http://jsbin.com/yigelepigi/2/edit?html,css,output

Is it possible to do what I want using overflow-x and y?

David Ball
  • 553
  • 9
  • 19
  • 2
    If it did overflow vertically, producing a vertical scrollbar, how would you expect the horizontal overflow to look? Should the horizontal content be painted over the vertical scrollbar? What happens when the user begins scrolling the content vertically? Should those parts of the horizontal overflow be clipped vertically? If so, that would look pretty odd. I think it makes more sense to ignore visible. – BoltClock Apr 07 '15 at 13:20

1 Answers1

0

Take away the overflow-x and overflow-y and the subcontent does overlap the right edge of its parent div.

Adrian
  • 285
  • 2
  • 14