How to overlay an icon image over an existing view

If I have a link to a view, how can I overlay an icon image on top of an existing view? Like in the screenshot below ( http://android.kanokgems.com/sms-unread-count ):

screenshot showing an unread account on top of the icon

It overlays the icon in the upper right corner of the dialer icon. How can i do this?

Thanks.

+3
source share
1 answer

Using RelativeLayout, you can place 2 images in one place. The second image will be placed automatically on top of the first. You can assign properties to the second to align it to the left, bottom, top, or right of the first.

+3
source

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


All Articles