0

I am working on an Xamarin.Android app and noticed the app icon doesn't look right on a Xiaomi Poco F3 smartphone running Android 11.

There is a very thin white line on top, bottom, left and right of the icon. It seems like the square icon was used and cut to fit a circle but it doesn't fit entirely.

See the second to the left app icon with the blue background:

enter image description here

The app is using the legacy approach for app icons:

Icon dimensions are as recommended: 48 x 48 pixels (mdpi), 72 x 72 pixels (hdpi) and so on... and look fine on other devices (Samsung Galaxy S5 (Android 6), Pixel 2 (Android 9)).

mipmap folders:

enter image description here

MainActivity:

[Activity(
    ...
    MainLauncher = true,
    Icon = "@mipmap/ic_launcher",
    RoundIcon = "@mipmap/ic_launcher_round",
    ...
    )]

Target version: Android 11.0 (API Level 30)

Minimum version: Android 4.1 (API Level 16)

No third party launcher installed.

Anyone experienced something similar? Can it be fixed without creating new icons?

Reepicheep
  • 33
  • 7

2 Answers2

2

Had similar issue on Xiaomi Redmi Note 8 Pro.

For some reason android studio resource manager didn't create mipmap-anydpi-v26 folder. (Screen 1)

Res screen

Check if you have one.

For me deleting all icon res and creating new helped. (Don't know why, but rewriting it is buggy. Some are missing during this procedure)

1

That is an interesting question. You just have to follow my simple steps down below.

1. Right-click on the "res" 2. New --> Image Asset

enter image description here

3. On the Asset Studio window, you will find a section called "Scaling" right below Scaling --> resize.

enter image description here

Now you can resize your icon and that is how you can make a white thin layer disappear. I hope this might help Thank you.

Uncle Roger
  • 183
  • 12
  • 1
    You can set background color same as Icon/Image background color(Blue) @Reepicheep – Jinal Patel Mar 09 '22 at 12:42
  • 1
    This should work , but you have to mention the operation should be done in `Android Studio`,and than migrate all the images to visual studio , refer to https://stackoverflow.com/a/53221631/8187800. – ColeX Mar 10 '22 at 02:54
  • I was hoping to avoid recreating the icons as it is very time consuming: Downloading Android Studio - there is no Image Asset Studio in Visual Studio 2019, etc.. But it seems resizing / removing of padding is the way to go. Thanks for your help. – Reepicheep Mar 10 '22 at 19:33
  • I'm glad that I'm able to help. – Uncle Roger Mar 12 '22 at 04:55
  • If it works consider marking it as answer because it's helpful to others. – ColeX Mar 14 '22 at 01:48