Mouse events outside stack bounds on mobile

Colin Holgate colinholgate at gmail.com
Sun Oct 11 15:16:58 EDT 2015


Think of any story scene based game, where what you see is not a utility app full of fields and buttons that could be placed using code. You would not want to have to create different artwork for every possible aspect ratio screen. Instead you have extra scenery that gets revealed on wider or taller devices.

Almost all the apps I’ve made used showall, where either there was extra content to the left and right of the card area (stage area as the case was, not being LiveCode apps), or extra content above and below the card area. Which way I work depends on the nature of the app. For example, in a book like app I want the full height of the page to always be visible, and I reveal spare background to the left and right (this is with landscape by the way). For graphical games I make it be that all devices see the full width of the scene, and on wider aspect ration devices the scene gets cropped at the top and bottom. The essential game play is within a 16:9 center part of the display, and there is extra background to take it up to 4:3 ratio.

Sometimes I don’t want to eat into so much of either the width or the height, and for those cases I have 14:9 ratio content, and use noborder. On a 4:3 device you see the full height of the scene, and most of the width. On 16:9 devices you see the full width of the scene, and most of the height. It’s a good compromise, and the safety area is the middle 14:9 part of the scene.

The advantage of all this is that you don’t have to worry about either the screen size or aspect ratio, LiveCode makes your content fill the screen.

I made these pages to show off the different modes. Choose one of them and then resize the browser window to simulate different aspect ratio devices:

http://colin.scienceninja.com/showall.html
http://colin.scienceninja.com/noborder.html
http://colin.scienceninja.com/topleftnoscale.html
http://colin.scienceninja.com/noscale.html
http://colin.scienceninja.com/exactfit.html

The red lines are iPad ratio, green is iPhone 4 ratio, and blue is iPhone 5 ratio.



> On Oct 11, 2015, at 2:53 PM, Richard Gaskin <ambassador at fourthworld.com> wrote:
> 
> J. Landman Gay wrote:
> 
> > On 10/11/2015 9:02 AM, Roger Eller wrote:
> >> If showAll works properly on other mobile devices, but "in
> >> particular" fails on Android, it is a bug.  Workarounds are
> >> fine, but bugs still need to be addressed.
> >
> > I probably wasn't clear. ShowAll works (or rather, doesn't work) the
> > same way on both iOS and Android though I think it's still a bug. But
> > I've hit lots of other bugs that do only affect Android, mostly with
> > image redraws and visual effects which are significantly broken on
> > Android, and I need to submit reports about those.
> 
> Help me understand something:  when is showAll useful?
> 
> I can appreciate the ease for quickie builds during early-stage development, but sooner or later the app will (hopefully) be released into a world in which device resolutions, sizes, and ratios can't be known in advance.
> 
> On the desktop we handle all possible sizes with resizeStack handlers. When would a developer not apply the same loving care to their mobile layout?
> 
> -- 
> Richard Gaskin
> Fourth World Systems
> Software Design and Development for the Desktop, Mobile, and the Web
> ____________________________________________________________________
> Ambassador at FourthWorld.com                http://www.FourthWorld.com
> 
> 
> _______________________________________________
> use-livecode mailing list
> use-livecode at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode





More information about the use-livecode mailing list