How to get screen size and resolution
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller
How to get screen size and resolution
Hi Folks,
I am trying to figure out if there is any way to determine the screen size and resolution. I have been looking through the documentation but have not been able to find any details on this. I have had a look at the platform, environment, processor, machine and systemVersion functions, and am wondering if there might be others I've missed that might be useful for determining the screen size. I want to write an application that will scale from smartphones to the desktop.
Any help would be greatly appreciated.
Thanks,
Daryl
I am trying to figure out if there is any way to determine the screen size and resolution. I have been looking through the documentation but have not been able to find any details on this. I have had a look at the platform, environment, processor, machine and systemVersion functions, and am wondering if there might be others I've missed that might be useful for determining the screen size. I want to write an application that will scale from smartphones to the desktop.
Any help would be greatly appreciated.
Thanks,
Daryl
Re: How to get screen size and resolution
Try the screenrect.
PowerDebug http://powerdebug.ahsoftware.net
PowerTools http://www.ahsoftware.net/PowerTools/PowerTools.irev
PowerTools http://www.ahsoftware.net/PowerTools/PowerTools.irev
Re: How to get screen size and resolution
Hi MWieder, that is just what I was looking for.
Regards,
Daryl
Regards,
Daryl
-
richmond62
- Livecode Opensource Backer

- Posts: 10388
- Joined: Fri Feb 19, 2010 10:17 am
Re: How to get screen size and resolution
That only gives you the resolution: it does NOT give you the physical screen size.
Re: How to get screen size and resolution
Come on, Richmond, 13 years later? 
Re: How to get screen size and resolution
Richmond.
13 years or not, I think the OP actually wanted what Mark suggested. After all, the physical dimensions of one's screen can only be found with a ruler, or by reading the manual that comes with the device, and that likely does not mean anything.
Craig
13 years or not, I think the OP actually wanted what Mark suggested. After all, the physical dimensions of one's screen can only be found with a ruler, or by reading the manual that comes with the device, and that likely does not mean anything.
Craig
-
richmond62
- Livecode Opensource Backer

- Posts: 10388
- Joined: Fri Feb 19, 2010 10:17 am
Re: How to get screen size and resolution
I have a 27 inch iMac that I can 'dial down' to an 800 * 600 screen resolution, and I can do the same with my cathode ray tube G3 iMac . . .
So, while LC can tell me that my screenRect is 800 * 600 on both of those machines, it cannot tell me that that looks reasonable on the G3 and like a bloated haggis on the 27 inch monster.
Of course if LC could determine the maximum screen resolution of a particular display that would be jolly useful.
So, while LC can tell me that my screenRect is 800 * 600 on both of those machines, it cannot tell me that that looks reasonable on the G3 and like a bloated haggis on the 27 inch monster.
Of course if LC could determine the maximum screen resolution of a particular display that would be jolly useful.
Re: How to get screen size and resolution
Richmond.
But it was never actually screen "size" that was in play. It was resolution, and I suppose if you were porting to an 85" TV at 800x600 each pixel would be about the size of a pignoli. No problem, just view the screen from 20 meters.
Craig
But it was never actually screen "size" that was in play. It was resolution, and I suppose if you were porting to an 85" TV at 800x600 each pixel would be about the size of a pignoli. No problem, just view the screen from 20 meters.
Craig
-
richmond62
- Livecode Opensource Backer

- Posts: 10388
- Joined: Fri Feb 19, 2010 10:17 am
Re: How to get screen size and resolution
Let's throw in Windows pixel scaling just to stir the discussion up a bit more.
