[Resolved] Samsung Galaxy SIII everything looks small in display

Hello,
I created an app that looks perfect on my Droid X. I just tried it on a Samsung Galaxy SIII and everything looks tiny. I am using Widget Candy widgets and these lines of code are in one file:

-- THIS IS TO FIND OUT IF THE APP RUNS ON A TABLET OR A SMALL DISPLAY  
-- IF WE HAVE A TABLET, SCALE DOWN THE GUI TO THE HALF, OTHERWISE THE  
-- WIDGETS APPEAR TOO BIG. YOU CAN USE ANY SCALE, BUT .5 IS FINE HERE.  
-- CHANGING THE SCALE OF A WIDGET DOES NOT CHANGE ITS WIDTH OR HEIGHT,  
-- IT JUST SCALES THE WIDGET GRAPHICS USED (BORDERS, ICONS, TEXT ETC.)  
local physicalW = math.round( (display.contentWidth - display.screenOriginX\*2) / display.contentScaleX)  
local physicalH = math.round( (display.contentHeight - display.screenOriginY\*2) / display.contentScaleY)  
--//TODO: might have to modify or comment these out  
\_G.isTablet = false; if physicalW \>= 1024 or physicalH \>= 1024 then isTablet = true end  
\_G.GUIScale = \_G.isTablet == true and .5 or 1.0  

Should I comment those out or something else? I’m going to try commenting them out. I’ll let you know how it goes. [import]uid: 104085 topic_id: 33477 reply_id: 333477[/import]

I tried commenting the lines out and everything still looks very small in the simulator. In fact, the Galaxy SIII looks really small in the simulator. What’s up with that?
[import]uid: 104085 topic_id: 33477 reply_id: 133024[/import]

Nevermind. I was changing a file in a different directory from the directory where I was running the project from.

I just set _G.GUIScale = 1 and everything looks fine in the simulator. The Galaxy SIII still looks really small in the simulator though. [import]uid: 104085 topic_id: 33477 reply_id: 133026[/import]

Just a thought on this. Wouldn’t it be better to use dynamic scaling and baseline all your devices to the same point system and let Corona do the heavy lifting on scaling things?

You’re assuming a 50% difference in screen sizes and that won’t always be the case. In your case you’re setting the isTablet to true because the S3 is a 720x1280 device which is scaling everything by half. This is the quirky bit when dealing with percentages. The S3’s screen is 50% larger than the Droid X’s. But if you look at it the other direction, the Droid X is 33% smaller than the S3. Bare with me:

720 / 480 = 1.5 or 50% larger
480 / 720 = 0.67 or 33% smaller

Since you are halving your image sizes on devices larger than 1024 (and the S3’s long side is 1280px) you’re in effect making the images 50% smaller, not 33% smaller and therefore they are smaller than you expect. Try changing the multiplier to be 0.667 and see if it solves your problem.

But the bigger issue comes from other devices. What if someone installs your app on a Kindle Fire HD or some other device with an even higher resolution? Those percentages are going to get even more off and you will continue to have sizing issues. If you set your config.lua up and tell it to make each device share a common width/height then you don’t have to fight this.

[import]uid: 19626 topic_id: 33477 reply_id: 133071[/import]

Rob,
Thanks for the reply. You’re giving me more credit than I’m due. I didn’t write the scaling code- it came with Widget Candy. I like you’re idea about dynamic scaling and, as you suggested, it would be preferable if I didn’t have to worry about which device the app was installed on.

Widget Candy has some dynamic scaling features built into the widgets themselves, but I agree with your concern about this particular patch of code. If you have any specific suggestions about dynamic scaling, I would love to read them.
Sincerely,
Michael [import]uid: 104085 topic_id: 33477 reply_id: 133137[/import]

I tried commenting the lines out and everything still looks very small in the simulator. In fact, the Galaxy SIII looks really small in the simulator. What’s up with that?
[import]uid: 104085 topic_id: 33477 reply_id: 133024[/import]

Nevermind. I was changing a file in a different directory from the directory where I was running the project from.

I just set _G.GUIScale = 1 and everything looks fine in the simulator. The Galaxy SIII still looks really small in the simulator though. [import]uid: 104085 topic_id: 33477 reply_id: 133026[/import]

Just a thought on this. Wouldn’t it be better to use dynamic scaling and baseline all your devices to the same point system and let Corona do the heavy lifting on scaling things?

You’re assuming a 50% difference in screen sizes and that won’t always be the case. In your case you’re setting the isTablet to true because the S3 is a 720x1280 device which is scaling everything by half. This is the quirky bit when dealing with percentages. The S3’s screen is 50% larger than the Droid X’s. But if you look at it the other direction, the Droid X is 33% smaller than the S3. Bare with me:

720 / 480 = 1.5 or 50% larger
480 / 720 = 0.67 or 33% smaller

Since you are halving your image sizes on devices larger than 1024 (and the S3’s long side is 1280px) you’re in effect making the images 50% smaller, not 33% smaller and therefore they are smaller than you expect. Try changing the multiplier to be 0.667 and see if it solves your problem.

But the bigger issue comes from other devices. What if someone installs your app on a Kindle Fire HD or some other device with an even higher resolution? Those percentages are going to get even more off and you will continue to have sizing issues. If you set your config.lua up and tell it to make each device share a common width/height then you don’t have to fight this.

[import]uid: 19626 topic_id: 33477 reply_id: 133071[/import]

Rob,
Thanks for the reply. You’re giving me more credit than I’m due. I didn’t write the scaling code- it came with Widget Candy. I like you’re idea about dynamic scaling and, as you suggested, it would be preferable if I didn’t have to worry about which device the app was installed on.

Widget Candy has some dynamic scaling features built into the widgets themselves, but I agree with your concern about this particular patch of code. If you have any specific suggestions about dynamic scaling, I would love to read them.
Sincerely,
Michael [import]uid: 104085 topic_id: 33477 reply_id: 133137[/import]