Infamous IE hasLayout is toast

Written by on December 24th, 2007 in Ajax News.

We are slowly finding more and more out about how nice IE8 is going to play. Markus Mielke
came out to tell us that hasLayout is a goner:

I do not think I am disclosing too much by saying that HasLayout will be history with IE8 (it was an internal data-structure to begin with and should have never been exposed). See http://msdn2.microsoft.com/en-us/library/bb250481.aspx for more details.

So what does “having a Layout” mean?

  • In short, having a layout means that an element is responsible for sizing and
    positioning itself and possibly any child elements. (If a child element has its
    own layout, it sizes itself and its descendents, but the original layout
    positions the child.)
  • Some elements have a “fixed” size or otherwise have special sizing constraints.
    They always have layout—for example, buttons, images, inputs, selects, and
    marquee elements have always a native size even if width and height are not
    specified.
  • Sometimes elements that do not normally require layout information, like a div
    or a span, may have properties specified that force a layout to be
    applied in order to support the property—for example, the element must
    have a layout in order to get scrollbars.
  • Once a layout is applied the “hasLayout” flag is set. This property returns
    true if queried.

Read more on hasLayout.

Source: Ajaxian
Original Article: http://feeds.feedburner.com/~r/ajaxian/~3/205581878/infamous-ie-haslayout-is-toast

Comments are closed.



Site Navigation