2

I create a simple splash screen with an AnimatedIcon (the black circle ... a simple block.png) and a BrandingImage (the red square: arborisoft_branding.png)

<?xml version="1.0" encoding="UTF-8"?>
<resources>
    <style name="My.SplashTheme" parent="Maui.SplashTheme">
        <item name="android:windowBackground">@drawable/arborisoft_background</item>
        <item name="android:windowSplashScreenBackground">#FFFFFF</item>
        <item name="android:windowSplashScreenAnimatedIcon">@drawable/block</item>
        <item name="android:windowSplashScreenBrandingImage">@drawable/arborisoft_branding</item>
        <item name="android:windowSplashScreenAnimationDuration">0</item>
    </style>
</resources>

No problemo on Samsung Galaxy S20+ :

But on some phones the BrandingImage goes above AnimatedIcon !

enter image description here

Can we configure something more? a maximum size of the AnimatedIcon, a margin, a position of the BrandingImage?

Thanks !

SpaaJ
  • 61
  • 6
  • Define the PNG at different sizes in different resource folders based on screen size/orientation: https://developer.android.com/guide/topics/resources/providing-resources#QualifierRules – Mark Aug 28 '22 at 15:29
  • I tried your solution with all the mipmap folders: it works ... but both phones use the same mipmap-xxhdpi :( – SpaaJ Aug 28 '22 at 16:41
  • 1
    It seems you used the android 12 splash screen api, so you can check [this case](https://stackoverflow.com/questions/69159905/is-possible-to-set-width-for-icon-in-android-12-splash-screens-api). – Liyun Zhang - MSFT Aug 29 '22 at 07:32
  • if I use scaleX scaleY it is also smaller on phones where it is already small ... like the 1st screenshot (like in your comment link : Using scaleX and scaleY leads to different icon sizes on different devices, e. g. Samsung devices show a lot smaller icon than the emulator.) – SpaaJ Aug 30 '22 at 10:42

1 Answers1

0

It's disappointing that the BrandingImage is displayed above the AnimatedIcon. I had to do a trick by playing on the height and positionning of the content of my images :(

But thank you!

Test result

SpaaJ
  • 61
  • 6