Configuring the navigation bar as transparent and dark at the same time

There are some Android 4.4 applications in which the navigation bar of the system is both dimming and transparent. One example of this is the camera app on the Xperia Z1:

f

I am trying to find a way to replicate this, and so far I have no problem setting the navigation bar as translucent (for example, by setting the style to android:Theme.Holo.NoActionBar.TranslucentDecor) or as dimming:

View decorView = getWindow().getDecorView();
int uiOptions = View.SYSTEM_UI_FLAG_LOW_PROFILE | decorView.getSystemUiVisibility();
decorView.setSystemUiVisibility(uiOptions);

The fact is that I can’t find a way to make both of them at the same time (i.e., blur and transparent at the same time). It seems that whenever I define an application style to use a transparent navigation bar, the dim flag ceases to have any effect.

... ? .

+4

Source: https://habr.com/ru/post/1535657/


All Articles