Image doesn't resize in standalone

LiveCode is the premier environment for creating multi-platform solutions for all major operating systems - Windows, Mac OS X, Linux, the Web, Server environments and Mobile platforms. Brand new to LiveCode? Welcome!

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
keyless
Posts: 211
Joined: Wed Dec 12, 2007 11:21 pm

Image doesn't resize in standalone

Post by keyless » Thu Jan 15, 2009 5:23 am

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.

Mark
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 5150
Joined: Thu Feb 23, 2006 9:24 pm
Contact:

Post by Mark » Thu Jan 15, 2009 11:08 am

Hi Keyless,

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

Best,

Mark
The biggest LiveCode group on Facebook: https://www.facebook.com/groups/livecode.developers
The book "Programming LiveCode for the Real Beginner"! Get it here! http://tinyurl.com/book-livecode

keyless
Posts: 211
Joined: Wed Dec 12, 2007 11:21 pm

Post by keyless » Fri Jan 16, 2009 6:49 am

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.

Post Reply