School lesson 2 test app screen size issue
Moderators: LCNeil, heatherlaine, kevinmiller, elanorb
School lesson 2 test app screen size issue
I've set-up the lesson 2 test app for my iPhone 4s 640x960 but when I load it onto my 4s it isn't the correct size. I can only see part of the title bar that says contacts. I'm using LC 6.6 and Xcode 5.1. Phone is iOS 7.1. Is this a bug or do I have something set-up incorrectly?
Roddy
Roddy
Re: School lesson 2 test app screen size issue
Hi Roddy,
As of LiveCode 6.5.1, there was a new property added that determines the scaling factor between logical and device pixels and this will explain why some of your stack is cut off. The pixelScale is initialised to the systemPixelScale on startup but can be modified whenever needed.
If you add the following to your stack script then your app will display correctly on iOS-
Kind Regards,
Neil Roger
--
RunRev Support Team ~ http://www.runrev.com
——
As of LiveCode 6.5.1, there was a new property added that determines the scaling factor between logical and device pixels and this will explain why some of your stack is cut off. The pixelScale is initialised to the systemPixelScale on startup but can be modified whenever needed.
If you add the following to your stack script then your app will display correctly on iOS-
Code: Select all
on openStack
set the pixelScale to 1
end openStack
Neil Roger
--
RunRev Support Team ~ http://www.runrev.com
——
Re: School lesson 2 test app screen size issue
Hi Neil,
That's giving me the error:
pixelScale: the pixelScale property cannot be set on this platform
I'm developing on Mavericks with LC 6.6 and targeting iOS 7.1 on the simulator.
That's giving me the error:
pixelScale: the pixelScale property cannot be set on this platform
I'm developing on Mavericks with LC 6.6 and targeting iOS 7.1 on the simulator.
Re: School lesson 2 test app screen size issue
Hi Roddy,
Pixel scale is a mobile specific property so you will receive an error when you attempt to execute it within the desktop environment. You will need to add some additional checks so that the property is only set on mobile-
Kind Regards,
Neil Roger
--
RunRev Support Team ~ http://www.runrev.com
——
Pixel scale is a mobile specific property so you will receive an error when you attempt to execute it within the desktop environment. You will need to add some additional checks so that the property is only set on mobile-
Code: Select all
on openStack
if the environment is "mobile" then
set the pixelScale to 1
end if
end openStack
Neil Roger
--
RunRev Support Team ~ http://www.runrev.com
——
Re: School lesson 2 test app screen size issue
The dictionary says the pixelscale property is only supported on iOS and Andriod.
This worked:
on preopenStack
iphoneUseDeviceResolution true
end preopenStack
Cheers!
This worked:
on preopenStack
iphoneUseDeviceResolution true
end preopenStack
Cheers!
Re: School lesson 2 test app screen size issue
That worked too, thanks.