Programmatic Fit Content?

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
SteveTX
Posts: 170
Joined: Sun Jan 17, 2010 9:00 pm

Programmatic Fit Content?

Post by SteveTX » Sun Jun 23, 2013 3:34 am

Is there a programmatic way to change a field size to the appropriate height and width for my dyanmic content? I don't want it to be any larger than it has to as it will have actions associated with it for a mobile screen size.

Simon
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 3901
Joined: Sat Mar 24, 2007 2:54 am

Re: Programmatic Fit Content?

Post by Simon » Sun Jun 23, 2013 5:17 am

Hi Steve,
Does:
set the width of fld 1 to the formattedWidth of fld 1
set the height of fld 1 to the formattedHeight of fld 1
Help you?

Maybe it's just:
set the rect of fld 1 to the formattedRect of fld 1

Simon
I used to be a newbie but then I learned how to spell teh correctly and now I'm a noob!

SteveTX
Posts: 170
Joined: Sun Jan 17, 2010 9:00 pm

Re: Programmatic Fit Content?

Post by SteveTX » Mon Jun 24, 2013 2:09 am

Perfect. Simon, you're awesome.

Post Reply