I've got a splash screen problem where I've got a simple logo I'd like to be roughly in the center of the screen. For some reason, the drawable I have is taking up the whole screen, and won't center my image neatly in the center. I've heard of 9-patch images, but I'm not sure if that's applicable to this (I think this is for icons?). Anyway, here is what I have for a drawable.
<?xml version="1.0" encoding="utf-8"?>
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
<item android:drawable="@color/orangey_red"/>
<item android:gravity="center">
<bitmap android:src="@drawable/ic_launcher"
android:gravity="center"/>
</item>
</layer-list>
I also have a theme defined for this drawable. Here is /values/style.xml
<resources>
<style name="MyCustomTheme" >
<item name="android:windowBackground">@drawable/splash_screen_drawable</item>
<item name="android:windowNoTitle">true</item>
<item name="android:windowFullscreen">true</item>
</style>
</resources>
I'm using Xamarin.Android (native), and cannot figure this problem out.
won't center my image neatly in the center
, I think it is better to give a picture for you result and what do you want to get.