Guidelines for "rounded" icon in Android 7.1 - android

Android 7.1 now supports Round Icon Resources.
Are there any "hard" specifications/requirements for the rounded icon?
So far, I have only seen round icons with a white background, is that mandatory?
It would be great to have some information on the padding of the circle, for example.

Related

How to change icon shape in Android 12 Splash screen?

I want splash screen icon in Rectangle shape instead of rounded shape in android 12
I don't believe you can. If you look at point 3 here: https://developer.android.com/about/versions/12/features/splash-screen#elements
It describes the image "As with adaptive icons, ⅓ of the foreground is masked"
The shape of the icon shown is just whatever shape is being used by the system for adaptive icons.
The splash screen changes in android 12 are specifically to reduce the amount of customisation you can do on splash screens, to keep the UX more consistent between apps. The customisation options that do exist are detailed on that page too.
Make your logo's canvas around 35% bigger, with the square logo in the middle, keeping the logo the same size. Then Android 12 will round a 1/3rd of the image, but your logo will be untouched.

How to Remove white Background from icon?

I have an app on android that create home shortcut icon.
The image of the icon is image that i set programmatically from the drawable
Now the problem is, when the shortcut was created on the home screen it's created with white background.
How do i remove that white backgroubd and set image to full size of icon?
Thank you all..
EDIT: the app i was talking about is app that i developed using android studio and just want to set full size of image when i create home shortcut
This is highly dependent on the launcher you use. The image looks like the standard google android 8+ (?) icon shape.
I theory it could be part of the icon you created but since you are asking this I doubt it.
In older versions of android the outer shape of the icons were individual, while rather cool and the outline correctly shown while dragging them etc many complained about the lack of a uniform look of all the icons in the app drawer etc.
It was introduced to make all icons seem more uniform.
Long pressing an empty space in the Google Pixel launcher for example shows a choice to go into the settings for the launcher and there you can change the shape all icons should have:
In addition to this, apps can take advantage of the various shapes and adapt to them and fill them out so to speak. See for example the Chrome icon while changing the icon shapes in the launcher settings.
Introduced in android 8: The feature is called adaptive icons.
See the docs about adaptive icons here:
https://developer.android.com/guide/practices/ui_guidelines/icon_design_adaptive
That is because of adaptive icons - a feature of Android 8 and can't or shouldn't be changed. You can at best change the colour of the background.
i removed the white background from the launcher icon by following these guidelines https://developer.android.com/studio/write/image-asset-studio
a few more points
in the background layer, move the slider to resize the icon until you see no what would have been the white background.
in the manifest file, change the icons to reference the mipmap folder;
android:icon="#mipmap/yourlogo"
android:roundIcon="#mipmap/yourlogo"

Get rid of the margin on Image Asset for launcher icons on Android Studio

I am trying hard to get rid of the extra margin around the ic launcher icons generated by Android Studio without luck. I know this is one of Google's material design trends. Though, the icons are so small on devices which is ugly.
I have Googled for around three hours and the only workaround I could find is to generate the clipart with a transparent background and photoshop the background with rounded corners which is pretty slow.
Is there a better solution than this?
Thank you.
Per the Designing adaptive icons blog post, the adaptive icon images created in the drawable directory for use on API 26+ devices follow the adaptive icon size and shape:
You'll note that while the entire image must be 108dp by 108dp, the actual visual area is only the center 72dp - the outer edge is only seen when dragging the icons around (where parallax effects may cause it be visible).
The Pixel Launcher, as well as many third party launchers, enforce the use of adaptive icons on API 26+ devices, so you should always design with that requirement in mind - the alternative, in the Pixel Launcher's case for instance, is to place your non-adaptive icon within a white circle.
Therefore you should always design your icon such that the background layer takes up the full size, but any foreground image you put on top of that background layer should be contained within that center area.
You can't just remove that margin without the foreground image being messed up, but as per the Implementing Adaptive Icons follow up blog post, you can remove any white excess around the foreground by putting your trimmed image within a transparent drawable of 108dp x 108dp by using an InsetDrawable.
<!-- Center a 54x54dp image in the 108x108dp size of adaptive icons -->
<inset
android:drawable="#mipmap/ic_fg_trimmed"
android:insetLeft="25%"
android:insetTop="25%"
android:insetRight="25%"
android:insetBottom="25%" />
Although this would have to be something you'd need to do to the ic_launcher_foreground image yourself after the fact.
A better solution, in most cases, is to use vector drawable images as the input to the Android Studio Image Asset wizard - this will ensure they are always the right size and don't take up any additional space in your APK.
I think i had the same problem as you. I solved this with a nasty hack, in the AndroidManifest.xml I just changed the roundIcon to point to the standard icon.
<application
…
android:icon="#mipmap/ic_launcher"
android:roundIcon="#mipmap/ic_launcher"
See more from the docs.

Icon Launcher Creating Icons Inconstantly Switching Between Round and Square

I have three different applications, all of which I am using the same style to create icons. Right-click mipmap > New > Image Asset
Using these settings:
But two icons have shrunk to the center of a round icon (blue and green) and one has the full icon as a square (Red) Which is I want.
When I look in Finder at the icons themselves they look normal.
Any ideas?
Read the Adaptive Icons Documentation. If you target 26+, you need to provide adaptive launcher icons or the launcher will place your default icon fully within the mask of the launcher icon background. Notice that Gmail also has the white circle around its icon in your screenshot.

Why so much Android Studio launcher icon padding?

The Android design guidelines state that a launcher icon should be 48dp across, with 1dp padding within that on each side, meaning the actual icon is 46dp in size (assuming a square icon). https://www.google.com/design/spec/style/icons.html#icons-product-icons
But when I use the launcher icon creation tool in Android Studio (from an image) it creates an icon with much more padding than that (it is not coming from the source image). For example my mipmap-xxxhdpi asset is 192x192px as expected, but excluding the padding Android Studio added the icon is only 160x164px, equivalent to 40dp, not 48dp.
It looks to me that Android Studio is failing to adopt the Android design guidelines regarding launcher icons, and adding substantially more padding than is needed, but I am posting here in case I'm missing something.
Update, added an example showing the expansive padding.

Categories

Resources