Scaling Objects To Screen Size (Fit Any Screen)

The place to discuss anything and everything about running your LiveCode on Android

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
Googie85
Posts: 199
Joined: Tue Aug 05, 2014 10:07 am

Scaling Objects To Screen Size (Fit Any Screen)

Post by Googie85 » Sat May 19, 2018 11:27 am

Hi Guys!

I have searched the forums for scaling objects to fit different screen sizes (Phone Size to Tablet Size) and all the posts are 5+ years old. Is it possible that LiveCode 9 has now included a feature/s that could assist with the issues I'm facing?

Many Thanks,

Googie.

FourthWorld
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 9802
Joined: Sat Apr 08, 2006 7:05 am
Location: Los Angeles
Contact:

Re: Scaling Objects To Screen Size (Fit Any Screen)

Post by FourthWorld » Sat May 19, 2018 3:15 pm

Are you sure scaling is what you want?

If making one layout that expands or shrinks for everything from 4" to 13" will do what you need, the fullscreenMode property makes that easy.

But few apps do that. Most reposition controls to make optimal use of such a wide range of display sizes.

In the web world this is generically called "responsive design", with metrics often broken into categories by device width.

On both mobile and desktop, LC provides a resizestack message you can handle for positioning objects. Positioning properties include rect, loc, left, top, right, bottom, width, height, etc.

There have been a few discussions comparing scaling with positioning in recent months - here's one:

http://forums.livecode.com/viewtopic.php?f=7&t=30609
Richard Gaskin
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn

Post Reply

Return to “Android Deployment”