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

zaheer ahmad zaheer.mot at gmail.com
Mon Feb 18 04:31:09 PST 2008


hi,
The patch does not reposition the changed document to the top of the frame
view and also does not alter the documents width/height. The same behavior
is seen with transforms from html pages(e..g scaled content goes out of the
window)
Are these known issues?

Setting the transform origin (style->setTransformOriginX(Length(0,Fixed));)
should fix the first problem.  A force layout with changed width/height for
the renderview should solve the second problem. not sure if this is the
right thing to do.
let us know your comments.

thanks,
Zaheer

On Nov 30, 2007 4:47 PM, Alp Toker <alp at atoker.com> wrote:

> Zaheer,
>
> If you really need full page zooming so much and can't wait for the bug
> to get fixed, try something like this (untested):
>
> void webkit_frame_set_scale(WebKitFrame* frame, double scale)
> {
>     g_return_if_fail(WEBKIT_IS_FRAME(frame));
>
>     WebKitFramePrivate* frameData = WEBKIT_FRAME_GET_PRIVATE(frame);
>     Frame* wframe = frameData->frame;
>     Document* document = wframe->document();
>     HTMLElement* root =
> reinterpret_cast<HTMLElement*>(document->documentElement());
>     RenderObject* renderer = root->renderer();
>     RenderStyle* style = renderer->style();
>     TransformOperations ops;
>     ScaleTransformOperation* scaleOp = new
> ScaleTransformOperation(scale, scale);
>     ops.append(scaleOp);
>     style->setTransform(ops);
>     renderer->setStyle(style);
> }
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.webkit.org/pipermail/webkit-dev/attachments/20080218/fff2fae8/attachment.html 


More information about the webkit-dev mailing list