Thanks. I'm aware that it's a privileged API. It seemed Botond was offering a workaround.
Anyhow, because of all your help I was able to dump the Frame Tree (not in real time). But I also learned the frame tree doesn't contain all the information I need. Especially the z-order information. The z-order information is included in the display-lists. These can already be dumped in real time, which is great. But they only contain the frames within the viewport, and I want this data on all frames within the document. I've posted my updated question in +mozilla.dev.tech.layout: https://groups.google.com/forum/#!topic/mozilla.dev.tech.layout/MClwXlzk5qM On Tuesday, 19 April 2016 15:49:40 UTC+2, Gijs Kruitbosch wrote: > On 19/04/2016 14:41, Jip de Beer wrote: > > I followed your steps exactly and uses this code to add a canvas on a page > > with jQuery: > > > > var myCanvas = document.createElement('canvas'); > > var width = $(document).width() > > myCanvas.width = width; > > var height = $(document).height() > > myCanvas.height = height; > > var ctx = myCanvas.getContext("2d"); > > ctx.drawWindow(window, 0, 0, width, height, "rgba(0, 0, 0, 0)"); > > console.log(myCanvas.toDataURL()); > > > > Result: > > TypeError: ctx.drawWindow is not a function > > > > I'm currently trying to figure out how to make Firefox render the entire > > page the whole time. > > drawWindow is a privileged API and you would need to use an add-on or > Firefox code to call it: > https://developer.mozilla.org/en-US/docs/Web/API/CanvasRenderingContext2D/drawWindow > > ~ Gijs _______________________________________________ dev-platform mailing list dev-platform@lists.mozilla.org https://lists.mozilla.org/listinfo/dev-platform