Actionbar Logo size? - android

In the Google I/O 2012 Android App an actionbar logo is used instead of the normal app icon. In the open source project I could find the image which is 340x72 and present only in this dimension. I searched if there is some specified size for using a logo in the actionbar, but I did not find anything. Do you know something about this?

I looked into the resources of the YouTube app, since that seems to be the only official Google app (besides I/O) that uses an action bar logo at the moment.
It contains three drawables for the logo:
drawable-mdpi/ic_logo_wide.png (75 x 32 px)
drawable-hdpi/ic_logo_wide.png (112 x 48 px)
drawable-xhdpi/ic_logo_wide.png (149 x 64 px)
According to Iconography from the Android design guidelines, those images' heights match the specification for the action bar icons, which is 32 x 32 dp.
32 dp = 32 px (MDPI)
32 dp * 1.5 = 48 px (HDPI)
32 dp * 2 = 64 px (XHDPI)
You'll notice that the 72 px (XHDPI) from the I/O app don't show up. I guess, they just wanted to increase the logo's height a bit.
If a drawable is only provided in XHDPI, Android scales it down, which is a little less performant than providing the images in the proper sizes. I guess, this was just accepted by the developers of the I/O app.

Related

What sizes should an Image in an navigation drawer be?

What sizes should the image be for each phone size (HDPI, MDPI, XHDPI, XXHDPI) in the navigation drawer like this one?
It should be 24dp. Refer image from material design specification for navigation drawer.
For entire specification of navigation drawer check out this link http://www.google.com/design/spec/patterns/navigation-drawer.html
According to the Google I/O 2015 App source code, it should be 40dp
You can check it here:
https://github.com/google/iosched/blob/master/android/src/main/res/layout/navdrawer.xml
Lines 72 and 73. You will see:
android:layout_width="#dimen/navdrawer_profile_image_size"
android:layout_height="#dimen/navdrawer_profile_image_size"
And, in the dimens.xml file (https://github.com/google/iosched/blob/master/android/src/main/res/values/dimens.xml), in line 136, you will be able to check that the dimen value is:
<dimen name="navdrawer_profile_image_size">40dp</dimen>
I personally found it the perfect size. It's the same used in the Gmail App, if I'm not wrong.
Edit:
I've tried and didn't achieved to get the same size than the Google I/O App, even using their exact dimen variables.
So I've created and measured the sizes, following the rules of the Google specs (https://www.google.com/design/spec/patterns/navigation-drawer.html#navigation-drawer-specs) and I achieved this which looks quite similar to Gmail and Google I/O Apps:
Hope this helps,
If you are designing in Photoshop or something similar and you need to work in pixels, the ratio of the navigation drawer image should be 16:9
In xxxhdpi folder it should be 1216 x 688 (pixels)
You might want to have your icons auto-generated (to give you the right sizes).
See Android Asset Studio.
Just select an ICON that you want from their collection (or UPLOAD one of your own), and choose the parameters (colors, etc) to match your project, and download..
You'll probably want this flavor of icons: Action bar and tab icons
The size should be based on device size for that use below icon sizes.
mdpi : 24 x 24 px
hdpi : 36 x 36 px
xhdpi : 48 x 48 px
it will fit based on device size.

Using the formula px = dp * (dpi/160) for creating image resources does not result in sharp images

Although this question is not related to programming, it is related to app development.
Suppose I have an ImageView whose dimensions are 40dp*40dp. If I use the above formula to create an icon for a device with screen density 217 ppi, the size of the icon that fits the ImageView exactly is 55px*55px. If I use this icon in the view in consideration, the result is that the icon does not appear very sharp.
On the other hand, if I use a larger image of size, say 80px*80px, it appears sharp. So this larger image is larger than the exactly fitting one by a factor of 1.6.
What I would like to know is whether there is a certain value of the above factor that is most efficient and conventional. I would like to follow conventions while developing my apps.
Thanks for your time.
Your ImageView size is 40dp, thats equal to:
40 x 1.0 = 40 pixel on mdpi devices
40 x 1.5 = 60 pixel on hdpi devices
40 x 2.0 = 80 pixel on xhdpi devices
40 x 3.0 = 120 pixel on xxhdpi devices
40 x 4.0 = 160 pixel on xxxhdpi devices
Now your device is hdpi (217). for thats device you need a 60x60 pixel bitmap, and you have to put it in the drawable-hdpi directory.
Using drawable directory is like using drawable-mdpi directory. fro each resource in that directory android will scale it up/down before using it.

How do some Android Apps get larger than recommended icons?

I followed what I believed to be the Android official icon sizes:
ldpi: 36x36px
mdpi: 48x48px
hdpi: 72x72px
xhdpi: 96x96px
My icon looks the same size as some other icons (the facebook one for example). But others, such as Trip Advisor and Kayak are moderately larger than these 2. What are these other apps doing to make their icons this size? I am fine following the guidelines, but my client is upset that their icon is not as large as these others. I have seen this behavior on several devices, but mostly ones with larger resolutions.
Thanks!
Edit: Removed icon.
Edit 2: I needed to add a 144x144 px icon into my xxhdpi folder. Issue was resolved.
You'll need to add a 144x144px icon into drawable-xxhdpi and a 192x192px icon into drawable-xxxhdpi.
It seems that if you do not have these versions on a high-density display, when they are scaled up padding is added.
So the solution is to make sure you have the high-density versions in your build as well.
Simply because they do not follow the guidelines and android allows you to have
Look at http://petrnohejl.github.io/Android-Cheatsheet-For-Graphic-Designers/
You are supposed to have
96 x 96 Canvas size
84 x 84 Actual drawing size
What other apps do is 96 x 96 of non transparent pixels

What are the sizes of the icons in Android notifications action-buttons?

In expandable Notifications: what dimensions (in dp) should the icons have?
Like the Icons for Snooze and Email here:
So to clarify this, I found the following in the Javadoc within the Android support library:
Add an action to this notification. Actions are typically displayed by
the system as a button adjacent to the notification content.
Every action must have an icon (32dp square and matching the Holo Dark
action bar visual
style,
a textual label, and a
PendingIntent.
A notification in its expanded form can display up to 3 actions, from
left to right in the order they were added. Actions will not be
displayed when the notification is collapsed, however, so be sure that
any essential functions may be accessed by the user in some other way.
So these should be identical to your action bar icons (for the Holo Dark theme), which is:
Asset Size: 32dp x 32dp
Optical Square: 24dp x 24dp
Color (Enabled): #FFFFFF 80% opacity
Color (Disabled): #FFFFFF 30% opacity
In Pixels:
22 × 22 area in 24 × 24 (mdpi)
33 × 33 area in 36 × 36 (hdpi)
44 × 44 area in 48 × 48 (xhdpi)
66 × 66 area in 72 × 72 (xxhdpi)
88 × 88 area in 96 × 96 (xxxhdpi)
as seen on http://iconhandbook.co.uk/reference/chart/android/
I did a tear down of the gmail apk:
it seems those icons are 32 x 32 dp
hope someone can confirm this
Preferred Notification Icon Size 24x24dp
mdpi # 24.00dp = 24.00px
hdpi # 24.00dp = 36.00px
xhdpi # 24.00dp = 48.00px
Wow, the answers here seem to mix apples and pears without references or a definitive answer. What you're usually interested in when creating an icon image is the size in pixels, not dp (density-independent pixels).
Looking at the UI guidelines for status bar icons on the official Android Developer website, it clearly lists the recommended icon sizes in pixels.
lpdi mdpi hdpi xhdpi
Status bar icon size
in pixels 18x18px 24x24px 36x36px 48x48px
(Android 3.0 and later)
You can also include a few pixels of padding in status bar icons to maintain a consistent visual weight with adjacent icons. For example, a 48 x 48 pixel xhdpi status bar icon can contain a 44 x 44 pixel shape with 2 pixels on each side for padding.

increasing the launcher icon size

How can i increase the size of launcher icons . I know that my custom launcher is taking images from the drawable-mdpi folder & the allowed icon size is 48x48 . I cant increase the size of launcher icon more than this.
Please help me
the icon of luacher it prepered by system itself you just put in your resources the icons for each vervion and below the standard size for each version
LDPI - 36 x 36
MDPI - 48 x 48
HDPI - 72 x 72
XHDPI - 96 x 96
WEB - 512 x 512
There was two way
1. Create your icon using 9-patch with your required size
2. Create different size of icon and put them in different drawable size. For this to know the size for specific like hdpi, mdpi etc just create sample/ open any exiting project which was created in juno(eclipse editor).
Here the specific size detail for different devices
ldpi-36x36
mdpi-48x48
hdpi-72x72
xdpi-96x96
web - 128x128

Categories

Resources