[webkit-dev] Re: get the bits of the complete page

Alp Toker alp at atoker.com
Fri Nov 23 00:12:37 PST 2007


zaheer ahmad wrote:
> hi,
> iam working on the gtk port of webkit and have a need to get the
> bitmap of the entire page without actually rendering it. Is there an
> easy way to get in the current implementation.  one of the ways i
> thought was to create a cairo surface over a memory buffer (instead of
> the drawing window in webkit_page_expose_event) and pass it to the
> scrollview::paint with a complete rectangle. Not sure if this is the
> right track to solve this issue (also this could be performance/memory
> intensive)

There's no public API to render content to an arbitrary graphics context 
yet. There are a few examples showing how to do it in places like 
webkitgtkpage.cpp or the experimental printing patch (bug #15576) 
though, if you're willing to use internal API.

Can you give an idea of what you need this for? It might help provide 
direction for how to expose this in the API, or it might turn out 
there's a simpler way of doing what you want.


More information about the webkit-dev mailing list