iPhone 5 simulator zooms all content

I’m currently trying to make my app work on the latest corona version and simulator. But now I’m stuck at a problem, the iPhone 5 simulator scales all content way too much. The app works and looks great on all other iOS devices, but not the iPhone 5.

Here is my config.lua file:

application =  
{  
 content =  
 {  
 fps = 30,  
 width = 768,  
 height = 1024,  
 scale = "zoomEven",  
 imageSuffix =  
 {  
 ["@2x"] = 2,  
 ["@3"] = 3,  
 ["-bar"] = 3.3,  
 ["-foo"] = 4.5,  
 }  
 },  
}  

It maybe isn’t what everyone suggests using but for me it has worked great with all iOS devices, except iPhone 5. [import]uid: 24111 topic_id: 31140 reply_id: 331140[/import]

Hi oskwish,

Your pixels for the Width and Height are wrong.

The iPhone 5’s screen is 640x1136.

Also, the scale should be blank because it scales it all wrong with any of the scales given.

It should look like this:

application = { content = { fps = 30, width = 640 height = 1136 scale = "", imageSuffix = { ["@2x"] = 2, ["@3"] = 3, ["-bar"] = 3.3, ["-foo"] = 4.5, } }, } [import]uid: 111492 topic_id: 31140 reply_id: 124536[/import]

But if I change the width and height all the other iOS devices render all the content with really weird placements. I need someway to use the config file that I got and then have some “if iPhone 5 then…” thingy. [import]uid: 24111 topic_id: 31140 reply_id: 124544[/import]

@Oskwish
You are in luck, because someone already worked on that sort of Config.lua
http://developer.coronalabs.com/forum/2012/09/18/supporting-iphone-5-configlua-still-need-tall-splash-image [import]uid: 134101 topic_id: 31140 reply_id: 124548[/import]

Yeah, if/else statements work in config.lua, makes it a lot easier to tailor everything for each device. [import]uid: 62706 topic_id: 31140 reply_id: 124561[/import]

Hi oskwish,

Your pixels for the Width and Height are wrong.

The iPhone 5’s screen is 640x1136.

Also, the scale should be blank because it scales it all wrong with any of the scales given.

It should look like this:

application = { content = { fps = 30, width = 640 height = 1136 scale = "", imageSuffix = { ["@2x"] = 2, ["@3"] = 3, ["-bar"] = 3.3, ["-foo"] = 4.5, } }, } [import]uid: 111492 topic_id: 31140 reply_id: 124536[/import]

But if I change the width and height all the other iOS devices render all the content with really weird placements. I need someway to use the config file that I got and then have some “if iPhone 5 then…” thingy. [import]uid: 24111 topic_id: 31140 reply_id: 124544[/import]

@Oskwish
You are in luck, because someone already worked on that sort of Config.lua
http://developer.coronalabs.com/forum/2012/09/18/supporting-iphone-5-configlua-still-need-tall-splash-image [import]uid: 134101 topic_id: 31140 reply_id: 124548[/import]

Yeah, if/else statements work in config.lua, makes it a lot easier to tailor everything for each device. [import]uid: 62706 topic_id: 31140 reply_id: 124561[/import]