logo       

Re: Activating the fullscreen zoom feature on page load: msg#00048

web.kupu.devel

Subject: Re: Activating the fullscreen zoom feature on page load

Andrew Crowe wrote:

> What would be the best way of going about activating the fullscreen zoom
> feature of kupu on a page load?
>
> I've added a save button to the zoomed version and I'd like to be able
> to have links that will load straight into the full screen editor to
> make editing as transparent as possible. However I'm not sure how to
> activate kupu functions as soon as it has finished loading?

First you need to get hold of the relevant instance of Kupu: for Plone it
is stored in window.kupu. Then you need to find the zoom tool, finally you
need to tell it to zoom.

This is untested but try adding this to the end of your page:

<script type="text/javascript">
addEventHandler(window, 'load',
function() {
var zoomtool = window.kupu.getTool('zoomtool');
zoomtool.execCommand();
}
</script>

>
> If anyone knows off-hand how to do that then that'd be great thanks.
>

Alternatively train all the users to press alt-x when the page loads.


<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

News | FAQ | advertise