Thanks, but why not generate a tree according to document ang css style at the same time? Or why is the post style decision needed?
Thanks, Song -----原信息----- 发自: ext Darin Adler 发送: 2011-06-16, 23:54 To: Liu Song.7 (Nokia-MP/Beijing) Cc: [email protected] 主题: Re: [webkit-dev] DOM tree vs. Render tree On Jun 16, 2011, at 7:21 AM, [email protected] wrote: > Could some share what’s the design consideration about the DOM tree and > Render tree separation? CSS styling makes it easy for almost any DOM node to render as almost anything. To give one trivial example, a paragraph element can be turned into a table cell with "display: table-cell" or removed from rendering entirely with "display: none". The main reason to have a separate render tree is that the structure and classes of the render tree nodes can reflect the post-style-computation decisions of what will actually be rendered, which can be quite a bit different from the structure of the document itself. The DOM tree nodes represent the document’s structure. -- Darin _______________________________________________ webkit-dev mailing list [email protected] http://lists.webkit.org/mailman/listinfo.cgi/webkit-dev

