Position objects with float value

Anything beyond the basics in using the LiveCode language. Share your handlers, functions and magic here.

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
CenturyMan1979
Posts: 86
Joined: Tue May 15, 2012 5:56 pm

Position objects with float value

Post by CenturyMan1979 » Tue Jul 29, 2014 4:17 pm

Hey All,

Just wondering if anyone out there knows a way to position objects based on a float value instead of an integer?

dunbarx
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 10305
Joined: Wed May 06, 2009 2:28 pm

Re: Position objects with float value

Post by dunbarx » Tue Jul 29, 2014 10:00 pm

Hi.

Do you mean a floating point value? That is a value that contains a decimal point?

Yes and no. You will get no error if you try to:

set the left of fld 1 to the left of fld 2 + 4.5

But the engine will round the decimal appropriately. I suppose you cannot have half a pixel.

Craig Newman

Post Reply