Page 1 of 1

Image doesn't resize in standalone

Posted: Thu Jan 15, 2009 5:23 am
by keyless
Using rev 2.8.1

I'm using this code in a stack to resize a image.

Code: Select all

set the height of last image to pNewH
set the width of last image to pNewW
It works fine in rev, but when I make a standalone the image doesn't resize.

***update I added a field and added some code that dumped the variables into the field to debug it. Oddly in this standalone the image resized fine. Then I made the field not visible and then made a new standalone. In this one the image didn't resize again ?????

Yep tested over and over, if I have this field visible, the resize works and if it is not visible then the resize doesn't work. I've just made it small and put it under another layer to hide it. that is very strang, but I guess I can work with it, unless anyone knows what is going on here.

Posted: Thu Jan 15, 2009 11:08 am
by Mark
Hi Keyless,

I think you need to post your entire script. When is the handler called (on preOpenStack/preOpenCard for instance)?

Best,

Mark

Posted: Fri Jan 16, 2009 6:49 am
by keyless
I have no pre anything scripts, handler is called from mouseup script. All it does is brings in an image, then it resizes (resize is a separate handler), keeping it proportional and no larger then the graphic I am placing it over.

I'll post script or maybe a demo stack when I get some time. I think its just one of those 2.8.1 things, and I haven't had any problems with it since I put in that field I was going to use to debug.

All I do with the field is put the two new size variables into it, so it has no function in the program or with the resize, yet for some reason it is the key to if resize works at all in stand alone (it always works in Rev). Take the field out or make it not visible and bam, the resize won't work in a standalone.

Off the top of my head, I was thinking that maybe the "put variables into field" was slowing down the run of the script somewhere it needed it to, but does,'t make sence why it wouldn't work with field not visible.