Android Notification smallIcon not displaying properly - android

So I've been working with Android Notifications and after setting a large image, I found out that my small image is actually not displaying properly.
As you can see on the following screenshot of the lockscreen, the background of the small icon is transparent. I want to set a specific colour there, just like the one Outlook.com is using:
Another example where the small icon shows next to the large one (please take notice of the small icon which is actually displaying, but not really noticable because there is just no background):
I've been thinking about changing the small icon to include the background colour, but obviously the colour would also be shown in the statusbar and that's wrong.

Try setColor() with NotificationCompat.Builder to set the accent color, which should be used by the colored circle behind the icon.

Related

why the image for notification icon generated using Android Asset Studio is completely white?

so I want to make icon for push notification. say for example I want to use the android image below as notification icon
https://p7.hiclipart.com/preview/135/689/279/android-computer-icons-logo-android.jpg
so I try to make it using Android asset studio. but the image generated from this Android Asset studio is completely white like this
what should I do ? is there any image requirement for this ?
Use Transparent Images
The icons generated will be totally solid color (dark grey or white will be used on the device depending on theme).
The icon you add should only contain the "shape" you want to show as the single color. The rest should be transparent pixels.
Any non-transparent pixels will be converted to white. So if you have a square logo with no transparent pixels, it will be a giant single colored square.
Use a .png image so you can save it with transparent background.
As you can see, icons in notifications bar are white, that's why you are seeing all white

Removing Grey and White Chequered background in Android Image Asset Studio

I am trying to remove the Grey and White Chequered background from a launcher icon jpg file using Android Studio's Image Asset.But no luck so far.
Is there any way to do this?
below is the Background :
The checkerboard background is for transparency. Same happens in paint.net. If you end up with transparency, you get a checkerboard like that of white and grey.
It is technically not a background, you don't actually see that in the launcher. Alpha shows as a checkerboard to ensure you know you are seeing alpha. If you install it on a device, you can see what is "under" the launcher icon. If your icon is 256x256, and has a 10x10 square of transparency in the middle, you will see a checkerboard there too. If you then launch it on the device and check the launcher, you will see that there is a see-through hole in the middle.
Basically, the checkerboard isn't a background - it is transparency.
With the exception of the times where you actually create a checkerboard on purpose, but that can then be deleted by modifying the .png file
Right-click on image, form the menu that pops up select Hide Chessboard.

In android, how to set the 2 small icons visible in the notification

In android notification, it's seam their is 3 different icons (see the picture below). I know how to set the large icon (via setlargeicon), however i don't know how to set the both 2 small icons as their is only one procedure setSmallIcon available.
It is the same setSmallIcon for both locations. However, you can also use setColor() to set the background color on the notification - that is how the lower icon gets the blue background.

Notification icon is greyed out

I created an image in a 96x96 size, gave padding of 4px on all sides following this information.
Then I used Android Asset Studio to generate icons for different screens. But when I used these in my Notification Builder it is showing a grey box. Where am I doing wrong?
This is my image. Unable to display it here as background is transparent and image is white in color. Please download to see it.
I have the same problem. all my colors are white over transparent png, i still get plain white square on it. I checked the drawable folder have already generated 12 corresponding ic_stat_name.png file and they look as expected. But when i send notification the icon still appear white square.
I found the solution
Notification Icon with the new Firebase Cloud Messaging system
I use firebase notification which, according to the above source, will use the launcher icon instead of my expected ic_stat_name.png for notification

How can I get rid of transparent background space in (Android Asset Studio - Icon Generator)?

When I upload my image (which has no background to begin with), it is automatically given transparent background no matter what settings I choose. I really like the "Square" shape (rounded corners) but there is way too much excess transparent background. When I see the icon on my phone it looks so small compared to Facebook for example. How can I get rid of this extra background space to make it as large as possible? Is one of my settings off?
http://reiszecke.github.io/AndroidAssetStudioFullsize/
Just click on >> Launcher icons << Full Size edit
pls mark as answer if it helped.
EDIT: only works on "bevel" and "none", I will adjust the other shapes at some point
http://www.gieson.com/Library/projects/utilities/icon_slayer/
Does the job but the an image must be provided first.
Creating the logo and background with LIG and loading the result in the gieson's icon_slayer should do it.

Categories

Resources