Hi all,

I am getting started customizing and starting up a firefox extension called ColorZilla [1], that provides a kind of zooming on webpages. Well, at this point, I got the core of this extension working on my own one (nothing special yet).

The main problem is that the colorzilla uses a depth-first based algorithm to reach such a functionality, like this:

** it retrieves (through a recurse method) every single node from the main dom tree of the webpage, and for each one (node), it does a comparison to find out if it is or not a relevant node for zooming (e.g. images, frames, font and so on). If so, the current zoom scale is applied to this node.

But this retrieving is done every time that zoom is required by the user (pretty bad). So, my idea is removing the recursivity of the colorzilla's algorithm storing all relevant nodes in a kind of linked list (or hash) during the rendering of the webpage, and then use just these stored elements to perform the zooming.

Is it feasible ? If so, my question is: where (in the source code) is handled the rendering ? Where do I get this dom tree ?

[1] http://www.iosart.com/firefox/colorzilla/

regards

--Antonio Gomes
Nokia Technology Institute (INdT)
_______________________________________________
mozilla-layout mailing list
[email protected]
http://mail.mozilla.org/listinfo/mozilla-layout

Reply via email to