[webkit-qt] How could I get hyperlink and control bounding box via QtWebkit?

UGlee matianfu at gmail.com
Mon Jul 18 08:06:58 PDT 2011

I am in a project which requires to render a static web page to
bitmap. By 'static' I mean javascript and all animations (gif, css
etc.) are disabled.

Besides the bitmap, we also want to output all bounding box of
hyperlink element, text, image, or image-map, as well as the bounding
box of form controls, input field, radio button, checkbox, etc. The
bouding box may be of different shape, rect, union of several rect,
circles, etc.

It seems that QtWebkit doesn't provide an easy way to get those info.
Although I can use hittest to test every pixel in rendered page, the
efficiency is an issue. So I want to hear some advice on how could I
achieve the goal. If I need to 'hack' or 'patch' the QtWebkit, where
should I started with?

Any advice would be greatly appreciated.

Tianfu Ma

More information about the webkit-qt mailing list