| Parameter | Description |
|---|---|
| types | The inset types to apply the appearance to. Multiple types can be combined. |
| appearance | The foreground appearance to apply to the specified inset types. |
Sets the foreground appearance of the specified inset types at build time.
Use this method to control whether system bar icons appear light or dark for individual inset types. Light uses light icons suitable for dark backgrounds, Dark uses dark icons suitable for light backgrounds.
Note: Only supported on Android 11 (API 30) and later. Has no effect on Android 10 (API 29) or earlier versions.
using UnityEditor;
public class ApplyInsetsAppearance { public static void Setup() { // Set the status bar to use light icons (for dark backgrounds). PlayerSettings.Android.SetInsetsAppearance(AndroidWindowInsetsType.StatusBars, AndroidWindowInsetsAppearance.Light);
// Set the navigation bar to use dark icons (for light backgrounds). PlayerSettings.Android.SetInsetsAppearance(AndroidWindowInsetsType.NavigationBars, AndroidWindowInsetsAppearance.Dark); } }