HTC One density?

fraxinus

Member
Licensed User
Longtime User
Hi all
What Density should I use for development of the HTC One phone the specs are:
720 x 1280 pixels, 4.7 inches (~312 ppi pixel density)

thanks
Rob
 

Mahares

Expert
Licensed User
Longtime User
312 ppi pixel density results in a scale of approximately 2. If you use a layout variant of 360x640 with a scale of 1, you should be good to go. If I misunderstood the question, please ignore.
 
Upvote 0

fraxinus

Member
Licensed User
Longtime User
Thank you Mahares.
I'll give it a try. I've been using the following(last on list) for this device but the owner gets a black screen when trying to run app.
The rest are working on various devices.
So how would I incorporate your recomendations.
Thanks again for your help.
Rob

LayoutVal = GetDeviceLayoutValues
Dim Dens As Float
Dens = Density
If LayoutVal.Width <=240 AND Dens = 0.75 Then
LayoutWidth = 240
Activity.LoadLayout("Main240x320")
DeviceType = Dim240x320
Else If LayoutVal.Width <=240 AND Dens = 1 Then
LayoutWidth = 240
Activity.LoadLayout("Main240x320")
DeviceType = Dim240x320

Else If LayoutVal.Width =320 AND Dens = 1 Then
LayoutWidth = 320
Activity.LoadLayout("Main320x480")
DeviceType = Dim320x480

Else If LayoutVal.Width = 480 AND Dens = 1.5 Then
LayoutWidth = 480
Activity.LoadLayout("Main480x800")
DeviceType = Dim480x800

Else If LayoutVal.Width = 600 AND Dens = 1.5 Then
LayoutWidth = 600
Activity.LoadLayout("Main600x1024")
DeviceType = Dim600x1024

Else If LayoutVal.Width >= 800 AND Dens = 1 Then
LayoutWidth = 800
Activity.LoadLayout("main800x1280")
DeviceType = Dim800x1280

Else If LayoutVal.Width >= 720 AND Dens = 1.5 Then
LayoutWidth = 720
Activity.LoadLayout("main720x1280x15")
DeviceType = Dim720x1280

Else If LayoutVal.Width >= 720 AND Dens = 2 Then
LayoutWidth = 720
Activity.LoadLayout("main720x1280x2")
DeviceType = Dim720x1280

End If
 
Upvote 0

fraxinus

Member
Licensed User
Longtime User
Thank you Erel, you are,as usual correct. I have just purchased version 1.9 and
and will try my best to implement the Designer Script in my App.
yours
Rob:sign0098:
 
Upvote 0
Top