Android Question Adaptive Icons In Android 9 'Pie'

RichardN

Well-Known Member
Licensed User
Longtime User
My lead development device is a Samsung S9+ which has just updated to Android 9 'Pie'. The first thing that strikes you is that all the icon frames have turned to 'Squircles' with most looking OK but some B4A apps looking very out of place. On the device there was previously a dialogue accessible from Home Screen > Home Screen Settings > Change Icon Shape. It now appears to have been removed completely in Pie.

More to the point, the 'Adaptive Icons' example provided by Erel at the top of the tutorial thread ... https://www.b4x.com/android/forum/threads/adaptive-icons.95244/ runs fine but does not produce the intended result. The foreground mask is not displayed at all and the 'B4A' text of the background is far too big so is being clipped by the Squircle that is applied by the OS. In my tests I cannot see any evidence of the foreground mask graphic at all, however the background (when suitably sized) appears in the Squircle. Any transparency of the background graphic now appears in white. I have also provided an ic_launcher.png graphic of a different colour so I can state with certainty that the ic_launcher graphic is not being displayed.

At the moment my apps with require a minimum of an icon rework to reduce them to the OS Squircle and the functionality of 'Adaptive Icons' remains a mystery.

Android.jar v28 JDK 1.8.0_201 Manifest as tutorial project

Any ideas?
 
Last edited:

RichardN

Well-Known Member
Licensed User
Longtime User
@Peter, thanks already been looking at those. I remain very suspicious with my (UK-3) device where I am unable to find any options to change the icon shape. Looking around YouTube 'First Looks' of Pie seem to suggest significant differences in the 'Pie' software supplied by different networks. I have seen at least two versions with completely different 'Icon Shape' selections. So far my device has yielded none!
 
Last edited:
Upvote 0

RichardN

Well-Known Member
Licensed User
Longtime User
My graphic assets seems to work fine with the Adapticon website with all of the different shapes..... ?????
 
Upvote 0

Brian Dean

Well-Known Member
Licensed User
Longtime User
I remain very suspicious with my (UK-3) device where I am unable to find any options to change the icon shape.

Just because you cannot find the option does not mean that its not there somewhere, in my experience. But you might be right, as manufacturers can provide their own app launcher.

I can only assure you that the Adaptive Icon tutorial provided by Erel, which you refer to in your first post, works perfectly on a "standard" device (I have a Google Pixel), but it is useful to read the Google article too. You have made both your foreground and background icons 108 pixels square, I hope.
 
Upvote 0

RichardN

Well-Known Member
Licensed User
Longtime User
@Brian.... Thank you for your observations. My point about Erel's example (now removed) is that the 'B4A' text of the background .png was much bigger than the foreground mask aperture so would always be cropped by the mask. The adapticon website noted by Peter Simpson above is a great resource for checking the final look & feel of your graphic layers. I was able to confirm my 108px graphics both worked and looked good.

As for the device support of adaptive icons.... I have seen chat elsewhere amongst mobile phone enthusiasts on the same subject. It seems possible that Samsung are pushing their paid-for icon sets which are readily available from the handset, and have removed the previous icon personalisation to promote their sales. I have posed the question to their technical support. I will post the reply if/when they decide to answer.
 
Upvote 0

Brian Dean

Well-Known Member
Licensed User
Longtime User
It seems possible that Samsung are pushing their paid-for icon sets ...

Yes - you might be right. As far as I can tell no manufacturer, including Google, is actually exploiting the effects that Google describe in their introduction (yet). So much trouble for so little benefit.
 
Upvote 0

RichardN

Well-Known Member
Licensed User
Longtime User
I have managed to get an answer from Samsung developer support about Adaptive Icons, Icon shape and OS support.

Unlike previous versions the Samsung implementation of Android Pie has NO facility to change icon shape so will not support adaptive icons. With Samsung's huge share of the Android market will affect many users.

More importantly, the 'Squircle' icon mask with a fixed white background actually changes the appearance of legacy icons, particularly square ones. I hesitate to say they are 'broken' but their appearance is changed markedly and the programmer is forced to re-think when designing icons.

In the Pie screen-shot below the top row of icons are web-page links that appear as apps used to under Oreo. The square graphic colour and detail extend into the corners and transparency continues to show the home-page background as one might expect.

New: The middle row of icons show the Samsung native apps. As you can see a more simplistic, naive design is used with colour extending to the limit of the mask with no transparency employed.

New: The bottom row shows third-party apps whose appearance has fundamentally changed. Where transparency was part of the design there is now a harsh white background. If the icon was circular then proximity to the squircle mask makes it look weird. Detail that extended into the corners of the graphic is cropped.

To fix this I have rethought my approach to icons. Forget using transparency unless white is OK. Circular images only look good against solid colour and they must remain well clear of the mask otherwise it looks weird. Square icons must not contain any detail close to or beyond the mask otherwise it is cropped. To facilitate this in my graphics editor I use a layer with a central guide circle that is 88% diameter of the square graphic side measurement. I then make the layer invisible before saving the final .png. It seems to have worked out OK so far.


pieicons.jpg
 
Upvote 0
Top