Search code examples
androidoverlaystatusbar

Create rounded corner and status bar padding overlay Android 10


I am compiling pixel experience 10 but the status bar presents a huge padding and the device in stock rom uses software corner rounding. Can anyone give me a hand on building an overlay for these two values please?


Solution

  • For software rounded corners, create an overlay for frameworks/base/core/res/res/values/dimens.xml and inside:
    Only <dimen name="rounded_corner_radius">100px</dimen> if top and bottom corners have the same radius, or both <dimen name="rounded_corner_radius_top">110px</dimen> and <dimen name="rounded_corner_radius_bottom">130px</dimen> if they are different.

    For side padding concering rounded corners, create an overlay for frameworks/base/packages/SystemUI/res/values/dimens.xml and inside <dimen name="rounded_corner_content_padding">16dp</dimen>