flex-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Maurice Amsellem (JIRA)" <j...@apache.org>
Subject [jira] [Comment Edited] (FLEX-34169) DPI not respected
Date Mon, 17 Mar 2014 15:01:57 GMT

    [ https://issues.apache.org/jira/browse/FLEX-34169?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13937879#comment-13937879
] 

Maurice Amsellem edited comment on FLEX-34169 at 3/17/14 3:00 PM:
------------------------------------------------------------------

Sorry, I overlooked the screenshot.
I understand what's going on.
Actually, your are not emulating real iOS devices, but "fictious" iOS devices, that's why
it does not work.
Let me explain from the beginning:
The general rule for computing applicationDPI is to test the real device DPI (132, 263, whatever)
against sucessive DPI buckets and to select the the highest one that is <= real DPI.
So in theory:


- iPad 2 (132 dpi, 1024x768) will get 120 
- iPad retina (263 dpi, 2048x1536) will get 240
- iPad mini (1024 × 768 px at 163 PPI) will get 160
- iPad mini retina (2048 × 1536 px at 326 PPI ) will get 320.
(source http://en.wikipedia.org/wiki/List_of_iOS_devices) 

But those theoretical conversions are problematic:
1) According to Apple guidelines, apps running on "mini" iPads should render identically to
their regular versions. ( iPad == iPad mini,  iPad retina == iPad mini retina) .
That won't be the case with the default conversion rule
2) in SDK 4.10 and before, the 120 DPI didn't exist. It was introduced in 4.11. So same app
that was designed for SDK 4.10 would render differently on SDK 4.11 on iPads (typically, everything
was 25% smaller). SDK 4.12 reverts to the original 4.10 layout.

For these reasons, we made an exception to the rule specifically for iPad devices, so that:
*iPad and iPad mini "regular" gets 160 dpi*
*iPad retina and iPad mini retina gets 320 dpi*. 
the detection is based on model=iPad and size of the display 1024x768 / 2048x1536.
That's why your "virtual" devices are getting strange result.
Now, you know how to fix it.

PS: that was stated in the SDK 4.12 release notes, in the SDK changes section:
http://www.apache.org/dyn/closer.cgi/flex/4.12.0/RELEASE_NOTES 

Sorry for the lengthy explanation, but it was necessary.


was (Author: mamsellem):
Sorry, I overlooked the screenshot.
I understand what's going on.
Actually, your are not emulating real iOS devices, but "fictious" iOS devices, that's why
it does not work.
Let me explain from the beginning:
The general rule for computing applicationDPI is to test the real device DPI (132, 263, whatever)
against sucessive DPI buckets and to select the the highest one that is <= real DPI.
So in theory:


- iPad 2 (132 dpi, 1024x768) will get 120 
- iPad retina (263 dpi, 2048x1536) will get 240
- iPad mini (1024 × 768 px at 163 PPI) will get 160
- iPad mini retina (2048 × 1536 px at 326 PPI ) will get 320.
(source http://en.wikipedia.org/wiki/List_of_iOS_devices) 

But those theoretical conversions are problematic:
1) According to Apple guidelines, apps running on "mini" iPads should render identically to
their regular versions. ( iPad == iPad mini,  iPad retina == iPad mini retina) .
That won't be the case with the default conversion rule
2) in SDK 4.10 and before, the 120 DPI didn't exist. It was introduced in 4.11. So same app
that was designed for SDK 4.10 would render differently on SDK 4.11 on iPads (typically, everything
was 25% smaller). SDK 4.12 reverts to the original 4.10 layout.

For these reasons, we made an exception to the rule specifically for iPad devices, so that:
iPad and iPad mini "regular" gets 160 dpi
iPad retina and iPad mini retina gets 320 dpi. 
the detection is based on model=iPad and size of the display 1024x768 / 2048x1536.
That's why your "virtual" devices are getting strange result.
Now, you know how to fix it.

PS: that was stated in the SDK 4.12 release notes:
http://www.apache.org/dyn/closer.cgi/flex/4.12.0/RELEASE_NOTES 

Sorry for the lengthy explanation, but it was necessary.

> DPI not respected
> -----------------
>
>                 Key: FLEX-34169
>                 URL: https://issues.apache.org/jira/browse/FLEX-34169
>             Project: Apache Flex
>          Issue Type: Bug
>          Components: .Unspecified - Mobile, Skinning
>    Affects Versions: Apache Flex 4.13.0
>         Environment: Windows 7, SP1
> Flash Builder 4.7
>            Reporter: Morten Gorm Madsen
>            Assignee: Maurice Amsellem
>            Priority: Minor
>         Attachments: Sample.fxp, screenshot-1.jpg
>
>
> Emulator DPI not respected.
> Set DPI -> applicationDPI
> 120 -> 160
> 160 -> 160
> 240 -> 240
> 320 -> 160
> 480 -> 160
> 640 -> 160



--
This message was sent by Atlassian JIRA
(v6.2#6252)

Mime
View raw message