一、找到启动的第一个页面,可以在AndroidManifest.xml配置,也可以在代码里面配置他的主题即可。
<activity android:name=".guide" android:theme="@style/myApptheme"> <intent-filter> <action android:name="android.intent.action.MAIN" /> <category android:name="android.intent.category.LAUNCHER" /> </intent-filter> </activity> </application>
二、自己定义一个主题:
<style name="AppTheme" parent="Theme.AppCompat.Light.DarkActionBar"> <!-- Customize your theme here. --> <item name="colorPrimary">@color/colorPrimary</item> <item name="colorPrimaryDark">@color/colorPrimaryDark</item> <item name="colorAccent">@color/colorAccent</item> </style> <style name="myApptheme" parent="AppTheme"> <item name="android:background">@drawable/part1</item> <item name="android:windowFullscreen">true</item> </style>这样AndroidManifest.xm配置就完成了,启动APP就不会出现空白页,至于在代码里面的配置也只需要将主题设置即可。