Re: CSS Engine Style Invalidation Strategy

On 7/29/13 7:48 PM, François REMY wrote:
> When an element is inserted, if the sibling-invalidation map of its previous sibling does not return zero, we reevaluate his next siblings. Otherwise we don't.

That's not good enough, unfortunately.  Consider this selector:

   div ~ span + i

and a DOM that looks like this:

   <div/><p/><i/>

and then a <span> is inserted.  There are no flags in your setup for tag 
names, right?

Also, inserting or removing a node can cause restyling of its parent or 
its preceding siblings, not just of following siblings.

> When an element is being removed, if its sibling-invalidation map does not return zero, we reevaluate his next siblings. Otherwise we don't.

Again, removing an element might need to restyle more than just the next 
siblings.

-Boris

Received on Tuesday, 30 July 2013 06:56:37 UTC