JScript Operation - RealWorld forums

Log-in or register.

JScript Operation

Goofing off with my RWPaint
on January 10th 2022

Hi Vlasta, hope you are well.

I want to add a button to the toolbar that zooms to 100% with a click. Not sure if this is possible. Maybe something as follows (which fails)...

var zoom = Operation.Create("Image - Zoom");
zoom.SetParameter("Level", 1);
Operation.Execute(zoom, Document);

Thank you, Jedi

on January 12th 2022

Hi Jedi,

I am afraid that is not possible in the current version. Changing the zoom factor and mode is not an operation that can be done to the image, it is merely a state of the window that displays it.

It currently takes two clicks and there is no hotkey for the editors, though there is a hotkey for the preview windows. Is there a special situation in which you would want to set zoom 100% that would benefit from an extra button?


on January 15th 2022

Often the first thing I do when opening an image is go into the Zoom drop down list and set the image at 100%. The Zoom to Fit selection is generally more useful, but a quick way to go 1:1 would be nice, especially when mocking up a new UI design.

Thanks for your time

Page views: 662       Posts: 3      
Select background
I wish there were...
What about ICL files?