0 Favourites

[R79] Problem with "mobile" Screen Size

  • Since there where no solutions posted in the How-To, I assume that this is a bug:

    I'm playing with touch objects on my iPhone and stumbled across an issue I do not understand.

    How do I build an App, that uses the whole Safari iPhone Screen Size? When I set the layout to 640x960 an do NOT enable full screen mode, I get a border I do not like.

    <img src="http://quak.laurig.de/iphone.PNG" border="0">

    If I set full screen mode to on, the screen size no longer seems to stay to 640x960.

    In fullscreen mode - regardless if scalled or croped - when I query WindowWidth and WindowHeight I do not get 640x960 as expected, but 320x356...why's that?

    <img src="http://quak.laurig.de/fullscreen.png" border="0">

    The left half is crop, the right scaled mode. I am running iOS 5.0.1 on an iPhone 3 GS

    The realy weird thing is, the thin blue line is placed at the left border of the "layout" which is set to a width of 640. The red circle with the yellow star is automaticly placed at the calculated right lower corner (WindowWith & WindowHeigt)

    Both textfields are place on a HUD layer with paralax 0,0....

    CAPX

  • Construct 3

    Buy Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Buy Now Construct 3 users don't see these ads
  • If you do not enable a fullscreen mode, it is by design that it appears with the border: it's displaying the canvas inline in an existing HTML page.

    I'm not sure why the canvas appears at the wrong scale in Safari, but I noticed you're checking in preview mode, is it the same after you export?

  • Same thing.

    <img src="http://iphone.laurig.de/Foto.PNG" border="0">

    If you want to try yourself - LINK

  • Oh, that's correct for the iPhone 3GS. 640x960 is the size of the iPhone 4+ which has a double-resolution screen. The 3GS is 320x480 so the values are right once you take in to account the top and bottom bar.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)