Closed Bug 794942 Opened 12 years ago Closed 11 years ago

Low resolution refresh button on the Nexus 7 (TVDPI)

Categories

(Firefox for Android Graveyard :: Theme and Visual Design, defect)

ARM
Android
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: aaronmt, Assigned: sriram)

References

Details

Attachments

(1 file)

See screenshot.

This looks like an Ian/Sriram bug.
OS: Mac OS X → Android
Hardware: x86 → ARM
https://plus.google.com/105051985738280261832/posts/6eWwQvFGLV8
Does this by any chance helps us?

Should we probably create a tvdpi folder?
I'd like to confirm that the assets we are using are not being scaled first. It looks like that's the problem here, and the range of resolutions we support should mean that there ought to be an icon set that works here without being blurry. 

From that link, "We consider tvdpi to be a "secondary" density -- one that counts as a compatible device, but which we discourage developers from creating assets for." <-- I tend to agree with this, simply because of the sheer number of asset sizes we already support.
The super low res refresh button keeps me up at night :(
Flags: needinfo?(sriram)
Sriram, can we check and see if we're scaling these in some funky way?
As per my calculations, the browser toolbar height on Nexus 7 is 75px -- though the size should have been 84px. How?

Nexus 7 is a tvdpi device. As per docs: http://developer.android.com/guide/practices/screens_support.html#qualifiers , tvdpi is somewhere between mdpi and hdpi with about 213ppi. Nexus 7 has 216ppi and falls in right there at tvdpi. But, to help the developers, they take hdpi resources and scale them down.

What's the scaling factor?
Docs says that the factor is 1.33*mdpi. Usual hdpi is 1.5*mdpi. But Nexus 7 is a bit different. It uses a scale of 1.34 (actually 1.339). A 50dp on Nexus 7 uses 67px on the device. Hence our sizes of 1.5*mdpi would fail a bit.

Additional problem:
The url-bar being 75px, we tend to leave 1/4th padding on all sides. That's about 19px (18.75 approximated). Hence the size to show the icon is 37px. We are trying to shrink a 42x42 px image to a 37x37 px canvas. This causes the blurry effect.

Options:
1. Let the action-bar be 60dp (instead of 56dp) on Nexus-7. This would translate to 80px on the device. Leave 1/4th of space around for padding will give the image a size of 40x40px window. Still a 42x42px would be squeeze in. (Even to even scaling is better than even to odd scaling).
2. Leave url-bar at 56dp, use a different padding on Nexus 7, that would ensure that the image is 42x42px or 38x38px (basically even to even scaling).
3. Specify a new folder for tvdpi resources. ( :cough: :cough: ).

Though the bug is for refresh button, this causes other icons blurry too. Like Back/Forward, lock icon (everything!)

Either we need to be make sure the size after scaling is good (scaling from: 1.5x to 1.34x). Or new set of resources.

Intuition: We might not see much blur with flat resources that would land with holo-ish theme. But I might be wrong too.
Flags: needinfo?(sriram)
Blocks: 784364
> Options:
> 1. Let the action-bar be 60dp (instead of 56dp) on Nexus-7. This would
> translate to 80px on the device. Leave 1/4th of space around for padding
> will give the image a size of 40x40px window. Still a 42x42px would be
> squeeze in. (Even to even scaling is better than even to odd scaling).
> 2. Leave url-bar at 56dp, use a different padding on Nexus 7, that would
> ensure that the image is 42x42px or 38x38px (basically even to even scaling).
> 3. Specify a new folder for tvdpi resources. ( :cough: :cough: ).

Can we learn anything from how other Android apps are handling this odd device resolution? I'm just wondering if TVDPI is something we really want to support, as it doesn't even really appear in Android's design guideline documentation.
To be clear, I want the images to be super crisp. I'm just wondering if that can (or should) be done with assets we already have.
Fixed by so many other bugs.
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Product: Firefox for Android → Firefox for Android Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: