Return-Path: X-Original-To: apmail-cordova-dev-archive@www.apache.org Delivered-To: apmail-cordova-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id B92F5105BB for ; Fri, 6 Dec 2013 16:41:27 +0000 (UTC) Received: (qmail 59333 invoked by uid 500); 6 Dec 2013 16:41:26 -0000 Delivered-To: apmail-cordova-dev-archive@cordova.apache.org Received: (qmail 59257 invoked by uid 500); 6 Dec 2013 16:41:26 -0000 Mailing-List: contact dev-help@cordova.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cordova.apache.org Delivered-To: mailing list dev@cordova.apache.org Received: (qmail 59249 invoked by uid 99); 6 Dec 2013 16:41:25 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 06 Dec 2013 16:41:25 +0000 X-ASF-Spam-Status: No, hits=1.5 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of mmocny@google.com designates 209.85.220.170 as permitted sender) Received: from [209.85.220.170] (HELO mail-vc0-f170.google.com) (209.85.220.170) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 06 Dec 2013 16:41:21 +0000 Received: by mail-vc0-f170.google.com with SMTP id ht10so981095vcb.29 for ; Fri, 06 Dec 2013 08:41:00 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:content-type; bh=arvBzQ7FgmEAeB0KCXKxQcU/LnMO8/qz7oncI2qgKKs=; b=Z1HCO8fYJYk+p/VgTbWJQkCkJVJE19VzMY8MpuBj6obf0Rb4raDOVvKn4Ca6hf9dZG z+L0HX2VRHMzdpQbFIK5uVQ0qZcREHnh6D6e44fU7vLuyDs7CkCIt7fp+YuWjU370bOG fg9ehioxkFcbQjehOlHo7jbucmpk9S0uBdXNUfqrU/Ip4fM/PCSAstGBCUCjydILTy00 Uw1+UHi7a800QSW1NDxXG7ELHo6Q8jh7he7LnXLpG7JXEVoWHlruHyOn+aGdCUZhU80Z Am0vUDPlxEZPPuPZpbcStGix75QX0I+dnhHZ01iaVnMGBbwm2O4LGXjYW0rN29i5ixOD mc2g== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:content-type; bh=arvBzQ7FgmEAeB0KCXKxQcU/LnMO8/qz7oncI2qgKKs=; b=bs21BHHY9eOGEWd5pezX3lRqd9sK/vCcAbBh+SGL7Ms+0lAo4sQg4e9kC17Zla5ZbG X26Vr5dKyUTbgfxRionkl+1MExQ31p9/Y7aCZl/qhTannL0PpqYoi1fO+nduhrgQKQ+Y 8xQZl7876Nr4v92nAc3Jr2Y9BSzmySmkLNjiE= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:sender:in-reply-to:references:from :date:message-id:subject:to:content-type; bh=arvBzQ7FgmEAeB0KCXKxQcU/LnMO8/qz7oncI2qgKKs=; b=ivhS6Cryi0GDlAGClb+bCDD3a1nNzRKRMSPTfZxLPd0WpKRRAAL02EGzloq04OyFhP UQ85UaCvF68R+MHYxp1RJ/jwTgzb37Snr5xPwFIYjObYJDZYCcPgu0s6+3tooXWIkm7j k0MfeVEsQyWoIpGnvHqhUJ7ZT1d7lUaPzfVBIhwB9nUQ91PRE5U4yx3K6GCOJtU1y0CU xFu6ZG/OB9PyCWtKXnCMOD0DITsLuqepg7Ni1g9lmaSI4y7nhDil1Faa5ND7VQrwUp4B fLTJihpLE7t3YbfNsSUuk1UBkapb6vZe2XQ0Hf0c6OcYmplzgioqCiaAZWpdE2l/D6z+ vEkw== X-Gm-Message-State: ALoCoQlwsI8AqNLYTljppV8v70e2pF35x7dBMCcfEGQFzA2mo9IelIkrbRWhWrET3Uc7Vn+lwUtvGIt84Bm61Byz5FM3WY7muwnAi1N6P0Ekg4d32RrhGMbTNjZVd9QuqST2lMA201jZ5YvnuD7c4MdvumraIbbGq2W1MMIP0Y6Athw8ggLbChiw9hl2sHP/DED98xIlS7XgSrvmG5dJvtCHUOwXXwJsqg== X-Received: by 10.58.216.74 with SMTP id oo10mr2565669vec.0.1386348060049; Fri, 06 Dec 2013 08:41:00 -0800 (PST) MIME-Version: 1.0 Sender: mmocny@google.com Received: by 10.52.110.38 with HTTP; Fri, 6 Dec 2013 08:40:39 -0800 (PST) In-Reply-To: References: <6affe29656d2421489861af148d8c6c6@DBXPR03MB159.eurprd03.prod.outlook.com> <301cd1592ef14342a7e2c8ca7c72800d@DBXPR03MB159.eurprd03.prod.outlook.com> <0056371D-E4A3-4A61-89AA-997A9D41E727@gmail.com> From: Michal Mocny Date: Fri, 6 Dec 2013 11:40:39 -0500 X-Google-Sender-Auth: e-ztsBu8DGade5ezyGWEMImKGpI Message-ID: Subject: Re: iOS webview size To: dev Content-Type: multipart/alternative; boundary=047d7b86e3d8a7d41c04ece04fee X-Virus-Checked: Checked by ClamAV on apache.org --047d7b86e3d8a7d41c04ece04fee Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Yeah if you don't have correct viewport, and are using the 3.5 inch retina iphone simulator, you will get 2 device pixels per css pixel, and thus see the resolution you claim. Also, even if you fix the viewport, I think that for efficiency reasons some web renderers will specifically treat the canvas element as lowdpi even on a highdpi device. I do not know the details of safari webview, but thats worth exploring if viewport doesn't fix the issue. One quick article I found that generally explains things to consider when working with canvas on highdpi is: http://www.html5rocks.com/en/tutorials/canvas/hidpi/ On Fri, Dec 6, 2013 at 10:54 AM, Andrew Grieve wrote= : > Problem with viewport tag? > > > On Fri, Dec 6, 2013 at 10:07 AM, James Jong wrote: > > > Are you targeting prior to iOS 5? > > -James Jong > > > > On Dec 6, 2013, at 9:49 AM, Maxime LUCE wrote: > > > > > By default, Cordova ios project targets iOS 5+, could it be blocking = ?? > > > > > > > > > Cordialement. > > > > > > > > > Maxime LUCE > > > > > > > > > maxime@touchit.fr > > > 06 28 60 72 34 > > > http://touchit.fr > > > > > > > > > -----Original Message----- > > > From: mmocny@google.com [mailto:mmocny@google.com] On Behalf Of Micha= l > > Mocny > > > Sent: vendredi 6 d=E9cembre 2013 15:45 > > > To: dev > > > Subject: Re: iOS webview size > > > > > > 320 sounds like the width of the first three generations of iphone > > (though the height is not 240 but 480). Perhaps you are emulating an > older > > device? > > > > > > > > > On Fri, Dec 6, 2013 at 9:28 AM, Maxime LUCE wrote= : > > > > > >> Frame is fullscreen but frame content is sized > > >> > > >> > > >> Cordialement. > > >> > > >> > > >> Maxime LUCE > > >> > > >> > > >> maxime@touchit.fr > > >> 06 28 60 72 34 > > >> http://touchit.fr > > >> > > >> > > >> -----Original Message----- > > >> From: James Jong [mailto:wjamesjong@gmail.com] > > >> Sent: vendredi 6 d=E9cembre 2013 14:47 > > >> To: dev@cordova.apache.org > > >> Subject: Re: iOS webview size > > >> > > >> Sounds like you have some customization in obj-c or the nib files. > > >> The frame should be fullscreen by default. > > >> -James Jong > > >> > > >> On Dec 6, 2013, at 8:25 AM, Maxime LUCE wrote: > > >> > > >>> Hi, > > >>> > > >>> I will try to explain the issue more precisely. > > >>> When I launch my app using XCode in the iOS emulator, I can see tha= t > > >>> my > > >> app is resized in a 320x240 frame. This behavior force iOS to resize > > >> every DOM elements to adjust to an arbitrary 320x240. > > >>> > > >>> I checked the behavior by putting a "alert(document.width) on start > > up". > > >>> > > >>> Someone could help me override this behavior ? I'm not an iOS nor > > >> objective C expert. > > >>> > > >>> > > >>> Cordialement. > > >>> ---------------------------- > > >>> Maxime LUCE > > >>> maxime@touchit.fr > > >>> 06 28 60 72 34 > > >>> http://touchit.fr > > >>> > > >>> > > >>> Not sure what you mean. > > >>> > > >>> Are you saying you can only have a canvas with a max size of > > >>> 320x240? I > > >> have an app with a larger canvas than that. > > >>> > > >>> If that is what you are saying, be sure you are not trying to set > > >>> the > > >> canvas size just using CSS. > > >>> > > >>> For an example maybe have a look at my canvas demo: > > >>> > > >>> https://github.com/devgeeks/Canvas2ImageDemo > > >>> On 06/12/2013 12:06 pm, "Maxime LUCE" wrote: > > >>> > > >>>> Hi everyone, > > >>>> > > >>>> It appears that on iOS, webview is restricted to a 320x240 canvas. > > >>>> > > >>>> Is it possible to automatically set canvas size using device > > >>>> screen's > > >> one ? > > >>>> > > >>>> Why is it not the default scenario ? > > >>>> > > >>>> Cordialement. > > >>>> ------------------------------- > > >>>> Maxime LUCE - Somatic > > >>>> maxime.luce@somatic.fr > > >>>> 06 28 60 72 34 > > >>>> > > >> > > >> > > > > > --047d7b86e3d8a7d41c04ece04fee--